]> granicus.if.org Git - postgresql/blob - configure
Remove use of obsolescent Autoconf macros
[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.4devel.
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-2013, 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.4devel'
602 PACKAGE_STRING='PostgreSQL 9.4devel'
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_FLAGS
663 MSGFMT
664 HAVE_POSIX_SIGNALS
665 LDAP_LIBS_BE
666 LDAP_LIBS_FE
667 PTHREAD_CFLAGS
668 PTHREAD_LIBS
669 PTHREAD_CC
670 acx_pthread_config
671 have_win32_dbghelp
672 HAVE_IPV6
673 LIBOBJS
674 OSSP_UUID_LIBS
675 ZIC
676 python_enable_shared
677 python_additional_libs
678 python_libspec
679 python_libdir
680 python_includespec
681 python_version
682 python_majorversion
683 PYTHON
684 perl_embed_ldflags
685 perl_useshrplib
686 perl_privlibexp
687 perl_archlibexp
688 PERL
689 FLEXFLAGS
690 FLEX
691 BISONFLAGS
692 BISON
693 MKDIR_P
694 AWK
695 LN_S
696 TAR
697 install_bin
698 INSTALL_DATA
699 INSTALL_SCRIPT
700 INSTALL_PROGRAM
701 WINDRES
702 DLLWRAP
703 DLLTOOL
704 AR
705 STRIP_SHARED_LIB
706 STRIP_STATIC_LIB
707 STRIP
708 RANLIB
709 ld_R_works
710 with_gnu_ld
711 LD
712 LDFLAGS_SL
713 LDFLAGS_EX
714 ELF_SYS
715 EGREP
716 GREP
717 with_zlib
718 with_system_tzdata
719 with_libxslt
720 with_libxml
721 XML2_CONFIG
722 with_ossp_uuid
723 with_selinux
724 with_openssl
725 krb_srvtab
726 with_python
727 with_perl
728 with_tcl
729 enable_thread_safety
730 INCLUDES
731 autodepend
732 TAS
733 GCC
734 CPP
735 CFLAGS_VECTOR
736 SUN_STUDIO_CC
737 OBJEXT
738 EXEEXT
739 ac_ct_CC
740 CPPFLAGS
741 LDFLAGS
742 CFLAGS
743 CC
744 enable_dtrace
745 DTRACEFLAGS
746 DTRACE
747 enable_coverage
748 GENHTML
749 LCOV
750 GCOV
751 enable_debug
752 enable_rpath
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_rpath
815 enable_spinlocks
816 enable_debug
817 enable_profiling
818 enable_coverage
819 enable_dtrace
820 with_blocksize
821 with_segsize
822 with_wal_blocksize
823 with_wal_segsize
824 with_CC
825 enable_depend
826 enable_cassert
827 enable_thread_safety
828 with_tcl
829 with_tclconfig
830 with_perl
831 with_python
832 with_gssapi
833 with_krb5
834 with_krb_srvnam
835 with_pam
836 with_ldap
837 with_bonjour
838 with_openssl
839 with_selinux
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.4devel 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.4devel:";;
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-rpath         do not embed shared library search path in
1494                           executables
1495   --disable-spinlocks     do not use spinlocks
1496   --enable-debug          build with debugging symbols (-g)
1497   --enable-profiling      build with profiling enabled
1498   --enable-coverage       build with coverage testing instrumentation
1499   --enable-dtrace         build with DTrace support
1500   --enable-depend         turn on automatic dependency tracking
1501   --enable-cassert        enable assertion checks (for debugging)
1502   --disable-thread-safety disable thread-safety in client libraries
1503   --disable-largefile     omit support for large files
1504   --disable-float4-byval  disable float4 passed by value
1505   --disable-float8-byval  disable float8 passed by value
1506
1507 Optional Packages:
1508   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1509   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1510   --with-template=NAME    override operating system template
1511   --with-includes=DIRS    look for additional header files in DIRS
1512   --with-libraries=DIRS   look for additional libraries in DIRS
1513   --with-libs=DIRS        alternative spelling of --with-libraries
1514   --with-pgport=PORTNUM   set default port number [5432]
1515   --with-blocksize=BLOCKSIZE
1516                           set table block size in kB [8]
1517   --with-segsize=SEGSIZE  set table segment size in GB [1]
1518   --with-wal-blocksize=BLOCKSIZE
1519                           set WAL block size in kB [8]
1520   --with-wal-segsize=SEGSIZE
1521                           set WAL segment size in MB [16]
1522   --with-CC=CMD           set compiler (deprecated)
1523   --with-tcl              build Tcl modules (PL/Tcl)
1524   --with-tclconfig=DIR    tclConfig.sh is in DIR
1525   --with-perl             build Perl modules (PL/Perl)
1526   --with-python           build Python modules (PL/Python)
1527   --with-gssapi           build with GSSAPI support
1528   --with-krb5             build with Kerberos 5 support
1529   --with-krb-srvnam=NAME  default service principal name in Kerberos
1530                           [postgres]
1531   --with-pam              build with PAM support
1532   --with-ldap             build with LDAP support
1533   --with-bonjour          build with Bonjour support
1534   --with-openssl          build with OpenSSL support
1535   --with-selinux          build with SELinux 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        build contrib/uuid-ossp, requires OSSP UUID library
1540   --with-libxml           build with XML support
1541   --with-libxslt          use XSLT support when building contrib/xml2
1542   --with-system-tzdata=DIR
1543                           use system time zone data in DIR
1544   --without-zlib          do not use Zlib
1545   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1546
1547 Some influential environment variables:
1548   CC          C compiler command
1549   CFLAGS      C compiler flags
1550   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1551               nonstandard directory <lib dir>
1552   LIBS        libraries to pass to the linker, e.g. -l<library>
1553   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1554               you have headers in a nonstandard directory <include dir>
1555   CPP         C preprocessor
1556   LDFLAGS_EX  extra linker flags for linking executables only
1557   LDFLAGS_SL  extra linker flags for linking shared libraries only
1558   DOCBOOKSTYLE
1559               location of DocBook stylesheets
1560
1561 Use these variables to override the choices made by `configure' or to help
1562 it to find libraries and programs with nonstandard names/locations.
1563
1564 Report bugs to <pgsql-bugs@postgresql.org>.
1565 _ACEOF
1566 ac_status=$?
1567 fi
1568
1569 if test "$ac_init_help" = "recursive"; then
1570   # If there are subdirs, report their specific --help.
1571   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1572     test -d "$ac_dir" ||
1573       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1574       continue
1575     ac_builddir=.
1576
1577 case "$ac_dir" in
1578 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1579 *)
1580   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1581   # A ".." for each directory in $ac_dir_suffix.
1582   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1583   case $ac_top_builddir_sub in
1584   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1585   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1586   esac ;;
1587 esac
1588 ac_abs_top_builddir=$ac_pwd
1589 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1590 # for backward compatibility:
1591 ac_top_builddir=$ac_top_build_prefix
1592
1593 case $srcdir in
1594   .)  # We are building in place.
1595     ac_srcdir=.
1596     ac_top_srcdir=$ac_top_builddir_sub
1597     ac_abs_top_srcdir=$ac_pwd ;;
1598   [\\/]* | ?:[\\/]* )  # Absolute name.
1599     ac_srcdir=$srcdir$ac_dir_suffix;
1600     ac_top_srcdir=$srcdir
1601     ac_abs_top_srcdir=$srcdir ;;
1602   *) # Relative name.
1603     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1604     ac_top_srcdir=$ac_top_build_prefix$srcdir
1605     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1606 esac
1607 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1608
1609     cd "$ac_dir" || { ac_status=$?; continue; }
1610     # Check for guested configure.
1611     if test -f "$ac_srcdir/configure.gnu"; then
1612       echo &&
1613       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1614     elif test -f "$ac_srcdir/configure"; then
1615       echo &&
1616       $SHELL "$ac_srcdir/configure" --help=recursive
1617     else
1618       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1619     fi || ac_status=$?
1620     cd "$ac_pwd" || { ac_status=$?; break; }
1621   done
1622 fi
1623
1624 test -n "$ac_init_help" && exit $ac_status
1625 if $ac_init_version; then
1626   cat <<\_ACEOF
1627 PostgreSQL configure 9.4devel
1628 generated by GNU Autoconf 2.63
1629
1630 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1631 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1632 This configure script is free software; the Free Software Foundation
1633 gives unlimited permission to copy, distribute and modify it.
1634
1635 Copyright (c) 1996-2013, PostgreSQL Global Development Group
1636 _ACEOF
1637   exit
1638 fi
1639 cat >config.log <<_ACEOF
1640 This file contains any messages produced by compilers while
1641 running configure, to aid debugging if configure makes a mistake.
1642
1643 It was created by PostgreSQL $as_me 9.4devel, which was
1644 generated by GNU Autoconf 2.63.  Invocation command line was
1645
1646   $ $0 $@
1647
1648 _ACEOF
1649 exec 5>>config.log
1650 {
1651 cat <<_ASUNAME
1652 ## --------- ##
1653 ## Platform. ##
1654 ## --------- ##
1655
1656 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1657 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1658 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1659 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1660 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1661
1662 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1663 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1664
1665 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1666 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1667 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1668 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1669 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1670 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1671 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1672
1673 _ASUNAME
1674
1675 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1676 for as_dir in $PATH
1677 do
1678   IFS=$as_save_IFS
1679   test -z "$as_dir" && as_dir=.
1680   $as_echo "PATH: $as_dir"
1681 done
1682 IFS=$as_save_IFS
1683
1684 } >&5
1685
1686 cat >&5 <<_ACEOF
1687
1688
1689 ## ----------- ##
1690 ## Core tests. ##
1691 ## ----------- ##
1692
1693 _ACEOF
1694
1695
1696 # Keep a trace of the command line.
1697 # Strip out --no-create and --no-recursion so they do not pile up.
1698 # Strip out --silent because we don't want to record it for future runs.
1699 # Also quote any args containing shell meta-characters.
1700 # Make two passes to allow for proper duplicate-argument suppression.
1701 ac_configure_args=
1702 ac_configure_args0=
1703 ac_configure_args1=
1704 ac_must_keep_next=false
1705 for ac_pass in 1 2
1706 do
1707   for ac_arg
1708   do
1709     case $ac_arg in
1710     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1711     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1712     | -silent | --silent | --silen | --sile | --sil)
1713       continue ;;
1714     *\'*)
1715       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1716     esac
1717     case $ac_pass in
1718     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1719     2)
1720       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1721       if test $ac_must_keep_next = true; then
1722         ac_must_keep_next=false # Got value, back to normal.
1723       else
1724         case $ac_arg in
1725           *=* | --config-cache | -C | -disable-* | --disable-* \
1726           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1727           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1728           | -with-* | --with-* | -without-* | --without-* | --x)
1729             case "$ac_configure_args0 " in
1730               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1731             esac
1732             ;;
1733           -* ) ac_must_keep_next=true ;;
1734         esac
1735       fi
1736       ac_configure_args="$ac_configure_args '$ac_arg'"
1737       ;;
1738     esac
1739   done
1740 done
1741 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1742 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1743
1744 # When interrupted or exit'd, cleanup temporary files, and complete
1745 # config.log.  We remove comments because anyway the quotes in there
1746 # would cause problems or look ugly.
1747 # WARNING: Use '\'' to represent an apostrophe within the trap.
1748 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1749 trap 'exit_status=$?
1750   # Save into config.log some information that might help in debugging.
1751   {
1752     echo
1753
1754     cat <<\_ASBOX
1755 ## ---------------- ##
1756 ## Cache variables. ##
1757 ## ---------------- ##
1758 _ASBOX
1759     echo
1760     # The following way of writing the cache mishandles newlines in values,
1761 (
1762   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1763     eval ac_val=\$$ac_var
1764     case $ac_val in #(
1765     *${as_nl}*)
1766       case $ac_var in #(
1767       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1768 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1769       esac
1770       case $ac_var in #(
1771       _ | IFS | as_nl) ;; #(
1772       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1773       *) $as_unset $ac_var ;;
1774       esac ;;
1775     esac
1776   done
1777   (set) 2>&1 |
1778     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1779     *${as_nl}ac_space=\ *)
1780       sed -n \
1781         "s/'\''/'\''\\\\'\'''\''/g;
1782           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1783       ;; #(
1784     *)
1785       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1786       ;;
1787     esac |
1788     sort
1789 )
1790     echo
1791
1792     cat <<\_ASBOX
1793 ## ----------------- ##
1794 ## Output variables. ##
1795 ## ----------------- ##
1796 _ASBOX
1797     echo
1798     for ac_var in $ac_subst_vars
1799     do
1800       eval ac_val=\$$ac_var
1801       case $ac_val in
1802       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1803       esac
1804       $as_echo "$ac_var='\''$ac_val'\''"
1805     done | sort
1806     echo
1807
1808     if test -n "$ac_subst_files"; then
1809       cat <<\_ASBOX
1810 ## ------------------- ##
1811 ## File substitutions. ##
1812 ## ------------------- ##
1813 _ASBOX
1814       echo
1815       for ac_var in $ac_subst_files
1816       do
1817         eval ac_val=\$$ac_var
1818         case $ac_val in
1819         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1820         esac
1821         $as_echo "$ac_var='\''$ac_val'\''"
1822       done | sort
1823       echo
1824     fi
1825
1826     if test -s confdefs.h; then
1827       cat <<\_ASBOX
1828 ## ----------- ##
1829 ## confdefs.h. ##
1830 ## ----------- ##
1831 _ASBOX
1832       echo
1833       cat confdefs.h
1834       echo
1835     fi
1836     test "$ac_signal" != 0 &&
1837       $as_echo "$as_me: caught signal $ac_signal"
1838     $as_echo "$as_me: exit $exit_status"
1839   } >&5
1840   rm -f core *.core core.conftest.* &&
1841     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1842     exit $exit_status
1843 ' 0
1844 for ac_signal in 1 2 13 15; do
1845   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1846 done
1847 ac_signal=0
1848
1849 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1850 rm -f -r conftest* confdefs.h
1851
1852 # Predefined preprocessor variables.
1853
1854 cat >>confdefs.h <<_ACEOF
1855 #define PACKAGE_NAME "$PACKAGE_NAME"
1856 _ACEOF
1857
1858
1859 cat >>confdefs.h <<_ACEOF
1860 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1861 _ACEOF
1862
1863
1864 cat >>confdefs.h <<_ACEOF
1865 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1866 _ACEOF
1867
1868
1869 cat >>confdefs.h <<_ACEOF
1870 #define PACKAGE_STRING "$PACKAGE_STRING"
1871 _ACEOF
1872
1873
1874 cat >>confdefs.h <<_ACEOF
1875 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1876 _ACEOF
1877
1878
1879 # Let the site file select an alternate cache file if it wants to.
1880 # Prefer an explicitly selected file to automatically selected ones.
1881 ac_site_file1=NONE
1882 ac_site_file2=NONE
1883 if test -n "$CONFIG_SITE"; then
1884   ac_site_file1=$CONFIG_SITE
1885 elif test "x$prefix" != xNONE; then
1886   ac_site_file1=$prefix/share/config.site
1887   ac_site_file2=$prefix/etc/config.site
1888 else
1889   ac_site_file1=$ac_default_prefix/share/config.site
1890   ac_site_file2=$ac_default_prefix/etc/config.site
1891 fi
1892 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1893 do
1894   test "x$ac_site_file" = xNONE && continue
1895   if test -r "$ac_site_file"; then
1896     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1897 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1898     sed 's/^/| /' "$ac_site_file" >&5
1899     . "$ac_site_file"
1900   fi
1901 done
1902
1903 if test -r "$cache_file"; then
1904   # Some versions of bash will fail to source /dev/null (special
1905   # files actually), so we avoid doing that.
1906   if test -f "$cache_file"; then
1907     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1908 $as_echo "$as_me: loading cache $cache_file" >&6;}
1909     case $cache_file in
1910       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1911       *)                      . "./$cache_file";;
1912     esac
1913   fi
1914 else
1915   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1916 $as_echo "$as_me: creating cache $cache_file" >&6;}
1917   >$cache_file
1918 fi
1919
1920 # Check that the precious variables saved in the cache have kept the same
1921 # value.
1922 ac_cache_corrupted=false
1923 for ac_var in $ac_precious_vars; do
1924   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1925   eval ac_new_set=\$ac_env_${ac_var}_set
1926   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1927   eval ac_new_val=\$ac_env_${ac_var}_value
1928   case $ac_old_set,$ac_new_set in
1929     set,)
1930       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1931 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1932       ac_cache_corrupted=: ;;
1933     ,set)
1934       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1935 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1936       ac_cache_corrupted=: ;;
1937     ,);;
1938     *)
1939       if test "x$ac_old_val" != "x$ac_new_val"; then
1940         # differences in whitespace do not lead to failure.
1941         ac_old_val_w=`echo x $ac_old_val`
1942         ac_new_val_w=`echo x $ac_new_val`
1943         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1944           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1945 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1946           ac_cache_corrupted=:
1947         else
1948           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1949 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1950           eval $ac_var=\$ac_old_val
1951         fi
1952         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1953 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1954         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1955 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1956       fi;;
1957   esac
1958   # Pass precious variables to config.status.
1959   if test "$ac_new_set" = set; then
1960     case $ac_new_val in
1961     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1962     *) ac_arg=$ac_var=$ac_new_val ;;
1963     esac
1964     case " $ac_configure_args " in
1965       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1966       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1967     esac
1968   fi
1969 done
1970 if $ac_cache_corrupted; then
1971   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1972 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1973   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1974 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1975   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1976 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1977    { (exit 1); exit 1; }; }
1978 fi
1979
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 ac_ext=c
2005 ac_cpp='$CPP $CPPFLAGS'
2006 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2007 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2008 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2009
2010
2011
2012
2013
2014
2015 ac_aux_dir=
2016 for ac_dir in config "$srcdir"/config; do
2017   if test -f "$ac_dir/install-sh"; then
2018     ac_aux_dir=$ac_dir
2019     ac_install_sh="$ac_aux_dir/install-sh -c"
2020     break
2021   elif test -f "$ac_dir/install.sh"; then
2022     ac_aux_dir=$ac_dir
2023     ac_install_sh="$ac_aux_dir/install.sh -c"
2024     break
2025   elif test -f "$ac_dir/shtool"; then
2026     ac_aux_dir=$ac_dir
2027     ac_install_sh="$ac_aux_dir/shtool install -c"
2028     break
2029   fi
2030 done
2031 if test -z "$ac_aux_dir"; then
2032   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2033 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2034    { (exit 1); exit 1; }; }
2035 fi
2036
2037 # These three variables are undocumented and unsupported,
2038 # and are intended to be withdrawn in a future Autoconf release.
2039 # They can cause serious problems if a builder's source tree is in a directory
2040 # whose full name contains unusual characters.
2041 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2042 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2043 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2044
2045
2046
2047 configure_args=$ac_configure_args
2048
2049
2050
2051 cat >>confdefs.h <<_ACEOF
2052 #define PG_VERSION "$PACKAGE_VERSION"
2053 _ACEOF
2054
2055 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2056
2057
2058 cat >>confdefs.h <<_ACEOF
2059 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2060 _ACEOF
2061
2062
2063 # Make sure we can run config.sub.
2064 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2065   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2066 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2067    { (exit 1); exit 1; }; }
2068
2069 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2070 $as_echo_n "checking build system type... " >&6; }
2071 if test "${ac_cv_build+set}" = set; then
2072   $as_echo_n "(cached) " >&6
2073 else
2074   ac_build_alias=$build_alias
2075 test "x$ac_build_alias" = x &&
2076   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2077 test "x$ac_build_alias" = x &&
2078   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2079 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2080    { (exit 1); exit 1; }; }
2081 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2082   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2083 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2084    { (exit 1); exit 1; }; }
2085
2086 fi
2087 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2088 $as_echo "$ac_cv_build" >&6; }
2089 case $ac_cv_build in
2090 *-*-*) ;;
2091 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2092 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2093    { (exit 1); exit 1; }; };;
2094 esac
2095 build=$ac_cv_build
2096 ac_save_IFS=$IFS; IFS='-'
2097 set x $ac_cv_build
2098 shift
2099 build_cpu=$1
2100 build_vendor=$2
2101 shift; shift
2102 # Remember, the first character of IFS is used to create $*,
2103 # except with old shells:
2104 build_os=$*
2105 IFS=$ac_save_IFS
2106 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2107
2108
2109 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2110 $as_echo_n "checking host system type... " >&6; }
2111 if test "${ac_cv_host+set}" = set; then
2112   $as_echo_n "(cached) " >&6
2113 else
2114   if test "x$host_alias" = x; then
2115   ac_cv_host=$ac_cv_build
2116 else
2117   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2118     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2119 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2120    { (exit 1); exit 1; }; }
2121 fi
2122
2123 fi
2124 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2125 $as_echo "$ac_cv_host" >&6; }
2126 case $ac_cv_host in
2127 *-*-*) ;;
2128 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2129 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2130    { (exit 1); exit 1; }; };;
2131 esac
2132 host=$ac_cv_host
2133 ac_save_IFS=$IFS; IFS='-'
2134 set x $ac_cv_host
2135 shift
2136 host_cpu=$1
2137 host_vendor=$2
2138 shift; shift
2139 # Remember, the first character of IFS is used to create $*,
2140 # except with old shells:
2141 host_os=$*
2142 IFS=$ac_save_IFS
2143 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2144
2145
2146
2147 template=
2148 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2149 $as_echo_n "checking which template to use... " >&6; }
2150
2151
2152
2153
2154 # Check whether --with-template was given.
2155 if test "${with_template+set}" = set; then
2156   withval=$with_template;
2157   case $withval in
2158     yes)
2159       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2160 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2161    { (exit 1); exit 1; }; }
2162       ;;
2163     no)
2164       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2165 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2166    { (exit 1); exit 1; }; }
2167       ;;
2168     *)
2169
2170   case $withval in
2171     list)   echo; ls "$srcdir/src/template"; exit;;
2172     *)      if test -f "$srcdir/src/template/$with_template" ; then
2173               template=$withval
2174             else
2175               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2176 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2177    { (exit 1); exit 1; }; }
2178             fi;;
2179   esac
2180
2181       ;;
2182   esac
2183
2184 else
2185
2186 # --with-template not given
2187
2188 case $host_os in
2189      aix*) template=aix ;;
2190   cygwin*) template=cygwin ;;
2191   darwin*) template=darwin ;;
2192 dragonfly*) template=netbsd ;;
2193  freebsd*) template=freebsd ;;
2194     hpux*) template=hpux ;;
2195  linux*|gnu*|k*bsd*-gnu)
2196            template=linux ;;
2197    mingw*) template=win32 ;;
2198   netbsd*) template=netbsd ;;
2199  openbsd*) template=openbsd ;;
2200      osf*) template=osf ;;
2201      sco*) template=sco ;;
2202  solaris*) template=solaris ;;
2203    sysv5*) template=unixware ;;
2204 esac
2205
2206   if test x"$template" = x"" ; then
2207     { { $as_echo "$as_me:$LINENO: error:
2208 *******************************************************************
2209 PostgreSQL has apparently not been ported to your platform yet.
2210 To try a manual configuration, look into the src/template directory
2211 for a similar platform and use the '--with-template=' option.
2212
2213 Please also contact <pgsql-bugs@postgresql.org> to see about
2214 rectifying this.  Include the above 'checking host system type...'
2215 line.
2216 *******************************************************************
2217 " >&5
2218 $as_echo "$as_me: 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 " >&2;}
2229    { (exit 1); exit 1; }; }
2230   fi
2231
2232
2233 fi
2234
2235
2236
2237 { $as_echo "$as_me:$LINENO: result: $template" >&5
2238 $as_echo "$template" >&6; }
2239
2240 PORTNAME=$template
2241
2242
2243 # Initialize default assumption that we do not need separate assembly code
2244 # for TAS (test-and-set).  This can be overridden by the template file
2245 # when it's executed.
2246 need_tas=no
2247 tas_file=dummy.s
2248
2249
2250
2251 ##
2252 ## Command line options
2253 ##
2254
2255 #
2256 # Add non-standard directories to the include path
2257 #
2258
2259
2260
2261 # Check whether --with-includes was given.
2262 if test "${with_includes+set}" = set; then
2263   withval=$with_includes;
2264   case $withval in
2265     yes)
2266       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2267 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2268    { (exit 1); exit 1; }; }
2269       ;;
2270     no)
2271       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2272 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2273    { (exit 1); exit 1; }; }
2274       ;;
2275     *)
2276
2277       ;;
2278   esac
2279
2280 fi
2281
2282
2283
2284
2285 #
2286 # Add non-standard directories to the library search path
2287 #
2288
2289
2290
2291 # Check whether --with-libraries was given.
2292 if test "${with_libraries+set}" = set; then
2293   withval=$with_libraries;
2294   case $withval in
2295     yes)
2296       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2297 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2298    { (exit 1); exit 1; }; }
2299       ;;
2300     no)
2301       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2302 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2303    { (exit 1); exit 1; }; }
2304       ;;
2305     *)
2306       LIBRARY_DIRS=$withval
2307       ;;
2308   esac
2309
2310 fi
2311
2312
2313
2314
2315
2316
2317 # Check whether --with-libs was given.
2318 if test "${with_libs+set}" = set; then
2319   withval=$with_libs;
2320   case $withval in
2321     yes)
2322       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2323 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2324    { (exit 1); exit 1; }; }
2325       ;;
2326     no)
2327       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2328 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2329    { (exit 1); exit 1; }; }
2330       ;;
2331     *)
2332       LIBRARY_DIRS=$withval
2333       ;;
2334   esac
2335
2336 fi
2337
2338
2339
2340
2341 #
2342 # 64-bit integer date/time storage: enabled by default.
2343 #
2344 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2345 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2346
2347
2348 # Check whether --enable-integer-datetimes was given.
2349 if test "${enable_integer_datetimes+set}" = set; then
2350   enableval=$enable_integer_datetimes;
2351   case $enableval in
2352     yes)
2353
2354 cat >>confdefs.h <<\_ACEOF
2355 #define USE_INTEGER_DATETIMES 1
2356 _ACEOF
2357
2358       ;;
2359     no)
2360       :
2361       ;;
2362     *)
2363       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2364 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2365    { (exit 1); exit 1; }; }
2366       ;;
2367   esac
2368
2369 else
2370   enable_integer_datetimes=yes
2371
2372 cat >>confdefs.h <<\_ACEOF
2373 #define USE_INTEGER_DATETIMES 1
2374 _ACEOF
2375
2376 fi
2377
2378
2379 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2380 $as_echo "$enable_integer_datetimes" >&6; }
2381
2382
2383 #
2384 # NLS
2385 #
2386 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2387 $as_echo_n "checking whether NLS is wanted... " >&6; }
2388
2389
2390 # Check whether --enable-nls was given.
2391 if test "${enable_nls+set}" = set; then
2392   enableval=$enable_nls;
2393   case $enableval in
2394     yes)
2395       :
2396       ;;
2397     no)
2398       :
2399       ;;
2400     *)
2401       enable_nls=yes
2402 WANTED_LANGUAGES=$enableval
2403       ;;
2404   esac
2405
2406 else
2407   enable_nls=no
2408 fi
2409
2410
2411
2412 if test "$enable_nls" = yes; then
2413
2414 cat >>confdefs.h <<\_ACEOF
2415 #define ENABLE_NLS 1
2416 _ACEOF
2417
2418 fi
2419
2420 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2421 $as_echo "$enable_nls" >&6; }
2422
2423
2424
2425 #
2426 # Default port number (--with-pgport), default 5432
2427 #
2428 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2429 $as_echo_n "checking for default port number... " >&6; }
2430
2431
2432
2433 # Check whether --with-pgport was given.
2434 if test "${with_pgport+set}" = set; then
2435   withval=$with_pgport;
2436   case $withval in
2437     yes)
2438       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2439 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2440    { (exit 1); exit 1; }; }
2441       ;;
2442     no)
2443       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2444 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2445    { (exit 1); exit 1; }; }
2446       ;;
2447     *)
2448       default_port=$withval
2449       ;;
2450   esac
2451
2452 else
2453   default_port=5432
2454 fi
2455
2456
2457 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2458 $as_echo "$default_port" >&6; }
2459 # Need both of these because some places want an integer and some a string
2460
2461 cat >>confdefs.h <<_ACEOF
2462 #define DEF_PGPORT ${default_port}
2463 _ACEOF
2464
2465
2466 cat >>confdefs.h <<_ACEOF
2467 #define DEF_PGPORT_STR "${default_port}"
2468 _ACEOF
2469
2470
2471
2472 #
2473 # '-rpath'-like feature can be disabled
2474 #
2475
2476
2477 # Check whether --enable-rpath was given.
2478 if test "${enable_rpath+set}" = set; then
2479   enableval=$enable_rpath;
2480   case $enableval in
2481     yes)
2482       :
2483       ;;
2484     no)
2485       :
2486       ;;
2487     *)
2488       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2489 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2490    { (exit 1); exit 1; }; }
2491       ;;
2492   esac
2493
2494 else
2495   enable_rpath=yes
2496
2497 fi
2498
2499
2500
2501
2502 #
2503 # Spinlocks
2504 #
2505
2506
2507 # Check whether --enable-spinlocks was given.
2508 if test "${enable_spinlocks+set}" = set; then
2509   enableval=$enable_spinlocks;
2510   case $enableval in
2511     yes)
2512       :
2513       ;;
2514     no)
2515       :
2516       ;;
2517     *)
2518       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2519 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2520    { (exit 1); exit 1; }; }
2521       ;;
2522   esac
2523
2524 else
2525   enable_spinlocks=yes
2526
2527 fi
2528
2529
2530
2531 #
2532 # --enable-debug adds -g to compiler flags
2533 #
2534
2535
2536 # Check whether --enable-debug was given.
2537 if test "${enable_debug+set}" = set; then
2538   enableval=$enable_debug;
2539   case $enableval in
2540     yes)
2541       :
2542       ;;
2543     no)
2544       :
2545       ;;
2546     *)
2547       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2548 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2549    { (exit 1); exit 1; }; }
2550       ;;
2551   esac
2552
2553 else
2554   enable_debug=no
2555
2556 fi
2557
2558
2559
2560
2561 #
2562 # --enable-profiling enables gcc profiling
2563 #
2564
2565
2566 # Check whether --enable-profiling was given.
2567 if test "${enable_profiling+set}" = set; then
2568   enableval=$enable_profiling;
2569   case $enableval in
2570     yes)
2571       :
2572       ;;
2573     no)
2574       :
2575       ;;
2576     *)
2577       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2578 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2579    { (exit 1); exit 1; }; }
2580       ;;
2581   esac
2582
2583 else
2584   enable_profiling=no
2585
2586 fi
2587
2588
2589
2590 #
2591 # --enable-coverage enables generation of code coverage metrics with gcov
2592 #
2593
2594
2595 # Check whether --enable-coverage was given.
2596 if test "${enable_coverage+set}" = set; then
2597   enableval=$enable_coverage;
2598   case $enableval in
2599     yes)
2600       for ac_prog in gcov
2601 do
2602   # Extract the first word of "$ac_prog", so it can be a program name with args.
2603 set dummy $ac_prog; ac_word=$2
2604 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2605 $as_echo_n "checking for $ac_word... " >&6; }
2606 if test "${ac_cv_prog_GCOV+set}" = set; then
2607   $as_echo_n "(cached) " >&6
2608 else
2609   if test -n "$GCOV"; then
2610   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2611 else
2612 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2613 for as_dir in $PATH
2614 do
2615   IFS=$as_save_IFS
2616   test -z "$as_dir" && as_dir=.
2617   for ac_exec_ext in '' $ac_executable_extensions; do
2618   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2619     ac_cv_prog_GCOV="$ac_prog"
2620     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2621     break 2
2622   fi
2623 done
2624 done
2625 IFS=$as_save_IFS
2626
2627 fi
2628 fi
2629 GCOV=$ac_cv_prog_GCOV
2630 if test -n "$GCOV"; then
2631   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2632 $as_echo "$GCOV" >&6; }
2633 else
2634   { $as_echo "$as_me:$LINENO: result: no" >&5
2635 $as_echo "no" >&6; }
2636 fi
2637
2638
2639   test -n "$GCOV" && break
2640 done
2641
2642 if test -z "$GCOV"; then
2643   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2644 $as_echo "$as_me: error: gcov not found" >&2;}
2645    { (exit 1); exit 1; }; }
2646 fi
2647 for ac_prog in lcov
2648 do
2649   # Extract the first word of "$ac_prog", so it can be a program name with args.
2650 set dummy $ac_prog; ac_word=$2
2651 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2652 $as_echo_n "checking for $ac_word... " >&6; }
2653 if test "${ac_cv_prog_LCOV+set}" = set; then
2654   $as_echo_n "(cached) " >&6
2655 else
2656   if test -n "$LCOV"; then
2657   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2658 else
2659 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2660 for as_dir in $PATH
2661 do
2662   IFS=$as_save_IFS
2663   test -z "$as_dir" && as_dir=.
2664   for ac_exec_ext in '' $ac_executable_extensions; do
2665   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2666     ac_cv_prog_LCOV="$ac_prog"
2667     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2668     break 2
2669   fi
2670 done
2671 done
2672 IFS=$as_save_IFS
2673
2674 fi
2675 fi
2676 LCOV=$ac_cv_prog_LCOV
2677 if test -n "$LCOV"; then
2678   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2679 $as_echo "$LCOV" >&6; }
2680 else
2681   { $as_echo "$as_me:$LINENO: result: no" >&5
2682 $as_echo "no" >&6; }
2683 fi
2684
2685
2686   test -n "$LCOV" && break
2687 done
2688
2689 if test -z "$LCOV"; then
2690   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2691 $as_echo "$as_me: error: lcov not found" >&2;}
2692    { (exit 1); exit 1; }; }
2693 fi
2694 for ac_prog in genhtml
2695 do
2696   # Extract the first word of "$ac_prog", so it can be a program name with args.
2697 set dummy $ac_prog; ac_word=$2
2698 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2699 $as_echo_n "checking for $ac_word... " >&6; }
2700 if test "${ac_cv_prog_GENHTML+set}" = set; then
2701   $as_echo_n "(cached) " >&6
2702 else
2703   if test -n "$GENHTML"; then
2704   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2705 else
2706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2707 for as_dir in $PATH
2708 do
2709   IFS=$as_save_IFS
2710   test -z "$as_dir" && as_dir=.
2711   for ac_exec_ext in '' $ac_executable_extensions; do
2712   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2713     ac_cv_prog_GENHTML="$ac_prog"
2714     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2715     break 2
2716   fi
2717 done
2718 done
2719 IFS=$as_save_IFS
2720
2721 fi
2722 fi
2723 GENHTML=$ac_cv_prog_GENHTML
2724 if test -n "$GENHTML"; then
2725   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2726 $as_echo "$GENHTML" >&6; }
2727 else
2728   { $as_echo "$as_me:$LINENO: result: no" >&5
2729 $as_echo "no" >&6; }
2730 fi
2731
2732
2733   test -n "$GENHTML" && break
2734 done
2735
2736 if test -z "$GENHTML"; then
2737   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2738 $as_echo "$as_me: error: genhtml not found" >&2;}
2739    { (exit 1); exit 1; }; }
2740 fi
2741       ;;
2742     no)
2743       :
2744       ;;
2745     *)
2746       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2747 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2748    { (exit 1); exit 1; }; }
2749       ;;
2750   esac
2751
2752 else
2753   enable_coverage=no
2754
2755 fi
2756
2757
2758
2759
2760 #
2761 # DTrace
2762 #
2763
2764
2765 # Check whether --enable-dtrace was given.
2766 if test "${enable_dtrace+set}" = set; then
2767   enableval=$enable_dtrace;
2768   case $enableval in
2769     yes)
2770       for ac_prog in dtrace
2771 do
2772   # Extract the first word of "$ac_prog", so it can be a program name with args.
2773 set dummy $ac_prog; ac_word=$2
2774 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2775 $as_echo_n "checking for $ac_word... " >&6; }
2776 if test "${ac_cv_prog_DTRACE+set}" = set; then
2777   $as_echo_n "(cached) " >&6
2778 else
2779   if test -n "$DTRACE"; then
2780   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2781 else
2782 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2783 for as_dir in $PATH
2784 do
2785   IFS=$as_save_IFS
2786   test -z "$as_dir" && as_dir=.
2787   for ac_exec_ext in '' $ac_executable_extensions; do
2788   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2789     ac_cv_prog_DTRACE="$ac_prog"
2790     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2791     break 2
2792   fi
2793 done
2794 done
2795 IFS=$as_save_IFS
2796
2797 fi
2798 fi
2799 DTRACE=$ac_cv_prog_DTRACE
2800 if test -n "$DTRACE"; then
2801   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2802 $as_echo "$DTRACE" >&6; }
2803 else
2804   { $as_echo "$as_me:$LINENO: result: no" >&5
2805 $as_echo "no" >&6; }
2806 fi
2807
2808
2809   test -n "$DTRACE" && break
2810 done
2811
2812 if test -z "$DTRACE"; then
2813   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2814 $as_echo "$as_me: error: dtrace not found" >&2;}
2815    { (exit 1); exit 1; }; }
2816 fi
2817
2818       ;;
2819     no)
2820       :
2821       ;;
2822     *)
2823       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2824 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2825    { (exit 1); exit 1; }; }
2826       ;;
2827   esac
2828
2829 else
2830   enable_dtrace=no
2831
2832 fi
2833
2834
2835
2836
2837 #
2838 # Block size
2839 #
2840 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2841 $as_echo_n "checking for block size... " >&6; }
2842
2843
2844
2845 # Check whether --with-blocksize was given.
2846 if test "${with_blocksize+set}" = set; then
2847   withval=$with_blocksize;
2848   case $withval in
2849     yes)
2850       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2851 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2852    { (exit 1); exit 1; }; }
2853       ;;
2854     no)
2855       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2856 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2857    { (exit 1); exit 1; }; }
2858       ;;
2859     *)
2860       blocksize=$withval
2861       ;;
2862   esac
2863
2864 else
2865   blocksize=8
2866 fi
2867
2868
2869 case ${blocksize} in
2870   1) BLCKSZ=1024;;
2871   2) BLCKSZ=2048;;
2872   4) BLCKSZ=4096;;
2873   8) BLCKSZ=8192;;
2874  16) BLCKSZ=16384;;
2875  32) BLCKSZ=32768;;
2876   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2877 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2878    { (exit 1); exit 1; }; }
2879 esac
2880 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2881 $as_echo "${blocksize}kB" >&6; }
2882
2883
2884 cat >>confdefs.h <<_ACEOF
2885 #define BLCKSZ ${BLCKSZ}
2886 _ACEOF
2887
2888
2889 #
2890 # Relation segment size
2891 #
2892 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2893 $as_echo_n "checking for segment size... " >&6; }
2894
2895
2896
2897 # Check whether --with-segsize was given.
2898 if test "${with_segsize+set}" = set; then
2899   withval=$with_segsize;
2900   case $withval in
2901     yes)
2902       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2903 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2904    { (exit 1); exit 1; }; }
2905       ;;
2906     no)
2907       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2908 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2909    { (exit 1); exit 1; }; }
2910       ;;
2911     *)
2912       segsize=$withval
2913       ;;
2914   esac
2915
2916 else
2917   segsize=1
2918 fi
2919
2920
2921 # this expression is set up to avoid unnecessary integer overflow
2922 # blocksize is already guaranteed to be a factor of 1024
2923 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2924 test $? -eq 0 || exit 1
2925 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2926 $as_echo "${segsize}GB" >&6; }
2927
2928
2929 cat >>confdefs.h <<_ACEOF
2930 #define RELSEG_SIZE ${RELSEG_SIZE}
2931 _ACEOF
2932
2933
2934 #
2935 # WAL block size
2936 #
2937 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2938 $as_echo_n "checking for WAL block size... " >&6; }
2939
2940
2941
2942 # Check whether --with-wal-blocksize was given.
2943 if test "${with_wal_blocksize+set}" = set; then
2944   withval=$with_wal_blocksize;
2945   case $withval in
2946     yes)
2947       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2948 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2949    { (exit 1); exit 1; }; }
2950       ;;
2951     no)
2952       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2953 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2954    { (exit 1); exit 1; }; }
2955       ;;
2956     *)
2957       wal_blocksize=$withval
2958       ;;
2959   esac
2960
2961 else
2962   wal_blocksize=8
2963 fi
2964
2965
2966 case ${wal_blocksize} in
2967   1) XLOG_BLCKSZ=1024;;
2968   2) XLOG_BLCKSZ=2048;;
2969   4) XLOG_BLCKSZ=4096;;
2970   8) XLOG_BLCKSZ=8192;;
2971  16) XLOG_BLCKSZ=16384;;
2972  32) XLOG_BLCKSZ=32768;;
2973  64) XLOG_BLCKSZ=65536;;
2974   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
2975 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
2976    { (exit 1); exit 1; }; }
2977 esac
2978 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
2979 $as_echo "${wal_blocksize}kB" >&6; }
2980
2981
2982 cat >>confdefs.h <<_ACEOF
2983 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
2984 _ACEOF
2985
2986
2987 #
2988 # WAL segment size
2989 #
2990 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
2991 $as_echo_n "checking for WAL segment size... " >&6; }
2992
2993
2994
2995 # Check whether --with-wal-segsize was given.
2996 if test "${with_wal_segsize+set}" = set; then
2997   withval=$with_wal_segsize;
2998   case $withval in
2999     yes)
3000       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3001 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3002    { (exit 1); exit 1; }; }
3003       ;;
3004     no)
3005       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3006 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3007    { (exit 1); exit 1; }; }
3008       ;;
3009     *)
3010       wal_segsize=$withval
3011       ;;
3012   esac
3013
3014 else
3015   wal_segsize=16
3016 fi
3017
3018
3019 case ${wal_segsize} in
3020   1) ;;
3021   2) ;;
3022   4) ;;
3023   8) ;;
3024  16) ;;
3025  32) ;;
3026  64) ;;
3027   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3028 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3029    { (exit 1); exit 1; }; }
3030 esac
3031 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3032 $as_echo "${wal_segsize}MB" >&6; }
3033
3034
3035 cat >>confdefs.h <<_ACEOF
3036 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3037 _ACEOF
3038
3039
3040 #
3041 # C compiler
3042 #
3043
3044 # For historical reasons you can also use --with-CC to specify the C compiler
3045 # to use, although the standard way to do this is to set the CC environment
3046 # variable.
3047
3048
3049
3050 # Check whether --with-CC was given.
3051 if test "${with_CC+set}" = set; then
3052   withval=$with_CC;
3053   case $withval in
3054     yes)
3055       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3056 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3057    { (exit 1); exit 1; }; }
3058       ;;
3059     no)
3060       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3061 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3062    { (exit 1); exit 1; }; }
3063       ;;
3064     *)
3065       CC=$with_CC
3066       ;;
3067   esac
3068
3069 fi
3070
3071
3072
3073 case $template in
3074   aix) pgac_cc_list="gcc xlc";;
3075     *) pgac_cc_list="gcc cc";;
3076 esac
3077
3078 ac_ext=c
3079 ac_cpp='$CPP $CPPFLAGS'
3080 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3081 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3082 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3083 if test -n "$ac_tool_prefix"; then
3084   for ac_prog in $pgac_cc_list
3085   do
3086     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3087 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3088 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3089 $as_echo_n "checking for $ac_word... " >&6; }
3090 if test "${ac_cv_prog_CC+set}" = set; then
3091   $as_echo_n "(cached) " >&6
3092 else
3093   if test -n "$CC"; then
3094   ac_cv_prog_CC="$CC" # Let the user override the test.
3095 else
3096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3097 for as_dir in $PATH
3098 do
3099   IFS=$as_save_IFS
3100   test -z "$as_dir" && as_dir=.
3101   for ac_exec_ext in '' $ac_executable_extensions; do
3102   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3103     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3104     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3105     break 2
3106   fi
3107 done
3108 done
3109 IFS=$as_save_IFS
3110
3111 fi
3112 fi
3113 CC=$ac_cv_prog_CC
3114 if test -n "$CC"; then
3115   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3116 $as_echo "$CC" >&6; }
3117 else
3118   { $as_echo "$as_me:$LINENO: result: no" >&5
3119 $as_echo "no" >&6; }
3120 fi
3121
3122
3123     test -n "$CC" && break
3124   done
3125 fi
3126 if test -z "$CC"; then
3127   ac_ct_CC=$CC
3128   for ac_prog in $pgac_cc_list
3129 do
3130   # Extract the first word of "$ac_prog", so it can be a program name with args.
3131 set dummy $ac_prog; ac_word=$2
3132 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3133 $as_echo_n "checking for $ac_word... " >&6; }
3134 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3135   $as_echo_n "(cached) " >&6
3136 else
3137   if test -n "$ac_ct_CC"; then
3138   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3139 else
3140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3141 for as_dir in $PATH
3142 do
3143   IFS=$as_save_IFS
3144   test -z "$as_dir" && as_dir=.
3145   for ac_exec_ext in '' $ac_executable_extensions; do
3146   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3147     ac_cv_prog_ac_ct_CC="$ac_prog"
3148     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3149     break 2
3150   fi
3151 done
3152 done
3153 IFS=$as_save_IFS
3154
3155 fi
3156 fi
3157 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3158 if test -n "$ac_ct_CC"; then
3159   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3160 $as_echo "$ac_ct_CC" >&6; }
3161 else
3162   { $as_echo "$as_me:$LINENO: result: no" >&5
3163 $as_echo "no" >&6; }
3164 fi
3165
3166
3167   test -n "$ac_ct_CC" && break
3168 done
3169
3170   if test "x$ac_ct_CC" = x; then
3171     CC=""
3172   else
3173     case $cross_compiling:$ac_tool_warned in
3174 yes:)
3175 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3176 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3177 ac_tool_warned=yes ;;
3178 esac
3179     CC=$ac_ct_CC
3180   fi
3181 fi
3182
3183
3184 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3185 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3186 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3187 See \`config.log' for more details." >&5
3188 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3189 See \`config.log' for more details." >&2;}
3190    { (exit 1); exit 1; }; }; }
3191
3192 # Provide some information about the compiler.
3193 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3194 set X $ac_compile
3195 ac_compiler=$2
3196 { (ac_try="$ac_compiler --version >&5"
3197 case "(($ac_try" in
3198   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3199   *) ac_try_echo=$ac_try;;
3200 esac
3201 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3202 $as_echo "$ac_try_echo") >&5
3203   (eval "$ac_compiler --version >&5") 2>&5
3204   ac_status=$?
3205   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3206   (exit $ac_status); }
3207 { (ac_try="$ac_compiler -v >&5"
3208 case "(($ac_try" in
3209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3210   *) ac_try_echo=$ac_try;;
3211 esac
3212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3213 $as_echo "$ac_try_echo") >&5
3214   (eval "$ac_compiler -v >&5") 2>&5
3215   ac_status=$?
3216   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3217   (exit $ac_status); }
3218 { (ac_try="$ac_compiler -V >&5"
3219 case "(($ac_try" in
3220   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3221   *) ac_try_echo=$ac_try;;
3222 esac
3223 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3224 $as_echo "$ac_try_echo") >&5
3225   (eval "$ac_compiler -V >&5") 2>&5
3226   ac_status=$?
3227   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3228   (exit $ac_status); }
3229
3230 cat >conftest.$ac_ext <<_ACEOF
3231 /* confdefs.h.  */
3232 _ACEOF
3233 cat confdefs.h >>conftest.$ac_ext
3234 cat >>conftest.$ac_ext <<_ACEOF
3235 /* end confdefs.h.  */
3236
3237 int
3238 main ()
3239 {
3240
3241   ;
3242   return 0;
3243 }
3244 _ACEOF
3245 ac_clean_files_save=$ac_clean_files
3246 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3247 # Try to create an executable without -o first, disregard a.out.
3248 # It will help us diagnose broken compilers, and finding out an intuition
3249 # of exeext.
3250 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3251 $as_echo_n "checking for C compiler default output file name... " >&6; }
3252 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3253
3254 # The possible output files:
3255 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3256
3257 ac_rmfiles=
3258 for ac_file in $ac_files
3259 do
3260   case $ac_file in
3261     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3262     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3263   esac
3264 done
3265 rm -f $ac_rmfiles
3266
3267 if { (ac_try="$ac_link_default"
3268 case "(($ac_try" in
3269   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3270   *) ac_try_echo=$ac_try;;
3271 esac
3272 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3273 $as_echo "$ac_try_echo") >&5
3274   (eval "$ac_link_default") 2>&5
3275   ac_status=$?
3276   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3277   (exit $ac_status); }; then
3278   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3279 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3280 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3281 # so that the user can short-circuit this test for compilers unknown to
3282 # Autoconf.
3283 for ac_file in $ac_files ''
3284 do
3285   test -f "$ac_file" || continue
3286   case $ac_file in
3287     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3288         ;;
3289     [ab].out )
3290         # We found the default executable, but exeext='' is most
3291         # certainly right.
3292         break;;
3293     *.* )
3294         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3295         then :; else
3296            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3297         fi
3298         # We set ac_cv_exeext here because the later test for it is not
3299         # safe: cross compilers may not add the suffix if given an `-o'
3300         # argument, so we may need to know it at that point already.
3301         # Even if this section looks crufty: it has the advantage of
3302         # actually working.
3303         break;;
3304     * )
3305         break;;
3306   esac
3307 done
3308 test "$ac_cv_exeext" = no && ac_cv_exeext=
3309
3310 else
3311   ac_file=''
3312 fi
3313
3314 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3315 $as_echo "$ac_file" >&6; }
3316 if test -z "$ac_file"; then
3317   $as_echo "$as_me: failed program was:" >&5
3318 sed 's/^/| /' conftest.$ac_ext >&5
3319
3320 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3321 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3322 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3323 See \`config.log' for more details." >&5
3324 $as_echo "$as_me: error: C compiler cannot create executables
3325 See \`config.log' for more details." >&2;}
3326    { (exit 77); exit 77; }; }; }
3327 fi
3328
3329 ac_exeext=$ac_cv_exeext
3330
3331 # Check that the compiler produces executables we can run.  If not, either
3332 # the compiler is broken, or we cross compile.
3333 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3334 $as_echo_n "checking whether the C compiler works... " >&6; }
3335 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3336 # If not cross compiling, check that we can run a simple program.
3337 if test "$cross_compiling" != yes; then
3338   if { ac_try='./$ac_file'
3339   { (case "(($ac_try" in
3340   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3341   *) ac_try_echo=$ac_try;;
3342 esac
3343 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3344 $as_echo "$ac_try_echo") >&5
3345   (eval "$ac_try") 2>&5
3346   ac_status=$?
3347   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3348   (exit $ac_status); }; }; then
3349     cross_compiling=no
3350   else
3351     if test "$cross_compiling" = maybe; then
3352         cross_compiling=yes
3353     else
3354         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3355 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3356 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3357 If you meant to cross compile, use \`--host'.
3358 See \`config.log' for more details." >&5
3359 $as_echo "$as_me: error: cannot run C compiled programs.
3360 If you meant to cross compile, use \`--host'.
3361 See \`config.log' for more details." >&2;}
3362    { (exit 1); exit 1; }; }; }
3363     fi
3364   fi
3365 fi
3366 { $as_echo "$as_me:$LINENO: result: yes" >&5
3367 $as_echo "yes" >&6; }
3368
3369 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3370 ac_clean_files=$ac_clean_files_save
3371 # Check that the compiler produces executables we can run.  If not, either
3372 # the compiler is broken, or we cross compile.
3373 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3374 $as_echo_n "checking whether we are cross compiling... " >&6; }
3375 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3376 $as_echo "$cross_compiling" >&6; }
3377
3378 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3379 $as_echo_n "checking for suffix of executables... " >&6; }
3380 if { (ac_try="$ac_link"
3381 case "(($ac_try" in
3382   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3383   *) ac_try_echo=$ac_try;;
3384 esac
3385 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3386 $as_echo "$ac_try_echo") >&5
3387   (eval "$ac_link") 2>&5
3388   ac_status=$?
3389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3390   (exit $ac_status); }; then
3391   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3392 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3393 # work properly (i.e., refer to `conftest.exe'), while it won't with
3394 # `rm'.
3395 for ac_file in conftest.exe conftest conftest.*; do
3396   test -f "$ac_file" || continue
3397   case $ac_file in
3398     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3399     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3400           break;;
3401     * ) break;;
3402   esac
3403 done
3404 else
3405   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3406 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3407 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3408 See \`config.log' for more details." >&5
3409 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3410 See \`config.log' for more details." >&2;}
3411    { (exit 1); exit 1; }; }; }
3412 fi
3413
3414 rm -f conftest$ac_cv_exeext
3415 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3416 $as_echo "$ac_cv_exeext" >&6; }
3417
3418 rm -f conftest.$ac_ext
3419 EXEEXT=$ac_cv_exeext
3420 ac_exeext=$EXEEXT
3421 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3422 $as_echo_n "checking for suffix of object files... " >&6; }
3423 if test "${ac_cv_objext+set}" = set; then
3424   $as_echo_n "(cached) " >&6
3425 else
3426   cat >conftest.$ac_ext <<_ACEOF
3427 /* confdefs.h.  */
3428 _ACEOF
3429 cat confdefs.h >>conftest.$ac_ext
3430 cat >>conftest.$ac_ext <<_ACEOF
3431 /* end confdefs.h.  */
3432
3433 int
3434 main ()
3435 {
3436
3437   ;
3438   return 0;
3439 }
3440 _ACEOF
3441 rm -f conftest.o conftest.obj
3442 if { (ac_try="$ac_compile"
3443 case "(($ac_try" in
3444   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3445   *) ac_try_echo=$ac_try;;
3446 esac
3447 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3448 $as_echo "$ac_try_echo") >&5
3449   (eval "$ac_compile") 2>&5
3450   ac_status=$?
3451   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3452   (exit $ac_status); }; then
3453   for ac_file in conftest.o conftest.obj conftest.*; do
3454   test -f "$ac_file" || continue;
3455   case $ac_file in
3456     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3457     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3458        break;;
3459   esac
3460 done
3461 else
3462   $as_echo "$as_me: failed program was:" >&5
3463 sed 's/^/| /' conftest.$ac_ext >&5
3464
3465 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3466 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3467 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3468 See \`config.log' for more details." >&5
3469 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3470 See \`config.log' for more details." >&2;}
3471    { (exit 1); exit 1; }; }; }
3472 fi
3473
3474 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3475 fi
3476 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3477 $as_echo "$ac_cv_objext" >&6; }
3478 OBJEXT=$ac_cv_objext
3479 ac_objext=$OBJEXT
3480 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3481 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3482 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3483   $as_echo_n "(cached) " >&6
3484 else
3485   cat >conftest.$ac_ext <<_ACEOF
3486 /* confdefs.h.  */
3487 _ACEOF
3488 cat confdefs.h >>conftest.$ac_ext
3489 cat >>conftest.$ac_ext <<_ACEOF
3490 /* end confdefs.h.  */
3491
3492 int
3493 main ()
3494 {
3495 #ifndef __GNUC__
3496        choke me
3497 #endif
3498
3499   ;
3500   return 0;
3501 }
3502 _ACEOF
3503 rm -f conftest.$ac_objext
3504 if { (ac_try="$ac_compile"
3505 case "(($ac_try" in
3506   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3507   *) ac_try_echo=$ac_try;;
3508 esac
3509 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3510 $as_echo "$ac_try_echo") >&5
3511   (eval "$ac_compile") 2>conftest.er1
3512   ac_status=$?
3513   grep -v '^ *+' conftest.er1 >conftest.err
3514   rm -f conftest.er1
3515   cat conftest.err >&5
3516   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3517   (exit $ac_status); } && {
3518          test -z "$ac_c_werror_flag" ||
3519          test ! -s conftest.err
3520        } && test -s conftest.$ac_objext; then
3521   ac_compiler_gnu=yes
3522 else
3523   $as_echo "$as_me: failed program was:" >&5
3524 sed 's/^/| /' conftest.$ac_ext >&5
3525
3526         ac_compiler_gnu=no
3527 fi
3528
3529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3530 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3531
3532 fi
3533 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3534 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3535 if test $ac_compiler_gnu = yes; then
3536   GCC=yes
3537 else
3538   GCC=
3539 fi
3540 ac_test_CFLAGS=${CFLAGS+set}
3541 ac_save_CFLAGS=$CFLAGS
3542 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3543 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3544 if test "${ac_cv_prog_cc_g+set}" = set; then
3545   $as_echo_n "(cached) " >&6
3546 else
3547   ac_save_c_werror_flag=$ac_c_werror_flag
3548    ac_c_werror_flag=yes
3549    ac_cv_prog_cc_g=no
3550    CFLAGS="-g"
3551    cat >conftest.$ac_ext <<_ACEOF
3552 /* confdefs.h.  */
3553 _ACEOF
3554 cat confdefs.h >>conftest.$ac_ext
3555 cat >>conftest.$ac_ext <<_ACEOF
3556 /* end confdefs.h.  */
3557
3558 int
3559 main ()
3560 {
3561
3562   ;
3563   return 0;
3564 }
3565 _ACEOF
3566 rm -f conftest.$ac_objext
3567 if { (ac_try="$ac_compile"
3568 case "(($ac_try" in
3569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3570   *) ac_try_echo=$ac_try;;
3571 esac
3572 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3573 $as_echo "$ac_try_echo") >&5
3574   (eval "$ac_compile") 2>conftest.er1
3575   ac_status=$?
3576   grep -v '^ *+' conftest.er1 >conftest.err
3577   rm -f conftest.er1
3578   cat conftest.err >&5
3579   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3580   (exit $ac_status); } && {
3581          test -z "$ac_c_werror_flag" ||
3582          test ! -s conftest.err
3583        } && test -s conftest.$ac_objext; then
3584   ac_cv_prog_cc_g=yes
3585 else
3586   $as_echo "$as_me: failed program was:" >&5
3587 sed 's/^/| /' conftest.$ac_ext >&5
3588
3589         CFLAGS=""
3590       cat >conftest.$ac_ext <<_ACEOF
3591 /* confdefs.h.  */
3592 _ACEOF
3593 cat confdefs.h >>conftest.$ac_ext
3594 cat >>conftest.$ac_ext <<_ACEOF
3595 /* end confdefs.h.  */
3596
3597 int
3598 main ()
3599 {
3600
3601   ;
3602   return 0;
3603 }
3604 _ACEOF
3605 rm -f conftest.$ac_objext
3606 if { (ac_try="$ac_compile"
3607 case "(($ac_try" in
3608   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3609   *) ac_try_echo=$ac_try;;
3610 esac
3611 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3612 $as_echo "$ac_try_echo") >&5
3613   (eval "$ac_compile") 2>conftest.er1
3614   ac_status=$?
3615   grep -v '^ *+' conftest.er1 >conftest.err
3616   rm -f conftest.er1
3617   cat conftest.err >&5
3618   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3619   (exit $ac_status); } && {
3620          test -z "$ac_c_werror_flag" ||
3621          test ! -s conftest.err
3622        } && test -s conftest.$ac_objext; then
3623   :
3624 else
3625   $as_echo "$as_me: failed program was:" >&5
3626 sed 's/^/| /' conftest.$ac_ext >&5
3627
3628         ac_c_werror_flag=$ac_save_c_werror_flag
3629          CFLAGS="-g"
3630          cat >conftest.$ac_ext <<_ACEOF
3631 /* confdefs.h.  */
3632 _ACEOF
3633 cat confdefs.h >>conftest.$ac_ext
3634 cat >>conftest.$ac_ext <<_ACEOF
3635 /* end confdefs.h.  */
3636
3637 int
3638 main ()
3639 {
3640
3641   ;
3642   return 0;
3643 }
3644 _ACEOF
3645 rm -f conftest.$ac_objext
3646 if { (ac_try="$ac_compile"
3647 case "(($ac_try" in
3648   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3649   *) ac_try_echo=$ac_try;;
3650 esac
3651 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3652 $as_echo "$ac_try_echo") >&5
3653   (eval "$ac_compile") 2>conftest.er1
3654   ac_status=$?
3655   grep -v '^ *+' conftest.er1 >conftest.err
3656   rm -f conftest.er1
3657   cat conftest.err >&5
3658   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3659   (exit $ac_status); } && {
3660          test -z "$ac_c_werror_flag" ||
3661          test ! -s conftest.err
3662        } && test -s conftest.$ac_objext; then
3663   ac_cv_prog_cc_g=yes
3664 else
3665   $as_echo "$as_me: failed program was:" >&5
3666 sed 's/^/| /' conftest.$ac_ext >&5
3667
3668
3669 fi
3670
3671 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3672 fi
3673
3674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3675 fi
3676
3677 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3678    ac_c_werror_flag=$ac_save_c_werror_flag
3679 fi
3680 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3681 $as_echo "$ac_cv_prog_cc_g" >&6; }
3682 if test "$ac_test_CFLAGS" = set; then
3683   CFLAGS=$ac_save_CFLAGS
3684 elif test $ac_cv_prog_cc_g = yes; then
3685   if test "$GCC" = yes; then
3686     CFLAGS="-g -O2"
3687   else
3688     CFLAGS="-g"
3689   fi
3690 else
3691   if test "$GCC" = yes; then
3692     CFLAGS="-O2"
3693   else
3694     CFLAGS=
3695   fi
3696 fi
3697 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3698 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3699 if test "${ac_cv_prog_cc_c89+set}" = set; then
3700   $as_echo_n "(cached) " >&6
3701 else
3702   ac_cv_prog_cc_c89=no
3703 ac_save_CC=$CC
3704 cat >conftest.$ac_ext <<_ACEOF
3705 /* confdefs.h.  */
3706 _ACEOF
3707 cat confdefs.h >>conftest.$ac_ext
3708 cat >>conftest.$ac_ext <<_ACEOF
3709 /* end confdefs.h.  */
3710 #include <stdarg.h>
3711 #include <stdio.h>
3712 #include <sys/types.h>
3713 #include <sys/stat.h>
3714 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3715 struct buf { int x; };
3716 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3717 static char *e (p, i)
3718      char **p;
3719      int i;
3720 {
3721   return p[i];
3722 }
3723 static char *f (char * (*g) (char **, int), char **p, ...)
3724 {
3725   char *s;
3726   va_list v;
3727   va_start (v,p);
3728   s = g (p, va_arg (v,int));
3729   va_end (v);
3730   return s;
3731 }
3732
3733 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3734    function prototypes and stuff, but not '\xHH' hex character constants.
3735    These don't provoke an error unfortunately, instead are silently treated
3736    as 'x'.  The following induces an error, until -std is added to get
3737    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3738    array size at least.  It's necessary to write '\x00'==0 to get something
3739    that's true only with -std.  */
3740 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3741
3742 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3743    inside strings and character constants.  */
3744 #define FOO(x) 'x'
3745 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3746
3747 int test (int i, double x);
3748 struct s1 {int (*f) (int a);};
3749 struct s2 {int (*f) (double a);};
3750 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3751 int argc;
3752 char **argv;
3753 int
3754 main ()
3755 {
3756 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3757   ;
3758   return 0;
3759 }
3760 _ACEOF
3761 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3762         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3763 do
3764   CC="$ac_save_CC $ac_arg"
3765   rm -f conftest.$ac_objext
3766 if { (ac_try="$ac_compile"
3767 case "(($ac_try" in
3768   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3769   *) ac_try_echo=$ac_try;;
3770 esac
3771 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3772 $as_echo "$ac_try_echo") >&5
3773   (eval "$ac_compile") 2>conftest.er1
3774   ac_status=$?
3775   grep -v '^ *+' conftest.er1 >conftest.err
3776   rm -f conftest.er1
3777   cat conftest.err >&5
3778   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3779   (exit $ac_status); } && {
3780          test -z "$ac_c_werror_flag" ||
3781          test ! -s conftest.err
3782        } && test -s conftest.$ac_objext; then
3783   ac_cv_prog_cc_c89=$ac_arg
3784 else
3785   $as_echo "$as_me: failed program was:" >&5
3786 sed 's/^/| /' conftest.$ac_ext >&5
3787
3788
3789 fi
3790
3791 rm -f core conftest.err conftest.$ac_objext
3792   test "x$ac_cv_prog_cc_c89" != "xno" && break
3793 done
3794 rm -f conftest.$ac_ext
3795 CC=$ac_save_CC
3796
3797 fi
3798 # AC_CACHE_VAL
3799 case "x$ac_cv_prog_cc_c89" in
3800   x)
3801     { $as_echo "$as_me:$LINENO: result: none needed" >&5
3802 $as_echo "none needed" >&6; } ;;
3803   xno)
3804     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3805 $as_echo "unsupported" >&6; } ;;
3806   *)
3807     CC="$CC $ac_cv_prog_cc_c89"
3808     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3809 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3810 esac
3811
3812
3813 ac_ext=c
3814 ac_cpp='$CPP $CPPFLAGS'
3815 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3816 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3817 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3818
3819
3820 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3821 # but has idiosyncrasies of its own.  We assume icc will define
3822 # __INTEL_COMPILER regardless of CFLAGS.
3823
3824 cat >conftest.$ac_ext <<_ACEOF
3825 /* confdefs.h.  */
3826 _ACEOF
3827 cat confdefs.h >>conftest.$ac_ext
3828 cat >>conftest.$ac_ext <<_ACEOF
3829 /* end confdefs.h.  */
3830
3831 int
3832 main ()
3833 {
3834 #ifndef __INTEL_COMPILER
3835 choke me
3836 #endif
3837   ;
3838   return 0;
3839 }
3840 _ACEOF
3841 rm -f conftest.$ac_objext
3842 if { (ac_try="$ac_compile"
3843 case "(($ac_try" in
3844   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3845   *) ac_try_echo=$ac_try;;
3846 esac
3847 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3848 $as_echo "$ac_try_echo") >&5
3849   (eval "$ac_compile") 2>conftest.er1
3850   ac_status=$?
3851   grep -v '^ *+' conftest.er1 >conftest.err
3852   rm -f conftest.er1
3853   cat conftest.err >&5
3854   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3855   (exit $ac_status); } && {
3856          test -z "$ac_c_werror_flag" ||
3857          test ! -s conftest.err
3858        } && test -s conftest.$ac_objext; then
3859   ICC=yes
3860 else
3861   $as_echo "$as_me: failed program was:" >&5
3862 sed 's/^/| /' conftest.$ac_ext >&5
3863
3864         ICC=no
3865 fi
3866
3867 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3868
3869 # Check if it's Sun Studio compiler. We assume that
3870 # __SUNPRO_C will be defined for Sun Studio compilers
3871 cat >conftest.$ac_ext <<_ACEOF
3872 /* confdefs.h.  */
3873 _ACEOF
3874 cat confdefs.h >>conftest.$ac_ext
3875 cat >>conftest.$ac_ext <<_ACEOF
3876 /* end confdefs.h.  */
3877
3878 int
3879 main ()
3880 {
3881 #ifndef __SUNPRO_C
3882 choke me
3883 #endif
3884   ;
3885   return 0;
3886 }
3887 _ACEOF
3888 rm -f conftest.$ac_objext
3889 if { (ac_try="$ac_compile"
3890 case "(($ac_try" in
3891   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3892   *) ac_try_echo=$ac_try;;
3893 esac
3894 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3895 $as_echo "$ac_try_echo") >&5
3896   (eval "$ac_compile") 2>conftest.er1
3897   ac_status=$?
3898   grep -v '^ *+' conftest.er1 >conftest.err
3899   rm -f conftest.er1
3900   cat conftest.err >&5
3901   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3902   (exit $ac_status); } && {
3903          test -z "$ac_c_werror_flag" ||
3904          test ! -s conftest.err
3905        } && test -s conftest.$ac_objext; then
3906   SUN_STUDIO_CC=yes
3907 else
3908   $as_echo "$as_me: failed program was:" >&5
3909 sed 's/^/| /' conftest.$ac_ext >&5
3910
3911         SUN_STUDIO_CC=no
3912 fi
3913
3914 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3915
3916
3917
3918 unset CFLAGS
3919
3920 #
3921 # Read the template
3922 #
3923 . "$srcdir/src/template/$template" || exit
3924
3925 # CFLAGS are selected so:
3926 # If the user specifies something in the environment, that is used.
3927 # else:  If the template file set something, that is used.
3928 # else:  If coverage was enabled, don't set anything.
3929 # else:  If the compiler is GCC, then we use -O2.
3930 # else:  If the compiler is something else, then we use -O, unless debugging.
3931
3932 if test "$ac_env_CFLAGS_set" = set; then
3933   CFLAGS=$ac_env_CFLAGS_value
3934 elif test "${CFLAGS+set}" = set; then
3935   : # (keep what template set)
3936 elif test "$enable_coverage" = yes; then
3937   : # no optimization by default
3938 elif test "$GCC" = yes; then
3939   CFLAGS="-O2"
3940 else
3941   # if the user selected debug mode, don't use -O
3942   if test "$enable_debug" != yes; then
3943     CFLAGS="-O"
3944   fi
3945 fi
3946
3947 # set CFLAGS_VECTOR from the environment, if available
3948 if test "$ac_env_CFLAGS_VECTOR_set" = set; then
3949   CFLAGS_VECTOR=$ac_env_CFLAGS_VECTOR_value
3950 fi
3951
3952 # Some versions of GCC support some additional useful warning flags.
3953 # Check whether they are supported, and add them to CFLAGS if so.
3954 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
3955 # but has its own.  Also check other compiler-specific flags here.
3956
3957 if test "$GCC" = yes -a "$ICC" = no; then
3958   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
3959   # These work in some but not all gcc versions
3960   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wdeclaration-after-statement" >&5
3961 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
3962 if test "${pgac_cv_prog_cc_cflags__Wdeclaration_after_statement+set}" = set; then
3963   $as_echo_n "(cached) " >&6
3964 else
3965   pgac_save_CFLAGS=$CFLAGS
3966 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
3967 ac_save_c_werror_flag=$ac_c_werror_flag
3968 ac_c_werror_flag=yes
3969 cat >conftest.$ac_ext <<_ACEOF
3970 /* confdefs.h.  */
3971 _ACEOF
3972 cat confdefs.h >>conftest.$ac_ext
3973 cat >>conftest.$ac_ext <<_ACEOF
3974 /* end confdefs.h.  */
3975
3976 int
3977 main ()
3978 {
3979
3980   ;
3981   return 0;
3982 }
3983 _ACEOF
3984 rm -f conftest.$ac_objext
3985 if { (ac_try="$ac_compile"
3986 case "(($ac_try" in
3987   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3988   *) ac_try_echo=$ac_try;;
3989 esac
3990 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3991 $as_echo "$ac_try_echo") >&5
3992   (eval "$ac_compile") 2>conftest.er1
3993   ac_status=$?
3994   grep -v '^ *+' conftest.er1 >conftest.err
3995   rm -f conftest.er1
3996   cat conftest.err >&5
3997   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3998   (exit $ac_status); } && {
3999          test -z "$ac_c_werror_flag" ||
4000          test ! -s conftest.err
4001        } && test -s conftest.$ac_objext; then
4002   pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=yes
4003 else
4004   $as_echo "$as_me: failed program was:" >&5
4005 sed 's/^/| /' conftest.$ac_ext >&5
4006
4007         pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=no
4008 fi
4009
4010 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4011 ac_c_werror_flag=$ac_save_c_werror_flag
4012 CFLAGS="$pgac_save_CFLAGS"
4013 fi
4014 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&5
4015 $as_echo "$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&6; }
4016 if test x"$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" = x"yes"; then
4017   CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4018 fi
4019
4020   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wendif-labels" >&5
4021 $as_echo_n "checking whether $CC supports -Wendif-labels... " >&6; }
4022 if test "${pgac_cv_prog_cc_cflags__Wendif_labels+set}" = set; then
4023   $as_echo_n "(cached) " >&6
4024 else
4025   pgac_save_CFLAGS=$CFLAGS
4026 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4027 ac_save_c_werror_flag=$ac_c_werror_flag
4028 ac_c_werror_flag=yes
4029 cat >conftest.$ac_ext <<_ACEOF
4030 /* confdefs.h.  */
4031 _ACEOF
4032 cat confdefs.h >>conftest.$ac_ext
4033 cat >>conftest.$ac_ext <<_ACEOF
4034 /* end confdefs.h.  */
4035
4036 int
4037 main ()
4038 {
4039
4040   ;
4041   return 0;
4042 }
4043 _ACEOF
4044 rm -f conftest.$ac_objext
4045 if { (ac_try="$ac_compile"
4046 case "(($ac_try" in
4047   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4048   *) ac_try_echo=$ac_try;;
4049 esac
4050 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4051 $as_echo "$ac_try_echo") >&5
4052   (eval "$ac_compile") 2>conftest.er1
4053   ac_status=$?
4054   grep -v '^ *+' conftest.er1 >conftest.err
4055   rm -f conftest.er1
4056   cat conftest.err >&5
4057   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4058   (exit $ac_status); } && {
4059          test -z "$ac_c_werror_flag" ||
4060          test ! -s conftest.err
4061        } && test -s conftest.$ac_objext; then
4062   pgac_cv_prog_cc_cflags__Wendif_labels=yes
4063 else
4064   $as_echo "$as_me: failed program was:" >&5
4065 sed 's/^/| /' conftest.$ac_ext >&5
4066
4067         pgac_cv_prog_cc_cflags__Wendif_labels=no
4068 fi
4069
4070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4071 ac_c_werror_flag=$ac_save_c_werror_flag
4072 CFLAGS="$pgac_save_CFLAGS"
4073 fi
4074 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wendif_labels" >&5
4075 $as_echo "$pgac_cv_prog_cc_cflags__Wendif_labels" >&6; }
4076 if test x"$pgac_cv_prog_cc_cflags__Wendif_labels" = x"yes"; then
4077   CFLAGS="$CFLAGS -Wendif-labels"
4078 fi
4079
4080   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wmissing-format-attribute" >&5
4081 $as_echo_n "checking whether $CC supports -Wmissing-format-attribute... " >&6; }
4082 if test "${pgac_cv_prog_cc_cflags__Wmissing_format_attribute+set}" = set; then
4083   $as_echo_n "(cached) " >&6
4084 else
4085   pgac_save_CFLAGS=$CFLAGS
4086 CFLAGS="$pgac_save_CFLAGS -Wmissing-format-attribute"
4087 ac_save_c_werror_flag=$ac_c_werror_flag
4088 ac_c_werror_flag=yes
4089 cat >conftest.$ac_ext <<_ACEOF
4090 /* confdefs.h.  */
4091 _ACEOF
4092 cat confdefs.h >>conftest.$ac_ext
4093 cat >>conftest.$ac_ext <<_ACEOF
4094 /* end confdefs.h.  */
4095
4096 int
4097 main ()
4098 {
4099
4100   ;
4101   return 0;
4102 }
4103 _ACEOF
4104 rm -f conftest.$ac_objext
4105 if { (ac_try="$ac_compile"
4106 case "(($ac_try" in
4107   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4108   *) ac_try_echo=$ac_try;;
4109 esac
4110 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4111 $as_echo "$ac_try_echo") >&5
4112   (eval "$ac_compile") 2>conftest.er1
4113   ac_status=$?
4114   grep -v '^ *+' conftest.er1 >conftest.err
4115   rm -f conftest.er1
4116   cat conftest.err >&5
4117   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4118   (exit $ac_status); } && {
4119          test -z "$ac_c_werror_flag" ||
4120          test ! -s conftest.err
4121        } && test -s conftest.$ac_objext; then
4122   pgac_cv_prog_cc_cflags__Wmissing_format_attribute=yes
4123 else
4124   $as_echo "$as_me: failed program was:" >&5
4125 sed 's/^/| /' conftest.$ac_ext >&5
4126
4127         pgac_cv_prog_cc_cflags__Wmissing_format_attribute=no
4128 fi
4129
4130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4131 ac_c_werror_flag=$ac_save_c_werror_flag
4132 CFLAGS="$pgac_save_CFLAGS"
4133 fi
4134 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wmissing_format_attribute" >&5
4135 $as_echo "$pgac_cv_prog_cc_cflags__Wmissing_format_attribute" >&6; }
4136 if test x"$pgac_cv_prog_cc_cflags__Wmissing_format_attribute" = x"yes"; then
4137   CFLAGS="$CFLAGS -Wmissing-format-attribute"
4138 fi
4139
4140   # This was included in -Wall/-Wformat in older GCC versions
4141   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wformat-security" >&5
4142 $as_echo_n "checking whether $CC supports -Wformat-security... " >&6; }
4143 if test "${pgac_cv_prog_cc_cflags__Wformat_security+set}" = set; then
4144   $as_echo_n "(cached) " >&6
4145 else
4146   pgac_save_CFLAGS=$CFLAGS
4147 CFLAGS="$pgac_save_CFLAGS -Wformat-security"
4148 ac_save_c_werror_flag=$ac_c_werror_flag
4149 ac_c_werror_flag=yes
4150 cat >conftest.$ac_ext <<_ACEOF
4151 /* confdefs.h.  */
4152 _ACEOF
4153 cat confdefs.h >>conftest.$ac_ext
4154 cat >>conftest.$ac_ext <<_ACEOF
4155 /* end confdefs.h.  */
4156
4157 int
4158 main ()
4159 {
4160
4161   ;
4162   return 0;
4163 }
4164 _ACEOF
4165 rm -f conftest.$ac_objext
4166 if { (ac_try="$ac_compile"
4167 case "(($ac_try" in
4168   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4169   *) ac_try_echo=$ac_try;;
4170 esac
4171 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4172 $as_echo "$ac_try_echo") >&5
4173   (eval "$ac_compile") 2>conftest.er1
4174   ac_status=$?
4175   grep -v '^ *+' conftest.er1 >conftest.err
4176   rm -f conftest.er1
4177   cat conftest.err >&5
4178   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4179   (exit $ac_status); } && {
4180          test -z "$ac_c_werror_flag" ||
4181          test ! -s conftest.err
4182        } && test -s conftest.$ac_objext; then
4183   pgac_cv_prog_cc_cflags__Wformat_security=yes
4184 else
4185   $as_echo "$as_me: failed program was:" >&5
4186 sed 's/^/| /' conftest.$ac_ext >&5
4187
4188         pgac_cv_prog_cc_cflags__Wformat_security=no
4189 fi
4190
4191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4192 ac_c_werror_flag=$ac_save_c_werror_flag
4193 CFLAGS="$pgac_save_CFLAGS"
4194 fi
4195 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wformat_security" >&5
4196 $as_echo "$pgac_cv_prog_cc_cflags__Wformat_security" >&6; }
4197 if test x"$pgac_cv_prog_cc_cflags__Wformat_security" = x"yes"; then
4198   CFLAGS="$CFLAGS -Wformat-security"
4199 fi
4200
4201   # Disable strict-aliasing rules; needed for gcc 3.3+
4202   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4203 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4204 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4205   $as_echo_n "(cached) " >&6
4206 else
4207   pgac_save_CFLAGS=$CFLAGS
4208 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4209 ac_save_c_werror_flag=$ac_c_werror_flag
4210 ac_c_werror_flag=yes
4211 cat >conftest.$ac_ext <<_ACEOF
4212 /* confdefs.h.  */
4213 _ACEOF
4214 cat confdefs.h >>conftest.$ac_ext
4215 cat >>conftest.$ac_ext <<_ACEOF
4216 /* end confdefs.h.  */
4217
4218 int
4219 main ()
4220 {
4221
4222   ;
4223   return 0;
4224 }
4225 _ACEOF
4226 rm -f conftest.$ac_objext
4227 if { (ac_try="$ac_compile"
4228 case "(($ac_try" in
4229   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4230   *) ac_try_echo=$ac_try;;
4231 esac
4232 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4233 $as_echo "$ac_try_echo") >&5
4234   (eval "$ac_compile") 2>conftest.er1
4235   ac_status=$?
4236   grep -v '^ *+' conftest.er1 >conftest.err
4237   rm -f conftest.er1
4238   cat conftest.err >&5
4239   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4240   (exit $ac_status); } && {
4241          test -z "$ac_c_werror_flag" ||
4242          test ! -s conftest.err
4243        } && test -s conftest.$ac_objext; then
4244   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4245 else
4246   $as_echo "$as_me: failed program was:" >&5
4247 sed 's/^/| /' conftest.$ac_ext >&5
4248
4249         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4250 fi
4251
4252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4253 ac_c_werror_flag=$ac_save_c_werror_flag
4254 CFLAGS="$pgac_save_CFLAGS"
4255 fi
4256 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4257 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4258 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4259   CFLAGS="$CFLAGS -fno-strict-aliasing"
4260 fi
4261
4262   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4263   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fwrapv" >&5
4264 $as_echo_n "checking whether $CC supports -fwrapv... " >&6; }
4265 if test "${pgac_cv_prog_cc_cflags__fwrapv+set}" = set; then
4266   $as_echo_n "(cached) " >&6
4267 else
4268   pgac_save_CFLAGS=$CFLAGS
4269 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4270 ac_save_c_werror_flag=$ac_c_werror_flag
4271 ac_c_werror_flag=yes
4272 cat >conftest.$ac_ext <<_ACEOF
4273 /* confdefs.h.  */
4274 _ACEOF
4275 cat confdefs.h >>conftest.$ac_ext
4276 cat >>conftest.$ac_ext <<_ACEOF
4277 /* end confdefs.h.  */
4278
4279 int
4280 main ()
4281 {
4282
4283   ;
4284   return 0;
4285 }
4286 _ACEOF
4287 rm -f conftest.$ac_objext
4288 if { (ac_try="$ac_compile"
4289 case "(($ac_try" in
4290   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4291   *) ac_try_echo=$ac_try;;
4292 esac
4293 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4294 $as_echo "$ac_try_echo") >&5
4295   (eval "$ac_compile") 2>conftest.er1
4296   ac_status=$?
4297   grep -v '^ *+' conftest.er1 >conftest.err
4298   rm -f conftest.er1
4299   cat conftest.err >&5
4300   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4301   (exit $ac_status); } && {
4302          test -z "$ac_c_werror_flag" ||
4303          test ! -s conftest.err
4304        } && test -s conftest.$ac_objext; then
4305   pgac_cv_prog_cc_cflags__fwrapv=yes
4306 else
4307   $as_echo "$as_me: failed program was:" >&5
4308 sed 's/^/| /' conftest.$ac_ext >&5
4309
4310         pgac_cv_prog_cc_cflags__fwrapv=no
4311 fi
4312
4313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4314 ac_c_werror_flag=$ac_save_c_werror_flag
4315 CFLAGS="$pgac_save_CFLAGS"
4316 fi
4317 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fwrapv" >&5
4318 $as_echo "$pgac_cv_prog_cc_cflags__fwrapv" >&6; }
4319 if test x"$pgac_cv_prog_cc_cflags__fwrapv" = x"yes"; then
4320   CFLAGS="$CFLAGS -fwrapv"
4321 fi
4322
4323   # Disable FP optimizations that cause various errors on gcc 4.5+ or maybe 4.6+
4324   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fexcess-precision=standard" >&5
4325 $as_echo_n "checking whether $CC supports -fexcess-precision=standard... " >&6; }
4326 if test "${pgac_cv_prog_cc_cflags__fexcess_precision_standard+set}" = set; then
4327   $as_echo_n "(cached) " >&6
4328 else
4329   pgac_save_CFLAGS=$CFLAGS
4330 CFLAGS="$pgac_save_CFLAGS -fexcess-precision=standard"
4331 ac_save_c_werror_flag=$ac_c_werror_flag
4332 ac_c_werror_flag=yes
4333 cat >conftest.$ac_ext <<_ACEOF
4334 /* confdefs.h.  */
4335 _ACEOF
4336 cat confdefs.h >>conftest.$ac_ext
4337 cat >>conftest.$ac_ext <<_ACEOF
4338 /* end confdefs.h.  */
4339
4340 int
4341 main ()
4342 {
4343
4344   ;
4345   return 0;
4346 }
4347 _ACEOF
4348 rm -f conftest.$ac_objext
4349 if { (ac_try="$ac_compile"
4350 case "(($ac_try" in
4351   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4352   *) ac_try_echo=$ac_try;;
4353 esac
4354 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4355 $as_echo "$ac_try_echo") >&5
4356   (eval "$ac_compile") 2>conftest.er1
4357   ac_status=$?
4358   grep -v '^ *+' conftest.er1 >conftest.err
4359   rm -f conftest.er1
4360   cat conftest.err >&5
4361   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4362   (exit $ac_status); } && {
4363          test -z "$ac_c_werror_flag" ||
4364          test ! -s conftest.err
4365        } && test -s conftest.$ac_objext; then
4366   pgac_cv_prog_cc_cflags__fexcess_precision_standard=yes
4367 else
4368   $as_echo "$as_me: failed program was:" >&5
4369 sed 's/^/| /' conftest.$ac_ext >&5
4370
4371         pgac_cv_prog_cc_cflags__fexcess_precision_standard=no
4372 fi
4373
4374 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4375 ac_c_werror_flag=$ac_save_c_werror_flag
4376 CFLAGS="$pgac_save_CFLAGS"
4377 fi
4378 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fexcess_precision_standard" >&5
4379 $as_echo "$pgac_cv_prog_cc_cflags__fexcess_precision_standard" >&6; }
4380 if test x"$pgac_cv_prog_cc_cflags__fexcess_precision_standard" = x"yes"; then
4381   CFLAGS="$CFLAGS -fexcess-precision=standard"
4382 fi
4383
4384   # Optimization flags for specific files that benefit from vectorization
4385   { $as_echo "$as_me:$LINENO: checking whether $CC supports -funroll-loops" >&5
4386 $as_echo_n "checking whether $CC supports -funroll-loops... " >&6; }
4387 if test "${pgac_cv_prog_cc_cflags__funroll_loops+set}" = set; then
4388   $as_echo_n "(cached) " >&6
4389 else
4390   pgac_save_CFLAGS=$CFLAGS
4391 CFLAGS="$pgac_save_CFLAGS -funroll-loops"
4392 ac_save_c_werror_flag=$ac_c_werror_flag
4393 ac_c_werror_flag=yes
4394 cat >conftest.$ac_ext <<_ACEOF
4395 /* confdefs.h.  */
4396 _ACEOF
4397 cat confdefs.h >>conftest.$ac_ext
4398 cat >>conftest.$ac_ext <<_ACEOF
4399 /* end confdefs.h.  */
4400
4401 int
4402 main ()
4403 {
4404
4405   ;
4406   return 0;
4407 }
4408 _ACEOF
4409 rm -f conftest.$ac_objext
4410 if { (ac_try="$ac_compile"
4411 case "(($ac_try" in
4412   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4413   *) ac_try_echo=$ac_try;;
4414 esac
4415 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4416 $as_echo "$ac_try_echo") >&5
4417   (eval "$ac_compile") 2>conftest.er1
4418   ac_status=$?
4419   grep -v '^ *+' conftest.er1 >conftest.err
4420   rm -f conftest.er1
4421   cat conftest.err >&5
4422   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4423   (exit $ac_status); } && {
4424          test -z "$ac_c_werror_flag" ||
4425          test ! -s conftest.err
4426        } && test -s conftest.$ac_objext; then
4427   pgac_cv_prog_cc_cflags__funroll_loops=yes
4428 else
4429   $as_echo "$as_me: failed program was:" >&5
4430 sed 's/^/| /' conftest.$ac_ext >&5
4431
4432         pgac_cv_prog_cc_cflags__funroll_loops=no
4433 fi
4434
4435 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4436 ac_c_werror_flag=$ac_save_c_werror_flag
4437 CFLAGS="$pgac_save_CFLAGS"
4438 fi
4439 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__funroll_loops" >&5
4440 $as_echo "$pgac_cv_prog_cc_cflags__funroll_loops" >&6; }
4441 if test x"$pgac_cv_prog_cc_cflags__funroll_loops" = x"yes"; then
4442   CFLAGS_VECTOR="${CFLAGS_VECTOR} -funroll-loops"
4443 fi
4444
4445   { $as_echo "$as_me:$LINENO: checking whether $CC supports -ftree-vectorize" >&5
4446 $as_echo_n "checking whether $CC supports -ftree-vectorize... " >&6; }
4447 if test "${pgac_cv_prog_cc_cflags__ftree_vectorize+set}" = set; then
4448   $as_echo_n "(cached) " >&6
4449 else
4450   pgac_save_CFLAGS=$CFLAGS
4451 CFLAGS="$pgac_save_CFLAGS -ftree-vectorize"
4452 ac_save_c_werror_flag=$ac_c_werror_flag
4453 ac_c_werror_flag=yes
4454 cat >conftest.$ac_ext <<_ACEOF
4455 /* confdefs.h.  */
4456 _ACEOF
4457 cat confdefs.h >>conftest.$ac_ext
4458 cat >>conftest.$ac_ext <<_ACEOF
4459 /* end confdefs.h.  */
4460
4461 int
4462 main ()
4463 {
4464
4465   ;
4466   return 0;
4467 }
4468 _ACEOF
4469 rm -f conftest.$ac_objext
4470 if { (ac_try="$ac_compile"
4471 case "(($ac_try" in
4472   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4473   *) ac_try_echo=$ac_try;;
4474 esac
4475 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4476 $as_echo "$ac_try_echo") >&5
4477   (eval "$ac_compile") 2>conftest.er1
4478   ac_status=$?
4479   grep -v '^ *+' conftest.er1 >conftest.err
4480   rm -f conftest.er1
4481   cat conftest.err >&5
4482   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4483   (exit $ac_status); } && {
4484          test -z "$ac_c_werror_flag" ||
4485          test ! -s conftest.err
4486        } && test -s conftest.$ac_objext; then
4487   pgac_cv_prog_cc_cflags__ftree_vectorize=yes
4488 else
4489   $as_echo "$as_me: failed program was:" >&5
4490 sed 's/^/| /' conftest.$ac_ext >&5
4491
4492         pgac_cv_prog_cc_cflags__ftree_vectorize=no
4493 fi
4494
4495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4496 ac_c_werror_flag=$ac_save_c_werror_flag
4497 CFLAGS="$pgac_save_CFLAGS"
4498 fi
4499 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__ftree_vectorize" >&5
4500 $as_echo "$pgac_cv_prog_cc_cflags__ftree_vectorize" >&6; }
4501 if test x"$pgac_cv_prog_cc_cflags__ftree_vectorize" = x"yes"; then
4502   CFLAGS_VECTOR="${CFLAGS_VECTOR} -ftree-vectorize"
4503 fi
4504
4505 elif test "$ICC" = yes; then
4506   # Intel's compiler has a bug/misoptimization in checking for
4507   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4508   { $as_echo "$as_me:$LINENO: checking whether $CC supports -mp1" >&5
4509 $as_echo_n "checking whether $CC supports -mp1... " >&6; }
4510 if test "${pgac_cv_prog_cc_cflags__mp1+set}" = set; then
4511   $as_echo_n "(cached) " >&6
4512 else
4513   pgac_save_CFLAGS=$CFLAGS
4514 CFLAGS="$pgac_save_CFLAGS -mp1"
4515 ac_save_c_werror_flag=$ac_c_werror_flag
4516 ac_c_werror_flag=yes
4517 cat >conftest.$ac_ext <<_ACEOF
4518 /* confdefs.h.  */
4519 _ACEOF
4520 cat confdefs.h >>conftest.$ac_ext
4521 cat >>conftest.$ac_ext <<_ACEOF
4522 /* end confdefs.h.  */
4523
4524 int
4525 main ()
4526 {
4527
4528   ;
4529   return 0;
4530 }
4531 _ACEOF
4532 rm -f conftest.$ac_objext
4533 if { (ac_try="$ac_compile"
4534 case "(($ac_try" in
4535   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4536   *) ac_try_echo=$ac_try;;
4537 esac
4538 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4539 $as_echo "$ac_try_echo") >&5
4540   (eval "$ac_compile") 2>conftest.er1
4541   ac_status=$?
4542   grep -v '^ *+' conftest.er1 >conftest.err
4543   rm -f conftest.er1
4544   cat conftest.err >&5
4545   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4546   (exit $ac_status); } && {
4547          test -z "$ac_c_werror_flag" ||
4548          test ! -s conftest.err
4549        } && test -s conftest.$ac_objext; then
4550   pgac_cv_prog_cc_cflags__mp1=yes
4551 else
4552   $as_echo "$as_me: failed program was:" >&5
4553 sed 's/^/| /' conftest.$ac_ext >&5
4554
4555         pgac_cv_prog_cc_cflags__mp1=no
4556 fi
4557
4558 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4559 ac_c_werror_flag=$ac_save_c_werror_flag
4560 CFLAGS="$pgac_save_CFLAGS"
4561 fi
4562 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__mp1" >&5
4563 $as_echo "$pgac_cv_prog_cc_cflags__mp1" >&6; }
4564 if test x"$pgac_cv_prog_cc_cflags__mp1" = x"yes"; then
4565   CFLAGS="$CFLAGS -mp1"
4566 fi
4567
4568   # Make sure strict aliasing is off (though this is said to be the default)
4569   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4570 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4571 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4572   $as_echo_n "(cached) " >&6
4573 else
4574   pgac_save_CFLAGS=$CFLAGS
4575 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4576 ac_save_c_werror_flag=$ac_c_werror_flag
4577 ac_c_werror_flag=yes
4578 cat >conftest.$ac_ext <<_ACEOF
4579 /* confdefs.h.  */
4580 _ACEOF
4581 cat confdefs.h >>conftest.$ac_ext
4582 cat >>conftest.$ac_ext <<_ACEOF
4583 /* end confdefs.h.  */
4584
4585 int
4586 main ()
4587 {
4588
4589   ;
4590   return 0;
4591 }
4592 _ACEOF
4593 rm -f conftest.$ac_objext
4594 if { (ac_try="$ac_compile"
4595 case "(($ac_try" in
4596   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4597   *) ac_try_echo=$ac_try;;
4598 esac
4599 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4600 $as_echo "$ac_try_echo") >&5
4601   (eval "$ac_compile") 2>conftest.er1
4602   ac_status=$?
4603   grep -v '^ *+' conftest.er1 >conftest.err
4604   rm -f conftest.er1
4605   cat conftest.err >&5
4606   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4607   (exit $ac_status); } && {
4608          test -z "$ac_c_werror_flag" ||
4609          test ! -s conftest.err
4610        } && test -s conftest.$ac_objext; then
4611   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4612 else
4613   $as_echo "$as_me: failed program was:" >&5
4614 sed 's/^/| /' conftest.$ac_ext >&5
4615
4616         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4617 fi
4618
4619 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4620 ac_c_werror_flag=$ac_save_c_werror_flag
4621 CFLAGS="$pgac_save_CFLAGS"
4622 fi
4623 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4624 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4625 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4626   CFLAGS="$CFLAGS -fno-strict-aliasing"
4627 fi
4628
4629 elif test "$PORTNAME" = "aix"; then
4630   # AIX's xlc has to have strict aliasing turned off too
4631   { $as_echo "$as_me:$LINENO: checking whether $CC supports -qnoansialias" >&5
4632 $as_echo_n "checking whether $CC supports -qnoansialias... " >&6; }
4633 if test "${pgac_cv_prog_cc_cflags__qnoansialias+set}" = set; then
4634   $as_echo_n "(cached) " >&6
4635 else
4636   pgac_save_CFLAGS=$CFLAGS
4637 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4638 ac_save_c_werror_flag=$ac_c_werror_flag
4639 ac_c_werror_flag=yes
4640 cat >conftest.$ac_ext <<_ACEOF
4641 /* confdefs.h.  */
4642 _ACEOF
4643 cat confdefs.h >>conftest.$ac_ext
4644 cat >>conftest.$ac_ext <<_ACEOF
4645 /* end confdefs.h.  */
4646
4647 int
4648 main ()
4649 {
4650
4651   ;
4652   return 0;
4653 }
4654 _ACEOF
4655 rm -f conftest.$ac_objext
4656 if { (ac_try="$ac_compile"
4657 case "(($ac_try" in
4658   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4659   *) ac_try_echo=$ac_try;;
4660 esac
4661 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4662 $as_echo "$ac_try_echo") >&5
4663   (eval "$ac_compile") 2>conftest.er1
4664   ac_status=$?
4665   grep -v '^ *+' conftest.er1 >conftest.err
4666   rm -f conftest.er1
4667   cat conftest.err >&5
4668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4669   (exit $ac_status); } && {
4670          test -z "$ac_c_werror_flag" ||
4671          test ! -s conftest.err
4672        } && test -s conftest.$ac_objext; then
4673   pgac_cv_prog_cc_cflags__qnoansialias=yes
4674 else
4675   $as_echo "$as_me: failed program was:" >&5
4676 sed 's/^/| /' conftest.$ac_ext >&5
4677
4678         pgac_cv_prog_cc_cflags__qnoansialias=no
4679 fi
4680
4681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4682 ac_c_werror_flag=$ac_save_c_werror_flag
4683 CFLAGS="$pgac_save_CFLAGS"
4684 fi
4685 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__qnoansialias" >&5
4686 $as_echo "$pgac_cv_prog_cc_cflags__qnoansialias" >&6; }
4687 if test x"$pgac_cv_prog_cc_cflags__qnoansialias" = x"yes"; then
4688   CFLAGS="$CFLAGS -qnoansialias"
4689 fi
4690
4691 elif test "$PORTNAME" = "hpux"; then
4692   # On some versions of HP-UX, libm functions do not set errno by default.
4693   # Fix that by using +Olibmerrno if the compiler recognizes it.
4694   { $as_echo "$as_me:$LINENO: checking whether $CC supports +Olibmerrno" >&5
4695 $as_echo_n "checking whether $CC supports +Olibmerrno... " >&6; }
4696 if test "${pgac_cv_prog_cc_cflags_pOlibmerrno+set}" = set; then
4697   $as_echo_n "(cached) " >&6
4698 else
4699   pgac_save_CFLAGS=$CFLAGS
4700 CFLAGS="$pgac_save_CFLAGS +Olibmerrno"
4701 ac_save_c_werror_flag=$ac_c_werror_flag
4702 ac_c_werror_flag=yes
4703 cat >conftest.$ac_ext <<_ACEOF
4704 /* confdefs.h.  */
4705 _ACEOF
4706 cat confdefs.h >>conftest.$ac_ext
4707 cat >>conftest.$ac_ext <<_ACEOF
4708 /* end confdefs.h.  */
4709
4710 int
4711 main ()
4712 {
4713
4714   ;
4715   return 0;
4716 }
4717 _ACEOF
4718 rm -f conftest.$ac_objext
4719 if { (ac_try="$ac_compile"
4720 case "(($ac_try" in
4721   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4722   *) ac_try_echo=$ac_try;;
4723 esac
4724 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4725 $as_echo "$ac_try_echo") >&5
4726   (eval "$ac_compile") 2>conftest.er1
4727   ac_status=$?
4728   grep -v '^ *+' conftest.er1 >conftest.err
4729   rm -f conftest.er1
4730   cat conftest.err >&5
4731   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4732   (exit $ac_status); } && {
4733          test -z "$ac_c_werror_flag" ||
4734          test ! -s conftest.err
4735        } && test -s conftest.$ac_objext; then
4736   pgac_cv_prog_cc_cflags_pOlibmerrno=yes
4737 else
4738   $as_echo "$as_me: failed program was:" >&5
4739 sed 's/^/| /' conftest.$ac_ext >&5
4740
4741         pgac_cv_prog_cc_cflags_pOlibmerrno=no
4742 fi
4743
4744 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4745 ac_c_werror_flag=$ac_save_c_werror_flag
4746 CFLAGS="$pgac_save_CFLAGS"
4747 fi
4748 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags_pOlibmerrno" >&5
4749 $as_echo "$pgac_cv_prog_cc_cflags_pOlibmerrno" >&6; }
4750 if test x"$pgac_cv_prog_cc_cflags_pOlibmerrno" = x"yes"; then
4751   CFLAGS="$CFLAGS +Olibmerrno"
4752 fi
4753
4754 fi
4755
4756 CFLAGS_VECTOR=$CFLAGS_VECTOR
4757
4758
4759 # supply -g if --enable-debug
4760 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4761   CFLAGS="$CFLAGS -g"
4762 fi
4763
4764 # enable code coverage if --enable-coverage
4765 if test "$enable_coverage" = yes; then
4766   if test "$GCC" = yes; then
4767     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4768   else
4769     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4770 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4771    { (exit 1); exit 1; }; }
4772   fi
4773 fi
4774
4775 # enable profiling if --enable-profiling
4776 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4777   if test "$GCC" = yes; then
4778
4779 cat >>confdefs.h <<\_ACEOF
4780 #define PROFILE_PID_DIR 1
4781 _ACEOF
4782
4783     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4784   else
4785     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4786 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4787    { (exit 1); exit 1; }; }
4788   fi
4789 fi
4790
4791 # We already have this in Makefile.win32, but configure needs it too
4792 if test "$PORTNAME" = "win32"; then
4793   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4794 fi
4795
4796 # Check if the compiler still works with the template settings
4797 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4798 $as_echo_n "checking whether the C compiler still works... " >&6; }
4799 cat >conftest.$ac_ext <<_ACEOF
4800 /* confdefs.h.  */
4801 _ACEOF
4802 cat confdefs.h >>conftest.$ac_ext
4803 cat >>conftest.$ac_ext <<_ACEOF
4804 /* end confdefs.h.  */
4805
4806 int
4807 main ()
4808 {
4809 return 0;
4810   ;
4811   return 0;
4812 }
4813 _ACEOF
4814 rm -f conftest.$ac_objext conftest$ac_exeext
4815 if { (ac_try="$ac_link"
4816 case "(($ac_try" in
4817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4818   *) ac_try_echo=$ac_try;;
4819 esac
4820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4821 $as_echo "$ac_try_echo") >&5
4822   (eval "$ac_link") 2>conftest.er1
4823   ac_status=$?
4824   grep -v '^ *+' conftest.er1 >conftest.err
4825   rm -f conftest.er1
4826   cat conftest.err >&5
4827   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4828   (exit $ac_status); } && {
4829          test -z "$ac_c_werror_flag" ||
4830          test ! -s conftest.err
4831        } && test -s conftest$ac_exeext && {
4832          test "$cross_compiling" = yes ||
4833          $as_test_x conftest$ac_exeext
4834        }; then
4835   { $as_echo "$as_me:$LINENO: result: yes" >&5
4836 $as_echo "yes" >&6; }
4837 else
4838   $as_echo "$as_me: failed program was:" >&5
4839 sed 's/^/| /' conftest.$ac_ext >&5
4840
4841         { $as_echo "$as_me:$LINENO: result: no" >&5
4842 $as_echo "no" >&6; }
4843    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4844 $as_echo "$as_me: error: cannot proceed" >&2;}
4845    { (exit 1); exit 1; }; }
4846 fi
4847
4848 rm -rf conftest.dSYM
4849 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4850       conftest$ac_exeext conftest.$ac_ext
4851
4852 # Defend against gcc -ffast-math
4853 if test "$GCC" = yes; then
4854 cat >conftest.$ac_ext <<_ACEOF
4855 /* confdefs.h.  */
4856 _ACEOF
4857 cat confdefs.h >>conftest.$ac_ext
4858 cat >>conftest.$ac_ext <<_ACEOF
4859 /* end confdefs.h.  */
4860
4861 int
4862 main ()
4863 {
4864 #ifdef __FAST_MATH__
4865 choke me
4866 #endif
4867   ;
4868   return 0;
4869 }
4870 _ACEOF
4871 rm -f conftest.$ac_objext
4872 if { (ac_try="$ac_compile"
4873 case "(($ac_try" in
4874   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4875   *) ac_try_echo=$ac_try;;
4876 esac
4877 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4878 $as_echo "$ac_try_echo") >&5
4879   (eval "$ac_compile") 2>conftest.er1
4880   ac_status=$?
4881   grep -v '^ *+' conftest.er1 >conftest.err
4882   rm -f conftest.er1
4883   cat conftest.err >&5
4884   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4885   (exit $ac_status); } && {
4886          test -z "$ac_c_werror_flag" ||
4887          test ! -s conftest.err
4888        } && test -s conftest.$ac_objext; then
4889   :
4890 else
4891   $as_echo "$as_me: failed program was:" >&5
4892 sed 's/^/| /' conftest.$ac_ext >&5
4893
4894         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4895 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4896    { (exit 1); exit 1; }; }
4897 fi
4898
4899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4900 fi
4901
4902 ac_ext=c
4903 ac_cpp='$CPP $CPPFLAGS'
4904 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4905 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4906 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4907 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4908 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4909 # On Suns, sometimes $CPP names a directory.
4910 if test -n "$CPP" && test -d "$CPP"; then
4911   CPP=
4912 fi
4913 if test -z "$CPP"; then
4914   if test "${ac_cv_prog_CPP+set}" = set; then
4915   $as_echo_n "(cached) " >&6
4916 else
4917       # Double quotes because CPP needs to be expanded
4918     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4919     do
4920       ac_preproc_ok=false
4921 for ac_c_preproc_warn_flag in '' yes
4922 do
4923   # Use a header file that comes with gcc, so configuring glibc
4924   # with a fresh cross-compiler works.
4925   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4926   # <limits.h> exists even on freestanding compilers.
4927   # On the NeXT, cc -E runs the code through the compiler's parser,
4928   # not just through cpp. "Syntax error" is here to catch this case.
4929   cat >conftest.$ac_ext <<_ACEOF
4930 /* confdefs.h.  */
4931 _ACEOF
4932 cat confdefs.h >>conftest.$ac_ext
4933 cat >>conftest.$ac_ext <<_ACEOF
4934 /* end confdefs.h.  */
4935 #ifdef __STDC__
4936 # include <limits.h>
4937 #else
4938 # include <assert.h>
4939 #endif
4940                      Syntax error
4941 _ACEOF
4942 if { (ac_try="$ac_cpp conftest.$ac_ext"
4943 case "(($ac_try" in
4944   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4945   *) ac_try_echo=$ac_try;;
4946 esac
4947 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4948 $as_echo "$ac_try_echo") >&5
4949   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4950   ac_status=$?
4951   grep -v '^ *+' conftest.er1 >conftest.err
4952   rm -f conftest.er1
4953   cat conftest.err >&5
4954   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4955   (exit $ac_status); } >/dev/null && {
4956          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4957          test ! -s conftest.err
4958        }; then
4959   :
4960 else
4961   $as_echo "$as_me: failed program was:" >&5
4962 sed 's/^/| /' conftest.$ac_ext >&5
4963
4964   # Broken: fails on valid input.
4965 continue
4966 fi
4967
4968 rm -f conftest.err conftest.$ac_ext
4969
4970   # OK, works on sane cases.  Now check whether nonexistent headers
4971   # can be detected and how.
4972   cat >conftest.$ac_ext <<_ACEOF
4973 /* confdefs.h.  */
4974 _ACEOF
4975 cat confdefs.h >>conftest.$ac_ext
4976 cat >>conftest.$ac_ext <<_ACEOF
4977 /* end confdefs.h.  */
4978 #include <ac_nonexistent.h>
4979 _ACEOF
4980 if { (ac_try="$ac_cpp conftest.$ac_ext"
4981 case "(($ac_try" in
4982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4983   *) ac_try_echo=$ac_try;;
4984 esac
4985 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4986 $as_echo "$ac_try_echo") >&5
4987   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4988   ac_status=$?
4989   grep -v '^ *+' conftest.er1 >conftest.err
4990   rm -f conftest.er1
4991   cat conftest.err >&5
4992   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4993   (exit $ac_status); } >/dev/null && {
4994          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4995          test ! -s conftest.err
4996        }; then
4997   # Broken: success on invalid input.
4998 continue
4999 else
5000   $as_echo "$as_me: failed program was:" >&5
5001 sed 's/^/| /' conftest.$ac_ext >&5
5002
5003   # Passes both tests.
5004 ac_preproc_ok=:
5005 break
5006 fi
5007
5008 rm -f conftest.err conftest.$ac_ext
5009
5010 done
5011 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5012 rm -f conftest.err conftest.$ac_ext
5013 if $ac_preproc_ok; then
5014   break
5015 fi
5016
5017     done
5018     ac_cv_prog_CPP=$CPP
5019
5020 fi
5021   CPP=$ac_cv_prog_CPP
5022 else
5023   ac_cv_prog_CPP=$CPP
5024 fi
5025 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
5026 $as_echo "$CPP" >&6; }
5027 ac_preproc_ok=false
5028 for ac_c_preproc_warn_flag in '' yes
5029 do
5030   # Use a header file that comes with gcc, so configuring glibc
5031   # with a fresh cross-compiler works.
5032   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5033   # <limits.h> exists even on freestanding compilers.
5034   # On the NeXT, cc -E runs the code through the compiler's parser,
5035   # not just through cpp. "Syntax error" is here to catch this case.
5036   cat >conftest.$ac_ext <<_ACEOF
5037 /* confdefs.h.  */
5038 _ACEOF
5039 cat confdefs.h >>conftest.$ac_ext
5040 cat >>conftest.$ac_ext <<_ACEOF
5041 /* end confdefs.h.  */
5042 #ifdef __STDC__
5043 # include <limits.h>
5044 #else
5045 # include <assert.h>
5046 #endif
5047                      Syntax error
5048 _ACEOF
5049 if { (ac_try="$ac_cpp conftest.$ac_ext"
5050 case "(($ac_try" in
5051   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5052   *) ac_try_echo=$ac_try;;
5053 esac
5054 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5055 $as_echo "$ac_try_echo") >&5
5056   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
5057   ac_status=$?
5058   grep -v '^ *+' conftest.er1 >conftest.err
5059   rm -f conftest.er1
5060   cat conftest.err >&5
5061   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5062   (exit $ac_status); } >/dev/null && {
5063          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
5064          test ! -s conftest.err
5065        }; then
5066   :
5067 else
5068   $as_echo "$as_me: failed program was:" >&5
5069 sed 's/^/| /' conftest.$ac_ext >&5
5070
5071   # Broken: fails on valid input.
5072 continue
5073 fi
5074
5075 rm -f conftest.err conftest.$ac_ext
5076
5077   # OK, works on sane cases.  Now check whether nonexistent headers
5078   # can be detected and how.
5079   cat >conftest.$ac_ext <<_ACEOF
5080 /* confdefs.h.  */
5081 _ACEOF
5082 cat confdefs.h >>conftest.$ac_ext
5083 cat >>conftest.$ac_ext <<_ACEOF
5084 /* end confdefs.h.  */
5085 #include <ac_nonexistent.h>
5086 _ACEOF
5087 if { (ac_try="$ac_cpp conftest.$ac_ext"
5088 case "(($ac_try" in
5089   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5090   *) ac_try_echo=$ac_try;;
5091 esac
5092 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5093 $as_echo "$ac_try_echo") >&5
5094   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
5095   ac_status=$?
5096   grep -v '^ *+' conftest.er1 >conftest.err
5097   rm -f conftest.er1
5098   cat conftest.err >&5
5099   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5100   (exit $ac_status); } >/dev/null && {
5101          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
5102          test ! -s conftest.err
5103        }; then
5104   # Broken: success on invalid input.
5105 continue
5106 else
5107   $as_echo "$as_me: failed program was:" >&5
5108 sed 's/^/| /' conftest.$ac_ext >&5
5109
5110   # Passes both tests.
5111 ac_preproc_ok=:
5112 break
5113 fi
5114
5115 rm -f conftest.err conftest.$ac_ext
5116
5117 done
5118 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5119 rm -f conftest.err conftest.$ac_ext
5120 if $ac_preproc_ok; then
5121   :
5122 else
5123   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
5124 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5125 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
5126 See \`config.log' for more details." >&5
5127 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
5128 See \`config.log' for more details." >&2;}
5129    { (exit 1); exit 1; }; }; }
5130 fi
5131
5132 ac_ext=c
5133 ac_cpp='$CPP $CPPFLAGS'
5134 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5135 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5136 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5137
5138
5139
5140
5141 #
5142 # Set up TAS assembly code if needed; the template file has now had its
5143 # chance to request this.
5144 #
5145 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
5146
5147
5148 if test "$need_tas" = yes ; then
5149   TAS=tas.o
5150 else
5151   TAS=""
5152 fi
5153
5154
5155
5156 #
5157 # Automatic dependency tracking
5158 #
5159
5160
5161 # Check whether --enable-depend was given.
5162 if test "${enable_depend+set}" = set; then
5163   enableval=$enable_depend;
5164   case $enableval in
5165     yes)
5166       autodepend=yes
5167       ;;
5168     no)
5169       :
5170       ;;
5171     *)
5172       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
5173 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
5174    { (exit 1); exit 1; }; }
5175       ;;
5176   esac
5177
5178 else
5179   enable_depend=no
5180
5181 fi
5182
5183
5184
5185
5186
5187 #
5188 # Enable assert checks
5189 #
5190
5191
5192 # Check whether --enable-cassert was given.
5193 if test "${enable_cassert+set}" = set; then
5194   enableval=$enable_cassert;
5195   case $enableval in
5196     yes)
5197
5198 cat >>confdefs.h <<\_ACEOF
5199 #define USE_ASSERT_CHECKING 1
5200 _ACEOF
5201
5202       ;;
5203     no)
5204       :
5205       ;;
5206     *)
5207       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
5208 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
5209    { (exit 1); exit 1; }; }
5210       ;;
5211   esac
5212
5213 else
5214   enable_cassert=no
5215
5216 fi
5217
5218
5219
5220
5221 #
5222 # Include directories
5223 #
5224 ac_save_IFS=$IFS
5225 IFS="${IFS}${PATH_SEPARATOR}"
5226 # SRCH_INC comes from the template file
5227 for dir in $with_includes $SRCH_INC; do
5228   if test -d "$dir"; then
5229     INCLUDES="$INCLUDES -I$dir"
5230   else
5231     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
5232 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
5233   fi
5234 done
5235 IFS=$ac_save_IFS
5236
5237
5238
5239 #
5240 # Library directories
5241 #
5242 ac_save_IFS=$IFS
5243 IFS="${IFS}${PATH_SEPARATOR}"
5244 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
5245 for dir in $LIBRARY_DIRS $SRCH_LIB; do
5246   if test -d "$dir"; then
5247     LIBDIRS="$LIBDIRS -L$dir"
5248   else
5249     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
5250 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
5251   fi
5252 done
5253 IFS=$ac_save_IFS
5254
5255 #
5256 # Enable thread-safe client libraries
5257 #
5258 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
5259 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
5260
5261
5262 # Check whether --enable-thread-safety was given.
5263 if test "${enable_thread_safety+set}" = set; then
5264   enableval=$enable_thread_safety;
5265   case $enableval in
5266     yes)
5267       :
5268       ;;
5269     no)
5270       :
5271       ;;
5272     *)
5273       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
5274 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
5275    { (exit 1); exit 1; }; }
5276       ;;
5277   esac
5278
5279 else
5280   enable_thread_safety=yes
5281
5282 fi
5283
5284
5285 if test "$enable_thread_safety" = yes; then
5286
5287 cat >>confdefs.h <<\_ACEOF
5288 #define ENABLE_THREAD_SAFETY 1
5289 _ACEOF
5290
5291 fi
5292 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
5293 $as_echo "$enable_thread_safety" >&6; }
5294
5295
5296 #
5297 # Optionally build Tcl modules (PL/Tcl)
5298 #
5299 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
5300 $as_echo_n "checking whether to build with Tcl... " >&6; }
5301
5302
5303
5304 # Check whether --with-tcl was given.
5305 if test "${with_tcl+set}" = set; then
5306   withval=$with_tcl;
5307   case $withval in
5308     yes)
5309       :
5310       ;;
5311     no)
5312       :
5313       ;;
5314     *)
5315       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
5316 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
5317    { (exit 1); exit 1; }; }
5318       ;;
5319   esac
5320
5321 else
5322   with_tcl=no
5323
5324 fi
5325
5326
5327 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
5328 $as_echo "$with_tcl" >&6; }
5329
5330
5331 # We see if the path to the Tcl/Tk configuration scripts is specified.
5332 # This will override the use of tclsh to find the paths to search.
5333
5334
5335
5336
5337 # Check whether --with-tclconfig was given.
5338 if test "${with_tclconfig+set}" = set; then
5339   withval=$with_tclconfig;
5340   case $withval in
5341     yes)
5342       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5343 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5344    { (exit 1); exit 1; }; }
5345       ;;
5346     no)
5347       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5348 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5349    { (exit 1); exit 1; }; }
5350       ;;
5351     *)
5352
5353       ;;
5354   esac
5355
5356 fi
5357
5358
5359
5360 #
5361 # Optionally build Perl modules (PL/Perl)
5362 #
5363 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
5364 $as_echo_n "checking whether to build Perl modules... " >&6; }
5365
5366
5367
5368 # Check whether --with-perl was given.
5369 if test "${with_perl+set}" = set; then
5370   withval=$with_perl;
5371   case $withval in
5372     yes)
5373       :
5374       ;;
5375     no)
5376       :
5377       ;;
5378     *)
5379       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
5380 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
5381    { (exit 1); exit 1; }; }
5382       ;;
5383   esac
5384
5385 else
5386   with_perl=no
5387
5388 fi
5389
5390
5391 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
5392 $as_echo "$with_perl" >&6; }
5393
5394
5395 #
5396 # Optionally build Python modules (PL/Python)
5397 #
5398 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
5399 $as_echo_n "checking whether to build Python modules... " >&6; }
5400
5401
5402
5403 # Check whether --with-python was given.
5404 if test "${with_python+set}" = set; then
5405   withval=$with_python;
5406   case $withval in
5407     yes)
5408       :
5409       ;;
5410     no)
5411       :
5412       ;;
5413     *)
5414       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5415 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5416    { (exit 1); exit 1; }; }
5417       ;;
5418   esac
5419
5420 else
5421   with_python=no
5422
5423 fi
5424
5425
5426 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5427 $as_echo "$with_python" >&6; }
5428
5429
5430 #
5431 # GSSAPI
5432 #
5433 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5434 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5435
5436
5437
5438 # Check whether --with-gssapi was given.
5439 if test "${with_gssapi+set}" = set; then
5440   withval=$with_gssapi;
5441   case $withval in
5442     yes)
5443
5444
5445 cat >>confdefs.h <<\_ACEOF
5446 #define ENABLE_GSS 1
5447 _ACEOF
5448
5449   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5450
5451       ;;
5452     no)
5453       :
5454       ;;
5455     *)
5456       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5457 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5458    { (exit 1); exit 1; }; }
5459       ;;
5460   esac
5461
5462 else
5463   with_gssapi=no
5464
5465 fi
5466
5467
5468 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5469 $as_echo "$with_gssapi" >&6; }
5470
5471 #
5472 # Kerberos 5
5473 #
5474 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5475 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5476
5477
5478
5479 # Check whether --with-krb5 was given.
5480 if test "${with_krb5+set}" = set; then
5481   withval=$with_krb5;
5482   case $withval in
5483     yes)
5484
5485
5486 cat >>confdefs.h <<\_ACEOF
5487 #define KRB5 1
5488 _ACEOF
5489
5490   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5491
5492       ;;
5493     no)
5494       :
5495       ;;
5496     *)
5497       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5498 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5499    { (exit 1); exit 1; }; }
5500       ;;
5501   esac
5502
5503 else
5504   with_krb5=no
5505
5506 fi
5507
5508
5509 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5510 $as_echo "$with_krb5" >&6; }
5511
5512
5513
5514
5515
5516 #
5517 # Kerberos configuration parameters
5518 #
5519
5520
5521
5522 # Check whether --with-krb-srvnam was given.
5523 if test "${with_krb_srvnam+set}" = set; then
5524   withval=$with_krb_srvnam;
5525   case $withval in
5526     yes)
5527       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5528 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5529    { (exit 1); exit 1; }; }
5530       ;;
5531     no)
5532       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5533 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5534    { (exit 1); exit 1; }; }
5535       ;;
5536     *)
5537
5538       ;;
5539   esac
5540
5541 else
5542   with_krb_srvnam="postgres"
5543 fi
5544
5545
5546
5547 cat >>confdefs.h <<_ACEOF
5548 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5549 _ACEOF
5550
5551
5552
5553 #
5554 # PAM
5555 #
5556 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5557 $as_echo_n "checking whether to build with PAM support... " >&6; }
5558
5559
5560
5561 # Check whether --with-pam was given.
5562 if test "${with_pam+set}" = set; then
5563   withval=$with_pam;
5564   case $withval in
5565     yes)
5566
5567 cat >>confdefs.h <<\_ACEOF
5568 #define USE_PAM 1
5569 _ACEOF
5570
5571       ;;
5572     no)
5573       :
5574       ;;
5575     *)
5576       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5577 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5578    { (exit 1); exit 1; }; }
5579       ;;
5580   esac
5581
5582 else
5583   with_pam=no
5584
5585 fi
5586
5587
5588 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5589 $as_echo "$with_pam" >&6; }
5590
5591
5592 #
5593 # LDAP
5594 #
5595 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5596 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5597
5598
5599
5600 # Check whether --with-ldap was given.
5601 if test "${with_ldap+set}" = set; then
5602   withval=$with_ldap;
5603   case $withval in
5604     yes)
5605
5606 cat >>confdefs.h <<\_ACEOF
5607 #define USE_LDAP 1
5608 _ACEOF
5609
5610       ;;
5611     no)
5612       :
5613       ;;
5614     *)
5615       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5616 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5617    { (exit 1); exit 1; }; }
5618       ;;
5619   esac
5620
5621 else
5622   with_ldap=no
5623
5624 fi
5625
5626
5627 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5628 $as_echo "$with_ldap" >&6; }
5629
5630
5631 #
5632 # Bonjour
5633 #
5634 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5635 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5636
5637
5638
5639 # Check whether --with-bonjour was given.
5640 if test "${with_bonjour+set}" = set; then
5641   withval=$with_bonjour;
5642   case $withval in
5643     yes)
5644
5645 cat >>confdefs.h <<\_ACEOF
5646 #define USE_BONJOUR 1
5647 _ACEOF
5648
5649       ;;
5650     no)
5651       :
5652       ;;
5653     *)
5654       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5655 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5656    { (exit 1); exit 1; }; }
5657       ;;
5658   esac
5659
5660 else
5661   with_bonjour=no
5662
5663 fi
5664
5665
5666 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5667 $as_echo "$with_bonjour" >&6; }
5668
5669
5670 #
5671 # OpenSSL
5672 #
5673 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5674 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5675
5676
5677
5678 # Check whether --with-openssl was given.
5679 if test "${with_openssl+set}" = set; then
5680   withval=$with_openssl;
5681   case $withval in
5682     yes)
5683
5684 cat >>confdefs.h <<\_ACEOF
5685 #define USE_SSL 1
5686 _ACEOF
5687
5688       ;;
5689     no)
5690       :
5691       ;;
5692     *)
5693       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5694 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5695    { (exit 1); exit 1; }; }
5696       ;;
5697   esac
5698
5699 else
5700   with_openssl=no
5701
5702 fi
5703
5704
5705 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5706 $as_echo "$with_openssl" >&6; }
5707
5708
5709 #
5710 # SELinux
5711 #
5712 { $as_echo "$as_me:$LINENO: checking whether to build with SELinux support" >&5
5713 $as_echo_n "checking whether to build with SELinux support... " >&6; }
5714
5715
5716
5717 # Check whether --with-selinux was given.
5718 if test "${with_selinux+set}" = set; then
5719   withval=$with_selinux;
5720   case $withval in
5721     yes)
5722       :
5723       ;;
5724     no)
5725       :
5726       ;;
5727     *)
5728       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-selinux option" >&5
5729 $as_echo "$as_me: error: no argument expected for --with-selinux option" >&2;}
5730    { (exit 1); exit 1; }; }
5731       ;;
5732   esac
5733
5734 else
5735   with_selinux=no
5736
5737 fi
5738
5739
5740
5741 { $as_echo "$as_me:$LINENO: result: $with_selinux" >&5
5742 $as_echo "$with_selinux" >&6; }
5743
5744 #
5745 # Readline
5746 #
5747
5748
5749
5750 # Check whether --with-readline was given.
5751 if test "${with_readline+set}" = set; then
5752   withval=$with_readline;
5753   case $withval in
5754     yes)
5755       :
5756       ;;
5757     no)
5758       :
5759       ;;
5760     *)
5761       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5762 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5763    { (exit 1); exit 1; }; }
5764       ;;
5765   esac
5766
5767 else
5768   with_readline=yes
5769
5770 fi
5771
5772
5773 # readline on MinGW has problems with backslashes in psql and other bugs.
5774 # This is particularly a problem with non-US code pages.
5775 # Therefore disable its use until we understand the cause. 2004-07-20
5776 if test "$PORTNAME" = "win32"; then
5777   if test "$with_readline" = yes; then
5778     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5779 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5780     with_readline=no
5781   fi
5782 fi
5783
5784
5785 #
5786 # Prefer libedit
5787 #
5788
5789
5790
5791 # Check whether --with-libedit-preferred was given.
5792 if test "${with_libedit_preferred+set}" = set; then
5793   withval=$with_libedit_preferred;
5794   case $withval in
5795     yes)
5796       :
5797       ;;
5798     no)
5799       :
5800       ;;
5801     *)
5802       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5803 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5804    { (exit 1); exit 1; }; }
5805       ;;
5806   esac
5807
5808 else
5809   with_libedit_preferred=no
5810
5811 fi
5812
5813
5814
5815
5816 #
5817 # OSSP UUID library
5818 #
5819
5820
5821
5822 # Check whether --with-ossp-uuid was given.
5823 if test "${with_ossp_uuid+set}" = set; then
5824   withval=$with_ossp_uuid;
5825   case $withval in
5826     yes)
5827       :
5828       ;;
5829     no)
5830       :
5831       ;;
5832     *)
5833       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5834 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5835    { (exit 1); exit 1; }; }
5836       ;;
5837   esac
5838
5839 else
5840   with_ossp_uuid=no
5841
5842 fi
5843
5844
5845
5846
5847
5848 #
5849 # XML
5850 #
5851
5852
5853
5854 # Check whether --with-libxml was given.
5855 if test "${with_libxml+set}" = set; then
5856   withval=$with_libxml;
5857   case $withval in
5858     yes)
5859
5860 cat >>confdefs.h <<\_ACEOF
5861 #define USE_LIBXML 1
5862 _ACEOF
5863
5864       ;;
5865     no)
5866       :
5867       ;;
5868     *)
5869       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5870 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5871    { (exit 1); exit 1; }; }
5872       ;;
5873   esac
5874
5875 else
5876   with_libxml=no
5877
5878 fi
5879
5880
5881
5882 if test "$with_libxml" = yes ; then
5883   for ac_prog in xml2-config
5884 do
5885   # Extract the first word of "$ac_prog", so it can be a program name with args.
5886 set dummy $ac_prog; ac_word=$2
5887 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5888 $as_echo_n "checking for $ac_word... " >&6; }
5889 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5890   $as_echo_n "(cached) " >&6
5891 else
5892   if test -n "$XML2_CONFIG"; then
5893   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5894 else
5895 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5896 for as_dir in $PATH
5897 do
5898   IFS=$as_save_IFS
5899   test -z "$as_dir" && as_dir=.
5900   for ac_exec_ext in '' $ac_executable_extensions; do
5901   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5902     ac_cv_prog_XML2_CONFIG="$ac_prog"
5903     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5904     break 2
5905   fi
5906 done
5907 done
5908 IFS=$as_save_IFS
5909
5910 fi
5911 fi
5912 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5913 if test -n "$XML2_CONFIG"; then
5914   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5915 $as_echo "$XML2_CONFIG" >&6; }
5916 else
5917   { $as_echo "$as_me:$LINENO: result: no" >&5
5918 $as_echo "no" >&6; }
5919 fi
5920
5921
5922   test -n "$XML2_CONFIG" && break
5923 done
5924
5925   if test -n "$XML2_CONFIG"; then
5926     for pgac_option in `$XML2_CONFIG --cflags`; do
5927       case $pgac_option in
5928         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5929       esac
5930     done
5931     for pgac_option in `$XML2_CONFIG --libs`; do
5932       case $pgac_option in
5933         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5934       esac
5935     done
5936   fi
5937 fi
5938
5939
5940
5941 #
5942 # XSLT
5943 #
5944
5945
5946
5947 # Check whether --with-libxslt was given.
5948 if test "${with_libxslt+set}" = set; then
5949   withval=$with_libxslt;
5950   case $withval in
5951     yes)
5952
5953 cat >>confdefs.h <<\_ACEOF
5954 #define USE_LIBXSLT 1
5955 _ACEOF
5956
5957       ;;
5958     no)
5959       :
5960       ;;
5961     *)
5962       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5963 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5964    { (exit 1); exit 1; }; }
5965       ;;
5966   esac
5967
5968 else
5969   with_libxslt=no
5970
5971 fi
5972
5973
5974
5975
5976
5977
5978 #
5979 # tzdata
5980 #
5981
5982
5983
5984 # Check whether --with-system-tzdata was given.
5985 if test "${with_system_tzdata+set}" = set; then
5986   withval=$with_system_tzdata;
5987   case $withval in
5988     yes)
5989       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5990 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5991    { (exit 1); exit 1; }; }
5992       ;;
5993     no)
5994       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5995 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5996    { (exit 1); exit 1; }; }
5997       ;;
5998     *)
5999
6000       ;;
6001   esac
6002
6003 fi
6004
6005
6006
6007
6008 #
6009 # Zlib
6010 #
6011
6012
6013
6014 # Check whether --with-zlib was given.
6015 if test "${with_zlib+set}" = set; then
6016   withval=$with_zlib;
6017   case $withval in
6018     yes)
6019       :
6020       ;;
6021     no)
6022       :
6023       ;;
6024     *)
6025       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
6026 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
6027    { (exit 1); exit 1; }; }
6028       ;;
6029   esac
6030
6031 else
6032   with_zlib=yes
6033
6034 fi
6035
6036
6037
6038
6039 #
6040 # Elf
6041 #
6042
6043 # Assume system is ELF if it predefines __ELF__ as 1,
6044 # otherwise believe host_os based default.
6045 case $host_os in
6046     freebsd1*|freebsd2*) elf=no;;
6047     freebsd3*|freebsd4*) elf=yes;;
6048 esac
6049
6050
6051 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
6052 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6053 if test "${ac_cv_path_GREP+set}" = set; then
6054   $as_echo_n "(cached) " >&6
6055 else
6056   if test -z "$GREP"; then
6057   ac_path_GREP_found=false
6058   # Loop through the user's path and test for each of PROGNAME-LIST
6059   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6060 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6061 do
6062   IFS=$as_save_IFS
6063   test -z "$as_dir" && as_dir=.
6064   for ac_prog in grep ggrep; do
6065     for ac_exec_ext in '' $ac_executable_extensions; do
6066       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6067       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6068 # Check for GNU ac_path_GREP and select it if it is found.
6069   # Check for GNU $ac_path_GREP
6070 case `"$ac_path_GREP" --version 2>&1` in
6071 *GNU*)
6072   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6073 *)
6074   ac_count=0
6075   $as_echo_n 0123456789 >"conftest.in"
6076   while :
6077   do
6078     cat "conftest.in" "conftest.in" >"conftest.tmp"
6079     mv "conftest.tmp" "conftest.in"
6080     cp "conftest.in" "conftest.nl"
6081     $as_echo 'GREP' >> "conftest.nl"
6082     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6083     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6084     ac_count=`expr $ac_count + 1`
6085     if test $ac_count -gt ${ac_path_GREP_max-0}; then
6086       # Best one so far, save it but keep looking for a better one
6087       ac_cv_path_GREP="$ac_path_GREP"
6088       ac_path_GREP_max=$ac_count
6089     fi
6090     # 10*(2^10) chars as input seems more than enough
6091     test $ac_count -gt 10 && break
6092   done
6093   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6094 esac
6095
6096       $ac_path_GREP_found && break 3
6097     done
6098   done
6099 done
6100 IFS=$as_save_IFS
6101   if test -z "$ac_cv_path_GREP"; then
6102     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
6103 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
6104    { (exit 1); exit 1; }; }
6105   fi
6106 else
6107   ac_cv_path_GREP=$GREP
6108 fi
6109
6110 fi
6111 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
6112 $as_echo "$ac_cv_path_GREP" >&6; }
6113  GREP="$ac_cv_path_GREP"
6114
6115
6116 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
6117 $as_echo_n "checking for egrep... " >&6; }
6118 if test "${ac_cv_path_EGREP+set}" = set; then
6119   $as_echo_n "(cached) " >&6
6120 else
6121   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6122    then ac_cv_path_EGREP="$GREP -E"
6123    else
6124      if test -z "$EGREP"; then
6125   ac_path_EGREP_found=false
6126   # Loop through the user's path and test for each of PROGNAME-LIST
6127   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6128 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6129 do
6130   IFS=$as_save_IFS
6131   test -z "$as_dir" && as_dir=.
6132   for ac_prog in egrep; do
6133     for ac_exec_ext in '' $ac_executable_extensions; do
6134       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6135       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6136 # Check for GNU ac_path_EGREP and select it if it is found.
6137   # Check for GNU $ac_path_EGREP
6138 case `"$ac_path_EGREP" --version 2>&1` in
6139 *GNU*)
6140   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6141 *)
6142   ac_count=0
6143   $as_echo_n 0123456789 >"conftest.in"
6144   while :
6145   do
6146     cat "conftest.in" "conftest.in" >"conftest.tmp"
6147     mv "conftest.tmp" "conftest.in"
6148     cp "conftest.in" "conftest.nl"
6149     $as_echo 'EGREP' >> "conftest.nl"
6150     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6151     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6152     ac_count=`expr $ac_count + 1`
6153     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6154       # Best one so far, save it but keep looking for a better one
6155       ac_cv_path_EGREP="$ac_path_EGREP"
6156       ac_path_EGREP_max=$ac_count
6157     fi
6158     # 10*(2^10) chars as input seems more than enough
6159     test $ac_count -gt 10 && break
6160   done
6161   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6162 esac
6163
6164       $ac_path_EGREP_found && break 3
6165     done
6166   done
6167 done
6168 IFS=$as_save_IFS
6169   if test -z "$ac_cv_path_EGREP"; then
6170     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
6171 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
6172    { (exit 1); exit 1; }; }
6173   fi
6174 else
6175   ac_cv_path_EGREP=$EGREP
6176 fi
6177
6178    fi
6179 fi
6180 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
6181 $as_echo "$ac_cv_path_EGREP" >&6; }
6182  EGREP="$ac_cv_path_EGREP"
6183
6184
6185 cat >conftest.$ac_ext <<_ACEOF
6186 /* confdefs.h.  */
6187 _ACEOF
6188 cat confdefs.h >>conftest.$ac_ext
6189 cat >>conftest.$ac_ext <<_ACEOF
6190 /* end confdefs.h.  */
6191 #if __ELF__
6192   yes
6193 #endif
6194
6195 _ACEOF
6196 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6197   $EGREP "yes" >/dev/null 2>&1; then
6198   ELF_SYS=true
6199 else
6200   if test "X$elf" = "Xyes" ; then
6201   ELF_SYS=true
6202 else
6203   ELF_SYS=
6204 fi
6205 fi
6206 rm -f conftest*
6207
6208
6209
6210 #
6211 # Assignments
6212 #
6213
6214 CPPFLAGS="$CPPFLAGS $INCLUDES"
6215 LDFLAGS="$LDFLAGS $LIBDIRS"
6216
6217
6218
6219
6220
6221 # Check whether --with-gnu-ld was given.
6222 if test "${with_gnu_ld+set}" = set; then
6223   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
6224 else
6225   with_gnu_ld=no
6226 fi
6227
6228 ac_prog=ld
6229 if test "$GCC" = yes; then
6230   # Check if gcc -print-prog-name=ld gives a path.
6231   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
6232 $as_echo_n "checking for ld used by GCC... " >&6; }
6233   case $host in
6234   *-*-mingw*)
6235     # gcc leaves a trailing carriage return which upsets mingw
6236     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
6237   *)
6238     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
6239   esac
6240   case "$ac_prog" in
6241     # Accept absolute paths.
6242     [\\/]* | [A-Za-z]:[\\/]*)
6243       re_direlt='/[^/][^/]*/\.\./'
6244       # Canonicalize the path of ld
6245       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
6246       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
6247         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
6248       done
6249       test -z "$LD" && LD="$ac_prog"
6250       ;;
6251   "")
6252     # If it fails, then pretend we aren't using GCC.
6253     ac_prog=ld
6254     ;;
6255   *)
6256     # If it is relative, then search for the first ld in PATH.
6257     with_gnu_ld=unknown
6258     ;;
6259   esac
6260 elif test "$with_gnu_ld" = yes; then
6261   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
6262 $as_echo_n "checking for GNU ld... " >&6; }
6263 else
6264   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
6265 $as_echo_n "checking for non-GNU ld... " >&6; }
6266 fi
6267 if test "${ac_cv_path_LD+set}" = set; then
6268   $as_echo_n "(cached) " >&6
6269 else
6270   if test -z "$LD"; then
6271   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
6272   for ac_dir in $PATH; do
6273     test -z "$ac_dir" && ac_dir=.
6274     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
6275       ac_cv_path_LD="$ac_dir/$ac_prog"
6276       # Check to see if the program is GNU ld.  I'd rather use --version,
6277       # but apparently some GNU ld's only accept -v.
6278       # Break only if it was the GNU/non-GNU ld that we prefer.
6279       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
6280         test "$with_gnu_ld" != no && break
6281       else
6282         test "$with_gnu_ld" != yes && break
6283       fi
6284     fi
6285   done
6286   IFS="$ac_save_ifs"
6287 else
6288   ac_cv_path_LD="$LD" # Let the user override the test with a path.
6289 fi
6290 fi
6291
6292 LD="$ac_cv_path_LD"
6293 if test -n "$LD"; then
6294   { $as_echo "$as_me:$LINENO: result: $LD" >&5
6295 $as_echo "$LD" >&6; }
6296 else
6297   { $as_echo "$as_me:$LINENO: result: no" >&5
6298 $as_echo "no" >&6; }
6299 fi
6300 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
6301 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
6302    { (exit 1); exit 1; }; }
6303 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
6304 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
6305 if test "${ac_cv_prog_gnu_ld+set}" = set; then
6306   $as_echo_n "(cached) " >&6
6307 else
6308   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
6309 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
6310   ac_cv_prog_gnu_ld=yes
6311 else
6312   ac_cv_prog_gnu_ld=no
6313 fi
6314 fi
6315 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
6316 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
6317 with_gnu_ld=$ac_cv_prog_gnu_ld
6318
6319
6320
6321
6322 case $host_os in sysv5*)
6323   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
6324 $as_echo_n "checking whether ld -R works... " >&6; }
6325 if test "${pgac_cv_prog_ld_R+set}" = set; then
6326   $as_echo_n "(cached) " >&6
6327 else
6328
6329     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
6330     cat >conftest.$ac_ext <<_ACEOF
6331 /* confdefs.h.  */
6332 _ACEOF
6333 cat confdefs.h >>conftest.$ac_ext
6334 cat >>conftest.$ac_ext <<_ACEOF
6335 /* end confdefs.h.  */
6336
6337 int
6338 main ()
6339 {
6340
6341   ;
6342   return 0;
6343 }
6344 _ACEOF
6345 rm -f conftest.$ac_objext conftest$ac_exeext
6346 if { (ac_try="$ac_link"
6347 case "(($ac_try" in
6348   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6349   *) ac_try_echo=$ac_try;;
6350 esac
6351 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6352 $as_echo "$ac_try_echo") >&5
6353   (eval "$ac_link") 2>conftest.er1
6354   ac_status=$?
6355   grep -v '^ *+' conftest.er1 >conftest.err
6356   rm -f conftest.er1
6357   cat conftest.err >&5
6358   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6359   (exit $ac_status); } && {
6360          test -z "$ac_c_werror_flag" ||
6361          test ! -s conftest.err
6362        } && test -s conftest$ac_exeext && {
6363          test "$cross_compiling" = yes ||
6364          $as_test_x conftest$ac_exeext
6365        }; then
6366   pgac_cv_prog_ld_R=yes
6367 else
6368   $as_echo "$as_me: failed program was:" >&5
6369 sed 's/^/| /' conftest.$ac_ext >&5
6370
6371         pgac_cv_prog_ld_R=no
6372 fi
6373
6374 rm -rf conftest.dSYM
6375 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6376       conftest$ac_exeext conftest.$ac_ext
6377     LDFLAGS=$pgac_save_LDFLAGS
6378
6379 fi
6380 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
6381 $as_echo "$pgac_cv_prog_ld_R" >&6; }
6382   ld_R_works=$pgac_cv_prog_ld_R
6383
6384 esac
6385 if test -n "$ac_tool_prefix"; then
6386   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6387 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6388 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6389 $as_echo_n "checking for $ac_word... " >&6; }
6390 if test "${ac_cv_prog_RANLIB+set}" = set; then
6391   $as_echo_n "(cached) " >&6
6392 else
6393   if test -n "$RANLIB"; then
6394   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6395 else
6396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6397 for as_dir in $PATH
6398 do
6399   IFS=$as_save_IFS
6400   test -z "$as_dir" && as_dir=.
6401   for ac_exec_ext in '' $ac_executable_extensions; do
6402   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6403     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6404     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6405     break 2
6406   fi
6407 done
6408 done
6409 IFS=$as_save_IFS
6410
6411 fi
6412 fi
6413 RANLIB=$ac_cv_prog_RANLIB
6414 if test -n "$RANLIB"; then
6415   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
6416 $as_echo "$RANLIB" >&6; }
6417 else
6418   { $as_echo "$as_me:$LINENO: result: no" >&5
6419 $as_echo "no" >&6; }
6420 fi
6421
6422
6423 fi
6424 if test -z "$ac_cv_prog_RANLIB"; then
6425   ac_ct_RANLIB=$RANLIB
6426   # Extract the first word of "ranlib", so it can be a program name with args.
6427 set dummy ranlib; ac_word=$2
6428 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6429 $as_echo_n "checking for $ac_word... " >&6; }
6430 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6431   $as_echo_n "(cached) " >&6
6432 else
6433   if test -n "$ac_ct_RANLIB"; then
6434   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6435 else
6436 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6437 for as_dir in $PATH
6438 do
6439   IFS=$as_save_IFS
6440   test -z "$as_dir" && as_dir=.
6441   for ac_exec_ext in '' $ac_executable_extensions; do
6442   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6443     ac_cv_prog_ac_ct_RANLIB="ranlib"
6444     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6445     break 2
6446   fi
6447 done
6448 done
6449 IFS=$as_save_IFS
6450
6451 fi
6452 fi
6453 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6454 if test -n "$ac_ct_RANLIB"; then
6455   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6456 $as_echo "$ac_ct_RANLIB" >&6; }
6457 else
6458   { $as_echo "$as_me:$LINENO: result: no" >&5
6459 $as_echo "no" >&6; }
6460 fi
6461
6462   if test "x$ac_ct_RANLIB" = x; then
6463     RANLIB=":"
6464   else
6465     case $cross_compiling:$ac_tool_warned in
6466 yes:)
6467 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6468 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6469 ac_tool_warned=yes ;;
6470 esac
6471     RANLIB=$ac_ct_RANLIB
6472   fi
6473 else
6474   RANLIB="$ac_cv_prog_RANLIB"
6475 fi
6476
6477
6478   if test -n "$ac_tool_prefix"; then
6479   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6480 set dummy ${ac_tool_prefix}strip; ac_word=$2
6481 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6482 $as_echo_n "checking for $ac_word... " >&6; }
6483 if test "${ac_cv_prog_STRIP+set}" = set; then
6484   $as_echo_n "(cached) " >&6
6485 else
6486   if test -n "$STRIP"; then
6487   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6488 else
6489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6490 for as_dir in $PATH
6491 do
6492   IFS=$as_save_IFS
6493   test -z "$as_dir" && as_dir=.
6494   for ac_exec_ext in '' $ac_executable_extensions; do
6495   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6496     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6497     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6498     break 2
6499   fi
6500 done
6501 done
6502 IFS=$as_save_IFS
6503
6504 fi
6505 fi
6506 STRIP=$ac_cv_prog_STRIP
6507 if test -n "$STRIP"; then
6508   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6509 $as_echo "$STRIP" >&6; }
6510 else
6511   { $as_echo "$as_me:$LINENO: result: no" >&5
6512 $as_echo "no" >&6; }
6513 fi
6514
6515
6516 fi
6517 if test -z "$ac_cv_prog_STRIP"; then
6518   ac_ct_STRIP=$STRIP
6519   # Extract the first word of "strip", so it can be a program name with args.
6520 set dummy strip; ac_word=$2
6521 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6522 $as_echo_n "checking for $ac_word... " >&6; }
6523 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6524   $as_echo_n "(cached) " >&6
6525 else
6526   if test -n "$ac_ct_STRIP"; then
6527   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6528 else
6529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6530 for as_dir in $PATH
6531 do
6532   IFS=$as_save_IFS
6533   test -z "$as_dir" && as_dir=.
6534   for ac_exec_ext in '' $ac_executable_extensions; do
6535   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6536     ac_cv_prog_ac_ct_STRIP="strip"
6537     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6538     break 2
6539   fi
6540 done
6541 done
6542 IFS=$as_save_IFS
6543
6544 fi
6545 fi
6546 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6547 if test -n "$ac_ct_STRIP"; then
6548   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6549 $as_echo "$ac_ct_STRIP" >&6; }
6550 else
6551   { $as_echo "$as_me:$LINENO: result: no" >&5
6552 $as_echo "no" >&6; }
6553 fi
6554
6555   if test "x$ac_ct_STRIP" = x; then
6556     STRIP=":"
6557   else
6558     case $cross_compiling:$ac_tool_warned in
6559 yes:)
6560 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6561 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6562 ac_tool_warned=yes ;;
6563 esac
6564     STRIP=$ac_ct_STRIP
6565   fi
6566 else
6567   STRIP="$ac_cv_prog_STRIP"
6568 fi
6569
6570
6571   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6572 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6573   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6574     STRIP_STATIC_LIB="$STRIP -x"
6575     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6576     { $as_echo "$as_me:$LINENO: result: yes" >&5
6577 $as_echo "yes" >&6; }
6578   else
6579     case $host_os in
6580       darwin*)
6581         STRIP="$STRIP -x"
6582         STRIP_STATIC_LIB=$STRIP
6583         STRIP_SHARED_LIB=$STRIP
6584         { $as_echo "$as_me:$LINENO: result: yes" >&5
6585 $as_echo "yes" >&6; }
6586         ;;
6587       *)
6588         STRIP_STATIC_LIB=:
6589         STRIP_SHARED_LIB=:
6590         { $as_echo "$as_me:$LINENO: result: no" >&5
6591 $as_echo "no" >&6; }
6592         ;;
6593     esac
6594   fi
6595
6596
6597
6598 if test -n "$ac_tool_prefix"; then
6599   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6600 set dummy ${ac_tool_prefix}ar; ac_word=$2
6601 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6602 $as_echo_n "checking for $ac_word... " >&6; }
6603 if test "${ac_cv_prog_AR+set}" = set; then
6604   $as_echo_n "(cached) " >&6
6605 else
6606   if test -n "$AR"; then
6607   ac_cv_prog_AR="$AR" # Let the user override the test.
6608 else
6609 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6610 for as_dir in $PATH
6611 do
6612   IFS=$as_save_IFS
6613   test -z "$as_dir" && as_dir=.
6614   for ac_exec_ext in '' $ac_executable_extensions; do
6615   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6616     ac_cv_prog_AR="${ac_tool_prefix}ar"
6617     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6618     break 2
6619   fi
6620 done
6621 done
6622 IFS=$as_save_IFS
6623
6624 fi
6625 fi
6626 AR=$ac_cv_prog_AR
6627 if test -n "$AR"; then
6628   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6629 $as_echo "$AR" >&6; }
6630 else
6631   { $as_echo "$as_me:$LINENO: result: no" >&5
6632 $as_echo "no" >&6; }
6633 fi
6634
6635
6636 fi
6637 if test -z "$ac_cv_prog_AR"; then
6638   ac_ct_AR=$AR
6639   # Extract the first word of "ar", so it can be a program name with args.
6640 set dummy ar; ac_word=$2
6641 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6642 $as_echo_n "checking for $ac_word... " >&6; }
6643 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6644   $as_echo_n "(cached) " >&6
6645 else
6646   if test -n "$ac_ct_AR"; then
6647   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6648 else
6649 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6650 for as_dir in $PATH
6651 do
6652   IFS=$as_save_IFS
6653   test -z "$as_dir" && as_dir=.
6654   for ac_exec_ext in '' $ac_executable_extensions; do
6655   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6656     ac_cv_prog_ac_ct_AR="ar"
6657     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6658     break 2
6659   fi
6660 done
6661 done
6662 IFS=$as_save_IFS
6663
6664 fi
6665 fi
6666 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6667 if test -n "$ac_ct_AR"; then
6668   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6669 $as_echo "$ac_ct_AR" >&6; }
6670 else
6671   { $as_echo "$as_me:$LINENO: result: no" >&5
6672 $as_echo "no" >&6; }
6673 fi
6674
6675   if test "x$ac_ct_AR" = x; then
6676     AR="ar"
6677   else
6678     case $cross_compiling:$ac_tool_warned in
6679 yes:)
6680 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6681 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6682 ac_tool_warned=yes ;;
6683 esac
6684     AR=$ac_ct_AR
6685   fi
6686 else
6687   AR="$ac_cv_prog_AR"
6688 fi
6689
6690 if test "$PORTNAME" = "win32"; then
6691   if test -n "$ac_tool_prefix"; then
6692   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6693 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6694 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6695 $as_echo_n "checking for $ac_word... " >&6; }
6696 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6697   $as_echo_n "(cached) " >&6
6698 else
6699   if test -n "$DLLTOOL"; then
6700   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6701 else
6702 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6703 for as_dir in $PATH
6704 do
6705   IFS=$as_save_IFS
6706   test -z "$as_dir" && as_dir=.
6707   for ac_exec_ext in '' $ac_executable_extensions; do
6708   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6709     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6710     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6711     break 2
6712   fi
6713 done
6714 done
6715 IFS=$as_save_IFS
6716
6717 fi
6718 fi
6719 DLLTOOL=$ac_cv_prog_DLLTOOL
6720 if test -n "$DLLTOOL"; then
6721   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6722 $as_echo "$DLLTOOL" >&6; }
6723 else
6724   { $as_echo "$as_me:$LINENO: result: no" >&5
6725 $as_echo "no" >&6; }
6726 fi
6727
6728
6729 fi
6730 if test -z "$ac_cv_prog_DLLTOOL"; then
6731   ac_ct_DLLTOOL=$DLLTOOL
6732   # Extract the first word of "dlltool", so it can be a program name with args.
6733 set dummy dlltool; ac_word=$2
6734 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6735 $as_echo_n "checking for $ac_word... " >&6; }
6736 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6737   $as_echo_n "(cached) " >&6
6738 else
6739   if test -n "$ac_ct_DLLTOOL"; then
6740   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6741 else
6742 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6743 for as_dir in $PATH
6744 do
6745   IFS=$as_save_IFS
6746   test -z "$as_dir" && as_dir=.
6747   for ac_exec_ext in '' $ac_executable_extensions; do
6748   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6749     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6750     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6751     break 2
6752   fi
6753 done
6754 done
6755 IFS=$as_save_IFS
6756
6757 fi
6758 fi
6759 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6760 if test -n "$ac_ct_DLLTOOL"; then
6761   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6762 $as_echo "$ac_ct_DLLTOOL" >&6; }
6763 else
6764   { $as_echo "$as_me:$LINENO: result: no" >&5
6765 $as_echo "no" >&6; }
6766 fi
6767
6768   if test "x$ac_ct_DLLTOOL" = x; then
6769     DLLTOOL="dlltool"
6770   else
6771     case $cross_compiling:$ac_tool_warned in
6772 yes:)
6773 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6774 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6775 ac_tool_warned=yes ;;
6776 esac
6777     DLLTOOL=$ac_ct_DLLTOOL
6778   fi
6779 else
6780   DLLTOOL="$ac_cv_prog_DLLTOOL"
6781 fi
6782
6783   if test -n "$ac_tool_prefix"; then
6784   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6785 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6786 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6787 $as_echo_n "checking for $ac_word... " >&6; }
6788 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6789   $as_echo_n "(cached) " >&6
6790 else
6791   if test -n "$DLLWRAP"; then
6792   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6793 else
6794 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6795 for as_dir in $PATH
6796 do
6797   IFS=$as_save_IFS
6798   test -z "$as_dir" && as_dir=.
6799   for ac_exec_ext in '' $ac_executable_extensions; do
6800   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6801     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6802     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6803     break 2
6804   fi
6805 done
6806 done
6807 IFS=$as_save_IFS
6808
6809 fi
6810 fi
6811 DLLWRAP=$ac_cv_prog_DLLWRAP
6812 if test -n "$DLLWRAP"; then
6813   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6814 $as_echo "$DLLWRAP" >&6; }
6815 else
6816   { $as_echo "$as_me:$LINENO: result: no" >&5
6817 $as_echo "no" >&6; }
6818 fi
6819
6820
6821 fi
6822 if test -z "$ac_cv_prog_DLLWRAP"; then
6823   ac_ct_DLLWRAP=$DLLWRAP
6824   # Extract the first word of "dllwrap", so it can be a program name with args.
6825 set dummy dllwrap; ac_word=$2
6826 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6827 $as_echo_n "checking for $ac_word... " >&6; }
6828 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6829   $as_echo_n "(cached) " >&6
6830 else
6831   if test -n "$ac_ct_DLLWRAP"; then
6832   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6833 else
6834 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6835 for as_dir in $PATH
6836 do
6837   IFS=$as_save_IFS
6838   test -z "$as_dir" && as_dir=.
6839   for ac_exec_ext in '' $ac_executable_extensions; do
6840   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6841     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6842     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6843     break 2
6844   fi
6845 done
6846 done
6847 IFS=$as_save_IFS
6848
6849 fi
6850 fi
6851 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6852 if test -n "$ac_ct_DLLWRAP"; then
6853   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6854 $as_echo "$ac_ct_DLLWRAP" >&6; }
6855 else
6856   { $as_echo "$as_me:$LINENO: result: no" >&5
6857 $as_echo "no" >&6; }
6858 fi
6859
6860   if test "x$ac_ct_DLLWRAP" = x; then
6861     DLLWRAP="dllwrap"
6862   else
6863     case $cross_compiling:$ac_tool_warned in
6864 yes:)
6865 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6866 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6867 ac_tool_warned=yes ;;
6868 esac
6869     DLLWRAP=$ac_ct_DLLWRAP
6870   fi
6871 else
6872   DLLWRAP="$ac_cv_prog_DLLWRAP"
6873 fi
6874
6875   if test -n "$ac_tool_prefix"; then
6876   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6877 set dummy ${ac_tool_prefix}windres; ac_word=$2
6878 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6879 $as_echo_n "checking for $ac_word... " >&6; }
6880 if test "${ac_cv_prog_WINDRES+set}" = set; then
6881   $as_echo_n "(cached) " >&6
6882 else
6883   if test -n "$WINDRES"; then
6884   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6885 else
6886 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6887 for as_dir in $PATH
6888 do
6889   IFS=$as_save_IFS
6890   test -z "$as_dir" && as_dir=.
6891   for ac_exec_ext in '' $ac_executable_extensions; do
6892   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6893     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6894     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6895     break 2
6896   fi
6897 done
6898 done
6899 IFS=$as_save_IFS
6900
6901 fi
6902 fi
6903 WINDRES=$ac_cv_prog_WINDRES
6904 if test -n "$WINDRES"; then
6905   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6906 $as_echo "$WINDRES" >&6; }
6907 else
6908   { $as_echo "$as_me:$LINENO: result: no" >&5
6909 $as_echo "no" >&6; }
6910 fi
6911
6912
6913 fi
6914 if test -z "$ac_cv_prog_WINDRES"; then
6915   ac_ct_WINDRES=$WINDRES
6916   # Extract the first word of "windres", so it can be a program name with args.
6917 set dummy windres; ac_word=$2
6918 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6919 $as_echo_n "checking for $ac_word... " >&6; }
6920 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6921   $as_echo_n "(cached) " >&6
6922 else
6923   if test -n "$ac_ct_WINDRES"; then
6924   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6925 else
6926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6927 for as_dir in $PATH
6928 do
6929   IFS=$as_save_IFS
6930   test -z "$as_dir" && as_dir=.
6931   for ac_exec_ext in '' $ac_executable_extensions; do
6932   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6933     ac_cv_prog_ac_ct_WINDRES="windres"
6934     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6935     break 2
6936   fi
6937 done
6938 done
6939 IFS=$as_save_IFS
6940
6941 fi
6942 fi
6943 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6944 if test -n "$ac_ct_WINDRES"; then
6945   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6946 $as_echo "$ac_ct_WINDRES" >&6; }
6947 else
6948   { $as_echo "$as_me:$LINENO: result: no" >&5
6949 $as_echo "no" >&6; }
6950 fi
6951
6952   if test "x$ac_ct_WINDRES" = x; then
6953     WINDRES="windres"
6954   else
6955     case $cross_compiling:$ac_tool_warned in
6956 yes:)
6957 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6958 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6959 ac_tool_warned=yes ;;
6960 esac
6961     WINDRES=$ac_ct_WINDRES
6962   fi
6963 else
6964   WINDRES="$ac_cv_prog_WINDRES"
6965 fi
6966
6967 fi
6968
6969 # Find a good install program.  We prefer a C program (faster),
6970 # so one script is as good as another.  But avoid the broken or
6971 # incompatible versions:
6972 # SysV /etc/install, /usr/sbin/install
6973 # SunOS /usr/etc/install
6974 # IRIX /sbin/install
6975 # AIX /bin/install
6976 # AmigaOS /C/install, which installs bootblocks on floppy discs
6977 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6978 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
6979 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6980 # OS/2's system install, which has a completely different semantic
6981 # ./install, which can be erroneously created by make from ./install.sh.
6982 # Reject install programs that cannot install multiple files.
6983 { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
6984 $as_echo_n "checking for a BSD-compatible install... " >&6; }
6985 if test -z "$INSTALL"; then
6986 if test "${ac_cv_path_install+set}" = set; then
6987   $as_echo_n "(cached) " >&6
6988 else
6989   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6990 for as_dir in $PATH
6991 do
6992   IFS=$as_save_IFS
6993   test -z "$as_dir" && as_dir=.
6994   # Account for people who put trailing slashes in PATH elements.
6995 case $as_dir/ in
6996   ./ | .// | /cC/* | \
6997   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
6998   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
6999   /usr/ucb/* ) ;;
7000   *)
7001     # OSF1 and SCO ODT 3.0 have their own names for install.
7002     # Don't use installbsd from OSF since it installs stuff as root
7003     # by default.
7004     for ac_prog in ginstall scoinst install; do
7005       for ac_exec_ext in '' $ac_executable_extensions; do
7006         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
7007           if test $ac_prog = install &&
7008             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7009             # AIX install.  It has an incompatible calling convention.
7010             :
7011           elif test $ac_prog = install &&
7012             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
7013             # program-specific install script used by HP pwplus--don't use.
7014             :
7015           else
7016             rm -rf conftest.one conftest.two conftest.dir
7017             echo one > conftest.one
7018             echo two > conftest.two
7019             mkdir conftest.dir
7020             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
7021               test -s conftest.one && test -s conftest.two &&
7022               test -s conftest.dir/conftest.one &&
7023               test -s conftest.dir/conftest.two
7024             then
7025               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
7026               break 3
7027             fi
7028           fi
7029         fi
7030       done
7031     done
7032     ;;
7033 esac
7034
7035 done
7036 IFS=$as_save_IFS
7037
7038 rm -rf conftest.one conftest.two conftest.dir
7039
7040 fi
7041   if test "${ac_cv_path_install+set}" = set; then
7042     INSTALL=$ac_cv_path_install
7043   else
7044     # As a last resort, use the slow shell script.  Don't cache a
7045     # value for INSTALL within a source directory, because that will
7046     # break other packages using the cache if that directory is
7047     # removed, or if the value is a relative name.
7048     INSTALL=$ac_install_sh
7049   fi
7050 fi
7051 { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
7052 $as_echo "$INSTALL" >&6; }
7053
7054 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
7055 # It thinks the first close brace ends the variable substitution.
7056 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
7057
7058 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
7059
7060 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
7061
7062 # When Autoconf chooses install-sh as install program it tries to generate
7063 # a relative path to it in each makefile where it subsitutes it. This clashes
7064 # with our Makefile.global concept. This workaround helps.
7065 case $INSTALL in
7066   *install-sh*) install_bin='';;
7067   *) install_bin=$INSTALL;;
7068 esac
7069
7070
7071 # Extract the first word of "tar", so it can be a program name with args.
7072 set dummy tar; ac_word=$2
7073 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7074 $as_echo_n "checking for $ac_word... " >&6; }
7075 if test "${ac_cv_path_TAR+set}" = set; then
7076   $as_echo_n "(cached) " >&6
7077 else
7078   case $TAR in
7079   [\\/]* | ?:[\\/]*)
7080   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
7081   ;;
7082   *)
7083   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7084 for as_dir in $PATH
7085 do
7086   IFS=$as_save_IFS
7087   test -z "$as_dir" && as_dir=.
7088   for ac_exec_ext in '' $ac_executable_extensions; do
7089   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7090     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
7091     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7092     break 2
7093   fi
7094 done
7095 done
7096 IFS=$as_save_IFS
7097
7098   ;;
7099 esac
7100 fi
7101 TAR=$ac_cv_path_TAR
7102 if test -n "$TAR"; then
7103   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
7104 $as_echo "$TAR" >&6; }
7105 else
7106   { $as_echo "$as_me:$LINENO: result: no" >&5
7107 $as_echo "no" >&6; }
7108 fi
7109
7110
7111 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
7112 $as_echo_n "checking whether ln -s works... " >&6; }
7113 LN_S=$as_ln_s
7114 if test "$LN_S" = "ln -s"; then
7115   { $as_echo "$as_me:$LINENO: result: yes" >&5
7116 $as_echo "yes" >&6; }
7117 else
7118   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
7119 $as_echo "no, using $LN_S" >&6; }
7120 fi
7121
7122 for ac_prog in gawk mawk nawk awk
7123 do
7124   # Extract the first word of "$ac_prog", so it can be a program name with args.
7125 set dummy $ac_prog; ac_word=$2
7126 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7127 $as_echo_n "checking for $ac_word... " >&6; }
7128 if test "${ac_cv_prog_AWK+set}" = set; then
7129   $as_echo_n "(cached) " >&6
7130 else
7131   if test -n "$AWK"; then
7132   ac_cv_prog_AWK="$AWK" # Let the user override the test.
7133 else
7134 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7135 for as_dir in $PATH
7136 do
7137   IFS=$as_save_IFS
7138   test -z "$as_dir" && as_dir=.
7139   for ac_exec_ext in '' $ac_executable_extensions; do
7140   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7141     ac_cv_prog_AWK="$ac_prog"
7142     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7143     break 2
7144   fi
7145 done
7146 done
7147 IFS=$as_save_IFS
7148
7149 fi
7150 fi
7151 AWK=$ac_cv_prog_AWK
7152 if test -n "$AWK"; then
7153   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
7154 $as_echo "$AWK" >&6; }
7155 else
7156   { $as_echo "$as_me:$LINENO: result: no" >&5
7157 $as_echo "no" >&6; }
7158 fi
7159
7160
7161   test -n "$AWK" && break
7162 done
7163
7164 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
7165 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
7166 if test -z "$MKDIR_P"; then
7167   if test "${ac_cv_path_mkdir+set}" = set; then
7168   $as_echo_n "(cached) " >&6
7169 else
7170   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7171 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
7172 do
7173   IFS=$as_save_IFS
7174   test -z "$as_dir" && as_dir=.
7175   for ac_prog in mkdir gmkdir; do
7176          for ac_exec_ext in '' $ac_executable_extensions; do
7177            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
7178            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
7179              'mkdir (GNU coreutils) '* | \
7180              'mkdir (coreutils) '* | \
7181              'mkdir (fileutils) '4.1*)
7182                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
7183                break 3;;
7184            esac
7185          done
7186        done
7187 done
7188 IFS=$as_save_IFS
7189
7190 fi
7191
7192   if test "${ac_cv_path_mkdir+set}" = set; then
7193     MKDIR_P="$ac_cv_path_mkdir -p"
7194   else
7195     # As a last resort, use the slow shell script.  Don't cache a
7196     # value for MKDIR_P within a source directory, because that will
7197     # break other packages using the cache if that directory is
7198     # removed, or if the value is a relative name.
7199     test -d ./--version && rmdir ./--version
7200     MKDIR_P="$ac_install_sh -d"
7201   fi
7202 fi
7203 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
7204 $as_echo "$MKDIR_P" >&6; }
7205
7206 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
7207 # a relative path to it in each makefile where it subsitutes it. This clashes
7208 # with our Makefile.global concept. This workaround helps.
7209 case $MKDIR_P in
7210   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
7211 esac
7212
7213 # Let the user override the search
7214 if test -z "$BISON"; then
7215   for ac_prog in bison
7216 do
7217   # Extract the first word of "$ac_prog", so it can be a program name with args.
7218 set dummy $ac_prog; ac_word=$2
7219 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7220 $as_echo_n "checking for $ac_word... " >&6; }
7221 if test "${ac_cv_path_BISON+set}" = set; then
7222   $as_echo_n "(cached) " >&6
7223 else
7224   case $BISON in
7225   [\\/]* | ?:[\\/]*)
7226   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
7227   ;;
7228   *)
7229   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7230 for as_dir in $PATH
7231 do
7232   IFS=$as_save_IFS
7233   test -z "$as_dir" && as_dir=.
7234   for ac_exec_ext in '' $ac_executable_extensions; do
7235   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7236     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
7237     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7238     break 2
7239   fi
7240 done
7241 done
7242 IFS=$as_save_IFS
7243
7244   ;;
7245 esac
7246 fi
7247 BISON=$ac_cv_path_BISON
7248 if test -n "$BISON"; then
7249   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
7250 $as_echo "$BISON" >&6; }
7251 else
7252   { $as_echo "$as_me:$LINENO: result: no" >&5
7253 $as_echo "no" >&6; }
7254 fi
7255
7256
7257   test -n "$BISON" && break
7258 done
7259
7260 fi
7261
7262 if test "$BISON"; then
7263   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
7264   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
7265 $as_echo "$as_me: using $pgac_bison_version" >&6;}
7266   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
7267   then
7268     { $as_echo "$as_me:$LINENO: WARNING:
7269 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
7270 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
7271 $as_echo "$as_me: WARNING:
7272 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
7273 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
7274     BISON=""
7275   fi
7276 fi
7277
7278 if test -z "$BISON"; then
7279   { $as_echo "$as_me:$LINENO: WARNING:
7280 *** Without Bison you will not be able to build PostgreSQL from Git nor
7281 *** change any of the parser definition files.  You can obtain Bison from
7282 *** a GNU mirror site.  (If you are using the official distribution of
7283 *** PostgreSQL then you do not need to worry about this, because the Bison
7284 *** output is pre-generated.)" >&5
7285 $as_echo "$as_me: WARNING:
7286 *** Without Bison you will not be able to build PostgreSQL from Git nor
7287 *** change any of the parser definition files.  You can obtain Bison from
7288 *** a GNU mirror site.  (If you are using the official distribution of
7289 *** PostgreSQL then you do not need to worry about this, because the Bison
7290 *** output is pre-generated.)" >&2;}
7291 fi
7292 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
7293
7294
7295 { $as_echo "$as_me:$LINENO: checking for flex" >&5
7296 $as_echo_n "checking for flex... " >&6; }
7297 if test "${pgac_cv_path_flex+set}" = set; then
7298   $as_echo_n "(cached) " >&6
7299 else
7300   # Let the user override the test
7301 if test -n "$FLEX"; then
7302   pgac_cv_path_flex=$FLEX
7303 else
7304   pgac_save_IFS=$IFS
7305   IFS=$PATH_SEPARATOR
7306   for pgac_dir in $PATH; do
7307     IFS=$pgac_save_IFS
7308     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
7309       pgac_dir=`pwd`
7310     fi
7311     for pgac_prog in flex lex; do
7312       pgac_candidate="$pgac_dir/$pgac_prog"
7313       if test -f "$pgac_candidate" \
7314         && $pgac_candidate --version </dev/null >/dev/null 2>&1
7315       then
7316         echo '%%'  > conftest.l
7317         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
7318           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
7319           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
7320           then
7321             pgac_cv_path_flex=$pgac_candidate
7322             break 2
7323           else
7324             { $as_echo "$as_me:$LINENO: WARNING:
7325 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
7326 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
7327 $as_echo "$as_me: WARNING:
7328 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
7329 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
7330           fi
7331         fi
7332       fi
7333     done
7334   done
7335   rm -f conftest.l lex.yy.c
7336   : ${pgac_cv_path_flex=no}
7337 fi
7338
7339 fi
7340 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
7341 $as_echo "$pgac_cv_path_flex" >&6; }
7342 if test x"$pgac_cv_path_flex" = x"no"; then
7343   { $as_echo "$as_me:$LINENO: WARNING:
7344 *** Without Flex you will not be able to build PostgreSQL from Git nor
7345 *** change any of the scanner definition files.  You can obtain Flex from
7346 *** a GNU mirror site.  (If you are using the official distribution of
7347 *** PostgreSQL then you do not need to worry about this because the Flex
7348 *** output is pre-generated.)" >&5
7349 $as_echo "$as_me: WARNING:
7350 *** Without Flex you will not be able to build PostgreSQL from Git nor
7351 *** change any of the scanner definition files.  You can obtain Flex from
7352 *** a GNU mirror site.  (If you are using the official distribution of
7353 *** PostgreSQL then you do not need to worry about this because the Flex
7354 *** output is pre-generated.)" >&2;}
7355
7356   FLEX=
7357 else
7358   FLEX=$pgac_cv_path_flex
7359   pgac_flex_version=`$FLEX --version 2>/dev/null`
7360   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
7361 $as_echo "$as_me: using $pgac_flex_version" >&6;}
7362 fi
7363
7364
7365
7366
7367
7368 # Let the user override the search
7369 if test -z "$PERL"; then
7370   # Extract the first word of "perl", so it can be a program name with args.
7371 set dummy perl; ac_word=$2
7372 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7373 $as_echo_n "checking for $ac_word... " >&6; }
7374 if test "${ac_cv_path_PERL+set}" = set; then
7375   $as_echo_n "(cached) " >&6
7376 else
7377   case $PERL in
7378   [\\/]* | ?:[\\/]*)
7379   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
7380   ;;
7381   *)
7382   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7383 for as_dir in $PATH
7384 do
7385   IFS=$as_save_IFS
7386   test -z "$as_dir" && as_dir=.
7387   for ac_exec_ext in '' $ac_executable_extensions; do
7388   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7389     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
7390     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7391     break 2
7392   fi
7393 done
7394 done
7395 IFS=$as_save_IFS
7396
7397   ;;
7398 esac
7399 fi
7400 PERL=$ac_cv_path_PERL
7401 if test -n "$PERL"; then
7402   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
7403 $as_echo "$PERL" >&6; }
7404 else
7405   { $as_echo "$as_me:$LINENO: result: no" >&5
7406 $as_echo "no" >&6; }
7407 fi
7408
7409
7410 fi
7411
7412 if test "$PERL"; then
7413   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'`
7414   { $as_echo "$as_me:$LINENO: using perl $pgac_perl_version" >&5
7415 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
7416   if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
7417     $AWK '{ if ($1 = 5 && $2 >= 8) exit 1; else exit 0;}'
7418   then
7419     { $as_echo "$as_me:$LINENO: WARNING:
7420 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
7421 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
7422 $as_echo "$as_me: WARNING:
7423 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
7424 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
7425     PERL=""
7426   fi
7427 fi
7428
7429 if test -z "$PERL"; then
7430   { $as_echo "$as_me:$LINENO: WARNING:
7431 *** Without Perl you will not be able to build PostgreSQL from Git.
7432 *** You can obtain Perl from any CPAN mirror site.
7433 *** (If you are using the official distribution of PostgreSQL then you do not
7434 *** need to worry about this, because the Perl output is pre-generated.)" >&5
7435 $as_echo "$as_me: WARNING:
7436 *** Without Perl you will not be able to build PostgreSQL from Git.
7437 *** You can obtain Perl from any CPAN mirror site.
7438 *** (If you are using the official distribution of PostgreSQL then you do not
7439 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
7440 fi
7441
7442 if test "$with_perl" = yes; then
7443   if test -z "$PERL"; then
7444     { { $as_echo "$as_me:$LINENO: error: Perl not found" >&5
7445 $as_echo "$as_me: error: Perl not found" >&2;}
7446    { (exit 1); exit 1; }; }
7447   fi
7448
7449 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
7450 $as_echo_n "checking for Perl archlibexp... " >&6; }
7451 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
7452 test "$PORTNAME" = "win32" && perl_archlibexp=`echo $perl_archlibexp | sed 's,\\\\,/,g'`
7453 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
7454 $as_echo "$perl_archlibexp" >&6; }
7455 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
7456 $as_echo_n "checking for Perl privlibexp... " >&6; }
7457 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
7458 test "$PORTNAME" = "win32" && perl_privlibexp=`echo $perl_privlibexp | sed 's,\\\\,/,g'`
7459 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
7460 $as_echo "$perl_privlibexp" >&6; }
7461 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
7462 $as_echo_n "checking for Perl useshrplib... " >&6; }
7463 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
7464 test "$PORTNAME" = "win32" && perl_useshrplib=`echo $perl_useshrplib | sed 's,\\\\,/,g'`
7465 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
7466 $as_echo "$perl_useshrplib" >&6; }
7467
7468 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
7469 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
7470 if test "$PORTNAME" = "win32" ; then
7471 perl_lib=`basename $perl_archlibexp/CORE/perl[5-9]*.lib .lib`
7472 test -e "$perl_archlibexp/CORE/$perl_lib.lib" && perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
7473 else
7474 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
7475 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
7476 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
7477 fi
7478 if test -z "$perl_embed_ldflags" ; then
7479         { $as_echo "$as_me:$LINENO: result: no" >&5
7480 $as_echo "no" >&6; }
7481         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
7482 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7483 installed." >&5
7484 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
7485 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7486 installed." >&2;}
7487    { (exit 1); exit 1; }; }
7488 else
7489         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
7490 $as_echo "$perl_embed_ldflags" >&6; }
7491 fi
7492
7493 fi
7494
7495 if test "$with_python" = yes; then
7496   # Extract the first word of "python", so it can be a program name with args.
7497 set dummy python; ac_word=$2
7498 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7499 $as_echo_n "checking for $ac_word... " >&6; }
7500 if test "${ac_cv_path_PYTHON+set}" = set; then
7501   $as_echo_n "(cached) " >&6
7502 else
7503   case $PYTHON in
7504   [\\/]* | ?:[\\/]*)
7505   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
7506   ;;
7507   *)
7508   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7509 for as_dir in $PATH
7510 do
7511   IFS=$as_save_IFS
7512   test -z "$as_dir" && as_dir=.
7513   for ac_exec_ext in '' $ac_executable_extensions; do
7514   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7515     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
7516     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7517     break 2
7518   fi
7519 done
7520 done
7521 IFS=$as_save_IFS
7522
7523   ;;
7524 esac
7525 fi
7526 PYTHON=$ac_cv_path_PYTHON
7527 if test -n "$PYTHON"; then
7528   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
7529 $as_echo "$PYTHON" >&6; }
7530 else
7531   { $as_echo "$as_me:$LINENO: result: no" >&5
7532 $as_echo "no" >&6; }
7533 fi
7534
7535
7536 if test x"$PYTHON" = x""; then
7537   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
7538 $as_echo "$as_me: error: Python not found" >&2;}
7539    { (exit 1); exit 1; }; }
7540 fi
7541
7542
7543 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
7544 $as_echo_n "checking for Python distutils module... " >&6; }
7545 if "${PYTHON}" -c 'import distutils' 2>&5
7546 then
7547     { $as_echo "$as_me:$LINENO: result: yes" >&5
7548 $as_echo "yes" >&6; }
7549 else
7550     { $as_echo "$as_me:$LINENO: result: no" >&5
7551 $as_echo "no" >&6; }
7552     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
7553 $as_echo "$as_me: error: distutils module not found" >&2;}
7554    { (exit 1); exit 1; }; }
7555 fi
7556 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
7557 $as_echo_n "checking Python configuration directory... " >&6; }
7558 python_majorversion=`${PYTHON} -c "import sys; print(sys.version[0])"`
7559 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
7560 python_configdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBPL'))))"`
7561 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
7562 $as_echo "$python_configdir" >&6; }
7563
7564 { $as_echo "$as_me:$LINENO: checking Python include directories" >&5
7565 $as_echo_n "checking Python include directories... " >&6; }
7566 python_includespec=`${PYTHON} -c "
7567 import distutils.sysconfig
7568 a = '-I' + distutils.sysconfig.get_python_inc(False)
7569 b = '-I' + distutils.sysconfig.get_python_inc(True)
7570 if a == b:
7571     print(a)
7572 else:
7573     print(a + ' ' + b)"`
7574 { $as_echo "$as_me:$LINENO: result: $python_includespec" >&5
7575 $as_echo "$python_includespec" >&6; }
7576
7577
7578
7579 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
7580 $as_echo_n "checking how to link an embedded Python application... " >&6; }
7581
7582 python_libdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
7583 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
7584 python_so=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
7585 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
7586 python_framework=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('PYTHONFRAMEWORK'))))"`
7587 python_enable_shared=`${PYTHON} -c "import distutils.sysconfig; print(distutils.sysconfig.get_config_vars().get('Py_ENABLE_SHARED',0))"`
7588
7589 if test -n "$python_framework"; then
7590         python_frameworkprefix=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('PYTHONFRAMEWORKPREFIX'))))"`
7591         python_libspec="-F${python_frameworkprefix} -framework $python_framework"
7592         python_enable_shared=1
7593 elif test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
7594 then
7595         # New way: use the official shared library
7596         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
7597         python_libspec="-L${python_libdir} -l${ldlibrary}"
7598 else
7599         # Old way: use libpython from python_configdir
7600         python_libdir="${python_configdir}"
7601         # LDVERSION was introduced in Python 3.2.
7602         python_ldversion=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDVERSION'))))"`
7603         if test x"${python_ldversion}" = x""; then
7604                 python_ldversion=$python_version
7605         fi
7606         python_libspec="-L${python_libdir} -lpython${python_ldversion}"
7607 fi
7608
7609 if test -z "$python_framework"; then
7610         python_additional_libs=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
7611 fi
7612
7613 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
7614 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
7615
7616
7617 # threaded python is not supported on OpenBSD
7618 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7619 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7620 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7621 if test "$pythreads" = "1"; then
7622   { $as_echo "$as_me:$LINENO: result: yes" >&5
7623 $as_echo "yes" >&6; }
7624   case $host_os in
7625   openbsd*)
7626     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7627 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7628    { (exit 1); exit 1; }; }
7629     ;;
7630   esac
7631 else
7632   { $as_echo "$as_me:$LINENO: result: no" >&5
7633 $as_echo "no" >&6; }
7634 fi
7635
7636
7637 fi
7638
7639 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7640   # Extract the first word of "zic", so it can be a program name with args.
7641 set dummy zic; ac_word=$2
7642 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7643 $as_echo_n "checking for $ac_word... " >&6; }
7644 if test "${ac_cv_path_ZIC+set}" = set; then
7645   $as_echo_n "(cached) " >&6
7646 else
7647   case $ZIC in
7648   [\\/]* | ?:[\\/]*)
7649   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7650   ;;
7651   *)
7652   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7653 for as_dir in $PATH
7654 do
7655   IFS=$as_save_IFS
7656   test -z "$as_dir" && as_dir=.
7657   for ac_exec_ext in '' $ac_executable_extensions; do
7658   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7659     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7660     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7661     break 2
7662   fi
7663 done
7664 done
7665 IFS=$as_save_IFS
7666
7667   ;;
7668 esac
7669 fi
7670 ZIC=$ac_cv_path_ZIC
7671 if test -n "$ZIC"; then
7672   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7673 $as_echo "$ZIC" >&6; }
7674 else
7675   { $as_echo "$as_me:$LINENO: result: no" >&5
7676 $as_echo "no" >&6; }
7677 fi
7678
7679
7680   if test -z "$ZIC"; then
7681     { { $as_echo "$as_me:$LINENO: error:
7682 When cross-compiling, either use the option --with-system-tzdata to use
7683 existing time-zone data, or set the environment variable ZIC to a zic
7684 program to use during the build." >&5
7685 $as_echo "$as_me: error:
7686 When cross-compiling, either use the option --with-system-tzdata to use
7687 existing time-zone data, or set the environment variable ZIC to a zic
7688 program to use during the build." >&2;}
7689    { (exit 1); exit 1; }; }
7690   fi
7691 fi
7692
7693
7694 ##
7695 ## Libraries
7696 ##
7697 ## Most libraries are included only if they demonstrably provide a function
7698 ## we need, but libm is an exception: always include it, because there are
7699 ## too many compilers that play cute optimization games that will break
7700 ## probes for standard functions such as pow().
7701 ##
7702
7703
7704 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7705 $as_echo_n "checking for main in -lm... " >&6; }
7706 if test "${ac_cv_lib_m_main+set}" = set; then
7707   $as_echo_n "(cached) " >&6
7708 else
7709   ac_check_lib_save_LIBS=$LIBS
7710 LIBS="-lm  $LIBS"
7711 cat >conftest.$ac_ext <<_ACEOF
7712 /* confdefs.h.  */
7713 _ACEOF
7714 cat confdefs.h >>conftest.$ac_ext
7715 cat >>conftest.$ac_ext <<_ACEOF
7716 /* end confdefs.h.  */
7717
7718
7719 int
7720 main ()
7721 {
7722 return main ();
7723   ;
7724   return 0;
7725 }
7726 _ACEOF
7727 rm -f conftest.$ac_objext conftest$ac_exeext
7728 if { (ac_try="$ac_link"
7729 case "(($ac_try" in
7730   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7731   *) ac_try_echo=$ac_try;;
7732 esac
7733 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7734 $as_echo "$ac_try_echo") >&5
7735   (eval "$ac_link") 2>conftest.er1
7736   ac_status=$?
7737   grep -v '^ *+' conftest.er1 >conftest.err
7738   rm -f conftest.er1
7739   cat conftest.err >&5
7740   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7741   (exit $ac_status); } && {
7742          test -z "$ac_c_werror_flag" ||
7743          test ! -s conftest.err
7744        } && test -s conftest$ac_exeext && {
7745          test "$cross_compiling" = yes ||
7746          $as_test_x conftest$ac_exeext
7747        }; then
7748   ac_cv_lib_m_main=yes
7749 else
7750   $as_echo "$as_me: failed program was:" >&5
7751 sed 's/^/| /' conftest.$ac_ext >&5
7752
7753         ac_cv_lib_m_main=no
7754 fi
7755
7756 rm -rf conftest.dSYM
7757 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7758       conftest$ac_exeext conftest.$ac_ext
7759 LIBS=$ac_check_lib_save_LIBS
7760 fi
7761 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7762 $as_echo "$ac_cv_lib_m_main" >&6; }
7763 if test "x$ac_cv_lib_m_main" = x""yes; then
7764   cat >>confdefs.h <<_ACEOF
7765 #define HAVE_LIBM 1
7766 _ACEOF
7767
7768   LIBS="-lm $LIBS"
7769
7770 fi
7771
7772 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7773 $as_echo_n "checking for library containing setproctitle... " >&6; }
7774 if test "${ac_cv_search_setproctitle+set}" = set; then
7775   $as_echo_n "(cached) " >&6
7776 else
7777   ac_func_search_save_LIBS=$LIBS
7778 cat >conftest.$ac_ext <<_ACEOF
7779 /* confdefs.h.  */
7780 _ACEOF
7781 cat confdefs.h >>conftest.$ac_ext
7782 cat >>conftest.$ac_ext <<_ACEOF
7783 /* end confdefs.h.  */
7784
7785 /* Override any GCC internal prototype to avoid an error.
7786    Use char because int might match the return type of a GCC
7787    builtin and then its argument prototype would still apply.  */
7788 #ifdef __cplusplus
7789 extern "C"
7790 #endif
7791 char setproctitle ();
7792 int
7793 main ()
7794 {
7795 return setproctitle ();
7796   ;
7797   return 0;
7798 }
7799 _ACEOF
7800 for ac_lib in '' util; do
7801   if test -z "$ac_lib"; then
7802     ac_res="none required"
7803   else
7804     ac_res=-l$ac_lib
7805     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7806   fi
7807   rm -f conftest.$ac_objext conftest$ac_exeext
7808 if { (ac_try="$ac_link"
7809 case "(($ac_try" in
7810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7811   *) ac_try_echo=$ac_try;;
7812 esac
7813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7814 $as_echo "$ac_try_echo") >&5
7815   (eval "$ac_link") 2>conftest.er1
7816   ac_status=$?
7817   grep -v '^ *+' conftest.er1 >conftest.err
7818   rm -f conftest.er1
7819   cat conftest.err >&5
7820   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7821   (exit $ac_status); } && {
7822          test -z "$ac_c_werror_flag" ||
7823          test ! -s conftest.err
7824        } && test -s conftest$ac_exeext && {
7825          test "$cross_compiling" = yes ||
7826          $as_test_x conftest$ac_exeext
7827        }; then
7828   ac_cv_search_setproctitle=$ac_res
7829 else
7830   $as_echo "$as_me: failed program was:" >&5
7831 sed 's/^/| /' conftest.$ac_ext >&5
7832
7833
7834 fi
7835
7836 rm -rf conftest.dSYM
7837 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7838       conftest$ac_exeext
7839   if test "${ac_cv_search_setproctitle+set}" = set; then
7840   break
7841 fi
7842 done
7843 if test "${ac_cv_search_setproctitle+set}" = set; then
7844   :
7845 else
7846   ac_cv_search_setproctitle=no
7847 fi
7848 rm conftest.$ac_ext
7849 LIBS=$ac_func_search_save_LIBS
7850 fi
7851 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7852 $as_echo "$ac_cv_search_setproctitle" >&6; }
7853 ac_res=$ac_cv_search_setproctitle
7854 if test "$ac_res" != no; then
7855   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7856
7857 fi
7858
7859 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7860 $as_echo_n "checking for library containing dlopen... " >&6; }
7861 if test "${ac_cv_search_dlopen+set}" = set; then
7862   $as_echo_n "(cached) " >&6
7863 else
7864   ac_func_search_save_LIBS=$LIBS
7865 cat >conftest.$ac_ext <<_ACEOF
7866 /* confdefs.h.  */
7867 _ACEOF
7868 cat confdefs.h >>conftest.$ac_ext
7869 cat >>conftest.$ac_ext <<_ACEOF
7870 /* end confdefs.h.  */
7871
7872 /* Override any GCC internal prototype to avoid an error.
7873    Use char because int might match the return type of a GCC
7874    builtin and then its argument prototype would still apply.  */
7875 #ifdef __cplusplus
7876 extern "C"
7877 #endif
7878 char dlopen ();
7879 int
7880 main ()
7881 {
7882 return dlopen ();
7883   ;
7884   return 0;
7885 }
7886 _ACEOF
7887 for ac_lib in '' dl; do
7888   if test -z "$ac_lib"; then
7889     ac_res="none required"
7890   else
7891     ac_res=-l$ac_lib
7892     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7893   fi
7894   rm -f conftest.$ac_objext conftest$ac_exeext
7895 if { (ac_try="$ac_link"
7896 case "(($ac_try" in
7897   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7898   *) ac_try_echo=$ac_try;;
7899 esac
7900 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7901 $as_echo "$ac_try_echo") >&5
7902   (eval "$ac_link") 2>conftest.er1
7903   ac_status=$?
7904   grep -v '^ *+' conftest.er1 >conftest.err
7905   rm -f conftest.er1
7906   cat conftest.err >&5
7907   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7908   (exit $ac_status); } && {
7909          test -z "$ac_c_werror_flag" ||
7910          test ! -s conftest.err
7911        } && test -s conftest$ac_exeext && {
7912          test "$cross_compiling" = yes ||
7913          $as_test_x conftest$ac_exeext
7914        }; then
7915   ac_cv_search_dlopen=$ac_res
7916 else
7917   $as_echo "$as_me: failed program was:" >&5
7918 sed 's/^/| /' conftest.$ac_ext >&5
7919
7920
7921 fi
7922
7923 rm -rf conftest.dSYM
7924 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7925       conftest$ac_exeext
7926   if test "${ac_cv_search_dlopen+set}" = set; then
7927   break
7928 fi
7929 done
7930 if test "${ac_cv_search_dlopen+set}" = set; then
7931   :
7932 else
7933   ac_cv_search_dlopen=no
7934 fi
7935 rm conftest.$ac_ext
7936 LIBS=$ac_func_search_save_LIBS
7937 fi
7938 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7939 $as_echo "$ac_cv_search_dlopen" >&6; }
7940 ac_res=$ac_cv_search_dlopen
7941 if test "$ac_res" != no; then
7942   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7943
7944 fi
7945
7946 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7947 $as_echo_n "checking for library containing socket... " >&6; }
7948 if test "${ac_cv_search_socket+set}" = set; then
7949   $as_echo_n "(cached) " >&6
7950 else
7951   ac_func_search_save_LIBS=$LIBS
7952 cat >conftest.$ac_ext <<_ACEOF
7953 /* confdefs.h.  */
7954 _ACEOF
7955 cat confdefs.h >>conftest.$ac_ext
7956 cat >>conftest.$ac_ext <<_ACEOF
7957 /* end confdefs.h.  */
7958
7959 /* Override any GCC internal prototype to avoid an error.
7960    Use char because int might match the return type of a GCC
7961    builtin and then its argument prototype would still apply.  */
7962 #ifdef __cplusplus
7963 extern "C"
7964 #endif
7965 char socket ();
7966 int
7967 main ()
7968 {
7969 return socket ();
7970   ;
7971   return 0;
7972 }
7973 _ACEOF
7974 for ac_lib in '' socket wsock32; do
7975   if test -z "$ac_lib"; then
7976     ac_res="none required"
7977   else
7978     ac_res=-l$ac_lib
7979     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7980   fi
7981   rm -f conftest.$ac_objext conftest$ac_exeext
7982 if { (ac_try="$ac_link"
7983 case "(($ac_try" in
7984   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7985   *) ac_try_echo=$ac_try;;
7986 esac
7987 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7988 $as_echo "$ac_try_echo") >&5
7989   (eval "$ac_link") 2>conftest.er1
7990   ac_status=$?
7991   grep -v '^ *+' conftest.er1 >conftest.err
7992   rm -f conftest.er1
7993   cat conftest.err >&5
7994   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7995   (exit $ac_status); } && {
7996          test -z "$ac_c_werror_flag" ||
7997          test ! -s conftest.err
7998        } && test -s conftest$ac_exeext && {
7999          test "$cross_compiling" = yes ||
8000          $as_test_x conftest$ac_exeext
8001        }; then
8002   ac_cv_search_socket=$ac_res
8003 else
8004   $as_echo "$as_me: failed program was:" >&5
8005 sed 's/^/| /' conftest.$ac_ext >&5
8006
8007
8008 fi
8009
8010 rm -rf conftest.dSYM
8011 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8012       conftest$ac_exeext
8013   if test "${ac_cv_search_socket+set}" = set; then
8014   break
8015 fi
8016 done
8017 if test "${ac_cv_search_socket+set}" = set; then
8018   :
8019 else
8020   ac_cv_search_socket=no
8021 fi
8022 rm conftest.$ac_ext
8023 LIBS=$ac_func_search_save_LIBS
8024 fi
8025 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
8026 $as_echo "$ac_cv_search_socket" >&6; }
8027 ac_res=$ac_cv_search_socket
8028 if test "$ac_res" != no; then
8029   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8030
8031 fi
8032
8033 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
8034 $as_echo_n "checking for library containing shl_load... " >&6; }
8035 if test "${ac_cv_search_shl_load+set}" = set; then
8036   $as_echo_n "(cached) " >&6
8037 else
8038   ac_func_search_save_LIBS=$LIBS
8039 cat >conftest.$ac_ext <<_ACEOF
8040 /* confdefs.h.  */
8041 _ACEOF
8042 cat confdefs.h >>conftest.$ac_ext
8043 cat >>conftest.$ac_ext <<_ACEOF
8044 /* end confdefs.h.  */
8045
8046 /* Override any GCC internal prototype to avoid an error.
8047    Use char because int might match the return type of a GCC
8048    builtin and then its argument prototype would still apply.  */
8049 #ifdef __cplusplus
8050 extern "C"
8051 #endif
8052 char shl_load ();
8053 int
8054 main ()
8055 {
8056 return shl_load ();
8057   ;
8058   return 0;
8059 }
8060 _ACEOF
8061 for ac_lib in '' dld; do
8062   if test -z "$ac_lib"; then
8063     ac_res="none required"
8064   else
8065     ac_res=-l$ac_lib
8066     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8067   fi
8068   rm -f conftest.$ac_objext conftest$ac_exeext
8069 if { (ac_try="$ac_link"
8070 case "(($ac_try" in
8071   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8072   *) ac_try_echo=$ac_try;;
8073 esac
8074 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8075 $as_echo "$ac_try_echo") >&5
8076   (eval "$ac_link") 2>conftest.er1
8077   ac_status=$?
8078   grep -v '^ *+' conftest.er1 >conftest.err
8079   rm -f conftest.er1
8080   cat conftest.err >&5
8081   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8082   (exit $ac_status); } && {
8083          test -z "$ac_c_werror_flag" ||
8084          test ! -s conftest.err
8085        } && test -s conftest$ac_exeext && {
8086          test "$cross_compiling" = yes ||
8087          $as_test_x conftest$ac_exeext
8088        }; then
8089   ac_cv_search_shl_load=$ac_res
8090 else
8091   $as_echo "$as_me: failed program was:" >&5
8092 sed 's/^/| /' conftest.$ac_ext >&5
8093
8094
8095 fi
8096
8097 rm -rf conftest.dSYM
8098 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8099       conftest$ac_exeext
8100   if test "${ac_cv_search_shl_load+set}" = set; then
8101   break
8102 fi
8103 done
8104 if test "${ac_cv_search_shl_load+set}" = set; then
8105   :
8106 else
8107   ac_cv_search_shl_load=no
8108 fi
8109 rm conftest.$ac_ext
8110 LIBS=$ac_func_search_save_LIBS
8111 fi
8112 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
8113 $as_echo "$ac_cv_search_shl_load" >&6; }
8114 ac_res=$ac_cv_search_shl_load
8115 if test "$ac_res" != no; then
8116   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8117
8118 fi
8119
8120 # We only use libld in port/dynloader/aix.c
8121 case $host_os in
8122      aix*)
8123         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
8124 $as_echo_n "checking for library containing ldopen... " >&6; }
8125 if test "${ac_cv_search_ldopen+set}" = set; then
8126   $as_echo_n "(cached) " >&6
8127 else
8128   ac_func_search_save_LIBS=$LIBS
8129 cat >conftest.$ac_ext <<_ACEOF
8130 /* confdefs.h.  */
8131 _ACEOF
8132 cat confdefs.h >>conftest.$ac_ext
8133 cat >>conftest.$ac_ext <<_ACEOF
8134 /* end confdefs.h.  */
8135
8136 /* Override any GCC internal prototype to avoid an error.
8137    Use char because int might match the return type of a GCC
8138    builtin and then its argument prototype would still apply.  */
8139 #ifdef __cplusplus
8140 extern "C"
8141 #endif
8142 char ldopen ();
8143 int
8144 main ()
8145 {
8146 return ldopen ();
8147   ;
8148   return 0;
8149 }
8150 _ACEOF
8151 for ac_lib in '' ld; do
8152   if test -z "$ac_lib"; then
8153     ac_res="none required"
8154   else
8155     ac_res=-l$ac_lib
8156     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8157   fi
8158   rm -f conftest.$ac_objext conftest$ac_exeext
8159 if { (ac_try="$ac_link"
8160 case "(($ac_try" in
8161   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8162   *) ac_try_echo=$ac_try;;
8163 esac
8164 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8165 $as_echo "$ac_try_echo") >&5
8166   (eval "$ac_link") 2>conftest.er1
8167   ac_status=$?
8168   grep -v '^ *+' conftest.er1 >conftest.err
8169   rm -f conftest.er1
8170   cat conftest.err >&5
8171   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8172   (exit $ac_status); } && {
8173          test -z "$ac_c_werror_flag" ||
8174          test ! -s conftest.err
8175        } && test -s conftest$ac_exeext && {
8176          test "$cross_compiling" = yes ||
8177          $as_test_x conftest$ac_exeext
8178        }; then
8179   ac_cv_search_ldopen=$ac_res
8180 else
8181   $as_echo "$as_me: failed program was:" >&5
8182 sed 's/^/| /' conftest.$ac_ext >&5
8183
8184
8185 fi
8186
8187 rm -rf conftest.dSYM
8188 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8189       conftest$ac_exeext
8190   if test "${ac_cv_search_ldopen+set}" = set; then
8191   break
8192 fi
8193 done
8194 if test "${ac_cv_search_ldopen+set}" = set; then
8195   :
8196 else
8197   ac_cv_search_ldopen=no
8198 fi
8199 rm conftest.$ac_ext
8200 LIBS=$ac_func_search_save_LIBS
8201 fi
8202 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
8203 $as_echo "$ac_cv_search_ldopen" >&6; }
8204 ac_res=$ac_cv_search_ldopen
8205 if test "$ac_res" != no; then
8206   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8207
8208 fi
8209
8210         ;;
8211 esac
8212 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
8213 $as_echo_n "checking for library containing getopt_long... " >&6; }
8214 if test "${ac_cv_search_getopt_long+set}" = set; then
8215   $as_echo_n "(cached) " >&6
8216 else
8217   ac_func_search_save_LIBS=$LIBS
8218 cat >conftest.$ac_ext <<_ACEOF
8219 /* confdefs.h.  */
8220 _ACEOF
8221 cat confdefs.h >>conftest.$ac_ext
8222 cat >>conftest.$ac_ext <<_ACEOF
8223 /* end confdefs.h.  */
8224
8225 /* Override any GCC internal prototype to avoid an error.
8226    Use char because int might match the return type of a GCC
8227    builtin and then its argument prototype would still apply.  */
8228 #ifdef __cplusplus
8229 extern "C"
8230 #endif
8231 char getopt_long ();
8232 int
8233 main ()
8234 {
8235 return getopt_long ();
8236   ;
8237   return 0;
8238 }
8239 _ACEOF
8240 for ac_lib in '' getopt gnugetopt; do
8241   if test -z "$ac_lib"; then
8242     ac_res="none required"
8243   else
8244     ac_res=-l$ac_lib
8245     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8246   fi
8247   rm -f conftest.$ac_objext conftest$ac_exeext
8248 if { (ac_try="$ac_link"
8249 case "(($ac_try" in
8250   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8251   *) ac_try_echo=$ac_try;;
8252 esac
8253 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8254 $as_echo "$ac_try_echo") >&5
8255   (eval "$ac_link") 2>conftest.er1
8256   ac_status=$?
8257   grep -v '^ *+' conftest.er1 >conftest.err
8258   rm -f conftest.er1
8259   cat conftest.err >&5
8260   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8261   (exit $ac_status); } && {
8262          test -z "$ac_c_werror_flag" ||
8263          test ! -s conftest.err
8264        } && test -s conftest$ac_exeext && {
8265          test "$cross_compiling" = yes ||
8266          $as_test_x conftest$ac_exeext
8267        }; then
8268   ac_cv_search_getopt_long=$ac_res
8269 else
8270   $as_echo "$as_me: failed program was:" >&5
8271 sed 's/^/| /' conftest.$ac_ext >&5
8272
8273
8274 fi
8275
8276 rm -rf conftest.dSYM
8277 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8278       conftest$ac_exeext
8279   if test "${ac_cv_search_getopt_long+set}" = set; then
8280   break
8281 fi
8282 done
8283 if test "${ac_cv_search_getopt_long+set}" = set; then
8284   :
8285 else
8286   ac_cv_search_getopt_long=no
8287 fi
8288 rm conftest.$ac_ext
8289 LIBS=$ac_func_search_save_LIBS
8290 fi
8291 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
8292 $as_echo "$ac_cv_search_getopt_long" >&6; }
8293 ac_res=$ac_cv_search_getopt_long
8294 if test "$ac_res" != no; then
8295   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8296
8297 fi
8298
8299 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
8300 $as_echo_n "checking for library containing crypt... " >&6; }
8301 if test "${ac_cv_search_crypt+set}" = set; then
8302   $as_echo_n "(cached) " >&6
8303 else
8304   ac_func_search_save_LIBS=$LIBS
8305 cat >conftest.$ac_ext <<_ACEOF
8306 /* confdefs.h.  */
8307 _ACEOF
8308 cat confdefs.h >>conftest.$ac_ext
8309 cat >>conftest.$ac_ext <<_ACEOF
8310 /* end confdefs.h.  */
8311
8312 /* Override any GCC internal prototype to avoid an error.
8313    Use char because int might match the return type of a GCC
8314    builtin and then its argument prototype would still apply.  */
8315 #ifdef __cplusplus
8316 extern "C"
8317 #endif
8318 char crypt ();
8319 int
8320 main ()
8321 {
8322 return crypt ();
8323   ;
8324   return 0;
8325 }
8326 _ACEOF
8327 for ac_lib in '' crypt; do
8328   if test -z "$ac_lib"; then
8329     ac_res="none required"
8330   else
8331     ac_res=-l$ac_lib
8332     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8333   fi
8334   rm -f conftest.$ac_objext conftest$ac_exeext
8335 if { (ac_try="$ac_link"
8336 case "(($ac_try" in
8337   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8338   *) ac_try_echo=$ac_try;;
8339 esac
8340 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8341 $as_echo "$ac_try_echo") >&5
8342   (eval "$ac_link") 2>conftest.er1
8343   ac_status=$?
8344   grep -v '^ *+' conftest.er1 >conftest.err
8345   rm -f conftest.er1
8346   cat conftest.err >&5
8347   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8348   (exit $ac_status); } && {
8349          test -z "$ac_c_werror_flag" ||
8350          test ! -s conftest.err
8351        } && test -s conftest$ac_exeext && {
8352          test "$cross_compiling" = yes ||
8353          $as_test_x conftest$ac_exeext
8354        }; then
8355   ac_cv_search_crypt=$ac_res
8356 else
8357   $as_echo "$as_me: failed program was:" >&5
8358 sed 's/^/| /' conftest.$ac_ext >&5
8359
8360
8361 fi
8362
8363 rm -rf conftest.dSYM
8364 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8365       conftest$ac_exeext
8366   if test "${ac_cv_search_crypt+set}" = set; then
8367   break
8368 fi
8369 done
8370 if test "${ac_cv_search_crypt+set}" = set; then
8371   :
8372 else
8373   ac_cv_search_crypt=no
8374 fi
8375 rm conftest.$ac_ext
8376 LIBS=$ac_func_search_save_LIBS
8377 fi
8378 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
8379 $as_echo "$ac_cv_search_crypt" >&6; }
8380 ac_res=$ac_cv_search_crypt
8381 if test "$ac_res" != no; then
8382   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8383
8384 fi
8385
8386 { $as_echo "$as_me:$LINENO: checking for library containing shm_open" >&5
8387 $as_echo_n "checking for library containing shm_open... " >&6; }
8388 if test "${ac_cv_search_shm_open+set}" = set; then
8389   $as_echo_n "(cached) " >&6
8390 else
8391   ac_func_search_save_LIBS=$LIBS
8392 cat >conftest.$ac_ext <<_ACEOF
8393 /* confdefs.h.  */
8394 _ACEOF
8395 cat confdefs.h >>conftest.$ac_ext
8396 cat >>conftest.$ac_ext <<_ACEOF
8397 /* end confdefs.h.  */
8398
8399 /* Override any GCC internal prototype to avoid an error.
8400    Use char because int might match the return type of a GCC
8401    builtin and then its argument prototype would still apply.  */
8402 #ifdef __cplusplus
8403 extern "C"
8404 #endif
8405 char shm_open ();
8406 int
8407 main ()
8408 {
8409 return shm_open ();
8410   ;
8411   return 0;
8412 }
8413 _ACEOF
8414 for ac_lib in '' rt; do
8415   if test -z "$ac_lib"; then
8416     ac_res="none required"
8417   else
8418     ac_res=-l$ac_lib
8419     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8420   fi
8421   rm -f conftest.$ac_objext conftest$ac_exeext
8422 if { (ac_try="$ac_link"
8423 case "(($ac_try" in
8424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8425   *) ac_try_echo=$ac_try;;
8426 esac
8427 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8428 $as_echo "$ac_try_echo") >&5
8429   (eval "$ac_link") 2>conftest.er1
8430   ac_status=$?
8431   grep -v '^ *+' conftest.er1 >conftest.err
8432   rm -f conftest.er1
8433   cat conftest.err >&5
8434   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8435   (exit $ac_status); } && {
8436          test -z "$ac_c_werror_flag" ||
8437          test ! -s conftest.err
8438        } && test -s conftest$ac_exeext && {
8439          test "$cross_compiling" = yes ||
8440          $as_test_x conftest$ac_exeext
8441        }; then
8442   ac_cv_search_shm_open=$ac_res
8443 else
8444   $as_echo "$as_me: failed program was:" >&5
8445 sed 's/^/| /' conftest.$ac_ext >&5
8446
8447
8448 fi
8449
8450 rm -rf conftest.dSYM
8451 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8452       conftest$ac_exeext
8453   if test "${ac_cv_search_shm_open+set}" = set; then
8454   break
8455 fi
8456 done
8457 if test "${ac_cv_search_shm_open+set}" = set; then
8458   :
8459 else
8460   ac_cv_search_shm_open=no
8461 fi
8462 rm conftest.$ac_ext
8463 LIBS=$ac_func_search_save_LIBS
8464 fi
8465 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shm_open" >&5
8466 $as_echo "$ac_cv_search_shm_open" >&6; }
8467 ac_res=$ac_cv_search_shm_open
8468 if test "$ac_res" != no; then
8469   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8470
8471 fi
8472
8473 { $as_echo "$as_me:$LINENO: checking for library containing shm_unlink" >&5
8474 $as_echo_n "checking for library containing shm_unlink... " >&6; }
8475 if test "${ac_cv_search_shm_unlink+set}" = set; then
8476   $as_echo_n "(cached) " >&6
8477 else
8478   ac_func_search_save_LIBS=$LIBS
8479 cat >conftest.$ac_ext <<_ACEOF
8480 /* confdefs.h.  */
8481 _ACEOF
8482 cat confdefs.h >>conftest.$ac_ext
8483 cat >>conftest.$ac_ext <<_ACEOF
8484 /* end confdefs.h.  */
8485
8486 /* Override any GCC internal prototype to avoid an error.
8487    Use char because int might match the return type of a GCC
8488    builtin and then its argument prototype would still apply.  */
8489 #ifdef __cplusplus
8490 extern "C"
8491 #endif
8492 char shm_unlink ();
8493 int
8494 main ()
8495 {
8496 return shm_unlink ();
8497   ;
8498   return 0;
8499 }
8500 _ACEOF
8501 for ac_lib in '' rt; do
8502   if test -z "$ac_lib"; then
8503     ac_res="none required"
8504   else
8505     ac_res=-l$ac_lib
8506     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8507   fi
8508   rm -f conftest.$ac_objext conftest$ac_exeext
8509 if { (ac_try="$ac_link"
8510 case "(($ac_try" in
8511   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8512   *) ac_try_echo=$ac_try;;
8513 esac
8514 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8515 $as_echo "$ac_try_echo") >&5
8516   (eval "$ac_link") 2>conftest.er1
8517   ac_status=$?
8518   grep -v '^ *+' conftest.er1 >conftest.err
8519   rm -f conftest.er1
8520   cat conftest.err >&5
8521   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8522   (exit $ac_status); } && {
8523          test -z "$ac_c_werror_flag" ||
8524          test ! -s conftest.err
8525        } && test -s conftest$ac_exeext && {
8526          test "$cross_compiling" = yes ||
8527          $as_test_x conftest$ac_exeext
8528        }; then
8529   ac_cv_search_shm_unlink=$ac_res
8530 else
8531   $as_echo "$as_me: failed program was:" >&5
8532 sed 's/^/| /' conftest.$ac_ext >&5
8533
8534
8535 fi
8536
8537 rm -rf conftest.dSYM
8538 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8539       conftest$ac_exeext
8540   if test "${ac_cv_search_shm_unlink+set}" = set; then
8541   break
8542 fi
8543 done
8544 if test "${ac_cv_search_shm_unlink+set}" = set; then
8545   :
8546 else
8547   ac_cv_search_shm_unlink=no
8548 fi
8549 rm conftest.$ac_ext
8550 LIBS=$ac_func_search_save_LIBS
8551 fi
8552 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shm_unlink" >&5
8553 $as_echo "$ac_cv_search_shm_unlink" >&6; }
8554 ac_res=$ac_cv_search_shm_unlink
8555 if test "$ac_res" != no; then
8556   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8557
8558 fi
8559
8560 # Solaris:
8561 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
8562 $as_echo_n "checking for library containing fdatasync... " >&6; }
8563 if test "${ac_cv_search_fdatasync+set}" = set; then
8564   $as_echo_n "(cached) " >&6
8565 else
8566   ac_func_search_save_LIBS=$LIBS
8567 cat >conftest.$ac_ext <<_ACEOF
8568 /* confdefs.h.  */
8569 _ACEOF
8570 cat confdefs.h >>conftest.$ac_ext
8571 cat >>conftest.$ac_ext <<_ACEOF
8572 /* end confdefs.h.  */
8573
8574 /* Override any GCC internal prototype to avoid an error.
8575    Use char because int might match the return type of a GCC
8576    builtin and then its argument prototype would still apply.  */
8577 #ifdef __cplusplus
8578 extern "C"
8579 #endif
8580 char fdatasync ();
8581 int
8582 main ()
8583 {
8584 return fdatasync ();
8585   ;
8586   return 0;
8587 }
8588 _ACEOF
8589 for ac_lib in '' rt posix4; do
8590   if test -z "$ac_lib"; then
8591     ac_res="none required"
8592   else
8593     ac_res=-l$ac_lib
8594     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8595   fi
8596   rm -f conftest.$ac_objext conftest$ac_exeext
8597 if { (ac_try="$ac_link"
8598 case "(($ac_try" in
8599   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8600   *) ac_try_echo=$ac_try;;
8601 esac
8602 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8603 $as_echo "$ac_try_echo") >&5
8604   (eval "$ac_link") 2>conftest.er1
8605   ac_status=$?
8606   grep -v '^ *+' conftest.er1 >conftest.err
8607   rm -f conftest.er1
8608   cat conftest.err >&5
8609   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8610   (exit $ac_status); } && {
8611          test -z "$ac_c_werror_flag" ||
8612          test ! -s conftest.err
8613        } && test -s conftest$ac_exeext && {
8614          test "$cross_compiling" = yes ||
8615          $as_test_x conftest$ac_exeext
8616        }; then
8617   ac_cv_search_fdatasync=$ac_res
8618 else
8619   $as_echo "$as_me: failed program was:" >&5
8620 sed 's/^/| /' conftest.$ac_ext >&5
8621
8622
8623 fi
8624
8625 rm -rf conftest.dSYM
8626 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8627       conftest$ac_exeext
8628   if test "${ac_cv_search_fdatasync+set}" = set; then
8629   break
8630 fi
8631 done
8632 if test "${ac_cv_search_fdatasync+set}" = set; then
8633   :
8634 else
8635   ac_cv_search_fdatasync=no
8636 fi
8637 rm conftest.$ac_ext
8638 LIBS=$ac_func_search_save_LIBS
8639 fi
8640 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
8641 $as_echo "$ac_cv_search_fdatasync" >&6; }
8642 ac_res=$ac_cv_search_fdatasync
8643 if test "$ac_res" != no; then
8644   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8645
8646 fi
8647
8648 # Required for thread_test.c on Solaris 2.5:
8649 # Other ports use it too (HP-UX) so test unconditionally
8650 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
8651 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
8652 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8653   $as_echo_n "(cached) " >&6
8654 else
8655   ac_func_search_save_LIBS=$LIBS
8656 cat >conftest.$ac_ext <<_ACEOF
8657 /* confdefs.h.  */
8658 _ACEOF
8659 cat confdefs.h >>conftest.$ac_ext
8660 cat >>conftest.$ac_ext <<_ACEOF
8661 /* end confdefs.h.  */
8662
8663 /* Override any GCC internal prototype to avoid an error.
8664    Use char because int might match the return type of a GCC
8665    builtin and then its argument prototype would still apply.  */
8666 #ifdef __cplusplus
8667 extern "C"
8668 #endif
8669 char gethostbyname_r ();
8670 int
8671 main ()
8672 {
8673 return gethostbyname_r ();
8674   ;
8675   return 0;
8676 }
8677 _ACEOF
8678 for ac_lib in '' nsl; do
8679   if test -z "$ac_lib"; then
8680     ac_res="none required"
8681   else
8682     ac_res=-l$ac_lib
8683     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8684   fi
8685   rm -f conftest.$ac_objext conftest$ac_exeext
8686 if { (ac_try="$ac_link"
8687 case "(($ac_try" in
8688   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8689   *) ac_try_echo=$ac_try;;
8690 esac
8691 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8692 $as_echo "$ac_try_echo") >&5
8693   (eval "$ac_link") 2>conftest.er1
8694   ac_status=$?
8695   grep -v '^ *+' conftest.er1 >conftest.err
8696   rm -f conftest.er1
8697   cat conftest.err >&5
8698   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8699   (exit $ac_status); } && {
8700          test -z "$ac_c_werror_flag" ||
8701          test ! -s conftest.err
8702        } && test -s conftest$ac_exeext && {
8703          test "$cross_compiling" = yes ||
8704          $as_test_x conftest$ac_exeext
8705        }; then
8706   ac_cv_search_gethostbyname_r=$ac_res
8707 else
8708   $as_echo "$as_me: failed program was:" >&5
8709 sed 's/^/| /' conftest.$ac_ext >&5
8710
8711
8712 fi
8713
8714 rm -rf conftest.dSYM
8715 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8716       conftest$ac_exeext
8717   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8718   break
8719 fi
8720 done
8721 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8722   :
8723 else
8724   ac_cv_search_gethostbyname_r=no
8725 fi
8726 rm conftest.$ac_ext
8727 LIBS=$ac_func_search_save_LIBS
8728 fi
8729 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
8730 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
8731 ac_res=$ac_cv_search_gethostbyname_r
8732 if test "$ac_res" != no; then
8733   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8734
8735 fi
8736
8737 # Cygwin:
8738 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
8739 $as_echo_n "checking for library containing shmget... " >&6; }
8740 if test "${ac_cv_search_shmget+set}" = set; then
8741   $as_echo_n "(cached) " >&6
8742 else
8743   ac_func_search_save_LIBS=$LIBS
8744 cat >conftest.$ac_ext <<_ACEOF
8745 /* confdefs.h.  */
8746 _ACEOF
8747 cat confdefs.h >>conftest.$ac_ext
8748 cat >>conftest.$ac_ext <<_ACEOF
8749 /* end confdefs.h.  */
8750
8751 /* Override any GCC internal prototype to avoid an error.
8752    Use char because int might match the return type of a GCC
8753    builtin and then its argument prototype would still apply.  */
8754 #ifdef __cplusplus
8755 extern "C"
8756 #endif
8757 char shmget ();
8758 int
8759 main ()
8760 {
8761 return shmget ();
8762   ;
8763   return 0;
8764 }
8765 _ACEOF
8766 for ac_lib in '' cygipc; do
8767   if test -z "$ac_lib"; then
8768     ac_res="none required"
8769   else
8770     ac_res=-l$ac_lib
8771     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8772   fi
8773   rm -f conftest.$ac_objext conftest$ac_exeext
8774 if { (ac_try="$ac_link"
8775 case "(($ac_try" in
8776   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8777   *) ac_try_echo=$ac_try;;
8778 esac
8779 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8780 $as_echo "$ac_try_echo") >&5
8781   (eval "$ac_link") 2>conftest.er1
8782   ac_status=$?
8783   grep -v '^ *+' conftest.er1 >conftest.err
8784   rm -f conftest.er1
8785   cat conftest.err >&5
8786   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8787   (exit $ac_status); } && {
8788          test -z "$ac_c_werror_flag" ||
8789          test ! -s conftest.err
8790        } && test -s conftest$ac_exeext && {
8791          test "$cross_compiling" = yes ||
8792          $as_test_x conftest$ac_exeext
8793        }; then
8794   ac_cv_search_shmget=$ac_res
8795 else
8796   $as_echo "$as_me: failed program was:" >&5
8797 sed 's/^/| /' conftest.$ac_ext >&5
8798
8799
8800 fi
8801
8802 rm -rf conftest.dSYM
8803 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8804       conftest$ac_exeext
8805   if test "${ac_cv_search_shmget+set}" = set; then
8806   break
8807 fi
8808 done
8809 if test "${ac_cv_search_shmget+set}" = set; then
8810   :
8811 else
8812   ac_cv_search_shmget=no
8813 fi
8814 rm conftest.$ac_ext
8815 LIBS=$ac_func_search_save_LIBS
8816 fi
8817 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8818 $as_echo "$ac_cv_search_shmget" >&6; }
8819 ac_res=$ac_cv_search_shmget
8820 if test "$ac_res" != no; then
8821   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8822
8823 fi
8824
8825
8826 if test "$with_readline" = yes; then
8827
8828
8829 { $as_echo "$as_me:$LINENO: checking for library containing readline" >&5
8830 $as_echo_n "checking for library containing readline... " >&6; }
8831 if test "${pgac_cv_check_readline+set}" = set; then
8832   $as_echo_n "(cached) " >&6
8833 else
8834   pgac_cv_check_readline=no
8835 pgac_save_LIBS=$LIBS
8836 if test x"$with_libedit_preferred" != x"yes"
8837 then    READLINE_ORDER="-lreadline -ledit"
8838 else    READLINE_ORDER="-ledit -lreadline"
8839 fi
8840 for pgac_rllib in $READLINE_ORDER ; do
8841   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8842     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8843     cat >conftest.$ac_ext <<_ACEOF
8844 /* confdefs.h.  */
8845 _ACEOF
8846 cat confdefs.h >>conftest.$ac_ext
8847 cat >>conftest.$ac_ext <<_ACEOF
8848 /* end confdefs.h.  */
8849
8850 /* Override any GCC internal prototype to avoid an error.
8851    Use char because int might match the return type of a GCC
8852    builtin and then its argument prototype would still apply.  */
8853 #ifdef __cplusplus
8854 extern "C"
8855 #endif
8856 char readline ();
8857 int
8858 main ()
8859 {
8860 return readline ();
8861   ;
8862   return 0;
8863 }
8864 _ACEOF
8865 rm -f conftest.$ac_objext conftest$ac_exeext
8866 if { (ac_try="$ac_link"
8867 case "(($ac_try" in
8868   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8869   *) ac_try_echo=$ac_try;;
8870 esac
8871 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8872 $as_echo "$ac_try_echo") >&5
8873   (eval "$ac_link") 2>conftest.er1
8874   ac_status=$?
8875   grep -v '^ *+' conftest.er1 >conftest.err
8876   rm -f conftest.er1
8877   cat conftest.err >&5
8878   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8879   (exit $ac_status); } && {
8880          test -z "$ac_c_werror_flag" ||
8881          test ! -s conftest.err
8882        } && test -s conftest$ac_exeext && {
8883          test "$cross_compiling" = yes ||
8884          $as_test_x conftest$ac_exeext
8885        }; then
8886
8887       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8888       # recognize dependent libraries; assume curses is needed if we didn't
8889       # find any dependency.
8890       case $host_os in
8891         netbsd* | openbsd* | irix*)
8892           if test x"$pgac_lib" = x"" ; then
8893             pgac_lib=" -lcurses"
8894           fi ;;
8895       esac
8896
8897       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8898       break
8899
8900 else
8901   $as_echo "$as_me: failed program was:" >&5
8902 sed 's/^/| /' conftest.$ac_ext >&5
8903
8904
8905 fi
8906
8907 rm -rf conftest.dSYM
8908 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8909       conftest$ac_exeext conftest.$ac_ext
8910   done
8911   if test "$pgac_cv_check_readline" != no ; then
8912     break
8913   fi
8914 done
8915 LIBS=$pgac_save_LIBS
8916
8917 fi
8918 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_readline" >&5
8919 $as_echo "$pgac_cv_check_readline" >&6; }
8920 if test "$pgac_cv_check_readline" != no ; then
8921   LIBS="$pgac_cv_check_readline $LIBS"
8922
8923 cat >>confdefs.h <<\_ACEOF
8924 #define HAVE_LIBREADLINE 1
8925 _ACEOF
8926
8927 fi
8928
8929
8930   if test x"$pgac_cv_check_readline" = x"no"; then
8931     { { $as_echo "$as_me:$LINENO: error: readline library not found
8932 If you have readline already installed, see config.log for details on the
8933 failure.  It is possible the compiler isn't looking in the proper directory.
8934 Use --without-readline to disable readline support." >&5
8935 $as_echo "$as_me: error: readline library not found
8936 If you have readline already installed, see config.log for details on the
8937 failure.  It is possible the compiler isn't looking in the proper directory.
8938 Use --without-readline to disable readline support." >&2;}
8939    { (exit 1); exit 1; }; }
8940   fi
8941 fi
8942
8943 if test "$with_zlib" = yes; then
8944
8945 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8946 $as_echo_n "checking for inflate in -lz... " >&6; }
8947 if test "${ac_cv_lib_z_inflate+set}" = set; then
8948   $as_echo_n "(cached) " >&6
8949 else
8950   ac_check_lib_save_LIBS=$LIBS
8951 LIBS="-lz  $LIBS"
8952 cat >conftest.$ac_ext <<_ACEOF
8953 /* confdefs.h.  */
8954 _ACEOF
8955 cat confdefs.h >>conftest.$ac_ext
8956 cat >>conftest.$ac_ext <<_ACEOF
8957 /* end confdefs.h.  */
8958
8959 /* Override any GCC internal prototype to avoid an error.
8960    Use char because int might match the return type of a GCC
8961    builtin and then its argument prototype would still apply.  */
8962 #ifdef __cplusplus
8963 extern "C"
8964 #endif
8965 char inflate ();
8966 int
8967 main ()
8968 {
8969 return inflate ();
8970   ;
8971   return 0;
8972 }
8973 _ACEOF
8974 rm -f conftest.$ac_objext conftest$ac_exeext
8975 if { (ac_try="$ac_link"
8976 case "(($ac_try" in
8977   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8978   *) ac_try_echo=$ac_try;;
8979 esac
8980 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8981 $as_echo "$ac_try_echo") >&5
8982   (eval "$ac_link") 2>conftest.er1
8983   ac_status=$?
8984   grep -v '^ *+' conftest.er1 >conftest.err
8985   rm -f conftest.er1
8986   cat conftest.err >&5
8987   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8988   (exit $ac_status); } && {
8989          test -z "$ac_c_werror_flag" ||
8990          test ! -s conftest.err
8991        } && test -s conftest$ac_exeext && {
8992          test "$cross_compiling" = yes ||
8993          $as_test_x conftest$ac_exeext
8994        }; then
8995   ac_cv_lib_z_inflate=yes
8996 else
8997   $as_echo "$as_me: failed program was:" >&5
8998 sed 's/^/| /' conftest.$ac_ext >&5
8999
9000         ac_cv_lib_z_inflate=no
9001 fi
9002
9003 rm -rf conftest.dSYM
9004 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9005       conftest$ac_exeext conftest.$ac_ext
9006 LIBS=$ac_check_lib_save_LIBS
9007 fi
9008 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
9009 $as_echo "$ac_cv_lib_z_inflate" >&6; }
9010 if test "x$ac_cv_lib_z_inflate" = x""yes; then
9011   cat >>confdefs.h <<_ACEOF
9012 #define HAVE_LIBZ 1
9013 _ACEOF
9014
9015   LIBS="-lz $LIBS"
9016
9017 else
9018   { { $as_echo "$as_me:$LINENO: error: zlib library not found
9019 If you have zlib already installed, see config.log for details on the
9020 failure.  It is possible the compiler isn't looking in the proper directory.
9021 Use --without-zlib to disable zlib support." >&5
9022 $as_echo "$as_me: error: zlib library not found
9023 If you have zlib already installed, see config.log for details on the
9024 failure.  It is possible the compiler isn't looking in the proper directory.
9025 Use --without-zlib to disable zlib support." >&2;}
9026    { (exit 1); exit 1; }; }
9027 fi
9028
9029 fi
9030
9031 if test "$enable_spinlocks" = yes; then
9032
9033 cat >>confdefs.h <<\_ACEOF
9034 #define HAVE_SPINLOCKS 1
9035 _ACEOF
9036
9037 else
9038   { $as_echo "$as_me:$LINENO: WARNING:
9039 *** Not using spinlocks will cause poor performance." >&5
9040 $as_echo "$as_me: WARNING:
9041 *** Not using spinlocks will cause poor performance." >&2;}
9042 fi
9043
9044 if test "$with_gssapi" = yes ; then
9045   if test "$PORTNAME" != "win32"; then
9046     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
9047 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
9048 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
9049   $as_echo_n "(cached) " >&6
9050 else
9051   ac_func_search_save_LIBS=$LIBS
9052 cat >conftest.$ac_ext <<_ACEOF
9053 /* confdefs.h.  */
9054 _ACEOF
9055 cat confdefs.h >>conftest.$ac_ext
9056 cat >>conftest.$ac_ext <<_ACEOF
9057 /* end confdefs.h.  */
9058
9059 /* Override any GCC internal prototype to avoid an error.
9060    Use char because int might match the return type of a GCC
9061    builtin and then its argument prototype would still apply.  */
9062 #ifdef __cplusplus
9063 extern "C"
9064 #endif
9065 char gss_init_sec_context ();
9066 int
9067 main ()
9068 {
9069 return gss_init_sec_context ();
9070   ;
9071   return 0;
9072 }
9073 _ACEOF
9074 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
9075   if test -z "$ac_lib"; then
9076     ac_res="none required"
9077   else
9078     ac_res=-l$ac_lib
9079     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9080   fi
9081   rm -f conftest.$ac_objext conftest$ac_exeext
9082 if { (ac_try="$ac_link"
9083 case "(($ac_try" in
9084   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9085   *) ac_try_echo=$ac_try;;
9086 esac
9087 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9088 $as_echo "$ac_try_echo") >&5
9089   (eval "$ac_link") 2>conftest.er1
9090   ac_status=$?
9091   grep -v '^ *+' conftest.er1 >conftest.err
9092   rm -f conftest.er1
9093   cat conftest.err >&5
9094   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9095   (exit $ac_status); } && {
9096          test -z "$ac_c_werror_flag" ||
9097          test ! -s conftest.err
9098        } && test -s conftest$ac_exeext && {
9099          test "$cross_compiling" = yes ||
9100          $as_test_x conftest$ac_exeext
9101        }; then
9102   ac_cv_search_gss_init_sec_context=$ac_res
9103 else
9104   $as_echo "$as_me: failed program was:" >&5
9105 sed 's/^/| /' conftest.$ac_ext >&5
9106
9107
9108 fi
9109
9110 rm -rf conftest.dSYM
9111 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9112       conftest$ac_exeext
9113   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
9114   break
9115 fi
9116 done
9117 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
9118   :
9119 else
9120   ac_cv_search_gss_init_sec_context=no
9121 fi
9122 rm conftest.$ac_ext
9123 LIBS=$ac_func_search_save_LIBS
9124 fi
9125 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
9126 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
9127 ac_res=$ac_cv_search_gss_init_sec_context
9128 if test "$ac_res" != no; then
9129   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9130
9131 else
9132   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
9133 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
9134    { (exit 1); exit 1; }; }
9135 fi
9136
9137   else
9138     LIBS="$LIBS -lgssapi32"
9139   fi
9140 fi
9141
9142 if test "$with_krb5" = yes ; then
9143   if test "$PORTNAME" != "win32"; then
9144      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
9145 $as_echo_n "checking for library containing com_err... " >&6; }
9146 if test "${ac_cv_search_com_err+set}" = set; then
9147   $as_echo_n "(cached) " >&6
9148 else
9149   ac_func_search_save_LIBS=$LIBS
9150 cat >conftest.$ac_ext <<_ACEOF
9151 /* confdefs.h.  */
9152 _ACEOF
9153 cat confdefs.h >>conftest.$ac_ext
9154 cat >>conftest.$ac_ext <<_ACEOF
9155 /* end confdefs.h.  */
9156
9157 /* Override any GCC internal prototype to avoid an error.
9158    Use char because int might match the return type of a GCC
9159    builtin and then its argument prototype would still apply.  */
9160 #ifdef __cplusplus
9161 extern "C"
9162 #endif
9163 char com_err ();
9164 int
9165 main ()
9166 {
9167 return com_err ();
9168   ;
9169   return 0;
9170 }
9171 _ACEOF
9172 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
9173   if test -z "$ac_lib"; then
9174     ac_res="none required"
9175   else
9176     ac_res=-l$ac_lib
9177     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9178   fi
9179   rm -f conftest.$ac_objext conftest$ac_exeext
9180 if { (ac_try="$ac_link"
9181 case "(($ac_try" in
9182   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9183   *) ac_try_echo=$ac_try;;
9184 esac
9185 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9186 $as_echo "$ac_try_echo") >&5
9187   (eval "$ac_link") 2>conftest.er1
9188   ac_status=$?
9189   grep -v '^ *+' conftest.er1 >conftest.err
9190   rm -f conftest.er1
9191   cat conftest.err >&5
9192   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9193   (exit $ac_status); } && {
9194          test -z "$ac_c_werror_flag" ||
9195          test ! -s conftest.err
9196        } && test -s conftest$ac_exeext && {
9197          test "$cross_compiling" = yes ||
9198          $as_test_x conftest$ac_exeext
9199        }; then
9200   ac_cv_search_com_err=$ac_res
9201 else
9202   $as_echo "$as_me: failed program was:" >&5
9203 sed 's/^/| /' conftest.$ac_ext >&5
9204
9205
9206 fi
9207
9208 rm -rf conftest.dSYM
9209 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9210       conftest$ac_exeext
9211   if test "${ac_cv_search_com_err+set}" = set; then
9212   break
9213 fi
9214 done
9215 if test "${ac_cv_search_com_err+set}" = set; then
9216   :
9217 else
9218   ac_cv_search_com_err=no
9219 fi
9220 rm conftest.$ac_ext
9221 LIBS=$ac_func_search_save_LIBS
9222 fi
9223 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
9224 $as_echo "$ac_cv_search_com_err" >&6; }
9225 ac_res=$ac_cv_search_com_err
9226 if test "$ac_res" != no; then
9227   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9228
9229 else
9230   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
9231 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
9232    { (exit 1); exit 1; }; }
9233 fi
9234
9235      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
9236 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
9237 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
9238   $as_echo_n "(cached) " >&6
9239 else
9240   ac_func_search_save_LIBS=$LIBS
9241 cat >conftest.$ac_ext <<_ACEOF
9242 /* confdefs.h.  */
9243 _ACEOF
9244 cat confdefs.h >>conftest.$ac_ext
9245 cat >>conftest.$ac_ext <<_ACEOF
9246 /* end confdefs.h.  */
9247
9248 /* Override any GCC internal prototype to avoid an error.
9249    Use char because int might match the return type of a GCC
9250    builtin and then its argument prototype would still apply.  */
9251 #ifdef __cplusplus
9252 extern "C"
9253 #endif
9254 char krb5_sendauth ();
9255 int
9256 main ()
9257 {
9258 return krb5_sendauth ();
9259   ;
9260   return 0;
9261 }
9262 _ACEOF
9263 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
9264   if test -z "$ac_lib"; then
9265     ac_res="none required"
9266   else
9267     ac_res=-l$ac_lib
9268     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9269   fi
9270   rm -f conftest.$ac_objext conftest$ac_exeext
9271 if { (ac_try="$ac_link"
9272 case "(($ac_try" in
9273   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9274   *) ac_try_echo=$ac_try;;
9275 esac
9276 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9277 $as_echo "$ac_try_echo") >&5
9278   (eval "$ac_link") 2>conftest.er1
9279   ac_status=$?
9280   grep -v '^ *+' conftest.er1 >conftest.err
9281   rm -f conftest.er1
9282   cat conftest.err >&5
9283   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9284   (exit $ac_status); } && {
9285          test -z "$ac_c_werror_flag" ||
9286          test ! -s conftest.err
9287        } && test -s conftest$ac_exeext && {
9288          test "$cross_compiling" = yes ||
9289          $as_test_x conftest$ac_exeext
9290        }; then
9291   ac_cv_search_krb5_sendauth=$ac_res
9292 else
9293   $as_echo "$as_me: failed program was:" >&5
9294 sed 's/^/| /' conftest.$ac_ext >&5
9295
9296
9297 fi
9298
9299 rm -rf conftest.dSYM
9300 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9301       conftest$ac_exeext
9302   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
9303   break
9304 fi
9305 done
9306 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
9307   :
9308 else
9309   ac_cv_search_krb5_sendauth=no
9310 fi
9311 rm conftest.$ac_ext
9312 LIBS=$ac_func_search_save_LIBS
9313 fi
9314 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
9315 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
9316 ac_res=$ac_cv_search_krb5_sendauth
9317 if test "$ac_res" != no; then
9318   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9319
9320 else
9321   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
9322 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
9323    { (exit 1); exit 1; }; }
9324 fi
9325
9326   else
9327      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
9328 $as_echo_n "checking for library containing com_err... " >&6; }
9329 if test "${ac_cv_search_com_err+set}" = set; then
9330   $as_echo_n "(cached) " >&6
9331 else
9332   ac_func_search_save_LIBS=$LIBS
9333 cat >conftest.$ac_ext <<_ACEOF
9334 /* confdefs.h.  */
9335 _ACEOF
9336 cat confdefs.h >>conftest.$ac_ext
9337 cat >>conftest.$ac_ext <<_ACEOF
9338 /* end confdefs.h.  */
9339
9340 /* Override any GCC internal prototype to avoid an error.
9341    Use char because int might match the return type of a GCC
9342    builtin and then its argument prototype would still apply.  */
9343 #ifdef __cplusplus
9344 extern "C"
9345 #endif
9346 char com_err ();
9347 int
9348 main ()
9349 {
9350 return com_err ();
9351   ;
9352   return 0;
9353 }
9354 _ACEOF
9355 for ac_lib in '' 'comerr32 -lkrb5_32'; do
9356   if test -z "$ac_lib"; then
9357     ac_res="none required"
9358   else
9359     ac_res=-l$ac_lib
9360     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9361   fi
9362   rm -f conftest.$ac_objext conftest$ac_exeext
9363 if { (ac_try="$ac_link"
9364 case "(($ac_try" in
9365   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9366   *) ac_try_echo=$ac_try;;
9367 esac
9368 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9369 $as_echo "$ac_try_echo") >&5
9370   (eval "$ac_link") 2>conftest.er1
9371   ac_status=$?
9372   grep -v '^ *+' conftest.er1 >conftest.err
9373   rm -f conftest.er1
9374   cat conftest.err >&5
9375   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9376   (exit $ac_status); } && {
9377          test -z "$ac_c_werror_flag" ||
9378          test ! -s conftest.err
9379        } && test -s conftest$ac_exeext && {
9380          test "$cross_compiling" = yes ||
9381          $as_test_x conftest$ac_exeext
9382        }; then
9383   ac_cv_search_com_err=$ac_res
9384 else
9385   $as_echo "$as_me: failed program was:" >&5
9386 sed 's/^/| /' conftest.$ac_ext >&5
9387
9388
9389 fi
9390
9391 rm -rf conftest.dSYM
9392 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9393       conftest$ac_exeext
9394   if test "${ac_cv_search_com_err+set}" = set; then
9395   break
9396 fi
9397 done
9398 if test "${ac_cv_search_com_err+set}" = set; then
9399   :
9400 else
9401   ac_cv_search_com_err=no
9402 fi
9403 rm conftest.$ac_ext
9404 LIBS=$ac_func_search_save_LIBS
9405 fi
9406 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
9407 $as_echo "$ac_cv_search_com_err" >&6; }
9408 ac_res=$ac_cv_search_com_err
9409 if test "$ac_res" != no; then
9410   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9411
9412 else
9413   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
9414 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
9415    { (exit 1); exit 1; }; }
9416 fi
9417
9418   fi
9419 fi
9420
9421 if test "$with_openssl" = yes ; then
9422     if test "$PORTNAME" != "win32"; then
9423
9424 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
9425 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
9426 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
9427   $as_echo_n "(cached) " >&6
9428 else
9429   ac_check_lib_save_LIBS=$LIBS
9430 LIBS="-lcrypto  $LIBS"
9431 cat >conftest.$ac_ext <<_ACEOF
9432 /* confdefs.h.  */
9433 _ACEOF
9434 cat confdefs.h >>conftest.$ac_ext
9435 cat >>conftest.$ac_ext <<_ACEOF
9436 /* end confdefs.h.  */
9437
9438 /* Override any GCC internal prototype to avoid an error.
9439    Use char because int might match the return type of a GCC
9440    builtin and then its argument prototype would still apply.  */
9441 #ifdef __cplusplus
9442 extern "C"
9443 #endif
9444 char CRYPTO_new_ex_data ();
9445 int
9446 main ()
9447 {
9448 return CRYPTO_new_ex_data ();
9449   ;
9450   return 0;
9451 }
9452 _ACEOF
9453 rm -f conftest.$ac_objext conftest$ac_exeext
9454 if { (ac_try="$ac_link"
9455 case "(($ac_try" in
9456   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9457   *) ac_try_echo=$ac_try;;
9458 esac
9459 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9460 $as_echo "$ac_try_echo") >&5
9461   (eval "$ac_link") 2>conftest.er1
9462   ac_status=$?
9463   grep -v '^ *+' conftest.er1 >conftest.err
9464   rm -f conftest.er1
9465   cat conftest.err >&5
9466   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9467   (exit $ac_status); } && {
9468          test -z "$ac_c_werror_flag" ||
9469          test ! -s conftest.err
9470        } && test -s conftest$ac_exeext && {
9471          test "$cross_compiling" = yes ||
9472          $as_test_x conftest$ac_exeext
9473        }; then
9474   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
9475 else
9476   $as_echo "$as_me: failed program was:" >&5
9477 sed 's/^/| /' conftest.$ac_ext >&5
9478
9479         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
9480 fi
9481
9482 rm -rf conftest.dSYM
9483 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9484       conftest$ac_exeext conftest.$ac_ext
9485 LIBS=$ac_check_lib_save_LIBS
9486 fi
9487 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
9488 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
9489 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
9490   cat >>confdefs.h <<_ACEOF
9491 #define HAVE_LIBCRYPTO 1
9492 _ACEOF
9493
9494   LIBS="-lcrypto $LIBS"
9495
9496 else
9497   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
9498 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
9499    { (exit 1); exit 1; }; }
9500 fi
9501
9502
9503 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
9504 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
9505 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
9506   $as_echo_n "(cached) " >&6
9507 else
9508   ac_check_lib_save_LIBS=$LIBS
9509 LIBS="-lssl  $LIBS"
9510 cat >conftest.$ac_ext <<_ACEOF
9511 /* confdefs.h.  */
9512 _ACEOF
9513 cat confdefs.h >>conftest.$ac_ext
9514 cat >>conftest.$ac_ext <<_ACEOF
9515 /* end confdefs.h.  */
9516
9517 /* Override any GCC internal prototype to avoid an error.
9518    Use char because int might match the return type of a GCC
9519    builtin and then its argument prototype would still apply.  */
9520 #ifdef __cplusplus
9521 extern "C"
9522 #endif
9523 char SSL_library_init ();
9524 int
9525 main ()
9526 {
9527 return SSL_library_init ();
9528   ;
9529   return 0;
9530 }
9531 _ACEOF
9532 rm -f conftest.$ac_objext conftest$ac_exeext
9533 if { (ac_try="$ac_link"
9534 case "(($ac_try" in
9535   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9536   *) ac_try_echo=$ac_try;;
9537 esac
9538 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9539 $as_echo "$ac_try_echo") >&5
9540   (eval "$ac_link") 2>conftest.er1
9541   ac_status=$?
9542   grep -v '^ *+' conftest.er1 >conftest.err
9543   rm -f conftest.er1
9544   cat conftest.err >&5
9545   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9546   (exit $ac_status); } && {
9547          test -z "$ac_c_werror_flag" ||
9548          test ! -s conftest.err
9549        } && test -s conftest$ac_exeext && {
9550          test "$cross_compiling" = yes ||
9551          $as_test_x conftest$ac_exeext
9552        }; then
9553   ac_cv_lib_ssl_SSL_library_init=yes
9554 else
9555   $as_echo "$as_me: failed program was:" >&5
9556 sed 's/^/| /' conftest.$ac_ext >&5
9557
9558         ac_cv_lib_ssl_SSL_library_init=no
9559 fi
9560
9561 rm -rf conftest.dSYM
9562 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9563       conftest$ac_exeext conftest.$ac_ext
9564 LIBS=$ac_check_lib_save_LIBS
9565 fi
9566 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
9567 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
9568 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
9569   cat >>confdefs.h <<_ACEOF
9570 #define HAVE_LIBSSL 1
9571 _ACEOF
9572
9573   LIBS="-lssl $LIBS"
9574
9575 else
9576   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
9577 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
9578    { (exit 1); exit 1; }; }
9579 fi
9580
9581   else
9582      { $as_echo "$as_me:$LINENO: checking for library containing CRYPTO_new_ex_data" >&5
9583 $as_echo_n "checking for library containing CRYPTO_new_ex_data... " >&6; }
9584 if test "${ac_cv_search_CRYPTO_new_ex_data+set}" = set; then
9585   $as_echo_n "(cached) " >&6
9586 else
9587   ac_func_search_save_LIBS=$LIBS
9588 cat >conftest.$ac_ext <<_ACEOF
9589 /* confdefs.h.  */
9590 _ACEOF
9591 cat confdefs.h >>conftest.$ac_ext
9592 cat >>conftest.$ac_ext <<_ACEOF
9593 /* end confdefs.h.  */
9594
9595 /* Override any GCC internal prototype to avoid an error.
9596    Use char because int might match the return type of a GCC
9597    builtin and then its argument prototype would still apply.  */
9598 #ifdef __cplusplus
9599 extern "C"
9600 #endif
9601 char CRYPTO_new_ex_data ();
9602 int
9603 main ()
9604 {
9605 return CRYPTO_new_ex_data ();
9606   ;
9607   return 0;
9608 }
9609 _ACEOF
9610 for ac_lib in '' eay32 crypto; do
9611   if test -z "$ac_lib"; then
9612     ac_res="none required"
9613   else
9614     ac_res=-l$ac_lib
9615     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9616   fi
9617   rm -f conftest.$ac_objext conftest$ac_exeext
9618 if { (ac_try="$ac_link"
9619 case "(($ac_try" in
9620   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9621   *) ac_try_echo=$ac_try;;
9622 esac
9623 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9624 $as_echo "$ac_try_echo") >&5
9625   (eval "$ac_link") 2>conftest.er1
9626   ac_status=$?
9627   grep -v '^ *+' conftest.er1 >conftest.err
9628   rm -f conftest.er1
9629   cat conftest.err >&5
9630   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9631   (exit $ac_status); } && {
9632          test -z "$ac_c_werror_flag" ||
9633          test ! -s conftest.err
9634        } && test -s conftest$ac_exeext && {
9635          test "$cross_compiling" = yes ||
9636          $as_test_x conftest$ac_exeext
9637        }; then
9638   ac_cv_search_CRYPTO_new_ex_data=$ac_res
9639 else
9640   $as_echo "$as_me: failed program was:" >&5
9641 sed 's/^/| /' conftest.$ac_ext >&5
9642
9643
9644 fi
9645
9646 rm -rf conftest.dSYM
9647 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9648       conftest$ac_exeext
9649   if test "${ac_cv_search_CRYPTO_new_ex_data+set}" = set; then
9650   break
9651 fi
9652 done
9653 if test "${ac_cv_search_CRYPTO_new_ex_data+set}" = set; then
9654   :
9655 else
9656   ac_cv_search_CRYPTO_new_ex_data=no
9657 fi
9658 rm conftest.$ac_ext
9659 LIBS=$ac_func_search_save_LIBS
9660 fi
9661 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_CRYPTO_new_ex_data" >&5
9662 $as_echo "$ac_cv_search_CRYPTO_new_ex_data" >&6; }
9663 ac_res=$ac_cv_search_CRYPTO_new_ex_data
9664 if test "$ac_res" != no; then
9665   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9666
9667 else
9668   { { $as_echo "$as_me:$LINENO: error: library 'eay32' or 'crypto' is required for OpenSSL" >&5
9669 $as_echo "$as_me: error: library 'eay32' or 'crypto' is required for OpenSSL" >&2;}
9670    { (exit 1); exit 1; }; }
9671 fi
9672
9673      { $as_echo "$as_me:$LINENO: checking for library containing SSL_library_init" >&5
9674 $as_echo_n "checking for library containing SSL_library_init... " >&6; }
9675 if test "${ac_cv_search_SSL_library_init+set}" = set; then
9676   $as_echo_n "(cached) " >&6
9677 else
9678   ac_func_search_save_LIBS=$LIBS
9679 cat >conftest.$ac_ext <<_ACEOF
9680 /* confdefs.h.  */
9681 _ACEOF
9682 cat confdefs.h >>conftest.$ac_ext
9683 cat >>conftest.$ac_ext <<_ACEOF
9684 /* end confdefs.h.  */
9685
9686 /* Override any GCC internal prototype to avoid an error.
9687    Use char because int might match the return type of a GCC
9688    builtin and then its argument prototype would still apply.  */
9689 #ifdef __cplusplus
9690 extern "C"
9691 #endif
9692 char SSL_library_init ();
9693 int
9694 main ()
9695 {
9696 return SSL_library_init ();
9697   ;
9698   return 0;
9699 }
9700 _ACEOF
9701 for ac_lib in '' ssleay32 ssl; do
9702   if test -z "$ac_lib"; then
9703     ac_res="none required"
9704   else
9705     ac_res=-l$ac_lib
9706     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9707   fi
9708   rm -f conftest.$ac_objext conftest$ac_exeext
9709 if { (ac_try="$ac_link"
9710 case "(($ac_try" in
9711   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9712   *) ac_try_echo=$ac_try;;
9713 esac
9714 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9715 $as_echo "$ac_try_echo") >&5
9716   (eval "$ac_link") 2>conftest.er1
9717   ac_status=$?
9718   grep -v '^ *+' conftest.er1 >conftest.err
9719   rm -f conftest.er1
9720   cat conftest.err >&5
9721   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9722   (exit $ac_status); } && {
9723          test -z "$ac_c_werror_flag" ||
9724          test ! -s conftest.err
9725        } && test -s conftest$ac_exeext && {
9726          test "$cross_compiling" = yes ||
9727          $as_test_x conftest$ac_exeext
9728        }; then
9729   ac_cv_search_SSL_library_init=$ac_res
9730 else
9731   $as_echo "$as_me: failed program was:" >&5
9732 sed 's/^/| /' conftest.$ac_ext >&5
9733
9734
9735 fi
9736
9737 rm -rf conftest.dSYM
9738 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9739       conftest$ac_exeext
9740   if test "${ac_cv_search_SSL_library_init+set}" = set; then
9741   break
9742 fi
9743 done
9744 if test "${ac_cv_search_SSL_library_init+set}" = set; then
9745   :
9746 else
9747   ac_cv_search_SSL_library_init=no
9748 fi
9749 rm conftest.$ac_ext
9750 LIBS=$ac_func_search_save_LIBS
9751 fi
9752 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_SSL_library_init" >&5
9753 $as_echo "$ac_cv_search_SSL_library_init" >&6; }
9754 ac_res=$ac_cv_search_SSL_library_init
9755 if test "$ac_res" != no; then
9756   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9757
9758 else
9759   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' or 'ssl' is required for OpenSSL" >&5
9760 $as_echo "$as_me: error: library 'ssleay32' or 'ssl' is required for OpenSSL" >&2;}
9761    { (exit 1); exit 1; }; }
9762 fi
9763
9764   fi
9765 fi
9766
9767 if test "$with_pam" = yes ; then
9768
9769 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
9770 $as_echo_n "checking for pam_start in -lpam... " >&6; }
9771 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
9772   $as_echo_n "(cached) " >&6
9773 else
9774   ac_check_lib_save_LIBS=$LIBS
9775 LIBS="-lpam  $LIBS"
9776 cat >conftest.$ac_ext <<_ACEOF
9777 /* confdefs.h.  */
9778 _ACEOF
9779 cat confdefs.h >>conftest.$ac_ext
9780 cat >>conftest.$ac_ext <<_ACEOF
9781 /* end confdefs.h.  */
9782
9783 /* Override any GCC internal prototype to avoid an error.
9784    Use char because int might match the return type of a GCC
9785    builtin and then its argument prototype would still apply.  */
9786 #ifdef __cplusplus
9787 extern "C"
9788 #endif
9789 char pam_start ();
9790 int
9791 main ()
9792 {
9793 return pam_start ();
9794   ;
9795   return 0;
9796 }
9797 _ACEOF
9798 rm -f conftest.$ac_objext conftest$ac_exeext
9799 if { (ac_try="$ac_link"
9800 case "(($ac_try" in
9801   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9802   *) ac_try_echo=$ac_try;;
9803 esac
9804 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9805 $as_echo "$ac_try_echo") >&5
9806   (eval "$ac_link") 2>conftest.er1
9807   ac_status=$?
9808   grep -v '^ *+' conftest.er1 >conftest.err
9809   rm -f conftest.er1
9810   cat conftest.err >&5
9811   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9812   (exit $ac_status); } && {
9813          test -z "$ac_c_werror_flag" ||
9814          test ! -s conftest.err
9815        } && test -s conftest$ac_exeext && {
9816          test "$cross_compiling" = yes ||
9817          $as_test_x conftest$ac_exeext
9818        }; then
9819   ac_cv_lib_pam_pam_start=yes
9820 else
9821   $as_echo "$as_me: failed program was:" >&5
9822 sed 's/^/| /' conftest.$ac_ext >&5
9823
9824         ac_cv_lib_pam_pam_start=no
9825 fi
9826
9827 rm -rf conftest.dSYM
9828 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9829       conftest$ac_exeext conftest.$ac_ext
9830 LIBS=$ac_check_lib_save_LIBS
9831 fi
9832 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9833 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9834 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9835   cat >>confdefs.h <<_ACEOF
9836 #define HAVE_LIBPAM 1
9837 _ACEOF
9838
9839   LIBS="-lpam $LIBS"
9840
9841 else
9842   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9843 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9844    { (exit 1); exit 1; }; }
9845 fi
9846
9847 fi
9848
9849 if test "$with_libxml" = yes ; then
9850
9851 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9852 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9853 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9854   $as_echo_n "(cached) " >&6
9855 else
9856   ac_check_lib_save_LIBS=$LIBS
9857 LIBS="-lxml2  $LIBS"
9858 cat >conftest.$ac_ext <<_ACEOF
9859 /* confdefs.h.  */
9860 _ACEOF
9861 cat confdefs.h >>conftest.$ac_ext
9862 cat >>conftest.$ac_ext <<_ACEOF
9863 /* end confdefs.h.  */
9864
9865 /* Override any GCC internal prototype to avoid an error.
9866    Use char because int might match the return type of a GCC
9867    builtin and then its argument prototype would still apply.  */
9868 #ifdef __cplusplus
9869 extern "C"
9870 #endif
9871 char xmlSaveToBuffer ();
9872 int
9873 main ()
9874 {
9875 return xmlSaveToBuffer ();
9876   ;
9877   return 0;
9878 }
9879 _ACEOF
9880 rm -f conftest.$ac_objext conftest$ac_exeext
9881 if { (ac_try="$ac_link"
9882 case "(($ac_try" in
9883   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9884   *) ac_try_echo=$ac_try;;
9885 esac
9886 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9887 $as_echo "$ac_try_echo") >&5
9888   (eval "$ac_link") 2>conftest.er1
9889   ac_status=$?
9890   grep -v '^ *+' conftest.er1 >conftest.err
9891   rm -f conftest.er1
9892   cat conftest.err >&5
9893   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9894   (exit $ac_status); } && {
9895          test -z "$ac_c_werror_flag" ||
9896          test ! -s conftest.err
9897        } && test -s conftest$ac_exeext && {
9898          test "$cross_compiling" = yes ||
9899          $as_test_x conftest$ac_exeext
9900        }; then
9901   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9902 else
9903   $as_echo "$as_me: failed program was:" >&5
9904 sed 's/^/| /' conftest.$ac_ext >&5
9905
9906         ac_cv_lib_xml2_xmlSaveToBuffer=no
9907 fi
9908
9909 rm -rf conftest.dSYM
9910 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9911       conftest$ac_exeext conftest.$ac_ext
9912 LIBS=$ac_check_lib_save_LIBS
9913 fi
9914 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9915 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9916 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9917   cat >>confdefs.h <<_ACEOF
9918 #define HAVE_LIBXML2 1
9919 _ACEOF
9920
9921   LIBS="-lxml2 $LIBS"
9922
9923 else
9924   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9925 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9926    { (exit 1); exit 1; }; }
9927 fi
9928
9929 fi
9930
9931 if test "$with_libxslt" = yes ; then
9932
9933 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9934 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9935 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9936   $as_echo_n "(cached) " >&6
9937 else
9938   ac_check_lib_save_LIBS=$LIBS
9939 LIBS="-lxslt  $LIBS"
9940 cat >conftest.$ac_ext <<_ACEOF
9941 /* confdefs.h.  */
9942 _ACEOF
9943 cat confdefs.h >>conftest.$ac_ext
9944 cat >>conftest.$ac_ext <<_ACEOF
9945 /* end confdefs.h.  */
9946
9947 /* Override any GCC internal prototype to avoid an error.
9948    Use char because int might match the return type of a GCC
9949    builtin and then its argument prototype would still apply.  */
9950 #ifdef __cplusplus
9951 extern "C"
9952 #endif
9953 char xsltCleanupGlobals ();
9954 int
9955 main ()
9956 {
9957 return xsltCleanupGlobals ();
9958   ;
9959   return 0;
9960 }
9961 _ACEOF
9962 rm -f conftest.$ac_objext conftest$ac_exeext
9963 if { (ac_try="$ac_link"
9964 case "(($ac_try" in
9965   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9966   *) ac_try_echo=$ac_try;;
9967 esac
9968 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9969 $as_echo "$ac_try_echo") >&5
9970   (eval "$ac_link") 2>conftest.er1
9971   ac_status=$?
9972   grep -v '^ *+' conftest.er1 >conftest.err
9973   rm -f conftest.er1
9974   cat conftest.err >&5
9975   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9976   (exit $ac_status); } && {
9977          test -z "$ac_c_werror_flag" ||
9978          test ! -s conftest.err
9979        } && test -s conftest$ac_exeext && {
9980          test "$cross_compiling" = yes ||
9981          $as_test_x conftest$ac_exeext
9982        }; then
9983   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9984 else
9985   $as_echo "$as_me: failed program was:" >&5
9986 sed 's/^/| /' conftest.$ac_ext >&5
9987
9988         ac_cv_lib_xslt_xsltCleanupGlobals=no
9989 fi
9990
9991 rm -rf conftest.dSYM
9992 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9993       conftest$ac_exeext conftest.$ac_ext
9994 LIBS=$ac_check_lib_save_LIBS
9995 fi
9996 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9997 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9998 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9999   cat >>confdefs.h <<_ACEOF
10000 #define HAVE_LIBXSLT 1
10001 _ACEOF
10002
10003   LIBS="-lxslt $LIBS"
10004
10005 else
10006   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
10007 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
10008    { (exit 1); exit 1; }; }
10009 fi
10010
10011 fi
10012
10013 # for contrib/sepgsql
10014 if test "$with_selinux" = yes; then
10015
10016 { $as_echo "$as_me:$LINENO: checking for security_compute_create_name in -lselinux" >&5
10017 $as_echo_n "checking for security_compute_create_name in -lselinux... " >&6; }
10018 if test "${ac_cv_lib_selinux_security_compute_create_name+set}" = set; then
10019   $as_echo_n "(cached) " >&6
10020 else
10021   ac_check_lib_save_LIBS=$LIBS
10022 LIBS="-lselinux  $LIBS"
10023 cat >conftest.$ac_ext <<_ACEOF
10024 /* confdefs.h.  */
10025 _ACEOF
10026 cat confdefs.h >>conftest.$ac_ext
10027 cat >>conftest.$ac_ext <<_ACEOF
10028 /* end confdefs.h.  */
10029
10030 /* Override any GCC internal prototype to avoid an error.
10031    Use char because int might match the return type of a GCC
10032    builtin and then its argument prototype would still apply.  */
10033 #ifdef __cplusplus
10034 extern "C"
10035 #endif
10036 char security_compute_create_name ();
10037 int
10038 main ()
10039 {
10040 return security_compute_create_name ();
10041   ;
10042   return 0;
10043 }
10044 _ACEOF
10045 rm -f conftest.$ac_objext conftest$ac_exeext
10046 if { (ac_try="$ac_link"
10047 case "(($ac_try" in
10048   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10049   *) ac_try_echo=$ac_try;;
10050 esac
10051 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10052 $as_echo "$ac_try_echo") >&5
10053   (eval "$ac_link") 2>conftest.er1
10054   ac_status=$?
10055   grep -v '^ *+' conftest.er1 >conftest.err
10056   rm -f conftest.er1
10057   cat conftest.err >&5
10058   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10059   (exit $ac_status); } && {
10060          test -z "$ac_c_werror_flag" ||
10061          test ! -s conftest.err
10062        } && test -s conftest$ac_exeext && {
10063          test "$cross_compiling" = yes ||
10064          $as_test_x conftest$ac_exeext
10065        }; then
10066   ac_cv_lib_selinux_security_compute_create_name=yes
10067 else
10068   $as_echo "$as_me: failed program was:" >&5
10069 sed 's/^/| /' conftest.$ac_ext >&5
10070
10071         ac_cv_lib_selinux_security_compute_create_name=no
10072 fi
10073
10074 rm -rf conftest.dSYM
10075 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10076       conftest$ac_exeext conftest.$ac_ext
10077 LIBS=$ac_check_lib_save_LIBS
10078 fi
10079 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_security_compute_create_name" >&5
10080 $as_echo "$ac_cv_lib_selinux_security_compute_create_name" >&6; }
10081 if test "x$ac_cv_lib_selinux_security_compute_create_name" = x""yes; then
10082   cat >>confdefs.h <<_ACEOF
10083 #define HAVE_LIBSELINUX 1
10084 _ACEOF
10085
10086   LIBS="-lselinux $LIBS"
10087
10088 else
10089   { { $as_echo "$as_me:$LINENO: error: library 'libselinux', version 2.1.10 or newer, is required for SELinux support" >&5
10090 $as_echo "$as_me: error: library 'libselinux', version 2.1.10 or newer, is required for SELinux support" >&2;}
10091    { (exit 1); exit 1; }; }
10092 fi
10093
10094 fi
10095
10096 # for contrib/uuid-ossp
10097 if test "$with_ossp_uuid" = yes ; then
10098   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
10099 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
10100 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
10101   $as_echo_n "(cached) " >&6
10102 else
10103   ac_check_lib_save_LIBS=$LIBS
10104 LIBS="-lossp-uuid  $LIBS"
10105 cat >conftest.$ac_ext <<_ACEOF
10106 /* confdefs.h.  */
10107 _ACEOF
10108 cat confdefs.h >>conftest.$ac_ext
10109 cat >>conftest.$ac_ext <<_ACEOF
10110 /* end confdefs.h.  */
10111
10112 /* Override any GCC internal prototype to avoid an error.
10113    Use char because int might match the return type of a GCC
10114    builtin and then its argument prototype would still apply.  */
10115 #ifdef __cplusplus
10116 extern "C"
10117 #endif
10118 char uuid_export ();
10119 int
10120 main ()
10121 {
10122 return uuid_export ();
10123   ;
10124   return 0;
10125 }
10126 _ACEOF
10127 rm -f conftest.$ac_objext conftest$ac_exeext
10128 if { (ac_try="$ac_link"
10129 case "(($ac_try" in
10130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10131   *) ac_try_echo=$ac_try;;
10132 esac
10133 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10134 $as_echo "$ac_try_echo") >&5
10135   (eval "$ac_link") 2>conftest.er1
10136   ac_status=$?
10137   grep -v '^ *+' conftest.er1 >conftest.err
10138   rm -f conftest.er1
10139   cat conftest.err >&5
10140   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10141   (exit $ac_status); } && {
10142          test -z "$ac_c_werror_flag" ||
10143          test ! -s conftest.err
10144        } && test -s conftest$ac_exeext && {
10145          test "$cross_compiling" = yes ||
10146          $as_test_x conftest$ac_exeext
10147        }; then
10148   ac_cv_lib_ossp_uuid_uuid_export=yes
10149 else
10150   $as_echo "$as_me: failed program was:" >&5
10151 sed 's/^/| /' conftest.$ac_ext >&5
10152
10153         ac_cv_lib_ossp_uuid_uuid_export=no
10154 fi
10155
10156 rm -rf conftest.dSYM
10157 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10158       conftest$ac_exeext conftest.$ac_ext
10159 LIBS=$ac_check_lib_save_LIBS
10160 fi
10161 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
10162 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
10163 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
10164   OSSP_UUID_LIBS="-lossp-uuid"
10165 else
10166   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
10167 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
10168 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
10169   $as_echo_n "(cached) " >&6
10170 else
10171   ac_check_lib_save_LIBS=$LIBS
10172 LIBS="-luuid  $LIBS"
10173 cat >conftest.$ac_ext <<_ACEOF
10174 /* confdefs.h.  */
10175 _ACEOF
10176 cat confdefs.h >>conftest.$ac_ext
10177 cat >>conftest.$ac_ext <<_ACEOF
10178 /* end confdefs.h.  */
10179
10180 /* Override any GCC internal prototype to avoid an error.
10181    Use char because int might match the return type of a GCC
10182    builtin and then its argument prototype would still apply.  */
10183 #ifdef __cplusplus
10184 extern "C"
10185 #endif
10186 char uuid_export ();
10187 int
10188 main ()
10189 {
10190 return uuid_export ();
10191   ;
10192   return 0;
10193 }
10194 _ACEOF
10195 rm -f conftest.$ac_objext conftest$ac_exeext
10196 if { (ac_try="$ac_link"
10197 case "(($ac_try" in
10198   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10199   *) ac_try_echo=$ac_try;;
10200 esac
10201 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10202 $as_echo "$ac_try_echo") >&5
10203   (eval "$ac_link") 2>conftest.er1
10204   ac_status=$?
10205   grep -v '^ *+' conftest.er1 >conftest.err
10206   rm -f conftest.er1
10207   cat conftest.err >&5
10208   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10209   (exit $ac_status); } && {
10210          test -z "$ac_c_werror_flag" ||
10211          test ! -s conftest.err
10212        } && test -s conftest$ac_exeext && {
10213          test "$cross_compiling" = yes ||
10214          $as_test_x conftest$ac_exeext
10215        }; then
10216   ac_cv_lib_uuid_uuid_export=yes
10217 else
10218   $as_echo "$as_me: failed program was:" >&5
10219 sed 's/^/| /' conftest.$ac_ext >&5
10220
10221         ac_cv_lib_uuid_uuid_export=no
10222 fi
10223
10224 rm -rf conftest.dSYM
10225 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10226       conftest$ac_exeext conftest.$ac_ext
10227 LIBS=$ac_check_lib_save_LIBS
10228 fi
10229 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
10230 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
10231 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
10232   OSSP_UUID_LIBS="-luuid"
10233 else
10234   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
10235 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
10236    { (exit 1); exit 1; }; }
10237 fi
10238
10239 fi
10240
10241 fi
10242
10243
10244
10245 ##
10246 ## Header files
10247 ##
10248
10249 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
10250 $as_echo_n "checking for ANSI C header files... " >&6; }
10251 if test "${ac_cv_header_stdc+set}" = set; then
10252   $as_echo_n "(cached) " >&6
10253 else
10254   cat >conftest.$ac_ext <<_ACEOF
10255 /* confdefs.h.  */
10256 _ACEOF
10257 cat confdefs.h >>conftest.$ac_ext
10258 cat >>conftest.$ac_ext <<_ACEOF
10259 /* end confdefs.h.  */
10260 #include <stdlib.h>
10261 #include <stdarg.h>
10262 #include <string.h>
10263 #include <float.h>
10264
10265 int
10266 main ()
10267 {
10268
10269   ;
10270   return 0;
10271 }
10272 _ACEOF
10273 rm -f conftest.$ac_objext
10274 if { (ac_try="$ac_compile"
10275 case "(($ac_try" in
10276   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10277   *) ac_try_echo=$ac_try;;
10278 esac
10279 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10280 $as_echo "$ac_try_echo") >&5
10281   (eval "$ac_compile") 2>conftest.er1
10282   ac_status=$?
10283   grep -v '^ *+' conftest.er1 >conftest.err
10284   rm -f conftest.er1
10285   cat conftest.err >&5
10286   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10287   (exit $ac_status); } && {
10288          test -z "$ac_c_werror_flag" ||
10289          test ! -s conftest.err
10290        } && test -s conftest.$ac_objext; then
10291   ac_cv_header_stdc=yes
10292 else
10293   $as_echo "$as_me: failed program was:" >&5
10294 sed 's/^/| /' conftest.$ac_ext >&5
10295
10296         ac_cv_header_stdc=no
10297 fi
10298
10299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10300
10301 if test $ac_cv_header_stdc = yes; then
10302   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10303   cat >conftest.$ac_ext <<_ACEOF
10304 /* confdefs.h.  */
10305 _ACEOF
10306 cat confdefs.h >>conftest.$ac_ext
10307 cat >>conftest.$ac_ext <<_ACEOF
10308 /* end confdefs.h.  */
10309 #include <string.h>
10310
10311 _ACEOF
10312 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10313   $EGREP "memchr" >/dev/null 2>&1; then
10314   :
10315 else
10316   ac_cv_header_stdc=no
10317 fi
10318 rm -f conftest*
10319
10320 fi
10321
10322 if test $ac_cv_header_stdc = yes; then
10323   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10324   cat >conftest.$ac_ext <<_ACEOF
10325 /* confdefs.h.  */
10326 _ACEOF
10327 cat confdefs.h >>conftest.$ac_ext
10328 cat >>conftest.$ac_ext <<_ACEOF
10329 /* end confdefs.h.  */
10330 #include <stdlib.h>
10331
10332 _ACEOF
10333 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10334   $EGREP "free" >/dev/null 2>&1; then
10335   :
10336 else
10337   ac_cv_header_stdc=no
10338 fi
10339 rm -f conftest*
10340
10341 fi
10342
10343 if test $ac_cv_header_stdc = yes; then
10344   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10345   if test "$cross_compiling" = yes; then
10346   :
10347 else
10348   cat >conftest.$ac_ext <<_ACEOF
10349 /* confdefs.h.  */
10350 _ACEOF
10351 cat confdefs.h >>conftest.$ac_ext
10352 cat >>conftest.$ac_ext <<_ACEOF
10353 /* end confdefs.h.  */
10354 #include <ctype.h>
10355 #include <stdlib.h>
10356 #if ((' ' & 0x0FF) == 0x020)
10357 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10358 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10359 #else
10360 # define ISLOWER(c) \
10361                    (('a' <= (c) && (c) <= 'i') \
10362                      || ('j' <= (c) && (c) <= 'r') \
10363                      || ('s' <= (c) && (c) <= 'z'))
10364 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10365 #endif
10366
10367 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10368 int
10369 main ()
10370 {
10371   int i;
10372   for (i = 0; i < 256; i++)
10373     if (XOR (islower (i), ISLOWER (i))
10374         || toupper (i) != TOUPPER (i))
10375       return 2;
10376   return 0;
10377 }
10378 _ACEOF
10379 rm -f conftest$ac_exeext
10380 if { (ac_try="$ac_link"
10381 case "(($ac_try" in
10382   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10383   *) ac_try_echo=$ac_try;;
10384 esac
10385 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10386 $as_echo "$ac_try_echo") >&5
10387   (eval "$ac_link") 2>&5
10388   ac_status=$?
10389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10390   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10391   { (case "(($ac_try" in
10392   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10393   *) ac_try_echo=$ac_try;;
10394 esac
10395 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10396 $as_echo "$ac_try_echo") >&5
10397   (eval "$ac_try") 2>&5
10398   ac_status=$?
10399   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10400   (exit $ac_status); }; }; then
10401   :
10402 else
10403   $as_echo "$as_me: program exited with status $ac_status" >&5
10404 $as_echo "$as_me: failed program was:" >&5
10405 sed 's/^/| /' conftest.$ac_ext >&5
10406
10407 ( exit $ac_status )
10408 ac_cv_header_stdc=no
10409 fi
10410 rm -rf conftest.dSYM
10411 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10412 fi
10413
10414
10415 fi
10416 fi
10417 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
10418 $as_echo "$ac_cv_header_stdc" >&6; }
10419 if test $ac_cv_header_stdc = yes; then
10420
10421 cat >>confdefs.h <<\_ACEOF
10422 #define STDC_HEADERS 1
10423 _ACEOF
10424
10425 fi
10426
10427 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
10428
10429
10430
10431
10432
10433
10434
10435
10436
10437 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10438                   inttypes.h stdint.h unistd.h
10439 do
10440 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10441 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10442 $as_echo_n "checking for $ac_header... " >&6; }
10443 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10444   $as_echo_n "(cached) " >&6
10445 else
10446   cat >conftest.$ac_ext <<_ACEOF
10447 /* confdefs.h.  */
10448 _ACEOF
10449 cat confdefs.h >>conftest.$ac_ext
10450 cat >>conftest.$ac_ext <<_ACEOF
10451 /* end confdefs.h.  */
10452 $ac_includes_default
10453
10454 #include <$ac_header>
10455 _ACEOF
10456 rm -f conftest.$ac_objext
10457 if { (ac_try="$ac_compile"
10458 case "(($ac_try" in
10459   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10460   *) ac_try_echo=$ac_try;;
10461 esac
10462 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10463 $as_echo "$ac_try_echo") >&5
10464   (eval "$ac_compile") 2>conftest.er1
10465   ac_status=$?
10466   grep -v '^ *+' conftest.er1 >conftest.err
10467   rm -f conftest.er1
10468   cat conftest.err >&5
10469   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10470   (exit $ac_status); } && {
10471          test -z "$ac_c_werror_flag" ||
10472          test ! -s conftest.err
10473        } && test -s conftest.$ac_objext; then
10474   eval "$as_ac_Header=yes"
10475 else
10476   $as_echo "$as_me: failed program was:" >&5
10477 sed 's/^/| /' conftest.$ac_ext >&5
10478
10479         eval "$as_ac_Header=no"
10480 fi
10481
10482 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10483 fi
10484 ac_res=`eval 'as_val=${'$as_ac_Header'}
10485                  $as_echo "$as_val"'`
10486                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10487 $as_echo "$ac_res" >&6; }
10488 as_val=`eval 'as_val=${'$as_ac_Header'}
10489                  $as_echo "$as_val"'`
10490    if test "x$as_val" = x""yes; then
10491   cat >>confdefs.h <<_ACEOF
10492 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10493 _ACEOF
10494
10495 fi
10496
10497 done
10498
10499
10500
10501
10502
10503
10504
10505
10506
10507
10508
10509
10510
10511
10512
10513
10514
10515
10516
10517
10518
10519
10520
10521
10522
10523
10524
10525
10526
10527 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
10528 do
10529 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10530 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10531   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10532 $as_echo_n "checking for $ac_header... " >&6; }
10533 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10534   $as_echo_n "(cached) " >&6
10535 fi
10536 ac_res=`eval 'as_val=${'$as_ac_Header'}
10537                  $as_echo "$as_val"'`
10538                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10539 $as_echo "$ac_res" >&6; }
10540 else
10541   # Is the header compilable?
10542 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10543 $as_echo_n "checking $ac_header usability... " >&6; }
10544 cat >conftest.$ac_ext <<_ACEOF
10545 /* confdefs.h.  */
10546 _ACEOF
10547 cat confdefs.h >>conftest.$ac_ext
10548 cat >>conftest.$ac_ext <<_ACEOF
10549 /* end confdefs.h.  */
10550 $ac_includes_default
10551 #include <$ac_header>
10552 _ACEOF
10553 rm -f conftest.$ac_objext
10554 if { (ac_try="$ac_compile"
10555 case "(($ac_try" in
10556   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10557   *) ac_try_echo=$ac_try;;
10558 esac
10559 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10560 $as_echo "$ac_try_echo") >&5
10561   (eval "$ac_compile") 2>conftest.er1
10562   ac_status=$?
10563   grep -v '^ *+' conftest.er1 >conftest.err
10564   rm -f conftest.er1
10565   cat conftest.err >&5
10566   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10567   (exit $ac_status); } && {
10568          test -z "$ac_c_werror_flag" ||
10569          test ! -s conftest.err
10570        } && test -s conftest.$ac_objext; then
10571   ac_header_compiler=yes
10572 else
10573   $as_echo "$as_me: failed program was:" >&5
10574 sed 's/^/| /' conftest.$ac_ext >&5
10575
10576         ac_header_compiler=no
10577 fi
10578
10579 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10580 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10581 $as_echo "$ac_header_compiler" >&6; }
10582
10583 # Is the header present?
10584 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10585 $as_echo_n "checking $ac_header presence... " >&6; }
10586 cat >conftest.$ac_ext <<_ACEOF
10587 /* confdefs.h.  */
10588 _ACEOF
10589 cat confdefs.h >>conftest.$ac_ext
10590 cat >>conftest.$ac_ext <<_ACEOF
10591 /* end confdefs.h.  */
10592 #include <$ac_header>
10593 _ACEOF
10594 if { (ac_try="$ac_cpp conftest.$ac_ext"
10595 case "(($ac_try" in
10596   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10597   *) ac_try_echo=$ac_try;;
10598 esac
10599 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10600 $as_echo "$ac_try_echo") >&5
10601   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10602   ac_status=$?
10603   grep -v '^ *+' conftest.er1 >conftest.err
10604   rm -f conftest.er1
10605   cat conftest.err >&5
10606   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10607   (exit $ac_status); } >/dev/null && {
10608          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10609          test ! -s conftest.err
10610        }; then
10611   ac_header_preproc=yes
10612 else
10613   $as_echo "$as_me: failed program was:" >&5
10614 sed 's/^/| /' conftest.$ac_ext >&5
10615
10616   ac_header_preproc=no
10617 fi
10618
10619 rm -f conftest.err conftest.$ac_ext
10620 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10621 $as_echo "$ac_header_preproc" >&6; }
10622
10623 # So?  What about this header?
10624 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10625   yes:no: )
10626     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10627 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10628     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10629 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10630     ac_header_preproc=yes
10631     ;;
10632   no:yes:* )
10633     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10634 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10635     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10636 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10637     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10638 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10639     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10640 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10641     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10642 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10643     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10644 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10645     ( cat <<\_ASBOX
10646 ## ---------------------------------------- ##
10647 ## Report this to pgsql-bugs@postgresql.org ##
10648 ## ---------------------------------------- ##
10649 _ASBOX
10650      ) | sed "s/^/$as_me: WARNING:     /" >&2
10651     ;;
10652 esac
10653 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10654 $as_echo_n "checking for $ac_header... " >&6; }
10655 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10656   $as_echo_n "(cached) " >&6
10657 else
10658   eval "$as_ac_Header=\$ac_header_preproc"
10659 fi
10660 ac_res=`eval 'as_val=${'$as_ac_Header'}
10661                  $as_echo "$as_val"'`
10662                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10663 $as_echo "$ac_res" >&6; }
10664
10665 fi
10666 as_val=`eval 'as_val=${'$as_ac_Header'}
10667                  $as_echo "$as_val"'`
10668    if test "x$as_val" = x""yes; then
10669   cat >>confdefs.h <<_ACEOF
10670 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10671 _ACEOF
10672
10673 fi
10674
10675 done
10676
10677
10678 # On BSD, test for net/if.h will fail unless sys/socket.h
10679 # is included first.
10680
10681 for ac_header in net/if.h
10682 do
10683 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10684 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10685 $as_echo_n "checking for $ac_header... " >&6; }
10686 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10687   $as_echo_n "(cached) " >&6
10688 else
10689   cat >conftest.$ac_ext <<_ACEOF
10690 /* confdefs.h.  */
10691 _ACEOF
10692 cat confdefs.h >>conftest.$ac_ext
10693 cat >>conftest.$ac_ext <<_ACEOF
10694 /* end confdefs.h.  */
10695 $ac_includes_default
10696 #ifdef HAVE_SYS_SOCKET_H
10697 #include <sys/socket.h>
10698 #endif
10699
10700
10701 #include <$ac_header>
10702 _ACEOF
10703 rm -f conftest.$ac_objext
10704 if { (ac_try="$ac_compile"
10705 case "(($ac_try" in
10706   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10707   *) ac_try_echo=$ac_try;;
10708 esac
10709 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10710 $as_echo "$ac_try_echo") >&5
10711   (eval "$ac_compile") 2>conftest.er1
10712   ac_status=$?
10713   grep -v '^ *+' conftest.er1 >conftest.err
10714   rm -f conftest.er1
10715   cat conftest.err >&5
10716   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10717   (exit $ac_status); } && {
10718          test -z "$ac_c_werror_flag" ||
10719          test ! -s conftest.err
10720        } && test -s conftest.$ac_objext; then
10721   eval "$as_ac_Header=yes"
10722 else
10723   $as_echo "$as_me: failed program was:" >&5
10724 sed 's/^/| /' conftest.$ac_ext >&5
10725
10726         eval "$as_ac_Header=no"
10727 fi
10728
10729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10730 fi
10731 ac_res=`eval 'as_val=${'$as_ac_Header'}
10732                  $as_echo "$as_val"'`
10733                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10734 $as_echo "$ac_res" >&6; }
10735 as_val=`eval 'as_val=${'$as_ac_Header'}
10736                  $as_echo "$as_val"'`
10737    if test "x$as_val" = x""yes; then
10738   cat >>confdefs.h <<_ACEOF
10739 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10740 _ACEOF
10741
10742 fi
10743
10744 done
10745
10746
10747 # On OpenBSD, test for sys/ucred.h will fail unless sys/param.h
10748 # is included first.
10749
10750 for ac_header in sys/ucred.h
10751 do
10752 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10753 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10754 $as_echo_n "checking for $ac_header... " >&6; }
10755 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10756   $as_echo_n "(cached) " >&6
10757 else
10758   cat >conftest.$ac_ext <<_ACEOF
10759 /* confdefs.h.  */
10760 _ACEOF
10761 cat confdefs.h >>conftest.$ac_ext
10762 cat >>conftest.$ac_ext <<_ACEOF
10763 /* end confdefs.h.  */
10764 $ac_includes_default
10765 #include <sys/param.h>
10766
10767
10768 #include <$ac_header>
10769 _ACEOF
10770 rm -f conftest.$ac_objext
10771 if { (ac_try="$ac_compile"
10772 case "(($ac_try" in
10773   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10774   *) ac_try_echo=$ac_try;;
10775 esac
10776 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10777 $as_echo "$ac_try_echo") >&5
10778   (eval "$ac_compile") 2>conftest.er1
10779   ac_status=$?
10780   grep -v '^ *+' conftest.er1 >conftest.err
10781   rm -f conftest.er1
10782   cat conftest.err >&5
10783   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10784   (exit $ac_status); } && {
10785          test -z "$ac_c_werror_flag" ||
10786          test ! -s conftest.err
10787        } && test -s conftest.$ac_objext; then
10788   eval "$as_ac_Header=yes"
10789 else
10790   $as_echo "$as_me: failed program was:" >&5
10791 sed 's/^/| /' conftest.$ac_ext >&5
10792
10793         eval "$as_ac_Header=no"
10794 fi
10795
10796 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10797 fi
10798 ac_res=`eval 'as_val=${'$as_ac_Header'}
10799                  $as_echo "$as_val"'`
10800                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10801 $as_echo "$ac_res" >&6; }
10802 as_val=`eval 'as_val=${'$as_ac_Header'}
10803                  $as_echo "$as_val"'`
10804    if test "x$as_val" = x""yes; then
10805   cat >>confdefs.h <<_ACEOF
10806 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10807 _ACEOF
10808
10809 fi
10810
10811 done
10812
10813
10814 # At least on IRIX, test for netinet/tcp.h will fail unless
10815 # netinet/in.h is included first.
10816
10817 for ac_header in netinet/in.h
10818 do
10819 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10820 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10821   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10822 $as_echo_n "checking for $ac_header... " >&6; }
10823 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10824   $as_echo_n "(cached) " >&6
10825 fi
10826 ac_res=`eval 'as_val=${'$as_ac_Header'}
10827                  $as_echo "$as_val"'`
10828                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10829 $as_echo "$ac_res" >&6; }
10830 else
10831   # Is the header compilable?
10832 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10833 $as_echo_n "checking $ac_header usability... " >&6; }
10834 cat >conftest.$ac_ext <<_ACEOF
10835 /* confdefs.h.  */
10836 _ACEOF
10837 cat confdefs.h >>conftest.$ac_ext
10838 cat >>conftest.$ac_ext <<_ACEOF
10839 /* end confdefs.h.  */
10840 $ac_includes_default
10841 #include <$ac_header>
10842 _ACEOF
10843 rm -f conftest.$ac_objext
10844 if { (ac_try="$ac_compile"
10845 case "(($ac_try" in
10846   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10847   *) ac_try_echo=$ac_try;;
10848 esac
10849 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10850 $as_echo "$ac_try_echo") >&5
10851   (eval "$ac_compile") 2>conftest.er1
10852   ac_status=$?
10853   grep -v '^ *+' conftest.er1 >conftest.err
10854   rm -f conftest.er1
10855   cat conftest.err >&5
10856   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10857   (exit $ac_status); } && {
10858          test -z "$ac_c_werror_flag" ||
10859          test ! -s conftest.err
10860        } && test -s conftest.$ac_objext; then
10861   ac_header_compiler=yes
10862 else
10863   $as_echo "$as_me: failed program was:" >&5
10864 sed 's/^/| /' conftest.$ac_ext >&5
10865
10866         ac_header_compiler=no
10867 fi
10868
10869 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10870 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10871 $as_echo "$ac_header_compiler" >&6; }
10872
10873 # Is the header present?
10874 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10875 $as_echo_n "checking $ac_header presence... " >&6; }
10876 cat >conftest.$ac_ext <<_ACEOF
10877 /* confdefs.h.  */
10878 _ACEOF
10879 cat confdefs.h >>conftest.$ac_ext
10880 cat >>conftest.$ac_ext <<_ACEOF
10881 /* end confdefs.h.  */
10882 #include <$ac_header>
10883 _ACEOF
10884 if { (ac_try="$ac_cpp conftest.$ac_ext"
10885 case "(($ac_try" in
10886   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10887   *) ac_try_echo=$ac_try;;
10888 esac
10889 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10890 $as_echo "$ac_try_echo") >&5
10891   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10892   ac_status=$?
10893   grep -v '^ *+' conftest.er1 >conftest.err
10894   rm -f conftest.er1
10895   cat conftest.err >&5
10896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10897   (exit $ac_status); } >/dev/null && {
10898          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10899          test ! -s conftest.err
10900        }; then
10901   ac_header_preproc=yes
10902 else
10903   $as_echo "$as_me: failed program was:" >&5
10904 sed 's/^/| /' conftest.$ac_ext >&5
10905
10906   ac_header_preproc=no
10907 fi
10908
10909 rm -f conftest.err conftest.$ac_ext
10910 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10911 $as_echo "$ac_header_preproc" >&6; }
10912
10913 # So?  What about this header?
10914 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10915   yes:no: )
10916     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10917 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10918     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10919 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10920     ac_header_preproc=yes
10921     ;;
10922   no:yes:* )
10923     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10924 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10925     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10926 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10927     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10928 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10929     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10930 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10931     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10932 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10933     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10934 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10935     ( cat <<\_ASBOX
10936 ## ---------------------------------------- ##
10937 ## Report this to pgsql-bugs@postgresql.org ##
10938 ## ---------------------------------------- ##
10939 _ASBOX
10940      ) | sed "s/^/$as_me: WARNING:     /" >&2
10941     ;;
10942 esac
10943 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10944 $as_echo_n "checking for $ac_header... " >&6; }
10945 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10946   $as_echo_n "(cached) " >&6
10947 else
10948   eval "$as_ac_Header=\$ac_header_preproc"
10949 fi
10950 ac_res=`eval 'as_val=${'$as_ac_Header'}
10951                  $as_echo "$as_val"'`
10952                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10953 $as_echo "$ac_res" >&6; }
10954
10955 fi
10956 as_val=`eval 'as_val=${'$as_ac_Header'}
10957                  $as_echo "$as_val"'`
10958    if test "x$as_val" = x""yes; then
10959   cat >>confdefs.h <<_ACEOF
10960 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10961 _ACEOF
10962
10963 fi
10964
10965 done
10966
10967
10968 for ac_header in netinet/tcp.h
10969 do
10970 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10971 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10972 $as_echo_n "checking for $ac_header... " >&6; }
10973 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10974   $as_echo_n "(cached) " >&6
10975 else
10976   cat >conftest.$ac_ext <<_ACEOF
10977 /* confdefs.h.  */
10978 _ACEOF
10979 cat confdefs.h >>conftest.$ac_ext
10980 cat >>conftest.$ac_ext <<_ACEOF
10981 /* end confdefs.h.  */
10982 $ac_includes_default
10983 #ifdef HAVE_NETINET_IN_H
10984 #include <netinet/in.h>
10985 #endif
10986
10987
10988 #include <$ac_header>
10989 _ACEOF
10990 rm -f conftest.$ac_objext
10991 if { (ac_try="$ac_compile"
10992 case "(($ac_try" in
10993   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10994   *) ac_try_echo=$ac_try;;
10995 esac
10996 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10997 $as_echo "$ac_try_echo") >&5
10998   (eval "$ac_compile") 2>conftest.er1
10999   ac_status=$?
11000   grep -v '^ *+' conftest.er1 >conftest.err
11001   rm -f conftest.er1
11002   cat conftest.err >&5
11003   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11004   (exit $ac_status); } && {
11005          test -z "$ac_c_werror_flag" ||
11006          test ! -s conftest.err
11007        } && test -s conftest.$ac_objext; then
11008   eval "$as_ac_Header=yes"
11009 else
11010   $as_echo "$as_me: failed program was:" >&5
11011 sed 's/^/| /' conftest.$ac_ext >&5
11012
11013         eval "$as_ac_Header=no"
11014 fi
11015
11016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11017 fi
11018 ac_res=`eval 'as_val=${'$as_ac_Header'}
11019                  $as_echo "$as_val"'`
11020                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11021 $as_echo "$ac_res" >&6; }
11022 as_val=`eval 'as_val=${'$as_ac_Header'}
11023                  $as_echo "$as_val"'`
11024    if test "x$as_val" = x""yes; then
11025   cat >>confdefs.h <<_ACEOF
11026 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11027 _ACEOF
11028
11029 fi
11030
11031 done
11032
11033
11034 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
11035
11036 for ac_header in readline/readline.h
11037 do
11038 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11039 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11040   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11041 $as_echo_n "checking for $ac_header... " >&6; }
11042 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11043   $as_echo_n "(cached) " >&6
11044 fi
11045 ac_res=`eval 'as_val=${'$as_ac_Header'}
11046                  $as_echo "$as_val"'`
11047                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11048 $as_echo "$ac_res" >&6; }
11049 else
11050   # Is the header compilable?
11051 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11052 $as_echo_n "checking $ac_header usability... " >&6; }
11053 cat >conftest.$ac_ext <<_ACEOF
11054 /* confdefs.h.  */
11055 _ACEOF
11056 cat confdefs.h >>conftest.$ac_ext
11057 cat >>conftest.$ac_ext <<_ACEOF
11058 /* end confdefs.h.  */
11059 $ac_includes_default
11060 #include <$ac_header>
11061 _ACEOF
11062 rm -f conftest.$ac_objext
11063 if { (ac_try="$ac_compile"
11064 case "(($ac_try" in
11065   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11066   *) ac_try_echo=$ac_try;;
11067 esac
11068 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11069 $as_echo "$ac_try_echo") >&5
11070   (eval "$ac_compile") 2>conftest.er1
11071   ac_status=$?
11072   grep -v '^ *+' conftest.er1 >conftest.err
11073   rm -f conftest.er1
11074   cat conftest.err >&5
11075   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11076   (exit $ac_status); } && {
11077          test -z "$ac_c_werror_flag" ||
11078          test ! -s conftest.err
11079        } && test -s conftest.$ac_objext; then
11080   ac_header_compiler=yes
11081 else
11082   $as_echo "$as_me: failed program was:" >&5
11083 sed 's/^/| /' conftest.$ac_ext >&5
11084
11085         ac_header_compiler=no
11086 fi
11087
11088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11089 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11090 $as_echo "$ac_header_compiler" >&6; }
11091
11092 # Is the header present?
11093 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11094 $as_echo_n "checking $ac_header presence... " >&6; }
11095 cat >conftest.$ac_ext <<_ACEOF
11096 /* confdefs.h.  */
11097 _ACEOF
11098 cat confdefs.h >>conftest.$ac_ext
11099 cat >>conftest.$ac_ext <<_ACEOF
11100 /* end confdefs.h.  */
11101 #include <$ac_header>
11102 _ACEOF
11103 if { (ac_try="$ac_cpp conftest.$ac_ext"
11104 case "(($ac_try" in
11105   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11106   *) ac_try_echo=$ac_try;;
11107 esac
11108 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11109 $as_echo "$ac_try_echo") >&5
11110   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11111   ac_status=$?
11112   grep -v '^ *+' conftest.er1 >conftest.err
11113   rm -f conftest.er1
11114   cat conftest.err >&5
11115   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11116   (exit $ac_status); } >/dev/null && {
11117          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11118          test ! -s conftest.err
11119        }; then
11120   ac_header_preproc=yes
11121 else
11122   $as_echo "$as_me: failed program was:" >&5
11123 sed 's/^/| /' conftest.$ac_ext >&5
11124
11125   ac_header_preproc=no
11126 fi
11127
11128 rm -f conftest.err conftest.$ac_ext
11129 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11130 $as_echo "$ac_header_preproc" >&6; }
11131
11132 # So?  What about this header?
11133 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11134   yes:no: )
11135     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11136 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11137     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11138 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11139     ac_header_preproc=yes
11140     ;;
11141   no:yes:* )
11142     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11143 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11144     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11145 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11146     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11147 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11148     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11149 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11150     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11151 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11152     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11153 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11154     ( cat <<\_ASBOX
11155 ## ---------------------------------------- ##
11156 ## Report this to pgsql-bugs@postgresql.org ##
11157 ## ---------------------------------------- ##
11158 _ASBOX
11159      ) | sed "s/^/$as_me: WARNING:     /" >&2
11160     ;;
11161 esac
11162 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11163 $as_echo_n "checking for $ac_header... " >&6; }
11164 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11165   $as_echo_n "(cached) " >&6
11166 else
11167   eval "$as_ac_Header=\$ac_header_preproc"
11168 fi
11169 ac_res=`eval 'as_val=${'$as_ac_Header'}
11170                  $as_echo "$as_val"'`
11171                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11172 $as_echo "$ac_res" >&6; }
11173
11174 fi
11175 as_val=`eval 'as_val=${'$as_ac_Header'}
11176                  $as_echo "$as_val"'`
11177    if test "x$as_val" = x""yes; then
11178   cat >>confdefs.h <<_ACEOF
11179 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11180 _ACEOF
11181
11182 else
11183
11184 for ac_header in readline.h
11185 do
11186 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11187 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11188   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11189 $as_echo_n "checking for $ac_header... " >&6; }
11190 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11191   $as_echo_n "(cached) " >&6
11192 fi
11193 ac_res=`eval 'as_val=${'$as_ac_Header'}
11194                  $as_echo "$as_val"'`
11195                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11196 $as_echo "$ac_res" >&6; }
11197 else
11198   # Is the header compilable?
11199 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11200 $as_echo_n "checking $ac_header usability... " >&6; }
11201 cat >conftest.$ac_ext <<_ACEOF
11202 /* confdefs.h.  */
11203 _ACEOF
11204 cat confdefs.h >>conftest.$ac_ext
11205 cat >>conftest.$ac_ext <<_ACEOF
11206 /* end confdefs.h.  */
11207 $ac_includes_default
11208 #include <$ac_header>
11209 _ACEOF
11210 rm -f conftest.$ac_objext
11211 if { (ac_try="$ac_compile"
11212 case "(($ac_try" in
11213   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11214   *) ac_try_echo=$ac_try;;
11215 esac
11216 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11217 $as_echo "$ac_try_echo") >&5
11218   (eval "$ac_compile") 2>conftest.er1
11219   ac_status=$?
11220   grep -v '^ *+' conftest.er1 >conftest.err
11221   rm -f conftest.er1
11222   cat conftest.err >&5
11223   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11224   (exit $ac_status); } && {
11225          test -z "$ac_c_werror_flag" ||
11226          test ! -s conftest.err
11227        } && test -s conftest.$ac_objext; then
11228   ac_header_compiler=yes
11229 else
11230   $as_echo "$as_me: failed program was:" >&5
11231 sed 's/^/| /' conftest.$ac_ext >&5
11232
11233         ac_header_compiler=no
11234 fi
11235
11236 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11237 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11238 $as_echo "$ac_header_compiler" >&6; }
11239
11240 # Is the header present?
11241 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11242 $as_echo_n "checking $ac_header presence... " >&6; }
11243 cat >conftest.$ac_ext <<_ACEOF
11244 /* confdefs.h.  */
11245 _ACEOF
11246 cat confdefs.h >>conftest.$ac_ext
11247 cat >>conftest.$ac_ext <<_ACEOF
11248 /* end confdefs.h.  */
11249 #include <$ac_header>
11250 _ACEOF
11251 if { (ac_try="$ac_cpp conftest.$ac_ext"
11252 case "(($ac_try" in
11253   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11254   *) ac_try_echo=$ac_try;;
11255 esac
11256 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11257 $as_echo "$ac_try_echo") >&5
11258   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11259   ac_status=$?
11260   grep -v '^ *+' conftest.er1 >conftest.err
11261   rm -f conftest.er1
11262   cat conftest.err >&5
11263   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11264   (exit $ac_status); } >/dev/null && {
11265          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11266          test ! -s conftest.err
11267        }; then
11268   ac_header_preproc=yes
11269 else
11270   $as_echo "$as_me: failed program was:" >&5
11271 sed 's/^/| /' conftest.$ac_ext >&5
11272
11273   ac_header_preproc=no
11274 fi
11275
11276 rm -f conftest.err conftest.$ac_ext
11277 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11278 $as_echo "$ac_header_preproc" >&6; }
11279
11280 # So?  What about this header?
11281 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11282   yes:no: )
11283     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11284 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11285     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11286 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11287     ac_header_preproc=yes
11288     ;;
11289   no:yes:* )
11290     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11291 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11292     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11293 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11294     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11295 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11296     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11297 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11298     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11299 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11300     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11301 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11302     ( cat <<\_ASBOX
11303 ## ---------------------------------------- ##
11304 ## Report this to pgsql-bugs@postgresql.org ##
11305 ## ---------------------------------------- ##
11306 _ASBOX
11307      ) | sed "s/^/$as_me: WARNING:     /" >&2
11308     ;;
11309 esac
11310 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11311 $as_echo_n "checking for $ac_header... " >&6; }
11312 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11313   $as_echo_n "(cached) " >&6
11314 else
11315   eval "$as_ac_Header=\$ac_header_preproc"
11316 fi
11317 ac_res=`eval 'as_val=${'$as_ac_Header'}
11318                  $as_echo "$as_val"'`
11319                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11320 $as_echo "$ac_res" >&6; }
11321
11322 fi
11323 as_val=`eval 'as_val=${'$as_ac_Header'}
11324                  $as_echo "$as_val"'`
11325    if test "x$as_val" = x""yes; then
11326   cat >>confdefs.h <<_ACEOF
11327 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11328 _ACEOF
11329
11330 else
11331   { { $as_echo "$as_me:$LINENO: error: readline header not found
11332 If you have readline already installed, see config.log for details on the
11333 failure.  It is possible the compiler isn't looking in the proper directory.
11334 Use --without-readline to disable readline support." >&5
11335 $as_echo "$as_me: error: readline header not found
11336 If you have readline already installed, see config.log for details on the
11337 failure.  It is possible the compiler isn't looking in the proper directory.
11338 Use --without-readline to disable readline support." >&2;}
11339    { (exit 1); exit 1; }; }
11340 fi
11341
11342 done
11343
11344 fi
11345
11346 done
11347
11348
11349 for ac_header in readline/history.h
11350 do
11351 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11352 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11353   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11354 $as_echo_n "checking for $ac_header... " >&6; }
11355 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11356   $as_echo_n "(cached) " >&6
11357 fi
11358 ac_res=`eval 'as_val=${'$as_ac_Header'}
11359                  $as_echo "$as_val"'`
11360                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11361 $as_echo "$ac_res" >&6; }
11362 else
11363   # Is the header compilable?
11364 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11365 $as_echo_n "checking $ac_header usability... " >&6; }
11366 cat >conftest.$ac_ext <<_ACEOF
11367 /* confdefs.h.  */
11368 _ACEOF
11369 cat confdefs.h >>conftest.$ac_ext
11370 cat >>conftest.$ac_ext <<_ACEOF
11371 /* end confdefs.h.  */
11372 $ac_includes_default
11373 #include <$ac_header>
11374 _ACEOF
11375 rm -f conftest.$ac_objext
11376 if { (ac_try="$ac_compile"
11377 case "(($ac_try" in
11378   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11379   *) ac_try_echo=$ac_try;;
11380 esac
11381 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11382 $as_echo "$ac_try_echo") >&5
11383   (eval "$ac_compile") 2>conftest.er1
11384   ac_status=$?
11385   grep -v '^ *+' conftest.er1 >conftest.err
11386   rm -f conftest.er1
11387   cat conftest.err >&5
11388   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11389   (exit $ac_status); } && {
11390          test -z "$ac_c_werror_flag" ||
11391          test ! -s conftest.err
11392        } && test -s conftest.$ac_objext; then
11393   ac_header_compiler=yes
11394 else
11395   $as_echo "$as_me: failed program was:" >&5
11396 sed 's/^/| /' conftest.$ac_ext >&5
11397
11398         ac_header_compiler=no
11399 fi
11400
11401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11402 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11403 $as_echo "$ac_header_compiler" >&6; }
11404
11405 # Is the header present?
11406 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11407 $as_echo_n "checking $ac_header presence... " >&6; }
11408 cat >conftest.$ac_ext <<_ACEOF
11409 /* confdefs.h.  */
11410 _ACEOF
11411 cat confdefs.h >>conftest.$ac_ext
11412 cat >>conftest.$ac_ext <<_ACEOF
11413 /* end confdefs.h.  */
11414 #include <$ac_header>
11415 _ACEOF
11416 if { (ac_try="$ac_cpp conftest.$ac_ext"
11417 case "(($ac_try" in
11418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11419   *) ac_try_echo=$ac_try;;
11420 esac
11421 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11422 $as_echo "$ac_try_echo") >&5
11423   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11424   ac_status=$?
11425   grep -v '^ *+' conftest.er1 >conftest.err
11426   rm -f conftest.er1
11427   cat conftest.err >&5
11428   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11429   (exit $ac_status); } >/dev/null && {
11430          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11431          test ! -s conftest.err
11432        }; then
11433   ac_header_preproc=yes
11434 else
11435   $as_echo "$as_me: failed program was:" >&5
11436 sed 's/^/| /' conftest.$ac_ext >&5
11437
11438   ac_header_preproc=no
11439 fi
11440
11441 rm -f conftest.err conftest.$ac_ext
11442 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11443 $as_echo "$ac_header_preproc" >&6; }
11444
11445 # So?  What about this header?
11446 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11447   yes:no: )
11448     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11449 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11450     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11451 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11452     ac_header_preproc=yes
11453     ;;
11454   no:yes:* )
11455     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11456 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11457     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11458 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11459     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11460 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11461     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11462 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11463     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11464 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11465     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11466 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11467     ( cat <<\_ASBOX
11468 ## ---------------------------------------- ##
11469 ## Report this to pgsql-bugs@postgresql.org ##
11470 ## ---------------------------------------- ##
11471 _ASBOX
11472      ) | sed "s/^/$as_me: WARNING:     /" >&2
11473     ;;
11474 esac
11475 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11476 $as_echo_n "checking for $ac_header... " >&6; }
11477 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11478   $as_echo_n "(cached) " >&6
11479 else
11480   eval "$as_ac_Header=\$ac_header_preproc"
11481 fi
11482 ac_res=`eval 'as_val=${'$as_ac_Header'}
11483                  $as_echo "$as_val"'`
11484                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11485 $as_echo "$ac_res" >&6; }
11486
11487 fi
11488 as_val=`eval 'as_val=${'$as_ac_Header'}
11489                  $as_echo "$as_val"'`
11490    if test "x$as_val" = x""yes; then
11491   cat >>confdefs.h <<_ACEOF
11492 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11493 _ACEOF
11494
11495 else
11496
11497 for ac_header in history.h
11498 do
11499 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11500 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11501   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11502 $as_echo_n "checking for $ac_header... " >&6; }
11503 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11504   $as_echo_n "(cached) " >&6
11505 fi
11506 ac_res=`eval 'as_val=${'$as_ac_Header'}
11507                  $as_echo "$as_val"'`
11508                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11509 $as_echo "$ac_res" >&6; }
11510 else
11511   # Is the header compilable?
11512 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11513 $as_echo_n "checking $ac_header usability... " >&6; }
11514 cat >conftest.$ac_ext <<_ACEOF
11515 /* confdefs.h.  */
11516 _ACEOF
11517 cat confdefs.h >>conftest.$ac_ext
11518 cat >>conftest.$ac_ext <<_ACEOF
11519 /* end confdefs.h.  */
11520 $ac_includes_default
11521 #include <$ac_header>
11522 _ACEOF
11523 rm -f conftest.$ac_objext
11524 if { (ac_try="$ac_compile"
11525 case "(($ac_try" in
11526   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11527   *) ac_try_echo=$ac_try;;
11528 esac
11529 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11530 $as_echo "$ac_try_echo") >&5
11531   (eval "$ac_compile") 2>conftest.er1
11532   ac_status=$?
11533   grep -v '^ *+' conftest.er1 >conftest.err
11534   rm -f conftest.er1
11535   cat conftest.err >&5
11536   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11537   (exit $ac_status); } && {
11538          test -z "$ac_c_werror_flag" ||
11539          test ! -s conftest.err
11540        } && test -s conftest.$ac_objext; then
11541   ac_header_compiler=yes
11542 else
11543   $as_echo "$as_me: failed program was:" >&5
11544 sed 's/^/| /' conftest.$ac_ext >&5
11545
11546         ac_header_compiler=no
11547 fi
11548
11549 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11550 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11551 $as_echo "$ac_header_compiler" >&6; }
11552
11553 # Is the header present?
11554 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11555 $as_echo_n "checking $ac_header presence... " >&6; }
11556 cat >conftest.$ac_ext <<_ACEOF
11557 /* confdefs.h.  */
11558 _ACEOF
11559 cat confdefs.h >>conftest.$ac_ext
11560 cat >>conftest.$ac_ext <<_ACEOF
11561 /* end confdefs.h.  */
11562 #include <$ac_header>
11563 _ACEOF
11564 if { (ac_try="$ac_cpp conftest.$ac_ext"
11565 case "(($ac_try" in
11566   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11567   *) ac_try_echo=$ac_try;;
11568 esac
11569 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11570 $as_echo "$ac_try_echo") >&5
11571   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11572   ac_status=$?
11573   grep -v '^ *+' conftest.er1 >conftest.err
11574   rm -f conftest.er1
11575   cat conftest.err >&5
11576   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11577   (exit $ac_status); } >/dev/null && {
11578          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11579          test ! -s conftest.err
11580        }; then
11581   ac_header_preproc=yes
11582 else
11583   $as_echo "$as_me: failed program was:" >&5
11584 sed 's/^/| /' conftest.$ac_ext >&5
11585
11586   ac_header_preproc=no
11587 fi
11588
11589 rm -f conftest.err conftest.$ac_ext
11590 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11591 $as_echo "$ac_header_preproc" >&6; }
11592
11593 # So?  What about this header?
11594 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11595   yes:no: )
11596     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11597 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11598     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11599 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11600     ac_header_preproc=yes
11601     ;;
11602   no:yes:* )
11603     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11604 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11605     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11606 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11607     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11608 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11609     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11610 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11611     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11612 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11613     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11614 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11615     ( cat <<\_ASBOX
11616 ## ---------------------------------------- ##
11617 ## Report this to pgsql-bugs@postgresql.org ##
11618 ## ---------------------------------------- ##
11619 _ASBOX
11620      ) | sed "s/^/$as_me: WARNING:     /" >&2
11621     ;;
11622 esac
11623 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11624 $as_echo_n "checking for $ac_header... " >&6; }
11625 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11626   $as_echo_n "(cached) " >&6
11627 else
11628   eval "$as_ac_Header=\$ac_header_preproc"
11629 fi
11630 ac_res=`eval 'as_val=${'$as_ac_Header'}
11631                  $as_echo "$as_val"'`
11632                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11633 $as_echo "$ac_res" >&6; }
11634
11635 fi
11636 as_val=`eval 'as_val=${'$as_ac_Header'}
11637                  $as_echo "$as_val"'`
11638    if test "x$as_val" = x""yes; then
11639   cat >>confdefs.h <<_ACEOF
11640 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11641 _ACEOF
11642
11643 else
11644   { { $as_echo "$as_me:$LINENO: error: history header not found
11645 If you have readline already installed, see config.log for details on the
11646 failure.  It is possible the compiler isn't looking in the proper directory.
11647 Use --without-readline to disable readline support." >&5
11648 $as_echo "$as_me: error: history header not found
11649 If you have readline already installed, see config.log for details on the
11650 failure.  It is possible the compiler isn't looking in the proper directory.
11651 Use --without-readline to disable readline support." >&2;}
11652    { (exit 1); exit 1; }; }
11653 fi
11654
11655 done
11656
11657 fi
11658
11659 done
11660
11661 fi
11662
11663 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
11664 # Some installations of libedit usurp /usr/include/readline/, which seems
11665 # bad practice, since in combined installations readline will have its headers
11666 # there.  We might have to resort to AC_EGREP checks to make sure we found
11667 # the proper header...
11668
11669 for ac_header in editline/readline.h
11670 do
11671 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11672 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11673   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11674 $as_echo_n "checking for $ac_header... " >&6; }
11675 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11676   $as_echo_n "(cached) " >&6
11677 fi
11678 ac_res=`eval 'as_val=${'$as_ac_Header'}
11679                  $as_echo "$as_val"'`
11680                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11681 $as_echo "$ac_res" >&6; }
11682 else
11683   # Is the header compilable?
11684 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11685 $as_echo_n "checking $ac_header usability... " >&6; }
11686 cat >conftest.$ac_ext <<_ACEOF
11687 /* confdefs.h.  */
11688 _ACEOF
11689 cat confdefs.h >>conftest.$ac_ext
11690 cat >>conftest.$ac_ext <<_ACEOF
11691 /* end confdefs.h.  */
11692 $ac_includes_default
11693 #include <$ac_header>
11694 _ACEOF
11695 rm -f conftest.$ac_objext
11696 if { (ac_try="$ac_compile"
11697 case "(($ac_try" in
11698   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11699   *) ac_try_echo=$ac_try;;
11700 esac
11701 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11702 $as_echo "$ac_try_echo") >&5
11703   (eval "$ac_compile") 2>conftest.er1
11704   ac_status=$?
11705   grep -v '^ *+' conftest.er1 >conftest.err
11706   rm -f conftest.er1
11707   cat conftest.err >&5
11708   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11709   (exit $ac_status); } && {
11710          test -z "$ac_c_werror_flag" ||
11711          test ! -s conftest.err
11712        } && test -s conftest.$ac_objext; then
11713   ac_header_compiler=yes
11714 else
11715   $as_echo "$as_me: failed program was:" >&5
11716 sed 's/^/| /' conftest.$ac_ext >&5
11717
11718         ac_header_compiler=no
11719 fi
11720
11721 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11722 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11723 $as_echo "$ac_header_compiler" >&6; }
11724
11725 # Is the header present?
11726 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11727 $as_echo_n "checking $ac_header presence... " >&6; }
11728 cat >conftest.$ac_ext <<_ACEOF
11729 /* confdefs.h.  */
11730 _ACEOF
11731 cat confdefs.h >>conftest.$ac_ext
11732 cat >>conftest.$ac_ext <<_ACEOF
11733 /* end confdefs.h.  */
11734 #include <$ac_header>
11735 _ACEOF
11736 if { (ac_try="$ac_cpp conftest.$ac_ext"
11737 case "(($ac_try" in
11738   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11739   *) ac_try_echo=$ac_try;;
11740 esac
11741 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11742 $as_echo "$ac_try_echo") >&5
11743   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11744   ac_status=$?
11745   grep -v '^ *+' conftest.er1 >conftest.err
11746   rm -f conftest.er1
11747   cat conftest.err >&5
11748   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11749   (exit $ac_status); } >/dev/null && {
11750          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11751          test ! -s conftest.err
11752        }; then
11753   ac_header_preproc=yes
11754 else
11755   $as_echo "$as_me: failed program was:" >&5
11756 sed 's/^/| /' conftest.$ac_ext >&5
11757
11758   ac_header_preproc=no
11759 fi
11760
11761 rm -f conftest.err conftest.$ac_ext
11762 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11763 $as_echo "$ac_header_preproc" >&6; }
11764
11765 # So?  What about this header?
11766 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11767   yes:no: )
11768     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11769 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11770     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11771 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11772     ac_header_preproc=yes
11773     ;;
11774   no:yes:* )
11775     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11776 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11777     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11778 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11779     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11780 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11781     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11782 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11783     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11784 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11785     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11786 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11787     ( cat <<\_ASBOX
11788 ## ---------------------------------------- ##
11789 ## Report this to pgsql-bugs@postgresql.org ##
11790 ## ---------------------------------------- ##
11791 _ASBOX
11792      ) | sed "s/^/$as_me: WARNING:     /" >&2
11793     ;;
11794 esac
11795 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11796 $as_echo_n "checking for $ac_header... " >&6; }
11797 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11798   $as_echo_n "(cached) " >&6
11799 else
11800   eval "$as_ac_Header=\$ac_header_preproc"
11801 fi
11802 ac_res=`eval 'as_val=${'$as_ac_Header'}
11803                  $as_echo "$as_val"'`
11804                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11805 $as_echo "$ac_res" >&6; }
11806
11807 fi
11808 as_val=`eval 'as_val=${'$as_ac_Header'}
11809                  $as_echo "$as_val"'`
11810    if test "x$as_val" = x""yes; then
11811   cat >>confdefs.h <<_ACEOF
11812 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11813 _ACEOF
11814
11815 else
11816
11817 for ac_header in readline.h
11818 do
11819 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11820 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11821   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11822 $as_echo_n "checking for $ac_header... " >&6; }
11823 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11824   $as_echo_n "(cached) " >&6
11825 fi
11826 ac_res=`eval 'as_val=${'$as_ac_Header'}
11827                  $as_echo "$as_val"'`
11828                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11829 $as_echo "$ac_res" >&6; }
11830 else
11831   # Is the header compilable?
11832 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11833 $as_echo_n "checking $ac_header usability... " >&6; }
11834 cat >conftest.$ac_ext <<_ACEOF
11835 /* confdefs.h.  */
11836 _ACEOF
11837 cat confdefs.h >>conftest.$ac_ext
11838 cat >>conftest.$ac_ext <<_ACEOF
11839 /* end confdefs.h.  */
11840 $ac_includes_default
11841 #include <$ac_header>
11842 _ACEOF
11843 rm -f conftest.$ac_objext
11844 if { (ac_try="$ac_compile"
11845 case "(($ac_try" in
11846   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11847   *) ac_try_echo=$ac_try;;
11848 esac
11849 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11850 $as_echo "$ac_try_echo") >&5
11851   (eval "$ac_compile") 2>conftest.er1
11852   ac_status=$?
11853   grep -v '^ *+' conftest.er1 >conftest.err
11854   rm -f conftest.er1
11855   cat conftest.err >&5
11856   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11857   (exit $ac_status); } && {
11858          test -z "$ac_c_werror_flag" ||
11859          test ! -s conftest.err
11860        } && test -s conftest.$ac_objext; then
11861   ac_header_compiler=yes
11862 else
11863   $as_echo "$as_me: failed program was:" >&5
11864 sed 's/^/| /' conftest.$ac_ext >&5
11865
11866         ac_header_compiler=no
11867 fi
11868
11869 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11870 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11871 $as_echo "$ac_header_compiler" >&6; }
11872
11873 # Is the header present?
11874 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11875 $as_echo_n "checking $ac_header presence... " >&6; }
11876 cat >conftest.$ac_ext <<_ACEOF
11877 /* confdefs.h.  */
11878 _ACEOF
11879 cat confdefs.h >>conftest.$ac_ext
11880 cat >>conftest.$ac_ext <<_ACEOF
11881 /* end confdefs.h.  */
11882 #include <$ac_header>
11883 _ACEOF
11884 if { (ac_try="$ac_cpp conftest.$ac_ext"
11885 case "(($ac_try" in
11886   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11887   *) ac_try_echo=$ac_try;;
11888 esac
11889 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11890 $as_echo "$ac_try_echo") >&5
11891   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11892   ac_status=$?
11893   grep -v '^ *+' conftest.er1 >conftest.err
11894   rm -f conftest.er1
11895   cat conftest.err >&5
11896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11897   (exit $ac_status); } >/dev/null && {
11898          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11899          test ! -s conftest.err
11900        }; then
11901   ac_header_preproc=yes
11902 else
11903   $as_echo "$as_me: failed program was:" >&5
11904 sed 's/^/| /' conftest.$ac_ext >&5
11905
11906   ac_header_preproc=no
11907 fi
11908
11909 rm -f conftest.err conftest.$ac_ext
11910 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11911 $as_echo "$ac_header_preproc" >&6; }
11912
11913 # So?  What about this header?
11914 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11915   yes:no: )
11916     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11917 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11918     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11919 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11920     ac_header_preproc=yes
11921     ;;
11922   no:yes:* )
11923     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11924 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11925     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11926 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11927     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11928 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11929     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11930 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11931     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11932 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11933     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11934 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11935     ( cat <<\_ASBOX
11936 ## ---------------------------------------- ##
11937 ## Report this to pgsql-bugs@postgresql.org ##
11938 ## ---------------------------------------- ##
11939 _ASBOX
11940      ) | sed "s/^/$as_me: WARNING:     /" >&2
11941     ;;
11942 esac
11943 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11944 $as_echo_n "checking for $ac_header... " >&6; }
11945 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11946   $as_echo_n "(cached) " >&6
11947 else
11948   eval "$as_ac_Header=\$ac_header_preproc"
11949 fi
11950 ac_res=`eval 'as_val=${'$as_ac_Header'}
11951                  $as_echo "$as_val"'`
11952                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11953 $as_echo "$ac_res" >&6; }
11954
11955 fi
11956 as_val=`eval 'as_val=${'$as_ac_Header'}
11957                  $as_echo "$as_val"'`
11958    if test "x$as_val" = x""yes; then
11959   cat >>confdefs.h <<_ACEOF
11960 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11961 _ACEOF
11962
11963 else
11964
11965 for ac_header in readline/readline.h
11966 do
11967 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11968 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11969   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11970 $as_echo_n "checking for $ac_header... " >&6; }
11971 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11972   $as_echo_n "(cached) " >&6
11973 fi
11974 ac_res=`eval 'as_val=${'$as_ac_Header'}
11975                  $as_echo "$as_val"'`
11976                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11977 $as_echo "$ac_res" >&6; }
11978 else
11979   # Is the header compilable?
11980 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11981 $as_echo_n "checking $ac_header usability... " >&6; }
11982 cat >conftest.$ac_ext <<_ACEOF
11983 /* confdefs.h.  */
11984 _ACEOF
11985 cat confdefs.h >>conftest.$ac_ext
11986 cat >>conftest.$ac_ext <<_ACEOF
11987 /* end confdefs.h.  */
11988 $ac_includes_default
11989 #include <$ac_header>
11990 _ACEOF
11991 rm -f conftest.$ac_objext
11992 if { (ac_try="$ac_compile"
11993 case "(($ac_try" in
11994   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11995   *) ac_try_echo=$ac_try;;
11996 esac
11997 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11998 $as_echo "$ac_try_echo") >&5
11999   (eval "$ac_compile") 2>conftest.er1
12000   ac_status=$?
12001   grep -v '^ *+' conftest.er1 >conftest.err
12002   rm -f conftest.er1
12003   cat conftest.err >&5
12004   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12005   (exit $ac_status); } && {
12006          test -z "$ac_c_werror_flag" ||
12007          test ! -s conftest.err
12008        } && test -s conftest.$ac_objext; then
12009   ac_header_compiler=yes
12010 else
12011   $as_echo "$as_me: failed program was:" >&5
12012 sed 's/^/| /' conftest.$ac_ext >&5
12013
12014         ac_header_compiler=no
12015 fi
12016
12017 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12018 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12019 $as_echo "$ac_header_compiler" >&6; }
12020
12021 # Is the header present?
12022 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12023 $as_echo_n "checking $ac_header presence... " >&6; }
12024 cat >conftest.$ac_ext <<_ACEOF
12025 /* confdefs.h.  */
12026 _ACEOF
12027 cat confdefs.h >>conftest.$ac_ext
12028 cat >>conftest.$ac_ext <<_ACEOF
12029 /* end confdefs.h.  */
12030 #include <$ac_header>
12031 _ACEOF
12032 if { (ac_try="$ac_cpp conftest.$ac_ext"
12033 case "(($ac_try" in
12034   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12035   *) ac_try_echo=$ac_try;;
12036 esac
12037 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12038 $as_echo "$ac_try_echo") >&5
12039   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12040   ac_status=$?
12041   grep -v '^ *+' conftest.er1 >conftest.err
12042   rm -f conftest.er1
12043   cat conftest.err >&5
12044   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12045   (exit $ac_status); } >/dev/null && {
12046          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12047          test ! -s conftest.err
12048        }; then
12049   ac_header_preproc=yes
12050 else
12051   $as_echo "$as_me: failed program was:" >&5
12052 sed 's/^/| /' conftest.$ac_ext >&5
12053
12054   ac_header_preproc=no
12055 fi
12056
12057 rm -f conftest.err conftest.$ac_ext
12058 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12059 $as_echo "$ac_header_preproc" >&6; }
12060
12061 # So?  What about this header?
12062 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12063   yes:no: )
12064     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12065 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12066     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12067 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12068     ac_header_preproc=yes
12069     ;;
12070   no:yes:* )
12071     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12072 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12073     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12074 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12075     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12076 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12077     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12078 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12079     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12080 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12081     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12082 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12083     ( cat <<\_ASBOX
12084 ## ---------------------------------------- ##
12085 ## Report this to pgsql-bugs@postgresql.org ##
12086 ## ---------------------------------------- ##
12087 _ASBOX
12088      ) | sed "s/^/$as_me: WARNING:     /" >&2
12089     ;;
12090 esac
12091 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12092 $as_echo_n "checking for $ac_header... " >&6; }
12093 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12094   $as_echo_n "(cached) " >&6
12095 else
12096   eval "$as_ac_Header=\$ac_header_preproc"
12097 fi
12098 ac_res=`eval 'as_val=${'$as_ac_Header'}
12099                  $as_echo "$as_val"'`
12100                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12101 $as_echo "$ac_res" >&6; }
12102
12103 fi
12104 as_val=`eval 'as_val=${'$as_ac_Header'}
12105                  $as_echo "$as_val"'`
12106    if test "x$as_val" = x""yes; then
12107   cat >>confdefs.h <<_ACEOF
12108 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12109 _ACEOF
12110
12111 else
12112   { { $as_echo "$as_me:$LINENO: error: readline header not found
12113 If you have libedit already installed, see config.log for details on the
12114 failure.  It is possible the compiler isn't looking in the proper directory.
12115 Use --without-readline to disable libedit support." >&5
12116 $as_echo "$as_me: error: readline header not found
12117 If you have libedit already installed, see config.log for details on the
12118 failure.  It is possible the compiler isn't looking in the proper directory.
12119 Use --without-readline to disable libedit support." >&2;}
12120    { (exit 1); exit 1; }; }
12121 fi
12122
12123 done
12124
12125 fi
12126
12127 done
12128
12129 fi
12130
12131 done
12132
12133 # Note: in a libedit installation, history.h is sometimes a dummy, and may
12134 # not be there at all.  Hence, don't complain if not found.  We must check
12135 # though, since in yet other versions it is an independent header.
12136
12137 for ac_header in editline/history.h
12138 do
12139 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12140 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12141   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12142 $as_echo_n "checking for $ac_header... " >&6; }
12143 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12144   $as_echo_n "(cached) " >&6
12145 fi
12146 ac_res=`eval 'as_val=${'$as_ac_Header'}
12147                  $as_echo "$as_val"'`
12148                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12149 $as_echo "$ac_res" >&6; }
12150 else
12151   # Is the header compilable?
12152 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12153 $as_echo_n "checking $ac_header usability... " >&6; }
12154 cat >conftest.$ac_ext <<_ACEOF
12155 /* confdefs.h.  */
12156 _ACEOF
12157 cat confdefs.h >>conftest.$ac_ext
12158 cat >>conftest.$ac_ext <<_ACEOF
12159 /* end confdefs.h.  */
12160 $ac_includes_default
12161 #include <$ac_header>
12162 _ACEOF
12163 rm -f conftest.$ac_objext
12164 if { (ac_try="$ac_compile"
12165 case "(($ac_try" in
12166   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12167   *) ac_try_echo=$ac_try;;
12168 esac
12169 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12170 $as_echo "$ac_try_echo") >&5
12171   (eval "$ac_compile") 2>conftest.er1
12172   ac_status=$?
12173   grep -v '^ *+' conftest.er1 >conftest.err
12174   rm -f conftest.er1
12175   cat conftest.err >&5
12176   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12177   (exit $ac_status); } && {
12178          test -z "$ac_c_werror_flag" ||
12179          test ! -s conftest.err
12180        } && test -s conftest.$ac_objext; then
12181   ac_header_compiler=yes
12182 else
12183   $as_echo "$as_me: failed program was:" >&5
12184 sed 's/^/| /' conftest.$ac_ext >&5
12185
12186         ac_header_compiler=no
12187 fi
12188
12189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12190 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12191 $as_echo "$ac_header_compiler" >&6; }
12192
12193 # Is the header present?
12194 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12195 $as_echo_n "checking $ac_header presence... " >&6; }
12196 cat >conftest.$ac_ext <<_ACEOF
12197 /* confdefs.h.  */
12198 _ACEOF
12199 cat confdefs.h >>conftest.$ac_ext
12200 cat >>conftest.$ac_ext <<_ACEOF
12201 /* end confdefs.h.  */
12202 #include <$ac_header>
12203 _ACEOF
12204 if { (ac_try="$ac_cpp conftest.$ac_ext"
12205 case "(($ac_try" in
12206   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12207   *) ac_try_echo=$ac_try;;
12208 esac
12209 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12210 $as_echo "$ac_try_echo") >&5
12211   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12212   ac_status=$?
12213   grep -v '^ *+' conftest.er1 >conftest.err
12214   rm -f conftest.er1
12215   cat conftest.err >&5
12216   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12217   (exit $ac_status); } >/dev/null && {
12218          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12219          test ! -s conftest.err
12220        }; then
12221   ac_header_preproc=yes
12222 else
12223   $as_echo "$as_me: failed program was:" >&5
12224 sed 's/^/| /' conftest.$ac_ext >&5
12225
12226   ac_header_preproc=no
12227 fi
12228
12229 rm -f conftest.err conftest.$ac_ext
12230 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12231 $as_echo "$ac_header_preproc" >&6; }
12232
12233 # So?  What about this header?
12234 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12235   yes:no: )
12236     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12237 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12238     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12239 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12240     ac_header_preproc=yes
12241     ;;
12242   no:yes:* )
12243     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12244 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12245     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12246 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12247     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12248 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12249     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12250 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12251     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12252 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12253     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12254 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12255     ( cat <<\_ASBOX
12256 ## ---------------------------------------- ##
12257 ## Report this to pgsql-bugs@postgresql.org ##
12258 ## ---------------------------------------- ##
12259 _ASBOX
12260      ) | sed "s/^/$as_me: WARNING:     /" >&2
12261     ;;
12262 esac
12263 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12264 $as_echo_n "checking for $ac_header... " >&6; }
12265 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12266   $as_echo_n "(cached) " >&6
12267 else
12268   eval "$as_ac_Header=\$ac_header_preproc"
12269 fi
12270 ac_res=`eval 'as_val=${'$as_ac_Header'}
12271                  $as_echo "$as_val"'`
12272                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12273 $as_echo "$ac_res" >&6; }
12274
12275 fi
12276 as_val=`eval 'as_val=${'$as_ac_Header'}
12277                  $as_echo "$as_val"'`
12278    if test "x$as_val" = x""yes; then
12279   cat >>confdefs.h <<_ACEOF
12280 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12281 _ACEOF
12282
12283 else
12284
12285 for ac_header in history.h
12286 do
12287 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12288 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12289   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12290 $as_echo_n "checking for $ac_header... " >&6; }
12291 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12292   $as_echo_n "(cached) " >&6
12293 fi
12294 ac_res=`eval 'as_val=${'$as_ac_Header'}
12295                  $as_echo "$as_val"'`
12296                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12297 $as_echo "$ac_res" >&6; }
12298 else
12299   # Is the header compilable?
12300 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12301 $as_echo_n "checking $ac_header usability... " >&6; }
12302 cat >conftest.$ac_ext <<_ACEOF
12303 /* confdefs.h.  */
12304 _ACEOF
12305 cat confdefs.h >>conftest.$ac_ext
12306 cat >>conftest.$ac_ext <<_ACEOF
12307 /* end confdefs.h.  */
12308 $ac_includes_default
12309 #include <$ac_header>
12310 _ACEOF
12311 rm -f conftest.$ac_objext
12312 if { (ac_try="$ac_compile"
12313 case "(($ac_try" in
12314   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12315   *) ac_try_echo=$ac_try;;
12316 esac
12317 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12318 $as_echo "$ac_try_echo") >&5
12319   (eval "$ac_compile") 2>conftest.er1
12320   ac_status=$?
12321   grep -v '^ *+' conftest.er1 >conftest.err
12322   rm -f conftest.er1
12323   cat conftest.err >&5
12324   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12325   (exit $ac_status); } && {
12326          test -z "$ac_c_werror_flag" ||
12327          test ! -s conftest.err
12328        } && test -s conftest.$ac_objext; then
12329   ac_header_compiler=yes
12330 else
12331   $as_echo "$as_me: failed program was:" >&5
12332 sed 's/^/| /' conftest.$ac_ext >&5
12333
12334         ac_header_compiler=no
12335 fi
12336
12337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12338 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12339 $as_echo "$ac_header_compiler" >&6; }
12340
12341 # Is the header present?
12342 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12343 $as_echo_n "checking $ac_header presence... " >&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 #include <$ac_header>
12351 _ACEOF
12352 if { (ac_try="$ac_cpp conftest.$ac_ext"
12353 case "(($ac_try" in
12354   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12355   *) ac_try_echo=$ac_try;;
12356 esac
12357 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12358 $as_echo "$ac_try_echo") >&5
12359   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12360   ac_status=$?
12361   grep -v '^ *+' conftest.er1 >conftest.err
12362   rm -f conftest.er1
12363   cat conftest.err >&5
12364   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12365   (exit $ac_status); } >/dev/null && {
12366          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12367          test ! -s conftest.err
12368        }; then
12369   ac_header_preproc=yes
12370 else
12371   $as_echo "$as_me: failed program was:" >&5
12372 sed 's/^/| /' conftest.$ac_ext >&5
12373
12374   ac_header_preproc=no
12375 fi
12376
12377 rm -f conftest.err conftest.$ac_ext
12378 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12379 $as_echo "$ac_header_preproc" >&6; }
12380
12381 # So?  What about this header?
12382 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12383   yes:no: )
12384     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12385 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12386     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12387 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12388     ac_header_preproc=yes
12389     ;;
12390   no:yes:* )
12391     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12392 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12393     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12394 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12395     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12396 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12397     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12398 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12399     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12400 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12401     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12402 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12403     ( cat <<\_ASBOX
12404 ## ---------------------------------------- ##
12405 ## Report this to pgsql-bugs@postgresql.org ##
12406 ## ---------------------------------------- ##
12407 _ASBOX
12408      ) | sed "s/^/$as_me: WARNING:     /" >&2
12409     ;;
12410 esac
12411 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12412 $as_echo_n "checking for $ac_header... " >&6; }
12413 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12414   $as_echo_n "(cached) " >&6
12415 else
12416   eval "$as_ac_Header=\$ac_header_preproc"
12417 fi
12418 ac_res=`eval 'as_val=${'$as_ac_Header'}
12419                  $as_echo "$as_val"'`
12420                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12421 $as_echo "$ac_res" >&6; }
12422
12423 fi
12424 as_val=`eval 'as_val=${'$as_ac_Header'}
12425                  $as_echo "$as_val"'`
12426    if test "x$as_val" = x""yes; then
12427   cat >>confdefs.h <<_ACEOF
12428 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12429 _ACEOF
12430
12431 else
12432
12433 for ac_header in readline/history.h
12434 do
12435 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12436 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12437   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12438 $as_echo_n "checking for $ac_header... " >&6; }
12439 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12440   $as_echo_n "(cached) " >&6
12441 fi
12442 ac_res=`eval 'as_val=${'$as_ac_Header'}
12443                  $as_echo "$as_val"'`
12444                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12445 $as_echo "$ac_res" >&6; }
12446 else
12447   # Is the header compilable?
12448 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12449 $as_echo_n "checking $ac_header usability... " >&6; }
12450 cat >conftest.$ac_ext <<_ACEOF
12451 /* confdefs.h.  */
12452 _ACEOF
12453 cat confdefs.h >>conftest.$ac_ext
12454 cat >>conftest.$ac_ext <<_ACEOF
12455 /* end confdefs.h.  */
12456 $ac_includes_default
12457 #include <$ac_header>
12458 _ACEOF
12459 rm -f conftest.$ac_objext
12460 if { (ac_try="$ac_compile"
12461 case "(($ac_try" in
12462   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12463   *) ac_try_echo=$ac_try;;
12464 esac
12465 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12466 $as_echo "$ac_try_echo") >&5
12467   (eval "$ac_compile") 2>conftest.er1
12468   ac_status=$?
12469   grep -v '^ *+' conftest.er1 >conftest.err
12470   rm -f conftest.er1
12471   cat conftest.err >&5
12472   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12473   (exit $ac_status); } && {
12474          test -z "$ac_c_werror_flag" ||
12475          test ! -s conftest.err
12476        } && test -s conftest.$ac_objext; then
12477   ac_header_compiler=yes
12478 else
12479   $as_echo "$as_me: failed program was:" >&5
12480 sed 's/^/| /' conftest.$ac_ext >&5
12481
12482         ac_header_compiler=no
12483 fi
12484
12485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12486 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12487 $as_echo "$ac_header_compiler" >&6; }
12488
12489 # Is the header present?
12490 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12491 $as_echo_n "checking $ac_header presence... " >&6; }
12492 cat >conftest.$ac_ext <<_ACEOF
12493 /* confdefs.h.  */
12494 _ACEOF
12495 cat confdefs.h >>conftest.$ac_ext
12496 cat >>conftest.$ac_ext <<_ACEOF
12497 /* end confdefs.h.  */
12498 #include <$ac_header>
12499 _ACEOF
12500 if { (ac_try="$ac_cpp conftest.$ac_ext"
12501 case "(($ac_try" in
12502   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12503   *) ac_try_echo=$ac_try;;
12504 esac
12505 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12506 $as_echo "$ac_try_echo") >&5
12507   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12508   ac_status=$?
12509   grep -v '^ *+' conftest.er1 >conftest.err
12510   rm -f conftest.er1
12511   cat conftest.err >&5
12512   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12513   (exit $ac_status); } >/dev/null && {
12514          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12515          test ! -s conftest.err
12516        }; then
12517   ac_header_preproc=yes
12518 else
12519   $as_echo "$as_me: failed program was:" >&5
12520 sed 's/^/| /' conftest.$ac_ext >&5
12521
12522   ac_header_preproc=no
12523 fi
12524
12525 rm -f conftest.err conftest.$ac_ext
12526 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12527 $as_echo "$ac_header_preproc" >&6; }
12528
12529 # So?  What about this header?
12530 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12531   yes:no: )
12532     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12533 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12534     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12535 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12536     ac_header_preproc=yes
12537     ;;
12538   no:yes:* )
12539     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12540 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12541     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12542 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12543     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12544 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12545     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12546 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12547     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12548 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12549     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12550 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12551     ( cat <<\_ASBOX
12552 ## ---------------------------------------- ##
12553 ## Report this to pgsql-bugs@postgresql.org ##
12554 ## ---------------------------------------- ##
12555 _ASBOX
12556      ) | sed "s/^/$as_me: WARNING:     /" >&2
12557     ;;
12558 esac
12559 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12560 $as_echo_n "checking for $ac_header... " >&6; }
12561 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12562   $as_echo_n "(cached) " >&6
12563 else
12564   eval "$as_ac_Header=\$ac_header_preproc"
12565 fi
12566 ac_res=`eval 'as_val=${'$as_ac_Header'}
12567                  $as_echo "$as_val"'`
12568                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12569 $as_echo "$ac_res" >&6; }
12570
12571 fi
12572 as_val=`eval 'as_val=${'$as_ac_Header'}
12573                  $as_echo "$as_val"'`
12574    if test "x$as_val" = x""yes; then
12575   cat >>confdefs.h <<_ACEOF
12576 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12577 _ACEOF
12578
12579 fi
12580
12581 done
12582
12583 fi
12584
12585 done
12586
12587 fi
12588
12589 done
12590
12591 fi
12592
12593 if test "$with_zlib" = yes; then
12594   if test "${ac_cv_header_zlib_h+set}" = set; then
12595   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
12596 $as_echo_n "checking for zlib.h... " >&6; }
12597 if test "${ac_cv_header_zlib_h+set}" = set; then
12598   $as_echo_n "(cached) " >&6
12599 fi
12600 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
12601 $as_echo "$ac_cv_header_zlib_h" >&6; }
12602 else
12603   # Is the header compilable?
12604 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
12605 $as_echo_n "checking zlib.h usability... " >&6; }
12606 cat >conftest.$ac_ext <<_ACEOF
12607 /* confdefs.h.  */
12608 _ACEOF
12609 cat confdefs.h >>conftest.$ac_ext
12610 cat >>conftest.$ac_ext <<_ACEOF
12611 /* end confdefs.h.  */
12612 $ac_includes_default
12613 #include <zlib.h>
12614 _ACEOF
12615 rm -f conftest.$ac_objext
12616 if { (ac_try="$ac_compile"
12617 case "(($ac_try" in
12618   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12619   *) ac_try_echo=$ac_try;;
12620 esac
12621 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12622 $as_echo "$ac_try_echo") >&5
12623   (eval "$ac_compile") 2>conftest.er1
12624   ac_status=$?
12625   grep -v '^ *+' conftest.er1 >conftest.err
12626   rm -f conftest.er1
12627   cat conftest.err >&5
12628   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12629   (exit $ac_status); } && {
12630          test -z "$ac_c_werror_flag" ||
12631          test ! -s conftest.err
12632        } && test -s conftest.$ac_objext; then
12633   ac_header_compiler=yes
12634 else
12635   $as_echo "$as_me: failed program was:" >&5
12636 sed 's/^/| /' conftest.$ac_ext >&5
12637
12638         ac_header_compiler=no
12639 fi
12640
12641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12642 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12643 $as_echo "$ac_header_compiler" >&6; }
12644
12645 # Is the header present?
12646 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
12647 $as_echo_n "checking zlib.h presence... " >&6; }
12648 cat >conftest.$ac_ext <<_ACEOF
12649 /* confdefs.h.  */
12650 _ACEOF
12651 cat confdefs.h >>conftest.$ac_ext
12652 cat >>conftest.$ac_ext <<_ACEOF
12653 /* end confdefs.h.  */
12654 #include <zlib.h>
12655 _ACEOF
12656 if { (ac_try="$ac_cpp conftest.$ac_ext"
12657 case "(($ac_try" in
12658   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12659   *) ac_try_echo=$ac_try;;
12660 esac
12661 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12662 $as_echo "$ac_try_echo") >&5
12663   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12664   ac_status=$?
12665   grep -v '^ *+' conftest.er1 >conftest.err
12666   rm -f conftest.er1
12667   cat conftest.err >&5
12668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12669   (exit $ac_status); } >/dev/null && {
12670          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12671          test ! -s conftest.err
12672        }; then
12673   ac_header_preproc=yes
12674 else
12675   $as_echo "$as_me: failed program was:" >&5
12676 sed 's/^/| /' conftest.$ac_ext >&5
12677
12678   ac_header_preproc=no
12679 fi
12680
12681 rm -f conftest.err conftest.$ac_ext
12682 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12683 $as_echo "$ac_header_preproc" >&6; }
12684
12685 # So?  What about this header?
12686 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12687   yes:no: )
12688     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12689 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12690     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
12691 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
12692     ac_header_preproc=yes
12693     ;;
12694   no:yes:* )
12695     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
12696 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
12697     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
12698 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
12699     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
12700 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
12701     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
12702 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12703     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
12704 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
12705     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
12706 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
12707     ( cat <<\_ASBOX
12708 ## ---------------------------------------- ##
12709 ## Report this to pgsql-bugs@postgresql.org ##
12710 ## ---------------------------------------- ##
12711 _ASBOX
12712      ) | sed "s/^/$as_me: WARNING:     /" >&2
12713     ;;
12714 esac
12715 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
12716 $as_echo_n "checking for zlib.h... " >&6; }
12717 if test "${ac_cv_header_zlib_h+set}" = set; then
12718   $as_echo_n "(cached) " >&6
12719 else
12720   ac_cv_header_zlib_h=$ac_header_preproc
12721 fi
12722 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
12723 $as_echo "$ac_cv_header_zlib_h" >&6; }
12724
12725 fi
12726 if test "x$ac_cv_header_zlib_h" = x""yes; then
12727   :
12728 else
12729   { { $as_echo "$as_me:$LINENO: error: zlib header not found
12730 If you have zlib already installed, see config.log for details on the
12731 failure.  It is possible the compiler isn't looking in the proper directory.
12732 Use --without-zlib to disable zlib support." >&5
12733 $as_echo "$as_me: error: zlib header not found
12734 If you have zlib already installed, see config.log for details on the
12735 failure.  It is possible the compiler isn't looking in the proper directory.
12736 Use --without-zlib to disable zlib support." >&2;}
12737    { (exit 1); exit 1; }; }
12738 fi
12739
12740
12741 fi
12742
12743 if test "$with_gssapi" = yes ; then
12744
12745 for ac_header in gssapi/gssapi.h
12746 do
12747 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12748 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12749   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12750 $as_echo_n "checking for $ac_header... " >&6; }
12751 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12752   $as_echo_n "(cached) " >&6
12753 fi
12754 ac_res=`eval 'as_val=${'$as_ac_Header'}
12755                  $as_echo "$as_val"'`
12756                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12757 $as_echo "$ac_res" >&6; }
12758 else
12759   # Is the header compilable?
12760 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12761 $as_echo_n "checking $ac_header usability... " >&6; }
12762 cat >conftest.$ac_ext <<_ACEOF
12763 /* confdefs.h.  */
12764 _ACEOF
12765 cat confdefs.h >>conftest.$ac_ext
12766 cat >>conftest.$ac_ext <<_ACEOF
12767 /* end confdefs.h.  */
12768 $ac_includes_default
12769 #include <$ac_header>
12770 _ACEOF
12771 rm -f conftest.$ac_objext
12772 if { (ac_try="$ac_compile"
12773 case "(($ac_try" in
12774   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12775   *) ac_try_echo=$ac_try;;
12776 esac
12777 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12778 $as_echo "$ac_try_echo") >&5
12779   (eval "$ac_compile") 2>conftest.er1
12780   ac_status=$?
12781   grep -v '^ *+' conftest.er1 >conftest.err
12782   rm -f conftest.er1
12783   cat conftest.err >&5
12784   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12785   (exit $ac_status); } && {
12786          test -z "$ac_c_werror_flag" ||
12787          test ! -s conftest.err
12788        } && test -s conftest.$ac_objext; then
12789   ac_header_compiler=yes
12790 else
12791   $as_echo "$as_me: failed program was:" >&5
12792 sed 's/^/| /' conftest.$ac_ext >&5
12793
12794         ac_header_compiler=no
12795 fi
12796
12797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12798 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12799 $as_echo "$ac_header_compiler" >&6; }
12800
12801 # Is the header present?
12802 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12803 $as_echo_n "checking $ac_header presence... " >&6; }
12804 cat >conftest.$ac_ext <<_ACEOF
12805 /* confdefs.h.  */
12806 _ACEOF
12807 cat confdefs.h >>conftest.$ac_ext
12808 cat >>conftest.$ac_ext <<_ACEOF
12809 /* end confdefs.h.  */
12810 #include <$ac_header>
12811 _ACEOF
12812 if { (ac_try="$ac_cpp conftest.$ac_ext"
12813 case "(($ac_try" in
12814   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12815   *) ac_try_echo=$ac_try;;
12816 esac
12817 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12818 $as_echo "$ac_try_echo") >&5
12819   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12820   ac_status=$?
12821   grep -v '^ *+' conftest.er1 >conftest.err
12822   rm -f conftest.er1
12823   cat conftest.err >&5
12824   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12825   (exit $ac_status); } >/dev/null && {
12826          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12827          test ! -s conftest.err
12828        }; then
12829   ac_header_preproc=yes
12830 else
12831   $as_echo "$as_me: failed program was:" >&5
12832 sed 's/^/| /' conftest.$ac_ext >&5
12833
12834   ac_header_preproc=no
12835 fi
12836
12837 rm -f conftest.err conftest.$ac_ext
12838 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12839 $as_echo "$ac_header_preproc" >&6; }
12840
12841 # So?  What about this header?
12842 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12843   yes:no: )
12844     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12845 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12846     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12847 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12848     ac_header_preproc=yes
12849     ;;
12850   no:yes:* )
12851     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12852 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12853     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12854 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12855     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12856 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12857     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12858 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12859     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12860 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12861     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12862 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12863     ( cat <<\_ASBOX
12864 ## ---------------------------------------- ##
12865 ## Report this to pgsql-bugs@postgresql.org ##
12866 ## ---------------------------------------- ##
12867 _ASBOX
12868      ) | sed "s/^/$as_me: WARNING:     /" >&2
12869     ;;
12870 esac
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 else
12876   eval "$as_ac_Header=\$ac_header_preproc"
12877 fi
12878 ac_res=`eval 'as_val=${'$as_ac_Header'}
12879                  $as_echo "$as_val"'`
12880                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12881 $as_echo "$ac_res" >&6; }
12882
12883 fi
12884 as_val=`eval 'as_val=${'$as_ac_Header'}
12885                  $as_echo "$as_val"'`
12886    if test "x$as_val" = x""yes; then
12887   cat >>confdefs.h <<_ACEOF
12888 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12889 _ACEOF
12890
12891 else
12892
12893 for ac_header in gssapi.h
12894 do
12895 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12896 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12897   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12898 $as_echo_n "checking for $ac_header... " >&6; }
12899 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12900   $as_echo_n "(cached) " >&6
12901 fi
12902 ac_res=`eval 'as_val=${'$as_ac_Header'}
12903                  $as_echo "$as_val"'`
12904                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12905 $as_echo "$ac_res" >&6; }
12906 else
12907   # Is the header compilable?
12908 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12909 $as_echo_n "checking $ac_header usability... " >&6; }
12910 cat >conftest.$ac_ext <<_ACEOF
12911 /* confdefs.h.  */
12912 _ACEOF
12913 cat confdefs.h >>conftest.$ac_ext
12914 cat >>conftest.$ac_ext <<_ACEOF
12915 /* end confdefs.h.  */
12916 $ac_includes_default
12917 #include <$ac_header>
12918 _ACEOF
12919 rm -f conftest.$ac_objext
12920 if { (ac_try="$ac_compile"
12921 case "(($ac_try" in
12922   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12923   *) ac_try_echo=$ac_try;;
12924 esac
12925 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12926 $as_echo "$ac_try_echo") >&5
12927   (eval "$ac_compile") 2>conftest.er1
12928   ac_status=$?
12929   grep -v '^ *+' conftest.er1 >conftest.err
12930   rm -f conftest.er1
12931   cat conftest.err >&5
12932   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12933   (exit $ac_status); } && {
12934          test -z "$ac_c_werror_flag" ||
12935          test ! -s conftest.err
12936        } && test -s conftest.$ac_objext; then
12937   ac_header_compiler=yes
12938 else
12939   $as_echo "$as_me: failed program was:" >&5
12940 sed 's/^/| /' conftest.$ac_ext >&5
12941
12942         ac_header_compiler=no
12943 fi
12944
12945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12946 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12947 $as_echo "$ac_header_compiler" >&6; }
12948
12949 # Is the header present?
12950 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12951 $as_echo_n "checking $ac_header presence... " >&6; }
12952 cat >conftest.$ac_ext <<_ACEOF
12953 /* confdefs.h.  */
12954 _ACEOF
12955 cat confdefs.h >>conftest.$ac_ext
12956 cat >>conftest.$ac_ext <<_ACEOF
12957 /* end confdefs.h.  */
12958 #include <$ac_header>
12959 _ACEOF
12960 if { (ac_try="$ac_cpp conftest.$ac_ext"
12961 case "(($ac_try" in
12962   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12963   *) ac_try_echo=$ac_try;;
12964 esac
12965 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12966 $as_echo "$ac_try_echo") >&5
12967   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12968   ac_status=$?
12969   grep -v '^ *+' conftest.er1 >conftest.err
12970   rm -f conftest.er1
12971   cat conftest.err >&5
12972   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12973   (exit $ac_status); } >/dev/null && {
12974          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12975          test ! -s conftest.err
12976        }; then
12977   ac_header_preproc=yes
12978 else
12979   $as_echo "$as_me: failed program was:" >&5
12980 sed 's/^/| /' conftest.$ac_ext >&5
12981
12982   ac_header_preproc=no
12983 fi
12984
12985 rm -f conftest.err conftest.$ac_ext
12986 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12987 $as_echo "$ac_header_preproc" >&6; }
12988
12989 # So?  What about this header?
12990 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12991   yes:no: )
12992     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12993 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12994     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12995 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12996     ac_header_preproc=yes
12997     ;;
12998   no:yes:* )
12999     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13000 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13001     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13002 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13003     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13004 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13005     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13006 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13007     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13008 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13009     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13010 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13011     ( cat <<\_ASBOX
13012 ## ---------------------------------------- ##
13013 ## Report this to pgsql-bugs@postgresql.org ##
13014 ## ---------------------------------------- ##
13015 _ASBOX
13016      ) | sed "s/^/$as_me: WARNING:     /" >&2
13017     ;;
13018 esac
13019 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13020 $as_echo_n "checking for $ac_header... " >&6; }
13021 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13022   $as_echo_n "(cached) " >&6
13023 else
13024   eval "$as_ac_Header=\$ac_header_preproc"
13025 fi
13026 ac_res=`eval 'as_val=${'$as_ac_Header'}
13027                  $as_echo "$as_val"'`
13028                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13029 $as_echo "$ac_res" >&6; }
13030
13031 fi
13032 as_val=`eval 'as_val=${'$as_ac_Header'}
13033                  $as_echo "$as_val"'`
13034    if test "x$as_val" = x""yes; then
13035   cat >>confdefs.h <<_ACEOF
13036 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13037 _ACEOF
13038
13039 else
13040   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
13041 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
13042    { (exit 1); exit 1; }; }
13043 fi
13044
13045 done
13046
13047 fi
13048
13049 done
13050
13051 fi
13052
13053 if test "$with_krb5" = yes ; then
13054   if test "${ac_cv_header_krb5_h+set}" = set; then
13055   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
13056 $as_echo_n "checking for krb5.h... " >&6; }
13057 if test "${ac_cv_header_krb5_h+set}" = set; then
13058   $as_echo_n "(cached) " >&6
13059 fi
13060 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
13061 $as_echo "$ac_cv_header_krb5_h" >&6; }
13062 else
13063   # Is the header compilable?
13064 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
13065 $as_echo_n "checking krb5.h usability... " >&6; }
13066 cat >conftest.$ac_ext <<_ACEOF
13067 /* confdefs.h.  */
13068 _ACEOF
13069 cat confdefs.h >>conftest.$ac_ext
13070 cat >>conftest.$ac_ext <<_ACEOF
13071 /* end confdefs.h.  */
13072 $ac_includes_default
13073 #include <krb5.h>
13074 _ACEOF
13075 rm -f conftest.$ac_objext
13076 if { (ac_try="$ac_compile"
13077 case "(($ac_try" in
13078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13079   *) ac_try_echo=$ac_try;;
13080 esac
13081 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13082 $as_echo "$ac_try_echo") >&5
13083   (eval "$ac_compile") 2>conftest.er1
13084   ac_status=$?
13085   grep -v '^ *+' conftest.er1 >conftest.err
13086   rm -f conftest.er1
13087   cat conftest.err >&5
13088   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13089   (exit $ac_status); } && {
13090          test -z "$ac_c_werror_flag" ||
13091          test ! -s conftest.err
13092        } && test -s conftest.$ac_objext; then
13093   ac_header_compiler=yes
13094 else
13095   $as_echo "$as_me: failed program was:" >&5
13096 sed 's/^/| /' conftest.$ac_ext >&5
13097
13098         ac_header_compiler=no
13099 fi
13100
13101 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13102 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13103 $as_echo "$ac_header_compiler" >&6; }
13104
13105 # Is the header present?
13106 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
13107 $as_echo_n "checking krb5.h presence... " >&6; }
13108 cat >conftest.$ac_ext <<_ACEOF
13109 /* confdefs.h.  */
13110 _ACEOF
13111 cat confdefs.h >>conftest.$ac_ext
13112 cat >>conftest.$ac_ext <<_ACEOF
13113 /* end confdefs.h.  */
13114 #include <krb5.h>
13115 _ACEOF
13116 if { (ac_try="$ac_cpp conftest.$ac_ext"
13117 case "(($ac_try" in
13118   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13119   *) ac_try_echo=$ac_try;;
13120 esac
13121 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13122 $as_echo "$ac_try_echo") >&5
13123   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13124   ac_status=$?
13125   grep -v '^ *+' conftest.er1 >conftest.err
13126   rm -f conftest.er1
13127   cat conftest.err >&5
13128   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13129   (exit $ac_status); } >/dev/null && {
13130          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13131          test ! -s conftest.err
13132        }; then
13133   ac_header_preproc=yes
13134 else
13135   $as_echo "$as_me: failed program was:" >&5
13136 sed 's/^/| /' conftest.$ac_ext >&5
13137
13138   ac_header_preproc=no
13139 fi
13140
13141 rm -f conftest.err conftest.$ac_ext
13142 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13143 $as_echo "$ac_header_preproc" >&6; }
13144
13145 # So?  What about this header?
13146 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13147   yes:no: )
13148     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
13149 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13150     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
13151 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
13152     ac_header_preproc=yes
13153     ;;
13154   no:yes:* )
13155     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
13156 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
13157     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
13158 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
13159     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
13160 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
13161     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
13162 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13163     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
13164 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
13165     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
13166 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
13167     ( cat <<\_ASBOX
13168 ## ---------------------------------------- ##
13169 ## Report this to pgsql-bugs@postgresql.org ##
13170 ## ---------------------------------------- ##
13171 _ASBOX
13172      ) | sed "s/^/$as_me: WARNING:     /" >&2
13173     ;;
13174 esac
13175 { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
13176 $as_echo_n "checking for krb5.h... " >&6; }
13177 if test "${ac_cv_header_krb5_h+set}" = set; then
13178   $as_echo_n "(cached) " >&6
13179 else
13180   ac_cv_header_krb5_h=$ac_header_preproc
13181 fi
13182 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
13183 $as_echo "$ac_cv_header_krb5_h" >&6; }
13184
13185 fi
13186 if test "x$ac_cv_header_krb5_h" = x""yes; then
13187   :
13188 else
13189   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
13190 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
13191    { (exit 1); exit 1; }; }
13192 fi
13193
13194
13195 fi
13196
13197 if test "$with_openssl" = yes ; then
13198   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
13199   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
13200 $as_echo_n "checking for openssl/ssl.h... " >&6; }
13201 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
13202   $as_echo_n "(cached) " >&6
13203 fi
13204 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
13205 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
13206 else
13207   # Is the header compilable?
13208 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
13209 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
13210 cat >conftest.$ac_ext <<_ACEOF
13211 /* confdefs.h.  */
13212 _ACEOF
13213 cat confdefs.h >>conftest.$ac_ext
13214 cat >>conftest.$ac_ext <<_ACEOF
13215 /* end confdefs.h.  */
13216 $ac_includes_default
13217 #include <openssl/ssl.h>
13218 _ACEOF
13219 rm -f conftest.$ac_objext
13220 if { (ac_try="$ac_compile"
13221 case "(($ac_try" in
13222   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13223   *) ac_try_echo=$ac_try;;
13224 esac
13225 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13226 $as_echo "$ac_try_echo") >&5
13227   (eval "$ac_compile") 2>conftest.er1
13228   ac_status=$?
13229   grep -v '^ *+' conftest.er1 >conftest.err
13230   rm -f conftest.er1
13231   cat conftest.err >&5
13232   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13233   (exit $ac_status); } && {
13234          test -z "$ac_c_werror_flag" ||
13235          test ! -s conftest.err
13236        } && test -s conftest.$ac_objext; then
13237   ac_header_compiler=yes
13238 else
13239   $as_echo "$as_me: failed program was:" >&5
13240 sed 's/^/| /' conftest.$ac_ext >&5
13241
13242         ac_header_compiler=no
13243 fi
13244
13245 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13246 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13247 $as_echo "$ac_header_compiler" >&6; }
13248
13249 # Is the header present?
13250 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
13251 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
13252 cat >conftest.$ac_ext <<_ACEOF
13253 /* confdefs.h.  */
13254 _ACEOF
13255 cat confdefs.h >>conftest.$ac_ext
13256 cat >>conftest.$ac_ext <<_ACEOF
13257 /* end confdefs.h.  */
13258 #include <openssl/ssl.h>
13259 _ACEOF
13260 if { (ac_try="$ac_cpp conftest.$ac_ext"
13261 case "(($ac_try" in
13262   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13263   *) ac_try_echo=$ac_try;;
13264 esac
13265 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13266 $as_echo "$ac_try_echo") >&5
13267   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13268   ac_status=$?
13269   grep -v '^ *+' conftest.er1 >conftest.err
13270   rm -f conftest.er1
13271   cat conftest.err >&5
13272   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13273   (exit $ac_status); } >/dev/null && {
13274          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13275          test ! -s conftest.err
13276        }; then
13277   ac_header_preproc=yes
13278 else
13279   $as_echo "$as_me: failed program was:" >&5
13280 sed 's/^/| /' conftest.$ac_ext >&5
13281
13282   ac_header_preproc=no
13283 fi
13284
13285 rm -f conftest.err conftest.$ac_ext
13286 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13287 $as_echo "$ac_header_preproc" >&6; }
13288
13289 # So?  What about this header?
13290 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13291   yes:no: )
13292     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
13293 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13294     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
13295 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
13296     ac_header_preproc=yes
13297     ;;
13298   no:yes:* )
13299     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
13300 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
13301     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
13302 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
13303     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
13304 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
13305     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
13306 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13307     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
13308 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
13309     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
13310 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
13311     ( cat <<\_ASBOX
13312 ## ---------------------------------------- ##
13313 ## Report this to pgsql-bugs@postgresql.org ##
13314 ## ---------------------------------------- ##
13315 _ASBOX
13316      ) | sed "s/^/$as_me: WARNING:     /" >&2
13317     ;;
13318 esac
13319 { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
13320 $as_echo_n "checking for openssl/ssl.h... " >&6; }
13321 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
13322   $as_echo_n "(cached) " >&6
13323 else
13324   ac_cv_header_openssl_ssl_h=$ac_header_preproc
13325 fi
13326 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
13327 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
13328
13329 fi
13330 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
13331   :
13332 else
13333   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
13334 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
13335    { (exit 1); exit 1; }; }
13336 fi
13337
13338
13339   if test "${ac_cv_header_openssl_err_h+set}" = set; then
13340   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
13341 $as_echo_n "checking for openssl/err.h... " >&6; }
13342 if test "${ac_cv_header_openssl_err_h+set}" = set; then
13343   $as_echo_n "(cached) " >&6
13344 fi
13345 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
13346 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
13347 else
13348   # Is the header compilable?
13349 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
13350 $as_echo_n "checking openssl/err.h usability... " >&6; }
13351 cat >conftest.$ac_ext <<_ACEOF
13352 /* confdefs.h.  */
13353 _ACEOF
13354 cat confdefs.h >>conftest.$ac_ext
13355 cat >>conftest.$ac_ext <<_ACEOF
13356 /* end confdefs.h.  */
13357 $ac_includes_default
13358 #include <openssl/err.h>
13359 _ACEOF
13360 rm -f conftest.$ac_objext
13361 if { (ac_try="$ac_compile"
13362 case "(($ac_try" in
13363   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13364   *) ac_try_echo=$ac_try;;
13365 esac
13366 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13367 $as_echo "$ac_try_echo") >&5
13368   (eval "$ac_compile") 2>conftest.er1
13369   ac_status=$?
13370   grep -v '^ *+' conftest.er1 >conftest.err
13371   rm -f conftest.er1
13372   cat conftest.err >&5
13373   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13374   (exit $ac_status); } && {
13375          test -z "$ac_c_werror_flag" ||
13376          test ! -s conftest.err
13377        } && test -s conftest.$ac_objext; then
13378   ac_header_compiler=yes
13379 else
13380   $as_echo "$as_me: failed program was:" >&5
13381 sed 's/^/| /' conftest.$ac_ext >&5
13382
13383         ac_header_compiler=no
13384 fi
13385
13386 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13387 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13388 $as_echo "$ac_header_compiler" >&6; }
13389
13390 # Is the header present?
13391 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
13392 $as_echo_n "checking openssl/err.h presence... " >&6; }
13393 cat >conftest.$ac_ext <<_ACEOF
13394 /* confdefs.h.  */
13395 _ACEOF
13396 cat confdefs.h >>conftest.$ac_ext
13397 cat >>conftest.$ac_ext <<_ACEOF
13398 /* end confdefs.h.  */
13399 #include <openssl/err.h>
13400 _ACEOF
13401 if { (ac_try="$ac_cpp conftest.$ac_ext"
13402 case "(($ac_try" in
13403   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13404   *) ac_try_echo=$ac_try;;
13405 esac
13406 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13407 $as_echo "$ac_try_echo") >&5
13408   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13409   ac_status=$?
13410   grep -v '^ *+' conftest.er1 >conftest.err
13411   rm -f conftest.er1
13412   cat conftest.err >&5
13413   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13414   (exit $ac_status); } >/dev/null && {
13415          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13416          test ! -s conftest.err
13417        }; then
13418   ac_header_preproc=yes
13419 else
13420   $as_echo "$as_me: failed program was:" >&5
13421 sed 's/^/| /' conftest.$ac_ext >&5
13422
13423   ac_header_preproc=no
13424 fi
13425
13426 rm -f conftest.err conftest.$ac_ext
13427 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13428 $as_echo "$ac_header_preproc" >&6; }
13429
13430 # So?  What about this header?
13431 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13432   yes:no: )
13433     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
13434 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13435     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
13436 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
13437     ac_header_preproc=yes
13438     ;;
13439   no:yes:* )
13440     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
13441 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
13442     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
13443 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
13444     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
13445 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
13446     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
13447 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13448     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
13449 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
13450     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
13451 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
13452     ( cat <<\_ASBOX
13453 ## ---------------------------------------- ##
13454 ## Report this to pgsql-bugs@postgresql.org ##
13455 ## ---------------------------------------- ##
13456 _ASBOX
13457      ) | sed "s/^/$as_me: WARNING:     /" >&2
13458     ;;
13459 esac
13460 { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
13461 $as_echo_n "checking for openssl/err.h... " >&6; }
13462 if test "${ac_cv_header_openssl_err_h+set}" = set; then
13463   $as_echo_n "(cached) " >&6
13464 else
13465   ac_cv_header_openssl_err_h=$ac_header_preproc
13466 fi
13467 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
13468 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
13469
13470 fi
13471 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
13472   :
13473 else
13474   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
13475 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
13476    { (exit 1); exit 1; }; }
13477 fi
13478
13479
13480 fi
13481
13482 if test "$with_pam" = yes ; then
13483
13484 for ac_header in security/pam_appl.h
13485 do
13486 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13487 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13488   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13489 $as_echo_n "checking for $ac_header... " >&6; }
13490 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13491   $as_echo_n "(cached) " >&6
13492 fi
13493 ac_res=`eval 'as_val=${'$as_ac_Header'}
13494                  $as_echo "$as_val"'`
13495                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13496 $as_echo "$ac_res" >&6; }
13497 else
13498   # Is the header compilable?
13499 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13500 $as_echo_n "checking $ac_header usability... " >&6; }
13501 cat >conftest.$ac_ext <<_ACEOF
13502 /* confdefs.h.  */
13503 _ACEOF
13504 cat confdefs.h >>conftest.$ac_ext
13505 cat >>conftest.$ac_ext <<_ACEOF
13506 /* end confdefs.h.  */
13507 $ac_includes_default
13508 #include <$ac_header>
13509 _ACEOF
13510 rm -f conftest.$ac_objext
13511 if { (ac_try="$ac_compile"
13512 case "(($ac_try" in
13513   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13514   *) ac_try_echo=$ac_try;;
13515 esac
13516 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13517 $as_echo "$ac_try_echo") >&5
13518   (eval "$ac_compile") 2>conftest.er1
13519   ac_status=$?
13520   grep -v '^ *+' conftest.er1 >conftest.err
13521   rm -f conftest.er1
13522   cat conftest.err >&5
13523   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13524   (exit $ac_status); } && {
13525          test -z "$ac_c_werror_flag" ||
13526          test ! -s conftest.err
13527        } && test -s conftest.$ac_objext; then
13528   ac_header_compiler=yes
13529 else
13530   $as_echo "$as_me: failed program was:" >&5
13531 sed 's/^/| /' conftest.$ac_ext >&5
13532
13533         ac_header_compiler=no
13534 fi
13535
13536 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13537 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13538 $as_echo "$ac_header_compiler" >&6; }
13539
13540 # Is the header present?
13541 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13542 $as_echo_n "checking $ac_header presence... " >&6; }
13543 cat >conftest.$ac_ext <<_ACEOF
13544 /* confdefs.h.  */
13545 _ACEOF
13546 cat confdefs.h >>conftest.$ac_ext
13547 cat >>conftest.$ac_ext <<_ACEOF
13548 /* end confdefs.h.  */
13549 #include <$ac_header>
13550 _ACEOF
13551 if { (ac_try="$ac_cpp conftest.$ac_ext"
13552 case "(($ac_try" in
13553   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13554   *) ac_try_echo=$ac_try;;
13555 esac
13556 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13557 $as_echo "$ac_try_echo") >&5
13558   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13559   ac_status=$?
13560   grep -v '^ *+' conftest.er1 >conftest.err
13561   rm -f conftest.er1
13562   cat conftest.err >&5
13563   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13564   (exit $ac_status); } >/dev/null && {
13565          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13566          test ! -s conftest.err
13567        }; then
13568   ac_header_preproc=yes
13569 else
13570   $as_echo "$as_me: failed program was:" >&5
13571 sed 's/^/| /' conftest.$ac_ext >&5
13572
13573   ac_header_preproc=no
13574 fi
13575
13576 rm -f conftest.err conftest.$ac_ext
13577 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13578 $as_echo "$ac_header_preproc" >&6; }
13579
13580 # So?  What about this header?
13581 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13582   yes:no: )
13583     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13584 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13585     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13586 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13587     ac_header_preproc=yes
13588     ;;
13589   no:yes:* )
13590     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13591 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13592     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13593 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13594     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13595 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13596     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13597 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13598     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13599 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13600     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13601 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13602     ( cat <<\_ASBOX
13603 ## ---------------------------------------- ##
13604 ## Report this to pgsql-bugs@postgresql.org ##
13605 ## ---------------------------------------- ##
13606 _ASBOX
13607      ) | sed "s/^/$as_me: WARNING:     /" >&2
13608     ;;
13609 esac
13610 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13611 $as_echo_n "checking for $ac_header... " >&6; }
13612 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13613   $as_echo_n "(cached) " >&6
13614 else
13615   eval "$as_ac_Header=\$ac_header_preproc"
13616 fi
13617 ac_res=`eval 'as_val=${'$as_ac_Header'}
13618                  $as_echo "$as_val"'`
13619                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13620 $as_echo "$ac_res" >&6; }
13621
13622 fi
13623 as_val=`eval 'as_val=${'$as_ac_Header'}
13624                  $as_echo "$as_val"'`
13625    if test "x$as_val" = x""yes; then
13626   cat >>confdefs.h <<_ACEOF
13627 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13628 _ACEOF
13629
13630 else
13631
13632 for ac_header in pam/pam_appl.h
13633 do
13634 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13635 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13636   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13637 $as_echo_n "checking for $ac_header... " >&6; }
13638 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13639   $as_echo_n "(cached) " >&6
13640 fi
13641 ac_res=`eval 'as_val=${'$as_ac_Header'}
13642                  $as_echo "$as_val"'`
13643                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13644 $as_echo "$ac_res" >&6; }
13645 else
13646   # Is the header compilable?
13647 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13648 $as_echo_n "checking $ac_header usability... " >&6; }
13649 cat >conftest.$ac_ext <<_ACEOF
13650 /* confdefs.h.  */
13651 _ACEOF
13652 cat confdefs.h >>conftest.$ac_ext
13653 cat >>conftest.$ac_ext <<_ACEOF
13654 /* end confdefs.h.  */
13655 $ac_includes_default
13656 #include <$ac_header>
13657 _ACEOF
13658 rm -f conftest.$ac_objext
13659 if { (ac_try="$ac_compile"
13660 case "(($ac_try" in
13661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13662   *) ac_try_echo=$ac_try;;
13663 esac
13664 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13665 $as_echo "$ac_try_echo") >&5
13666   (eval "$ac_compile") 2>conftest.er1
13667   ac_status=$?
13668   grep -v '^ *+' conftest.er1 >conftest.err
13669   rm -f conftest.er1
13670   cat conftest.err >&5
13671   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13672   (exit $ac_status); } && {
13673          test -z "$ac_c_werror_flag" ||
13674          test ! -s conftest.err
13675        } && test -s conftest.$ac_objext; then
13676   ac_header_compiler=yes
13677 else
13678   $as_echo "$as_me: failed program was:" >&5
13679 sed 's/^/| /' conftest.$ac_ext >&5
13680
13681         ac_header_compiler=no
13682 fi
13683
13684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13685 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13686 $as_echo "$ac_header_compiler" >&6; }
13687
13688 # Is the header present?
13689 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13690 $as_echo_n "checking $ac_header presence... " >&6; }
13691 cat >conftest.$ac_ext <<_ACEOF
13692 /* confdefs.h.  */
13693 _ACEOF
13694 cat confdefs.h >>conftest.$ac_ext
13695 cat >>conftest.$ac_ext <<_ACEOF
13696 /* end confdefs.h.  */
13697 #include <$ac_header>
13698 _ACEOF
13699 if { (ac_try="$ac_cpp conftest.$ac_ext"
13700 case "(($ac_try" in
13701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13702   *) ac_try_echo=$ac_try;;
13703 esac
13704 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13705 $as_echo "$ac_try_echo") >&5
13706   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13707   ac_status=$?
13708   grep -v '^ *+' conftest.er1 >conftest.err
13709   rm -f conftest.er1
13710   cat conftest.err >&5
13711   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13712   (exit $ac_status); } >/dev/null && {
13713          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13714          test ! -s conftest.err
13715        }; then
13716   ac_header_preproc=yes
13717 else
13718   $as_echo "$as_me: failed program was:" >&5
13719 sed 's/^/| /' conftest.$ac_ext >&5
13720
13721   ac_header_preproc=no
13722 fi
13723
13724 rm -f conftest.err conftest.$ac_ext
13725 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13726 $as_echo "$ac_header_preproc" >&6; }
13727
13728 # So?  What about this header?
13729 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13730   yes:no: )
13731     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13732 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13733     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13734 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13735     ac_header_preproc=yes
13736     ;;
13737   no:yes:* )
13738     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13739 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13740     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13741 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13742     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13743 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13744     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13745 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13746     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13747 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13748     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13749 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13750     ( cat <<\_ASBOX
13751 ## ---------------------------------------- ##
13752 ## Report this to pgsql-bugs@postgresql.org ##
13753 ## ---------------------------------------- ##
13754 _ASBOX
13755      ) | sed "s/^/$as_me: WARNING:     /" >&2
13756     ;;
13757 esac
13758 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13759 $as_echo_n "checking for $ac_header... " >&6; }
13760 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13761   $as_echo_n "(cached) " >&6
13762 else
13763   eval "$as_ac_Header=\$ac_header_preproc"
13764 fi
13765 ac_res=`eval 'as_val=${'$as_ac_Header'}
13766                  $as_echo "$as_val"'`
13767                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13768 $as_echo "$ac_res" >&6; }
13769
13770 fi
13771 as_val=`eval 'as_val=${'$as_ac_Header'}
13772                  $as_echo "$as_val"'`
13773    if test "x$as_val" = x""yes; then
13774   cat >>confdefs.h <<_ACEOF
13775 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13776 _ACEOF
13777
13778 else
13779   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
13780 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
13781    { (exit 1); exit 1; }; }
13782 fi
13783
13784 done
13785
13786 fi
13787
13788 done
13789
13790 fi
13791
13792 if test "$with_libxml" = yes ; then
13793   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13794   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13795 $as_echo_n "checking for libxml/parser.h... " >&6; }
13796 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13797   $as_echo_n "(cached) " >&6
13798 fi
13799 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13800 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13801 else
13802   # Is the header compilable?
13803 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
13804 $as_echo_n "checking libxml/parser.h usability... " >&6; }
13805 cat >conftest.$ac_ext <<_ACEOF
13806 /* confdefs.h.  */
13807 _ACEOF
13808 cat confdefs.h >>conftest.$ac_ext
13809 cat >>conftest.$ac_ext <<_ACEOF
13810 /* end confdefs.h.  */
13811 $ac_includes_default
13812 #include <libxml/parser.h>
13813 _ACEOF
13814 rm -f conftest.$ac_objext
13815 if { (ac_try="$ac_compile"
13816 case "(($ac_try" in
13817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13818   *) ac_try_echo=$ac_try;;
13819 esac
13820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13821 $as_echo "$ac_try_echo") >&5
13822   (eval "$ac_compile") 2>conftest.er1
13823   ac_status=$?
13824   grep -v '^ *+' conftest.er1 >conftest.err
13825   rm -f conftest.er1
13826   cat conftest.err >&5
13827   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13828   (exit $ac_status); } && {
13829          test -z "$ac_c_werror_flag" ||
13830          test ! -s conftest.err
13831        } && test -s conftest.$ac_objext; then
13832   ac_header_compiler=yes
13833 else
13834   $as_echo "$as_me: failed program was:" >&5
13835 sed 's/^/| /' conftest.$ac_ext >&5
13836
13837         ac_header_compiler=no
13838 fi
13839
13840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13841 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13842 $as_echo "$ac_header_compiler" >&6; }
13843
13844 # Is the header present?
13845 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
13846 $as_echo_n "checking libxml/parser.h presence... " >&6; }
13847 cat >conftest.$ac_ext <<_ACEOF
13848 /* confdefs.h.  */
13849 _ACEOF
13850 cat confdefs.h >>conftest.$ac_ext
13851 cat >>conftest.$ac_ext <<_ACEOF
13852 /* end confdefs.h.  */
13853 #include <libxml/parser.h>
13854 _ACEOF
13855 if { (ac_try="$ac_cpp conftest.$ac_ext"
13856 case "(($ac_try" in
13857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13858   *) ac_try_echo=$ac_try;;
13859 esac
13860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13861 $as_echo "$ac_try_echo") >&5
13862   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13863   ac_status=$?
13864   grep -v '^ *+' conftest.er1 >conftest.err
13865   rm -f conftest.er1
13866   cat conftest.err >&5
13867   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13868   (exit $ac_status); } >/dev/null && {
13869          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13870          test ! -s conftest.err
13871        }; then
13872   ac_header_preproc=yes
13873 else
13874   $as_echo "$as_me: failed program was:" >&5
13875 sed 's/^/| /' conftest.$ac_ext >&5
13876
13877   ac_header_preproc=no
13878 fi
13879
13880 rm -f conftest.err conftest.$ac_ext
13881 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13882 $as_echo "$ac_header_preproc" >&6; }
13883
13884 # So?  What about this header?
13885 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13886   yes:no: )
13887     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13888 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13889     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13890 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13891     ac_header_preproc=yes
13892     ;;
13893   no:yes:* )
13894     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13895 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13896     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13897 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13898     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13899 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13900     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13901 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13902     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13903 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13904     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13905 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13906     ( cat <<\_ASBOX
13907 ## ---------------------------------------- ##
13908 ## Report this to pgsql-bugs@postgresql.org ##
13909 ## ---------------------------------------- ##
13910 _ASBOX
13911      ) | sed "s/^/$as_me: WARNING:     /" >&2
13912     ;;
13913 esac
13914 { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13915 $as_echo_n "checking for libxml/parser.h... " >&6; }
13916 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13917   $as_echo_n "(cached) " >&6
13918 else
13919   ac_cv_header_libxml_parser_h=$ac_header_preproc
13920 fi
13921 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13922 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13923
13924 fi
13925 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13926   :
13927 else
13928   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13929 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13930    { (exit 1); exit 1; }; }
13931 fi
13932
13933
13934 fi
13935
13936 if test "$with_libxslt" = yes ; then
13937   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13938   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13939 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13940 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13941   $as_echo_n "(cached) " >&6
13942 fi
13943 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13944 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13945 else
13946   # Is the header compilable?
13947 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13948 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13949 cat >conftest.$ac_ext <<_ACEOF
13950 /* confdefs.h.  */
13951 _ACEOF
13952 cat confdefs.h >>conftest.$ac_ext
13953 cat >>conftest.$ac_ext <<_ACEOF
13954 /* end confdefs.h.  */
13955 $ac_includes_default
13956 #include <libxslt/xslt.h>
13957 _ACEOF
13958 rm -f conftest.$ac_objext
13959 if { (ac_try="$ac_compile"
13960 case "(($ac_try" in
13961   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13962   *) ac_try_echo=$ac_try;;
13963 esac
13964 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13965 $as_echo "$ac_try_echo") >&5
13966   (eval "$ac_compile") 2>conftest.er1
13967   ac_status=$?
13968   grep -v '^ *+' conftest.er1 >conftest.err
13969   rm -f conftest.er1
13970   cat conftest.err >&5
13971   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13972   (exit $ac_status); } && {
13973          test -z "$ac_c_werror_flag" ||
13974          test ! -s conftest.err
13975        } && test -s conftest.$ac_objext; then
13976   ac_header_compiler=yes
13977 else
13978   $as_echo "$as_me: failed program was:" >&5
13979 sed 's/^/| /' conftest.$ac_ext >&5
13980
13981         ac_header_compiler=no
13982 fi
13983
13984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13985 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13986 $as_echo "$ac_header_compiler" >&6; }
13987
13988 # Is the header present?
13989 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13990 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13991 cat >conftest.$ac_ext <<_ACEOF
13992 /* confdefs.h.  */
13993 _ACEOF
13994 cat confdefs.h >>conftest.$ac_ext
13995 cat >>conftest.$ac_ext <<_ACEOF
13996 /* end confdefs.h.  */
13997 #include <libxslt/xslt.h>
13998 _ACEOF
13999 if { (ac_try="$ac_cpp conftest.$ac_ext"
14000 case "(($ac_try" in
14001   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14002   *) ac_try_echo=$ac_try;;
14003 esac
14004 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14005 $as_echo "$ac_try_echo") >&5
14006   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14007   ac_status=$?
14008   grep -v '^ *+' conftest.er1 >conftest.err
14009   rm -f conftest.er1
14010   cat conftest.err >&5
14011   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14012   (exit $ac_status); } >/dev/null && {
14013          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14014          test ! -s conftest.err
14015        }; then
14016   ac_header_preproc=yes
14017 else
14018   $as_echo "$as_me: failed program was:" >&5
14019 sed 's/^/| /' conftest.$ac_ext >&5
14020
14021   ac_header_preproc=no
14022 fi
14023
14024 rm -f conftest.err conftest.$ac_ext
14025 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14026 $as_echo "$ac_header_preproc" >&6; }
14027
14028 # So?  What about this header?
14029 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14030   yes:no: )
14031     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
14032 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14033     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
14034 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
14035     ac_header_preproc=yes
14036     ;;
14037   no:yes:* )
14038     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
14039 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
14040     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
14041 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
14042     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
14043 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
14044     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
14045 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
14046     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
14047 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
14048     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
14049 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
14050     ( cat <<\_ASBOX
14051 ## ---------------------------------------- ##
14052 ## Report this to pgsql-bugs@postgresql.org ##
14053 ## ---------------------------------------- ##
14054 _ASBOX
14055      ) | sed "s/^/$as_me: WARNING:     /" >&2
14056     ;;
14057 esac
14058 { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
14059 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
14060 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
14061   $as_echo_n "(cached) " >&6
14062 else
14063   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
14064 fi
14065 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
14066 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
14067
14068 fi
14069 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
14070   :
14071 else
14072   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
14073 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
14074    { (exit 1); exit 1; }; }
14075 fi
14076
14077
14078 fi
14079
14080 if test "$with_ldap" = yes ; then
14081   if test "$PORTNAME" != "win32"; then
14082
14083 for ac_header in ldap.h
14084 do
14085 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14086 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14087   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14088 $as_echo_n "checking for $ac_header... " >&6; }
14089 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14090   $as_echo_n "(cached) " >&6
14091 fi
14092 ac_res=`eval 'as_val=${'$as_ac_Header'}
14093                  $as_echo "$as_val"'`
14094                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14095 $as_echo "$ac_res" >&6; }
14096 else
14097   # Is the header compilable?
14098 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14099 $as_echo_n "checking $ac_header usability... " >&6; }
14100 cat >conftest.$ac_ext <<_ACEOF
14101 /* confdefs.h.  */
14102 _ACEOF
14103 cat confdefs.h >>conftest.$ac_ext
14104 cat >>conftest.$ac_ext <<_ACEOF
14105 /* end confdefs.h.  */
14106 $ac_includes_default
14107 #include <$ac_header>
14108 _ACEOF
14109 rm -f conftest.$ac_objext
14110 if { (ac_try="$ac_compile"
14111 case "(($ac_try" in
14112   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14113   *) ac_try_echo=$ac_try;;
14114 esac
14115 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14116 $as_echo "$ac_try_echo") >&5
14117   (eval "$ac_compile") 2>conftest.er1
14118   ac_status=$?
14119   grep -v '^ *+' conftest.er1 >conftest.err
14120   rm -f conftest.er1
14121   cat conftest.err >&5
14122   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14123   (exit $ac_status); } && {
14124          test -z "$ac_c_werror_flag" ||
14125          test ! -s conftest.err
14126        } && test -s conftest.$ac_objext; then
14127   ac_header_compiler=yes
14128 else
14129   $as_echo "$as_me: failed program was:" >&5
14130 sed 's/^/| /' conftest.$ac_ext >&5
14131
14132         ac_header_compiler=no
14133 fi
14134
14135 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14136 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14137 $as_echo "$ac_header_compiler" >&6; }
14138
14139 # Is the header present?
14140 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14141 $as_echo_n "checking $ac_header presence... " >&6; }
14142 cat >conftest.$ac_ext <<_ACEOF
14143 /* confdefs.h.  */
14144 _ACEOF
14145 cat confdefs.h >>conftest.$ac_ext
14146 cat >>conftest.$ac_ext <<_ACEOF
14147 /* end confdefs.h.  */
14148 #include <$ac_header>
14149 _ACEOF
14150 if { (ac_try="$ac_cpp conftest.$ac_ext"
14151 case "(($ac_try" in
14152   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14153   *) ac_try_echo=$ac_try;;
14154 esac
14155 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14156 $as_echo "$ac_try_echo") >&5
14157   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14158   ac_status=$?
14159   grep -v '^ *+' conftest.er1 >conftest.err
14160   rm -f conftest.er1
14161   cat conftest.err >&5
14162   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14163   (exit $ac_status); } >/dev/null && {
14164          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14165          test ! -s conftest.err
14166        }; then
14167   ac_header_preproc=yes
14168 else
14169   $as_echo "$as_me: failed program was:" >&5
14170 sed 's/^/| /' conftest.$ac_ext >&5
14171
14172   ac_header_preproc=no
14173 fi
14174
14175 rm -f conftest.err conftest.$ac_ext
14176 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14177 $as_echo "$ac_header_preproc" >&6; }
14178
14179 # So?  What about this header?
14180 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14181   yes:no: )
14182     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14183 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14184     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14185 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14186     ac_header_preproc=yes
14187     ;;
14188   no:yes:* )
14189     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14190 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14191     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14192 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14193     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14194 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14195     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14196 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14197     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14198 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14199     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14200 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14201     ( cat <<\_ASBOX
14202 ## ---------------------------------------- ##
14203 ## Report this to pgsql-bugs@postgresql.org ##
14204 ## ---------------------------------------- ##
14205 _ASBOX
14206      ) | sed "s/^/$as_me: WARNING:     /" >&2
14207     ;;
14208 esac
14209 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14210 $as_echo_n "checking for $ac_header... " >&6; }
14211 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14212   $as_echo_n "(cached) " >&6
14213 else
14214   eval "$as_ac_Header=\$ac_header_preproc"
14215 fi
14216 ac_res=`eval 'as_val=${'$as_ac_Header'}
14217                  $as_echo "$as_val"'`
14218                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14219 $as_echo "$ac_res" >&6; }
14220
14221 fi
14222 as_val=`eval 'as_val=${'$as_ac_Header'}
14223                  $as_echo "$as_val"'`
14224    if test "x$as_val" = x""yes; then
14225   cat >>confdefs.h <<_ACEOF
14226 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14227 _ACEOF
14228
14229 else
14230   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
14231 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
14232    { (exit 1); exit 1; }; }
14233 fi
14234
14235 done
14236
14237   else
14238
14239 for ac_header in winldap.h
14240 do
14241 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14242 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14243 $as_echo_n "checking for $ac_header... " >&6; }
14244 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14245   $as_echo_n "(cached) " >&6
14246 else
14247   cat >conftest.$ac_ext <<_ACEOF
14248 /* confdefs.h.  */
14249 _ACEOF
14250 cat confdefs.h >>conftest.$ac_ext
14251 cat >>conftest.$ac_ext <<_ACEOF
14252 /* end confdefs.h.  */
14253 $ac_includes_default
14254 #include <windows.h>
14255
14256
14257 #include <$ac_header>
14258 _ACEOF
14259 rm -f conftest.$ac_objext
14260 if { (ac_try="$ac_compile"
14261 case "(($ac_try" in
14262   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14263   *) ac_try_echo=$ac_try;;
14264 esac
14265 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14266 $as_echo "$ac_try_echo") >&5
14267   (eval "$ac_compile") 2>conftest.er1
14268   ac_status=$?
14269   grep -v '^ *+' conftest.er1 >conftest.err
14270   rm -f conftest.er1
14271   cat conftest.err >&5
14272   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14273   (exit $ac_status); } && {
14274          test -z "$ac_c_werror_flag" ||
14275          test ! -s conftest.err
14276        } && test -s conftest.$ac_objext; then
14277   eval "$as_ac_Header=yes"
14278 else
14279   $as_echo "$as_me: failed program was:" >&5
14280 sed 's/^/| /' conftest.$ac_ext >&5
14281
14282         eval "$as_ac_Header=no"
14283 fi
14284
14285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14286 fi
14287 ac_res=`eval 'as_val=${'$as_ac_Header'}
14288                  $as_echo "$as_val"'`
14289                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14290 $as_echo "$ac_res" >&6; }
14291 as_val=`eval 'as_val=${'$as_ac_Header'}
14292                  $as_echo "$as_val"'`
14293    if test "x$as_val" = x""yes; then
14294   cat >>confdefs.h <<_ACEOF
14295 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14296 _ACEOF
14297
14298 else
14299   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
14300 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
14301    { (exit 1); exit 1; }; }
14302 fi
14303
14304 done
14305
14306   fi
14307 fi
14308
14309 if test "$with_bonjour" = yes ; then
14310   if test "${ac_cv_header_dns_sd_h+set}" = set; then
14311   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
14312 $as_echo_n "checking for dns_sd.h... " >&6; }
14313 if test "${ac_cv_header_dns_sd_h+set}" = set; then
14314   $as_echo_n "(cached) " >&6
14315 fi
14316 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
14317 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
14318 else
14319   # Is the header compilable?
14320 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
14321 $as_echo_n "checking dns_sd.h usability... " >&6; }
14322 cat >conftest.$ac_ext <<_ACEOF
14323 /* confdefs.h.  */
14324 _ACEOF
14325 cat confdefs.h >>conftest.$ac_ext
14326 cat >>conftest.$ac_ext <<_ACEOF
14327 /* end confdefs.h.  */
14328 $ac_includes_default
14329 #include <dns_sd.h>
14330 _ACEOF
14331 rm -f conftest.$ac_objext
14332 if { (ac_try="$ac_compile"
14333 case "(($ac_try" in
14334   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14335   *) ac_try_echo=$ac_try;;
14336 esac
14337 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14338 $as_echo "$ac_try_echo") >&5
14339   (eval "$ac_compile") 2>conftest.er1
14340   ac_status=$?
14341   grep -v '^ *+' conftest.er1 >conftest.err
14342   rm -f conftest.er1
14343   cat conftest.err >&5
14344   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14345   (exit $ac_status); } && {
14346          test -z "$ac_c_werror_flag" ||
14347          test ! -s conftest.err
14348        } && test -s conftest.$ac_objext; then
14349   ac_header_compiler=yes
14350 else
14351   $as_echo "$as_me: failed program was:" >&5
14352 sed 's/^/| /' conftest.$ac_ext >&5
14353
14354         ac_header_compiler=no
14355 fi
14356
14357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14358 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14359 $as_echo "$ac_header_compiler" >&6; }
14360
14361 # Is the header present?
14362 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
14363 $as_echo_n "checking dns_sd.h presence... " >&6; }
14364 cat >conftest.$ac_ext <<_ACEOF
14365 /* confdefs.h.  */
14366 _ACEOF
14367 cat confdefs.h >>conftest.$ac_ext
14368 cat >>conftest.$ac_ext <<_ACEOF
14369 /* end confdefs.h.  */
14370 #include <dns_sd.h>
14371 _ACEOF
14372 if { (ac_try="$ac_cpp conftest.$ac_ext"
14373 case "(($ac_try" in
14374   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14375   *) ac_try_echo=$ac_try;;
14376 esac
14377 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14378 $as_echo "$ac_try_echo") >&5
14379   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14380   ac_status=$?
14381   grep -v '^ *+' conftest.er1 >conftest.err
14382   rm -f conftest.er1
14383   cat conftest.err >&5
14384   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14385   (exit $ac_status); } >/dev/null && {
14386          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14387          test ! -s conftest.err
14388        }; then
14389   ac_header_preproc=yes
14390 else
14391   $as_echo "$as_me: failed program was:" >&5
14392 sed 's/^/| /' conftest.$ac_ext >&5
14393
14394   ac_header_preproc=no
14395 fi
14396
14397 rm -f conftest.err conftest.$ac_ext
14398 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14399 $as_echo "$ac_header_preproc" >&6; }
14400
14401 # So?  What about this header?
14402 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14403   yes:no: )
14404     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
14405 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14406     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
14407 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
14408     ac_header_preproc=yes
14409     ;;
14410   no:yes:* )
14411     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
14412 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
14413     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
14414 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
14415     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
14416 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
14417     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
14418 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
14419     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
14420 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
14421     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
14422 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
14423     ( cat <<\_ASBOX
14424 ## ---------------------------------------- ##
14425 ## Report this to pgsql-bugs@postgresql.org ##
14426 ## ---------------------------------------- ##
14427 _ASBOX
14428      ) | sed "s/^/$as_me: WARNING:     /" >&2
14429     ;;
14430 esac
14431 { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
14432 $as_echo_n "checking for dns_sd.h... " >&6; }
14433 if test "${ac_cv_header_dns_sd_h+set}" = set; then
14434   $as_echo_n "(cached) " >&6
14435 else
14436   ac_cv_header_dns_sd_h=$ac_header_preproc
14437 fi
14438 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
14439 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
14440
14441 fi
14442 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
14443   :
14444 else
14445   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
14446 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
14447    { (exit 1); exit 1; }; }
14448 fi
14449
14450
14451 fi
14452
14453 # for contrib/uuid-ossp
14454 if test "$with_ossp_uuid" = yes ; then
14455
14456 for ac_header in ossp/uuid.h
14457 do
14458 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14459 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14460   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14461 $as_echo_n "checking for $ac_header... " >&6; }
14462 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14463   $as_echo_n "(cached) " >&6
14464 fi
14465 ac_res=`eval 'as_val=${'$as_ac_Header'}
14466                  $as_echo "$as_val"'`
14467                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14468 $as_echo "$ac_res" >&6; }
14469 else
14470   # Is the header compilable?
14471 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14472 $as_echo_n "checking $ac_header usability... " >&6; }
14473 cat >conftest.$ac_ext <<_ACEOF
14474 /* confdefs.h.  */
14475 _ACEOF
14476 cat confdefs.h >>conftest.$ac_ext
14477 cat >>conftest.$ac_ext <<_ACEOF
14478 /* end confdefs.h.  */
14479 $ac_includes_default
14480 #include <$ac_header>
14481 _ACEOF
14482 rm -f conftest.$ac_objext
14483 if { (ac_try="$ac_compile"
14484 case "(($ac_try" in
14485   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14486   *) ac_try_echo=$ac_try;;
14487 esac
14488 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14489 $as_echo "$ac_try_echo") >&5
14490   (eval "$ac_compile") 2>conftest.er1
14491   ac_status=$?
14492   grep -v '^ *+' conftest.er1 >conftest.err
14493   rm -f conftest.er1
14494   cat conftest.err >&5
14495   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14496   (exit $ac_status); } && {
14497          test -z "$ac_c_werror_flag" ||
14498          test ! -s conftest.err
14499        } && test -s conftest.$ac_objext; then
14500   ac_header_compiler=yes
14501 else
14502   $as_echo "$as_me: failed program was:" >&5
14503 sed 's/^/| /' conftest.$ac_ext >&5
14504
14505         ac_header_compiler=no
14506 fi
14507
14508 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14509 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14510 $as_echo "$ac_header_compiler" >&6; }
14511
14512 # Is the header present?
14513 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14514 $as_echo_n "checking $ac_header presence... " >&6; }
14515 cat >conftest.$ac_ext <<_ACEOF
14516 /* confdefs.h.  */
14517 _ACEOF
14518 cat confdefs.h >>conftest.$ac_ext
14519 cat >>conftest.$ac_ext <<_ACEOF
14520 /* end confdefs.h.  */
14521 #include <$ac_header>
14522 _ACEOF
14523 if { (ac_try="$ac_cpp conftest.$ac_ext"
14524 case "(($ac_try" in
14525   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14526   *) ac_try_echo=$ac_try;;
14527 esac
14528 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14529 $as_echo "$ac_try_echo") >&5
14530   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14531   ac_status=$?
14532   grep -v '^ *+' conftest.er1 >conftest.err
14533   rm -f conftest.er1
14534   cat conftest.err >&5
14535   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14536   (exit $ac_status); } >/dev/null && {
14537          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14538          test ! -s conftest.err
14539        }; then
14540   ac_header_preproc=yes
14541 else
14542   $as_echo "$as_me: failed program was:" >&5
14543 sed 's/^/| /' conftest.$ac_ext >&5
14544
14545   ac_header_preproc=no
14546 fi
14547
14548 rm -f conftest.err conftest.$ac_ext
14549 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14550 $as_echo "$ac_header_preproc" >&6; }
14551
14552 # So?  What about this header?
14553 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14554   yes:no: )
14555     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14556 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14557     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14558 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14559     ac_header_preproc=yes
14560     ;;
14561   no:yes:* )
14562     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14563 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14564     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14565 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14566     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14567 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14568     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14569 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14570     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14571 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14572     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14573 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14574     ( cat <<\_ASBOX
14575 ## ---------------------------------------- ##
14576 ## Report this to pgsql-bugs@postgresql.org ##
14577 ## ---------------------------------------- ##
14578 _ASBOX
14579      ) | sed "s/^/$as_me: WARNING:     /" >&2
14580     ;;
14581 esac
14582 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14583 $as_echo_n "checking for $ac_header... " >&6; }
14584 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14585   $as_echo_n "(cached) " >&6
14586 else
14587   eval "$as_ac_Header=\$ac_header_preproc"
14588 fi
14589 ac_res=`eval 'as_val=${'$as_ac_Header'}
14590                  $as_echo "$as_val"'`
14591                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14592 $as_echo "$ac_res" >&6; }
14593
14594 fi
14595 as_val=`eval 'as_val=${'$as_ac_Header'}
14596                  $as_echo "$as_val"'`
14597    if test "x$as_val" = x""yes; then
14598   cat >>confdefs.h <<_ACEOF
14599 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14600 _ACEOF
14601
14602 else
14603
14604
14605 for ac_header in uuid.h
14606 do
14607 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14608 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14609   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14610 $as_echo_n "checking for $ac_header... " >&6; }
14611 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14612   $as_echo_n "(cached) " >&6
14613 fi
14614 ac_res=`eval 'as_val=${'$as_ac_Header'}
14615                  $as_echo "$as_val"'`
14616                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14617 $as_echo "$ac_res" >&6; }
14618 else
14619   # Is the header compilable?
14620 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14621 $as_echo_n "checking $ac_header usability... " >&6; }
14622 cat >conftest.$ac_ext <<_ACEOF
14623 /* confdefs.h.  */
14624 _ACEOF
14625 cat confdefs.h >>conftest.$ac_ext
14626 cat >>conftest.$ac_ext <<_ACEOF
14627 /* end confdefs.h.  */
14628 $ac_includes_default
14629 #include <$ac_header>
14630 _ACEOF
14631 rm -f conftest.$ac_objext
14632 if { (ac_try="$ac_compile"
14633 case "(($ac_try" in
14634   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14635   *) ac_try_echo=$ac_try;;
14636 esac
14637 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14638 $as_echo "$ac_try_echo") >&5
14639   (eval "$ac_compile") 2>conftest.er1
14640   ac_status=$?
14641   grep -v '^ *+' conftest.er1 >conftest.err
14642   rm -f conftest.er1
14643   cat conftest.err >&5
14644   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14645   (exit $ac_status); } && {
14646          test -z "$ac_c_werror_flag" ||
14647          test ! -s conftest.err
14648        } && test -s conftest.$ac_objext; then
14649   ac_header_compiler=yes
14650 else
14651   $as_echo "$as_me: failed program was:" >&5
14652 sed 's/^/| /' conftest.$ac_ext >&5
14653
14654         ac_header_compiler=no
14655 fi
14656
14657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14658 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14659 $as_echo "$ac_header_compiler" >&6; }
14660
14661 # Is the header present?
14662 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14663 $as_echo_n "checking $ac_header presence... " >&6; }
14664 cat >conftest.$ac_ext <<_ACEOF
14665 /* confdefs.h.  */
14666 _ACEOF
14667 cat confdefs.h >>conftest.$ac_ext
14668 cat >>conftest.$ac_ext <<_ACEOF
14669 /* end confdefs.h.  */
14670 #include <$ac_header>
14671 _ACEOF
14672 if { (ac_try="$ac_cpp conftest.$ac_ext"
14673 case "(($ac_try" in
14674   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14675   *) ac_try_echo=$ac_try;;
14676 esac
14677 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14678 $as_echo "$ac_try_echo") >&5
14679   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14680   ac_status=$?
14681   grep -v '^ *+' conftest.er1 >conftest.err
14682   rm -f conftest.er1
14683   cat conftest.err >&5
14684   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14685   (exit $ac_status); } >/dev/null && {
14686          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14687          test ! -s conftest.err
14688        }; then
14689   ac_header_preproc=yes
14690 else
14691   $as_echo "$as_me: failed program was:" >&5
14692 sed 's/^/| /' conftest.$ac_ext >&5
14693
14694   ac_header_preproc=no
14695 fi
14696
14697 rm -f conftest.err conftest.$ac_ext
14698 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14699 $as_echo "$ac_header_preproc" >&6; }
14700
14701 # So?  What about this header?
14702 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14703   yes:no: )
14704     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14705 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14706     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14707 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14708     ac_header_preproc=yes
14709     ;;
14710   no:yes:* )
14711     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14712 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14713     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14714 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14715     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14716 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14717     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14718 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14719     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14720 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14721     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14722 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14723     ( cat <<\_ASBOX
14724 ## ---------------------------------------- ##
14725 ## Report this to pgsql-bugs@postgresql.org ##
14726 ## ---------------------------------------- ##
14727 _ASBOX
14728      ) | sed "s/^/$as_me: WARNING:     /" >&2
14729     ;;
14730 esac
14731 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14732 $as_echo_n "checking for $ac_header... " >&6; }
14733 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14734   $as_echo_n "(cached) " >&6
14735 else
14736   eval "$as_ac_Header=\$ac_header_preproc"
14737 fi
14738 ac_res=`eval 'as_val=${'$as_ac_Header'}
14739                  $as_echo "$as_val"'`
14740                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14741 $as_echo "$ac_res" >&6; }
14742
14743 fi
14744 as_val=`eval 'as_val=${'$as_ac_Header'}
14745                  $as_echo "$as_val"'`
14746    if test "x$as_val" = x""yes; then
14747   cat >>confdefs.h <<_ACEOF
14748 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14749 _ACEOF
14750
14751 else
14752   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
14753 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
14754    { (exit 1); exit 1; }; }
14755 fi
14756
14757 done
14758
14759 fi
14760
14761 done
14762
14763 fi
14764
14765 if test "$PORTNAME" = "win32" ; then
14766
14767 for ac_header in crtdefs.h
14768 do
14769 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14770 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14771   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14772 $as_echo_n "checking for $ac_header... " >&6; }
14773 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14774   $as_echo_n "(cached) " >&6
14775 fi
14776 ac_res=`eval 'as_val=${'$as_ac_Header'}
14777                  $as_echo "$as_val"'`
14778                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14779 $as_echo "$ac_res" >&6; }
14780 else
14781   # Is the header compilable?
14782 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14783 $as_echo_n "checking $ac_header usability... " >&6; }
14784 cat >conftest.$ac_ext <<_ACEOF
14785 /* confdefs.h.  */
14786 _ACEOF
14787 cat confdefs.h >>conftest.$ac_ext
14788 cat >>conftest.$ac_ext <<_ACEOF
14789 /* end confdefs.h.  */
14790 $ac_includes_default
14791 #include <$ac_header>
14792 _ACEOF
14793 rm -f conftest.$ac_objext
14794 if { (ac_try="$ac_compile"
14795 case "(($ac_try" in
14796   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14797   *) ac_try_echo=$ac_try;;
14798 esac
14799 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14800 $as_echo "$ac_try_echo") >&5
14801   (eval "$ac_compile") 2>conftest.er1
14802   ac_status=$?
14803   grep -v '^ *+' conftest.er1 >conftest.err
14804   rm -f conftest.er1
14805   cat conftest.err >&5
14806   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14807   (exit $ac_status); } && {
14808          test -z "$ac_c_werror_flag" ||
14809          test ! -s conftest.err
14810        } && test -s conftest.$ac_objext; then
14811   ac_header_compiler=yes
14812 else
14813   $as_echo "$as_me: failed program was:" >&5
14814 sed 's/^/| /' conftest.$ac_ext >&5
14815
14816         ac_header_compiler=no
14817 fi
14818
14819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14820 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14821 $as_echo "$ac_header_compiler" >&6; }
14822
14823 # Is the header present?
14824 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14825 $as_echo_n "checking $ac_header presence... " >&6; }
14826 cat >conftest.$ac_ext <<_ACEOF
14827 /* confdefs.h.  */
14828 _ACEOF
14829 cat confdefs.h >>conftest.$ac_ext
14830 cat >>conftest.$ac_ext <<_ACEOF
14831 /* end confdefs.h.  */
14832 #include <$ac_header>
14833 _ACEOF
14834 if { (ac_try="$ac_cpp conftest.$ac_ext"
14835 case "(($ac_try" in
14836   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14837   *) ac_try_echo=$ac_try;;
14838 esac
14839 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14840 $as_echo "$ac_try_echo") >&5
14841   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14842   ac_status=$?
14843   grep -v '^ *+' conftest.er1 >conftest.err
14844   rm -f conftest.er1
14845   cat conftest.err >&5
14846   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14847   (exit $ac_status); } >/dev/null && {
14848          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14849          test ! -s conftest.err
14850        }; then
14851   ac_header_preproc=yes
14852 else
14853   $as_echo "$as_me: failed program was:" >&5
14854 sed 's/^/| /' conftest.$ac_ext >&5
14855
14856   ac_header_preproc=no
14857 fi
14858
14859 rm -f conftest.err conftest.$ac_ext
14860 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14861 $as_echo "$ac_header_preproc" >&6; }
14862
14863 # So?  What about this header?
14864 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14865   yes:no: )
14866     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14867 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14868     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14869 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14870     ac_header_preproc=yes
14871     ;;
14872   no:yes:* )
14873     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14874 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14875     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14876 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14877     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14878 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14879     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14880 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14881     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14882 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14883     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14884 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14885     ( cat <<\_ASBOX
14886 ## ---------------------------------------- ##
14887 ## Report this to pgsql-bugs@postgresql.org ##
14888 ## ---------------------------------------- ##
14889 _ASBOX
14890      ) | sed "s/^/$as_me: WARNING:     /" >&2
14891     ;;
14892 esac
14893 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14894 $as_echo_n "checking for $ac_header... " >&6; }
14895 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14896   $as_echo_n "(cached) " >&6
14897 else
14898   eval "$as_ac_Header=\$ac_header_preproc"
14899 fi
14900 ac_res=`eval 'as_val=${'$as_ac_Header'}
14901                  $as_echo "$as_val"'`
14902                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14903 $as_echo "$ac_res" >&6; }
14904
14905 fi
14906 as_val=`eval 'as_val=${'$as_ac_Header'}
14907                  $as_echo "$as_val"'`
14908    if test "x$as_val" = x""yes; then
14909   cat >>confdefs.h <<_ACEOF
14910 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14911 _ACEOF
14912
14913 fi
14914
14915 done
14916
14917 fi
14918
14919 ##
14920 ## Types, structures, compiler characteristics
14921 ##
14922
14923
14924  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
14925 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
14926 if test "${ac_cv_c_bigendian+set}" = set; then
14927   $as_echo_n "(cached) " >&6
14928 else
14929   ac_cv_c_bigendian=unknown
14930     # See if we're dealing with a universal compiler.
14931     cat >conftest.$ac_ext <<_ACEOF
14932 /* confdefs.h.  */
14933 _ACEOF
14934 cat confdefs.h >>conftest.$ac_ext
14935 cat >>conftest.$ac_ext <<_ACEOF
14936 /* end confdefs.h.  */
14937 #ifndef __APPLE_CC__
14938                not a universal capable compiler
14939              #endif
14940              typedef int dummy;
14941
14942 _ACEOF
14943 rm -f conftest.$ac_objext
14944 if { (ac_try="$ac_compile"
14945 case "(($ac_try" in
14946   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14947   *) ac_try_echo=$ac_try;;
14948 esac
14949 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14950 $as_echo "$ac_try_echo") >&5
14951   (eval "$ac_compile") 2>conftest.er1
14952   ac_status=$?
14953   grep -v '^ *+' conftest.er1 >conftest.err
14954   rm -f conftest.er1
14955   cat conftest.err >&5
14956   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14957   (exit $ac_status); } && {
14958          test -z "$ac_c_werror_flag" ||
14959          test ! -s conftest.err
14960        } && test -s conftest.$ac_objext; then
14961
14962         # Check for potential -arch flags.  It is not universal unless
14963         # there are some -arch flags.  Note that *ppc* also matches
14964         # ppc64.  This check is also rather less than ideal.
14965         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
14966           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
14967         esac
14968 else
14969   $as_echo "$as_me: failed program was:" >&5
14970 sed 's/^/| /' conftest.$ac_ext >&5
14971
14972
14973 fi
14974
14975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14976     if test $ac_cv_c_bigendian = unknown; then
14977       # See if sys/param.h defines the BYTE_ORDER macro.
14978       cat >conftest.$ac_ext <<_ACEOF
14979 /* confdefs.h.  */
14980 _ACEOF
14981 cat confdefs.h >>conftest.$ac_ext
14982 cat >>conftest.$ac_ext <<_ACEOF
14983 /* end confdefs.h.  */
14984 #include <sys/types.h>
14985              #include <sys/param.h>
14986
14987 int
14988 main ()
14989 {
14990 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14991                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14992                      && LITTLE_ENDIAN)
14993               bogus endian macros
14994              #endif
14995
14996   ;
14997   return 0;
14998 }
14999 _ACEOF
15000 rm -f conftest.$ac_objext
15001 if { (ac_try="$ac_compile"
15002 case "(($ac_try" in
15003   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15004   *) ac_try_echo=$ac_try;;
15005 esac
15006 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15007 $as_echo "$ac_try_echo") >&5
15008   (eval "$ac_compile") 2>conftest.er1
15009   ac_status=$?
15010   grep -v '^ *+' conftest.er1 >conftest.err
15011   rm -f conftest.er1
15012   cat conftest.err >&5
15013   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15014   (exit $ac_status); } && {
15015          test -z "$ac_c_werror_flag" ||
15016          test ! -s conftest.err
15017        } && test -s conftest.$ac_objext; then
15018   # It does; now see whether it defined to BIG_ENDIAN or not.
15019          cat >conftest.$ac_ext <<_ACEOF
15020 /* confdefs.h.  */
15021 _ACEOF
15022 cat confdefs.h >>conftest.$ac_ext
15023 cat >>conftest.$ac_ext <<_ACEOF
15024 /* end confdefs.h.  */
15025 #include <sys/types.h>
15026                 #include <sys/param.h>
15027
15028 int
15029 main ()
15030 {
15031 #if BYTE_ORDER != BIG_ENDIAN
15032                  not big endian
15033                 #endif
15034
15035   ;
15036   return 0;
15037 }
15038 _ACEOF
15039 rm -f conftest.$ac_objext
15040 if { (ac_try="$ac_compile"
15041 case "(($ac_try" in
15042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15043   *) ac_try_echo=$ac_try;;
15044 esac
15045 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15046 $as_echo "$ac_try_echo") >&5
15047   (eval "$ac_compile") 2>conftest.er1
15048   ac_status=$?
15049   grep -v '^ *+' conftest.er1 >conftest.err
15050   rm -f conftest.er1
15051   cat conftest.err >&5
15052   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15053   (exit $ac_status); } && {
15054          test -z "$ac_c_werror_flag" ||
15055          test ! -s conftest.err
15056        } && test -s conftest.$ac_objext; then
15057   ac_cv_c_bigendian=yes
15058 else
15059   $as_echo "$as_me: failed program was:" >&5
15060 sed 's/^/| /' conftest.$ac_ext >&5
15061
15062         ac_cv_c_bigendian=no
15063 fi
15064
15065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15066 else
15067   $as_echo "$as_me: failed program was:" >&5
15068 sed 's/^/| /' conftest.$ac_ext >&5
15069
15070
15071 fi
15072
15073 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15074     fi
15075     if test $ac_cv_c_bigendian = unknown; then
15076       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
15077       cat >conftest.$ac_ext <<_ACEOF
15078 /* confdefs.h.  */
15079 _ACEOF
15080 cat confdefs.h >>conftest.$ac_ext
15081 cat >>conftest.$ac_ext <<_ACEOF
15082 /* end confdefs.h.  */
15083 #include <limits.h>
15084
15085 int
15086 main ()
15087 {
15088 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
15089               bogus endian macros
15090              #endif
15091
15092   ;
15093   return 0;
15094 }
15095 _ACEOF
15096 rm -f conftest.$ac_objext
15097 if { (ac_try="$ac_compile"
15098 case "(($ac_try" in
15099   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15100   *) ac_try_echo=$ac_try;;
15101 esac
15102 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15103 $as_echo "$ac_try_echo") >&5
15104   (eval "$ac_compile") 2>conftest.er1
15105   ac_status=$?
15106   grep -v '^ *+' conftest.er1 >conftest.err
15107   rm -f conftest.er1
15108   cat conftest.err >&5
15109   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15110   (exit $ac_status); } && {
15111          test -z "$ac_c_werror_flag" ||
15112          test ! -s conftest.err
15113        } && test -s conftest.$ac_objext; then
15114   # It does; now see whether it defined to _BIG_ENDIAN or not.
15115          cat >conftest.$ac_ext <<_ACEOF
15116 /* confdefs.h.  */
15117 _ACEOF
15118 cat confdefs.h >>conftest.$ac_ext
15119 cat >>conftest.$ac_ext <<_ACEOF
15120 /* end confdefs.h.  */
15121 #include <limits.h>
15122
15123 int
15124 main ()
15125 {
15126 #ifndef _BIG_ENDIAN
15127                  not big endian
15128                 #endif
15129
15130   ;
15131   return 0;
15132 }
15133 _ACEOF
15134 rm -f conftest.$ac_objext
15135 if { (ac_try="$ac_compile"
15136 case "(($ac_try" in
15137   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15138   *) ac_try_echo=$ac_try;;
15139 esac
15140 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15141 $as_echo "$ac_try_echo") >&5
15142   (eval "$ac_compile") 2>conftest.er1
15143   ac_status=$?
15144   grep -v '^ *+' conftest.er1 >conftest.err
15145   rm -f conftest.er1
15146   cat conftest.err >&5
15147   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15148   (exit $ac_status); } && {
15149          test -z "$ac_c_werror_flag" ||
15150          test ! -s conftest.err
15151        } && test -s conftest.$ac_objext; then
15152   ac_cv_c_bigendian=yes
15153 else
15154   $as_echo "$as_me: failed program was:" >&5
15155 sed 's/^/| /' conftest.$ac_ext >&5
15156
15157         ac_cv_c_bigendian=no
15158 fi
15159
15160 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15161 else
15162   $as_echo "$as_me: failed program was:" >&5
15163 sed 's/^/| /' conftest.$ac_ext >&5
15164
15165
15166 fi
15167
15168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15169     fi
15170     if test $ac_cv_c_bigendian = unknown; then
15171       # Compile a test program.
15172       if test "$cross_compiling" = yes; then
15173   # Try to guess by grepping values from an object file.
15174          cat >conftest.$ac_ext <<_ACEOF
15175 /* confdefs.h.  */
15176 _ACEOF
15177 cat confdefs.h >>conftest.$ac_ext
15178 cat >>conftest.$ac_ext <<_ACEOF
15179 /* end confdefs.h.  */
15180 short int ascii_mm[] =
15181                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
15182                 short int ascii_ii[] =
15183                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
15184                 int use_ascii (int i) {
15185                   return ascii_mm[i] + ascii_ii[i];
15186                 }
15187                 short int ebcdic_ii[] =
15188                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
15189                 short int ebcdic_mm[] =
15190                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
15191                 int use_ebcdic (int i) {
15192                   return ebcdic_mm[i] + ebcdic_ii[i];
15193                 }
15194                 extern int foo;
15195
15196 int
15197 main ()
15198 {
15199 return use_ascii (foo) == use_ebcdic (foo);
15200   ;
15201   return 0;
15202 }
15203 _ACEOF
15204 rm -f conftest.$ac_objext
15205 if { (ac_try="$ac_compile"
15206 case "(($ac_try" in
15207   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15208   *) ac_try_echo=$ac_try;;
15209 esac
15210 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15211 $as_echo "$ac_try_echo") >&5
15212   (eval "$ac_compile") 2>conftest.er1
15213   ac_status=$?
15214   grep -v '^ *+' conftest.er1 >conftest.err
15215   rm -f conftest.er1
15216   cat conftest.err >&5
15217   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15218   (exit $ac_status); } && {
15219          test -z "$ac_c_werror_flag" ||
15220          test ! -s conftest.err
15221        } && test -s conftest.$ac_objext; then
15222   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
15223               ac_cv_c_bigendian=yes
15224             fi
15225             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
15226               if test "$ac_cv_c_bigendian" = unknown; then
15227                 ac_cv_c_bigendian=no
15228               else
15229                 # finding both strings is unlikely to happen, but who knows?
15230                 ac_cv_c_bigendian=unknown
15231               fi
15232             fi
15233 else
15234   $as_echo "$as_me: failed program was:" >&5
15235 sed 's/^/| /' conftest.$ac_ext >&5
15236
15237
15238 fi
15239
15240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15241 else
15242   cat >conftest.$ac_ext <<_ACEOF
15243 /* confdefs.h.  */
15244 _ACEOF
15245 cat confdefs.h >>conftest.$ac_ext
15246 cat >>conftest.$ac_ext <<_ACEOF
15247 /* end confdefs.h.  */
15248 $ac_includes_default
15249 int
15250 main ()
15251 {
15252
15253              /* Are we little or big endian?  From Harbison&Steele.  */
15254              union
15255              {
15256                long int l;
15257                char c[sizeof (long int)];
15258              } u;
15259              u.l = 1;
15260              return u.c[sizeof (long int) - 1] == 1;
15261
15262   ;
15263   return 0;
15264 }
15265 _ACEOF
15266 rm -f conftest$ac_exeext
15267 if { (ac_try="$ac_link"
15268 case "(($ac_try" in
15269   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15270   *) ac_try_echo=$ac_try;;
15271 esac
15272 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15273 $as_echo "$ac_try_echo") >&5
15274   (eval "$ac_link") 2>&5
15275   ac_status=$?
15276   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15277   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15278   { (case "(($ac_try" in
15279   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15280   *) ac_try_echo=$ac_try;;
15281 esac
15282 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15283 $as_echo "$ac_try_echo") >&5
15284   (eval "$ac_try") 2>&5
15285   ac_status=$?
15286   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15287   (exit $ac_status); }; }; then
15288   ac_cv_c_bigendian=no
15289 else
15290   $as_echo "$as_me: program exited with status $ac_status" >&5
15291 $as_echo "$as_me: failed program was:" >&5
15292 sed 's/^/| /' conftest.$ac_ext >&5
15293
15294 ( exit $ac_status )
15295 ac_cv_c_bigendian=yes
15296 fi
15297 rm -rf conftest.dSYM
15298 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15299 fi
15300
15301
15302     fi
15303 fi
15304 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
15305 $as_echo "$ac_cv_c_bigendian" >&6; }
15306  case $ac_cv_c_bigendian in #(
15307    yes)
15308      cat >>confdefs.h <<\_ACEOF
15309 #define WORDS_BIGENDIAN 1
15310 _ACEOF
15311 ;; #(
15312    no)
15313       ;; #(
15314    universal)
15315
15316 cat >>confdefs.h <<\_ACEOF
15317 #define AC_APPLE_UNIVERSAL_BUILD 1
15318 _ACEOF
15319
15320      ;; #(
15321    *)
15322      { { $as_echo "$as_me:$LINENO: error: unknown endianness
15323  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
15324 $as_echo "$as_me: error: unknown endianness
15325  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
15326    { (exit 1); exit 1; }; } ;;
15327  esac
15328
15329 { $as_echo "$as_me:$LINENO: checking for inline" >&5
15330 $as_echo_n "checking for inline... " >&6; }
15331 if test "${ac_cv_c_inline+set}" = set; then
15332   $as_echo_n "(cached) " >&6
15333 else
15334   ac_cv_c_inline=no
15335 for ac_kw in inline __inline__ __inline; do
15336   cat >conftest.$ac_ext <<_ACEOF
15337 /* confdefs.h.  */
15338 _ACEOF
15339 cat confdefs.h >>conftest.$ac_ext
15340 cat >>conftest.$ac_ext <<_ACEOF
15341 /* end confdefs.h.  */
15342 #ifndef __cplusplus
15343 typedef int foo_t;
15344 static $ac_kw foo_t static_foo () {return 0; }
15345 $ac_kw foo_t foo () {return 0; }
15346 #endif
15347
15348 _ACEOF
15349 rm -f conftest.$ac_objext
15350 if { (ac_try="$ac_compile"
15351 case "(($ac_try" in
15352   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15353   *) ac_try_echo=$ac_try;;
15354 esac
15355 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15356 $as_echo "$ac_try_echo") >&5
15357   (eval "$ac_compile") 2>conftest.er1
15358   ac_status=$?
15359   grep -v '^ *+' conftest.er1 >conftest.err
15360   rm -f conftest.er1
15361   cat conftest.err >&5
15362   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15363   (exit $ac_status); } && {
15364          test -z "$ac_c_werror_flag" ||
15365          test ! -s conftest.err
15366        } && test -s conftest.$ac_objext; then
15367   ac_cv_c_inline=$ac_kw
15368 else
15369   $as_echo "$as_me: failed program was:" >&5
15370 sed 's/^/| /' conftest.$ac_ext >&5
15371
15372
15373 fi
15374
15375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15376   test "$ac_cv_c_inline" != no && break
15377 done
15378
15379 fi
15380 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
15381 $as_echo "$ac_cv_c_inline" >&6; }
15382
15383
15384 case $ac_cv_c_inline in
15385   inline | yes) ;;
15386   *)
15387     case $ac_cv_c_inline in
15388       no) ac_val=;;
15389       *) ac_val=$ac_cv_c_inline;;
15390     esac
15391     cat >>confdefs.h <<_ACEOF
15392 #ifndef __cplusplus
15393 #define inline $ac_val
15394 #endif
15395 _ACEOF
15396     ;;
15397 esac
15398
15399 { $as_echo "$as_me:$LINENO: checking for quiet inline (no complaint if unreferenced)" >&5
15400 $as_echo_n "checking for quiet inline (no complaint if unreferenced)... " >&6; }
15401 if test "${pgac_cv_c_inline_quietly+set}" = set; then
15402   $as_echo_n "(cached) " >&6
15403 else
15404   pgac_cv_c_inline_quietly=no
15405   if test "$ac_cv_c_inline" != no; then
15406     pgac_c_inline_save_werror=$ac_c_werror_flag
15407     ac_c_werror_flag=yes
15408     cat >conftest.$ac_ext <<_ACEOF
15409 /* confdefs.h.  */
15410 _ACEOF
15411 cat confdefs.h >>conftest.$ac_ext
15412 cat >>conftest.$ac_ext <<_ACEOF
15413 /* end confdefs.h.  */
15414 static inline int fun () {return 0;}
15415 int
15416 main ()
15417 {
15418
15419   ;
15420   return 0;
15421 }
15422 _ACEOF
15423 rm -f conftest.$ac_objext conftest$ac_exeext
15424 if { (ac_try="$ac_link"
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_link") 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_exeext && {
15441          test "$cross_compiling" = yes ||
15442          $as_test_x conftest$ac_exeext
15443        }; then
15444   pgac_cv_c_inline_quietly=yes
15445 else
15446   $as_echo "$as_me: failed program was:" >&5
15447 sed 's/^/| /' conftest.$ac_ext >&5
15448
15449
15450 fi
15451
15452 rm -rf conftest.dSYM
15453 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15454       conftest$ac_exeext conftest.$ac_ext
15455     ac_c_werror_flag=$pgac_c_inline_save_werror
15456   fi
15457 fi
15458 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_inline_quietly" >&5
15459 $as_echo "$pgac_cv_c_inline_quietly" >&6; }
15460 if test "$pgac_cv_c_inline_quietly" != no; then
15461
15462 cat >>confdefs.h <<_ACEOF
15463 #define PG_USE_INLINE 1
15464 _ACEOF
15465
15466 fi
15467
15468
15469   { $as_echo "$as_me:$LINENO: checking for flexible array members" >&5
15470 $as_echo_n "checking for flexible array members... " >&6; }
15471 if test "${ac_cv_c_flexmember+set}" = set; then
15472   $as_echo_n "(cached) " >&6
15473 else
15474   cat >conftest.$ac_ext <<_ACEOF
15475 /* confdefs.h.  */
15476 _ACEOF
15477 cat confdefs.h >>conftest.$ac_ext
15478 cat >>conftest.$ac_ext <<_ACEOF
15479 /* end confdefs.h.  */
15480 #include <stdlib.h>
15481             #include <stdio.h>
15482             #include <stddef.h>
15483             struct s { int n; double d[]; };
15484 int
15485 main ()
15486 {
15487 int m = getchar ();
15488             struct s *p = malloc (offsetof (struct s, d)
15489                                   + m * sizeof (double));
15490             p->d[0] = 0.0;
15491             return p->d != (double *) NULL;
15492   ;
15493   return 0;
15494 }
15495 _ACEOF
15496 rm -f conftest.$ac_objext
15497 if { (ac_try="$ac_compile"
15498 case "(($ac_try" in
15499   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15500   *) ac_try_echo=$ac_try;;
15501 esac
15502 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15503 $as_echo "$ac_try_echo") >&5
15504   (eval "$ac_compile") 2>conftest.er1
15505   ac_status=$?
15506   grep -v '^ *+' conftest.er1 >conftest.err
15507   rm -f conftest.er1
15508   cat conftest.err >&5
15509   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15510   (exit $ac_status); } && {
15511          test -z "$ac_c_werror_flag" ||
15512          test ! -s conftest.err
15513        } && test -s conftest.$ac_objext; then
15514   ac_cv_c_flexmember=yes
15515 else
15516   $as_echo "$as_me: failed program was:" >&5
15517 sed 's/^/| /' conftest.$ac_ext >&5
15518
15519         ac_cv_c_flexmember=no
15520 fi
15521
15522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15523 fi
15524 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_flexmember" >&5
15525 $as_echo "$ac_cv_c_flexmember" >&6; }
15526   if test $ac_cv_c_flexmember = yes; then
15527
15528 cat >>confdefs.h <<\_ACEOF
15529 #define FLEXIBLE_ARRAY_MEMBER /**/
15530 _ACEOF
15531
15532   else
15533     cat >>confdefs.h <<\_ACEOF
15534 #define FLEXIBLE_ARRAY_MEMBER 1
15535 _ACEOF
15536
15537   fi
15538
15539 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
15540 $as_echo_n "checking for signed types... " >&6; }
15541 if test "${pgac_cv_c_signed+set}" = set; then
15542   $as_echo_n "(cached) " >&6
15543 else
15544   cat >conftest.$ac_ext <<_ACEOF
15545 /* confdefs.h.  */
15546 _ACEOF
15547 cat confdefs.h >>conftest.$ac_ext
15548 cat >>conftest.$ac_ext <<_ACEOF
15549 /* end confdefs.h.  */
15550
15551 int
15552 main ()
15553 {
15554 signed char c; signed short s; signed int i;
15555   ;
15556   return 0;
15557 }
15558 _ACEOF
15559 rm -f conftest.$ac_objext
15560 if { (ac_try="$ac_compile"
15561 case "(($ac_try" in
15562   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15563   *) ac_try_echo=$ac_try;;
15564 esac
15565 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15566 $as_echo "$ac_try_echo") >&5
15567   (eval "$ac_compile") 2>conftest.er1
15568   ac_status=$?
15569   grep -v '^ *+' conftest.er1 >conftest.err
15570   rm -f conftest.er1
15571   cat conftest.err >&5
15572   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15573   (exit $ac_status); } && {
15574          test -z "$ac_c_werror_flag" ||
15575          test ! -s conftest.err
15576        } && test -s conftest.$ac_objext; then
15577   pgac_cv_c_signed=yes
15578 else
15579   $as_echo "$as_me: failed program was:" >&5
15580 sed 's/^/| /' conftest.$ac_ext >&5
15581
15582         pgac_cv_c_signed=no
15583 fi
15584
15585 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15586 fi
15587 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
15588 $as_echo "$pgac_cv_c_signed" >&6; }
15589 if test x"$pgac_cv_c_signed" = xno ; then
15590
15591 cat >>confdefs.h <<\_ACEOF
15592 #define signed /**/
15593 _ACEOF
15594
15595 fi
15596 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
15597 $as_echo_n "checking for __func__... " >&6; }
15598 if test "${pgac_cv_funcname_func_support+set}" = set; then
15599   $as_echo_n "(cached) " >&6
15600 else
15601   cat >conftest.$ac_ext <<_ACEOF
15602 /* confdefs.h.  */
15603 _ACEOF
15604 cat confdefs.h >>conftest.$ac_ext
15605 cat >>conftest.$ac_ext <<_ACEOF
15606 /* end confdefs.h.  */
15607 #include <stdio.h>
15608 int
15609 main ()
15610 {
15611 printf("%s\n", __func__);
15612   ;
15613   return 0;
15614 }
15615 _ACEOF
15616 rm -f conftest.$ac_objext
15617 if { (ac_try="$ac_compile"
15618 case "(($ac_try" in
15619   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15620   *) ac_try_echo=$ac_try;;
15621 esac
15622 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15623 $as_echo "$ac_try_echo") >&5
15624   (eval "$ac_compile") 2>conftest.er1
15625   ac_status=$?
15626   grep -v '^ *+' conftest.er1 >conftest.err
15627   rm -f conftest.er1
15628   cat conftest.err >&5
15629   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15630   (exit $ac_status); } && {
15631          test -z "$ac_c_werror_flag" ||
15632          test ! -s conftest.err
15633        } && test -s conftest.$ac_objext; then
15634   pgac_cv_funcname_func_support=yes
15635 else
15636   $as_echo "$as_me: failed program was:" >&5
15637 sed 's/^/| /' conftest.$ac_ext >&5
15638
15639         pgac_cv_funcname_func_support=no
15640 fi
15641
15642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15643 fi
15644 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
15645 $as_echo "$pgac_cv_funcname_func_support" >&6; }
15646 if test x"$pgac_cv_funcname_func_support" = xyes ; then
15647
15648 cat >>confdefs.h <<\_ACEOF
15649 #define HAVE_FUNCNAME__FUNC 1
15650 _ACEOF
15651
15652 else
15653 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
15654 $as_echo_n "checking for __FUNCTION__... " >&6; }
15655 if test "${pgac_cv_funcname_function_support+set}" = set; then
15656   $as_echo_n "(cached) " >&6
15657 else
15658   cat >conftest.$ac_ext <<_ACEOF
15659 /* confdefs.h.  */
15660 _ACEOF
15661 cat confdefs.h >>conftest.$ac_ext
15662 cat >>conftest.$ac_ext <<_ACEOF
15663 /* end confdefs.h.  */
15664 #include <stdio.h>
15665 int
15666 main ()
15667 {
15668 printf("%s\n", __FUNCTION__);
15669   ;
15670   return 0;
15671 }
15672 _ACEOF
15673 rm -f conftest.$ac_objext
15674 if { (ac_try="$ac_compile"
15675 case "(($ac_try" in
15676   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15677   *) ac_try_echo=$ac_try;;
15678 esac
15679 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15680 $as_echo "$ac_try_echo") >&5
15681   (eval "$ac_compile") 2>conftest.er1
15682   ac_status=$?
15683   grep -v '^ *+' conftest.er1 >conftest.err
15684   rm -f conftest.er1
15685   cat conftest.err >&5
15686   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15687   (exit $ac_status); } && {
15688          test -z "$ac_c_werror_flag" ||
15689          test ! -s conftest.err
15690        } && test -s conftest.$ac_objext; then
15691   pgac_cv_funcname_function_support=yes
15692 else
15693   $as_echo "$as_me: failed program was:" >&5
15694 sed 's/^/| /' conftest.$ac_ext >&5
15695
15696         pgac_cv_funcname_function_support=no
15697 fi
15698
15699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15700 fi
15701 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
15702 $as_echo "$pgac_cv_funcname_function_support" >&6; }
15703 if test x"$pgac_cv_funcname_function_support" = xyes ; then
15704
15705 cat >>confdefs.h <<\_ACEOF
15706 #define HAVE_FUNCNAME__FUNCTION 1
15707 _ACEOF
15708
15709 fi
15710 fi
15711 { $as_echo "$as_me:$LINENO: checking for _Static_assert" >&5
15712 $as_echo_n "checking for _Static_assert... " >&6; }
15713 if test "${pgac_cv__static_assert+set}" = set; then
15714   $as_echo_n "(cached) " >&6
15715 else
15716   cat >conftest.$ac_ext <<_ACEOF
15717 /* confdefs.h.  */
15718 _ACEOF
15719 cat confdefs.h >>conftest.$ac_ext
15720 cat >>conftest.$ac_ext <<_ACEOF
15721 /* end confdefs.h.  */
15722
15723 int
15724 main ()
15725 {
15726 ({ _Static_assert(1, "foo"); })
15727   ;
15728   return 0;
15729 }
15730 _ACEOF
15731 rm -f conftest.$ac_objext conftest$ac_exeext
15732 if { (ac_try="$ac_link"
15733 case "(($ac_try" in
15734   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15735   *) ac_try_echo=$ac_try;;
15736 esac
15737 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15738 $as_echo "$ac_try_echo") >&5
15739   (eval "$ac_link") 2>conftest.er1
15740   ac_status=$?
15741   grep -v '^ *+' conftest.er1 >conftest.err
15742   rm -f conftest.er1
15743   cat conftest.err >&5
15744   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15745   (exit $ac_status); } && {
15746          test -z "$ac_c_werror_flag" ||
15747          test ! -s conftest.err
15748        } && test -s conftest$ac_exeext && {
15749          test "$cross_compiling" = yes ||
15750          $as_test_x conftest$ac_exeext
15751        }; then
15752   pgac_cv__static_assert=yes
15753 else
15754   $as_echo "$as_me: failed program was:" >&5
15755 sed 's/^/| /' conftest.$ac_ext >&5
15756
15757         pgac_cv__static_assert=no
15758 fi
15759
15760 rm -rf conftest.dSYM
15761 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15762       conftest$ac_exeext conftest.$ac_ext
15763 fi
15764 { $as_echo "$as_me:$LINENO: result: $pgac_cv__static_assert" >&5
15765 $as_echo "$pgac_cv__static_assert" >&6; }
15766 if test x"$pgac_cv__static_assert" = xyes ; then
15767
15768 cat >>confdefs.h <<\_ACEOF
15769 #define HAVE__STATIC_ASSERT 1
15770 _ACEOF
15771
15772 fi
15773 { $as_echo "$as_me:$LINENO: checking for __builtin_types_compatible_p" >&5
15774 $as_echo_n "checking for __builtin_types_compatible_p... " >&6; }
15775 if test "${pgac_cv__types_compatible+set}" = set; then
15776   $as_echo_n "(cached) " >&6
15777 else
15778   cat >conftest.$ac_ext <<_ACEOF
15779 /* confdefs.h.  */
15780 _ACEOF
15781 cat confdefs.h >>conftest.$ac_ext
15782 cat >>conftest.$ac_ext <<_ACEOF
15783 /* end confdefs.h.  */
15784
15785 int
15786 main ()
15787 {
15788  int x; static int y[__builtin_types_compatible_p(__typeof__(x), int)];
15789   ;
15790   return 0;
15791 }
15792 _ACEOF
15793 rm -f conftest.$ac_objext
15794 if { (ac_try="$ac_compile"
15795 case "(($ac_try" in
15796   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15797   *) ac_try_echo=$ac_try;;
15798 esac
15799 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15800 $as_echo "$ac_try_echo") >&5
15801   (eval "$ac_compile") 2>conftest.er1
15802   ac_status=$?
15803   grep -v '^ *+' conftest.er1 >conftest.err
15804   rm -f conftest.er1
15805   cat conftest.err >&5
15806   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15807   (exit $ac_status); } && {
15808          test -z "$ac_c_werror_flag" ||
15809          test ! -s conftest.err
15810        } && test -s conftest.$ac_objext; then
15811   pgac_cv__types_compatible=yes
15812 else
15813   $as_echo "$as_me: failed program was:" >&5
15814 sed 's/^/| /' conftest.$ac_ext >&5
15815
15816         pgac_cv__types_compatible=no
15817 fi
15818
15819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15820 fi
15821 { $as_echo "$as_me:$LINENO: result: $pgac_cv__types_compatible" >&5
15822 $as_echo "$pgac_cv__types_compatible" >&6; }
15823 if test x"$pgac_cv__types_compatible" = xyes ; then
15824
15825 cat >>confdefs.h <<\_ACEOF
15826 #define HAVE__BUILTIN_TYPES_COMPATIBLE_P 1
15827 _ACEOF
15828
15829 fi
15830 { $as_echo "$as_me:$LINENO: checking for __builtin_constant_p" >&5
15831 $as_echo_n "checking for __builtin_constant_p... " >&6; }
15832 if test "${pgac_cv__builtin_constant_p+set}" = set; then
15833   $as_echo_n "(cached) " >&6
15834 else
15835   cat >conftest.$ac_ext <<_ACEOF
15836 /* confdefs.h.  */
15837 _ACEOF
15838 cat confdefs.h >>conftest.$ac_ext
15839 cat >>conftest.$ac_ext <<_ACEOF
15840 /* end confdefs.h.  */
15841 static int x; static int y[__builtin_constant_p(x) ? x : 1];
15842 int
15843 main ()
15844 {
15845
15846   ;
15847   return 0;
15848 }
15849 _ACEOF
15850 rm -f conftest.$ac_objext
15851 if { (ac_try="$ac_compile"
15852 case "(($ac_try" in
15853   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15854   *) ac_try_echo=$ac_try;;
15855 esac
15856 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15857 $as_echo "$ac_try_echo") >&5
15858   (eval "$ac_compile") 2>conftest.er1
15859   ac_status=$?
15860   grep -v '^ *+' conftest.er1 >conftest.err
15861   rm -f conftest.er1
15862   cat conftest.err >&5
15863   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15864   (exit $ac_status); } && {
15865          test -z "$ac_c_werror_flag" ||
15866          test ! -s conftest.err
15867        } && test -s conftest.$ac_objext; then
15868   pgac_cv__builtin_constant_p=yes
15869 else
15870   $as_echo "$as_me: failed program was:" >&5
15871 sed 's/^/| /' conftest.$ac_ext >&5
15872
15873         pgac_cv__builtin_constant_p=no
15874 fi
15875
15876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15877 fi
15878 { $as_echo "$as_me:$LINENO: result: $pgac_cv__builtin_constant_p" >&5
15879 $as_echo "$pgac_cv__builtin_constant_p" >&6; }
15880 if test x"$pgac_cv__builtin_constant_p" = xyes ; then
15881
15882 cat >>confdefs.h <<\_ACEOF
15883 #define HAVE__BUILTIN_CONSTANT_P 1
15884 _ACEOF
15885
15886 fi
15887 { $as_echo "$as_me:$LINENO: checking for __builtin_unreachable" >&5
15888 $as_echo_n "checking for __builtin_unreachable... " >&6; }
15889 if test "${pgac_cv__builtin_unreachable+set}" = set; then
15890   $as_echo_n "(cached) " >&6
15891 else
15892   cat >conftest.$ac_ext <<_ACEOF
15893 /* confdefs.h.  */
15894 _ACEOF
15895 cat confdefs.h >>conftest.$ac_ext
15896 cat >>conftest.$ac_ext <<_ACEOF
15897 /* end confdefs.h.  */
15898
15899 int
15900 main ()
15901 {
15902 __builtin_unreachable();
15903   ;
15904   return 0;
15905 }
15906 _ACEOF
15907 rm -f conftest.$ac_objext conftest$ac_exeext
15908 if { (ac_try="$ac_link"
15909 case "(($ac_try" in
15910   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15911   *) ac_try_echo=$ac_try;;
15912 esac
15913 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15914 $as_echo "$ac_try_echo") >&5
15915   (eval "$ac_link") 2>conftest.er1
15916   ac_status=$?
15917   grep -v '^ *+' conftest.er1 >conftest.err
15918   rm -f conftest.er1
15919   cat conftest.err >&5
15920   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15921   (exit $ac_status); } && {
15922          test -z "$ac_c_werror_flag" ||
15923          test ! -s conftest.err
15924        } && test -s conftest$ac_exeext && {
15925          test "$cross_compiling" = yes ||
15926          $as_test_x conftest$ac_exeext
15927        }; then
15928   pgac_cv__builtin_unreachable=yes
15929 else
15930   $as_echo "$as_me: failed program was:" >&5
15931 sed 's/^/| /' conftest.$ac_ext >&5
15932
15933         pgac_cv__builtin_unreachable=no
15934 fi
15935
15936 rm -rf conftest.dSYM
15937 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15938       conftest$ac_exeext conftest.$ac_ext
15939 fi
15940 { $as_echo "$as_me:$LINENO: result: $pgac_cv__builtin_unreachable" >&5
15941 $as_echo "$pgac_cv__builtin_unreachable" >&6; }
15942 if test x"$pgac_cv__builtin_unreachable" = xyes ; then
15943
15944 cat >>confdefs.h <<\_ACEOF
15945 #define HAVE__BUILTIN_UNREACHABLE 1
15946 _ACEOF
15947
15948 fi
15949 { $as_echo "$as_me:$LINENO: checking for __VA_ARGS__" >&5
15950 $as_echo_n "checking for __VA_ARGS__... " >&6; }
15951 if test "${pgac_cv__va_args+set}" = set; then
15952   $as_echo_n "(cached) " >&6
15953 else
15954   cat >conftest.$ac_ext <<_ACEOF
15955 /* confdefs.h.  */
15956 _ACEOF
15957 cat confdefs.h >>conftest.$ac_ext
15958 cat >>conftest.$ac_ext <<_ACEOF
15959 /* end confdefs.h.  */
15960 #include <stdio.h>
15961 int
15962 main ()
15963 {
15964 #define debug(...) fprintf(stderr, __VA_ARGS__)
15965 debug("%s", "blarg");
15966
15967   ;
15968   return 0;
15969 }
15970 _ACEOF
15971 rm -f conftest.$ac_objext
15972 if { (ac_try="$ac_compile"
15973 case "(($ac_try" in
15974   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15975   *) ac_try_echo=$ac_try;;
15976 esac
15977 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15978 $as_echo "$ac_try_echo") >&5
15979   (eval "$ac_compile") 2>conftest.er1
15980   ac_status=$?
15981   grep -v '^ *+' conftest.er1 >conftest.err
15982   rm -f conftest.er1
15983   cat conftest.err >&5
15984   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15985   (exit $ac_status); } && {
15986          test -z "$ac_c_werror_flag" ||
15987          test ! -s conftest.err
15988        } && test -s conftest.$ac_objext; then
15989   pgac_cv__va_args=yes
15990 else
15991   $as_echo "$as_me: failed program was:" >&5
15992 sed 's/^/| /' conftest.$ac_ext >&5
15993
15994         pgac_cv__va_args=no
15995 fi
15996
15997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15998 fi
15999 { $as_echo "$as_me:$LINENO: result: $pgac_cv__va_args" >&5
16000 $as_echo "$pgac_cv__va_args" >&6; }
16001 if test x"$pgac_cv__va_args" = xyes ; then
16002
16003 cat >>confdefs.h <<\_ACEOF
16004 #define HAVE__VA_ARGS 1
16005 _ACEOF
16006
16007 fi
16008 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
16009 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
16010 if test "${ac_cv_struct_tm+set}" = set; then
16011   $as_echo_n "(cached) " >&6
16012 else
16013   cat >conftest.$ac_ext <<_ACEOF
16014 /* confdefs.h.  */
16015 _ACEOF
16016 cat confdefs.h >>conftest.$ac_ext
16017 cat >>conftest.$ac_ext <<_ACEOF
16018 /* end confdefs.h.  */
16019 #include <sys/types.h>
16020 #include <time.h>
16021
16022 int
16023 main ()
16024 {
16025 struct tm tm;
16026                                      int *p = &tm.tm_sec;
16027                                      return !p;
16028   ;
16029   return 0;
16030 }
16031 _ACEOF
16032 rm -f conftest.$ac_objext
16033 if { (ac_try="$ac_compile"
16034 case "(($ac_try" in
16035   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16036   *) ac_try_echo=$ac_try;;
16037 esac
16038 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16039 $as_echo "$ac_try_echo") >&5
16040   (eval "$ac_compile") 2>conftest.er1
16041   ac_status=$?
16042   grep -v '^ *+' conftest.er1 >conftest.err
16043   rm -f conftest.er1
16044   cat conftest.err >&5
16045   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16046   (exit $ac_status); } && {
16047          test -z "$ac_c_werror_flag" ||
16048          test ! -s conftest.err
16049        } && test -s conftest.$ac_objext; then
16050   ac_cv_struct_tm=time.h
16051 else
16052   $as_echo "$as_me: failed program was:" >&5
16053 sed 's/^/| /' conftest.$ac_ext >&5
16054
16055         ac_cv_struct_tm=sys/time.h
16056 fi
16057
16058 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16059 fi
16060 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
16061 $as_echo "$ac_cv_struct_tm" >&6; }
16062 if test $ac_cv_struct_tm = sys/time.h; then
16063
16064 cat >>confdefs.h <<\_ACEOF
16065 #define TM_IN_SYS_TIME 1
16066 _ACEOF
16067
16068 fi
16069
16070 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
16071 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
16072 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
16073   $as_echo_n "(cached) " >&6
16074 else
16075   cat >conftest.$ac_ext <<_ACEOF
16076 /* confdefs.h.  */
16077 _ACEOF
16078 cat confdefs.h >>conftest.$ac_ext
16079 cat >>conftest.$ac_ext <<_ACEOF
16080 /* end confdefs.h.  */
16081 #include <sys/types.h>
16082 #include <$ac_cv_struct_tm>
16083
16084
16085 int
16086 main ()
16087 {
16088 static struct tm ac_aggr;
16089 if (ac_aggr.tm_zone)
16090 return 0;
16091   ;
16092   return 0;
16093 }
16094 _ACEOF
16095 rm -f conftest.$ac_objext
16096 if { (ac_try="$ac_compile"
16097 case "(($ac_try" in
16098   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16099   *) ac_try_echo=$ac_try;;
16100 esac
16101 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16102 $as_echo "$ac_try_echo") >&5
16103   (eval "$ac_compile") 2>conftest.er1
16104   ac_status=$?
16105   grep -v '^ *+' conftest.er1 >conftest.err
16106   rm -f conftest.er1
16107   cat conftest.err >&5
16108   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16109   (exit $ac_status); } && {
16110          test -z "$ac_c_werror_flag" ||
16111          test ! -s conftest.err
16112        } && test -s conftest.$ac_objext; then
16113   ac_cv_member_struct_tm_tm_zone=yes
16114 else
16115   $as_echo "$as_me: failed program was:" >&5
16116 sed 's/^/| /' conftest.$ac_ext >&5
16117
16118         cat >conftest.$ac_ext <<_ACEOF
16119 /* confdefs.h.  */
16120 _ACEOF
16121 cat confdefs.h >>conftest.$ac_ext
16122 cat >>conftest.$ac_ext <<_ACEOF
16123 /* end confdefs.h.  */
16124 #include <sys/types.h>
16125 #include <$ac_cv_struct_tm>
16126
16127
16128 int
16129 main ()
16130 {
16131 static struct tm ac_aggr;
16132 if (sizeof ac_aggr.tm_zone)
16133 return 0;
16134   ;
16135   return 0;
16136 }
16137 _ACEOF
16138 rm -f conftest.$ac_objext
16139 if { (ac_try="$ac_compile"
16140 case "(($ac_try" in
16141   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16142   *) ac_try_echo=$ac_try;;
16143 esac
16144 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16145 $as_echo "$ac_try_echo") >&5
16146   (eval "$ac_compile") 2>conftest.er1
16147   ac_status=$?
16148   grep -v '^ *+' conftest.er1 >conftest.err
16149   rm -f conftest.er1
16150   cat conftest.err >&5
16151   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16152   (exit $ac_status); } && {
16153          test -z "$ac_c_werror_flag" ||
16154          test ! -s conftest.err
16155        } && test -s conftest.$ac_objext; then
16156   ac_cv_member_struct_tm_tm_zone=yes
16157 else
16158   $as_echo "$as_me: failed program was:" >&5
16159 sed 's/^/| /' conftest.$ac_ext >&5
16160
16161         ac_cv_member_struct_tm_tm_zone=no
16162 fi
16163
16164 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16165 fi
16166
16167 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16168 fi
16169 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
16170 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
16171 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
16172
16173 cat >>confdefs.h <<_ACEOF
16174 #define HAVE_STRUCT_TM_TM_ZONE 1
16175 _ACEOF
16176
16177
16178 fi
16179
16180 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
16181
16182 cat >>confdefs.h <<\_ACEOF
16183 #define HAVE_TM_ZONE 1
16184 _ACEOF
16185
16186 fi
16187 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
16188 $as_echo_n "checking for tzname... " >&6; }
16189 if test "${ac_cv_var_tzname+set}" = set; then
16190   $as_echo_n "(cached) " >&6
16191 else
16192   cat >conftest.$ac_ext <<_ACEOF
16193 /* confdefs.h.  */
16194 _ACEOF
16195 cat confdefs.h >>conftest.$ac_ext
16196 cat >>conftest.$ac_ext <<_ACEOF
16197 /* end confdefs.h.  */
16198 #include <time.h>
16199 #ifndef tzname /* For SGI.  */
16200 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
16201 #endif
16202
16203 int
16204 main ()
16205 {
16206 atoi(*tzname);
16207   ;
16208   return 0;
16209 }
16210 _ACEOF
16211 rm -f conftest.$ac_objext conftest$ac_exeext
16212 if { (ac_try="$ac_link"
16213 case "(($ac_try" in
16214   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16215   *) ac_try_echo=$ac_try;;
16216 esac
16217 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16218 $as_echo "$ac_try_echo") >&5
16219   (eval "$ac_link") 2>conftest.er1
16220   ac_status=$?
16221   grep -v '^ *+' conftest.er1 >conftest.err
16222   rm -f conftest.er1
16223   cat conftest.err >&5
16224   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16225   (exit $ac_status); } && {
16226          test -z "$ac_c_werror_flag" ||
16227          test ! -s conftest.err
16228        } && test -s conftest$ac_exeext && {
16229          test "$cross_compiling" = yes ||
16230          $as_test_x conftest$ac_exeext
16231        }; then
16232   ac_cv_var_tzname=yes
16233 else
16234   $as_echo "$as_me: failed program was:" >&5
16235 sed 's/^/| /' conftest.$ac_ext >&5
16236
16237         ac_cv_var_tzname=no
16238 fi
16239
16240 rm -rf conftest.dSYM
16241 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16242       conftest$ac_exeext conftest.$ac_ext
16243 fi
16244 { $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
16245 $as_echo "$ac_cv_var_tzname" >&6; }
16246 if test $ac_cv_var_tzname = yes; then
16247
16248 cat >>confdefs.h <<\_ACEOF
16249 #define HAVE_TZNAME 1
16250 _ACEOF
16251
16252 fi
16253
16254 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
16255 $as_echo_n "checking for union semun... " >&6; }
16256 if test "${ac_cv_type_union_semun+set}" = set; then
16257   $as_echo_n "(cached) " >&6
16258 else
16259   ac_cv_type_union_semun=no
16260 cat >conftest.$ac_ext <<_ACEOF
16261 /* confdefs.h.  */
16262 _ACEOF
16263 cat confdefs.h >>conftest.$ac_ext
16264 cat >>conftest.$ac_ext <<_ACEOF
16265 /* end confdefs.h.  */
16266 #include <sys/types.h>
16267 #include <sys/ipc.h>
16268 #include <sys/sem.h>
16269
16270 int
16271 main ()
16272 {
16273 if (sizeof (union semun))
16274        return 0;
16275   ;
16276   return 0;
16277 }
16278 _ACEOF
16279 rm -f conftest.$ac_objext
16280 if { (ac_try="$ac_compile"
16281 case "(($ac_try" in
16282   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16283   *) ac_try_echo=$ac_try;;
16284 esac
16285 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16286 $as_echo "$ac_try_echo") >&5
16287   (eval "$ac_compile") 2>conftest.er1
16288   ac_status=$?
16289   grep -v '^ *+' conftest.er1 >conftest.err
16290   rm -f conftest.er1
16291   cat conftest.err >&5
16292   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16293   (exit $ac_status); } && {
16294          test -z "$ac_c_werror_flag" ||
16295          test ! -s conftest.err
16296        } && test -s conftest.$ac_objext; then
16297   cat >conftest.$ac_ext <<_ACEOF
16298 /* confdefs.h.  */
16299 _ACEOF
16300 cat confdefs.h >>conftest.$ac_ext
16301 cat >>conftest.$ac_ext <<_ACEOF
16302 /* end confdefs.h.  */
16303 #include <sys/types.h>
16304 #include <sys/ipc.h>
16305 #include <sys/sem.h>
16306
16307 int
16308 main ()
16309 {
16310 if (sizeof ((union semun)))
16311           return 0;
16312   ;
16313   return 0;
16314 }
16315 _ACEOF
16316 rm -f conftest.$ac_objext
16317 if { (ac_try="$ac_compile"
16318 case "(($ac_try" in
16319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16320   *) ac_try_echo=$ac_try;;
16321 esac
16322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16323 $as_echo "$ac_try_echo") >&5
16324   (eval "$ac_compile") 2>conftest.er1
16325   ac_status=$?
16326   grep -v '^ *+' conftest.er1 >conftest.err
16327   rm -f conftest.er1
16328   cat conftest.err >&5
16329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16330   (exit $ac_status); } && {
16331          test -z "$ac_c_werror_flag" ||
16332          test ! -s conftest.err
16333        } && test -s conftest.$ac_objext; then
16334   :
16335 else
16336   $as_echo "$as_me: failed program was:" >&5
16337 sed 's/^/| /' conftest.$ac_ext >&5
16338
16339         ac_cv_type_union_semun=yes
16340 fi
16341
16342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16343 else
16344   $as_echo "$as_me: failed program was:" >&5
16345 sed 's/^/| /' conftest.$ac_ext >&5
16346
16347
16348 fi
16349
16350 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16351 fi
16352 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
16353 $as_echo "$ac_cv_type_union_semun" >&6; }
16354 if test "x$ac_cv_type_union_semun" = x""yes; then
16355
16356 cat >>confdefs.h <<_ACEOF
16357 #define HAVE_UNION_SEMUN 1
16358 _ACEOF
16359
16360
16361 fi
16362
16363 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
16364 $as_echo_n "checking for struct sockaddr_un... " >&6; }
16365 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
16366   $as_echo_n "(cached) " >&6
16367 else
16368   ac_cv_type_struct_sockaddr_un=no
16369 cat >conftest.$ac_ext <<_ACEOF
16370 /* confdefs.h.  */
16371 _ACEOF
16372 cat confdefs.h >>conftest.$ac_ext
16373 cat >>conftest.$ac_ext <<_ACEOF
16374 /* end confdefs.h.  */
16375 #include <sys/types.h>
16376 #ifdef HAVE_SYS_UN_H
16377 #include <sys/un.h>
16378 #endif
16379
16380
16381 int
16382 main ()
16383 {
16384 if (sizeof (struct sockaddr_un))
16385        return 0;
16386   ;
16387   return 0;
16388 }
16389 _ACEOF
16390 rm -f conftest.$ac_objext
16391 if { (ac_try="$ac_compile"
16392 case "(($ac_try" in
16393   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16394   *) ac_try_echo=$ac_try;;
16395 esac
16396 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16397 $as_echo "$ac_try_echo") >&5
16398   (eval "$ac_compile") 2>conftest.er1
16399   ac_status=$?
16400   grep -v '^ *+' conftest.er1 >conftest.err
16401   rm -f conftest.er1
16402   cat conftest.err >&5
16403   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16404   (exit $ac_status); } && {
16405          test -z "$ac_c_werror_flag" ||
16406          test ! -s conftest.err
16407        } && test -s conftest.$ac_objext; then
16408   cat >conftest.$ac_ext <<_ACEOF
16409 /* confdefs.h.  */
16410 _ACEOF
16411 cat confdefs.h >>conftest.$ac_ext
16412 cat >>conftest.$ac_ext <<_ACEOF
16413 /* end confdefs.h.  */
16414 #include <sys/types.h>
16415 #ifdef HAVE_SYS_UN_H
16416 #include <sys/un.h>
16417 #endif
16418
16419
16420 int
16421 main ()
16422 {
16423 if (sizeof ((struct sockaddr_un)))
16424           return 0;
16425   ;
16426   return 0;
16427 }
16428 _ACEOF
16429 rm -f conftest.$ac_objext
16430 if { (ac_try="$ac_compile"
16431 case "(($ac_try" in
16432   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16433   *) ac_try_echo=$ac_try;;
16434 esac
16435 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16436 $as_echo "$ac_try_echo") >&5
16437   (eval "$ac_compile") 2>conftest.er1
16438   ac_status=$?
16439   grep -v '^ *+' conftest.er1 >conftest.err
16440   rm -f conftest.er1
16441   cat conftest.err >&5
16442   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16443   (exit $ac_status); } && {
16444          test -z "$ac_c_werror_flag" ||
16445          test ! -s conftest.err
16446        } && test -s conftest.$ac_objext; then
16447   :
16448 else
16449   $as_echo "$as_me: failed program was:" >&5
16450 sed 's/^/| /' conftest.$ac_ext >&5
16451
16452         ac_cv_type_struct_sockaddr_un=yes
16453 fi
16454
16455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16456 else
16457   $as_echo "$as_me: failed program was:" >&5
16458 sed 's/^/| /' conftest.$ac_ext >&5
16459
16460
16461 fi
16462
16463 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16464 fi
16465 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
16466 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
16467 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
16468
16469 cat >>confdefs.h <<\_ACEOF
16470 #define HAVE_UNIX_SOCKETS 1
16471 _ACEOF
16472
16473 fi
16474
16475 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
16476 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
16477 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
16478   $as_echo_n "(cached) " >&6
16479 else
16480   ac_cv_type_struct_sockaddr_storage=no
16481 cat >conftest.$ac_ext <<_ACEOF
16482 /* confdefs.h.  */
16483 _ACEOF
16484 cat confdefs.h >>conftest.$ac_ext
16485 cat >>conftest.$ac_ext <<_ACEOF
16486 /* end confdefs.h.  */
16487 #include <sys/types.h>
16488 #ifdef HAVE_SYS_SOCKET_H
16489 #include <sys/socket.h>
16490 #endif
16491
16492
16493 int
16494 main ()
16495 {
16496 if (sizeof (struct sockaddr_storage))
16497        return 0;
16498   ;
16499   return 0;
16500 }
16501 _ACEOF
16502 rm -f conftest.$ac_objext
16503 if { (ac_try="$ac_compile"
16504 case "(($ac_try" in
16505   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16506   *) ac_try_echo=$ac_try;;
16507 esac
16508 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16509 $as_echo "$ac_try_echo") >&5
16510   (eval "$ac_compile") 2>conftest.er1
16511   ac_status=$?
16512   grep -v '^ *+' conftest.er1 >conftest.err
16513   rm -f conftest.er1
16514   cat conftest.err >&5
16515   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16516   (exit $ac_status); } && {
16517          test -z "$ac_c_werror_flag" ||
16518          test ! -s conftest.err
16519        } && test -s conftest.$ac_objext; then
16520   cat >conftest.$ac_ext <<_ACEOF
16521 /* confdefs.h.  */
16522 _ACEOF
16523 cat confdefs.h >>conftest.$ac_ext
16524 cat >>conftest.$ac_ext <<_ACEOF
16525 /* end confdefs.h.  */
16526 #include <sys/types.h>
16527 #ifdef HAVE_SYS_SOCKET_H
16528 #include <sys/socket.h>
16529 #endif
16530
16531
16532 int
16533 main ()
16534 {
16535 if (sizeof ((struct sockaddr_storage)))
16536           return 0;
16537   ;
16538   return 0;
16539 }
16540 _ACEOF
16541 rm -f conftest.$ac_objext
16542 if { (ac_try="$ac_compile"
16543 case "(($ac_try" in
16544   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16545   *) ac_try_echo=$ac_try;;
16546 esac
16547 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16548 $as_echo "$ac_try_echo") >&5
16549   (eval "$ac_compile") 2>conftest.er1
16550   ac_status=$?
16551   grep -v '^ *+' conftest.er1 >conftest.err
16552   rm -f conftest.er1
16553   cat conftest.err >&5
16554   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16555   (exit $ac_status); } && {
16556          test -z "$ac_c_werror_flag" ||
16557          test ! -s conftest.err
16558        } && test -s conftest.$ac_objext; then
16559   :
16560 else
16561   $as_echo "$as_me: failed program was:" >&5
16562 sed 's/^/| /' conftest.$ac_ext >&5
16563
16564         ac_cv_type_struct_sockaddr_storage=yes
16565 fi
16566
16567 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16568 else
16569   $as_echo "$as_me: failed program was:" >&5
16570 sed 's/^/| /' conftest.$ac_ext >&5
16571
16572
16573 fi
16574
16575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16576 fi
16577 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
16578 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
16579 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
16580
16581 cat >>confdefs.h <<_ACEOF
16582 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
16583 _ACEOF
16584
16585
16586 fi
16587
16588 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
16589 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
16590 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
16591   $as_echo_n "(cached) " >&6
16592 else
16593   cat >conftest.$ac_ext <<_ACEOF
16594 /* confdefs.h.  */
16595 _ACEOF
16596 cat confdefs.h >>conftest.$ac_ext
16597 cat >>conftest.$ac_ext <<_ACEOF
16598 /* end confdefs.h.  */
16599 #include <sys/types.h>
16600 #ifdef HAVE_SYS_SOCKET_H
16601 #include <sys/socket.h>
16602 #endif
16603
16604
16605 int
16606 main ()
16607 {
16608 static struct sockaddr_storage ac_aggr;
16609 if (ac_aggr.ss_family)
16610 return 0;
16611   ;
16612   return 0;
16613 }
16614 _ACEOF
16615 rm -f conftest.$ac_objext
16616 if { (ac_try="$ac_compile"
16617 case "(($ac_try" in
16618   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16619   *) ac_try_echo=$ac_try;;
16620 esac
16621 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16622 $as_echo "$ac_try_echo") >&5
16623   (eval "$ac_compile") 2>conftest.er1
16624   ac_status=$?
16625   grep -v '^ *+' conftest.er1 >conftest.err
16626   rm -f conftest.er1
16627   cat conftest.err >&5
16628   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16629   (exit $ac_status); } && {
16630          test -z "$ac_c_werror_flag" ||
16631          test ! -s conftest.err
16632        } && test -s conftest.$ac_objext; then
16633   ac_cv_member_struct_sockaddr_storage_ss_family=yes
16634 else
16635   $as_echo "$as_me: failed program was:" >&5
16636 sed 's/^/| /' conftest.$ac_ext >&5
16637
16638         cat >conftest.$ac_ext <<_ACEOF
16639 /* confdefs.h.  */
16640 _ACEOF
16641 cat confdefs.h >>conftest.$ac_ext
16642 cat >>conftest.$ac_ext <<_ACEOF
16643 /* end confdefs.h.  */
16644 #include <sys/types.h>
16645 #ifdef HAVE_SYS_SOCKET_H
16646 #include <sys/socket.h>
16647 #endif
16648
16649
16650 int
16651 main ()
16652 {
16653 static struct sockaddr_storage ac_aggr;
16654 if (sizeof ac_aggr.ss_family)
16655 return 0;
16656   ;
16657   return 0;
16658 }
16659 _ACEOF
16660 rm -f conftest.$ac_objext
16661 if { (ac_try="$ac_compile"
16662 case "(($ac_try" in
16663   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16664   *) ac_try_echo=$ac_try;;
16665 esac
16666 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16667 $as_echo "$ac_try_echo") >&5
16668   (eval "$ac_compile") 2>conftest.er1
16669   ac_status=$?
16670   grep -v '^ *+' conftest.er1 >conftest.err
16671   rm -f conftest.er1
16672   cat conftest.err >&5
16673   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16674   (exit $ac_status); } && {
16675          test -z "$ac_c_werror_flag" ||
16676          test ! -s conftest.err
16677        } && test -s conftest.$ac_objext; then
16678   ac_cv_member_struct_sockaddr_storage_ss_family=yes
16679 else
16680   $as_echo "$as_me: failed program was:" >&5
16681 sed 's/^/| /' conftest.$ac_ext >&5
16682
16683         ac_cv_member_struct_sockaddr_storage_ss_family=no
16684 fi
16685
16686 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16687 fi
16688
16689 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16690 fi
16691 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
16692 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
16693 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
16694
16695 cat >>confdefs.h <<_ACEOF
16696 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
16697 _ACEOF
16698
16699
16700 fi
16701 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
16702 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
16703 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
16704   $as_echo_n "(cached) " >&6
16705 else
16706   cat >conftest.$ac_ext <<_ACEOF
16707 /* confdefs.h.  */
16708 _ACEOF
16709 cat confdefs.h >>conftest.$ac_ext
16710 cat >>conftest.$ac_ext <<_ACEOF
16711 /* end confdefs.h.  */
16712 #include <sys/types.h>
16713 #ifdef HAVE_SYS_SOCKET_H
16714 #include <sys/socket.h>
16715 #endif
16716
16717
16718 int
16719 main ()
16720 {
16721 static struct sockaddr_storage ac_aggr;
16722 if (ac_aggr.__ss_family)
16723 return 0;
16724   ;
16725   return 0;
16726 }
16727 _ACEOF
16728 rm -f conftest.$ac_objext
16729 if { (ac_try="$ac_compile"
16730 case "(($ac_try" in
16731   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16732   *) ac_try_echo=$ac_try;;
16733 esac
16734 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16735 $as_echo "$ac_try_echo") >&5
16736   (eval "$ac_compile") 2>conftest.er1
16737   ac_status=$?
16738   grep -v '^ *+' conftest.er1 >conftest.err
16739   rm -f conftest.er1
16740   cat conftest.err >&5
16741   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16742   (exit $ac_status); } && {
16743          test -z "$ac_c_werror_flag" ||
16744          test ! -s conftest.err
16745        } && test -s conftest.$ac_objext; then
16746   ac_cv_member_struct_sockaddr_storage___ss_family=yes
16747 else
16748   $as_echo "$as_me: failed program was:" >&5
16749 sed 's/^/| /' conftest.$ac_ext >&5
16750
16751         cat >conftest.$ac_ext <<_ACEOF
16752 /* confdefs.h.  */
16753 _ACEOF
16754 cat confdefs.h >>conftest.$ac_ext
16755 cat >>conftest.$ac_ext <<_ACEOF
16756 /* end confdefs.h.  */
16757 #include <sys/types.h>
16758 #ifdef HAVE_SYS_SOCKET_H
16759 #include <sys/socket.h>
16760 #endif
16761
16762
16763 int
16764 main ()
16765 {
16766 static struct sockaddr_storage ac_aggr;
16767 if (sizeof ac_aggr.__ss_family)
16768 return 0;
16769   ;
16770   return 0;
16771 }
16772 _ACEOF
16773 rm -f conftest.$ac_objext
16774 if { (ac_try="$ac_compile"
16775 case "(($ac_try" in
16776   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16777   *) ac_try_echo=$ac_try;;
16778 esac
16779 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16780 $as_echo "$ac_try_echo") >&5
16781   (eval "$ac_compile") 2>conftest.er1
16782   ac_status=$?
16783   grep -v '^ *+' conftest.er1 >conftest.err
16784   rm -f conftest.er1
16785   cat conftest.err >&5
16786   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16787   (exit $ac_status); } && {
16788          test -z "$ac_c_werror_flag" ||
16789          test ! -s conftest.err
16790        } && test -s conftest.$ac_objext; then
16791   ac_cv_member_struct_sockaddr_storage___ss_family=yes
16792 else
16793   $as_echo "$as_me: failed program was:" >&5
16794 sed 's/^/| /' conftest.$ac_ext >&5
16795
16796         ac_cv_member_struct_sockaddr_storage___ss_family=no
16797 fi
16798
16799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16800 fi
16801
16802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16803 fi
16804 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
16805 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
16806 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
16807
16808 cat >>confdefs.h <<_ACEOF
16809 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
16810 _ACEOF
16811
16812
16813 fi
16814 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
16815 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
16816 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
16817   $as_echo_n "(cached) " >&6
16818 else
16819   cat >conftest.$ac_ext <<_ACEOF
16820 /* confdefs.h.  */
16821 _ACEOF
16822 cat confdefs.h >>conftest.$ac_ext
16823 cat >>conftest.$ac_ext <<_ACEOF
16824 /* end confdefs.h.  */
16825 #include <sys/types.h>
16826 #ifdef HAVE_SYS_SOCKET_H
16827 #include <sys/socket.h>
16828 #endif
16829
16830
16831 int
16832 main ()
16833 {
16834 static struct sockaddr_storage ac_aggr;
16835 if (ac_aggr.ss_len)
16836 return 0;
16837   ;
16838   return 0;
16839 }
16840 _ACEOF
16841 rm -f conftest.$ac_objext
16842 if { (ac_try="$ac_compile"
16843 case "(($ac_try" in
16844   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16845   *) ac_try_echo=$ac_try;;
16846 esac
16847 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16848 $as_echo "$ac_try_echo") >&5
16849   (eval "$ac_compile") 2>conftest.er1
16850   ac_status=$?
16851   grep -v '^ *+' conftest.er1 >conftest.err
16852   rm -f conftest.er1
16853   cat conftest.err >&5
16854   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16855   (exit $ac_status); } && {
16856          test -z "$ac_c_werror_flag" ||
16857          test ! -s conftest.err
16858        } && test -s conftest.$ac_objext; then
16859   ac_cv_member_struct_sockaddr_storage_ss_len=yes
16860 else
16861   $as_echo "$as_me: failed program was:" >&5
16862 sed 's/^/| /' conftest.$ac_ext >&5
16863
16864         cat >conftest.$ac_ext <<_ACEOF
16865 /* confdefs.h.  */
16866 _ACEOF
16867 cat confdefs.h >>conftest.$ac_ext
16868 cat >>conftest.$ac_ext <<_ACEOF
16869 /* end confdefs.h.  */
16870 #include <sys/types.h>
16871 #ifdef HAVE_SYS_SOCKET_H
16872 #include <sys/socket.h>
16873 #endif
16874
16875
16876 int
16877 main ()
16878 {
16879 static struct sockaddr_storage ac_aggr;
16880 if (sizeof ac_aggr.ss_len)
16881 return 0;
16882   ;
16883   return 0;
16884 }
16885 _ACEOF
16886 rm -f conftest.$ac_objext
16887 if { (ac_try="$ac_compile"
16888 case "(($ac_try" in
16889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16890   *) ac_try_echo=$ac_try;;
16891 esac
16892 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16893 $as_echo "$ac_try_echo") >&5
16894   (eval "$ac_compile") 2>conftest.er1
16895   ac_status=$?
16896   grep -v '^ *+' conftest.er1 >conftest.err
16897   rm -f conftest.er1
16898   cat conftest.err >&5
16899   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16900   (exit $ac_status); } && {
16901          test -z "$ac_c_werror_flag" ||
16902          test ! -s conftest.err
16903        } && test -s conftest.$ac_objext; then
16904   ac_cv_member_struct_sockaddr_storage_ss_len=yes
16905 else
16906   $as_echo "$as_me: failed program was:" >&5
16907 sed 's/^/| /' conftest.$ac_ext >&5
16908
16909         ac_cv_member_struct_sockaddr_storage_ss_len=no
16910 fi
16911
16912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16913 fi
16914
16915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16916 fi
16917 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
16918 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
16919 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
16920
16921 cat >>confdefs.h <<_ACEOF
16922 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
16923 _ACEOF
16924
16925
16926 fi
16927 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
16928 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
16929 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
16930   $as_echo_n "(cached) " >&6
16931 else
16932   cat >conftest.$ac_ext <<_ACEOF
16933 /* confdefs.h.  */
16934 _ACEOF
16935 cat confdefs.h >>conftest.$ac_ext
16936 cat >>conftest.$ac_ext <<_ACEOF
16937 /* end confdefs.h.  */
16938 #include <sys/types.h>
16939 #ifdef HAVE_SYS_SOCKET_H
16940 #include <sys/socket.h>
16941 #endif
16942
16943
16944 int
16945 main ()
16946 {
16947 static struct sockaddr_storage ac_aggr;
16948 if (ac_aggr.__ss_len)
16949 return 0;
16950   ;
16951   return 0;
16952 }
16953 _ACEOF
16954 rm -f conftest.$ac_objext
16955 if { (ac_try="$ac_compile"
16956 case "(($ac_try" in
16957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16958   *) ac_try_echo=$ac_try;;
16959 esac
16960 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16961 $as_echo "$ac_try_echo") >&5
16962   (eval "$ac_compile") 2>conftest.er1
16963   ac_status=$?
16964   grep -v '^ *+' conftest.er1 >conftest.err
16965   rm -f conftest.er1
16966   cat conftest.err >&5
16967   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16968   (exit $ac_status); } && {
16969          test -z "$ac_c_werror_flag" ||
16970          test ! -s conftest.err
16971        } && test -s conftest.$ac_objext; then
16972   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16973 else
16974   $as_echo "$as_me: failed program was:" >&5
16975 sed 's/^/| /' conftest.$ac_ext >&5
16976
16977         cat >conftest.$ac_ext <<_ACEOF
16978 /* confdefs.h.  */
16979 _ACEOF
16980 cat confdefs.h >>conftest.$ac_ext
16981 cat >>conftest.$ac_ext <<_ACEOF
16982 /* end confdefs.h.  */
16983 #include <sys/types.h>
16984 #ifdef HAVE_SYS_SOCKET_H
16985 #include <sys/socket.h>
16986 #endif
16987
16988
16989 int
16990 main ()
16991 {
16992 static struct sockaddr_storage ac_aggr;
16993 if (sizeof ac_aggr.__ss_len)
16994 return 0;
16995   ;
16996   return 0;
16997 }
16998 _ACEOF
16999 rm -f conftest.$ac_objext
17000 if { (ac_try="$ac_compile"
17001 case "(($ac_try" in
17002   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17003   *) ac_try_echo=$ac_try;;
17004 esac
17005 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17006 $as_echo "$ac_try_echo") >&5
17007   (eval "$ac_compile") 2>conftest.er1
17008   ac_status=$?
17009   grep -v '^ *+' conftest.er1 >conftest.err
17010   rm -f conftest.er1
17011   cat conftest.err >&5
17012   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17013   (exit $ac_status); } && {
17014          test -z "$ac_c_werror_flag" ||
17015          test ! -s conftest.err
17016        } && test -s conftest.$ac_objext; then
17017   ac_cv_member_struct_sockaddr_storage___ss_len=yes
17018 else
17019   $as_echo "$as_me: failed program was:" >&5
17020 sed 's/^/| /' conftest.$ac_ext >&5
17021
17022         ac_cv_member_struct_sockaddr_storage___ss_len=no
17023 fi
17024
17025 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17026 fi
17027
17028 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17029 fi
17030 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
17031 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
17032 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
17033
17034 cat >>confdefs.h <<_ACEOF
17035 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
17036 _ACEOF
17037
17038
17039 fi
17040 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
17041 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
17042 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
17043   $as_echo_n "(cached) " >&6
17044 else
17045   cat >conftest.$ac_ext <<_ACEOF
17046 /* confdefs.h.  */
17047 _ACEOF
17048 cat confdefs.h >>conftest.$ac_ext
17049 cat >>conftest.$ac_ext <<_ACEOF
17050 /* end confdefs.h.  */
17051 #include <sys/types.h>
17052 #ifdef HAVE_SYS_SOCKET_H
17053 #include <sys/socket.h>
17054 #endif
17055
17056
17057 int
17058 main ()
17059 {
17060 static struct sockaddr ac_aggr;
17061 if (ac_aggr.sa_len)
17062 return 0;
17063   ;
17064   return 0;
17065 }
17066 _ACEOF
17067 rm -f conftest.$ac_objext
17068 if { (ac_try="$ac_compile"
17069 case "(($ac_try" in
17070   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17071   *) ac_try_echo=$ac_try;;
17072 esac
17073 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17074 $as_echo "$ac_try_echo") >&5
17075   (eval "$ac_compile") 2>conftest.er1
17076   ac_status=$?
17077   grep -v '^ *+' conftest.er1 >conftest.err
17078   rm -f conftest.er1
17079   cat conftest.err >&5
17080   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17081   (exit $ac_status); } && {
17082          test -z "$ac_c_werror_flag" ||
17083          test ! -s conftest.err
17084        } && test -s conftest.$ac_objext; then
17085   ac_cv_member_struct_sockaddr_sa_len=yes
17086 else
17087   $as_echo "$as_me: failed program was:" >&5
17088 sed 's/^/| /' conftest.$ac_ext >&5
17089
17090         cat >conftest.$ac_ext <<_ACEOF
17091 /* confdefs.h.  */
17092 _ACEOF
17093 cat confdefs.h >>conftest.$ac_ext
17094 cat >>conftest.$ac_ext <<_ACEOF
17095 /* end confdefs.h.  */
17096 #include <sys/types.h>
17097 #ifdef HAVE_SYS_SOCKET_H
17098 #include <sys/socket.h>
17099 #endif
17100
17101
17102 int
17103 main ()
17104 {
17105 static struct sockaddr ac_aggr;
17106 if (sizeof ac_aggr.sa_len)
17107 return 0;
17108   ;
17109   return 0;
17110 }
17111 _ACEOF
17112 rm -f conftest.$ac_objext
17113 if { (ac_try="$ac_compile"
17114 case "(($ac_try" in
17115   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17116   *) ac_try_echo=$ac_try;;
17117 esac
17118 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17119 $as_echo "$ac_try_echo") >&5
17120   (eval "$ac_compile") 2>conftest.er1
17121   ac_status=$?
17122   grep -v '^ *+' conftest.er1 >conftest.err
17123   rm -f conftest.er1
17124   cat conftest.err >&5
17125   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17126   (exit $ac_status); } && {
17127          test -z "$ac_c_werror_flag" ||
17128          test ! -s conftest.err
17129        } && test -s conftest.$ac_objext; then
17130   ac_cv_member_struct_sockaddr_sa_len=yes
17131 else
17132   $as_echo "$as_me: failed program was:" >&5
17133 sed 's/^/| /' conftest.$ac_ext >&5
17134
17135         ac_cv_member_struct_sockaddr_sa_len=no
17136 fi
17137
17138 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17139 fi
17140
17141 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17142 fi
17143 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
17144 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
17145 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
17146
17147 cat >>confdefs.h <<_ACEOF
17148 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
17149 _ACEOF
17150
17151
17152 fi
17153
17154 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
17155 $as_echo_n "checking for struct addrinfo... " >&6; }
17156 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
17157   $as_echo_n "(cached) " >&6
17158 else
17159   ac_cv_type_struct_addrinfo=no
17160 cat >conftest.$ac_ext <<_ACEOF
17161 /* confdefs.h.  */
17162 _ACEOF
17163 cat confdefs.h >>conftest.$ac_ext
17164 cat >>conftest.$ac_ext <<_ACEOF
17165 /* end confdefs.h.  */
17166 #include <sys/types.h>
17167 #include <sys/socket.h>
17168 #include <netdb.h>
17169
17170
17171 int
17172 main ()
17173 {
17174 if (sizeof (struct addrinfo))
17175        return 0;
17176   ;
17177   return 0;
17178 }
17179 _ACEOF
17180 rm -f conftest.$ac_objext
17181 if { (ac_try="$ac_compile"
17182 case "(($ac_try" in
17183   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17184   *) ac_try_echo=$ac_try;;
17185 esac
17186 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17187 $as_echo "$ac_try_echo") >&5
17188   (eval "$ac_compile") 2>conftest.er1
17189   ac_status=$?
17190   grep -v '^ *+' conftest.er1 >conftest.err
17191   rm -f conftest.er1
17192   cat conftest.err >&5
17193   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17194   (exit $ac_status); } && {
17195          test -z "$ac_c_werror_flag" ||
17196          test ! -s conftest.err
17197        } && test -s conftest.$ac_objext; then
17198   cat >conftest.$ac_ext <<_ACEOF
17199 /* confdefs.h.  */
17200 _ACEOF
17201 cat confdefs.h >>conftest.$ac_ext
17202 cat >>conftest.$ac_ext <<_ACEOF
17203 /* end confdefs.h.  */
17204 #include <sys/types.h>
17205 #include <sys/socket.h>
17206 #include <netdb.h>
17207
17208
17209 int
17210 main ()
17211 {
17212 if (sizeof ((struct addrinfo)))
17213           return 0;
17214   ;
17215   return 0;
17216 }
17217 _ACEOF
17218 rm -f conftest.$ac_objext
17219 if { (ac_try="$ac_compile"
17220 case "(($ac_try" in
17221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17222   *) ac_try_echo=$ac_try;;
17223 esac
17224 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17225 $as_echo "$ac_try_echo") >&5
17226   (eval "$ac_compile") 2>conftest.er1
17227   ac_status=$?
17228   grep -v '^ *+' conftest.er1 >conftest.err
17229   rm -f conftest.er1
17230   cat conftest.err >&5
17231   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17232   (exit $ac_status); } && {
17233          test -z "$ac_c_werror_flag" ||
17234          test ! -s conftest.err
17235        } && test -s conftest.$ac_objext; then
17236   :
17237 else
17238   $as_echo "$as_me: failed program was:" >&5
17239 sed 's/^/| /' conftest.$ac_ext >&5
17240
17241         ac_cv_type_struct_addrinfo=yes
17242 fi
17243
17244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17245 else
17246   $as_echo "$as_me: failed program was:" >&5
17247 sed 's/^/| /' conftest.$ac_ext >&5
17248
17249
17250 fi
17251
17252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17253 fi
17254 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
17255 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
17256 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
17257
17258 cat >>confdefs.h <<_ACEOF
17259 #define HAVE_STRUCT_ADDRINFO 1
17260 _ACEOF
17261
17262
17263 fi
17264
17265
17266   { $as_echo "$as_me:$LINENO: checking for intptr_t" >&5
17267 $as_echo_n "checking for intptr_t... " >&6; }
17268 if test "${ac_cv_type_intptr_t+set}" = set; then
17269   $as_echo_n "(cached) " >&6
17270 else
17271   ac_cv_type_intptr_t=no
17272 cat >conftest.$ac_ext <<_ACEOF
17273 /* confdefs.h.  */
17274 _ACEOF
17275 cat confdefs.h >>conftest.$ac_ext
17276 cat >>conftest.$ac_ext <<_ACEOF
17277 /* end confdefs.h.  */
17278 $ac_includes_default
17279 int
17280 main ()
17281 {
17282 if (sizeof (intptr_t))
17283        return 0;
17284   ;
17285   return 0;
17286 }
17287 _ACEOF
17288 rm -f conftest.$ac_objext
17289 if { (ac_try="$ac_compile"
17290 case "(($ac_try" in
17291   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17292   *) ac_try_echo=$ac_try;;
17293 esac
17294 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17295 $as_echo "$ac_try_echo") >&5
17296   (eval "$ac_compile") 2>conftest.er1
17297   ac_status=$?
17298   grep -v '^ *+' conftest.er1 >conftest.err
17299   rm -f conftest.er1
17300   cat conftest.err >&5
17301   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17302   (exit $ac_status); } && {
17303          test -z "$ac_c_werror_flag" ||
17304          test ! -s conftest.err
17305        } && test -s conftest.$ac_objext; then
17306   cat >conftest.$ac_ext <<_ACEOF
17307 /* confdefs.h.  */
17308 _ACEOF
17309 cat confdefs.h >>conftest.$ac_ext
17310 cat >>conftest.$ac_ext <<_ACEOF
17311 /* end confdefs.h.  */
17312 $ac_includes_default
17313 int
17314 main ()
17315 {
17316 if (sizeof ((intptr_t)))
17317           return 0;
17318   ;
17319   return 0;
17320 }
17321 _ACEOF
17322 rm -f conftest.$ac_objext
17323 if { (ac_try="$ac_compile"
17324 case "(($ac_try" in
17325   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17326   *) ac_try_echo=$ac_try;;
17327 esac
17328 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17329 $as_echo "$ac_try_echo") >&5
17330   (eval "$ac_compile") 2>conftest.er1
17331   ac_status=$?
17332   grep -v '^ *+' conftest.er1 >conftest.err
17333   rm -f conftest.er1
17334   cat conftest.err >&5
17335   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17336   (exit $ac_status); } && {
17337          test -z "$ac_c_werror_flag" ||
17338          test ! -s conftest.err
17339        } && test -s conftest.$ac_objext; then
17340   :
17341 else
17342   $as_echo "$as_me: failed program was:" >&5
17343 sed 's/^/| /' conftest.$ac_ext >&5
17344
17345         ac_cv_type_intptr_t=yes
17346 fi
17347
17348 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17349 else
17350   $as_echo "$as_me: failed program was:" >&5
17351 sed 's/^/| /' conftest.$ac_ext >&5
17352
17353
17354 fi
17355
17356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17357 fi
17358 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
17359 $as_echo "$ac_cv_type_intptr_t" >&6; }
17360 if test "x$ac_cv_type_intptr_t" = x""yes; then
17361
17362 cat >>confdefs.h <<\_ACEOF
17363 #define HAVE_INTPTR_T 1
17364 _ACEOF
17365
17366 else
17367   for ac_type in 'int' 'long int' 'long long int'; do
17368        cat >conftest.$ac_ext <<_ACEOF
17369 /* confdefs.h.  */
17370 _ACEOF
17371 cat confdefs.h >>conftest.$ac_ext
17372 cat >>conftest.$ac_ext <<_ACEOF
17373 /* end confdefs.h.  */
17374 $ac_includes_default
17375 int
17376 main ()
17377 {
17378 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
17379 test_array [0] = 0
17380
17381   ;
17382   return 0;
17383 }
17384 _ACEOF
17385 rm -f conftest.$ac_objext
17386 if { (ac_try="$ac_compile"
17387 case "(($ac_try" in
17388   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17389   *) ac_try_echo=$ac_try;;
17390 esac
17391 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17392 $as_echo "$ac_try_echo") >&5
17393   (eval "$ac_compile") 2>conftest.er1
17394   ac_status=$?
17395   grep -v '^ *+' conftest.er1 >conftest.err
17396   rm -f conftest.er1
17397   cat conftest.err >&5
17398   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17399   (exit $ac_status); } && {
17400          test -z "$ac_c_werror_flag" ||
17401          test ! -s conftest.err
17402        } && test -s conftest.$ac_objext; then
17403
17404 cat >>confdefs.h <<_ACEOF
17405 #define intptr_t $ac_type
17406 _ACEOF
17407
17408           ac_type=
17409 else
17410   $as_echo "$as_me: failed program was:" >&5
17411 sed 's/^/| /' conftest.$ac_ext >&5
17412
17413
17414 fi
17415
17416 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17417        test -z "$ac_type" && break
17418      done
17419 fi
17420
17421
17422
17423   { $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
17424 $as_echo_n "checking for uintptr_t... " >&6; }
17425 if test "${ac_cv_type_uintptr_t+set}" = set; then
17426   $as_echo_n "(cached) " >&6
17427 else
17428   ac_cv_type_uintptr_t=no
17429 cat >conftest.$ac_ext <<_ACEOF
17430 /* confdefs.h.  */
17431 _ACEOF
17432 cat confdefs.h >>conftest.$ac_ext
17433 cat >>conftest.$ac_ext <<_ACEOF
17434 /* end confdefs.h.  */
17435 $ac_includes_default
17436 int
17437 main ()
17438 {
17439 if (sizeof (uintptr_t))
17440        return 0;
17441   ;
17442   return 0;
17443 }
17444 _ACEOF
17445 rm -f conftest.$ac_objext
17446 if { (ac_try="$ac_compile"
17447 case "(($ac_try" in
17448   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17449   *) ac_try_echo=$ac_try;;
17450 esac
17451 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17452 $as_echo "$ac_try_echo") >&5
17453   (eval "$ac_compile") 2>conftest.er1
17454   ac_status=$?
17455   grep -v '^ *+' conftest.er1 >conftest.err
17456   rm -f conftest.er1
17457   cat conftest.err >&5
17458   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17459   (exit $ac_status); } && {
17460          test -z "$ac_c_werror_flag" ||
17461          test ! -s conftest.err
17462        } && test -s conftest.$ac_objext; then
17463   cat >conftest.$ac_ext <<_ACEOF
17464 /* confdefs.h.  */
17465 _ACEOF
17466 cat confdefs.h >>conftest.$ac_ext
17467 cat >>conftest.$ac_ext <<_ACEOF
17468 /* end confdefs.h.  */
17469 $ac_includes_default
17470 int
17471 main ()
17472 {
17473 if (sizeof ((uintptr_t)))
17474           return 0;
17475   ;
17476   return 0;
17477 }
17478 _ACEOF
17479 rm -f conftest.$ac_objext
17480 if { (ac_try="$ac_compile"
17481 case "(($ac_try" in
17482   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17483   *) ac_try_echo=$ac_try;;
17484 esac
17485 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17486 $as_echo "$ac_try_echo") >&5
17487   (eval "$ac_compile") 2>conftest.er1
17488   ac_status=$?
17489   grep -v '^ *+' conftest.er1 >conftest.err
17490   rm -f conftest.er1
17491   cat conftest.err >&5
17492   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17493   (exit $ac_status); } && {
17494          test -z "$ac_c_werror_flag" ||
17495          test ! -s conftest.err
17496        } && test -s conftest.$ac_objext; then
17497   :
17498 else
17499   $as_echo "$as_me: failed program was:" >&5
17500 sed 's/^/| /' conftest.$ac_ext >&5
17501
17502         ac_cv_type_uintptr_t=yes
17503 fi
17504
17505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17506 else
17507   $as_echo "$as_me: failed program was:" >&5
17508 sed 's/^/| /' conftest.$ac_ext >&5
17509
17510
17511 fi
17512
17513 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17514 fi
17515 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
17516 $as_echo "$ac_cv_type_uintptr_t" >&6; }
17517 if test "x$ac_cv_type_uintptr_t" = x""yes; then
17518
17519 cat >>confdefs.h <<\_ACEOF
17520 #define HAVE_UINTPTR_T 1
17521 _ACEOF
17522
17523 else
17524   for ac_type in 'unsigned int' 'unsigned long int' \
17525         'unsigned long long int'; do
17526        cat >conftest.$ac_ext <<_ACEOF
17527 /* confdefs.h.  */
17528 _ACEOF
17529 cat confdefs.h >>conftest.$ac_ext
17530 cat >>conftest.$ac_ext <<_ACEOF
17531 /* end confdefs.h.  */
17532 $ac_includes_default
17533 int
17534 main ()
17535 {
17536 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
17537 test_array [0] = 0
17538
17539   ;
17540   return 0;
17541 }
17542 _ACEOF
17543 rm -f conftest.$ac_objext
17544 if { (ac_try="$ac_compile"
17545 case "(($ac_try" in
17546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17547   *) ac_try_echo=$ac_try;;
17548 esac
17549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17550 $as_echo "$ac_try_echo") >&5
17551   (eval "$ac_compile") 2>conftest.er1
17552   ac_status=$?
17553   grep -v '^ *+' conftest.er1 >conftest.err
17554   rm -f conftest.er1
17555   cat conftest.err >&5
17556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17557   (exit $ac_status); } && {
17558          test -z "$ac_c_werror_flag" ||
17559          test ! -s conftest.err
17560        } && test -s conftest.$ac_objext; then
17561
17562 cat >>confdefs.h <<_ACEOF
17563 #define uintptr_t $ac_type
17564 _ACEOF
17565
17566           ac_type=
17567 else
17568   $as_echo "$as_me: failed program was:" >&5
17569 sed 's/^/| /' conftest.$ac_ext >&5
17570
17571
17572 fi
17573
17574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17575        test -z "$ac_type" && break
17576      done
17577 fi
17578
17579
17580
17581   { $as_echo "$as_me:$LINENO: checking for long long int" >&5
17582 $as_echo_n "checking for long long int... " >&6; }
17583 if test "${ac_cv_type_long_long_int+set}" = set; then
17584   $as_echo_n "(cached) " >&6
17585 else
17586   cat >conftest.$ac_ext <<_ACEOF
17587
17588   /* confdefs.h.  */
17589 _ACEOF
17590 cat confdefs.h >>conftest.$ac_ext
17591 cat >>conftest.$ac_ext <<_ACEOF
17592 /* end confdefs.h.  */
17593 /* For now, do not test the preprocessor; as of 2007 there are too many
17594          implementations with broken preprocessors.  Perhaps this can
17595          be revisited in 2012.  In the meantime, code should not expect
17596          #if to work with literals wider than 32 bits.  */
17597       /* Test literals.  */
17598       long long int ll = 9223372036854775807ll;
17599       long long int nll = -9223372036854775807LL;
17600       unsigned long long int ull = 18446744073709551615ULL;
17601       /* Test constant expressions.   */
17602       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17603                      ? 1 : -1)];
17604       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17605                      ? 1 : -1)];
17606       int i = 63;
17607 int
17608 main ()
17609 {
17610 /* Test availability of runtime routines for shift and division.  */
17611       long long int llmax = 9223372036854775807ll;
17612       unsigned long long int ullmax = 18446744073709551615ull;
17613       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17614               | (llmax / ll) | (llmax % ll)
17615               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17616               | (ullmax / ull) | (ullmax % ull));
17617   ;
17618   return 0;
17619 }
17620
17621 _ACEOF
17622 rm -f conftest.$ac_objext conftest$ac_exeext
17623 if { (ac_try="$ac_link"
17624 case "(($ac_try" in
17625   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17626   *) ac_try_echo=$ac_try;;
17627 esac
17628 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17629 $as_echo "$ac_try_echo") >&5
17630   (eval "$ac_link") 2>conftest.er1
17631   ac_status=$?
17632   grep -v '^ *+' conftest.er1 >conftest.err
17633   rm -f conftest.er1
17634   cat conftest.err >&5
17635   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17636   (exit $ac_status); } && {
17637          test -z "$ac_c_werror_flag" ||
17638          test ! -s conftest.err
17639        } && test -s conftest$ac_exeext && {
17640          test "$cross_compiling" = yes ||
17641          $as_test_x conftest$ac_exeext
17642        }; then
17643                         if test "$cross_compiling" = yes; then
17644   ac_cv_type_long_long_int=yes
17645 else
17646   cat >conftest.$ac_ext <<_ACEOF
17647 /* confdefs.h.  */
17648 _ACEOF
17649 cat confdefs.h >>conftest.$ac_ext
17650 cat >>conftest.$ac_ext <<_ACEOF
17651 /* end confdefs.h.  */
17652 #include <limits.h>
17653                #ifndef LLONG_MAX
17654                # define HALF \
17655                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17656                # define LLONG_MAX (HALF - 1 + HALF)
17657                #endif
17658 int
17659 main ()
17660 {
17661 long long int n = 1;
17662                int i;
17663                for (i = 0; ; i++)
17664                  {
17665                    long long int m = n << i;
17666                    if (m >> i != n)
17667                      return 1;
17668                    if (LLONG_MAX / 2 < m)
17669                      break;
17670                  }
17671                return 0;
17672   ;
17673   return 0;
17674 }
17675 _ACEOF
17676 rm -f conftest$ac_exeext
17677 if { (ac_try="$ac_link"
17678 case "(($ac_try" in
17679   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17680   *) ac_try_echo=$ac_try;;
17681 esac
17682 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17683 $as_echo "$ac_try_echo") >&5
17684   (eval "$ac_link") 2>&5
17685   ac_status=$?
17686   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17687   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17688   { (case "(($ac_try" in
17689   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17690   *) ac_try_echo=$ac_try;;
17691 esac
17692 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17693 $as_echo "$ac_try_echo") >&5
17694   (eval "$ac_try") 2>&5
17695   ac_status=$?
17696   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17697   (exit $ac_status); }; }; then
17698   ac_cv_type_long_long_int=yes
17699 else
17700   $as_echo "$as_me: program exited with status $ac_status" >&5
17701 $as_echo "$as_me: failed program was:" >&5
17702 sed 's/^/| /' conftest.$ac_ext >&5
17703
17704 ( exit $ac_status )
17705 ac_cv_type_long_long_int=no
17706 fi
17707 rm -rf conftest.dSYM
17708 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17709 fi
17710
17711
17712 else
17713   $as_echo "$as_me: failed program was:" >&5
17714 sed 's/^/| /' conftest.$ac_ext >&5
17715
17716         ac_cv_type_long_long_int=no
17717 fi
17718
17719 rm -rf conftest.dSYM
17720 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17721       conftest$ac_exeext conftest.$ac_ext
17722 fi
17723 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
17724 $as_echo "$ac_cv_type_long_long_int" >&6; }
17725   if test $ac_cv_type_long_long_int = yes; then
17726
17727 cat >>confdefs.h <<\_ACEOF
17728 #define HAVE_LONG_LONG_INT 1
17729 _ACEOF
17730
17731   fi
17732
17733
17734 { $as_echo "$as_me:$LINENO: checking for locale_t" >&5
17735 $as_echo_n "checking for locale_t... " >&6; }
17736 if test "${pgac_cv_type_locale_t+set}" = set; then
17737   $as_echo_n "(cached) " >&6
17738 else
17739   cat >conftest.$ac_ext <<_ACEOF
17740 /* confdefs.h.  */
17741 _ACEOF
17742 cat confdefs.h >>conftest.$ac_ext
17743 cat >>conftest.$ac_ext <<_ACEOF
17744 /* end confdefs.h.  */
17745 #include <locale.h>
17746 locale_t x;
17747 int
17748 main ()
17749 {
17750
17751   ;
17752   return 0;
17753 }
17754 _ACEOF
17755 rm -f conftest.$ac_objext
17756 if { (ac_try="$ac_compile"
17757 case "(($ac_try" in
17758   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17759   *) ac_try_echo=$ac_try;;
17760 esac
17761 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17762 $as_echo "$ac_try_echo") >&5
17763   (eval "$ac_compile") 2>conftest.er1
17764   ac_status=$?
17765   grep -v '^ *+' conftest.er1 >conftest.err
17766   rm -f conftest.er1
17767   cat conftest.err >&5
17768   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17769   (exit $ac_status); } && {
17770          test -z "$ac_c_werror_flag" ||
17771          test ! -s conftest.err
17772        } && test -s conftest.$ac_objext; then
17773   pgac_cv_type_locale_t=yes
17774 else
17775   $as_echo "$as_me: failed program was:" >&5
17776 sed 's/^/| /' conftest.$ac_ext >&5
17777
17778         cat >conftest.$ac_ext <<_ACEOF
17779 /* confdefs.h.  */
17780 _ACEOF
17781 cat confdefs.h >>conftest.$ac_ext
17782 cat >>conftest.$ac_ext <<_ACEOF
17783 /* end confdefs.h.  */
17784 #include <xlocale.h>
17785 locale_t x;
17786 int
17787 main ()
17788 {
17789
17790   ;
17791   return 0;
17792 }
17793 _ACEOF
17794 rm -f conftest.$ac_objext
17795 if { (ac_try="$ac_compile"
17796 case "(($ac_try" in
17797   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17798   *) ac_try_echo=$ac_try;;
17799 esac
17800 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17801 $as_echo "$ac_try_echo") >&5
17802   (eval "$ac_compile") 2>conftest.er1
17803   ac_status=$?
17804   grep -v '^ *+' conftest.er1 >conftest.err
17805   rm -f conftest.er1
17806   cat conftest.err >&5
17807   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17808   (exit $ac_status); } && {
17809          test -z "$ac_c_werror_flag" ||
17810          test ! -s conftest.err
17811        } && test -s conftest.$ac_objext; then
17812   pgac_cv_type_locale_t='yes (in xlocale.h)'
17813 else
17814   $as_echo "$as_me: failed program was:" >&5
17815 sed 's/^/| /' conftest.$ac_ext >&5
17816
17817         pgac_cv_type_locale_t=no
17818 fi
17819
17820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17821 fi
17822
17823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17824 fi
17825 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_locale_t" >&5
17826 $as_echo "$pgac_cv_type_locale_t" >&6; }
17827 if test "$pgac_cv_type_locale_t" != no; then
17828
17829 cat >>confdefs.h <<\_ACEOF
17830 #define HAVE_LOCALE_T 1
17831 _ACEOF
17832
17833 fi
17834 if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then
17835
17836 cat >>confdefs.h <<\_ACEOF
17837 #define LOCALE_T_IN_XLOCALE 1
17838 _ACEOF
17839
17840 fi
17841
17842 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
17843 $as_echo_n "checking for struct cmsgcred... " >&6; }
17844 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
17845   $as_echo_n "(cached) " >&6
17846 else
17847   ac_cv_type_struct_cmsgcred=no
17848 cat >conftest.$ac_ext <<_ACEOF
17849 /* confdefs.h.  */
17850 _ACEOF
17851 cat confdefs.h >>conftest.$ac_ext
17852 cat >>conftest.$ac_ext <<_ACEOF
17853 /* end confdefs.h.  */
17854 #include <sys/socket.h>
17855 #include <sys/param.h>
17856 #ifdef HAVE_SYS_UCRED_H
17857 #include <sys/ucred.h>
17858 #endif
17859
17860 int
17861 main ()
17862 {
17863 if (sizeof (struct cmsgcred))
17864        return 0;
17865   ;
17866   return 0;
17867 }
17868 _ACEOF
17869 rm -f conftest.$ac_objext
17870 if { (ac_try="$ac_compile"
17871 case "(($ac_try" in
17872   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17873   *) ac_try_echo=$ac_try;;
17874 esac
17875 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17876 $as_echo "$ac_try_echo") >&5
17877   (eval "$ac_compile") 2>conftest.er1
17878   ac_status=$?
17879   grep -v '^ *+' conftest.er1 >conftest.err
17880   rm -f conftest.er1
17881   cat conftest.err >&5
17882   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17883   (exit $ac_status); } && {
17884          test -z "$ac_c_werror_flag" ||
17885          test ! -s conftest.err
17886        } && test -s conftest.$ac_objext; then
17887   cat >conftest.$ac_ext <<_ACEOF
17888 /* confdefs.h.  */
17889 _ACEOF
17890 cat confdefs.h >>conftest.$ac_ext
17891 cat >>conftest.$ac_ext <<_ACEOF
17892 /* end confdefs.h.  */
17893 #include <sys/socket.h>
17894 #include <sys/param.h>
17895 #ifdef HAVE_SYS_UCRED_H
17896 #include <sys/ucred.h>
17897 #endif
17898
17899 int
17900 main ()
17901 {
17902 if (sizeof ((struct cmsgcred)))
17903           return 0;
17904   ;
17905   return 0;
17906 }
17907 _ACEOF
17908 rm -f conftest.$ac_objext
17909 if { (ac_try="$ac_compile"
17910 case "(($ac_try" in
17911   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17912   *) ac_try_echo=$ac_try;;
17913 esac
17914 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17915 $as_echo "$ac_try_echo") >&5
17916   (eval "$ac_compile") 2>conftest.er1
17917   ac_status=$?
17918   grep -v '^ *+' conftest.er1 >conftest.err
17919   rm -f conftest.er1
17920   cat conftest.err >&5
17921   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17922   (exit $ac_status); } && {
17923          test -z "$ac_c_werror_flag" ||
17924          test ! -s conftest.err
17925        } && test -s conftest.$ac_objext; then
17926   :
17927 else
17928   $as_echo "$as_me: failed program was:" >&5
17929 sed 's/^/| /' conftest.$ac_ext >&5
17930
17931         ac_cv_type_struct_cmsgcred=yes
17932 fi
17933
17934 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17935 else
17936   $as_echo "$as_me: failed program was:" >&5
17937 sed 's/^/| /' conftest.$ac_ext >&5
17938
17939
17940 fi
17941
17942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17943 fi
17944 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
17945 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
17946 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
17947
17948 cat >>confdefs.h <<_ACEOF
17949 #define HAVE_STRUCT_CMSGCRED 1
17950 _ACEOF
17951
17952
17953 fi
17954
17955
17956 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
17957 $as_echo_n "checking for struct option... " >&6; }
17958 if test "${ac_cv_type_struct_option+set}" = set; then
17959   $as_echo_n "(cached) " >&6
17960 else
17961   ac_cv_type_struct_option=no
17962 cat >conftest.$ac_ext <<_ACEOF
17963 /* confdefs.h.  */
17964 _ACEOF
17965 cat confdefs.h >>conftest.$ac_ext
17966 cat >>conftest.$ac_ext <<_ACEOF
17967 /* end confdefs.h.  */
17968 #ifdef HAVE_GETOPT_H
17969 #include <getopt.h>
17970 #endif
17971
17972 int
17973 main ()
17974 {
17975 if (sizeof (struct option))
17976        return 0;
17977   ;
17978   return 0;
17979 }
17980 _ACEOF
17981 rm -f conftest.$ac_objext
17982 if { (ac_try="$ac_compile"
17983 case "(($ac_try" in
17984   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17985   *) ac_try_echo=$ac_try;;
17986 esac
17987 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17988 $as_echo "$ac_try_echo") >&5
17989   (eval "$ac_compile") 2>conftest.er1
17990   ac_status=$?
17991   grep -v '^ *+' conftest.er1 >conftest.err
17992   rm -f conftest.er1
17993   cat conftest.err >&5
17994   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17995   (exit $ac_status); } && {
17996          test -z "$ac_c_werror_flag" ||
17997          test ! -s conftest.err
17998        } && test -s conftest.$ac_objext; then
17999   cat >conftest.$ac_ext <<_ACEOF
18000 /* confdefs.h.  */
18001 _ACEOF
18002 cat confdefs.h >>conftest.$ac_ext
18003 cat >>conftest.$ac_ext <<_ACEOF
18004 /* end confdefs.h.  */
18005 #ifdef HAVE_GETOPT_H
18006 #include <getopt.h>
18007 #endif
18008
18009 int
18010 main ()
18011 {
18012 if (sizeof ((struct option)))
18013           return 0;
18014   ;
18015   return 0;
18016 }
18017 _ACEOF
18018 rm -f conftest.$ac_objext
18019 if { (ac_try="$ac_compile"
18020 case "(($ac_try" in
18021   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18022   *) ac_try_echo=$ac_try;;
18023 esac
18024 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18025 $as_echo "$ac_try_echo") >&5
18026   (eval "$ac_compile") 2>conftest.er1
18027   ac_status=$?
18028   grep -v '^ *+' conftest.er1 >conftest.err
18029   rm -f conftest.er1
18030   cat conftest.err >&5
18031   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18032   (exit $ac_status); } && {
18033          test -z "$ac_c_werror_flag" ||
18034          test ! -s conftest.err
18035        } && test -s conftest.$ac_objext; then
18036   :
18037 else
18038   $as_echo "$as_me: failed program was:" >&5
18039 sed 's/^/| /' conftest.$ac_ext >&5
18040
18041         ac_cv_type_struct_option=yes
18042 fi
18043
18044 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18045 else
18046   $as_echo "$as_me: failed program was:" >&5
18047 sed 's/^/| /' conftest.$ac_ext >&5
18048
18049
18050 fi
18051
18052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18053 fi
18054 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
18055 $as_echo "$ac_cv_type_struct_option" >&6; }
18056 if test "x$ac_cv_type_struct_option" = x""yes; then
18057
18058 cat >>confdefs.h <<_ACEOF
18059 #define HAVE_STRUCT_OPTION 1
18060 _ACEOF
18061
18062
18063 fi
18064
18065
18066 if test "$with_zlib" = yes; then
18067   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
18068   # did not).  While we could work around the lack of z_streamp, it
18069   # seems unwise to encourage people to use such old zlib versions...
18070   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
18071 $as_echo_n "checking for z_streamp... " >&6; }
18072 if test "${ac_cv_type_z_streamp+set}" = set; then
18073   $as_echo_n "(cached) " >&6
18074 else
18075   ac_cv_type_z_streamp=no
18076 cat >conftest.$ac_ext <<_ACEOF
18077 /* confdefs.h.  */
18078 _ACEOF
18079 cat confdefs.h >>conftest.$ac_ext
18080 cat >>conftest.$ac_ext <<_ACEOF
18081 /* end confdefs.h.  */
18082 #include <zlib.h>
18083
18084 int
18085 main ()
18086 {
18087 if (sizeof (z_streamp))
18088        return 0;
18089   ;
18090   return 0;
18091 }
18092 _ACEOF
18093 rm -f conftest.$ac_objext
18094 if { (ac_try="$ac_compile"
18095 case "(($ac_try" in
18096   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18097   *) ac_try_echo=$ac_try;;
18098 esac
18099 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18100 $as_echo "$ac_try_echo") >&5
18101   (eval "$ac_compile") 2>conftest.er1
18102   ac_status=$?
18103   grep -v '^ *+' conftest.er1 >conftest.err
18104   rm -f conftest.er1
18105   cat conftest.err >&5
18106   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18107   (exit $ac_status); } && {
18108          test -z "$ac_c_werror_flag" ||
18109          test ! -s conftest.err
18110        } && test -s conftest.$ac_objext; then
18111   cat >conftest.$ac_ext <<_ACEOF
18112 /* confdefs.h.  */
18113 _ACEOF
18114 cat confdefs.h >>conftest.$ac_ext
18115 cat >>conftest.$ac_ext <<_ACEOF
18116 /* end confdefs.h.  */
18117 #include <zlib.h>
18118
18119 int
18120 main ()
18121 {
18122 if (sizeof ((z_streamp)))
18123           return 0;
18124   ;
18125   return 0;
18126 }
18127 _ACEOF
18128 rm -f conftest.$ac_objext
18129 if { (ac_try="$ac_compile"
18130 case "(($ac_try" in
18131   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18132   *) ac_try_echo=$ac_try;;
18133 esac
18134 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18135 $as_echo "$ac_try_echo") >&5
18136   (eval "$ac_compile") 2>conftest.er1
18137   ac_status=$?
18138   grep -v '^ *+' conftest.er1 >conftest.err
18139   rm -f conftest.er1
18140   cat conftest.err >&5
18141   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18142   (exit $ac_status); } && {
18143          test -z "$ac_c_werror_flag" ||
18144          test ! -s conftest.err
18145        } && test -s conftest.$ac_objext; then
18146   :
18147 else
18148   $as_echo "$as_me: failed program was:" >&5
18149 sed 's/^/| /' conftest.$ac_ext >&5
18150
18151         ac_cv_type_z_streamp=yes
18152 fi
18153
18154 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18155 else
18156   $as_echo "$as_me: failed program was:" >&5
18157 sed 's/^/| /' conftest.$ac_ext >&5
18158
18159
18160 fi
18161
18162 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18163 fi
18164 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
18165 $as_echo "$ac_cv_type_z_streamp" >&6; }
18166 if test "x$ac_cv_type_z_streamp" = x""yes; then
18167   :
18168 else
18169   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
18170 Use --without-zlib to disable zlib support." >&5
18171 $as_echo "$as_me: error: zlib version is too old
18172 Use --without-zlib to disable zlib support." >&2;}
18173    { (exit 1); exit 1; }; }
18174 fi
18175
18176 fi
18177
18178 if test "$with_krb5" = yes; then
18179 # Check for differences between MIT and Heimdal (KTH) releases
18180   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
18181 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
18182 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
18183   $as_echo_n "(cached) " >&6
18184 else
18185   cat >conftest.$ac_ext <<_ACEOF
18186 /* confdefs.h.  */
18187 _ACEOF
18188 cat confdefs.h >>conftest.$ac_ext
18189 cat >>conftest.$ac_ext <<_ACEOF
18190 /* end confdefs.h.  */
18191 #include <krb5.h>
18192
18193 int
18194 main ()
18195 {
18196 static krb5_ticket ac_aggr;
18197 if (ac_aggr.enc_part2)
18198 return 0;
18199   ;
18200   return 0;
18201 }
18202 _ACEOF
18203 rm -f conftest.$ac_objext
18204 if { (ac_try="$ac_compile"
18205 case "(($ac_try" in
18206   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18207   *) ac_try_echo=$ac_try;;
18208 esac
18209 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18210 $as_echo "$ac_try_echo") >&5
18211   (eval "$ac_compile") 2>conftest.er1
18212   ac_status=$?
18213   grep -v '^ *+' conftest.er1 >conftest.err
18214   rm -f conftest.er1
18215   cat conftest.err >&5
18216   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18217   (exit $ac_status); } && {
18218          test -z "$ac_c_werror_flag" ||
18219          test ! -s conftest.err
18220        } && test -s conftest.$ac_objext; then
18221   ac_cv_member_krb5_ticket_enc_part2=yes
18222 else
18223   $as_echo "$as_me: failed program was:" >&5
18224 sed 's/^/| /' conftest.$ac_ext >&5
18225
18226         cat >conftest.$ac_ext <<_ACEOF
18227 /* confdefs.h.  */
18228 _ACEOF
18229 cat confdefs.h >>conftest.$ac_ext
18230 cat >>conftest.$ac_ext <<_ACEOF
18231 /* end confdefs.h.  */
18232 #include <krb5.h>
18233
18234 int
18235 main ()
18236 {
18237 static krb5_ticket ac_aggr;
18238 if (sizeof ac_aggr.enc_part2)
18239 return 0;
18240   ;
18241   return 0;
18242 }
18243 _ACEOF
18244 rm -f conftest.$ac_objext
18245 if { (ac_try="$ac_compile"
18246 case "(($ac_try" in
18247   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18248   *) ac_try_echo=$ac_try;;
18249 esac
18250 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18251 $as_echo "$ac_try_echo") >&5
18252   (eval "$ac_compile") 2>conftest.er1
18253   ac_status=$?
18254   grep -v '^ *+' conftest.er1 >conftest.err
18255   rm -f conftest.er1
18256   cat conftest.err >&5
18257   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18258   (exit $ac_status); } && {
18259          test -z "$ac_c_werror_flag" ||
18260          test ! -s conftest.err
18261        } && test -s conftest.$ac_objext; then
18262   ac_cv_member_krb5_ticket_enc_part2=yes
18263 else
18264   $as_echo "$as_me: failed program was:" >&5
18265 sed 's/^/| /' conftest.$ac_ext >&5
18266
18267         ac_cv_member_krb5_ticket_enc_part2=no
18268 fi
18269
18270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18271 fi
18272
18273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18274 fi
18275 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
18276 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
18277 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
18278
18279 cat >>confdefs.h <<_ACEOF
18280 #define HAVE_KRB5_TICKET_ENC_PART2 1
18281 _ACEOF
18282
18283
18284 else
18285   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
18286 $as_echo_n "checking for krb5_ticket.client... " >&6; }
18287 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
18288   $as_echo_n "(cached) " >&6
18289 else
18290   cat >conftest.$ac_ext <<_ACEOF
18291 /* confdefs.h.  */
18292 _ACEOF
18293 cat confdefs.h >>conftest.$ac_ext
18294 cat >>conftest.$ac_ext <<_ACEOF
18295 /* end confdefs.h.  */
18296 #include <krb5.h>
18297
18298 int
18299 main ()
18300 {
18301 static krb5_ticket ac_aggr;
18302 if (ac_aggr.client)
18303 return 0;
18304   ;
18305   return 0;
18306 }
18307 _ACEOF
18308 rm -f conftest.$ac_objext
18309 if { (ac_try="$ac_compile"
18310 case "(($ac_try" in
18311   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18312   *) ac_try_echo=$ac_try;;
18313 esac
18314 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18315 $as_echo "$ac_try_echo") >&5
18316   (eval "$ac_compile") 2>conftest.er1
18317   ac_status=$?
18318   grep -v '^ *+' conftest.er1 >conftest.err
18319   rm -f conftest.er1
18320   cat conftest.err >&5
18321   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18322   (exit $ac_status); } && {
18323          test -z "$ac_c_werror_flag" ||
18324          test ! -s conftest.err
18325        } && test -s conftest.$ac_objext; then
18326   ac_cv_member_krb5_ticket_client=yes
18327 else
18328   $as_echo "$as_me: failed program was:" >&5
18329 sed 's/^/| /' conftest.$ac_ext >&5
18330
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 #include <krb5.h>
18338
18339 int
18340 main ()
18341 {
18342 static krb5_ticket ac_aggr;
18343 if (sizeof ac_aggr.client)
18344 return 0;
18345   ;
18346   return 0;
18347 }
18348 _ACEOF
18349 rm -f conftest.$ac_objext
18350 if { (ac_try="$ac_compile"
18351 case "(($ac_try" in
18352   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18353   *) ac_try_echo=$ac_try;;
18354 esac
18355 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18356 $as_echo "$ac_try_echo") >&5
18357   (eval "$ac_compile") 2>conftest.er1
18358   ac_status=$?
18359   grep -v '^ *+' conftest.er1 >conftest.err
18360   rm -f conftest.er1
18361   cat conftest.err >&5
18362   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18363   (exit $ac_status); } && {
18364          test -z "$ac_c_werror_flag" ||
18365          test ! -s conftest.err
18366        } && test -s conftest.$ac_objext; then
18367   ac_cv_member_krb5_ticket_client=yes
18368 else
18369   $as_echo "$as_me: failed program was:" >&5
18370 sed 's/^/| /' conftest.$ac_ext >&5
18371
18372         ac_cv_member_krb5_ticket_client=no
18373 fi
18374
18375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18376 fi
18377
18378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18379 fi
18380 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
18381 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
18382 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
18383
18384 cat >>confdefs.h <<_ACEOF
18385 #define HAVE_KRB5_TICKET_CLIENT 1
18386 _ACEOF
18387
18388
18389 else
18390   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
18391 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
18392    { (exit 1); exit 1; }; }
18393 fi
18394
18395 fi
18396
18397   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
18398 $as_echo_n "checking for krb5_error.text.data... " >&6; }
18399 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
18400   $as_echo_n "(cached) " >&6
18401 else
18402   cat >conftest.$ac_ext <<_ACEOF
18403 /* confdefs.h.  */
18404 _ACEOF
18405 cat confdefs.h >>conftest.$ac_ext
18406 cat >>conftest.$ac_ext <<_ACEOF
18407 /* end confdefs.h.  */
18408 #include <krb5.h>
18409
18410 int
18411 main ()
18412 {
18413 static krb5_error ac_aggr;
18414 if (ac_aggr.text.data)
18415 return 0;
18416   ;
18417   return 0;
18418 }
18419 _ACEOF
18420 rm -f conftest.$ac_objext
18421 if { (ac_try="$ac_compile"
18422 case "(($ac_try" in
18423   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18424   *) ac_try_echo=$ac_try;;
18425 esac
18426 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18427 $as_echo "$ac_try_echo") >&5
18428   (eval "$ac_compile") 2>conftest.er1
18429   ac_status=$?
18430   grep -v '^ *+' conftest.er1 >conftest.err
18431   rm -f conftest.er1
18432   cat conftest.err >&5
18433   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18434   (exit $ac_status); } && {
18435          test -z "$ac_c_werror_flag" ||
18436          test ! -s conftest.err
18437        } && test -s conftest.$ac_objext; then
18438   ac_cv_member_krb5_error_text_data=yes
18439 else
18440   $as_echo "$as_me: failed program was:" >&5
18441 sed 's/^/| /' conftest.$ac_ext >&5
18442
18443         cat >conftest.$ac_ext <<_ACEOF
18444 /* confdefs.h.  */
18445 _ACEOF
18446 cat confdefs.h >>conftest.$ac_ext
18447 cat >>conftest.$ac_ext <<_ACEOF
18448 /* end confdefs.h.  */
18449 #include <krb5.h>
18450
18451 int
18452 main ()
18453 {
18454 static krb5_error ac_aggr;
18455 if (sizeof ac_aggr.text.data)
18456 return 0;
18457   ;
18458   return 0;
18459 }
18460 _ACEOF
18461 rm -f conftest.$ac_objext
18462 if { (ac_try="$ac_compile"
18463 case "(($ac_try" in
18464   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18465   *) ac_try_echo=$ac_try;;
18466 esac
18467 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18468 $as_echo "$ac_try_echo") >&5
18469   (eval "$ac_compile") 2>conftest.er1
18470   ac_status=$?
18471   grep -v '^ *+' conftest.er1 >conftest.err
18472   rm -f conftest.er1
18473   cat conftest.err >&5
18474   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18475   (exit $ac_status); } && {
18476          test -z "$ac_c_werror_flag" ||
18477          test ! -s conftest.err
18478        } && test -s conftest.$ac_objext; then
18479   ac_cv_member_krb5_error_text_data=yes
18480 else
18481   $as_echo "$as_me: failed program was:" >&5
18482 sed 's/^/| /' conftest.$ac_ext >&5
18483
18484         ac_cv_member_krb5_error_text_data=no
18485 fi
18486
18487 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18488 fi
18489
18490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18491 fi
18492 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
18493 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
18494 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
18495
18496 cat >>confdefs.h <<_ACEOF
18497 #define HAVE_KRB5_ERROR_TEXT_DATA 1
18498 _ACEOF
18499
18500
18501 else
18502   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
18503 $as_echo_n "checking for krb5_error.e_data... " >&6; }
18504 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
18505   $as_echo_n "(cached) " >&6
18506 else
18507   cat >conftest.$ac_ext <<_ACEOF
18508 /* confdefs.h.  */
18509 _ACEOF
18510 cat confdefs.h >>conftest.$ac_ext
18511 cat >>conftest.$ac_ext <<_ACEOF
18512 /* end confdefs.h.  */
18513 #include <krb5.h>
18514
18515 int
18516 main ()
18517 {
18518 static krb5_error ac_aggr;
18519 if (ac_aggr.e_data)
18520 return 0;
18521   ;
18522   return 0;
18523 }
18524 _ACEOF
18525 rm -f conftest.$ac_objext
18526 if { (ac_try="$ac_compile"
18527 case "(($ac_try" in
18528   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18529   *) ac_try_echo=$ac_try;;
18530 esac
18531 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18532 $as_echo "$ac_try_echo") >&5
18533   (eval "$ac_compile") 2>conftest.er1
18534   ac_status=$?
18535   grep -v '^ *+' conftest.er1 >conftest.err
18536   rm -f conftest.er1
18537   cat conftest.err >&5
18538   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18539   (exit $ac_status); } && {
18540          test -z "$ac_c_werror_flag" ||
18541          test ! -s conftest.err
18542        } && test -s conftest.$ac_objext; then
18543   ac_cv_member_krb5_error_e_data=yes
18544 else
18545   $as_echo "$as_me: failed program was:" >&5
18546 sed 's/^/| /' conftest.$ac_ext >&5
18547
18548         cat >conftest.$ac_ext <<_ACEOF
18549 /* confdefs.h.  */
18550 _ACEOF
18551 cat confdefs.h >>conftest.$ac_ext
18552 cat >>conftest.$ac_ext <<_ACEOF
18553 /* end confdefs.h.  */
18554 #include <krb5.h>
18555
18556 int
18557 main ()
18558 {
18559 static krb5_error ac_aggr;
18560 if (sizeof ac_aggr.e_data)
18561 return 0;
18562   ;
18563   return 0;
18564 }
18565 _ACEOF
18566 rm -f conftest.$ac_objext
18567 if { (ac_try="$ac_compile"
18568 case "(($ac_try" in
18569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18570   *) ac_try_echo=$ac_try;;
18571 esac
18572 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18573 $as_echo "$ac_try_echo") >&5
18574   (eval "$ac_compile") 2>conftest.er1
18575   ac_status=$?
18576   grep -v '^ *+' conftest.er1 >conftest.err
18577   rm -f conftest.er1
18578   cat conftest.err >&5
18579   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18580   (exit $ac_status); } && {
18581          test -z "$ac_c_werror_flag" ||
18582          test ! -s conftest.err
18583        } && test -s conftest.$ac_objext; then
18584   ac_cv_member_krb5_error_e_data=yes
18585 else
18586   $as_echo "$as_me: failed program was:" >&5
18587 sed 's/^/| /' conftest.$ac_ext >&5
18588
18589         ac_cv_member_krb5_error_e_data=no
18590 fi
18591
18592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18593 fi
18594
18595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18596 fi
18597 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
18598 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
18599 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
18600
18601 cat >>confdefs.h <<_ACEOF
18602 #define HAVE_KRB5_ERROR_E_DATA 1
18603 _ACEOF
18604
18605
18606 else
18607   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
18608 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
18609    { (exit 1); exit 1; }; }
18610 fi
18611
18612 fi
18613
18614
18615 # Win32 requires headers to be loaded for __stdcall, so can't use
18616 # AC_CHECK_FUNCS here.
18617   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
18618 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
18619   cat >conftest.$ac_ext <<_ACEOF
18620 /* confdefs.h.  */
18621 _ACEOF
18622 cat confdefs.h >>conftest.$ac_ext
18623 cat >>conftest.$ac_ext <<_ACEOF
18624 /* end confdefs.h.  */
18625 #include <krb5.h>
18626 int
18627 main ()
18628 {
18629 krb5_free_unparsed_name(NULL,NULL);
18630   ;
18631   return 0;
18632 }
18633 _ACEOF
18634 rm -f conftest.$ac_objext conftest$ac_exeext
18635 if { (ac_try="$ac_link"
18636 case "(($ac_try" in
18637   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18638   *) ac_try_echo=$ac_try;;
18639 esac
18640 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18641 $as_echo "$ac_try_echo") >&5
18642   (eval "$ac_link") 2>conftest.er1
18643   ac_status=$?
18644   grep -v '^ *+' conftest.er1 >conftest.err
18645   rm -f conftest.er1
18646   cat conftest.err >&5
18647   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18648   (exit $ac_status); } && {
18649          test -z "$ac_c_werror_flag" ||
18650          test ! -s conftest.err
18651        } && test -s conftest$ac_exeext && {
18652          test "$cross_compiling" = yes ||
18653          $as_test_x conftest$ac_exeext
18654        }; then
18655
18656 cat >>confdefs.h <<\_ACEOF
18657 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
18658 _ACEOF
18659
18660 { $as_echo "$as_me:$LINENO: result: yes" >&5
18661 $as_echo "yes" >&6; }
18662 else
18663   $as_echo "$as_me: failed program was:" >&5
18664 sed 's/^/| /' conftest.$ac_ext >&5
18665
18666         { $as_echo "$as_me:$LINENO: result: no" >&5
18667 $as_echo "no" >&6; }
18668 fi
18669
18670 rm -rf conftest.dSYM
18671 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18672       conftest$ac_exeext conftest.$ac_ext
18673 fi
18674
18675 # On PPC, check if assembler supports LWARX instruction's mutex hint bit
18676 case $host_cpu in
18677   ppc*|powerpc*)
18678     { $as_echo "$as_me:$LINENO: checking whether assembler supports lwarx hint bit" >&5
18679 $as_echo_n "checking whether assembler supports lwarx hint bit... " >&6; }
18680     cat >conftest.$ac_ext <<_ACEOF
18681 /* confdefs.h.  */
18682 _ACEOF
18683 cat confdefs.h >>conftest.$ac_ext
18684 cat >>conftest.$ac_ext <<_ACEOF
18685 /* end confdefs.h.  */
18686
18687 int
18688 main ()
18689 {
18690 int a = 0; int *p = &a; int r;
18691          __asm__ __volatile__ (" lwarx %0,0,%1,1\n" : "=&r"(r) : "r"(p));
18692   ;
18693   return 0;
18694 }
18695 _ACEOF
18696 rm -f conftest.$ac_objext
18697 if { (ac_try="$ac_compile"
18698 case "(($ac_try" in
18699   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18700   *) ac_try_echo=$ac_try;;
18701 esac
18702 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18703 $as_echo "$ac_try_echo") >&5
18704   (eval "$ac_compile") 2>conftest.er1
18705   ac_status=$?
18706   grep -v '^ *+' conftest.er1 >conftest.err
18707   rm -f conftest.er1
18708   cat conftest.err >&5
18709   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18710   (exit $ac_status); } && {
18711          test -z "$ac_c_werror_flag" ||
18712          test ! -s conftest.err
18713        } && test -s conftest.$ac_objext; then
18714   pgac_cv_have_ppc_mutex_hint=yes
18715 else
18716   $as_echo "$as_me: failed program was:" >&5
18717 sed 's/^/| /' conftest.$ac_ext >&5
18718
18719         pgac_cv_have_ppc_mutex_hint=no
18720 fi
18721
18722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18723     { $as_echo "$as_me:$LINENO: result: $pgac_cv_have_ppc_mutex_hint" >&5
18724 $as_echo "$pgac_cv_have_ppc_mutex_hint" >&6; }
18725     if test x"$pgac_cv_have_ppc_mutex_hint" = xyes ; then
18726
18727 cat >>confdefs.h <<\_ACEOF
18728 #define HAVE_PPC_LWARX_MUTEX_HINT 1
18729 _ACEOF
18730
18731     fi
18732   ;;
18733 esac
18734
18735 # Check largefile support.  You might think this is a system service not a
18736 # compiler characteristic, but you'd be wrong.  We must check this before
18737 # probing existence of related functions such as fseeko, since the largefile
18738 # defines can affect what is generated for that.
18739 if test "$PORTNAME" != "win32"; then
18740    # Check whether --enable-largefile was given.
18741 if test "${enable_largefile+set}" = set; then
18742   enableval=$enable_largefile;
18743 fi
18744
18745 if test "$enable_largefile" != no; then
18746
18747   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
18748 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
18749 if test "${ac_cv_sys_largefile_CC+set}" = set; then
18750   $as_echo_n "(cached) " >&6
18751 else
18752   ac_cv_sys_largefile_CC=no
18753      if test "$GCC" != yes; then
18754        ac_save_CC=$CC
18755        while :; do
18756          # IRIX 6.2 and later do not support large files by default,
18757          # so use the C compiler's -n32 option if that helps.
18758          cat >conftest.$ac_ext <<_ACEOF
18759 /* confdefs.h.  */
18760 _ACEOF
18761 cat confdefs.h >>conftest.$ac_ext
18762 cat >>conftest.$ac_ext <<_ACEOF
18763 /* end confdefs.h.  */
18764 #include <sys/types.h>
18765  /* Check that off_t can represent 2**63 - 1 correctly.
18766     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18767     since some C++ compilers masquerading as C compilers
18768     incorrectly reject 9223372036854775807.  */
18769 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18770   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18771                        && LARGE_OFF_T % 2147483647 == 1)
18772                       ? 1 : -1];
18773 int
18774 main ()
18775 {
18776
18777   ;
18778   return 0;
18779 }
18780 _ACEOF
18781          rm -f conftest.$ac_objext
18782 if { (ac_try="$ac_compile"
18783 case "(($ac_try" in
18784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18785   *) ac_try_echo=$ac_try;;
18786 esac
18787 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18788 $as_echo "$ac_try_echo") >&5
18789   (eval "$ac_compile") 2>conftest.er1
18790   ac_status=$?
18791   grep -v '^ *+' conftest.er1 >conftest.err
18792   rm -f conftest.er1
18793   cat conftest.err >&5
18794   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18795   (exit $ac_status); } && {
18796          test -z "$ac_c_werror_flag" ||
18797          test ! -s conftest.err
18798        } && test -s conftest.$ac_objext; then
18799   break
18800 else
18801   $as_echo "$as_me: failed program was:" >&5
18802 sed 's/^/| /' conftest.$ac_ext >&5
18803
18804
18805 fi
18806
18807 rm -f core conftest.err conftest.$ac_objext
18808          CC="$CC -n32"
18809          rm -f conftest.$ac_objext
18810 if { (ac_try="$ac_compile"
18811 case "(($ac_try" in
18812   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18813   *) ac_try_echo=$ac_try;;
18814 esac
18815 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18816 $as_echo "$ac_try_echo") >&5
18817   (eval "$ac_compile") 2>conftest.er1
18818   ac_status=$?
18819   grep -v '^ *+' conftest.er1 >conftest.err
18820   rm -f conftest.er1
18821   cat conftest.err >&5
18822   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18823   (exit $ac_status); } && {
18824          test -z "$ac_c_werror_flag" ||
18825          test ! -s conftest.err
18826        } && test -s conftest.$ac_objext; then
18827   ac_cv_sys_largefile_CC=' -n32'; break
18828 else
18829   $as_echo "$as_me: failed program was:" >&5
18830 sed 's/^/| /' conftest.$ac_ext >&5
18831
18832
18833 fi
18834
18835 rm -f core conftest.err conftest.$ac_objext
18836          break
18837        done
18838        CC=$ac_save_CC
18839        rm -f conftest.$ac_ext
18840     fi
18841 fi
18842 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
18843 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
18844   if test "$ac_cv_sys_largefile_CC" != no; then
18845     CC=$CC$ac_cv_sys_largefile_CC
18846   fi
18847
18848   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
18849 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
18850 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
18851   $as_echo_n "(cached) " >&6
18852 else
18853   while :; do
18854   cat >conftest.$ac_ext <<_ACEOF
18855 /* confdefs.h.  */
18856 _ACEOF
18857 cat confdefs.h >>conftest.$ac_ext
18858 cat >>conftest.$ac_ext <<_ACEOF
18859 /* end confdefs.h.  */
18860 #include <sys/types.h>
18861  /* Check that off_t can represent 2**63 - 1 correctly.
18862     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18863     since some C++ compilers masquerading as C compilers
18864     incorrectly reject 9223372036854775807.  */
18865 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18866   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18867                        && LARGE_OFF_T % 2147483647 == 1)
18868                       ? 1 : -1];
18869 int
18870 main ()
18871 {
18872
18873   ;
18874   return 0;
18875 }
18876 _ACEOF
18877 rm -f conftest.$ac_objext
18878 if { (ac_try="$ac_compile"
18879 case "(($ac_try" in
18880   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18881   *) ac_try_echo=$ac_try;;
18882 esac
18883 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18884 $as_echo "$ac_try_echo") >&5
18885   (eval "$ac_compile") 2>conftest.er1
18886   ac_status=$?
18887   grep -v '^ *+' conftest.er1 >conftest.err
18888   rm -f conftest.er1
18889   cat conftest.err >&5
18890   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18891   (exit $ac_status); } && {
18892          test -z "$ac_c_werror_flag" ||
18893          test ! -s conftest.err
18894        } && test -s conftest.$ac_objext; then
18895   ac_cv_sys_file_offset_bits=no; break
18896 else
18897   $as_echo "$as_me: failed program was:" >&5
18898 sed 's/^/| /' conftest.$ac_ext >&5
18899
18900
18901 fi
18902
18903 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18904   cat >conftest.$ac_ext <<_ACEOF
18905 /* confdefs.h.  */
18906 _ACEOF
18907 cat confdefs.h >>conftest.$ac_ext
18908 cat >>conftest.$ac_ext <<_ACEOF
18909 /* end confdefs.h.  */
18910 #define _FILE_OFFSET_BITS 64
18911 #include <sys/types.h>
18912  /* Check that off_t can represent 2**63 - 1 correctly.
18913     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18914     since some C++ compilers masquerading as C compilers
18915     incorrectly reject 9223372036854775807.  */
18916 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18917   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18918                        && LARGE_OFF_T % 2147483647 == 1)
18919                       ? 1 : -1];
18920 int
18921 main ()
18922 {
18923
18924   ;
18925   return 0;
18926 }
18927 _ACEOF
18928 rm -f conftest.$ac_objext
18929 if { (ac_try="$ac_compile"
18930 case "(($ac_try" in
18931   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18932   *) ac_try_echo=$ac_try;;
18933 esac
18934 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18935 $as_echo "$ac_try_echo") >&5
18936   (eval "$ac_compile") 2>conftest.er1
18937   ac_status=$?
18938   grep -v '^ *+' conftest.er1 >conftest.err
18939   rm -f conftest.er1
18940   cat conftest.err >&5
18941   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18942   (exit $ac_status); } && {
18943          test -z "$ac_c_werror_flag" ||
18944          test ! -s conftest.err
18945        } && test -s conftest.$ac_objext; then
18946   ac_cv_sys_file_offset_bits=64; break
18947 else
18948   $as_echo "$as_me: failed program was:" >&5
18949 sed 's/^/| /' conftest.$ac_ext >&5
18950
18951
18952 fi
18953
18954 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18955   ac_cv_sys_file_offset_bits=unknown
18956   break
18957 done
18958 fi
18959 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
18960 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
18961 case $ac_cv_sys_file_offset_bits in #(
18962   no | unknown) ;;
18963   *)
18964 cat >>confdefs.h <<_ACEOF
18965 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
18966 _ACEOF
18967 ;;
18968 esac
18969 rm -rf conftest*
18970   if test $ac_cv_sys_file_offset_bits = unknown; then
18971     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
18972 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
18973 if test "${ac_cv_sys_large_files+set}" = set; then
18974   $as_echo_n "(cached) " >&6
18975 else
18976   while :; do
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 #include <sys/types.h>
18984  /* Check that off_t can represent 2**63 - 1 correctly.
18985     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18986     since some C++ compilers masquerading as C compilers
18987     incorrectly reject 9223372036854775807.  */
18988 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18989   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18990                        && LARGE_OFF_T % 2147483647 == 1)
18991                       ? 1 : -1];
18992 int
18993 main ()
18994 {
18995
18996   ;
18997   return 0;
18998 }
18999 _ACEOF
19000 rm -f conftest.$ac_objext
19001 if { (ac_try="$ac_compile"
19002 case "(($ac_try" in
19003   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19004   *) ac_try_echo=$ac_try;;
19005 esac
19006 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19007 $as_echo "$ac_try_echo") >&5
19008   (eval "$ac_compile") 2>conftest.er1
19009   ac_status=$?
19010   grep -v '^ *+' conftest.er1 >conftest.err
19011   rm -f conftest.er1
19012   cat conftest.err >&5
19013   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19014   (exit $ac_status); } && {
19015          test -z "$ac_c_werror_flag" ||
19016          test ! -s conftest.err
19017        } && test -s conftest.$ac_objext; then
19018   ac_cv_sys_large_files=no; break
19019 else
19020   $as_echo "$as_me: failed program was:" >&5
19021 sed 's/^/| /' conftest.$ac_ext >&5
19022
19023
19024 fi
19025
19026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19027   cat >conftest.$ac_ext <<_ACEOF
19028 /* confdefs.h.  */
19029 _ACEOF
19030 cat confdefs.h >>conftest.$ac_ext
19031 cat >>conftest.$ac_ext <<_ACEOF
19032 /* end confdefs.h.  */
19033 #define _LARGE_FILES 1
19034 #include <sys/types.h>
19035  /* Check that off_t can represent 2**63 - 1 correctly.
19036     We can't simply define LARGE_OFF_T to be 9223372036854775807,
19037     since some C++ compilers masquerading as C compilers
19038     incorrectly reject 9223372036854775807.  */
19039 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
19040   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
19041                        && LARGE_OFF_T % 2147483647 == 1)
19042                       ? 1 : -1];
19043 int
19044 main ()
19045 {
19046
19047   ;
19048   return 0;
19049 }
19050 _ACEOF
19051 rm -f conftest.$ac_objext
19052 if { (ac_try="$ac_compile"
19053 case "(($ac_try" in
19054   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19055   *) ac_try_echo=$ac_try;;
19056 esac
19057 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19058 $as_echo "$ac_try_echo") >&5
19059   (eval "$ac_compile") 2>conftest.er1
19060   ac_status=$?
19061   grep -v '^ *+' conftest.er1 >conftest.err
19062   rm -f conftest.er1
19063   cat conftest.err >&5
19064   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19065   (exit $ac_status); } && {
19066          test -z "$ac_c_werror_flag" ||
19067          test ! -s conftest.err
19068        } && test -s conftest.$ac_objext; then
19069   ac_cv_sys_large_files=1; break
19070 else
19071   $as_echo "$as_me: failed program was:" >&5
19072 sed 's/^/| /' conftest.$ac_ext >&5
19073
19074
19075 fi
19076
19077 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19078   ac_cv_sys_large_files=unknown
19079   break
19080 done
19081 fi
19082 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
19083 $as_echo "$ac_cv_sys_large_files" >&6; }
19084 case $ac_cv_sys_large_files in #(
19085   no | unknown) ;;
19086   *)
19087 cat >>confdefs.h <<_ACEOF
19088 #define _LARGE_FILES $ac_cv_sys_large_files
19089 _ACEOF
19090 ;;
19091 esac
19092 rm -rf conftest*
19093   fi
19094 fi
19095
19096 fi
19097
19098 # Check for largefile support (must be after AC_SYS_LARGEFILE)
19099 # The cast to long int works around a bug in the HP C Compiler
19100 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
19101 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
19102 # This bug is HP SR number 8606223364.
19103 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
19104 $as_echo_n "checking size of off_t... " >&6; }
19105 if test "${ac_cv_sizeof_off_t+set}" = set; then
19106   $as_echo_n "(cached) " >&6
19107 else
19108   if test "$cross_compiling" = yes; then
19109   # Depending upon the size, compute the lo and hi bounds.
19110 cat >conftest.$ac_ext <<_ACEOF
19111 /* confdefs.h.  */
19112 _ACEOF
19113 cat confdefs.h >>conftest.$ac_ext
19114 cat >>conftest.$ac_ext <<_ACEOF
19115 /* end confdefs.h.  */
19116 $ac_includes_default
19117 int
19118 main ()
19119 {
19120 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
19121 test_array [0] = 0
19122
19123   ;
19124   return 0;
19125 }
19126 _ACEOF
19127 rm -f conftest.$ac_objext
19128 if { (ac_try="$ac_compile"
19129 case "(($ac_try" in
19130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19131   *) ac_try_echo=$ac_try;;
19132 esac
19133 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19134 $as_echo "$ac_try_echo") >&5
19135   (eval "$ac_compile") 2>conftest.er1
19136   ac_status=$?
19137   grep -v '^ *+' conftest.er1 >conftest.err
19138   rm -f conftest.er1
19139   cat conftest.err >&5
19140   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19141   (exit $ac_status); } && {
19142          test -z "$ac_c_werror_flag" ||
19143          test ! -s conftest.err
19144        } && test -s conftest.$ac_objext; then
19145   ac_lo=0 ac_mid=0
19146   while :; do
19147     cat >conftest.$ac_ext <<_ACEOF
19148 /* confdefs.h.  */
19149 _ACEOF
19150 cat confdefs.h >>conftest.$ac_ext
19151 cat >>conftest.$ac_ext <<_ACEOF
19152 /* end confdefs.h.  */
19153 $ac_includes_default
19154 int
19155 main ()
19156 {
19157 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
19158 test_array [0] = 0
19159
19160   ;
19161   return 0;
19162 }
19163 _ACEOF
19164 rm -f conftest.$ac_objext
19165 if { (ac_try="$ac_compile"
19166 case "(($ac_try" in
19167   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19168   *) ac_try_echo=$ac_try;;
19169 esac
19170 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19171 $as_echo "$ac_try_echo") >&5
19172   (eval "$ac_compile") 2>conftest.er1
19173   ac_status=$?
19174   grep -v '^ *+' conftest.er1 >conftest.err
19175   rm -f conftest.er1
19176   cat conftest.err >&5
19177   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19178   (exit $ac_status); } && {
19179          test -z "$ac_c_werror_flag" ||
19180          test ! -s conftest.err
19181        } && test -s conftest.$ac_objext; then
19182   ac_hi=$ac_mid; break
19183 else
19184   $as_echo "$as_me: failed program was:" >&5
19185 sed 's/^/| /' conftest.$ac_ext >&5
19186
19187         ac_lo=`expr $ac_mid + 1`
19188                         if test $ac_lo -le $ac_mid; then
19189                           ac_lo= ac_hi=
19190                           break
19191                         fi
19192                         ac_mid=`expr 2 '*' $ac_mid + 1`
19193 fi
19194
19195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19196   done
19197 else
19198   $as_echo "$as_me: failed program was:" >&5
19199 sed 's/^/| /' conftest.$ac_ext >&5
19200
19201         cat >conftest.$ac_ext <<_ACEOF
19202 /* confdefs.h.  */
19203 _ACEOF
19204 cat confdefs.h >>conftest.$ac_ext
19205 cat >>conftest.$ac_ext <<_ACEOF
19206 /* end confdefs.h.  */
19207 $ac_includes_default
19208 int
19209 main ()
19210 {
19211 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
19212 test_array [0] = 0
19213
19214   ;
19215   return 0;
19216 }
19217 _ACEOF
19218 rm -f conftest.$ac_objext
19219 if { (ac_try="$ac_compile"
19220 case "(($ac_try" in
19221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19222   *) ac_try_echo=$ac_try;;
19223 esac
19224 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19225 $as_echo "$ac_try_echo") >&5
19226   (eval "$ac_compile") 2>conftest.er1
19227   ac_status=$?
19228   grep -v '^ *+' conftest.er1 >conftest.err
19229   rm -f conftest.er1
19230   cat conftest.err >&5
19231   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19232   (exit $ac_status); } && {
19233          test -z "$ac_c_werror_flag" ||
19234          test ! -s conftest.err
19235        } && test -s conftest.$ac_objext; then
19236   ac_hi=-1 ac_mid=-1
19237   while :; do
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 $ac_includes_default
19245 int
19246 main ()
19247 {
19248 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
19249 test_array [0] = 0
19250
19251   ;
19252   return 0;
19253 }
19254 _ACEOF
19255 rm -f conftest.$ac_objext
19256 if { (ac_try="$ac_compile"
19257 case "(($ac_try" in
19258   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19259   *) ac_try_echo=$ac_try;;
19260 esac
19261 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19262 $as_echo "$ac_try_echo") >&5
19263   (eval "$ac_compile") 2>conftest.er1
19264   ac_status=$?
19265   grep -v '^ *+' conftest.er1 >conftest.err
19266   rm -f conftest.er1
19267   cat conftest.err >&5
19268   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19269   (exit $ac_status); } && {
19270          test -z "$ac_c_werror_flag" ||
19271          test ! -s conftest.err
19272        } && test -s conftest.$ac_objext; then
19273   ac_lo=$ac_mid; break
19274 else
19275   $as_echo "$as_me: failed program was:" >&5
19276 sed 's/^/| /' conftest.$ac_ext >&5
19277
19278         ac_hi=`expr '(' $ac_mid ')' - 1`
19279                         if test $ac_mid -le $ac_hi; then
19280                           ac_lo= ac_hi=
19281                           break
19282                         fi
19283                         ac_mid=`expr 2 '*' $ac_mid`
19284 fi
19285
19286 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19287   done
19288 else
19289   $as_echo "$as_me: failed program was:" >&5
19290 sed 's/^/| /' conftest.$ac_ext >&5
19291
19292         ac_lo= ac_hi=
19293 fi
19294
19295 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19296 fi
19297
19298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19299 # Binary search between lo and hi bounds.
19300 while test "x$ac_lo" != "x$ac_hi"; do
19301   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19302   cat >conftest.$ac_ext <<_ACEOF
19303 /* confdefs.h.  */
19304 _ACEOF
19305 cat confdefs.h >>conftest.$ac_ext
19306 cat >>conftest.$ac_ext <<_ACEOF
19307 /* end confdefs.h.  */
19308 $ac_includes_default
19309 int
19310 main ()
19311 {
19312 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
19313 test_array [0] = 0
19314
19315   ;
19316   return 0;
19317 }
19318 _ACEOF
19319 rm -f conftest.$ac_objext
19320 if { (ac_try="$ac_compile"
19321 case "(($ac_try" in
19322   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19323   *) ac_try_echo=$ac_try;;
19324 esac
19325 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19326 $as_echo "$ac_try_echo") >&5
19327   (eval "$ac_compile") 2>conftest.er1
19328   ac_status=$?
19329   grep -v '^ *+' conftest.er1 >conftest.err
19330   rm -f conftest.er1
19331   cat conftest.err >&5
19332   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19333   (exit $ac_status); } && {
19334          test -z "$ac_c_werror_flag" ||
19335          test ! -s conftest.err
19336        } && test -s conftest.$ac_objext; then
19337   ac_hi=$ac_mid
19338 else
19339   $as_echo "$as_me: failed program was:" >&5
19340 sed 's/^/| /' conftest.$ac_ext >&5
19341
19342         ac_lo=`expr '(' $ac_mid ')' + 1`
19343 fi
19344
19345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19346 done
19347 case $ac_lo in
19348 ?*) ac_cv_sizeof_off_t=$ac_lo;;
19349 '') if test "$ac_cv_type_off_t" = yes; then
19350      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19351 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19352 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
19353 See \`config.log' for more details." >&5
19354 $as_echo "$as_me: error: cannot compute sizeof (off_t)
19355 See \`config.log' for more details." >&2;}
19356    { (exit 77); exit 77; }; }; }
19357    else
19358      ac_cv_sizeof_off_t=0
19359    fi ;;
19360 esac
19361 else
19362   cat >conftest.$ac_ext <<_ACEOF
19363 /* confdefs.h.  */
19364 _ACEOF
19365 cat confdefs.h >>conftest.$ac_ext
19366 cat >>conftest.$ac_ext <<_ACEOF
19367 /* end confdefs.h.  */
19368 $ac_includes_default
19369 static long int longval () { return (long int) (sizeof (off_t)); }
19370 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
19371 #include <stdio.h>
19372 #include <stdlib.h>
19373 int
19374 main ()
19375 {
19376
19377   FILE *f = fopen ("conftest.val", "w");
19378   if (! f)
19379     return 1;
19380   if (((long int) (sizeof (off_t))) < 0)
19381     {
19382       long int i = longval ();
19383       if (i != ((long int) (sizeof (off_t))))
19384         return 1;
19385       fprintf (f, "%ld", i);
19386     }
19387   else
19388     {
19389       unsigned long int i = ulongval ();
19390       if (i != ((long int) (sizeof (off_t))))
19391         return 1;
19392       fprintf (f, "%lu", i);
19393     }
19394   /* Do not output a trailing newline, as this causes \r\n confusion
19395      on some platforms.  */
19396   return ferror (f) || fclose (f) != 0;
19397
19398   ;
19399   return 0;
19400 }
19401 _ACEOF
19402 rm -f conftest$ac_exeext
19403 if { (ac_try="$ac_link"
19404 case "(($ac_try" in
19405   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19406   *) ac_try_echo=$ac_try;;
19407 esac
19408 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19409 $as_echo "$ac_try_echo") >&5
19410   (eval "$ac_link") 2>&5
19411   ac_status=$?
19412   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19413   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19414   { (case "(($ac_try" in
19415   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19416   *) ac_try_echo=$ac_try;;
19417 esac
19418 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19419 $as_echo "$ac_try_echo") >&5
19420   (eval "$ac_try") 2>&5
19421   ac_status=$?
19422   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19423   (exit $ac_status); }; }; then
19424   ac_cv_sizeof_off_t=`cat conftest.val`
19425 else
19426   $as_echo "$as_me: program exited with status $ac_status" >&5
19427 $as_echo "$as_me: failed program was:" >&5
19428 sed 's/^/| /' conftest.$ac_ext >&5
19429
19430 ( exit $ac_status )
19431 if test "$ac_cv_type_off_t" = yes; then
19432      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19433 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19434 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
19435 See \`config.log' for more details." >&5
19436 $as_echo "$as_me: error: cannot compute sizeof (off_t)
19437 See \`config.log' for more details." >&2;}
19438    { (exit 77); exit 77; }; }; }
19439    else
19440      ac_cv_sizeof_off_t=0
19441    fi
19442 fi
19443 rm -rf conftest.dSYM
19444 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19445 fi
19446 rm -f conftest.val
19447 fi
19448 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
19449 $as_echo "$ac_cv_sizeof_off_t" >&6; }
19450
19451
19452
19453 cat >>confdefs.h <<_ACEOF
19454 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
19455 _ACEOF
19456
19457
19458
19459 # If we don't have largefile support, can't handle segsize >= 2GB.
19460 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
19461    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
19462 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
19463    { (exit 1); exit 1; }; }
19464 fi
19465
19466
19467 ##
19468 ## Functions, global variables
19469 ##
19470
19471 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
19472 $as_echo_n "checking for int timezone... " >&6; }
19473 if test "${pgac_cv_var_int_timezone+set}" = set; then
19474   $as_echo_n "(cached) " >&6
19475 else
19476   cat >conftest.$ac_ext <<_ACEOF
19477 /* confdefs.h.  */
19478 _ACEOF
19479 cat confdefs.h >>conftest.$ac_ext
19480 cat >>conftest.$ac_ext <<_ACEOF
19481 /* end confdefs.h.  */
19482 #include <time.h>
19483 int res;
19484 int
19485 main ()
19486 {
19487 #ifndef __CYGWIN__
19488 res = timezone / 60;
19489 #else
19490 res = _timezone / 60;
19491 #endif
19492   ;
19493   return 0;
19494 }
19495 _ACEOF
19496 rm -f conftest.$ac_objext conftest$ac_exeext
19497 if { (ac_try="$ac_link"
19498 case "(($ac_try" in
19499   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19500   *) ac_try_echo=$ac_try;;
19501 esac
19502 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19503 $as_echo "$ac_try_echo") >&5
19504   (eval "$ac_link") 2>conftest.er1
19505   ac_status=$?
19506   grep -v '^ *+' conftest.er1 >conftest.err
19507   rm -f conftest.er1
19508   cat conftest.err >&5
19509   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19510   (exit $ac_status); } && {
19511          test -z "$ac_c_werror_flag" ||
19512          test ! -s conftest.err
19513        } && test -s conftest$ac_exeext && {
19514          test "$cross_compiling" = yes ||
19515          $as_test_x conftest$ac_exeext
19516        }; then
19517   pgac_cv_var_int_timezone=yes
19518 else
19519   $as_echo "$as_me: failed program was:" >&5
19520 sed 's/^/| /' conftest.$ac_ext >&5
19521
19522         pgac_cv_var_int_timezone=no
19523 fi
19524
19525 rm -rf conftest.dSYM
19526 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19527       conftest$ac_exeext conftest.$ac_ext
19528 fi
19529 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
19530 $as_echo "$pgac_cv_var_int_timezone" >&6; }
19531 if test x"$pgac_cv_var_int_timezone" = xyes ; then
19532
19533 cat >>confdefs.h <<\_ACEOF
19534 #define HAVE_INT_TIMEZONE 1
19535 _ACEOF
19536
19537 fi
19538 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
19539 $as_echo_n "checking types of arguments for accept()... " >&6; }
19540  if test "${ac_cv_func_accept_return+set}" = set; then
19541   $as_echo_n "(cached) " >&6
19542 else
19543    if test "${ac_cv_func_accept_arg1+set}" = set; then
19544   $as_echo_n "(cached) " >&6
19545 else
19546     if test "${ac_cv_func_accept_arg2+set}" = set; then
19547   $as_echo_n "(cached) " >&6
19548 else
19549      if test "${ac_cv_func_accept_arg3+set}" = set; then
19550   $as_echo_n "(cached) " >&6
19551 else
19552       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET WSAAPI'; do
19553       for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
19554        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
19555         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
19556          cat >conftest.$ac_ext <<_ACEOF
19557 /* confdefs.h.  */
19558 _ACEOF
19559 cat confdefs.h >>conftest.$ac_ext
19560 cat >>conftest.$ac_ext <<_ACEOF
19561 /* end confdefs.h.  */
19562 #ifdef HAVE_SYS_TYPES_H
19563 #include <sys/types.h>
19564 #endif
19565 #ifdef HAVE_SYS_SOCKET_H
19566 #include <sys/socket.h>
19567 #endif
19568 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
19569 int
19570 main ()
19571 {
19572
19573   ;
19574   return 0;
19575 }
19576 _ACEOF
19577 rm -f conftest.$ac_objext
19578 if { (ac_try="$ac_compile"
19579 case "(($ac_try" in
19580   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19581   *) ac_try_echo=$ac_try;;
19582 esac
19583 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19584 $as_echo "$ac_try_echo") >&5
19585   (eval "$ac_compile") 2>conftest.er1
19586   ac_status=$?
19587   grep -v '^ *+' conftest.er1 >conftest.err
19588   rm -f conftest.er1
19589   cat conftest.err >&5
19590   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19591   (exit $ac_status); } && {
19592          test -z "$ac_c_werror_flag" ||
19593          test ! -s conftest.err
19594        } && test -s conftest.$ac_objext; then
19595   ac_not_found=no; break 4
19596 else
19597   $as_echo "$as_me: failed program was:" >&5
19598 sed 's/^/| /' conftest.$ac_ext >&5
19599
19600         ac_not_found=yes
19601 fi
19602
19603 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19604        done
19605       done
19606      done
19607     done
19608     if test "$ac_not_found" = yes; then
19609       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
19610 $as_echo "$as_me: error: could not determine argument types" >&2;}
19611    { (exit 1); exit 1; }; }
19612     fi
19613     if test "$ac_cv_func_accept_arg3" = "void"; then
19614       ac_cv_func_accept_arg3=int
19615     fi
19616
19617 fi
19618
19619 fi
19620
19621 fi
19622
19623 fi
19624  { $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
19625 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
19626
19627 cat >>confdefs.h <<_ACEOF
19628 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
19629 _ACEOF
19630
19631
19632 cat >>confdefs.h <<_ACEOF
19633 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
19634 _ACEOF
19635
19636
19637 cat >>confdefs.h <<_ACEOF
19638 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
19639 _ACEOF
19640
19641
19642 cat >>confdefs.h <<_ACEOF
19643 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
19644 _ACEOF
19645
19646
19647 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
19648 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
19649 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
19650   $as_echo_n "(cached) " >&6
19651 else
19652   cat >conftest.$ac_ext <<_ACEOF
19653 /* confdefs.h.  */
19654 _ACEOF
19655 cat confdefs.h >>conftest.$ac_ext
19656 cat >>conftest.$ac_ext <<_ACEOF
19657 /* end confdefs.h.  */
19658 #include <sys/time.h>
19659 int
19660 main ()
19661 {
19662 struct timeval *tp;
19663 struct timezone *tzp;
19664 gettimeofday(tp,tzp);
19665   ;
19666   return 0;
19667 }
19668 _ACEOF
19669 rm -f conftest.$ac_objext
19670 if { (ac_try="$ac_compile"
19671 case "(($ac_try" in
19672   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19673   *) ac_try_echo=$ac_try;;
19674 esac
19675 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19676 $as_echo "$ac_try_echo") >&5
19677   (eval "$ac_compile") 2>conftest.er1
19678   ac_status=$?
19679   grep -v '^ *+' conftest.er1 >conftest.err
19680   rm -f conftest.er1
19681   cat conftest.err >&5
19682   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19683   (exit $ac_status); } && {
19684          test -z "$ac_c_werror_flag" ||
19685          test ! -s conftest.err
19686        } && test -s conftest.$ac_objext; then
19687   pgac_cv_func_gettimeofday_1arg=no
19688 else
19689   $as_echo "$as_me: failed program was:" >&5
19690 sed 's/^/| /' conftest.$ac_ext >&5
19691
19692         pgac_cv_func_gettimeofday_1arg=yes
19693 fi
19694
19695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19696 fi
19697 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
19698 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
19699 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
19700
19701 cat >>confdefs.h <<\_ACEOF
19702 #define GETTIMEOFDAY_1ARG 1
19703 _ACEOF
19704
19705 fi
19706
19707
19708
19709 # Some versions of libedit contain strlcpy(), setproctitle(), and other
19710 # symbols that that library has no business exposing to the world.  Pending
19711 # acquisition of a clue by those developers, ignore libedit (including its
19712 # possible alias of libreadline) while checking for everything else.
19713 LIBS_including_readline="$LIBS"
19714 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
19715
19716
19717
19718
19719
19720
19721
19722
19723
19724
19725
19726
19727
19728
19729
19730
19731
19732
19733
19734
19735
19736
19737
19738 for ac_func in cbrt dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove poll pstat readlink setproctitle setsid shm_open sigprocmask symlink sync_file_range towlower utime utimes wcstombs wcstombs_l
19739 do
19740 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19741 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19742 $as_echo_n "checking for $ac_func... " >&6; }
19743 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19744   $as_echo_n "(cached) " >&6
19745 else
19746   cat >conftest.$ac_ext <<_ACEOF
19747 /* confdefs.h.  */
19748 _ACEOF
19749 cat confdefs.h >>conftest.$ac_ext
19750 cat >>conftest.$ac_ext <<_ACEOF
19751 /* end confdefs.h.  */
19752 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19753    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19754 #define $ac_func innocuous_$ac_func
19755
19756 /* System header to define __stub macros and hopefully few prototypes,
19757     which can conflict with char $ac_func (); below.
19758     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19759     <limits.h> exists even on freestanding compilers.  */
19760
19761 #ifdef __STDC__
19762 # include <limits.h>
19763 #else
19764 # include <assert.h>
19765 #endif
19766
19767 #undef $ac_func
19768
19769 /* Override any GCC internal prototype to avoid an error.
19770    Use char because int might match the return type of a GCC
19771    builtin and then its argument prototype would still apply.  */
19772 #ifdef __cplusplus
19773 extern "C"
19774 #endif
19775 char $ac_func ();
19776 /* The GNU C library defines this for functions which it implements
19777     to always fail with ENOSYS.  Some functions are actually named
19778     something starting with __ and the normal name is an alias.  */
19779 #if defined __stub_$ac_func || defined __stub___$ac_func
19780 choke me
19781 #endif
19782
19783 int
19784 main ()
19785 {
19786 return $ac_func ();
19787   ;
19788   return 0;
19789 }
19790 _ACEOF
19791 rm -f conftest.$ac_objext conftest$ac_exeext
19792 if { (ac_try="$ac_link"
19793 case "(($ac_try" in
19794   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19795   *) ac_try_echo=$ac_try;;
19796 esac
19797 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19798 $as_echo "$ac_try_echo") >&5
19799   (eval "$ac_link") 2>conftest.er1
19800   ac_status=$?
19801   grep -v '^ *+' conftest.er1 >conftest.err
19802   rm -f conftest.er1
19803   cat conftest.err >&5
19804   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19805   (exit $ac_status); } && {
19806          test -z "$ac_c_werror_flag" ||
19807          test ! -s conftest.err
19808        } && test -s conftest$ac_exeext && {
19809          test "$cross_compiling" = yes ||
19810          $as_test_x conftest$ac_exeext
19811        }; then
19812   eval "$as_ac_var=yes"
19813 else
19814   $as_echo "$as_me: failed program was:" >&5
19815 sed 's/^/| /' conftest.$ac_ext >&5
19816
19817         eval "$as_ac_var=no"
19818 fi
19819
19820 rm -rf conftest.dSYM
19821 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19822       conftest$ac_exeext conftest.$ac_ext
19823 fi
19824 ac_res=`eval 'as_val=${'$as_ac_var'}
19825                  $as_echo "$as_val"'`
19826                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19827 $as_echo "$ac_res" >&6; }
19828 as_val=`eval 'as_val=${'$as_ac_var'}
19829                  $as_echo "$as_val"'`
19830    if test "x$as_val" = x""yes; then
19831   cat >>confdefs.h <<_ACEOF
19832 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19833 _ACEOF
19834
19835 fi
19836 done
19837
19838
19839
19840 for ac_func in fseeko
19841 do
19842 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19843 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19844 $as_echo_n "checking for $ac_func... " >&6; }
19845 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19846   $as_echo_n "(cached) " >&6
19847 else
19848   cat >conftest.$ac_ext <<_ACEOF
19849 /* confdefs.h.  */
19850 _ACEOF
19851 cat confdefs.h >>conftest.$ac_ext
19852 cat >>conftest.$ac_ext <<_ACEOF
19853 /* end confdefs.h.  */
19854 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19855    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19856 #define $ac_func innocuous_$ac_func
19857
19858 /* System header to define __stub macros and hopefully few prototypes,
19859     which can conflict with char $ac_func (); below.
19860     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19861     <limits.h> exists even on freestanding compilers.  */
19862
19863 #ifdef __STDC__
19864 # include <limits.h>
19865 #else
19866 # include <assert.h>
19867 #endif
19868
19869 #undef $ac_func
19870
19871 /* Override any GCC internal prototype to avoid an error.
19872    Use char because int might match the return type of a GCC
19873    builtin and then its argument prototype would still apply.  */
19874 #ifdef __cplusplus
19875 extern "C"
19876 #endif
19877 char $ac_func ();
19878 /* The GNU C library defines this for functions which it implements
19879     to always fail with ENOSYS.  Some functions are actually named
19880     something starting with __ and the normal name is an alias.  */
19881 #if defined __stub_$ac_func || defined __stub___$ac_func
19882 choke me
19883 #endif
19884
19885 int
19886 main ()
19887 {
19888 return $ac_func ();
19889   ;
19890   return 0;
19891 }
19892 _ACEOF
19893 rm -f conftest.$ac_objext conftest$ac_exeext
19894 if { (ac_try="$ac_link"
19895 case "(($ac_try" in
19896   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19897   *) ac_try_echo=$ac_try;;
19898 esac
19899 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19900 $as_echo "$ac_try_echo") >&5
19901   (eval "$ac_link") 2>conftest.er1
19902   ac_status=$?
19903   grep -v '^ *+' conftest.er1 >conftest.err
19904   rm -f conftest.er1
19905   cat conftest.err >&5
19906   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19907   (exit $ac_status); } && {
19908          test -z "$ac_c_werror_flag" ||
19909          test ! -s conftest.err
19910        } && test -s conftest$ac_exeext && {
19911          test "$cross_compiling" = yes ||
19912          $as_test_x conftest$ac_exeext
19913        }; then
19914   eval "$as_ac_var=yes"
19915 else
19916   $as_echo "$as_me: failed program was:" >&5
19917 sed 's/^/| /' conftest.$ac_ext >&5
19918
19919         eval "$as_ac_var=no"
19920 fi
19921
19922 rm -rf conftest.dSYM
19923 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19924       conftest$ac_exeext conftest.$ac_ext
19925 fi
19926 ac_res=`eval 'as_val=${'$as_ac_var'}
19927                  $as_echo "$as_val"'`
19928                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19929 $as_echo "$ac_res" >&6; }
19930 as_val=`eval 'as_val=${'$as_ac_var'}
19931                  $as_echo "$as_val"'`
19932    if test "x$as_val" = x""yes; then
19933   cat >>confdefs.h <<_ACEOF
19934 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19935 _ACEOF
19936
19937 else
19938   case " $LIBOBJS " in
19939   *" $ac_func.$ac_objext "* ) ;;
19940   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19941  ;;
19942 esac
19943
19944 fi
19945 done
19946
19947
19948 case $host_os in
19949         # NetBSD uses a custom fseeko/ftello built on fsetpos/fgetpos
19950         # Mingw uses macros to access Win32 API calls
19951         netbsd*|mingw*)
19952
19953 cat >>confdefs.h <<\_ACEOF
19954 #define HAVE_FSEEKO 1
19955 _ACEOF
19956
19957                 ac_cv_func_fseeko=yes;;
19958         *)
19959                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
19960 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
19961 if test "${ac_cv_sys_largefile_source+set}" = set; then
19962   $as_echo_n "(cached) " >&6
19963 else
19964   while :; do
19965   cat >conftest.$ac_ext <<_ACEOF
19966 /* confdefs.h.  */
19967 _ACEOF
19968 cat confdefs.h >>conftest.$ac_ext
19969 cat >>conftest.$ac_ext <<_ACEOF
19970 /* end confdefs.h.  */
19971 #include <sys/types.h> /* for off_t */
19972      #include <stdio.h>
19973 int
19974 main ()
19975 {
19976 int (*fp) (FILE *, off_t, int) = fseeko;
19977      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19978   ;
19979   return 0;
19980 }
19981 _ACEOF
19982 rm -f conftest.$ac_objext conftest$ac_exeext
19983 if { (ac_try="$ac_link"
19984 case "(($ac_try" in
19985   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19986   *) ac_try_echo=$ac_try;;
19987 esac
19988 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19989 $as_echo "$ac_try_echo") >&5
19990   (eval "$ac_link") 2>conftest.er1
19991   ac_status=$?
19992   grep -v '^ *+' conftest.er1 >conftest.err
19993   rm -f conftest.er1
19994   cat conftest.err >&5
19995   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19996   (exit $ac_status); } && {
19997          test -z "$ac_c_werror_flag" ||
19998          test ! -s conftest.err
19999        } && test -s conftest$ac_exeext && {
20000          test "$cross_compiling" = yes ||
20001          $as_test_x conftest$ac_exeext
20002        }; then
20003   ac_cv_sys_largefile_source=no; break
20004 else
20005   $as_echo "$as_me: failed program was:" >&5
20006 sed 's/^/| /' conftest.$ac_ext >&5
20007
20008
20009 fi
20010
20011 rm -rf conftest.dSYM
20012 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20013       conftest$ac_exeext conftest.$ac_ext
20014   cat >conftest.$ac_ext <<_ACEOF
20015 /* confdefs.h.  */
20016 _ACEOF
20017 cat confdefs.h >>conftest.$ac_ext
20018 cat >>conftest.$ac_ext <<_ACEOF
20019 /* end confdefs.h.  */
20020 #define _LARGEFILE_SOURCE 1
20021 #include <sys/types.h> /* for off_t */
20022      #include <stdio.h>
20023 int
20024 main ()
20025 {
20026 int (*fp) (FILE *, off_t, int) = fseeko;
20027      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
20028   ;
20029   return 0;
20030 }
20031 _ACEOF
20032 rm -f conftest.$ac_objext conftest$ac_exeext
20033 if { (ac_try="$ac_link"
20034 case "(($ac_try" in
20035   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20036   *) ac_try_echo=$ac_try;;
20037 esac
20038 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20039 $as_echo "$ac_try_echo") >&5
20040   (eval "$ac_link") 2>conftest.er1
20041   ac_status=$?
20042   grep -v '^ *+' conftest.er1 >conftest.err
20043   rm -f conftest.er1
20044   cat conftest.err >&5
20045   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20046   (exit $ac_status); } && {
20047          test -z "$ac_c_werror_flag" ||
20048          test ! -s conftest.err
20049        } && test -s conftest$ac_exeext && {
20050          test "$cross_compiling" = yes ||
20051          $as_test_x conftest$ac_exeext
20052        }; then
20053   ac_cv_sys_largefile_source=1; break
20054 else
20055   $as_echo "$as_me: failed program was:" >&5
20056 sed 's/^/| /' conftest.$ac_ext >&5
20057
20058
20059 fi
20060
20061 rm -rf conftest.dSYM
20062 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20063       conftest$ac_exeext conftest.$ac_ext
20064   ac_cv_sys_largefile_source=unknown
20065   break
20066 done
20067 fi
20068 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
20069 $as_echo "$ac_cv_sys_largefile_source" >&6; }
20070 case $ac_cv_sys_largefile_source in #(
20071   no | unknown) ;;
20072   *)
20073 cat >>confdefs.h <<_ACEOF
20074 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
20075 _ACEOF
20076 ;;
20077 esac
20078 rm -rf conftest*
20079
20080 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
20081 # in glibc 2.1.3, but that breaks too many other things.
20082 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
20083 if test $ac_cv_sys_largefile_source != unknown; then
20084
20085 cat >>confdefs.h <<\_ACEOF
20086 #define HAVE_FSEEKO 1
20087 _ACEOF
20088
20089 fi
20090 ;;
20091 esac
20092
20093 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
20094 # by calling it, 2009-04-02
20095 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
20096 if test "$PORTNAME" != "solaris"; then
20097
20098 for ac_func in posix_fadvise
20099 do
20100 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20101 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20102 $as_echo_n "checking for $ac_func... " >&6; }
20103 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20104   $as_echo_n "(cached) " >&6
20105 else
20106   cat >conftest.$ac_ext <<_ACEOF
20107 /* confdefs.h.  */
20108 _ACEOF
20109 cat confdefs.h >>conftest.$ac_ext
20110 cat >>conftest.$ac_ext <<_ACEOF
20111 /* end confdefs.h.  */
20112 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20113    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20114 #define $ac_func innocuous_$ac_func
20115
20116 /* System header to define __stub macros and hopefully few prototypes,
20117     which can conflict with char $ac_func (); below.
20118     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20119     <limits.h> exists even on freestanding compilers.  */
20120
20121 #ifdef __STDC__
20122 # include <limits.h>
20123 #else
20124 # include <assert.h>
20125 #endif
20126
20127 #undef $ac_func
20128
20129 /* Override any GCC internal prototype to avoid an error.
20130    Use char because int might match the return type of a GCC
20131    builtin and then its argument prototype would still apply.  */
20132 #ifdef __cplusplus
20133 extern "C"
20134 #endif
20135 char $ac_func ();
20136 /* The GNU C library defines this for functions which it implements
20137     to always fail with ENOSYS.  Some functions are actually named
20138     something starting with __ and the normal name is an alias.  */
20139 #if defined __stub_$ac_func || defined __stub___$ac_func
20140 choke me
20141 #endif
20142
20143 int
20144 main ()
20145 {
20146 return $ac_func ();
20147   ;
20148   return 0;
20149 }
20150 _ACEOF
20151 rm -f conftest.$ac_objext conftest$ac_exeext
20152 if { (ac_try="$ac_link"
20153 case "(($ac_try" in
20154   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20155   *) ac_try_echo=$ac_try;;
20156 esac
20157 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20158 $as_echo "$ac_try_echo") >&5
20159   (eval "$ac_link") 2>conftest.er1
20160   ac_status=$?
20161   grep -v '^ *+' conftest.er1 >conftest.err
20162   rm -f conftest.er1
20163   cat conftest.err >&5
20164   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20165   (exit $ac_status); } && {
20166          test -z "$ac_c_werror_flag" ||
20167          test ! -s conftest.err
20168        } && test -s conftest$ac_exeext && {
20169          test "$cross_compiling" = yes ||
20170          $as_test_x conftest$ac_exeext
20171        }; then
20172   eval "$as_ac_var=yes"
20173 else
20174   $as_echo "$as_me: failed program was:" >&5
20175 sed 's/^/| /' conftest.$ac_ext >&5
20176
20177         eval "$as_ac_var=no"
20178 fi
20179
20180 rm -rf conftest.dSYM
20181 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20182       conftest$ac_exeext conftest.$ac_ext
20183 fi
20184 ac_res=`eval 'as_val=${'$as_ac_var'}
20185                  $as_echo "$as_val"'`
20186                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20187 $as_echo "$ac_res" >&6; }
20188 as_val=`eval 'as_val=${'$as_ac_var'}
20189                  $as_echo "$as_val"'`
20190    if test "x$as_val" = x""yes; then
20191   cat >>confdefs.h <<_ACEOF
20192 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20193 _ACEOF
20194
20195 fi
20196 done
20197
20198 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
20199 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
20200 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
20201   $as_echo_n "(cached) " >&6
20202 else
20203   cat >conftest.$ac_ext <<_ACEOF
20204 /* confdefs.h.  */
20205 _ACEOF
20206 cat confdefs.h >>conftest.$ac_ext
20207 cat >>conftest.$ac_ext <<_ACEOF
20208 /* end confdefs.h.  */
20209 #include <fcntl.h>
20210
20211 int
20212 main ()
20213 {
20214 #ifndef posix_fadvise
20215   (void) posix_fadvise;
20216 #endif
20217
20218   ;
20219   return 0;
20220 }
20221 _ACEOF
20222 rm -f conftest.$ac_objext
20223 if { (ac_try="$ac_compile"
20224 case "(($ac_try" in
20225   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20226   *) ac_try_echo=$ac_try;;
20227 esac
20228 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20229 $as_echo "$ac_try_echo") >&5
20230   (eval "$ac_compile") 2>conftest.er1
20231   ac_status=$?
20232   grep -v '^ *+' conftest.er1 >conftest.err
20233   rm -f conftest.er1
20234   cat conftest.err >&5
20235   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20236   (exit $ac_status); } && {
20237          test -z "$ac_c_werror_flag" ||
20238          test ! -s conftest.err
20239        } && test -s conftest.$ac_objext; then
20240   ac_cv_have_decl_posix_fadvise=yes
20241 else
20242   $as_echo "$as_me: failed program was:" >&5
20243 sed 's/^/| /' conftest.$ac_ext >&5
20244
20245         ac_cv_have_decl_posix_fadvise=no
20246 fi
20247
20248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20249 fi
20250 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
20251 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
20252 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
20253
20254 cat >>confdefs.h <<_ACEOF
20255 #define HAVE_DECL_POSIX_FADVISE 1
20256 _ACEOF
20257
20258
20259 else
20260   cat >>confdefs.h <<_ACEOF
20261 #define HAVE_DECL_POSIX_FADVISE 0
20262 _ACEOF
20263
20264
20265 fi
20266
20267
20268 fi
20269
20270 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
20271 $as_echo_n "checking whether fdatasync is declared... " >&6; }
20272 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
20273   $as_echo_n "(cached) " >&6
20274 else
20275   cat >conftest.$ac_ext <<_ACEOF
20276 /* confdefs.h.  */
20277 _ACEOF
20278 cat confdefs.h >>conftest.$ac_ext
20279 cat >>conftest.$ac_ext <<_ACEOF
20280 /* end confdefs.h.  */
20281 #include <unistd.h>
20282
20283 int
20284 main ()
20285 {
20286 #ifndef fdatasync
20287   (void) fdatasync;
20288 #endif
20289
20290   ;
20291   return 0;
20292 }
20293 _ACEOF
20294 rm -f conftest.$ac_objext
20295 if { (ac_try="$ac_compile"
20296 case "(($ac_try" in
20297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20298   *) ac_try_echo=$ac_try;;
20299 esac
20300 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20301 $as_echo "$ac_try_echo") >&5
20302   (eval "$ac_compile") 2>conftest.er1
20303   ac_status=$?
20304   grep -v '^ *+' conftest.er1 >conftest.err
20305   rm -f conftest.er1
20306   cat conftest.err >&5
20307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20308   (exit $ac_status); } && {
20309          test -z "$ac_c_werror_flag" ||
20310          test ! -s conftest.err
20311        } && test -s conftest.$ac_objext; then
20312   ac_cv_have_decl_fdatasync=yes
20313 else
20314   $as_echo "$as_me: failed program was:" >&5
20315 sed 's/^/| /' conftest.$ac_ext >&5
20316
20317         ac_cv_have_decl_fdatasync=no
20318 fi
20319
20320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20321 fi
20322 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
20323 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
20324 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
20325
20326 cat >>confdefs.h <<_ACEOF
20327 #define HAVE_DECL_FDATASYNC 1
20328 _ACEOF
20329
20330
20331 else
20332   cat >>confdefs.h <<_ACEOF
20333 #define HAVE_DECL_FDATASYNC 0
20334 _ACEOF
20335
20336
20337 fi
20338
20339
20340 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
20341 $as_echo_n "checking whether strlcat is declared... " >&6; }
20342 if test "${ac_cv_have_decl_strlcat+set}" = set; then
20343   $as_echo_n "(cached) " >&6
20344 else
20345   cat >conftest.$ac_ext <<_ACEOF
20346 /* confdefs.h.  */
20347 _ACEOF
20348 cat confdefs.h >>conftest.$ac_ext
20349 cat >>conftest.$ac_ext <<_ACEOF
20350 /* end confdefs.h.  */
20351 $ac_includes_default
20352 int
20353 main ()
20354 {
20355 #ifndef strlcat
20356   (void) strlcat;
20357 #endif
20358
20359   ;
20360   return 0;
20361 }
20362 _ACEOF
20363 rm -f conftest.$ac_objext
20364 if { (ac_try="$ac_compile"
20365 case "(($ac_try" in
20366   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20367   *) ac_try_echo=$ac_try;;
20368 esac
20369 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20370 $as_echo "$ac_try_echo") >&5
20371   (eval "$ac_compile") 2>conftest.er1
20372   ac_status=$?
20373   grep -v '^ *+' conftest.er1 >conftest.err
20374   rm -f conftest.er1
20375   cat conftest.err >&5
20376   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20377   (exit $ac_status); } && {
20378          test -z "$ac_c_werror_flag" ||
20379          test ! -s conftest.err
20380        } && test -s conftest.$ac_objext; then
20381   ac_cv_have_decl_strlcat=yes
20382 else
20383   $as_echo "$as_me: failed program was:" >&5
20384 sed 's/^/| /' conftest.$ac_ext >&5
20385
20386         ac_cv_have_decl_strlcat=no
20387 fi
20388
20389 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20390 fi
20391 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
20392 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
20393 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
20394
20395 cat >>confdefs.h <<_ACEOF
20396 #define HAVE_DECL_STRLCAT 1
20397 _ACEOF
20398
20399
20400 else
20401   cat >>confdefs.h <<_ACEOF
20402 #define HAVE_DECL_STRLCAT 0
20403 _ACEOF
20404
20405
20406 fi
20407 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
20408 $as_echo_n "checking whether strlcpy is declared... " >&6; }
20409 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
20410   $as_echo_n "(cached) " >&6
20411 else
20412   cat >conftest.$ac_ext <<_ACEOF
20413 /* confdefs.h.  */
20414 _ACEOF
20415 cat confdefs.h >>conftest.$ac_ext
20416 cat >>conftest.$ac_ext <<_ACEOF
20417 /* end confdefs.h.  */
20418 $ac_includes_default
20419 int
20420 main ()
20421 {
20422 #ifndef strlcpy
20423   (void) strlcpy;
20424 #endif
20425
20426   ;
20427   return 0;
20428 }
20429 _ACEOF
20430 rm -f conftest.$ac_objext
20431 if { (ac_try="$ac_compile"
20432 case "(($ac_try" in
20433   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20434   *) ac_try_echo=$ac_try;;
20435 esac
20436 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20437 $as_echo "$ac_try_echo") >&5
20438   (eval "$ac_compile") 2>conftest.er1
20439   ac_status=$?
20440   grep -v '^ *+' conftest.er1 >conftest.err
20441   rm -f conftest.er1
20442   cat conftest.err >&5
20443   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20444   (exit $ac_status); } && {
20445          test -z "$ac_c_werror_flag" ||
20446          test ! -s conftest.err
20447        } && test -s conftest.$ac_objext; then
20448   ac_cv_have_decl_strlcpy=yes
20449 else
20450   $as_echo "$as_me: failed program was:" >&5
20451 sed 's/^/| /' conftest.$ac_ext >&5
20452
20453         ac_cv_have_decl_strlcpy=no
20454 fi
20455
20456 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20457 fi
20458 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
20459 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
20460 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
20461
20462 cat >>confdefs.h <<_ACEOF
20463 #define HAVE_DECL_STRLCPY 1
20464 _ACEOF
20465
20466
20467 else
20468   cat >>confdefs.h <<_ACEOF
20469 #define HAVE_DECL_STRLCPY 0
20470 _ACEOF
20471
20472
20473 fi
20474
20475
20476 # This is probably only present on Darwin, but may as well check always
20477 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
20478 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
20479 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
20480   $as_echo_n "(cached) " >&6
20481 else
20482   cat >conftest.$ac_ext <<_ACEOF
20483 /* confdefs.h.  */
20484 _ACEOF
20485 cat confdefs.h >>conftest.$ac_ext
20486 cat >>conftest.$ac_ext <<_ACEOF
20487 /* end confdefs.h.  */
20488 #include <fcntl.h>
20489
20490 int
20491 main ()
20492 {
20493 #ifndef F_FULLFSYNC
20494   (void) F_FULLFSYNC;
20495 #endif
20496
20497   ;
20498   return 0;
20499 }
20500 _ACEOF
20501 rm -f conftest.$ac_objext
20502 if { (ac_try="$ac_compile"
20503 case "(($ac_try" in
20504   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20505   *) ac_try_echo=$ac_try;;
20506 esac
20507 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20508 $as_echo "$ac_try_echo") >&5
20509   (eval "$ac_compile") 2>conftest.er1
20510   ac_status=$?
20511   grep -v '^ *+' conftest.er1 >conftest.err
20512   rm -f conftest.er1
20513   cat conftest.err >&5
20514   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20515   (exit $ac_status); } && {
20516          test -z "$ac_c_werror_flag" ||
20517          test ! -s conftest.err
20518        } && test -s conftest.$ac_objext; then
20519   ac_cv_have_decl_F_FULLFSYNC=yes
20520 else
20521   $as_echo "$as_me: failed program was:" >&5
20522 sed 's/^/| /' conftest.$ac_ext >&5
20523
20524         ac_cv_have_decl_F_FULLFSYNC=no
20525 fi
20526
20527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20528 fi
20529 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
20530 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
20531 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
20532
20533 cat >>confdefs.h <<_ACEOF
20534 #define HAVE_DECL_F_FULLFSYNC 1
20535 _ACEOF
20536
20537
20538 else
20539   cat >>confdefs.h <<_ACEOF
20540 #define HAVE_DECL_F_FULLFSYNC 0
20541 _ACEOF
20542
20543
20544 fi
20545
20546
20547
20548 HAVE_IPV6=no
20549 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
20550 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
20551 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
20552   $as_echo_n "(cached) " >&6
20553 else
20554   ac_cv_type_struct_sockaddr_in6=no
20555 cat >conftest.$ac_ext <<_ACEOF
20556 /* confdefs.h.  */
20557 _ACEOF
20558 cat confdefs.h >>conftest.$ac_ext
20559 cat >>conftest.$ac_ext <<_ACEOF
20560 /* end confdefs.h.  */
20561 $ac_includes_default
20562 #include <netinet/in.h>
20563
20564 int
20565 main ()
20566 {
20567 if (sizeof (struct sockaddr_in6))
20568        return 0;
20569   ;
20570   return 0;
20571 }
20572 _ACEOF
20573 rm -f conftest.$ac_objext
20574 if { (ac_try="$ac_compile"
20575 case "(($ac_try" in
20576   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20577   *) ac_try_echo=$ac_try;;
20578 esac
20579 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20580 $as_echo "$ac_try_echo") >&5
20581   (eval "$ac_compile") 2>conftest.er1
20582   ac_status=$?
20583   grep -v '^ *+' conftest.er1 >conftest.err
20584   rm -f conftest.er1
20585   cat conftest.err >&5
20586   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20587   (exit $ac_status); } && {
20588          test -z "$ac_c_werror_flag" ||
20589          test ! -s conftest.err
20590        } && test -s conftest.$ac_objext; then
20591   cat >conftest.$ac_ext <<_ACEOF
20592 /* confdefs.h.  */
20593 _ACEOF
20594 cat confdefs.h >>conftest.$ac_ext
20595 cat >>conftest.$ac_ext <<_ACEOF
20596 /* end confdefs.h.  */
20597 $ac_includes_default
20598 #include <netinet/in.h>
20599
20600 int
20601 main ()
20602 {
20603 if (sizeof ((struct sockaddr_in6)))
20604           return 0;
20605   ;
20606   return 0;
20607 }
20608 _ACEOF
20609 rm -f conftest.$ac_objext
20610 if { (ac_try="$ac_compile"
20611 case "(($ac_try" in
20612   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20613   *) ac_try_echo=$ac_try;;
20614 esac
20615 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20616 $as_echo "$ac_try_echo") >&5
20617   (eval "$ac_compile") 2>conftest.er1
20618   ac_status=$?
20619   grep -v '^ *+' conftest.er1 >conftest.err
20620   rm -f conftest.er1
20621   cat conftest.err >&5
20622   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20623   (exit $ac_status); } && {
20624          test -z "$ac_c_werror_flag" ||
20625          test ! -s conftest.err
20626        } && test -s conftest.$ac_objext; then
20627   :
20628 else
20629   $as_echo "$as_me: failed program was:" >&5
20630 sed 's/^/| /' conftest.$ac_ext >&5
20631
20632         ac_cv_type_struct_sockaddr_in6=yes
20633 fi
20634
20635 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20636 else
20637   $as_echo "$as_me: failed program was:" >&5
20638 sed 's/^/| /' conftest.$ac_ext >&5
20639
20640
20641 fi
20642
20643 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20644 fi
20645 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
20646 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
20647 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
20648
20649 cat >>confdefs.h <<\_ACEOF
20650 #define HAVE_IPV6 1
20651 _ACEOF
20652
20653          HAVE_IPV6=yes
20654 fi
20655
20656
20657
20658 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
20659 $as_echo_n "checking for PS_STRINGS... " >&6; }
20660 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
20661   $as_echo_n "(cached) " >&6
20662 else
20663   cat >conftest.$ac_ext <<_ACEOF
20664 /* confdefs.h.  */
20665 _ACEOF
20666 cat confdefs.h >>conftest.$ac_ext
20667 cat >>conftest.$ac_ext <<_ACEOF
20668 /* end confdefs.h.  */
20669 #include <machine/vmparam.h>
20670 #include <sys/exec.h>
20671
20672 int
20673 main ()
20674 {
20675 PS_STRINGS->ps_nargvstr = 1;
20676 PS_STRINGS->ps_argvstr = "foo";
20677   ;
20678   return 0;
20679 }
20680 _ACEOF
20681 rm -f conftest.$ac_objext conftest$ac_exeext
20682 if { (ac_try="$ac_link"
20683 case "(($ac_try" in
20684   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20685   *) ac_try_echo=$ac_try;;
20686 esac
20687 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20688 $as_echo "$ac_try_echo") >&5
20689   (eval "$ac_link") 2>conftest.er1
20690   ac_status=$?
20691   grep -v '^ *+' conftest.er1 >conftest.err
20692   rm -f conftest.er1
20693   cat conftest.err >&5
20694   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20695   (exit $ac_status); } && {
20696          test -z "$ac_c_werror_flag" ||
20697          test ! -s conftest.err
20698        } && test -s conftest$ac_exeext && {
20699          test "$cross_compiling" = yes ||
20700          $as_test_x conftest$ac_exeext
20701        }; then
20702   pgac_cv_var_PS_STRINGS=yes
20703 else
20704   $as_echo "$as_me: failed program was:" >&5
20705 sed 's/^/| /' conftest.$ac_ext >&5
20706
20707         pgac_cv_var_PS_STRINGS=no
20708 fi
20709
20710 rm -rf conftest.dSYM
20711 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20712       conftest$ac_exeext conftest.$ac_ext
20713 fi
20714 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
20715 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
20716 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
20717
20718 cat >>confdefs.h <<\_ACEOF
20719 #define HAVE_PS_STRINGS 1
20720 _ACEOF
20721
20722 fi
20723
20724
20725 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
20726 # is missing.  Yes, there are machines that have only one.  We may
20727 # also decide to use snprintf.c if snprintf() is present but does not
20728 # have all the features we need --- see below.
20729
20730 if test "$PORTNAME" = "win32"; then
20731   # Win32 gets snprintf.c built unconditionally.
20732   #
20733   # To properly translate all NLS languages strings, we must support the
20734   # *printf() %$ format, which allows *printf() arguments to be selected
20735   # by position in the translated string.
20736   #
20737   # libintl versions < 0.13 use the native *printf() functions, and Win32
20738   # *printf() doesn't understand %$, so we must use our /port versions,
20739   # which do understand %$. libintl versions >= 0.13 include their own
20740   # *printf versions on Win32.  The libintl 0.13 release note text is:
20741   #
20742   #   C format strings with positions, as they arise when a translator
20743   #   needs to reorder a sentence, are now supported on all platforms.
20744   #   On those few platforms (NetBSD and Woe32) for which the native
20745   #   printf()/fprintf()/... functions don't support such format
20746   #   strings, replacements are provided through <libintl.h>.
20747   #
20748   # We could use libintl >= 0.13's *printf() if we were sure that we had
20749   # a litint >= 0.13 at runtime, but seeing that there is no clean way
20750   # to guarantee that, it is best to just use our own, so we are sure to
20751   # get %$ support. In include/port.h we disable the *printf() macros
20752   # that might have been defined by libintl.
20753   #
20754   # We do this unconditionally whether NLS is used or not so we are sure
20755   # that all Win32 libraries and binaries behave the same.
20756   pgac_need_repl_snprintf=yes
20757 else
20758   pgac_need_repl_snprintf=no
20759
20760 for ac_func in snprintf
20761 do
20762 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20763 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20764 $as_echo_n "checking for $ac_func... " >&6; }
20765 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20766   $as_echo_n "(cached) " >&6
20767 else
20768   cat >conftest.$ac_ext <<_ACEOF
20769 /* confdefs.h.  */
20770 _ACEOF
20771 cat confdefs.h >>conftest.$ac_ext
20772 cat >>conftest.$ac_ext <<_ACEOF
20773 /* end confdefs.h.  */
20774 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20775    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20776 #define $ac_func innocuous_$ac_func
20777
20778 /* System header to define __stub macros and hopefully few prototypes,
20779     which can conflict with char $ac_func (); below.
20780     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20781     <limits.h> exists even on freestanding compilers.  */
20782
20783 #ifdef __STDC__
20784 # include <limits.h>
20785 #else
20786 # include <assert.h>
20787 #endif
20788
20789 #undef $ac_func
20790
20791 /* Override any GCC internal prototype to avoid an error.
20792    Use char because int might match the return type of a GCC
20793    builtin and then its argument prototype would still apply.  */
20794 #ifdef __cplusplus
20795 extern "C"
20796 #endif
20797 char $ac_func ();
20798 /* The GNU C library defines this for functions which it implements
20799     to always fail with ENOSYS.  Some functions are actually named
20800     something starting with __ and the normal name is an alias.  */
20801 #if defined __stub_$ac_func || defined __stub___$ac_func
20802 choke me
20803 #endif
20804
20805 int
20806 main ()
20807 {
20808 return $ac_func ();
20809   ;
20810   return 0;
20811 }
20812 _ACEOF
20813 rm -f conftest.$ac_objext conftest$ac_exeext
20814 if { (ac_try="$ac_link"
20815 case "(($ac_try" in
20816   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20817   *) ac_try_echo=$ac_try;;
20818 esac
20819 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20820 $as_echo "$ac_try_echo") >&5
20821   (eval "$ac_link") 2>conftest.er1
20822   ac_status=$?
20823   grep -v '^ *+' conftest.er1 >conftest.err
20824   rm -f conftest.er1
20825   cat conftest.err >&5
20826   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20827   (exit $ac_status); } && {
20828          test -z "$ac_c_werror_flag" ||
20829          test ! -s conftest.err
20830        } && test -s conftest$ac_exeext && {
20831          test "$cross_compiling" = yes ||
20832          $as_test_x conftest$ac_exeext
20833        }; then
20834   eval "$as_ac_var=yes"
20835 else
20836   $as_echo "$as_me: failed program was:" >&5
20837 sed 's/^/| /' conftest.$ac_ext >&5
20838
20839         eval "$as_ac_var=no"
20840 fi
20841
20842 rm -rf conftest.dSYM
20843 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20844       conftest$ac_exeext conftest.$ac_ext
20845 fi
20846 ac_res=`eval 'as_val=${'$as_ac_var'}
20847                  $as_echo "$as_val"'`
20848                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20849 $as_echo "$ac_res" >&6; }
20850 as_val=`eval 'as_val=${'$as_ac_var'}
20851                  $as_echo "$as_val"'`
20852    if test "x$as_val" = x""yes; then
20853   cat >>confdefs.h <<_ACEOF
20854 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20855 _ACEOF
20856
20857 else
20858   pgac_need_repl_snprintf=yes
20859 fi
20860 done
20861
20862
20863 for ac_func in vsnprintf
20864 do
20865 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20866 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20867 $as_echo_n "checking for $ac_func... " >&6; }
20868 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20869   $as_echo_n "(cached) " >&6
20870 else
20871   cat >conftest.$ac_ext <<_ACEOF
20872 /* confdefs.h.  */
20873 _ACEOF
20874 cat confdefs.h >>conftest.$ac_ext
20875 cat >>conftest.$ac_ext <<_ACEOF
20876 /* end confdefs.h.  */
20877 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20878    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20879 #define $ac_func innocuous_$ac_func
20880
20881 /* System header to define __stub macros and hopefully few prototypes,
20882     which can conflict with char $ac_func (); below.
20883     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20884     <limits.h> exists even on freestanding compilers.  */
20885
20886 #ifdef __STDC__
20887 # include <limits.h>
20888 #else
20889 # include <assert.h>
20890 #endif
20891
20892 #undef $ac_func
20893
20894 /* Override any GCC internal prototype to avoid an error.
20895    Use char because int might match the return type of a GCC
20896    builtin and then its argument prototype would still apply.  */
20897 #ifdef __cplusplus
20898 extern "C"
20899 #endif
20900 char $ac_func ();
20901 /* The GNU C library defines this for functions which it implements
20902     to always fail with ENOSYS.  Some functions are actually named
20903     something starting with __ and the normal name is an alias.  */
20904 #if defined __stub_$ac_func || defined __stub___$ac_func
20905 choke me
20906 #endif
20907
20908 int
20909 main ()
20910 {
20911 return $ac_func ();
20912   ;
20913   return 0;
20914 }
20915 _ACEOF
20916 rm -f conftest.$ac_objext conftest$ac_exeext
20917 if { (ac_try="$ac_link"
20918 case "(($ac_try" in
20919   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20920   *) ac_try_echo=$ac_try;;
20921 esac
20922 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20923 $as_echo "$ac_try_echo") >&5
20924   (eval "$ac_link") 2>conftest.er1
20925   ac_status=$?
20926   grep -v '^ *+' conftest.er1 >conftest.err
20927   rm -f conftest.er1
20928   cat conftest.err >&5
20929   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20930   (exit $ac_status); } && {
20931          test -z "$ac_c_werror_flag" ||
20932          test ! -s conftest.err
20933        } && test -s conftest$ac_exeext && {
20934          test "$cross_compiling" = yes ||
20935          $as_test_x conftest$ac_exeext
20936        }; then
20937   eval "$as_ac_var=yes"
20938 else
20939   $as_echo "$as_me: failed program was:" >&5
20940 sed 's/^/| /' conftest.$ac_ext >&5
20941
20942         eval "$as_ac_var=no"
20943 fi
20944
20945 rm -rf conftest.dSYM
20946 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20947       conftest$ac_exeext conftest.$ac_ext
20948 fi
20949 ac_res=`eval 'as_val=${'$as_ac_var'}
20950                  $as_echo "$as_val"'`
20951                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20952 $as_echo "$ac_res" >&6; }
20953 as_val=`eval 'as_val=${'$as_ac_var'}
20954                  $as_echo "$as_val"'`
20955    if test "x$as_val" = x""yes; then
20956   cat >>confdefs.h <<_ACEOF
20957 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20958 _ACEOF
20959
20960 else
20961   pgac_need_repl_snprintf=yes
20962 fi
20963 done
20964
20965 fi
20966
20967
20968 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
20969 # include/c.h will provide declarations.  Note this is a separate test
20970 # from whether the functions exist in the C library --- there are
20971 # systems that have the functions but don't bother to declare them :-(
20972
20973 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
20974 $as_echo_n "checking whether snprintf is declared... " >&6; }
20975 if test "${ac_cv_have_decl_snprintf+set}" = set; then
20976   $as_echo_n "(cached) " >&6
20977 else
20978   cat >conftest.$ac_ext <<_ACEOF
20979 /* confdefs.h.  */
20980 _ACEOF
20981 cat confdefs.h >>conftest.$ac_ext
20982 cat >>conftest.$ac_ext <<_ACEOF
20983 /* end confdefs.h.  */
20984 $ac_includes_default
20985 int
20986 main ()
20987 {
20988 #ifndef snprintf
20989   (void) snprintf;
20990 #endif
20991
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   ac_cv_have_decl_snprintf=yes
21015 else
21016   $as_echo "$as_me: failed program was:" >&5
21017 sed 's/^/| /' conftest.$ac_ext >&5
21018
21019         ac_cv_have_decl_snprintf=no
21020 fi
21021
21022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21023 fi
21024 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
21025 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
21026 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
21027
21028 cat >>confdefs.h <<_ACEOF
21029 #define HAVE_DECL_SNPRINTF 1
21030 _ACEOF
21031
21032
21033 else
21034   cat >>confdefs.h <<_ACEOF
21035 #define HAVE_DECL_SNPRINTF 0
21036 _ACEOF
21037
21038
21039 fi
21040 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
21041 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
21042 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
21043   $as_echo_n "(cached) " >&6
21044 else
21045   cat >conftest.$ac_ext <<_ACEOF
21046 /* confdefs.h.  */
21047 _ACEOF
21048 cat confdefs.h >>conftest.$ac_ext
21049 cat >>conftest.$ac_ext <<_ACEOF
21050 /* end confdefs.h.  */
21051 $ac_includes_default
21052 int
21053 main ()
21054 {
21055 #ifndef vsnprintf
21056   (void) vsnprintf;
21057 #endif
21058
21059   ;
21060   return 0;
21061 }
21062 _ACEOF
21063 rm -f conftest.$ac_objext
21064 if { (ac_try="$ac_compile"
21065 case "(($ac_try" in
21066   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21067   *) ac_try_echo=$ac_try;;
21068 esac
21069 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21070 $as_echo "$ac_try_echo") >&5
21071   (eval "$ac_compile") 2>conftest.er1
21072   ac_status=$?
21073   grep -v '^ *+' conftest.er1 >conftest.err
21074   rm -f conftest.er1
21075   cat conftest.err >&5
21076   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21077   (exit $ac_status); } && {
21078          test -z "$ac_c_werror_flag" ||
21079          test ! -s conftest.err
21080        } && test -s conftest.$ac_objext; then
21081   ac_cv_have_decl_vsnprintf=yes
21082 else
21083   $as_echo "$as_me: failed program was:" >&5
21084 sed 's/^/| /' conftest.$ac_ext >&5
21085
21086         ac_cv_have_decl_vsnprintf=no
21087 fi
21088
21089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21090 fi
21091 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
21092 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
21093 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
21094
21095 cat >>confdefs.h <<_ACEOF
21096 #define HAVE_DECL_VSNPRINTF 1
21097 _ACEOF
21098
21099
21100 else
21101   cat >>confdefs.h <<_ACEOF
21102 #define HAVE_DECL_VSNPRINTF 0
21103 _ACEOF
21104
21105
21106 fi
21107
21108
21109
21110
21111 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
21112 $as_echo_n "checking for isinf... " >&6; }
21113 if test "${ac_cv_func_isinf+set}" = set; then
21114   $as_echo_n "(cached) " >&6
21115 else
21116   cat >conftest.$ac_ext <<_ACEOF
21117 /* confdefs.h.  */
21118 _ACEOF
21119 cat confdefs.h >>conftest.$ac_ext
21120 cat >>conftest.$ac_ext <<_ACEOF
21121 /* end confdefs.h.  */
21122
21123 #include <math.h>
21124 double glob_double;
21125
21126 int
21127 main ()
21128 {
21129 return isinf(glob_double) ? 0 : 1;
21130   ;
21131   return 0;
21132 }
21133 _ACEOF
21134 rm -f conftest.$ac_objext conftest$ac_exeext
21135 if { (ac_try="$ac_link"
21136 case "(($ac_try" in
21137   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21138   *) ac_try_echo=$ac_try;;
21139 esac
21140 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21141 $as_echo "$ac_try_echo") >&5
21142   (eval "$ac_link") 2>conftest.er1
21143   ac_status=$?
21144   grep -v '^ *+' conftest.er1 >conftest.err
21145   rm -f conftest.er1
21146   cat conftest.err >&5
21147   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21148   (exit $ac_status); } && {
21149          test -z "$ac_c_werror_flag" ||
21150          test ! -s conftest.err
21151        } && test -s conftest$ac_exeext && {
21152          test "$cross_compiling" = yes ||
21153          $as_test_x conftest$ac_exeext
21154        }; then
21155   ac_cv_func_isinf=yes
21156 else
21157   $as_echo "$as_me: failed program was:" >&5
21158 sed 's/^/| /' conftest.$ac_ext >&5
21159
21160         ac_cv_func_isinf=no
21161 fi
21162
21163 rm -rf conftest.dSYM
21164 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21165       conftest$ac_exeext conftest.$ac_ext
21166 fi
21167 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
21168 $as_echo "$ac_cv_func_isinf" >&6; }
21169
21170 if test $ac_cv_func_isinf = yes ; then
21171
21172 cat >>confdefs.h <<\_ACEOF
21173 #define HAVE_ISINF 1
21174 _ACEOF
21175
21176 else
21177   case " $LIBOBJS " in
21178   *" isinf.$ac_objext "* ) ;;
21179   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
21180  ;;
21181 esac
21182
21183   # Look for a way to implement a substitute for isinf()
21184
21185
21186
21187
21188 for ac_func in fpclass fp_class fp_class_d class
21189 do
21190 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21191 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21192 $as_echo_n "checking for $ac_func... " >&6; }
21193 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21194   $as_echo_n "(cached) " >&6
21195 else
21196   cat >conftest.$ac_ext <<_ACEOF
21197 /* confdefs.h.  */
21198 _ACEOF
21199 cat confdefs.h >>conftest.$ac_ext
21200 cat >>conftest.$ac_ext <<_ACEOF
21201 /* end confdefs.h.  */
21202 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21203    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21204 #define $ac_func innocuous_$ac_func
21205
21206 /* System header to define __stub macros and hopefully few prototypes,
21207     which can conflict with char $ac_func (); below.
21208     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21209     <limits.h> exists even on freestanding compilers.  */
21210
21211 #ifdef __STDC__
21212 # include <limits.h>
21213 #else
21214 # include <assert.h>
21215 #endif
21216
21217 #undef $ac_func
21218
21219 /* Override any GCC internal prototype to avoid an error.
21220    Use char because int might match the return type of a GCC
21221    builtin and then its argument prototype would still apply.  */
21222 #ifdef __cplusplus
21223 extern "C"
21224 #endif
21225 char $ac_func ();
21226 /* The GNU C library defines this for functions which it implements
21227     to always fail with ENOSYS.  Some functions are actually named
21228     something starting with __ and the normal name is an alias.  */
21229 #if defined __stub_$ac_func || defined __stub___$ac_func
21230 choke me
21231 #endif
21232
21233 int
21234 main ()
21235 {
21236 return $ac_func ();
21237   ;
21238   return 0;
21239 }
21240 _ACEOF
21241 rm -f conftest.$ac_objext conftest$ac_exeext
21242 if { (ac_try="$ac_link"
21243 case "(($ac_try" in
21244   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21245   *) ac_try_echo=$ac_try;;
21246 esac
21247 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21248 $as_echo "$ac_try_echo") >&5
21249   (eval "$ac_link") 2>conftest.er1
21250   ac_status=$?
21251   grep -v '^ *+' conftest.er1 >conftest.err
21252   rm -f conftest.er1
21253   cat conftest.err >&5
21254   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21255   (exit $ac_status); } && {
21256          test -z "$ac_c_werror_flag" ||
21257          test ! -s conftest.err
21258        } && test -s conftest$ac_exeext && {
21259          test "$cross_compiling" = yes ||
21260          $as_test_x conftest$ac_exeext
21261        }; then
21262   eval "$as_ac_var=yes"
21263 else
21264   $as_echo "$as_me: failed program was:" >&5
21265 sed 's/^/| /' conftest.$ac_ext >&5
21266
21267         eval "$as_ac_var=no"
21268 fi
21269
21270 rm -rf conftest.dSYM
21271 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21272       conftest$ac_exeext conftest.$ac_ext
21273 fi
21274 ac_res=`eval 'as_val=${'$as_ac_var'}
21275                  $as_echo "$as_val"'`
21276                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21277 $as_echo "$ac_res" >&6; }
21278 as_val=`eval 'as_val=${'$as_ac_var'}
21279                  $as_echo "$as_val"'`
21280    if test "x$as_val" = x""yes; then
21281   cat >>confdefs.h <<_ACEOF
21282 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21283 _ACEOF
21284  break
21285 fi
21286 done
21287
21288 fi
21289
21290
21291
21292
21293
21294
21295
21296
21297
21298
21299
21300
21301 for ac_func in crypt fls getopt getrusage inet_aton random rint srandom strerror strlcat strlcpy
21302 do
21303 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21304 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21305 $as_echo_n "checking for $ac_func... " >&6; }
21306 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21307   $as_echo_n "(cached) " >&6
21308 else
21309   cat >conftest.$ac_ext <<_ACEOF
21310 /* confdefs.h.  */
21311 _ACEOF
21312 cat confdefs.h >>conftest.$ac_ext
21313 cat >>conftest.$ac_ext <<_ACEOF
21314 /* end confdefs.h.  */
21315 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21316    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21317 #define $ac_func innocuous_$ac_func
21318
21319 /* System header to define __stub macros and hopefully few prototypes,
21320     which can conflict with char $ac_func (); below.
21321     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21322     <limits.h> exists even on freestanding compilers.  */
21323
21324 #ifdef __STDC__
21325 # include <limits.h>
21326 #else
21327 # include <assert.h>
21328 #endif
21329
21330 #undef $ac_func
21331
21332 /* Override any GCC internal prototype to avoid an error.
21333    Use char because int might match the return type of a GCC
21334    builtin and then its argument prototype would still apply.  */
21335 #ifdef __cplusplus
21336 extern "C"
21337 #endif
21338 char $ac_func ();
21339 /* The GNU C library defines this for functions which it implements
21340     to always fail with ENOSYS.  Some functions are actually named
21341     something starting with __ and the normal name is an alias.  */
21342 #if defined __stub_$ac_func || defined __stub___$ac_func
21343 choke me
21344 #endif
21345
21346 int
21347 main ()
21348 {
21349 return $ac_func ();
21350   ;
21351   return 0;
21352 }
21353 _ACEOF
21354 rm -f conftest.$ac_objext conftest$ac_exeext
21355 if { (ac_try="$ac_link"
21356 case "(($ac_try" in
21357   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21358   *) ac_try_echo=$ac_try;;
21359 esac
21360 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21361 $as_echo "$ac_try_echo") >&5
21362   (eval "$ac_link") 2>conftest.er1
21363   ac_status=$?
21364   grep -v '^ *+' conftest.er1 >conftest.err
21365   rm -f conftest.er1
21366   cat conftest.err >&5
21367   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21368   (exit $ac_status); } && {
21369          test -z "$ac_c_werror_flag" ||
21370          test ! -s conftest.err
21371        } && test -s conftest$ac_exeext && {
21372          test "$cross_compiling" = yes ||
21373          $as_test_x conftest$ac_exeext
21374        }; then
21375   eval "$as_ac_var=yes"
21376 else
21377   $as_echo "$as_me: failed program was:" >&5
21378 sed 's/^/| /' conftest.$ac_ext >&5
21379
21380         eval "$as_ac_var=no"
21381 fi
21382
21383 rm -rf conftest.dSYM
21384 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21385       conftest$ac_exeext conftest.$ac_ext
21386 fi
21387 ac_res=`eval 'as_val=${'$as_ac_var'}
21388                  $as_echo "$as_val"'`
21389                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21390 $as_echo "$ac_res" >&6; }
21391 as_val=`eval 'as_val=${'$as_ac_var'}
21392                  $as_echo "$as_val"'`
21393    if test "x$as_val" = x""yes; then
21394   cat >>confdefs.h <<_ACEOF
21395 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21396 _ACEOF
21397
21398 else
21399   case " $LIBOBJS " in
21400   *" $ac_func.$ac_objext "* ) ;;
21401   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21402  ;;
21403 esac
21404
21405 fi
21406 done
21407
21408
21409
21410 case $host_os in
21411
21412         # Windows uses a specialised env handler
21413         # and doesn't need a replacement getpeereid because it doesn't use
21414         # Unix sockets.
21415         mingw*)
21416
21417 cat >>confdefs.h <<\_ACEOF
21418 #define HAVE_UNSETENV 1
21419 _ACEOF
21420
21421
21422 cat >>confdefs.h <<\_ACEOF
21423 #define HAVE_GETPEEREID 1
21424 _ACEOF
21425
21426                 ac_cv_func_unsetenv=yes
21427                 ac_cv_func_getpeereid=yes;;
21428         *)
21429
21430
21431 for ac_func in unsetenv getpeereid
21432 do
21433 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21434 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21435 $as_echo_n "checking for $ac_func... " >&6; }
21436 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21437   $as_echo_n "(cached) " >&6
21438 else
21439   cat >conftest.$ac_ext <<_ACEOF
21440 /* confdefs.h.  */
21441 _ACEOF
21442 cat confdefs.h >>conftest.$ac_ext
21443 cat >>conftest.$ac_ext <<_ACEOF
21444 /* end confdefs.h.  */
21445 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21446    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21447 #define $ac_func innocuous_$ac_func
21448
21449 /* System header to define __stub macros and hopefully few prototypes,
21450     which can conflict with char $ac_func (); below.
21451     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21452     <limits.h> exists even on freestanding compilers.  */
21453
21454 #ifdef __STDC__
21455 # include <limits.h>
21456 #else
21457 # include <assert.h>
21458 #endif
21459
21460 #undef $ac_func
21461
21462 /* Override any GCC internal prototype to avoid an error.
21463    Use char because int might match the return type of a GCC
21464    builtin and then its argument prototype would still apply.  */
21465 #ifdef __cplusplus
21466 extern "C"
21467 #endif
21468 char $ac_func ();
21469 /* The GNU C library defines this for functions which it implements
21470     to always fail with ENOSYS.  Some functions are actually named
21471     something starting with __ and the normal name is an alias.  */
21472 #if defined __stub_$ac_func || defined __stub___$ac_func
21473 choke me
21474 #endif
21475
21476 int
21477 main ()
21478 {
21479 return $ac_func ();
21480   ;
21481   return 0;
21482 }
21483 _ACEOF
21484 rm -f conftest.$ac_objext conftest$ac_exeext
21485 if { (ac_try="$ac_link"
21486 case "(($ac_try" in
21487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21488   *) ac_try_echo=$ac_try;;
21489 esac
21490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21491 $as_echo "$ac_try_echo") >&5
21492   (eval "$ac_link") 2>conftest.er1
21493   ac_status=$?
21494   grep -v '^ *+' conftest.er1 >conftest.err
21495   rm -f conftest.er1
21496   cat conftest.err >&5
21497   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21498   (exit $ac_status); } && {
21499          test -z "$ac_c_werror_flag" ||
21500          test ! -s conftest.err
21501        } && test -s conftest$ac_exeext && {
21502          test "$cross_compiling" = yes ||
21503          $as_test_x conftest$ac_exeext
21504        }; then
21505   eval "$as_ac_var=yes"
21506 else
21507   $as_echo "$as_me: failed program was:" >&5
21508 sed 's/^/| /' conftest.$ac_ext >&5
21509
21510         eval "$as_ac_var=no"
21511 fi
21512
21513 rm -rf conftest.dSYM
21514 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21515       conftest$ac_exeext conftest.$ac_ext
21516 fi
21517 ac_res=`eval 'as_val=${'$as_ac_var'}
21518                  $as_echo "$as_val"'`
21519                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21520 $as_echo "$ac_res" >&6; }
21521 as_val=`eval 'as_val=${'$as_ac_var'}
21522                  $as_echo "$as_val"'`
21523    if test "x$as_val" = x""yes; then
21524   cat >>confdefs.h <<_ACEOF
21525 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21526 _ACEOF
21527
21528 else
21529   case " $LIBOBJS " in
21530   *" $ac_func.$ac_objext "* ) ;;
21531   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21532  ;;
21533 esac
21534
21535 fi
21536 done
21537
21538
21539                 ;;
21540 esac
21541
21542 # System's version of getaddrinfo(), if any, may be used only if we found
21543 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
21544 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
21545 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
21546 # because we want to use our own getaddrinfo.c on Windows anyway.)
21547 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
21548
21549 for ac_func in getaddrinfo
21550 do
21551 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21552 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21553 $as_echo_n "checking for $ac_func... " >&6; }
21554 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21555   $as_echo_n "(cached) " >&6
21556 else
21557   cat >conftest.$ac_ext <<_ACEOF
21558 /* confdefs.h.  */
21559 _ACEOF
21560 cat confdefs.h >>conftest.$ac_ext
21561 cat >>conftest.$ac_ext <<_ACEOF
21562 /* end confdefs.h.  */
21563 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21564    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21565 #define $ac_func innocuous_$ac_func
21566
21567 /* System header to define __stub macros and hopefully few prototypes,
21568     which can conflict with char $ac_func (); below.
21569     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21570     <limits.h> exists even on freestanding compilers.  */
21571
21572 #ifdef __STDC__
21573 # include <limits.h>
21574 #else
21575 # include <assert.h>
21576 #endif
21577
21578 #undef $ac_func
21579
21580 /* Override any GCC internal prototype to avoid an error.
21581    Use char because int might match the return type of a GCC
21582    builtin and then its argument prototype would still apply.  */
21583 #ifdef __cplusplus
21584 extern "C"
21585 #endif
21586 char $ac_func ();
21587 /* The GNU C library defines this for functions which it implements
21588     to always fail with ENOSYS.  Some functions are actually named
21589     something starting with __ and the normal name is an alias.  */
21590 #if defined __stub_$ac_func || defined __stub___$ac_func
21591 choke me
21592 #endif
21593
21594 int
21595 main ()
21596 {
21597 return $ac_func ();
21598   ;
21599   return 0;
21600 }
21601 _ACEOF
21602 rm -f conftest.$ac_objext conftest$ac_exeext
21603 if { (ac_try="$ac_link"
21604 case "(($ac_try" in
21605   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21606   *) ac_try_echo=$ac_try;;
21607 esac
21608 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21609 $as_echo "$ac_try_echo") >&5
21610   (eval "$ac_link") 2>conftest.er1
21611   ac_status=$?
21612   grep -v '^ *+' conftest.er1 >conftest.err
21613   rm -f conftest.er1
21614   cat conftest.err >&5
21615   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21616   (exit $ac_status); } && {
21617          test -z "$ac_c_werror_flag" ||
21618          test ! -s conftest.err
21619        } && test -s conftest$ac_exeext && {
21620          test "$cross_compiling" = yes ||
21621          $as_test_x conftest$ac_exeext
21622        }; then
21623   eval "$as_ac_var=yes"
21624 else
21625   $as_echo "$as_me: failed program was:" >&5
21626 sed 's/^/| /' conftest.$ac_ext >&5
21627
21628         eval "$as_ac_var=no"
21629 fi
21630
21631 rm -rf conftest.dSYM
21632 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21633       conftest$ac_exeext conftest.$ac_ext
21634 fi
21635 ac_res=`eval 'as_val=${'$as_ac_var'}
21636                  $as_echo "$as_val"'`
21637                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21638 $as_echo "$ac_res" >&6; }
21639 as_val=`eval 'as_val=${'$as_ac_var'}
21640                  $as_echo "$as_val"'`
21641    if test "x$as_val" = x""yes; then
21642   cat >>confdefs.h <<_ACEOF
21643 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21644 _ACEOF
21645
21646 else
21647   case " $LIBOBJS " in
21648   *" $ac_func.$ac_objext "* ) ;;
21649   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21650  ;;
21651 esac
21652
21653 fi
21654 done
21655
21656
21657 else
21658   case " $LIBOBJS " in
21659   *" getaddrinfo.$ac_objext "* ) ;;
21660   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
21661  ;;
21662 esac
21663
21664 fi
21665
21666 # Similarly, use system's getopt_long() only if system provides struct option.
21667 if test x"$ac_cv_type_struct_option" = xyes ; then
21668
21669 for ac_func in getopt_long
21670 do
21671 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21672 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21673 $as_echo_n "checking for $ac_func... " >&6; }
21674 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21675   $as_echo_n "(cached) " >&6
21676 else
21677   cat >conftest.$ac_ext <<_ACEOF
21678 /* confdefs.h.  */
21679 _ACEOF
21680 cat confdefs.h >>conftest.$ac_ext
21681 cat >>conftest.$ac_ext <<_ACEOF
21682 /* end confdefs.h.  */
21683 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21684    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21685 #define $ac_func innocuous_$ac_func
21686
21687 /* System header to define __stub macros and hopefully few prototypes,
21688     which can conflict with char $ac_func (); below.
21689     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21690     <limits.h> exists even on freestanding compilers.  */
21691
21692 #ifdef __STDC__
21693 # include <limits.h>
21694 #else
21695 # include <assert.h>
21696 #endif
21697
21698 #undef $ac_func
21699
21700 /* Override any GCC internal prototype to avoid an error.
21701    Use char because int might match the return type of a GCC
21702    builtin and then its argument prototype would still apply.  */
21703 #ifdef __cplusplus
21704 extern "C"
21705 #endif
21706 char $ac_func ();
21707 /* The GNU C library defines this for functions which it implements
21708     to always fail with ENOSYS.  Some functions are actually named
21709     something starting with __ and the normal name is an alias.  */
21710 #if defined __stub_$ac_func || defined __stub___$ac_func
21711 choke me
21712 #endif
21713
21714 int
21715 main ()
21716 {
21717 return $ac_func ();
21718   ;
21719   return 0;
21720 }
21721 _ACEOF
21722 rm -f conftest.$ac_objext conftest$ac_exeext
21723 if { (ac_try="$ac_link"
21724 case "(($ac_try" in
21725   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21726   *) ac_try_echo=$ac_try;;
21727 esac
21728 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21729 $as_echo "$ac_try_echo") >&5
21730   (eval "$ac_link") 2>conftest.er1
21731   ac_status=$?
21732   grep -v '^ *+' conftest.er1 >conftest.err
21733   rm -f conftest.er1
21734   cat conftest.err >&5
21735   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21736   (exit $ac_status); } && {
21737          test -z "$ac_c_werror_flag" ||
21738          test ! -s conftest.err
21739        } && test -s conftest$ac_exeext && {
21740          test "$cross_compiling" = yes ||
21741          $as_test_x conftest$ac_exeext
21742        }; then
21743   eval "$as_ac_var=yes"
21744 else
21745   $as_echo "$as_me: failed program was:" >&5
21746 sed 's/^/| /' conftest.$ac_ext >&5
21747
21748         eval "$as_ac_var=no"
21749 fi
21750
21751 rm -rf conftest.dSYM
21752 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21753       conftest$ac_exeext conftest.$ac_ext
21754 fi
21755 ac_res=`eval 'as_val=${'$as_ac_var'}
21756                  $as_echo "$as_val"'`
21757                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21758 $as_echo "$ac_res" >&6; }
21759 as_val=`eval 'as_val=${'$as_ac_var'}
21760                  $as_echo "$as_val"'`
21761    if test "x$as_val" = x""yes; then
21762   cat >>confdefs.h <<_ACEOF
21763 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21764 _ACEOF
21765
21766 else
21767   case " $LIBOBJS " in
21768   *" $ac_func.$ac_objext "* ) ;;
21769   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21770  ;;
21771 esac
21772
21773 fi
21774 done
21775
21776
21777 else
21778   case " $LIBOBJS " in
21779   *" getopt_long.$ac_objext "* ) ;;
21780   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
21781  ;;
21782 esac
21783
21784 fi
21785
21786 # Solaris' getopt() doesn't do what we want for long options, so always use
21787 # our version on that platform.
21788 if test "$PORTNAME" = "solaris"; then
21789   case " $LIBOBJS " in
21790   *" getopt.$ac_objext "* ) ;;
21791   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
21792  ;;
21793 esac
21794
21795 fi
21796
21797 # mingw has adopted a GNU-centric interpretation of optind/optreset,
21798 # so always use our version on Windows.
21799 if test "$PORTNAME" = "win32"; then
21800   case " $LIBOBJS " in
21801   *" getopt.$ac_objext "* ) ;;
21802   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
21803  ;;
21804 esac
21805
21806   case " $LIBOBJS " in
21807   *" getopt_long.$ac_objext "* ) ;;
21808   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
21809  ;;
21810 esac
21811
21812 fi
21813
21814 # Win32 support
21815 if test "$PORTNAME" = "win32"; then
21816
21817 for ac_func in gettimeofday
21818 do
21819 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21820 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21821 $as_echo_n "checking for $ac_func... " >&6; }
21822 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21823   $as_echo_n "(cached) " >&6
21824 else
21825   cat >conftest.$ac_ext <<_ACEOF
21826 /* confdefs.h.  */
21827 _ACEOF
21828 cat confdefs.h >>conftest.$ac_ext
21829 cat >>conftest.$ac_ext <<_ACEOF
21830 /* end confdefs.h.  */
21831 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21832    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21833 #define $ac_func innocuous_$ac_func
21834
21835 /* System header to define __stub macros and hopefully few prototypes,
21836     which can conflict with char $ac_func (); below.
21837     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21838     <limits.h> exists even on freestanding compilers.  */
21839
21840 #ifdef __STDC__
21841 # include <limits.h>
21842 #else
21843 # include <assert.h>
21844 #endif
21845
21846 #undef $ac_func
21847
21848 /* Override any GCC internal prototype to avoid an error.
21849    Use char because int might match the return type of a GCC
21850    builtin and then its argument prototype would still apply.  */
21851 #ifdef __cplusplus
21852 extern "C"
21853 #endif
21854 char $ac_func ();
21855 /* The GNU C library defines this for functions which it implements
21856     to always fail with ENOSYS.  Some functions are actually named
21857     something starting with __ and the normal name is an alias.  */
21858 #if defined __stub_$ac_func || defined __stub___$ac_func
21859 choke me
21860 #endif
21861
21862 int
21863 main ()
21864 {
21865 return $ac_func ();
21866   ;
21867   return 0;
21868 }
21869 _ACEOF
21870 rm -f conftest.$ac_objext conftest$ac_exeext
21871 if { (ac_try="$ac_link"
21872 case "(($ac_try" in
21873   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21874   *) ac_try_echo=$ac_try;;
21875 esac
21876 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21877 $as_echo "$ac_try_echo") >&5
21878   (eval "$ac_link") 2>conftest.er1
21879   ac_status=$?
21880   grep -v '^ *+' conftest.er1 >conftest.err
21881   rm -f conftest.er1
21882   cat conftest.err >&5
21883   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21884   (exit $ac_status); } && {
21885          test -z "$ac_c_werror_flag" ||
21886          test ! -s conftest.err
21887        } && test -s conftest$ac_exeext && {
21888          test "$cross_compiling" = yes ||
21889          $as_test_x conftest$ac_exeext
21890        }; then
21891   eval "$as_ac_var=yes"
21892 else
21893   $as_echo "$as_me: failed program was:" >&5
21894 sed 's/^/| /' conftest.$ac_ext >&5
21895
21896         eval "$as_ac_var=no"
21897 fi
21898
21899 rm -rf conftest.dSYM
21900 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21901       conftest$ac_exeext conftest.$ac_ext
21902 fi
21903 ac_res=`eval 'as_val=${'$as_ac_var'}
21904                  $as_echo "$as_val"'`
21905                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21906 $as_echo "$ac_res" >&6; }
21907 as_val=`eval 'as_val=${'$as_ac_var'}
21908                  $as_echo "$as_val"'`
21909    if test "x$as_val" = x""yes; then
21910   cat >>confdefs.h <<_ACEOF
21911 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21912 _ACEOF
21913
21914 else
21915   case " $LIBOBJS " in
21916   *" $ac_func.$ac_objext "* ) ;;
21917   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21918  ;;
21919 esac
21920
21921 fi
21922 done
21923
21924
21925   case " $LIBOBJS " in
21926   *" kill.$ac_objext "* ) ;;
21927   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
21928  ;;
21929 esac
21930
21931   case " $LIBOBJS " in
21932   *" open.$ac_objext "* ) ;;
21933   *) LIBOBJS="$LIBOBJS open.$ac_objext"
21934  ;;
21935 esac
21936
21937   case " $LIBOBJS " in
21938   *" win32env.$ac_objext "* ) ;;
21939   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
21940  ;;
21941 esac
21942
21943   case " $LIBOBJS " in
21944   *" win32error.$ac_objext "* ) ;;
21945   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
21946  ;;
21947 esac
21948
21949   case " $LIBOBJS " in
21950   *" win32setlocale.$ac_objext "* ) ;;
21951   *) LIBOBJS="$LIBOBJS win32setlocale.$ac_objext"
21952  ;;
21953 esac
21954
21955
21956 cat >>confdefs.h <<\_ACEOF
21957 #define HAVE_SYMLINK 1
21958 _ACEOF
21959
21960   { $as_echo "$as_me:$LINENO: checking for MINIDUMP_TYPE" >&5
21961 $as_echo_n "checking for MINIDUMP_TYPE... " >&6; }
21962 if test "${ac_cv_type_MINIDUMP_TYPE+set}" = set; then
21963   $as_echo_n "(cached) " >&6
21964 else
21965   ac_cv_type_MINIDUMP_TYPE=no
21966 cat >conftest.$ac_ext <<_ACEOF
21967 /* confdefs.h.  */
21968 _ACEOF
21969 cat confdefs.h >>conftest.$ac_ext
21970 cat >>conftest.$ac_ext <<_ACEOF
21971 /* end confdefs.h.  */
21972
21973 #define WIN32_LEAN_AND_MEAN
21974 #include <windows.h>
21975 #include <string.h>
21976 #include <dbghelp.h>
21977
21978 int
21979 main ()
21980 {
21981 if (sizeof (MINIDUMP_TYPE))
21982        return 0;
21983   ;
21984   return 0;
21985 }
21986 _ACEOF
21987 rm -f conftest.$ac_objext
21988 if { (ac_try="$ac_compile"
21989 case "(($ac_try" in
21990   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21991   *) ac_try_echo=$ac_try;;
21992 esac
21993 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21994 $as_echo "$ac_try_echo") >&5
21995   (eval "$ac_compile") 2>conftest.er1
21996   ac_status=$?
21997   grep -v '^ *+' conftest.er1 >conftest.err
21998   rm -f conftest.er1
21999   cat conftest.err >&5
22000   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22001   (exit $ac_status); } && {
22002          test -z "$ac_c_werror_flag" ||
22003          test ! -s conftest.err
22004        } && test -s conftest.$ac_objext; then
22005   cat >conftest.$ac_ext <<_ACEOF
22006 /* confdefs.h.  */
22007 _ACEOF
22008 cat confdefs.h >>conftest.$ac_ext
22009 cat >>conftest.$ac_ext <<_ACEOF
22010 /* end confdefs.h.  */
22011
22012 #define WIN32_LEAN_AND_MEAN
22013 #include <windows.h>
22014 #include <string.h>
22015 #include <dbghelp.h>
22016
22017 int
22018 main ()
22019 {
22020 if (sizeof ((MINIDUMP_TYPE)))
22021           return 0;
22022   ;
22023   return 0;
22024 }
22025 _ACEOF
22026 rm -f conftest.$ac_objext
22027 if { (ac_try="$ac_compile"
22028 case "(($ac_try" in
22029   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22030   *) ac_try_echo=$ac_try;;
22031 esac
22032 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22033 $as_echo "$ac_try_echo") >&5
22034   (eval "$ac_compile") 2>conftest.er1
22035   ac_status=$?
22036   grep -v '^ *+' conftest.er1 >conftest.err
22037   rm -f conftest.er1
22038   cat conftest.err >&5
22039   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22040   (exit $ac_status); } && {
22041          test -z "$ac_c_werror_flag" ||
22042          test ! -s conftest.err
22043        } && test -s conftest.$ac_objext; then
22044   :
22045 else
22046   $as_echo "$as_me: failed program was:" >&5
22047 sed 's/^/| /' conftest.$ac_ext >&5
22048
22049         ac_cv_type_MINIDUMP_TYPE=yes
22050 fi
22051
22052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22053 else
22054   $as_echo "$as_me: failed program was:" >&5
22055 sed 's/^/| /' conftest.$ac_ext >&5
22056
22057
22058 fi
22059
22060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22061 fi
22062 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_MINIDUMP_TYPE" >&5
22063 $as_echo "$ac_cv_type_MINIDUMP_TYPE" >&6; }
22064 if test "x$ac_cv_type_MINIDUMP_TYPE" = x""yes; then
22065
22066 cat >>confdefs.h <<_ACEOF
22067 #define HAVE_MINIDUMP_TYPE 1
22068 _ACEOF
22069
22070 pgac_minidump_type=yes
22071 else
22072   pgac_minidump_type=no
22073 fi
22074
22075 fi
22076 if test x"$pgac_minidump_type" = x"yes" ; then
22077   have_win32_dbghelp=yes
22078
22079 else
22080   have_win32_dbghelp=no
22081
22082 fi
22083
22084 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
22085 $as_echo_n "checking for sigsetjmp... " >&6; }
22086 if test "${pgac_cv_func_sigsetjmp+set}" = set; then
22087   $as_echo_n "(cached) " >&6
22088 else
22089   cat >conftest.$ac_ext <<_ACEOF
22090 /* confdefs.h.  */
22091 _ACEOF
22092 cat confdefs.h >>conftest.$ac_ext
22093 cat >>conftest.$ac_ext <<_ACEOF
22094 /* end confdefs.h.  */
22095 #include <setjmp.h>
22096 int
22097 main ()
22098 {
22099 sigjmp_buf x; sigsetjmp(x, 1);
22100   ;
22101   return 0;
22102 }
22103 _ACEOF
22104 rm -f conftest.$ac_objext conftest$ac_exeext
22105 if { (ac_try="$ac_link"
22106 case "(($ac_try" in
22107   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22108   *) ac_try_echo=$ac_try;;
22109 esac
22110 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22111 $as_echo "$ac_try_echo") >&5
22112   (eval "$ac_link") 2>conftest.er1
22113   ac_status=$?
22114   grep -v '^ *+' conftest.er1 >conftest.err
22115   rm -f conftest.er1
22116   cat conftest.err >&5
22117   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22118   (exit $ac_status); } && {
22119          test -z "$ac_c_werror_flag" ||
22120          test ! -s conftest.err
22121        } && test -s conftest$ac_exeext && {
22122          test "$cross_compiling" = yes ||
22123          $as_test_x conftest$ac_exeext
22124        }; then
22125   pgac_cv_func_sigsetjmp=yes
22126 else
22127   $as_echo "$as_me: failed program was:" >&5
22128 sed 's/^/| /' conftest.$ac_ext >&5
22129
22130         pgac_cv_func_sigsetjmp=no
22131 fi
22132
22133 rm -rf conftest.dSYM
22134 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22135       conftest$ac_exeext conftest.$ac_ext
22136 fi
22137 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_sigsetjmp" >&5
22138 $as_echo "$pgac_cv_func_sigsetjmp" >&6; }
22139 if test x"$pgac_cv_func_sigsetjmp" = x"yes"; then
22140
22141 cat >>confdefs.h <<\_ACEOF
22142 #define HAVE_SIGSETJMP 1
22143 _ACEOF
22144
22145 fi
22146
22147 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
22148 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
22149 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
22150   $as_echo_n "(cached) " >&6
22151 else
22152   cat >conftest.$ac_ext <<_ACEOF
22153 /* confdefs.h.  */
22154 _ACEOF
22155 cat confdefs.h >>conftest.$ac_ext
22156 cat >>conftest.$ac_ext <<_ACEOF
22157 /* end confdefs.h.  */
22158 #include <signal.h>
22159 /* NetBSD declares sys_siglist in unistd.h.  */
22160 #ifdef HAVE_UNISTD_H
22161 # include <unistd.h>
22162 #endif
22163
22164
22165 int
22166 main ()
22167 {
22168 #ifndef sys_siglist
22169   (void) sys_siglist;
22170 #endif
22171
22172   ;
22173   return 0;
22174 }
22175 _ACEOF
22176 rm -f conftest.$ac_objext
22177 if { (ac_try="$ac_compile"
22178 case "(($ac_try" in
22179   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22180   *) ac_try_echo=$ac_try;;
22181 esac
22182 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22183 $as_echo "$ac_try_echo") >&5
22184   (eval "$ac_compile") 2>conftest.er1
22185   ac_status=$?
22186   grep -v '^ *+' conftest.er1 >conftest.err
22187   rm -f conftest.er1
22188   cat conftest.err >&5
22189   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22190   (exit $ac_status); } && {
22191          test -z "$ac_c_werror_flag" ||
22192          test ! -s conftest.err
22193        } && test -s conftest.$ac_objext; then
22194   ac_cv_have_decl_sys_siglist=yes
22195 else
22196   $as_echo "$as_me: failed program was:" >&5
22197 sed 's/^/| /' conftest.$ac_ext >&5
22198
22199         ac_cv_have_decl_sys_siglist=no
22200 fi
22201
22202 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22203 fi
22204 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
22205 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
22206 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
22207
22208 cat >>confdefs.h <<_ACEOF
22209 #define HAVE_DECL_SYS_SIGLIST 1
22210 _ACEOF
22211
22212
22213 else
22214   cat >>confdefs.h <<_ACEOF
22215 #define HAVE_DECL_SYS_SIGLIST 0
22216 _ACEOF
22217
22218
22219 fi
22220
22221
22222
22223
22224 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
22225 $as_echo_n "checking for syslog... " >&6; }
22226 if test "${ac_cv_func_syslog+set}" = set; then
22227   $as_echo_n "(cached) " >&6
22228 else
22229   cat >conftest.$ac_ext <<_ACEOF
22230 /* confdefs.h.  */
22231 _ACEOF
22232 cat confdefs.h >>conftest.$ac_ext
22233 cat >>conftest.$ac_ext <<_ACEOF
22234 /* end confdefs.h.  */
22235 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
22236    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22237 #define syslog innocuous_syslog
22238
22239 /* System header to define __stub macros and hopefully few prototypes,
22240     which can conflict with char syslog (); below.
22241     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22242     <limits.h> exists even on freestanding compilers.  */
22243
22244 #ifdef __STDC__
22245 # include <limits.h>
22246 #else
22247 # include <assert.h>
22248 #endif
22249
22250 #undef syslog
22251
22252 /* Override any GCC internal prototype to avoid an error.
22253    Use char because int might match the return type of a GCC
22254    builtin and then its argument prototype would still apply.  */
22255 #ifdef __cplusplus
22256 extern "C"
22257 #endif
22258 char syslog ();
22259 /* The GNU C library defines this for functions which it implements
22260     to always fail with ENOSYS.  Some functions are actually named
22261     something starting with __ and the normal name is an alias.  */
22262 #if defined __stub_syslog || defined __stub___syslog
22263 choke me
22264 #endif
22265
22266 int
22267 main ()
22268 {
22269 return syslog ();
22270   ;
22271   return 0;
22272 }
22273 _ACEOF
22274 rm -f conftest.$ac_objext conftest$ac_exeext
22275 if { (ac_try="$ac_link"
22276 case "(($ac_try" in
22277   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22278   *) ac_try_echo=$ac_try;;
22279 esac
22280 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22281 $as_echo "$ac_try_echo") >&5
22282   (eval "$ac_link") 2>conftest.er1
22283   ac_status=$?
22284   grep -v '^ *+' conftest.er1 >conftest.err
22285   rm -f conftest.er1
22286   cat conftest.err >&5
22287   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22288   (exit $ac_status); } && {
22289          test -z "$ac_c_werror_flag" ||
22290          test ! -s conftest.err
22291        } && test -s conftest$ac_exeext && {
22292          test "$cross_compiling" = yes ||
22293          $as_test_x conftest$ac_exeext
22294        }; then
22295   ac_cv_func_syslog=yes
22296 else
22297   $as_echo "$as_me: failed program was:" >&5
22298 sed 's/^/| /' conftest.$ac_ext >&5
22299
22300         ac_cv_func_syslog=no
22301 fi
22302
22303 rm -rf conftest.dSYM
22304 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22305       conftest$ac_exeext conftest.$ac_ext
22306 fi
22307 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
22308 $as_echo "$ac_cv_func_syslog" >&6; }
22309 if test "x$ac_cv_func_syslog" = x""yes; then
22310   if test "${ac_cv_header_syslog_h+set}" = set; then
22311   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
22312 $as_echo_n "checking for syslog.h... " >&6; }
22313 if test "${ac_cv_header_syslog_h+set}" = set; then
22314   $as_echo_n "(cached) " >&6
22315 fi
22316 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
22317 $as_echo "$ac_cv_header_syslog_h" >&6; }
22318 else
22319   # Is the header compilable?
22320 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
22321 $as_echo_n "checking syslog.h usability... " >&6; }
22322 cat >conftest.$ac_ext <<_ACEOF
22323 /* confdefs.h.  */
22324 _ACEOF
22325 cat confdefs.h >>conftest.$ac_ext
22326 cat >>conftest.$ac_ext <<_ACEOF
22327 /* end confdefs.h.  */
22328 $ac_includes_default
22329 #include <syslog.h>
22330 _ACEOF
22331 rm -f conftest.$ac_objext
22332 if { (ac_try="$ac_compile"
22333 case "(($ac_try" in
22334   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22335   *) ac_try_echo=$ac_try;;
22336 esac
22337 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22338 $as_echo "$ac_try_echo") >&5
22339   (eval "$ac_compile") 2>conftest.er1
22340   ac_status=$?
22341   grep -v '^ *+' conftest.er1 >conftest.err
22342   rm -f conftest.er1
22343   cat conftest.err >&5
22344   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22345   (exit $ac_status); } && {
22346          test -z "$ac_c_werror_flag" ||
22347          test ! -s conftest.err
22348        } && test -s conftest.$ac_objext; then
22349   ac_header_compiler=yes
22350 else
22351   $as_echo "$as_me: failed program was:" >&5
22352 sed 's/^/| /' conftest.$ac_ext >&5
22353
22354         ac_header_compiler=no
22355 fi
22356
22357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22358 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22359 $as_echo "$ac_header_compiler" >&6; }
22360
22361 # Is the header present?
22362 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
22363 $as_echo_n "checking syslog.h presence... " >&6; }
22364 cat >conftest.$ac_ext <<_ACEOF
22365 /* confdefs.h.  */
22366 _ACEOF
22367 cat confdefs.h >>conftest.$ac_ext
22368 cat >>conftest.$ac_ext <<_ACEOF
22369 /* end confdefs.h.  */
22370 #include <syslog.h>
22371 _ACEOF
22372 if { (ac_try="$ac_cpp conftest.$ac_ext"
22373 case "(($ac_try" in
22374   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22375   *) ac_try_echo=$ac_try;;
22376 esac
22377 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22378 $as_echo "$ac_try_echo") >&5
22379   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
22380   ac_status=$?
22381   grep -v '^ *+' conftest.er1 >conftest.err
22382   rm -f conftest.er1
22383   cat conftest.err >&5
22384   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22385   (exit $ac_status); } >/dev/null && {
22386          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22387          test ! -s conftest.err
22388        }; then
22389   ac_header_preproc=yes
22390 else
22391   $as_echo "$as_me: failed program was:" >&5
22392 sed 's/^/| /' conftest.$ac_ext >&5
22393
22394   ac_header_preproc=no
22395 fi
22396
22397 rm -f conftest.err conftest.$ac_ext
22398 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22399 $as_echo "$ac_header_preproc" >&6; }
22400
22401 # So?  What about this header?
22402 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22403   yes:no: )
22404     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
22405 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22406     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
22407 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
22408     ac_header_preproc=yes
22409     ;;
22410   no:yes:* )
22411     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
22412 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
22413     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
22414 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
22415     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
22416 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
22417     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
22418 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22419     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
22420 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
22421     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
22422 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
22423     ( cat <<\_ASBOX
22424 ## ---------------------------------------- ##
22425 ## Report this to pgsql-bugs@postgresql.org ##
22426 ## ---------------------------------------- ##
22427 _ASBOX
22428      ) | sed "s/^/$as_me: WARNING:     /" >&2
22429     ;;
22430 esac
22431 { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
22432 $as_echo_n "checking for syslog.h... " >&6; }
22433 if test "${ac_cv_header_syslog_h+set}" = set; then
22434   $as_echo_n "(cached) " >&6
22435 else
22436   ac_cv_header_syslog_h=$ac_header_preproc
22437 fi
22438 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
22439 $as_echo "$ac_cv_header_syslog_h" >&6; }
22440
22441 fi
22442 if test "x$ac_cv_header_syslog_h" = x""yes; then
22443
22444 cat >>confdefs.h <<\_ACEOF
22445 #define HAVE_SYSLOG 1
22446 _ACEOF
22447
22448 fi
22449
22450
22451 fi
22452
22453
22454 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
22455 $as_echo_n "checking for opterr... " >&6; }
22456 if test "${pgac_cv_var_int_opterr+set}" = set; then
22457   $as_echo_n "(cached) " >&6
22458 else
22459   cat >conftest.$ac_ext <<_ACEOF
22460 /* confdefs.h.  */
22461 _ACEOF
22462 cat confdefs.h >>conftest.$ac_ext
22463 cat >>conftest.$ac_ext <<_ACEOF
22464 /* end confdefs.h.  */
22465 #include <unistd.h>
22466 int
22467 main ()
22468 {
22469 extern int opterr; opterr = 1;
22470   ;
22471   return 0;
22472 }
22473 _ACEOF
22474 rm -f conftest.$ac_objext conftest$ac_exeext
22475 if { (ac_try="$ac_link"
22476 case "(($ac_try" in
22477   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22478   *) ac_try_echo=$ac_try;;
22479 esac
22480 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22481 $as_echo "$ac_try_echo") >&5
22482   (eval "$ac_link") 2>conftest.er1
22483   ac_status=$?
22484   grep -v '^ *+' conftest.er1 >conftest.err
22485   rm -f conftest.er1
22486   cat conftest.err >&5
22487   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22488   (exit $ac_status); } && {
22489          test -z "$ac_c_werror_flag" ||
22490          test ! -s conftest.err
22491        } && test -s conftest$ac_exeext && {
22492          test "$cross_compiling" = yes ||
22493          $as_test_x conftest$ac_exeext
22494        }; then
22495   pgac_cv_var_int_opterr=yes
22496 else
22497   $as_echo "$as_me: failed program was:" >&5
22498 sed 's/^/| /' conftest.$ac_ext >&5
22499
22500         pgac_cv_var_int_opterr=no
22501 fi
22502
22503 rm -rf conftest.dSYM
22504 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22505       conftest$ac_exeext conftest.$ac_ext
22506 fi
22507 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
22508 $as_echo "$pgac_cv_var_int_opterr" >&6; }
22509 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
22510
22511 cat >>confdefs.h <<\_ACEOF
22512 #define HAVE_INT_OPTERR 1
22513 _ACEOF
22514
22515 fi
22516
22517 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
22518 $as_echo_n "checking for optreset... " >&6; }
22519 if test "${pgac_cv_var_int_optreset+set}" = set; then
22520   $as_echo_n "(cached) " >&6
22521 else
22522   cat >conftest.$ac_ext <<_ACEOF
22523 /* confdefs.h.  */
22524 _ACEOF
22525 cat confdefs.h >>conftest.$ac_ext
22526 cat >>conftest.$ac_ext <<_ACEOF
22527 /* end confdefs.h.  */
22528 #include <unistd.h>
22529 int
22530 main ()
22531 {
22532 extern int optreset; optreset = 1;
22533   ;
22534   return 0;
22535 }
22536 _ACEOF
22537 rm -f conftest.$ac_objext conftest$ac_exeext
22538 if { (ac_try="$ac_link"
22539 case "(($ac_try" in
22540   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22541   *) ac_try_echo=$ac_try;;
22542 esac
22543 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22544 $as_echo "$ac_try_echo") >&5
22545   (eval "$ac_link") 2>conftest.er1
22546   ac_status=$?
22547   grep -v '^ *+' conftest.er1 >conftest.err
22548   rm -f conftest.er1
22549   cat conftest.err >&5
22550   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22551   (exit $ac_status); } && {
22552          test -z "$ac_c_werror_flag" ||
22553          test ! -s conftest.err
22554        } && test -s conftest$ac_exeext && {
22555          test "$cross_compiling" = yes ||
22556          $as_test_x conftest$ac_exeext
22557        }; then
22558   pgac_cv_var_int_optreset=yes
22559 else
22560   $as_echo "$as_me: failed program was:" >&5
22561 sed 's/^/| /' conftest.$ac_ext >&5
22562
22563         pgac_cv_var_int_optreset=no
22564 fi
22565
22566 rm -rf conftest.dSYM
22567 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22568       conftest$ac_exeext conftest.$ac_ext
22569 fi
22570 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
22571 $as_echo "$pgac_cv_var_int_optreset" >&6; }
22572 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
22573
22574 cat >>confdefs.h <<\_ACEOF
22575 #define HAVE_INT_OPTRESET 1
22576 _ACEOF
22577
22578 fi
22579
22580
22581
22582 for ac_func in strtoll strtoq
22583 do
22584 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22585 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22586 $as_echo_n "checking for $ac_func... " >&6; }
22587 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22588   $as_echo_n "(cached) " >&6
22589 else
22590   cat >conftest.$ac_ext <<_ACEOF
22591 /* confdefs.h.  */
22592 _ACEOF
22593 cat confdefs.h >>conftest.$ac_ext
22594 cat >>conftest.$ac_ext <<_ACEOF
22595 /* end confdefs.h.  */
22596 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22597    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22598 #define $ac_func innocuous_$ac_func
22599
22600 /* System header to define __stub macros and hopefully few prototypes,
22601     which can conflict with char $ac_func (); below.
22602     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22603     <limits.h> exists even on freestanding compilers.  */
22604
22605 #ifdef __STDC__
22606 # include <limits.h>
22607 #else
22608 # include <assert.h>
22609 #endif
22610
22611 #undef $ac_func
22612
22613 /* Override any GCC internal prototype to avoid an error.
22614    Use char because int might match the return type of a GCC
22615    builtin and then its argument prototype would still apply.  */
22616 #ifdef __cplusplus
22617 extern "C"
22618 #endif
22619 char $ac_func ();
22620 /* The GNU C library defines this for functions which it implements
22621     to always fail with ENOSYS.  Some functions are actually named
22622     something starting with __ and the normal name is an alias.  */
22623 #if defined __stub_$ac_func || defined __stub___$ac_func
22624 choke me
22625 #endif
22626
22627 int
22628 main ()
22629 {
22630 return $ac_func ();
22631   ;
22632   return 0;
22633 }
22634 _ACEOF
22635 rm -f conftest.$ac_objext conftest$ac_exeext
22636 if { (ac_try="$ac_link"
22637 case "(($ac_try" in
22638   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22639   *) ac_try_echo=$ac_try;;
22640 esac
22641 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22642 $as_echo "$ac_try_echo") >&5
22643   (eval "$ac_link") 2>conftest.er1
22644   ac_status=$?
22645   grep -v '^ *+' conftest.er1 >conftest.err
22646   rm -f conftest.er1
22647   cat conftest.err >&5
22648   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22649   (exit $ac_status); } && {
22650          test -z "$ac_c_werror_flag" ||
22651          test ! -s conftest.err
22652        } && test -s conftest$ac_exeext && {
22653          test "$cross_compiling" = yes ||
22654          $as_test_x conftest$ac_exeext
22655        }; then
22656   eval "$as_ac_var=yes"
22657 else
22658   $as_echo "$as_me: failed program was:" >&5
22659 sed 's/^/| /' conftest.$ac_ext >&5
22660
22661         eval "$as_ac_var=no"
22662 fi
22663
22664 rm -rf conftest.dSYM
22665 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22666       conftest$ac_exeext conftest.$ac_ext
22667 fi
22668 ac_res=`eval 'as_val=${'$as_ac_var'}
22669                  $as_echo "$as_val"'`
22670                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22671 $as_echo "$ac_res" >&6; }
22672 as_val=`eval 'as_val=${'$as_ac_var'}
22673                  $as_echo "$as_val"'`
22674    if test "x$as_val" = x""yes; then
22675   cat >>confdefs.h <<_ACEOF
22676 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22677 _ACEOF
22678  break
22679 fi
22680 done
22681
22682
22683
22684 for ac_func in strtoull strtouq
22685 do
22686 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22687 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22688 $as_echo_n "checking for $ac_func... " >&6; }
22689 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22690   $as_echo_n "(cached) " >&6
22691 else
22692   cat >conftest.$ac_ext <<_ACEOF
22693 /* confdefs.h.  */
22694 _ACEOF
22695 cat confdefs.h >>conftest.$ac_ext
22696 cat >>conftest.$ac_ext <<_ACEOF
22697 /* end confdefs.h.  */
22698 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22699    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22700 #define $ac_func innocuous_$ac_func
22701
22702 /* System header to define __stub macros and hopefully few prototypes,
22703     which can conflict with char $ac_func (); below.
22704     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22705     <limits.h> exists even on freestanding compilers.  */
22706
22707 #ifdef __STDC__
22708 # include <limits.h>
22709 #else
22710 # include <assert.h>
22711 #endif
22712
22713 #undef $ac_func
22714
22715 /* Override any GCC internal prototype to avoid an error.
22716    Use char because int might match the return type of a GCC
22717    builtin and then its argument prototype would still apply.  */
22718 #ifdef __cplusplus
22719 extern "C"
22720 #endif
22721 char $ac_func ();
22722 /* The GNU C library defines this for functions which it implements
22723     to always fail with ENOSYS.  Some functions are actually named
22724     something starting with __ and the normal name is an alias.  */
22725 #if defined __stub_$ac_func || defined __stub___$ac_func
22726 choke me
22727 #endif
22728
22729 int
22730 main ()
22731 {
22732 return $ac_func ();
22733   ;
22734   return 0;
22735 }
22736 _ACEOF
22737 rm -f conftest.$ac_objext conftest$ac_exeext
22738 if { (ac_try="$ac_link"
22739 case "(($ac_try" in
22740   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22741   *) ac_try_echo=$ac_try;;
22742 esac
22743 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22744 $as_echo "$ac_try_echo") >&5
22745   (eval "$ac_link") 2>conftest.er1
22746   ac_status=$?
22747   grep -v '^ *+' conftest.er1 >conftest.err
22748   rm -f conftest.er1
22749   cat conftest.err >&5
22750   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22751   (exit $ac_status); } && {
22752          test -z "$ac_c_werror_flag" ||
22753          test ! -s conftest.err
22754        } && test -s conftest$ac_exeext && {
22755          test "$cross_compiling" = yes ||
22756          $as_test_x conftest$ac_exeext
22757        }; then
22758   eval "$as_ac_var=yes"
22759 else
22760   $as_echo "$as_me: failed program was:" >&5
22761 sed 's/^/| /' conftest.$ac_ext >&5
22762
22763         eval "$as_ac_var=no"
22764 fi
22765
22766 rm -rf conftest.dSYM
22767 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22768       conftest$ac_exeext conftest.$ac_ext
22769 fi
22770 ac_res=`eval 'as_val=${'$as_ac_var'}
22771                  $as_echo "$as_val"'`
22772                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22773 $as_echo "$ac_res" >&6; }
22774 as_val=`eval 'as_val=${'$as_ac_var'}
22775                  $as_echo "$as_val"'`
22776    if test "x$as_val" = x""yes; then
22777   cat >>confdefs.h <<_ACEOF
22778 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22779 _ACEOF
22780  break
22781 fi
22782 done
22783
22784
22785 { $as_echo "$as_me:$LINENO: checking for builtin locking functions" >&5
22786 $as_echo_n "checking for builtin locking functions... " >&6; }
22787 if test "${pgac_cv_gcc_int_atomics+set}" = set; then
22788   $as_echo_n "(cached) " >&6
22789 else
22790   cat >conftest.$ac_ext <<_ACEOF
22791 /* confdefs.h.  */
22792 _ACEOF
22793 cat confdefs.h >>conftest.$ac_ext
22794 cat >>conftest.$ac_ext <<_ACEOF
22795 /* end confdefs.h.  */
22796
22797 int
22798 main ()
22799 {
22800 int lock = 0;
22801    __sync_lock_test_and_set(&lock, 1);
22802    __sync_lock_release(&lock);
22803   ;
22804   return 0;
22805 }
22806 _ACEOF
22807 rm -f conftest.$ac_objext conftest$ac_exeext
22808 if { (ac_try="$ac_link"
22809 case "(($ac_try" in
22810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22811   *) ac_try_echo=$ac_try;;
22812 esac
22813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22814 $as_echo "$ac_try_echo") >&5
22815   (eval "$ac_link") 2>conftest.er1
22816   ac_status=$?
22817   grep -v '^ *+' conftest.er1 >conftest.err
22818   rm -f conftest.er1
22819   cat conftest.err >&5
22820   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22821   (exit $ac_status); } && {
22822          test -z "$ac_c_werror_flag" ||
22823          test ! -s conftest.err
22824        } && test -s conftest$ac_exeext && {
22825          test "$cross_compiling" = yes ||
22826          $as_test_x conftest$ac_exeext
22827        }; then
22828   pgac_cv_gcc_int_atomics="yes"
22829 else
22830   $as_echo "$as_me: failed program was:" >&5
22831 sed 's/^/| /' conftest.$ac_ext >&5
22832
22833         pgac_cv_gcc_int_atomics="no"
22834 fi
22835
22836 rm -rf conftest.dSYM
22837 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22838       conftest$ac_exeext conftest.$ac_ext
22839 fi
22840 { $as_echo "$as_me:$LINENO: result: $pgac_cv_gcc_int_atomics" >&5
22841 $as_echo "$pgac_cv_gcc_int_atomics" >&6; }
22842 if test x"$pgac_cv_gcc_int_atomics" = x"yes"; then
22843
22844 cat >>confdefs.h <<\_ACEOF
22845 #define HAVE_GCC_INT_ATOMICS 1
22846 _ACEOF
22847
22848 fi
22849
22850 # Lastly, restore full LIBS list and check for readline/libedit symbols
22851 LIBS="$LIBS_including_readline"
22852
22853 if test "$with_readline" = yes; then
22854   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
22855 $as_echo_n "checking for rl_completion_append_character... " >&6; }
22856 if test "${pgac_cv_var_rl_completion_append_character+set}" = set; then
22857   $as_echo_n "(cached) " >&6
22858 else
22859   cat >conftest.$ac_ext <<_ACEOF
22860 /* confdefs.h.  */
22861 _ACEOF
22862 cat confdefs.h >>conftest.$ac_ext
22863 cat >>conftest.$ac_ext <<_ACEOF
22864 /* end confdefs.h.  */
22865 #include <stdio.h>
22866 #ifdef HAVE_READLINE_READLINE_H
22867 # include <readline/readline.h>
22868 #elif defined(HAVE_READLINE_H)
22869 # include <readline.h>
22870 #endif
22871
22872 int
22873 main ()
22874 {
22875 rl_completion_append_character = 'x';
22876   ;
22877   return 0;
22878 }
22879 _ACEOF
22880 rm -f conftest.$ac_objext conftest$ac_exeext
22881 if { (ac_try="$ac_link"
22882 case "(($ac_try" in
22883   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22884   *) ac_try_echo=$ac_try;;
22885 esac
22886 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22887 $as_echo "$ac_try_echo") >&5
22888   (eval "$ac_link") 2>conftest.er1
22889   ac_status=$?
22890   grep -v '^ *+' conftest.er1 >conftest.err
22891   rm -f conftest.er1
22892   cat conftest.err >&5
22893   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22894   (exit $ac_status); } && {
22895          test -z "$ac_c_werror_flag" ||
22896          test ! -s conftest.err
22897        } && test -s conftest$ac_exeext && {
22898          test "$cross_compiling" = yes ||
22899          $as_test_x conftest$ac_exeext
22900        }; then
22901   pgac_cv_var_rl_completion_append_character=yes
22902 else
22903   $as_echo "$as_me: failed program was:" >&5
22904 sed 's/^/| /' conftest.$ac_ext >&5
22905
22906         pgac_cv_var_rl_completion_append_character=no
22907 fi
22908
22909 rm -rf conftest.dSYM
22910 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22911       conftest$ac_exeext conftest.$ac_ext
22912 fi
22913 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_rl_completion_append_character" >&5
22914 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
22915 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
22916
22917 cat >>confdefs.h <<\_ACEOF
22918 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
22919 _ACEOF
22920
22921 fi
22922
22923
22924 for ac_func in rl_completion_matches rl_filename_completion_function
22925 do
22926 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22927 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22928 $as_echo_n "checking for $ac_func... " >&6; }
22929 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22930   $as_echo_n "(cached) " >&6
22931 else
22932   cat >conftest.$ac_ext <<_ACEOF
22933 /* confdefs.h.  */
22934 _ACEOF
22935 cat confdefs.h >>conftest.$ac_ext
22936 cat >>conftest.$ac_ext <<_ACEOF
22937 /* end confdefs.h.  */
22938 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22939    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22940 #define $ac_func innocuous_$ac_func
22941
22942 /* System header to define __stub macros and hopefully few prototypes,
22943     which can conflict with char $ac_func (); below.
22944     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22945     <limits.h> exists even on freestanding compilers.  */
22946
22947 #ifdef __STDC__
22948 # include <limits.h>
22949 #else
22950 # include <assert.h>
22951 #endif
22952
22953 #undef $ac_func
22954
22955 /* Override any GCC internal prototype to avoid an error.
22956    Use char because int might match the return type of a GCC
22957    builtin and then its argument prototype would still apply.  */
22958 #ifdef __cplusplus
22959 extern "C"
22960 #endif
22961 char $ac_func ();
22962 /* The GNU C library defines this for functions which it implements
22963     to always fail with ENOSYS.  Some functions are actually named
22964     something starting with __ and the normal name is an alias.  */
22965 #if defined __stub_$ac_func || defined __stub___$ac_func
22966 choke me
22967 #endif
22968
22969 int
22970 main ()
22971 {
22972 return $ac_func ();
22973   ;
22974   return 0;
22975 }
22976 _ACEOF
22977 rm -f conftest.$ac_objext conftest$ac_exeext
22978 if { (ac_try="$ac_link"
22979 case "(($ac_try" in
22980   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22981   *) ac_try_echo=$ac_try;;
22982 esac
22983 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22984 $as_echo "$ac_try_echo") >&5
22985   (eval "$ac_link") 2>conftest.er1
22986   ac_status=$?
22987   grep -v '^ *+' conftest.er1 >conftest.err
22988   rm -f conftest.er1
22989   cat conftest.err >&5
22990   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22991   (exit $ac_status); } && {
22992          test -z "$ac_c_werror_flag" ||
22993          test ! -s conftest.err
22994        } && test -s conftest$ac_exeext && {
22995          test "$cross_compiling" = yes ||
22996          $as_test_x conftest$ac_exeext
22997        }; then
22998   eval "$as_ac_var=yes"
22999 else
23000   $as_echo "$as_me: failed program was:" >&5
23001 sed 's/^/| /' conftest.$ac_ext >&5
23002
23003         eval "$as_ac_var=no"
23004 fi
23005
23006 rm -rf conftest.dSYM
23007 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23008       conftest$ac_exeext conftest.$ac_ext
23009 fi
23010 ac_res=`eval 'as_val=${'$as_ac_var'}
23011                  $as_echo "$as_val"'`
23012                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23013 $as_echo "$ac_res" >&6; }
23014 as_val=`eval 'as_val=${'$as_ac_var'}
23015                  $as_echo "$as_val"'`
23016    if test "x$as_val" = x""yes; then
23017   cat >>confdefs.h <<_ACEOF
23018 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23019 _ACEOF
23020
23021 fi
23022 done
23023
23024
23025
23026 for ac_func in append_history history_truncate_file
23027 do
23028 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23029 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
23030 $as_echo_n "checking for $ac_func... " >&6; }
23031 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23032   $as_echo_n "(cached) " >&6
23033 else
23034   cat >conftest.$ac_ext <<_ACEOF
23035 /* confdefs.h.  */
23036 _ACEOF
23037 cat confdefs.h >>conftest.$ac_ext
23038 cat >>conftest.$ac_ext <<_ACEOF
23039 /* end confdefs.h.  */
23040 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23041    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23042 #define $ac_func innocuous_$ac_func
23043
23044 /* System header to define __stub macros and hopefully few prototypes,
23045     which can conflict with char $ac_func (); below.
23046     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23047     <limits.h> exists even on freestanding compilers.  */
23048
23049 #ifdef __STDC__
23050 # include <limits.h>
23051 #else
23052 # include <assert.h>
23053 #endif
23054
23055 #undef $ac_func
23056
23057 /* Override any GCC internal prototype to avoid an error.
23058    Use char because int might match the return type of a GCC
23059    builtin and then its argument prototype would still apply.  */
23060 #ifdef __cplusplus
23061 extern "C"
23062 #endif
23063 char $ac_func ();
23064 /* The GNU C library defines this for functions which it implements
23065     to always fail with ENOSYS.  Some functions are actually named
23066     something starting with __ and the normal name is an alias.  */
23067 #if defined __stub_$ac_func || defined __stub___$ac_func
23068 choke me
23069 #endif
23070
23071 int
23072 main ()
23073 {
23074 return $ac_func ();
23075   ;
23076   return 0;
23077 }
23078 _ACEOF
23079 rm -f conftest.$ac_objext conftest$ac_exeext
23080 if { (ac_try="$ac_link"
23081 case "(($ac_try" in
23082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23083   *) ac_try_echo=$ac_try;;
23084 esac
23085 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23086 $as_echo "$ac_try_echo") >&5
23087   (eval "$ac_link") 2>conftest.er1
23088   ac_status=$?
23089   grep -v '^ *+' conftest.er1 >conftest.err
23090   rm -f conftest.er1
23091   cat conftest.err >&5
23092   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23093   (exit $ac_status); } && {
23094          test -z "$ac_c_werror_flag" ||
23095          test ! -s conftest.err
23096        } && test -s conftest$ac_exeext && {
23097          test "$cross_compiling" = yes ||
23098          $as_test_x conftest$ac_exeext
23099        }; then
23100   eval "$as_ac_var=yes"
23101 else
23102   $as_echo "$as_me: failed program was:" >&5
23103 sed 's/^/| /' conftest.$ac_ext >&5
23104
23105         eval "$as_ac_var=no"
23106 fi
23107
23108 rm -rf conftest.dSYM
23109 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23110       conftest$ac_exeext conftest.$ac_ext
23111 fi
23112 ac_res=`eval 'as_val=${'$as_ac_var'}
23113                  $as_echo "$as_val"'`
23114                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23115 $as_echo "$ac_res" >&6; }
23116 as_val=`eval 'as_val=${'$as_ac_var'}
23117                  $as_echo "$as_val"'`
23118    if test "x$as_val" = x""yes; then
23119   cat >>confdefs.h <<_ACEOF
23120 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23121 _ACEOF
23122
23123 fi
23124 done
23125
23126 fi
23127
23128
23129 #
23130 # Pthreads
23131 #
23132 # For each platform, we need to know about any special compile and link
23133 # libraries, and whether the normal C function names are thread-safe.
23134 # See the comment at the top of src/port/thread.c for more information.
23135 # WIN32 doesn't need the pthread tests;  it always uses threads
23136 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
23137
23138
23139
23140 ac_ext=c
23141 ac_cpp='$CPP $CPPFLAGS'
23142 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23143 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23144 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23145
23146 acx_pthread_ok=no
23147
23148 # We used to check for pthread.h first, but this fails if pthread.h
23149 # requires special compiler flags (e.g. on True64 or Sequent).
23150 # It gets checked for in the link test anyway.
23151
23152 # First of all, check if the user has set any of the PTHREAD_LIBS,
23153 # etcetera environment variables, and if threads linking works using
23154 # them:
23155 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
23156         save_CFLAGS="$CFLAGS"
23157         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
23158         save_LIBS="$LIBS"
23159         LIBS="$PTHREAD_LIBS $LIBS"
23160         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
23161 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
23162         cat >conftest.$ac_ext <<_ACEOF
23163 /* confdefs.h.  */
23164 _ACEOF
23165 cat confdefs.h >>conftest.$ac_ext
23166 cat >>conftest.$ac_ext <<_ACEOF
23167 /* end confdefs.h.  */
23168
23169 /* Override any GCC internal prototype to avoid an error.
23170    Use char because int might match the return type of a GCC
23171    builtin and then its argument prototype would still apply.  */
23172 #ifdef __cplusplus
23173 extern "C"
23174 #endif
23175 char pthread_join ();
23176 int
23177 main ()
23178 {
23179 return pthread_join ();
23180   ;
23181   return 0;
23182 }
23183 _ACEOF
23184 rm -f conftest.$ac_objext conftest$ac_exeext
23185 if { (ac_try="$ac_link"
23186 case "(($ac_try" in
23187   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23188   *) ac_try_echo=$ac_try;;
23189 esac
23190 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23191 $as_echo "$ac_try_echo") >&5
23192   (eval "$ac_link") 2>conftest.er1
23193   ac_status=$?
23194   grep -v '^ *+' conftest.er1 >conftest.err
23195   rm -f conftest.er1
23196   cat conftest.err >&5
23197   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23198   (exit $ac_status); } && {
23199          test -z "$ac_c_werror_flag" ||
23200          test ! -s conftest.err
23201        } && test -s conftest$ac_exeext && {
23202          test "$cross_compiling" = yes ||
23203          $as_test_x conftest$ac_exeext
23204        }; then
23205   acx_pthread_ok=yes
23206 else
23207   $as_echo "$as_me: failed program was:" >&5
23208 sed 's/^/| /' conftest.$ac_ext >&5
23209
23210
23211 fi
23212
23213 rm -rf conftest.dSYM
23214 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23215       conftest$ac_exeext conftest.$ac_ext
23216         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
23217 $as_echo "$acx_pthread_ok" >&6; }
23218         if test x"$acx_pthread_ok" = xno; then
23219                 PTHREAD_LIBS=""
23220                 PTHREAD_CFLAGS=""
23221         fi
23222         LIBS="$save_LIBS"
23223         CFLAGS="$save_CFLAGS"
23224 fi
23225
23226 # We must check for the threads library under a number of different
23227 # names; the ordering is very important because some systems
23228 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
23229 # libraries is broken (non-POSIX).
23230
23231 # Create a list of thread flags to try.  Items starting with a "-" are
23232 # C compiler flags, and other items are library names, except for "none"
23233 # which indicates that we try without any flags at all, and "pthread-config"
23234 # which is a program returning the flags for the Pth emulation library.
23235
23236 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
23237
23238 # The ordering *is* (sometimes) important.  Some notes on the
23239 # individual items follow:
23240
23241 # pthreads: AIX (must check this before -lpthread)
23242 # none: in case threads are in libc; should be tried before -Kthread and
23243 #       other compiler flags to prevent continual compiler warnings
23244 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
23245 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
23246 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
23247 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
23248 # -pthreads: Solaris/gcc
23249 # -mthreads: Mingw32/gcc, Lynx/gcc
23250 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
23251 #      doesn't hurt to check since this sometimes defines pthreads too;
23252 #      also defines -D_REENTRANT)
23253 # pthread: Linux, etcetera
23254 # --thread-safe: KAI C++
23255 # pthread-config: use pthread-config program (for GNU Pth library)
23256
23257 case "${host_cpu}-${host_os}" in
23258         *solaris*)
23259
23260         # On Solaris (at least, for some versions), libc contains stubbed
23261         # (non-functional) versions of the pthreads routines, so link-based
23262         # tests will erroneously succeed.  (We need to link with -pthread or
23263         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
23264         # a function called by this macro, so we could check for that, but
23265         # who knows whether they'll stub that too in a future libc.)  So,
23266         # we'll just look for -pthreads and -lpthread first:
23267
23268         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
23269         ;;
23270 esac
23271
23272 if test x"$acx_pthread_ok" = xno; then
23273 for flag in $acx_pthread_flags; do
23274
23275         tryPTHREAD_CFLAGS=""
23276         tryPTHREAD_LIBS=""
23277         case $flag in
23278                 none)
23279                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
23280 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
23281                 ;;
23282
23283                 -*)
23284                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
23285 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
23286                 tryPTHREAD_CFLAGS="$flag"
23287                 ;;
23288
23289                 pthread-config)
23290                 # skip this if we already have flags defined, for PostgreSQL
23291                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
23292                 # Extract the first word of "pthread-config", so it can be a program name with args.
23293 set dummy pthread-config; ac_word=$2
23294 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
23295 $as_echo_n "checking for $ac_word... " >&6; }
23296 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
23297   $as_echo_n "(cached) " >&6
23298 else
23299   if test -n "$acx_pthread_config"; then
23300   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
23301 else
23302 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23303 for as_dir in $PATH
23304 do
23305   IFS=$as_save_IFS
23306   test -z "$as_dir" && as_dir=.
23307   for ac_exec_ext in '' $ac_executable_extensions; do
23308   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
23309     ac_cv_prog_acx_pthread_config="yes"
23310     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
23311     break 2
23312   fi
23313 done
23314 done
23315 IFS=$as_save_IFS
23316
23317   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
23318 fi
23319 fi
23320 acx_pthread_config=$ac_cv_prog_acx_pthread_config
23321 if test -n "$acx_pthread_config"; then
23322   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
23323 $as_echo "$acx_pthread_config" >&6; }
23324 else
23325   { $as_echo "$as_me:$LINENO: result: no" >&5
23326 $as_echo "no" >&6; }
23327 fi
23328
23329
23330                 if test x"$acx_pthread_config" = xno; then continue; fi
23331                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
23332                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
23333                 ;;
23334
23335                 *)
23336                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
23337 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
23338                 tryPTHREAD_LIBS="-l$flag"
23339                 ;;
23340         esac
23341
23342         save_LIBS="$LIBS"
23343         save_CFLAGS="$CFLAGS"
23344         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
23345         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
23346
23347         # Check for various functions.  We must include pthread.h,
23348         # since some functions may be macros.  (On the Sequent, we
23349         # need a special flag -Kthread to make this header compile.)
23350         # We check for pthread_join because it is in -lpthread on IRIX
23351         # while pthread_create is in libc.  We check for pthread_attr_init
23352         # due to DEC craziness with -lpthreads.  We check for
23353         # pthread_cleanup_push because it is one of the few pthread
23354         # functions on Solaris that doesn't have a non-functional libc stub.
23355         # We try pthread_create on general principles.
23356         cat >conftest.$ac_ext <<_ACEOF
23357 /* confdefs.h.  */
23358 _ACEOF
23359 cat confdefs.h >>conftest.$ac_ext
23360 cat >>conftest.$ac_ext <<_ACEOF
23361 /* end confdefs.h.  */
23362 #include <pthread.h>
23363 int
23364 main ()
23365 {
23366 pthread_t th; pthread_join(th, 0);
23367                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
23368                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
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   acx_pthread_ok=yes
23395 else
23396   $as_echo "$as_me: failed program was:" >&5
23397 sed 's/^/| /' conftest.$ac_ext >&5
23398
23399         acx_pthread_ok=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
23406         if test "x$acx_pthread_ok" = xyes; then
23407             # Don't use options that are ignored by the compiler.
23408             # We find them by checking stderror.
23409             cat >conftest.$ac_ext <<_ACEOF
23410 int
23411 main (int argc, char **argv)
23412 {
23413   (void) argc;
23414   (void) argv;
23415   return 0;
23416 }
23417 _ACEOF
23418             rm -f conftest.$ac_objext conftest$ac_exeext
23419             # Check both linking and compiling, because they might tolerate different options.
23420             if test "`(eval $ac_link 2>&1 1>&5)`" = "" && test "`(eval $ac_compile 2>&1 1>&5)`" = ""; then
23421                 # we continue with more flags because Linux needs -lpthread
23422                 # for libpq builds on PostgreSQL.  The test above only
23423                 # tests for building binaries, not shared libraries.
23424                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
23425                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
23426             else   acx_pthread_ok=no
23427             fi
23428         fi
23429
23430         LIBS="$save_LIBS"
23431         CFLAGS="$save_CFLAGS"
23432
23433         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
23434 $as_echo "$acx_pthread_ok" >&6; }
23435 done
23436 fi
23437
23438 # Various other checks:
23439 if test "x$acx_pthread_ok" = xyes; then
23440         save_LIBS="$LIBS"
23441         LIBS="$PTHREAD_LIBS $LIBS"
23442         save_CFLAGS="$CFLAGS"
23443         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
23444
23445         # Detect AIX lossage: threads are created detached by default
23446         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
23447         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
23448 $as_echo_n "checking for joinable pthread attribute... " >&6; }
23449         cat >conftest.$ac_ext <<_ACEOF
23450 /* confdefs.h.  */
23451 _ACEOF
23452 cat confdefs.h >>conftest.$ac_ext
23453 cat >>conftest.$ac_ext <<_ACEOF
23454 /* end confdefs.h.  */
23455 #include <pthread.h>
23456 int
23457 main ()
23458 {
23459 int attr=PTHREAD_CREATE_JOINABLE;
23460   ;
23461   return 0;
23462 }
23463 _ACEOF
23464 rm -f conftest.$ac_objext conftest$ac_exeext
23465 if { (ac_try="$ac_link"
23466 case "(($ac_try" in
23467   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23468   *) ac_try_echo=$ac_try;;
23469 esac
23470 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23471 $as_echo "$ac_try_echo") >&5
23472   (eval "$ac_link") 2>conftest.er1
23473   ac_status=$?
23474   grep -v '^ *+' conftest.er1 >conftest.err
23475   rm -f conftest.er1
23476   cat conftest.err >&5
23477   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23478   (exit $ac_status); } && {
23479          test -z "$ac_c_werror_flag" ||
23480          test ! -s conftest.err
23481        } && test -s conftest$ac_exeext && {
23482          test "$cross_compiling" = yes ||
23483          $as_test_x conftest$ac_exeext
23484        }; then
23485   ok=PTHREAD_CREATE_JOINABLE
23486 else
23487   $as_echo "$as_me: failed program was:" >&5
23488 sed 's/^/| /' conftest.$ac_ext >&5
23489
23490         ok=unknown
23491 fi
23492
23493 rm -rf conftest.dSYM
23494 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23495       conftest$ac_exeext conftest.$ac_ext
23496         if test x"$ok" = xunknown; then
23497                 cat >conftest.$ac_ext <<_ACEOF
23498 /* confdefs.h.  */
23499 _ACEOF
23500 cat confdefs.h >>conftest.$ac_ext
23501 cat >>conftest.$ac_ext <<_ACEOF
23502 /* end confdefs.h.  */
23503 #include <pthread.h>
23504 int
23505 main ()
23506 {
23507 int attr=PTHREAD_CREATE_UNDETACHED;
23508   ;
23509   return 0;
23510 }
23511 _ACEOF
23512 rm -f conftest.$ac_objext conftest$ac_exeext
23513 if { (ac_try="$ac_link"
23514 case "(($ac_try" in
23515   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23516   *) ac_try_echo=$ac_try;;
23517 esac
23518 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23519 $as_echo "$ac_try_echo") >&5
23520   (eval "$ac_link") 2>conftest.er1
23521   ac_status=$?
23522   grep -v '^ *+' conftest.er1 >conftest.err
23523   rm -f conftest.er1
23524   cat conftest.err >&5
23525   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23526   (exit $ac_status); } && {
23527          test -z "$ac_c_werror_flag" ||
23528          test ! -s conftest.err
23529        } && test -s conftest$ac_exeext && {
23530          test "$cross_compiling" = yes ||
23531          $as_test_x conftest$ac_exeext
23532        }; then
23533   ok=PTHREAD_CREATE_UNDETACHED
23534 else
23535   $as_echo "$as_me: failed program was:" >&5
23536 sed 's/^/| /' conftest.$ac_ext >&5
23537
23538         ok=unknown
23539 fi
23540
23541 rm -rf conftest.dSYM
23542 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23543       conftest$ac_exeext conftest.$ac_ext
23544         fi
23545         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
23546
23547 cat >>confdefs.h <<\_ACEOF
23548 #define PTHREAD_CREATE_JOINABLE $ok
23549 _ACEOF
23550
23551         fi
23552         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
23553 $as_echo "${ok}" >&6; }
23554         if test x"$ok" = xunknown; then
23555                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
23556 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
23557         fi
23558
23559         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
23560 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
23561         flag=no
23562 # We always add these in PostgreSQL
23563 #       case "${host_cpu}-${host_os}" in
23564 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
23565 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
23566 #       esac
23567         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
23568 $as_echo "${flag}" >&6; }
23569         if test "x$flag" != xno; then
23570                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
23571         fi
23572
23573         LIBS="$save_LIBS"
23574         CFLAGS="$save_CFLAGS"
23575
23576 # Supporting cc_r would require a special CC in all places that
23577 # use libpq, and that is ugly, so we don't do it.  Users can still
23578 # define their compiler as cc_r to do thread builds of everything.
23579         # More AIX lossage: must compile with cc_r
23580         # Extract the first word of "cc_r", so it can be a program name with args.
23581 set dummy cc_r; ac_word=$2
23582 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
23583 $as_echo_n "checking for $ac_word... " >&6; }
23584 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
23585   $as_echo_n "(cached) " >&6
23586 else
23587   if test -n "$PTHREAD_CC"; then
23588   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
23589 else
23590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23591 for as_dir in $PATH
23592 do
23593   IFS=$as_save_IFS
23594   test -z "$as_dir" && as_dir=.
23595   for ac_exec_ext in '' $ac_executable_extensions; do
23596   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
23597     ac_cv_prog_PTHREAD_CC="cc_r"
23598     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
23599     break 2
23600   fi
23601 done
23602 done
23603 IFS=$as_save_IFS
23604
23605   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
23606 fi
23607 fi
23608 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
23609 if test -n "$PTHREAD_CC"; then
23610   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
23611 $as_echo "$PTHREAD_CC" >&6; }
23612 else
23613   { $as_echo "$as_me:$LINENO: result: no" >&5
23614 $as_echo "no" >&6; }
23615 fi
23616
23617
23618 else
23619         PTHREAD_CC="$CC"
23620 fi
23621
23622
23623
23624
23625
23626 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
23627 if test x"$acx_pthread_ok" = xyes; then
23628
23629 cat >>confdefs.h <<\_ACEOF
23630 #define HAVE_PTHREAD 1
23631 _ACEOF
23632
23633         :
23634 else
23635         acx_pthread_ok=no
23636
23637 fi
23638 ac_ext=c
23639 ac_cpp='$CPP $CPPFLAGS'
23640 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23641 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23642 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23643
23644         # set thread flags
23645
23646 # Some platforms use these, so just define them.  They can't hurt if they
23647 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
23648 # enables 5-arg getpwuid_r, among other things.
23649 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
23650
23651
23652 # At this point, we don't want to muck with the compiler name for threading.
23653 # Let's see who fails, perhaps AIX.  2004-04-23
23654 if test "$PTHREAD_CC" != "$CC"; then
23655 { { $as_echo "$as_me:$LINENO: error:
23656 PostgreSQL does not support platforms that require a special compiler
23657 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
23658 $as_echo "$as_me: error:
23659 PostgreSQL does not support platforms that require a special compiler
23660 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
23661    { (exit 1); exit 1; }; }
23662 fi
23663
23664 # Check for *_r functions
23665 _CFLAGS="$CFLAGS"
23666 _LIBS="$LIBS"
23667 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
23668 LIBS="$LIBS $PTHREAD_LIBS"
23669
23670 if test "$PORTNAME" != "win32"; then
23671 if test "${ac_cv_header_pthread_h+set}" = set; then
23672   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23673 $as_echo_n "checking for pthread.h... " >&6; }
23674 if test "${ac_cv_header_pthread_h+set}" = set; then
23675   $as_echo_n "(cached) " >&6
23676 fi
23677 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23678 $as_echo "$ac_cv_header_pthread_h" >&6; }
23679 else
23680   # Is the header compilable?
23681 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
23682 $as_echo_n "checking pthread.h usability... " >&6; }
23683 cat >conftest.$ac_ext <<_ACEOF
23684 /* confdefs.h.  */
23685 _ACEOF
23686 cat confdefs.h >>conftest.$ac_ext
23687 cat >>conftest.$ac_ext <<_ACEOF
23688 /* end confdefs.h.  */
23689 $ac_includes_default
23690 #include <pthread.h>
23691 _ACEOF
23692 rm -f conftest.$ac_objext
23693 if { (ac_try="$ac_compile"
23694 case "(($ac_try" in
23695   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23696   *) ac_try_echo=$ac_try;;
23697 esac
23698 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23699 $as_echo "$ac_try_echo") >&5
23700   (eval "$ac_compile") 2>conftest.er1
23701   ac_status=$?
23702   grep -v '^ *+' conftest.er1 >conftest.err
23703   rm -f conftest.er1
23704   cat conftest.err >&5
23705   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23706   (exit $ac_status); } && {
23707          test -z "$ac_c_werror_flag" ||
23708          test ! -s conftest.err
23709        } && test -s conftest.$ac_objext; then
23710   ac_header_compiler=yes
23711 else
23712   $as_echo "$as_me: failed program was:" >&5
23713 sed 's/^/| /' conftest.$ac_ext >&5
23714
23715         ac_header_compiler=no
23716 fi
23717
23718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23719 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23720 $as_echo "$ac_header_compiler" >&6; }
23721
23722 # Is the header present?
23723 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
23724 $as_echo_n "checking pthread.h presence... " >&6; }
23725 cat >conftest.$ac_ext <<_ACEOF
23726 /* confdefs.h.  */
23727 _ACEOF
23728 cat confdefs.h >>conftest.$ac_ext
23729 cat >>conftest.$ac_ext <<_ACEOF
23730 /* end confdefs.h.  */
23731 #include <pthread.h>
23732 _ACEOF
23733 if { (ac_try="$ac_cpp conftest.$ac_ext"
23734 case "(($ac_try" in
23735   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23736   *) ac_try_echo=$ac_try;;
23737 esac
23738 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23739 $as_echo "$ac_try_echo") >&5
23740   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
23741   ac_status=$?
23742   grep -v '^ *+' conftest.er1 >conftest.err
23743   rm -f conftest.er1
23744   cat conftest.err >&5
23745   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23746   (exit $ac_status); } >/dev/null && {
23747          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
23748          test ! -s conftest.err
23749        }; then
23750   ac_header_preproc=yes
23751 else
23752   $as_echo "$as_me: failed program was:" >&5
23753 sed 's/^/| /' conftest.$ac_ext >&5
23754
23755   ac_header_preproc=no
23756 fi
23757
23758 rm -f conftest.err conftest.$ac_ext
23759 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23760 $as_echo "$ac_header_preproc" >&6; }
23761
23762 # So?  What about this header?
23763 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
23764   yes:no: )
23765     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
23766 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
23767     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
23768 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
23769     ac_header_preproc=yes
23770     ;;
23771   no:yes:* )
23772     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
23773 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
23774     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
23775 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
23776     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
23777 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
23778     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
23779 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
23780     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
23781 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
23782     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
23783 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
23784     ( cat <<\_ASBOX
23785 ## ---------------------------------------- ##
23786 ## Report this to pgsql-bugs@postgresql.org ##
23787 ## ---------------------------------------- ##
23788 _ASBOX
23789      ) | sed "s/^/$as_me: WARNING:     /" >&2
23790     ;;
23791 esac
23792 { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23793 $as_echo_n "checking for pthread.h... " >&6; }
23794 if test "${ac_cv_header_pthread_h+set}" = set; then
23795   $as_echo_n "(cached) " >&6
23796 else
23797   ac_cv_header_pthread_h=$ac_header_preproc
23798 fi
23799 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23800 $as_echo "$ac_cv_header_pthread_h" >&6; }
23801
23802 fi
23803 if test "x$ac_cv_header_pthread_h" = x""yes; then
23804   :
23805 else
23806   { { $as_echo "$as_me:$LINENO: error:
23807 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
23808 $as_echo "$as_me: error:
23809 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
23810    { (exit 1); exit 1; }; }
23811 fi
23812
23813
23814 fi
23815
23816
23817
23818
23819 for ac_func in strerror_r getpwuid_r gethostbyname_r
23820 do
23821 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23822 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
23823 $as_echo_n "checking for $ac_func... " >&6; }
23824 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23825   $as_echo_n "(cached) " >&6
23826 else
23827   cat >conftest.$ac_ext <<_ACEOF
23828 /* confdefs.h.  */
23829 _ACEOF
23830 cat confdefs.h >>conftest.$ac_ext
23831 cat >>conftest.$ac_ext <<_ACEOF
23832 /* end confdefs.h.  */
23833 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23834    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23835 #define $ac_func innocuous_$ac_func
23836
23837 /* System header to define __stub macros and hopefully few prototypes,
23838     which can conflict with char $ac_func (); below.
23839     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23840     <limits.h> exists even on freestanding compilers.  */
23841
23842 #ifdef __STDC__
23843 # include <limits.h>
23844 #else
23845 # include <assert.h>
23846 #endif
23847
23848 #undef $ac_func
23849
23850 /* Override any GCC internal prototype to avoid an error.
23851    Use char because int might match the return type of a GCC
23852    builtin and then its argument prototype would still apply.  */
23853 #ifdef __cplusplus
23854 extern "C"
23855 #endif
23856 char $ac_func ();
23857 /* The GNU C library defines this for functions which it implements
23858     to always fail with ENOSYS.  Some functions are actually named
23859     something starting with __ and the normal name is an alias.  */
23860 #if defined __stub_$ac_func || defined __stub___$ac_func
23861 choke me
23862 #endif
23863
23864 int
23865 main ()
23866 {
23867 return $ac_func ();
23868   ;
23869   return 0;
23870 }
23871 _ACEOF
23872 rm -f conftest.$ac_objext conftest$ac_exeext
23873 if { (ac_try="$ac_link"
23874 case "(($ac_try" in
23875   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23876   *) ac_try_echo=$ac_try;;
23877 esac
23878 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23879 $as_echo "$ac_try_echo") >&5
23880   (eval "$ac_link") 2>conftest.er1
23881   ac_status=$?
23882   grep -v '^ *+' conftest.er1 >conftest.err
23883   rm -f conftest.er1
23884   cat conftest.err >&5
23885   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23886   (exit $ac_status); } && {
23887          test -z "$ac_c_werror_flag" ||
23888          test ! -s conftest.err
23889        } && test -s conftest$ac_exeext && {
23890          test "$cross_compiling" = yes ||
23891          $as_test_x conftest$ac_exeext
23892        }; then
23893   eval "$as_ac_var=yes"
23894 else
23895   $as_echo "$as_me: failed program was:" >&5
23896 sed 's/^/| /' conftest.$ac_ext >&5
23897
23898         eval "$as_ac_var=no"
23899 fi
23900
23901 rm -rf conftest.dSYM
23902 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23903       conftest$ac_exeext conftest.$ac_ext
23904 fi
23905 ac_res=`eval 'as_val=${'$as_ac_var'}
23906                  $as_echo "$as_val"'`
23907                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23908 $as_echo "$ac_res" >&6; }
23909 as_val=`eval 'as_val=${'$as_ac_var'}
23910                  $as_echo "$as_val"'`
23911    if test "x$as_val" = x""yes; then
23912   cat >>confdefs.h <<_ACEOF
23913 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23914 _ACEOF
23915
23916 fi
23917 done
23918
23919
23920 # Do test here with the proper thread flags
23921 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
23922 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
23923 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
23924   $as_echo_n "(cached) " >&6
23925 else
23926   cat >conftest.$ac_ext <<_ACEOF
23927 /* confdefs.h.  */
23928 _ACEOF
23929 cat confdefs.h >>conftest.$ac_ext
23930 cat >>conftest.$ac_ext <<_ACEOF
23931 /* end confdefs.h.  */
23932 #include <sys/types.h>
23933 #include <pwd.h>
23934 int
23935 main ()
23936 {
23937 uid_t uid;
23938 struct passwd *space;
23939 char *buf;
23940 size_t bufsize;
23941 struct passwd **result;
23942 getpwuid_r(uid, space, buf, bufsize, result);
23943   ;
23944   return 0;
23945 }
23946 _ACEOF
23947 rm -f conftest.$ac_objext
23948 if { (ac_try="$ac_compile"
23949 case "(($ac_try" in
23950   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23951   *) ac_try_echo=$ac_try;;
23952 esac
23953 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23954 $as_echo "$ac_try_echo") >&5
23955   (eval "$ac_compile") 2>conftest.er1
23956   ac_status=$?
23957   grep -v '^ *+' conftest.er1 >conftest.err
23958   rm -f conftest.er1
23959   cat conftest.err >&5
23960   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23961   (exit $ac_status); } && {
23962          test -z "$ac_c_werror_flag" ||
23963          test ! -s conftest.err
23964        } && test -s conftest.$ac_objext; then
23965   pgac_cv_func_getpwuid_r_5arg=yes
23966 else
23967   $as_echo "$as_me: failed program was:" >&5
23968 sed 's/^/| /' conftest.$ac_ext >&5
23969
23970         pgac_cv_func_getpwuid_r_5arg=no
23971 fi
23972
23973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23974 fi
23975 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
23976 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
23977 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
23978
23979 cat >>confdefs.h <<\_ACEOF
23980 #define GETPWUID_R_5ARG 1
23981 _ACEOF
23982
23983 fi
23984
23985 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
23986 $as_echo_n "checking whether strerror_r returns int... " >&6; }
23987 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
23988   $as_echo_n "(cached) " >&6
23989 else
23990   cat >conftest.$ac_ext <<_ACEOF
23991 /* confdefs.h.  */
23992 _ACEOF
23993 cat confdefs.h >>conftest.$ac_ext
23994 cat >>conftest.$ac_ext <<_ACEOF
23995 /* end confdefs.h.  */
23996 #include <string.h>
23997 int
23998 main ()
23999 {
24000 #ifndef _AIX
24001 int strerror_r(int, char *, size_t);
24002 #else
24003 /* Older AIX has 'int' for the third argument so we don't test the args. */
24004 int strerror_r();
24005 #endif
24006   ;
24007   return 0;
24008 }
24009 _ACEOF
24010 rm -f conftest.$ac_objext
24011 if { (ac_try="$ac_compile"
24012 case "(($ac_try" in
24013   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24014   *) ac_try_echo=$ac_try;;
24015 esac
24016 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24017 $as_echo "$ac_try_echo") >&5
24018   (eval "$ac_compile") 2>conftest.er1
24019   ac_status=$?
24020   grep -v '^ *+' conftest.er1 >conftest.err
24021   rm -f conftest.er1
24022   cat conftest.err >&5
24023   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24024   (exit $ac_status); } && {
24025          test -z "$ac_c_werror_flag" ||
24026          test ! -s conftest.err
24027        } && test -s conftest.$ac_objext; then
24028   pgac_cv_func_strerror_r_int=yes
24029 else
24030   $as_echo "$as_me: failed program was:" >&5
24031 sed 's/^/| /' conftest.$ac_ext >&5
24032
24033         pgac_cv_func_strerror_r_int=no
24034 fi
24035
24036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24037 fi
24038 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
24039 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
24040 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
24041
24042 cat >>confdefs.h <<\_ACEOF
24043 #define STRERROR_R_INT 1
24044 _ACEOF
24045
24046 fi
24047
24048
24049 CFLAGS="$_CFLAGS"
24050 LIBS="$_LIBS"
24051
24052 else
24053 # do not use values from template file
24054 PTHREAD_CFLAGS=
24055 PTHREAD_LIBS=
24056 fi
24057
24058
24059
24060
24061
24062 # We can test for libldap_r only after we know PTHREAD_LIBS
24063 if test "$with_ldap" = yes ; then
24064   _LIBS="$LIBS"
24065   if test "$PORTNAME" != "win32"; then
24066
24067 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
24068 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
24069 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
24070   $as_echo_n "(cached) " >&6
24071 else
24072   ac_check_lib_save_LIBS=$LIBS
24073 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
24074 cat >conftest.$ac_ext <<_ACEOF
24075 /* confdefs.h.  */
24076 _ACEOF
24077 cat confdefs.h >>conftest.$ac_ext
24078 cat >>conftest.$ac_ext <<_ACEOF
24079 /* end confdefs.h.  */
24080
24081 /* Override any GCC internal prototype to avoid an error.
24082    Use char because int might match the return type of a GCC
24083    builtin and then its argument prototype would still apply.  */
24084 #ifdef __cplusplus
24085 extern "C"
24086 #endif
24087 char ldap_bind ();
24088 int
24089 main ()
24090 {
24091 return ldap_bind ();
24092   ;
24093   return 0;
24094 }
24095 _ACEOF
24096 rm -f conftest.$ac_objext conftest$ac_exeext
24097 if { (ac_try="$ac_link"
24098 case "(($ac_try" in
24099   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24100   *) ac_try_echo=$ac_try;;
24101 esac
24102 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24103 $as_echo "$ac_try_echo") >&5
24104   (eval "$ac_link") 2>conftest.er1
24105   ac_status=$?
24106   grep -v '^ *+' conftest.er1 >conftest.err
24107   rm -f conftest.er1
24108   cat conftest.err >&5
24109   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24110   (exit $ac_status); } && {
24111          test -z "$ac_c_werror_flag" ||
24112          test ! -s conftest.err
24113        } && test -s conftest$ac_exeext && {
24114          test "$cross_compiling" = yes ||
24115          $as_test_x conftest$ac_exeext
24116        }; then
24117   ac_cv_lib_ldap_ldap_bind=yes
24118 else
24119   $as_echo "$as_me: failed program was:" >&5
24120 sed 's/^/| /' conftest.$ac_ext >&5
24121
24122         ac_cv_lib_ldap_ldap_bind=no
24123 fi
24124
24125 rm -rf conftest.dSYM
24126 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24127       conftest$ac_exeext conftest.$ac_ext
24128 LIBS=$ac_check_lib_save_LIBS
24129 fi
24130 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
24131 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
24132 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
24133   cat >>confdefs.h <<_ACEOF
24134 #define HAVE_LIBLDAP 1
24135 _ACEOF
24136
24137   LIBS="-lldap $LIBS"
24138
24139 else
24140   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
24141 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
24142    { (exit 1); exit 1; }; }
24143 fi
24144
24145     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
24146     if test "$enable_thread_safety" = yes; then
24147       # on some platforms ldap_r fails to link without PTHREAD_LIBS
24148
24149 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
24150 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
24151 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
24152   $as_echo_n "(cached) " >&6
24153 else
24154   ac_check_lib_save_LIBS=$LIBS
24155 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
24156 cat >conftest.$ac_ext <<_ACEOF
24157 /* confdefs.h.  */
24158 _ACEOF
24159 cat confdefs.h >>conftest.$ac_ext
24160 cat >>conftest.$ac_ext <<_ACEOF
24161 /* end confdefs.h.  */
24162
24163 /* Override any GCC internal prototype to avoid an error.
24164    Use char because int might match the return type of a GCC
24165    builtin and then its argument prototype would still apply.  */
24166 #ifdef __cplusplus
24167 extern "C"
24168 #endif
24169 char ldap_simple_bind ();
24170 int
24171 main ()
24172 {
24173 return ldap_simple_bind ();
24174   ;
24175   return 0;
24176 }
24177 _ACEOF
24178 rm -f conftest.$ac_objext conftest$ac_exeext
24179 if { (ac_try="$ac_link"
24180 case "(($ac_try" in
24181   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24182   *) ac_try_echo=$ac_try;;
24183 esac
24184 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24185 $as_echo "$ac_try_echo") >&5
24186   (eval "$ac_link") 2>conftest.er1
24187   ac_status=$?
24188   grep -v '^ *+' conftest.er1 >conftest.err
24189   rm -f conftest.er1
24190   cat conftest.err >&5
24191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24192   (exit $ac_status); } && {
24193          test -z "$ac_c_werror_flag" ||
24194          test ! -s conftest.err
24195        } && test -s conftest$ac_exeext && {
24196          test "$cross_compiling" = yes ||
24197          $as_test_x conftest$ac_exeext
24198        }; then
24199   ac_cv_lib_ldap_r_ldap_simple_bind=yes
24200 else
24201   $as_echo "$as_me: failed program was:" >&5
24202 sed 's/^/| /' conftest.$ac_ext >&5
24203
24204         ac_cv_lib_ldap_r_ldap_simple_bind=no
24205 fi
24206
24207 rm -rf conftest.dSYM
24208 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24209       conftest$ac_exeext conftest.$ac_ext
24210 LIBS=$ac_check_lib_save_LIBS
24211 fi
24212 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
24213 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
24214 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
24215   cat >>confdefs.h <<_ACEOF
24216 #define HAVE_LIBLDAP_R 1
24217 _ACEOF
24218
24219   LIBS="-lldap_r $LIBS"
24220
24221 else
24222   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
24223 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
24224    { (exit 1); exit 1; }; }
24225 fi
24226
24227       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
24228     else
24229       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
24230     fi
24231   else
24232
24233 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
24234 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
24235 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
24236   $as_echo_n "(cached) " >&6
24237 else
24238   ac_check_lib_save_LIBS=$LIBS
24239 LIBS="-lwldap32  $LIBS"
24240 cat >conftest.$ac_ext <<_ACEOF
24241 /* confdefs.h.  */
24242 _ACEOF
24243 cat confdefs.h >>conftest.$ac_ext
24244 cat >>conftest.$ac_ext <<_ACEOF
24245 /* end confdefs.h.  */
24246
24247 /* Override any GCC internal prototype to avoid an error.
24248    Use char because int might match the return type of a GCC
24249    builtin and then its argument prototype would still apply.  */
24250 #ifdef __cplusplus
24251 extern "C"
24252 #endif
24253 char ldap_bind ();
24254 int
24255 main ()
24256 {
24257 return ldap_bind ();
24258   ;
24259   return 0;
24260 }
24261 _ACEOF
24262 rm -f conftest.$ac_objext conftest$ac_exeext
24263 if { (ac_try="$ac_link"
24264 case "(($ac_try" in
24265   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24266   *) ac_try_echo=$ac_try;;
24267 esac
24268 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24269 $as_echo "$ac_try_echo") >&5
24270   (eval "$ac_link") 2>conftest.er1
24271   ac_status=$?
24272   grep -v '^ *+' conftest.er1 >conftest.err
24273   rm -f conftest.er1
24274   cat conftest.err >&5
24275   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24276   (exit $ac_status); } && {
24277          test -z "$ac_c_werror_flag" ||
24278          test ! -s conftest.err
24279        } && test -s conftest$ac_exeext && {
24280          test "$cross_compiling" = yes ||
24281          $as_test_x conftest$ac_exeext
24282        }; then
24283   ac_cv_lib_wldap32_ldap_bind=yes
24284 else
24285   $as_echo "$as_me: failed program was:" >&5
24286 sed 's/^/| /' conftest.$ac_ext >&5
24287
24288         ac_cv_lib_wldap32_ldap_bind=no
24289 fi
24290
24291 rm -rf conftest.dSYM
24292 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24293       conftest$ac_exeext conftest.$ac_ext
24294 LIBS=$ac_check_lib_save_LIBS
24295 fi
24296 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
24297 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
24298 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
24299   cat >>confdefs.h <<_ACEOF
24300 #define HAVE_LIBWLDAP32 1
24301 _ACEOF
24302
24303   LIBS="-lwldap32 $LIBS"
24304
24305 else
24306   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
24307 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
24308    { (exit 1); exit 1; }; }
24309 fi
24310
24311     LDAP_LIBS_FE="-lwldap32"
24312     LDAP_LIBS_BE="-lwldap32"
24313   fi
24314   LIBS="$_LIBS"
24315 fi
24316
24317
24318
24319
24320 # This test makes sure that run tests work at all.  Sometimes a shared
24321 # library is found by the linker, but the runtime linker can't find it.
24322 # This check should come after all modifications of compiler or linker
24323 # variables, and before any other run tests.
24324 { $as_echo "$as_me:$LINENO: checking test program" >&5
24325 $as_echo_n "checking test program... " >&6; }
24326 if test "$cross_compiling" = yes; then
24327   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
24328 $as_echo "cross-compiling" >&6; }
24329 else
24330   cat >conftest.$ac_ext <<_ACEOF
24331 /* confdefs.h.  */
24332 _ACEOF
24333 cat confdefs.h >>conftest.$ac_ext
24334 cat >>conftest.$ac_ext <<_ACEOF
24335 /* end confdefs.h.  */
24336 int main() { return 0; }
24337 _ACEOF
24338 rm -f conftest$ac_exeext
24339 if { (ac_try="$ac_link"
24340 case "(($ac_try" in
24341   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24342   *) ac_try_echo=$ac_try;;
24343 esac
24344 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24345 $as_echo "$ac_try_echo") >&5
24346   (eval "$ac_link") 2>&5
24347   ac_status=$?
24348   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24349   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24350   { (case "(($ac_try" in
24351   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24352   *) ac_try_echo=$ac_try;;
24353 esac
24354 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24355 $as_echo "$ac_try_echo") >&5
24356   (eval "$ac_try") 2>&5
24357   ac_status=$?
24358   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24359   (exit $ac_status); }; }; then
24360   { $as_echo "$as_me:$LINENO: result: ok" >&5
24361 $as_echo "ok" >&6; }
24362 else
24363   $as_echo "$as_me: program exited with status $ac_status" >&5
24364 $as_echo "$as_me: failed program was:" >&5
24365 sed 's/^/| /' conftest.$ac_ext >&5
24366
24367 ( exit $ac_status )
24368 { $as_echo "$as_me:$LINENO: result: failed" >&5
24369 $as_echo "failed" >&6; }
24370 { { $as_echo "$as_me:$LINENO: error:
24371 Could not execute a simple test program.  This may be a problem
24372 related to locating shared libraries.  Check the file 'config.log'
24373 for the exact reason." >&5
24374 $as_echo "$as_me: error:
24375 Could not execute a simple test program.  This may be a problem
24376 related to locating shared libraries.  Check the file 'config.log'
24377 for the exact reason." >&2;}
24378    { (exit 1); exit 1; }; }
24379 fi
24380 rm -rf conftest.dSYM
24381 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24382 fi
24383
24384
24385
24386 # --------------------
24387 # Run tests below here
24388 # --------------------
24389
24390 # Force use of our snprintf if system's doesn't do arg control
24391 # See comment above at snprintf test for details.
24392 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
24393   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
24394 $as_echo_n "checking whether printf supports argument control... " >&6; }
24395 if test "${pgac_cv_printf_arg_control+set}" = set; then
24396   $as_echo_n "(cached) " >&6
24397 else
24398   if test "$cross_compiling" = yes; then
24399   pgac_cv_printf_arg_control=cross
24400 else
24401   cat >conftest.$ac_ext <<_ACEOF
24402 /* confdefs.h.  */
24403 _ACEOF
24404 cat confdefs.h >>conftest.$ac_ext
24405 cat >>conftest.$ac_ext <<_ACEOF
24406 /* end confdefs.h.  */
24407 #include <stdio.h>
24408 #include <string.h>
24409
24410 int main()
24411 {
24412   char buf[100];
24413
24414   /* can it swap arguments? */
24415   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
24416   if (strcmp(buf, "4 3") != 0)
24417     return 1;
24418   return 0;
24419 }
24420 _ACEOF
24421 rm -f conftest$ac_exeext
24422 if { (ac_try="$ac_link"
24423 case "(($ac_try" in
24424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24425   *) ac_try_echo=$ac_try;;
24426 esac
24427 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24428 $as_echo "$ac_try_echo") >&5
24429   (eval "$ac_link") 2>&5
24430   ac_status=$?
24431   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24432   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24433   { (case "(($ac_try" in
24434   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24435   *) ac_try_echo=$ac_try;;
24436 esac
24437 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24438 $as_echo "$ac_try_echo") >&5
24439   (eval "$ac_try") 2>&5
24440   ac_status=$?
24441   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24442   (exit $ac_status); }; }; then
24443   pgac_cv_printf_arg_control=yes
24444 else
24445   $as_echo "$as_me: program exited with status $ac_status" >&5
24446 $as_echo "$as_me: failed program was:" >&5
24447 sed 's/^/| /' conftest.$ac_ext >&5
24448
24449 ( exit $ac_status )
24450 pgac_cv_printf_arg_control=no
24451 fi
24452 rm -rf conftest.dSYM
24453 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24454 fi
24455
24456
24457
24458 fi
24459 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
24460 $as_echo "$pgac_cv_printf_arg_control" >&6; }
24461
24462   if test $pgac_cv_printf_arg_control != yes ; then
24463     pgac_need_repl_snprintf=yes
24464   fi
24465 fi
24466
24467
24468
24469
24470 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
24471 $as_echo_n "checking whether long int is 64 bits... " >&6; }
24472 if test "${pgac_cv_type_long_int_64+set}" = set; then
24473   $as_echo_n "(cached) " >&6
24474 else
24475   if test "$cross_compiling" = yes; then
24476   # If cross-compiling, check the size reported by the compiler and
24477 # trust that the arithmetic works.
24478 cat >conftest.$ac_ext <<_ACEOF
24479 /* confdefs.h.  */
24480 _ACEOF
24481 cat confdefs.h >>conftest.$ac_ext
24482 cat >>conftest.$ac_ext <<_ACEOF
24483 /* end confdefs.h.  */
24484
24485 int
24486 main ()
24487 {
24488 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
24489 test_array [0] = 0
24490
24491   ;
24492   return 0;
24493 }
24494 _ACEOF
24495 rm -f conftest.$ac_objext
24496 if { (ac_try="$ac_compile"
24497 case "(($ac_try" in
24498   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24499   *) ac_try_echo=$ac_try;;
24500 esac
24501 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24502 $as_echo "$ac_try_echo") >&5
24503   (eval "$ac_compile") 2>conftest.er1
24504   ac_status=$?
24505   grep -v '^ *+' conftest.er1 >conftest.err
24506   rm -f conftest.er1
24507   cat conftest.err >&5
24508   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24509   (exit $ac_status); } && {
24510          test -z "$ac_c_werror_flag" ||
24511          test ! -s conftest.err
24512        } && test -s conftest.$ac_objext; then
24513   pgac_cv_type_long_int_64=yes
24514 else
24515   $as_echo "$as_me: failed program was:" >&5
24516 sed 's/^/| /' conftest.$ac_ext >&5
24517
24518         pgac_cv_type_long_int_64=no
24519 fi
24520
24521 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24522 else
24523   cat >conftest.$ac_ext <<_ACEOF
24524 /* confdefs.h.  */
24525 _ACEOF
24526 cat confdefs.h >>conftest.$ac_ext
24527 cat >>conftest.$ac_ext <<_ACEOF
24528 /* end confdefs.h.  */
24529 typedef long int ac_int64;
24530
24531 /*
24532  * These are globals to discourage the compiler from folding all the
24533  * arithmetic tests down to compile-time constants.
24534  */
24535 ac_int64 a = 20000001;
24536 ac_int64 b = 40000005;
24537
24538 int does_int64_work()
24539 {
24540   ac_int64 c,d;
24541
24542   if (sizeof(ac_int64) != 8)
24543     return 0;                   /* definitely not the right size */
24544
24545   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
24546   c = a * b;
24547   d = (c + b) / b;
24548   if (d != a+1)
24549     return 0;
24550   return 1;
24551 }
24552 main() {
24553   exit(! does_int64_work());
24554 }
24555 _ACEOF
24556 rm -f conftest$ac_exeext
24557 if { (ac_try="$ac_link"
24558 case "(($ac_try" in
24559   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24560   *) ac_try_echo=$ac_try;;
24561 esac
24562 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24563 $as_echo "$ac_try_echo") >&5
24564   (eval "$ac_link") 2>&5
24565   ac_status=$?
24566   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24567   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24568   { (case "(($ac_try" in
24569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24570   *) ac_try_echo=$ac_try;;
24571 esac
24572 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24573 $as_echo "$ac_try_echo") >&5
24574   (eval "$ac_try") 2>&5
24575   ac_status=$?
24576   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24577   (exit $ac_status); }; }; then
24578   pgac_cv_type_long_int_64=yes
24579 else
24580   $as_echo "$as_me: program exited with status $ac_status" >&5
24581 $as_echo "$as_me: failed program was:" >&5
24582 sed 's/^/| /' conftest.$ac_ext >&5
24583
24584 ( exit $ac_status )
24585 pgac_cv_type_long_int_64=no
24586 fi
24587 rm -rf conftest.dSYM
24588 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24589 fi
24590
24591
24592 fi
24593 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
24594 $as_echo "$pgac_cv_type_long_int_64" >&6; }
24595
24596 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
24597 if test x"$pgac_cv_type_long_int_64" = xyes ; then
24598
24599 cat >>confdefs.h <<\_ACEOF
24600 #define HAVE_LONG_INT_64 1
24601 _ACEOF
24602
24603 fi
24604
24605
24606 if test x"$HAVE_LONG_INT_64" = x"yes" ; then
24607   pg_int64_type="long int"
24608 else
24609   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
24610 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
24611 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
24612   $as_echo_n "(cached) " >&6
24613 else
24614   if test "$cross_compiling" = yes; then
24615   # If cross-compiling, check the size reported by the compiler and
24616 # trust that the arithmetic works.
24617 cat >conftest.$ac_ext <<_ACEOF
24618 /* confdefs.h.  */
24619 _ACEOF
24620 cat confdefs.h >>conftest.$ac_ext
24621 cat >>conftest.$ac_ext <<_ACEOF
24622 /* end confdefs.h.  */
24623
24624 int
24625 main ()
24626 {
24627 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
24628 test_array [0] = 0
24629
24630   ;
24631   return 0;
24632 }
24633 _ACEOF
24634 rm -f conftest.$ac_objext
24635 if { (ac_try="$ac_compile"
24636 case "(($ac_try" in
24637   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24638   *) ac_try_echo=$ac_try;;
24639 esac
24640 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24641 $as_echo "$ac_try_echo") >&5
24642   (eval "$ac_compile") 2>conftest.er1
24643   ac_status=$?
24644   grep -v '^ *+' conftest.er1 >conftest.err
24645   rm -f conftest.er1
24646   cat conftest.err >&5
24647   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24648   (exit $ac_status); } && {
24649          test -z "$ac_c_werror_flag" ||
24650          test ! -s conftest.err
24651        } && test -s conftest.$ac_objext; then
24652   pgac_cv_type_long_long_int_64=yes
24653 else
24654   $as_echo "$as_me: failed program was:" >&5
24655 sed 's/^/| /' conftest.$ac_ext >&5
24656
24657         pgac_cv_type_long_long_int_64=no
24658 fi
24659
24660 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24661 else
24662   cat >conftest.$ac_ext <<_ACEOF
24663 /* confdefs.h.  */
24664 _ACEOF
24665 cat confdefs.h >>conftest.$ac_ext
24666 cat >>conftest.$ac_ext <<_ACEOF
24667 /* end confdefs.h.  */
24668 typedef long long int ac_int64;
24669
24670 /*
24671  * These are globals to discourage the compiler from folding all the
24672  * arithmetic tests down to compile-time constants.
24673  */
24674 ac_int64 a = 20000001;
24675 ac_int64 b = 40000005;
24676
24677 int does_int64_work()
24678 {
24679   ac_int64 c,d;
24680
24681   if (sizeof(ac_int64) != 8)
24682     return 0;                   /* definitely not the right size */
24683
24684   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
24685   c = a * b;
24686   d = (c + b) / b;
24687   if (d != a+1)
24688     return 0;
24689   return 1;
24690 }
24691 main() {
24692   exit(! does_int64_work());
24693 }
24694 _ACEOF
24695 rm -f conftest$ac_exeext
24696 if { (ac_try="$ac_link"
24697 case "(($ac_try" in
24698   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24699   *) ac_try_echo=$ac_try;;
24700 esac
24701 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24702 $as_echo "$ac_try_echo") >&5
24703   (eval "$ac_link") 2>&5
24704   ac_status=$?
24705   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24706   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24707   { (case "(($ac_try" in
24708   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24709   *) ac_try_echo=$ac_try;;
24710 esac
24711 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24712 $as_echo "$ac_try_echo") >&5
24713   (eval "$ac_try") 2>&5
24714   ac_status=$?
24715   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24716   (exit $ac_status); }; }; then
24717   pgac_cv_type_long_long_int_64=yes
24718 else
24719   $as_echo "$as_me: program exited with status $ac_status" >&5
24720 $as_echo "$as_me: failed program was:" >&5
24721 sed 's/^/| /' conftest.$ac_ext >&5
24722
24723 ( exit $ac_status )
24724 pgac_cv_type_long_long_int_64=no
24725 fi
24726 rm -rf conftest.dSYM
24727 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24728 fi
24729
24730
24731 fi
24732 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
24733 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
24734
24735 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
24736 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
24737
24738 cat >>confdefs.h <<\_ACEOF
24739 #define HAVE_LONG_LONG_INT_64 1
24740 _ACEOF
24741
24742 fi
24743
24744   if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
24745     pg_int64_type="long long int"
24746   else
24747     { { $as_echo "$as_me:$LINENO: error: Cannot find a working 64-bit integer type." >&5
24748 $as_echo "$as_me: error: Cannot find a working 64-bit integer type." >&2;}
24749    { (exit 1); exit 1; }; }
24750   fi
24751 fi
24752
24753
24754 cat >>confdefs.h <<_ACEOF
24755 #define PG_INT64_TYPE $pg_int64_type
24756 _ACEOF
24757
24758
24759
24760 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
24761   cat >conftest.$ac_ext <<_ACEOF
24762 /* confdefs.h.  */
24763 _ACEOF
24764 cat confdefs.h >>conftest.$ac_ext
24765 cat >>conftest.$ac_ext <<_ACEOF
24766 /* end confdefs.h.  */
24767
24768 #define INT64CONST(x)  x##LL
24769 long long int foo = INT64CONST(0x1234567890123456);
24770
24771 int
24772 main ()
24773 {
24774
24775   ;
24776   return 0;
24777 }
24778 _ACEOF
24779 rm -f conftest.$ac_objext
24780 if { (ac_try="$ac_compile"
24781 case "(($ac_try" in
24782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24783   *) ac_try_echo=$ac_try;;
24784 esac
24785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24786 $as_echo "$ac_try_echo") >&5
24787   (eval "$ac_compile") 2>conftest.er1
24788   ac_status=$?
24789   grep -v '^ *+' conftest.er1 >conftest.err
24790   rm -f conftest.er1
24791   cat conftest.err >&5
24792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24793   (exit $ac_status); } && {
24794          test -z "$ac_c_werror_flag" ||
24795          test ! -s conftest.err
24796        } && test -s conftest.$ac_objext; then
24797
24798 cat >>confdefs.h <<\_ACEOF
24799 #define HAVE_LL_CONSTANTS 1
24800 _ACEOF
24801
24802 else
24803   $as_echo "$as_me: failed program was:" >&5
24804 sed 's/^/| /' conftest.$ac_ext >&5
24805
24806
24807 fi
24808
24809 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24810 fi
24811
24812
24813 # If we found "long int" is 64 bits, assume snprintf handles it.  If
24814 # we found we need to use "long long int", better check.  We cope with
24815 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
24816 # work, fall back to our own snprintf emulation (which we know uses %lld).
24817
24818 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
24819   if test $pgac_need_repl_snprintf = no; then
24820     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
24821 $as_echo_n "checking snprintf format for long long int... " >&6; }
24822 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
24823   $as_echo_n "(cached) " >&6
24824 else
24825   for pgac_format in '%lld' '%qd' '%I64d'; do
24826 if test "$cross_compiling" = yes; then
24827   pgac_cv_snprintf_long_long_int_format=cross; break
24828 else
24829   cat >conftest.$ac_ext <<_ACEOF
24830 /* confdefs.h.  */
24831 _ACEOF
24832 cat confdefs.h >>conftest.$ac_ext
24833 cat >>conftest.$ac_ext <<_ACEOF
24834 /* end confdefs.h.  */
24835 #include <stdio.h>
24836 typedef long long int ac_int64;
24837 #define INT64_FORMAT "$pgac_format"
24838
24839 ac_int64 a = 20000001;
24840 ac_int64 b = 40000005;
24841
24842 int does_int64_snprintf_work()
24843 {
24844   ac_int64 c;
24845   char buf[100];
24846
24847   if (sizeof(ac_int64) != 8)
24848     return 0;                   /* doesn't look like the right size */
24849
24850   c = a * b;
24851   snprintf(buf, 100, INT64_FORMAT, c);
24852   if (strcmp(buf, "800000140000005") != 0)
24853     return 0;                   /* either multiply or snprintf is busted */
24854   return 1;
24855 }
24856 main() {
24857   exit(! does_int64_snprintf_work());
24858 }
24859 _ACEOF
24860 rm -f conftest$ac_exeext
24861 if { (ac_try="$ac_link"
24862 case "(($ac_try" in
24863   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24864   *) ac_try_echo=$ac_try;;
24865 esac
24866 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24867 $as_echo "$ac_try_echo") >&5
24868   (eval "$ac_link") 2>&5
24869   ac_status=$?
24870   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24871   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24872   { (case "(($ac_try" in
24873   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24874   *) ac_try_echo=$ac_try;;
24875 esac
24876 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24877 $as_echo "$ac_try_echo") >&5
24878   (eval "$ac_try") 2>&5
24879   ac_status=$?
24880   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24881   (exit $ac_status); }; }; then
24882   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
24883 else
24884   $as_echo "$as_me: program exited with status $ac_status" >&5
24885 $as_echo "$as_me: failed program was:" >&5
24886 sed 's/^/| /' conftest.$ac_ext >&5
24887
24888 fi
24889 rm -rf conftest.dSYM
24890 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24891 fi
24892
24893
24894 done
24895 fi
24896
24897 LONG_LONG_INT_FORMAT=''
24898
24899 case $pgac_cv_snprintf_long_long_int_format in
24900   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
24901 $as_echo "cannot test (not on host machine)" >&6; };;
24902   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
24903 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
24904          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
24905   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
24906 $as_echo "none" >&6; };;
24907 esac
24908     if test "$LONG_LONG_INT_FORMAT" = ""; then
24909       # Force usage of our own snprintf, since system snprintf is broken
24910       pgac_need_repl_snprintf=yes
24911       LONG_LONG_INT_FORMAT='%lld'
24912     fi
24913   else
24914     # Here if we previously decided we needed to use our own snprintf
24915     LONG_LONG_INT_FORMAT='%lld'
24916   fi
24917   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
24918   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
24919   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
24920 else
24921   # Here if we are not using 'long long int' at all
24922   INT64_FORMAT='"%ld"'
24923   UINT64_FORMAT='"%lu"'
24924 fi
24925
24926
24927 cat >>confdefs.h <<_ACEOF
24928 #define INT64_FORMAT $INT64_FORMAT
24929 _ACEOF
24930
24931
24932
24933 cat >>confdefs.h <<_ACEOF
24934 #define UINT64_FORMAT $UINT64_FORMAT
24935 _ACEOF
24936
24937
24938 # Now we have checked all the reasons to replace snprintf
24939 if test $pgac_need_repl_snprintf = yes; then
24940
24941 cat >>confdefs.h <<\_ACEOF
24942 #define USE_REPL_SNPRINTF 1
24943 _ACEOF
24944
24945   case " $LIBOBJS " in
24946   *" snprintf.$ac_objext "* ) ;;
24947   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
24948  ;;
24949 esac
24950
24951 fi
24952
24953 # Check size of void *, size_t (enables tweaks for > 32bit address space)
24954 # The cast to long int works around a bug in the HP C Compiler
24955 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24956 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24957 # This bug is HP SR number 8606223364.
24958 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
24959 $as_echo_n "checking size of void *... " >&6; }
24960 if test "${ac_cv_sizeof_void_p+set}" = set; then
24961   $as_echo_n "(cached) " >&6
24962 else
24963   if test "$cross_compiling" = yes; then
24964   # Depending upon the size, compute the lo and hi bounds.
24965 cat >conftest.$ac_ext <<_ACEOF
24966 /* confdefs.h.  */
24967 _ACEOF
24968 cat confdefs.h >>conftest.$ac_ext
24969 cat >>conftest.$ac_ext <<_ACEOF
24970 /* end confdefs.h.  */
24971 $ac_includes_default
24972 int
24973 main ()
24974 {
24975 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
24976 test_array [0] = 0
24977
24978   ;
24979   return 0;
24980 }
24981 _ACEOF
24982 rm -f conftest.$ac_objext
24983 if { (ac_try="$ac_compile"
24984 case "(($ac_try" in
24985   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24986   *) ac_try_echo=$ac_try;;
24987 esac
24988 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24989 $as_echo "$ac_try_echo") >&5
24990   (eval "$ac_compile") 2>conftest.er1
24991   ac_status=$?
24992   grep -v '^ *+' conftest.er1 >conftest.err
24993   rm -f conftest.er1
24994   cat conftest.err >&5
24995   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24996   (exit $ac_status); } && {
24997          test -z "$ac_c_werror_flag" ||
24998          test ! -s conftest.err
24999        } && test -s conftest.$ac_objext; then
25000   ac_lo=0 ac_mid=0
25001   while :; do
25002     cat >conftest.$ac_ext <<_ACEOF
25003 /* confdefs.h.  */
25004 _ACEOF
25005 cat confdefs.h >>conftest.$ac_ext
25006 cat >>conftest.$ac_ext <<_ACEOF
25007 /* end confdefs.h.  */
25008 $ac_includes_default
25009 int
25010 main ()
25011 {
25012 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
25013 test_array [0] = 0
25014
25015   ;
25016   return 0;
25017 }
25018 _ACEOF
25019 rm -f conftest.$ac_objext
25020 if { (ac_try="$ac_compile"
25021 case "(($ac_try" in
25022   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25023   *) ac_try_echo=$ac_try;;
25024 esac
25025 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25026 $as_echo "$ac_try_echo") >&5
25027   (eval "$ac_compile") 2>conftest.er1
25028   ac_status=$?
25029   grep -v '^ *+' conftest.er1 >conftest.err
25030   rm -f conftest.er1
25031   cat conftest.err >&5
25032   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25033   (exit $ac_status); } && {
25034          test -z "$ac_c_werror_flag" ||
25035          test ! -s conftest.err
25036        } && test -s conftest.$ac_objext; then
25037   ac_hi=$ac_mid; break
25038 else
25039   $as_echo "$as_me: failed program was:" >&5
25040 sed 's/^/| /' conftest.$ac_ext >&5
25041
25042         ac_lo=`expr $ac_mid + 1`
25043                         if test $ac_lo -le $ac_mid; then
25044                           ac_lo= ac_hi=
25045                           break
25046                         fi
25047                         ac_mid=`expr 2 '*' $ac_mid + 1`
25048 fi
25049
25050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25051   done
25052 else
25053   $as_echo "$as_me: failed program was:" >&5
25054 sed 's/^/| /' conftest.$ac_ext >&5
25055
25056         cat >conftest.$ac_ext <<_ACEOF
25057 /* confdefs.h.  */
25058 _ACEOF
25059 cat confdefs.h >>conftest.$ac_ext
25060 cat >>conftest.$ac_ext <<_ACEOF
25061 /* end confdefs.h.  */
25062 $ac_includes_default
25063 int
25064 main ()
25065 {
25066 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
25067 test_array [0] = 0
25068
25069   ;
25070   return 0;
25071 }
25072 _ACEOF
25073 rm -f conftest.$ac_objext
25074 if { (ac_try="$ac_compile"
25075 case "(($ac_try" in
25076   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25077   *) ac_try_echo=$ac_try;;
25078 esac
25079 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25080 $as_echo "$ac_try_echo") >&5
25081   (eval "$ac_compile") 2>conftest.er1
25082   ac_status=$?
25083   grep -v '^ *+' conftest.er1 >conftest.err
25084   rm -f conftest.er1
25085   cat conftest.err >&5
25086   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25087   (exit $ac_status); } && {
25088          test -z "$ac_c_werror_flag" ||
25089          test ! -s conftest.err
25090        } && test -s conftest.$ac_objext; then
25091   ac_hi=-1 ac_mid=-1
25092   while :; do
25093     cat >conftest.$ac_ext <<_ACEOF
25094 /* confdefs.h.  */
25095 _ACEOF
25096 cat confdefs.h >>conftest.$ac_ext
25097 cat >>conftest.$ac_ext <<_ACEOF
25098 /* end confdefs.h.  */
25099 $ac_includes_default
25100 int
25101 main ()
25102 {
25103 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
25104 test_array [0] = 0
25105
25106   ;
25107   return 0;
25108 }
25109 _ACEOF
25110 rm -f conftest.$ac_objext
25111 if { (ac_try="$ac_compile"
25112 case "(($ac_try" in
25113   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25114   *) ac_try_echo=$ac_try;;
25115 esac
25116 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25117 $as_echo "$ac_try_echo") >&5
25118   (eval "$ac_compile") 2>conftest.er1
25119   ac_status=$?
25120   grep -v '^ *+' conftest.er1 >conftest.err
25121   rm -f conftest.er1
25122   cat conftest.err >&5
25123   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25124   (exit $ac_status); } && {
25125          test -z "$ac_c_werror_flag" ||
25126          test ! -s conftest.err
25127        } && test -s conftest.$ac_objext; then
25128   ac_lo=$ac_mid; break
25129 else
25130   $as_echo "$as_me: failed program was:" >&5
25131 sed 's/^/| /' conftest.$ac_ext >&5
25132
25133         ac_hi=`expr '(' $ac_mid ')' - 1`
25134                         if test $ac_mid -le $ac_hi; then
25135                           ac_lo= ac_hi=
25136                           break
25137                         fi
25138                         ac_mid=`expr 2 '*' $ac_mid`
25139 fi
25140
25141 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25142   done
25143 else
25144   $as_echo "$as_me: failed program was:" >&5
25145 sed 's/^/| /' conftest.$ac_ext >&5
25146
25147         ac_lo= ac_hi=
25148 fi
25149
25150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25151 fi
25152
25153 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25154 # Binary search between lo and hi bounds.
25155 while test "x$ac_lo" != "x$ac_hi"; do
25156   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25157   cat >conftest.$ac_ext <<_ACEOF
25158 /* confdefs.h.  */
25159 _ACEOF
25160 cat confdefs.h >>conftest.$ac_ext
25161 cat >>conftest.$ac_ext <<_ACEOF
25162 /* end confdefs.h.  */
25163 $ac_includes_default
25164 int
25165 main ()
25166 {
25167 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
25168 test_array [0] = 0
25169
25170   ;
25171   return 0;
25172 }
25173 _ACEOF
25174 rm -f conftest.$ac_objext
25175 if { (ac_try="$ac_compile"
25176 case "(($ac_try" in
25177   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25178   *) ac_try_echo=$ac_try;;
25179 esac
25180 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25181 $as_echo "$ac_try_echo") >&5
25182   (eval "$ac_compile") 2>conftest.er1
25183   ac_status=$?
25184   grep -v '^ *+' conftest.er1 >conftest.err
25185   rm -f conftest.er1
25186   cat conftest.err >&5
25187   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25188   (exit $ac_status); } && {
25189          test -z "$ac_c_werror_flag" ||
25190          test ! -s conftest.err
25191        } && test -s conftest.$ac_objext; then
25192   ac_hi=$ac_mid
25193 else
25194   $as_echo "$as_me: failed program was:" >&5
25195 sed 's/^/| /' conftest.$ac_ext >&5
25196
25197         ac_lo=`expr '(' $ac_mid ')' + 1`
25198 fi
25199
25200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25201 done
25202 case $ac_lo in
25203 ?*) ac_cv_sizeof_void_p=$ac_lo;;
25204 '') if test "$ac_cv_type_void_p" = yes; then
25205      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25206 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25207 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
25208 See \`config.log' for more details." >&5
25209 $as_echo "$as_me: error: cannot compute sizeof (void *)
25210 See \`config.log' for more details." >&2;}
25211    { (exit 77); exit 77; }; }; }
25212    else
25213      ac_cv_sizeof_void_p=0
25214    fi ;;
25215 esac
25216 else
25217   cat >conftest.$ac_ext <<_ACEOF
25218 /* confdefs.h.  */
25219 _ACEOF
25220 cat confdefs.h >>conftest.$ac_ext
25221 cat >>conftest.$ac_ext <<_ACEOF
25222 /* end confdefs.h.  */
25223 $ac_includes_default
25224 static long int longval () { return (long int) (sizeof (void *)); }
25225 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
25226 #include <stdio.h>
25227 #include <stdlib.h>
25228 int
25229 main ()
25230 {
25231
25232   FILE *f = fopen ("conftest.val", "w");
25233   if (! f)
25234     return 1;
25235   if (((long int) (sizeof (void *))) < 0)
25236     {
25237       long int i = longval ();
25238       if (i != ((long int) (sizeof (void *))))
25239         return 1;
25240       fprintf (f, "%ld", i);
25241     }
25242   else
25243     {
25244       unsigned long int i = ulongval ();
25245       if (i != ((long int) (sizeof (void *))))
25246         return 1;
25247       fprintf (f, "%lu", i);
25248     }
25249   /* Do not output a trailing newline, as this causes \r\n confusion
25250      on some platforms.  */
25251   return ferror (f) || fclose (f) != 0;
25252
25253   ;
25254   return 0;
25255 }
25256 _ACEOF
25257 rm -f conftest$ac_exeext
25258 if { (ac_try="$ac_link"
25259 case "(($ac_try" in
25260   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25261   *) ac_try_echo=$ac_try;;
25262 esac
25263 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25264 $as_echo "$ac_try_echo") >&5
25265   (eval "$ac_link") 2>&5
25266   ac_status=$?
25267   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25268   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25269   { (case "(($ac_try" in
25270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25271   *) ac_try_echo=$ac_try;;
25272 esac
25273 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25274 $as_echo "$ac_try_echo") >&5
25275   (eval "$ac_try") 2>&5
25276   ac_status=$?
25277   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25278   (exit $ac_status); }; }; then
25279   ac_cv_sizeof_void_p=`cat conftest.val`
25280 else
25281   $as_echo "$as_me: program exited with status $ac_status" >&5
25282 $as_echo "$as_me: failed program was:" >&5
25283 sed 's/^/| /' conftest.$ac_ext >&5
25284
25285 ( exit $ac_status )
25286 if test "$ac_cv_type_void_p" = yes; then
25287      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25288 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25289 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
25290 See \`config.log' for more details." >&5
25291 $as_echo "$as_me: error: cannot compute sizeof (void *)
25292 See \`config.log' for more details." >&2;}
25293    { (exit 77); exit 77; }; }; }
25294    else
25295      ac_cv_sizeof_void_p=0
25296    fi
25297 fi
25298 rm -rf conftest.dSYM
25299 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25300 fi
25301 rm -f conftest.val
25302 fi
25303 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
25304 $as_echo "$ac_cv_sizeof_void_p" >&6; }
25305
25306
25307
25308 cat >>confdefs.h <<_ACEOF
25309 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
25310 _ACEOF
25311
25312
25313 # The cast to long int works around a bug in the HP C Compiler
25314 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
25315 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
25316 # This bug is HP SR number 8606223364.
25317 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
25318 $as_echo_n "checking size of size_t... " >&6; }
25319 if test "${ac_cv_sizeof_size_t+set}" = set; then
25320   $as_echo_n "(cached) " >&6
25321 else
25322   if test "$cross_compiling" = yes; then
25323   # Depending upon the size, compute the lo and hi bounds.
25324 cat >conftest.$ac_ext <<_ACEOF
25325 /* confdefs.h.  */
25326 _ACEOF
25327 cat confdefs.h >>conftest.$ac_ext
25328 cat >>conftest.$ac_ext <<_ACEOF
25329 /* end confdefs.h.  */
25330 $ac_includes_default
25331 int
25332 main ()
25333 {
25334 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
25335 test_array [0] = 0
25336
25337   ;
25338   return 0;
25339 }
25340 _ACEOF
25341 rm -f conftest.$ac_objext
25342 if { (ac_try="$ac_compile"
25343 case "(($ac_try" in
25344   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25345   *) ac_try_echo=$ac_try;;
25346 esac
25347 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25348 $as_echo "$ac_try_echo") >&5
25349   (eval "$ac_compile") 2>conftest.er1
25350   ac_status=$?
25351   grep -v '^ *+' conftest.er1 >conftest.err
25352   rm -f conftest.er1
25353   cat conftest.err >&5
25354   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25355   (exit $ac_status); } && {
25356          test -z "$ac_c_werror_flag" ||
25357          test ! -s conftest.err
25358        } && test -s conftest.$ac_objext; then
25359   ac_lo=0 ac_mid=0
25360   while :; do
25361     cat >conftest.$ac_ext <<_ACEOF
25362 /* confdefs.h.  */
25363 _ACEOF
25364 cat confdefs.h >>conftest.$ac_ext
25365 cat >>conftest.$ac_ext <<_ACEOF
25366 /* end confdefs.h.  */
25367 $ac_includes_default
25368 int
25369 main ()
25370 {
25371 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
25372 test_array [0] = 0
25373
25374   ;
25375   return 0;
25376 }
25377 _ACEOF
25378 rm -f conftest.$ac_objext
25379 if { (ac_try="$ac_compile"
25380 case "(($ac_try" in
25381   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25382   *) ac_try_echo=$ac_try;;
25383 esac
25384 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25385 $as_echo "$ac_try_echo") >&5
25386   (eval "$ac_compile") 2>conftest.er1
25387   ac_status=$?
25388   grep -v '^ *+' conftest.er1 >conftest.err
25389   rm -f conftest.er1
25390   cat conftest.err >&5
25391   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25392   (exit $ac_status); } && {
25393          test -z "$ac_c_werror_flag" ||
25394          test ! -s conftest.err
25395        } && test -s conftest.$ac_objext; then
25396   ac_hi=$ac_mid; break
25397 else
25398   $as_echo "$as_me: failed program was:" >&5
25399 sed 's/^/| /' conftest.$ac_ext >&5
25400
25401         ac_lo=`expr $ac_mid + 1`
25402                         if test $ac_lo -le $ac_mid; then
25403                           ac_lo= ac_hi=
25404                           break
25405                         fi
25406                         ac_mid=`expr 2 '*' $ac_mid + 1`
25407 fi
25408
25409 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25410   done
25411 else
25412   $as_echo "$as_me: failed program was:" >&5
25413 sed 's/^/| /' conftest.$ac_ext >&5
25414
25415         cat >conftest.$ac_ext <<_ACEOF
25416 /* confdefs.h.  */
25417 _ACEOF
25418 cat confdefs.h >>conftest.$ac_ext
25419 cat >>conftest.$ac_ext <<_ACEOF
25420 /* end confdefs.h.  */
25421 $ac_includes_default
25422 int
25423 main ()
25424 {
25425 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
25426 test_array [0] = 0
25427
25428   ;
25429   return 0;
25430 }
25431 _ACEOF
25432 rm -f conftest.$ac_objext
25433 if { (ac_try="$ac_compile"
25434 case "(($ac_try" in
25435   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25436   *) ac_try_echo=$ac_try;;
25437 esac
25438 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25439 $as_echo "$ac_try_echo") >&5
25440   (eval "$ac_compile") 2>conftest.er1
25441   ac_status=$?
25442   grep -v '^ *+' conftest.er1 >conftest.err
25443   rm -f conftest.er1
25444   cat conftest.err >&5
25445   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25446   (exit $ac_status); } && {
25447          test -z "$ac_c_werror_flag" ||
25448          test ! -s conftest.err
25449        } && test -s conftest.$ac_objext; then
25450   ac_hi=-1 ac_mid=-1
25451   while :; do
25452     cat >conftest.$ac_ext <<_ACEOF
25453 /* confdefs.h.  */
25454 _ACEOF
25455 cat confdefs.h >>conftest.$ac_ext
25456 cat >>conftest.$ac_ext <<_ACEOF
25457 /* end confdefs.h.  */
25458 $ac_includes_default
25459 int
25460 main ()
25461 {
25462 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
25463 test_array [0] = 0
25464
25465   ;
25466   return 0;
25467 }
25468 _ACEOF
25469 rm -f conftest.$ac_objext
25470 if { (ac_try="$ac_compile"
25471 case "(($ac_try" in
25472   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25473   *) ac_try_echo=$ac_try;;
25474 esac
25475 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25476 $as_echo "$ac_try_echo") >&5
25477   (eval "$ac_compile") 2>conftest.er1
25478   ac_status=$?
25479   grep -v '^ *+' conftest.er1 >conftest.err
25480   rm -f conftest.er1
25481   cat conftest.err >&5
25482   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25483   (exit $ac_status); } && {
25484          test -z "$ac_c_werror_flag" ||
25485          test ! -s conftest.err
25486        } && test -s conftest.$ac_objext; then
25487   ac_lo=$ac_mid; break
25488 else
25489   $as_echo "$as_me: failed program was:" >&5
25490 sed 's/^/| /' conftest.$ac_ext >&5
25491
25492         ac_hi=`expr '(' $ac_mid ')' - 1`
25493                         if test $ac_mid -le $ac_hi; then
25494                           ac_lo= ac_hi=
25495                           break
25496                         fi
25497                         ac_mid=`expr 2 '*' $ac_mid`
25498 fi
25499
25500 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25501   done
25502 else
25503   $as_echo "$as_me: failed program was:" >&5
25504 sed 's/^/| /' conftest.$ac_ext >&5
25505
25506         ac_lo= ac_hi=
25507 fi
25508
25509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25510 fi
25511
25512 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25513 # Binary search between lo and hi bounds.
25514 while test "x$ac_lo" != "x$ac_hi"; do
25515   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25516   cat >conftest.$ac_ext <<_ACEOF
25517 /* confdefs.h.  */
25518 _ACEOF
25519 cat confdefs.h >>conftest.$ac_ext
25520 cat >>conftest.$ac_ext <<_ACEOF
25521 /* end confdefs.h.  */
25522 $ac_includes_default
25523 int
25524 main ()
25525 {
25526 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
25527 test_array [0] = 0
25528
25529   ;
25530   return 0;
25531 }
25532 _ACEOF
25533 rm -f conftest.$ac_objext
25534 if { (ac_try="$ac_compile"
25535 case "(($ac_try" in
25536   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25537   *) ac_try_echo=$ac_try;;
25538 esac
25539 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25540 $as_echo "$ac_try_echo") >&5
25541   (eval "$ac_compile") 2>conftest.er1
25542   ac_status=$?
25543   grep -v '^ *+' conftest.er1 >conftest.err
25544   rm -f conftest.er1
25545   cat conftest.err >&5
25546   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25547   (exit $ac_status); } && {
25548          test -z "$ac_c_werror_flag" ||
25549          test ! -s conftest.err
25550        } && test -s conftest.$ac_objext; then
25551   ac_hi=$ac_mid
25552 else
25553   $as_echo "$as_me: failed program was:" >&5
25554 sed 's/^/| /' conftest.$ac_ext >&5
25555
25556         ac_lo=`expr '(' $ac_mid ')' + 1`
25557 fi
25558
25559 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25560 done
25561 case $ac_lo in
25562 ?*) ac_cv_sizeof_size_t=$ac_lo;;
25563 '') if test "$ac_cv_type_size_t" = yes; then
25564      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25565 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25566 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
25567 See \`config.log' for more details." >&5
25568 $as_echo "$as_me: error: cannot compute sizeof (size_t)
25569 See \`config.log' for more details." >&2;}
25570    { (exit 77); exit 77; }; }; }
25571    else
25572      ac_cv_sizeof_size_t=0
25573    fi ;;
25574 esac
25575 else
25576   cat >conftest.$ac_ext <<_ACEOF
25577 /* confdefs.h.  */
25578 _ACEOF
25579 cat confdefs.h >>conftest.$ac_ext
25580 cat >>conftest.$ac_ext <<_ACEOF
25581 /* end confdefs.h.  */
25582 $ac_includes_default
25583 static long int longval () { return (long int) (sizeof (size_t)); }
25584 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
25585 #include <stdio.h>
25586 #include <stdlib.h>
25587 int
25588 main ()
25589 {
25590
25591   FILE *f = fopen ("conftest.val", "w");
25592   if (! f)
25593     return 1;
25594   if (((long int) (sizeof (size_t))) < 0)
25595     {
25596       long int i = longval ();
25597       if (i != ((long int) (sizeof (size_t))))
25598         return 1;
25599       fprintf (f, "%ld", i);
25600     }
25601   else
25602     {
25603       unsigned long int i = ulongval ();
25604       if (i != ((long int) (sizeof (size_t))))
25605         return 1;
25606       fprintf (f, "%lu", i);
25607     }
25608   /* Do not output a trailing newline, as this causes \r\n confusion
25609      on some platforms.  */
25610   return ferror (f) || fclose (f) != 0;
25611
25612   ;
25613   return 0;
25614 }
25615 _ACEOF
25616 rm -f conftest$ac_exeext
25617 if { (ac_try="$ac_link"
25618 case "(($ac_try" in
25619   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25620   *) ac_try_echo=$ac_try;;
25621 esac
25622 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25623 $as_echo "$ac_try_echo") >&5
25624   (eval "$ac_link") 2>&5
25625   ac_status=$?
25626   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25627   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25628   { (case "(($ac_try" in
25629   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25630   *) ac_try_echo=$ac_try;;
25631 esac
25632 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25633 $as_echo "$ac_try_echo") >&5
25634   (eval "$ac_try") 2>&5
25635   ac_status=$?
25636   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25637   (exit $ac_status); }; }; then
25638   ac_cv_sizeof_size_t=`cat conftest.val`
25639 else
25640   $as_echo "$as_me: program exited with status $ac_status" >&5
25641 $as_echo "$as_me: failed program was:" >&5
25642 sed 's/^/| /' conftest.$ac_ext >&5
25643
25644 ( exit $ac_status )
25645 if test "$ac_cv_type_size_t" = yes; then
25646      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25647 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25648 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
25649 See \`config.log' for more details." >&5
25650 $as_echo "$as_me: error: cannot compute sizeof (size_t)
25651 See \`config.log' for more details." >&2;}
25652    { (exit 77); exit 77; }; }; }
25653    else
25654      ac_cv_sizeof_size_t=0
25655    fi
25656 fi
25657 rm -rf conftest.dSYM
25658 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25659 fi
25660 rm -f conftest.val
25661 fi
25662 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
25663 $as_echo "$ac_cv_sizeof_size_t" >&6; }
25664
25665
25666
25667 cat >>confdefs.h <<_ACEOF
25668 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
25669 _ACEOF
25670
25671
25672 # The cast to long int works around a bug in the HP C Compiler
25673 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
25674 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
25675 # This bug is HP SR number 8606223364.
25676 { $as_echo "$as_me:$LINENO: checking size of long" >&5
25677 $as_echo_n "checking size of long... " >&6; }
25678 if test "${ac_cv_sizeof_long+set}" = set; then
25679   $as_echo_n "(cached) " >&6
25680 else
25681   if test "$cross_compiling" = yes; then
25682   # Depending upon the size, compute the lo and hi bounds.
25683 cat >conftest.$ac_ext <<_ACEOF
25684 /* confdefs.h.  */
25685 _ACEOF
25686 cat confdefs.h >>conftest.$ac_ext
25687 cat >>conftest.$ac_ext <<_ACEOF
25688 /* end confdefs.h.  */
25689 $ac_includes_default
25690 int
25691 main ()
25692 {
25693 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
25694 test_array [0] = 0
25695
25696   ;
25697   return 0;
25698 }
25699 _ACEOF
25700 rm -f conftest.$ac_objext
25701 if { (ac_try="$ac_compile"
25702 case "(($ac_try" in
25703   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25704   *) ac_try_echo=$ac_try;;
25705 esac
25706 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25707 $as_echo "$ac_try_echo") >&5
25708   (eval "$ac_compile") 2>conftest.er1
25709   ac_status=$?
25710   grep -v '^ *+' conftest.er1 >conftest.err
25711   rm -f conftest.er1
25712   cat conftest.err >&5
25713   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25714   (exit $ac_status); } && {
25715          test -z "$ac_c_werror_flag" ||
25716          test ! -s conftest.err
25717        } && test -s conftest.$ac_objext; then
25718   ac_lo=0 ac_mid=0
25719   while :; do
25720     cat >conftest.$ac_ext <<_ACEOF
25721 /* confdefs.h.  */
25722 _ACEOF
25723 cat confdefs.h >>conftest.$ac_ext
25724 cat >>conftest.$ac_ext <<_ACEOF
25725 /* end confdefs.h.  */
25726 $ac_includes_default
25727 int
25728 main ()
25729 {
25730 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25731 test_array [0] = 0
25732
25733   ;
25734   return 0;
25735 }
25736 _ACEOF
25737 rm -f conftest.$ac_objext
25738 if { (ac_try="$ac_compile"
25739 case "(($ac_try" in
25740   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25741   *) ac_try_echo=$ac_try;;
25742 esac
25743 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25744 $as_echo "$ac_try_echo") >&5
25745   (eval "$ac_compile") 2>conftest.er1
25746   ac_status=$?
25747   grep -v '^ *+' conftest.er1 >conftest.err
25748   rm -f conftest.er1
25749   cat conftest.err >&5
25750   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25751   (exit $ac_status); } && {
25752          test -z "$ac_c_werror_flag" ||
25753          test ! -s conftest.err
25754        } && test -s conftest.$ac_objext; then
25755   ac_hi=$ac_mid; break
25756 else
25757   $as_echo "$as_me: failed program was:" >&5
25758 sed 's/^/| /' conftest.$ac_ext >&5
25759
25760         ac_lo=`expr $ac_mid + 1`
25761                         if test $ac_lo -le $ac_mid; then
25762                           ac_lo= ac_hi=
25763                           break
25764                         fi
25765                         ac_mid=`expr 2 '*' $ac_mid + 1`
25766 fi
25767
25768 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25769   done
25770 else
25771   $as_echo "$as_me: failed program was:" >&5
25772 sed 's/^/| /' conftest.$ac_ext >&5
25773
25774         cat >conftest.$ac_ext <<_ACEOF
25775 /* confdefs.h.  */
25776 _ACEOF
25777 cat confdefs.h >>conftest.$ac_ext
25778 cat >>conftest.$ac_ext <<_ACEOF
25779 /* end confdefs.h.  */
25780 $ac_includes_default
25781 int
25782 main ()
25783 {
25784 static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
25785 test_array [0] = 0
25786
25787   ;
25788   return 0;
25789 }
25790 _ACEOF
25791 rm -f conftest.$ac_objext
25792 if { (ac_try="$ac_compile"
25793 case "(($ac_try" in
25794   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25795   *) ac_try_echo=$ac_try;;
25796 esac
25797 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25798 $as_echo "$ac_try_echo") >&5
25799   (eval "$ac_compile") 2>conftest.er1
25800   ac_status=$?
25801   grep -v '^ *+' conftest.er1 >conftest.err
25802   rm -f conftest.er1
25803   cat conftest.err >&5
25804   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25805   (exit $ac_status); } && {
25806          test -z "$ac_c_werror_flag" ||
25807          test ! -s conftest.err
25808        } && test -s conftest.$ac_objext; then
25809   ac_hi=-1 ac_mid=-1
25810   while :; do
25811     cat >conftest.$ac_ext <<_ACEOF
25812 /* confdefs.h.  */
25813 _ACEOF
25814 cat confdefs.h >>conftest.$ac_ext
25815 cat >>conftest.$ac_ext <<_ACEOF
25816 /* end confdefs.h.  */
25817 $ac_includes_default
25818 int
25819 main ()
25820 {
25821 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
25822 test_array [0] = 0
25823
25824   ;
25825   return 0;
25826 }
25827 _ACEOF
25828 rm -f conftest.$ac_objext
25829 if { (ac_try="$ac_compile"
25830 case "(($ac_try" in
25831   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25832   *) ac_try_echo=$ac_try;;
25833 esac
25834 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25835 $as_echo "$ac_try_echo") >&5
25836   (eval "$ac_compile") 2>conftest.er1
25837   ac_status=$?
25838   grep -v '^ *+' conftest.er1 >conftest.err
25839   rm -f conftest.er1
25840   cat conftest.err >&5
25841   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25842   (exit $ac_status); } && {
25843          test -z "$ac_c_werror_flag" ||
25844          test ! -s conftest.err
25845        } && test -s conftest.$ac_objext; then
25846   ac_lo=$ac_mid; break
25847 else
25848   $as_echo "$as_me: failed program was:" >&5
25849 sed 's/^/| /' conftest.$ac_ext >&5
25850
25851         ac_hi=`expr '(' $ac_mid ')' - 1`
25852                         if test $ac_mid -le $ac_hi; then
25853                           ac_lo= ac_hi=
25854                           break
25855                         fi
25856                         ac_mid=`expr 2 '*' $ac_mid`
25857 fi
25858
25859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25860   done
25861 else
25862   $as_echo "$as_me: failed program was:" >&5
25863 sed 's/^/| /' conftest.$ac_ext >&5
25864
25865         ac_lo= ac_hi=
25866 fi
25867
25868 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25869 fi
25870
25871 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25872 # Binary search between lo and hi bounds.
25873 while test "x$ac_lo" != "x$ac_hi"; do
25874   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25875   cat >conftest.$ac_ext <<_ACEOF
25876 /* confdefs.h.  */
25877 _ACEOF
25878 cat confdefs.h >>conftest.$ac_ext
25879 cat >>conftest.$ac_ext <<_ACEOF
25880 /* end confdefs.h.  */
25881 $ac_includes_default
25882 int
25883 main ()
25884 {
25885 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25886 test_array [0] = 0
25887
25888   ;
25889   return 0;
25890 }
25891 _ACEOF
25892 rm -f conftest.$ac_objext
25893 if { (ac_try="$ac_compile"
25894 case "(($ac_try" in
25895   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25896   *) ac_try_echo=$ac_try;;
25897 esac
25898 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25899 $as_echo "$ac_try_echo") >&5
25900   (eval "$ac_compile") 2>conftest.er1
25901   ac_status=$?
25902   grep -v '^ *+' conftest.er1 >conftest.err
25903   rm -f conftest.er1
25904   cat conftest.err >&5
25905   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25906   (exit $ac_status); } && {
25907          test -z "$ac_c_werror_flag" ||
25908          test ! -s conftest.err
25909        } && test -s conftest.$ac_objext; then
25910   ac_hi=$ac_mid
25911 else
25912   $as_echo "$as_me: failed program was:" >&5
25913 sed 's/^/| /' conftest.$ac_ext >&5
25914
25915         ac_lo=`expr '(' $ac_mid ')' + 1`
25916 fi
25917
25918 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25919 done
25920 case $ac_lo in
25921 ?*) ac_cv_sizeof_long=$ac_lo;;
25922 '') if test "$ac_cv_type_long" = yes; then
25923      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25924 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25925 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25926 See \`config.log' for more details." >&5
25927 $as_echo "$as_me: error: cannot compute sizeof (long)
25928 See \`config.log' for more details." >&2;}
25929    { (exit 77); exit 77; }; }; }
25930    else
25931      ac_cv_sizeof_long=0
25932    fi ;;
25933 esac
25934 else
25935   cat >conftest.$ac_ext <<_ACEOF
25936 /* confdefs.h.  */
25937 _ACEOF
25938 cat confdefs.h >>conftest.$ac_ext
25939 cat >>conftest.$ac_ext <<_ACEOF
25940 /* end confdefs.h.  */
25941 $ac_includes_default
25942 static long int longval () { return (long int) (sizeof (long)); }
25943 static unsigned long int ulongval () { return (long int) (sizeof (long)); }
25944 #include <stdio.h>
25945 #include <stdlib.h>
25946 int
25947 main ()
25948 {
25949
25950   FILE *f = fopen ("conftest.val", "w");
25951   if (! f)
25952     return 1;
25953   if (((long int) (sizeof (long))) < 0)
25954     {
25955       long int i = longval ();
25956       if (i != ((long int) (sizeof (long))))
25957         return 1;
25958       fprintf (f, "%ld", i);
25959     }
25960   else
25961     {
25962       unsigned long int i = ulongval ();
25963       if (i != ((long int) (sizeof (long))))
25964         return 1;
25965       fprintf (f, "%lu", i);
25966     }
25967   /* Do not output a trailing newline, as this causes \r\n confusion
25968      on some platforms.  */
25969   return ferror (f) || fclose (f) != 0;
25970
25971   ;
25972   return 0;
25973 }
25974 _ACEOF
25975 rm -f conftest$ac_exeext
25976 if { (ac_try="$ac_link"
25977 case "(($ac_try" in
25978   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25979   *) ac_try_echo=$ac_try;;
25980 esac
25981 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25982 $as_echo "$ac_try_echo") >&5
25983   (eval "$ac_link") 2>&5
25984   ac_status=$?
25985   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25986   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25987   { (case "(($ac_try" in
25988   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25989   *) ac_try_echo=$ac_try;;
25990 esac
25991 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25992 $as_echo "$ac_try_echo") >&5
25993   (eval "$ac_try") 2>&5
25994   ac_status=$?
25995   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25996   (exit $ac_status); }; }; then
25997   ac_cv_sizeof_long=`cat conftest.val`
25998 else
25999   $as_echo "$as_me: program exited with status $ac_status" >&5
26000 $as_echo "$as_me: failed program was:" >&5
26001 sed 's/^/| /' conftest.$ac_ext >&5
26002
26003 ( exit $ac_status )
26004 if test "$ac_cv_type_long" = yes; then
26005      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26006 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26007 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
26008 See \`config.log' for more details." >&5
26009 $as_echo "$as_me: error: cannot compute sizeof (long)
26010 See \`config.log' for more details." >&2;}
26011    { (exit 77); exit 77; }; }; }
26012    else
26013      ac_cv_sizeof_long=0
26014    fi
26015 fi
26016 rm -rf conftest.dSYM
26017 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26018 fi
26019 rm -f conftest.val
26020 fi
26021 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
26022 $as_echo "$ac_cv_sizeof_long" >&6; }
26023
26024
26025
26026 cat >>confdefs.h <<_ACEOF
26027 #define SIZEOF_LONG $ac_cv_sizeof_long
26028 _ACEOF
26029
26030
26031
26032 # Decide whether float4 is passed by value: user-selectable, enabled by default
26033 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
26034 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
26035
26036
26037 # Check whether --enable-float4-byval was given.
26038 if test "${enable_float4_byval+set}" = set; then
26039   enableval=$enable_float4_byval;
26040   case $enableval in
26041     yes)
26042
26043 cat >>confdefs.h <<\_ACEOF
26044 #define USE_FLOAT4_BYVAL 1
26045 _ACEOF
26046
26047                float4passbyval=true
26048       ;;
26049     no)
26050       float4passbyval=false
26051       ;;
26052     *)
26053       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
26054 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
26055    { (exit 1); exit 1; }; }
26056       ;;
26057   esac
26058
26059 else
26060   enable_float4_byval=yes
26061
26062 cat >>confdefs.h <<\_ACEOF
26063 #define USE_FLOAT4_BYVAL 1
26064 _ACEOF
26065
26066                float4passbyval=true
26067 fi
26068
26069
26070 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
26071 $as_echo "$enable_float4_byval" >&6; }
26072
26073 cat >>confdefs.h <<_ACEOF
26074 #define FLOAT4PASSBYVAL $float4passbyval
26075 _ACEOF
26076
26077
26078 # Decide whether float8 is passed by value.
26079 # Note: this setting also controls int8 and related types such as timestamp.
26080 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
26081 # If not, trying to select it is an error.
26082 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
26083 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
26084 if test $ac_cv_sizeof_void_p -ge 8 ; then
26085
26086
26087 # Check whether --enable-float8-byval was given.
26088 if test "${enable_float8_byval+set}" = set; then
26089   enableval=$enable_float8_byval;
26090   case $enableval in
26091     yes)
26092       :
26093       ;;
26094     no)
26095       :
26096       ;;
26097     *)
26098       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
26099 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
26100    { (exit 1); exit 1; }; }
26101       ;;
26102   esac
26103
26104 else
26105   enable_float8_byval=yes
26106
26107 fi
26108
26109
26110 else
26111
26112
26113 # Check whether --enable-float8-byval was given.
26114 if test "${enable_float8_byval+set}" = set; then
26115   enableval=$enable_float8_byval;
26116   case $enableval in
26117     yes)
26118       :
26119       ;;
26120     no)
26121       :
26122       ;;
26123     *)
26124       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
26125 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
26126    { (exit 1); exit 1; }; }
26127       ;;
26128   esac
26129
26130 else
26131   enable_float8_byval=no
26132
26133 fi
26134
26135
26136   if test "$enable_float8_byval" = yes ; then
26137     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
26138 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
26139    { (exit 1); exit 1; }; }
26140   fi
26141 fi
26142 if test "$enable_float8_byval" = yes ; then
26143
26144 cat >>confdefs.h <<\_ACEOF
26145 #define USE_FLOAT8_BYVAL 1
26146 _ACEOF
26147
26148   float8passbyval=true
26149 else
26150   float8passbyval=false
26151 fi
26152 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
26153 $as_echo "$enable_float8_byval" >&6; }
26154
26155 cat >>confdefs.h <<_ACEOF
26156 #define FLOAT8PASSBYVAL $float8passbyval
26157 _ACEOF
26158
26159
26160 # Determine memory alignment requirements for the basic C data types.
26161
26162 # The cast to long int works around a bug in the HP C Compiler,
26163 # see AC_CHECK_SIZEOF for more information.
26164 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
26165 $as_echo_n "checking alignment of short... " >&6; }
26166 if test "${ac_cv_alignof_short+set}" = set; then
26167   $as_echo_n "(cached) " >&6
26168 else
26169   if test "$cross_compiling" = yes; then
26170   # Depending upon the size, compute the lo and hi bounds.
26171 cat >conftest.$ac_ext <<_ACEOF
26172 /* confdefs.h.  */
26173 _ACEOF
26174 cat confdefs.h >>conftest.$ac_ext
26175 cat >>conftest.$ac_ext <<_ACEOF
26176 /* end confdefs.h.  */
26177 $ac_includes_default
26178 #ifndef offsetof
26179 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26180 #endif
26181 typedef struct { char x; short y; } ac__type_alignof_;
26182 int
26183 main ()
26184 {
26185 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26186 test_array [0] = 0
26187
26188   ;
26189   return 0;
26190 }
26191 _ACEOF
26192 rm -f conftest.$ac_objext
26193 if { (ac_try="$ac_compile"
26194 case "(($ac_try" in
26195   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26196   *) ac_try_echo=$ac_try;;
26197 esac
26198 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26199 $as_echo "$ac_try_echo") >&5
26200   (eval "$ac_compile") 2>conftest.er1
26201   ac_status=$?
26202   grep -v '^ *+' conftest.er1 >conftest.err
26203   rm -f conftest.er1
26204   cat conftest.err >&5
26205   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26206   (exit $ac_status); } && {
26207          test -z "$ac_c_werror_flag" ||
26208          test ! -s conftest.err
26209        } && test -s conftest.$ac_objext; then
26210   ac_lo=0 ac_mid=0
26211   while :; do
26212     cat >conftest.$ac_ext <<_ACEOF
26213 /* confdefs.h.  */
26214 _ACEOF
26215 cat confdefs.h >>conftest.$ac_ext
26216 cat >>conftest.$ac_ext <<_ACEOF
26217 /* end confdefs.h.  */
26218 $ac_includes_default
26219 #ifndef offsetof
26220 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26221 #endif
26222 typedef struct { char x; short y; } ac__type_alignof_;
26223 int
26224 main ()
26225 {
26226 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26227 test_array [0] = 0
26228
26229   ;
26230   return 0;
26231 }
26232 _ACEOF
26233 rm -f conftest.$ac_objext
26234 if { (ac_try="$ac_compile"
26235 case "(($ac_try" in
26236   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26237   *) ac_try_echo=$ac_try;;
26238 esac
26239 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26240 $as_echo "$ac_try_echo") >&5
26241   (eval "$ac_compile") 2>conftest.er1
26242   ac_status=$?
26243   grep -v '^ *+' conftest.er1 >conftest.err
26244   rm -f conftest.er1
26245   cat conftest.err >&5
26246   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26247   (exit $ac_status); } && {
26248          test -z "$ac_c_werror_flag" ||
26249          test ! -s conftest.err
26250        } && test -s conftest.$ac_objext; then
26251   ac_hi=$ac_mid; break
26252 else
26253   $as_echo "$as_me: failed program was:" >&5
26254 sed 's/^/| /' conftest.$ac_ext >&5
26255
26256         ac_lo=`expr $ac_mid + 1`
26257                         if test $ac_lo -le $ac_mid; then
26258                           ac_lo= ac_hi=
26259                           break
26260                         fi
26261                         ac_mid=`expr 2 '*' $ac_mid + 1`
26262 fi
26263
26264 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26265   done
26266 else
26267   $as_echo "$as_me: failed program was:" >&5
26268 sed 's/^/| /' conftest.$ac_ext >&5
26269
26270         cat >conftest.$ac_ext <<_ACEOF
26271 /* confdefs.h.  */
26272 _ACEOF
26273 cat confdefs.h >>conftest.$ac_ext
26274 cat >>conftest.$ac_ext <<_ACEOF
26275 /* end confdefs.h.  */
26276 $ac_includes_default
26277 #ifndef offsetof
26278 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26279 #endif
26280 typedef struct { char x; short y; } ac__type_alignof_;
26281 int
26282 main ()
26283 {
26284 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26285 test_array [0] = 0
26286
26287   ;
26288   return 0;
26289 }
26290 _ACEOF
26291 rm -f conftest.$ac_objext
26292 if { (ac_try="$ac_compile"
26293 case "(($ac_try" in
26294   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26295   *) ac_try_echo=$ac_try;;
26296 esac
26297 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26298 $as_echo "$ac_try_echo") >&5
26299   (eval "$ac_compile") 2>conftest.er1
26300   ac_status=$?
26301   grep -v '^ *+' conftest.er1 >conftest.err
26302   rm -f conftest.er1
26303   cat conftest.err >&5
26304   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26305   (exit $ac_status); } && {
26306          test -z "$ac_c_werror_flag" ||
26307          test ! -s conftest.err
26308        } && test -s conftest.$ac_objext; then
26309   ac_hi=-1 ac_mid=-1
26310   while :; do
26311     cat >conftest.$ac_ext <<_ACEOF
26312 /* confdefs.h.  */
26313 _ACEOF
26314 cat confdefs.h >>conftest.$ac_ext
26315 cat >>conftest.$ac_ext <<_ACEOF
26316 /* end confdefs.h.  */
26317 $ac_includes_default
26318 #ifndef offsetof
26319 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26320 #endif
26321 typedef struct { char x; short y; } ac__type_alignof_;
26322 int
26323 main ()
26324 {
26325 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26326 test_array [0] = 0
26327
26328   ;
26329   return 0;
26330 }
26331 _ACEOF
26332 rm -f conftest.$ac_objext
26333 if { (ac_try="$ac_compile"
26334 case "(($ac_try" in
26335   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26336   *) ac_try_echo=$ac_try;;
26337 esac
26338 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26339 $as_echo "$ac_try_echo") >&5
26340   (eval "$ac_compile") 2>conftest.er1
26341   ac_status=$?
26342   grep -v '^ *+' conftest.er1 >conftest.err
26343   rm -f conftest.er1
26344   cat conftest.err >&5
26345   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26346   (exit $ac_status); } && {
26347          test -z "$ac_c_werror_flag" ||
26348          test ! -s conftest.err
26349        } && test -s conftest.$ac_objext; then
26350   ac_lo=$ac_mid; break
26351 else
26352   $as_echo "$as_me: failed program was:" >&5
26353 sed 's/^/| /' conftest.$ac_ext >&5
26354
26355         ac_hi=`expr '(' $ac_mid ')' - 1`
26356                         if test $ac_mid -le $ac_hi; then
26357                           ac_lo= ac_hi=
26358                           break
26359                         fi
26360                         ac_mid=`expr 2 '*' $ac_mid`
26361 fi
26362
26363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26364   done
26365 else
26366   $as_echo "$as_me: failed program was:" >&5
26367 sed 's/^/| /' conftest.$ac_ext >&5
26368
26369         ac_lo= ac_hi=
26370 fi
26371
26372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26373 fi
26374
26375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26376 # Binary search between lo and hi bounds.
26377 while test "x$ac_lo" != "x$ac_hi"; do
26378   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26379   cat >conftest.$ac_ext <<_ACEOF
26380 /* confdefs.h.  */
26381 _ACEOF
26382 cat confdefs.h >>conftest.$ac_ext
26383 cat >>conftest.$ac_ext <<_ACEOF
26384 /* end confdefs.h.  */
26385 $ac_includes_default
26386 #ifndef offsetof
26387 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26388 #endif
26389 typedef struct { char x; short y; } ac__type_alignof_;
26390 int
26391 main ()
26392 {
26393 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26394 test_array [0] = 0
26395
26396   ;
26397   return 0;
26398 }
26399 _ACEOF
26400 rm -f conftest.$ac_objext
26401 if { (ac_try="$ac_compile"
26402 case "(($ac_try" in
26403   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26404   *) ac_try_echo=$ac_try;;
26405 esac
26406 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26407 $as_echo "$ac_try_echo") >&5
26408   (eval "$ac_compile") 2>conftest.er1
26409   ac_status=$?
26410   grep -v '^ *+' conftest.er1 >conftest.err
26411   rm -f conftest.er1
26412   cat conftest.err >&5
26413   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26414   (exit $ac_status); } && {
26415          test -z "$ac_c_werror_flag" ||
26416          test ! -s conftest.err
26417        } && test -s conftest.$ac_objext; then
26418   ac_hi=$ac_mid
26419 else
26420   $as_echo "$as_me: failed program was:" >&5
26421 sed 's/^/| /' conftest.$ac_ext >&5
26422
26423         ac_lo=`expr '(' $ac_mid ')' + 1`
26424 fi
26425
26426 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26427 done
26428 case $ac_lo in
26429 ?*) ac_cv_alignof_short=$ac_lo;;
26430 '') if test "$ac_cv_type_short" = yes; then
26431      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26432 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26433 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
26434 See \`config.log' for more details." >&5
26435 $as_echo "$as_me: error: cannot compute alignment of short
26436 See \`config.log' for more details." >&2;}
26437    { (exit 77); exit 77; }; }; }
26438    else
26439      ac_cv_alignof_short=0
26440    fi ;;
26441 esac
26442 else
26443   cat >conftest.$ac_ext <<_ACEOF
26444 /* confdefs.h.  */
26445 _ACEOF
26446 cat confdefs.h >>conftest.$ac_ext
26447 cat >>conftest.$ac_ext <<_ACEOF
26448 /* end confdefs.h.  */
26449 $ac_includes_default
26450 #ifndef offsetof
26451 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26452 #endif
26453 typedef struct { char x; short y; } ac__type_alignof_;
26454 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26455 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26456 #include <stdio.h>
26457 #include <stdlib.h>
26458 int
26459 main ()
26460 {
26461
26462   FILE *f = fopen ("conftest.val", "w");
26463   if (! f)
26464     return 1;
26465   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26466     {
26467       long int i = longval ();
26468       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26469         return 1;
26470       fprintf (f, "%ld", i);
26471     }
26472   else
26473     {
26474       unsigned long int i = ulongval ();
26475       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26476         return 1;
26477       fprintf (f, "%lu", i);
26478     }
26479   /* Do not output a trailing newline, as this causes \r\n confusion
26480      on some platforms.  */
26481   return ferror (f) || fclose (f) != 0;
26482
26483   ;
26484   return 0;
26485 }
26486 _ACEOF
26487 rm -f conftest$ac_exeext
26488 if { (ac_try="$ac_link"
26489 case "(($ac_try" in
26490   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26491   *) ac_try_echo=$ac_try;;
26492 esac
26493 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26494 $as_echo "$ac_try_echo") >&5
26495   (eval "$ac_link") 2>&5
26496   ac_status=$?
26497   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26498   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26499   { (case "(($ac_try" in
26500   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26501   *) ac_try_echo=$ac_try;;
26502 esac
26503 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26504 $as_echo "$ac_try_echo") >&5
26505   (eval "$ac_try") 2>&5
26506   ac_status=$?
26507   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26508   (exit $ac_status); }; }; then
26509   ac_cv_alignof_short=`cat conftest.val`
26510 else
26511   $as_echo "$as_me: program exited with status $ac_status" >&5
26512 $as_echo "$as_me: failed program was:" >&5
26513 sed 's/^/| /' conftest.$ac_ext >&5
26514
26515 ( exit $ac_status )
26516 if test "$ac_cv_type_short" = yes; then
26517      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26518 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26519 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
26520 See \`config.log' for more details." >&5
26521 $as_echo "$as_me: error: cannot compute alignment of short
26522 See \`config.log' for more details." >&2;}
26523    { (exit 77); exit 77; }; }; }
26524    else
26525      ac_cv_alignof_short=0
26526    fi
26527 fi
26528 rm -rf conftest.dSYM
26529 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26530 fi
26531 rm -f conftest.val
26532 fi
26533 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
26534 $as_echo "$ac_cv_alignof_short" >&6; }
26535
26536
26537
26538 cat >>confdefs.h <<_ACEOF
26539 #define ALIGNOF_SHORT $ac_cv_alignof_short
26540 _ACEOF
26541
26542
26543 # The cast to long int works around a bug in the HP C Compiler,
26544 # see AC_CHECK_SIZEOF for more information.
26545 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
26546 $as_echo_n "checking alignment of int... " >&6; }
26547 if test "${ac_cv_alignof_int+set}" = set; then
26548   $as_echo_n "(cached) " >&6
26549 else
26550   if test "$cross_compiling" = yes; then
26551   # Depending upon the size, compute the lo and hi bounds.
26552 cat >conftest.$ac_ext <<_ACEOF
26553 /* confdefs.h.  */
26554 _ACEOF
26555 cat confdefs.h >>conftest.$ac_ext
26556 cat >>conftest.$ac_ext <<_ACEOF
26557 /* end confdefs.h.  */
26558 $ac_includes_default
26559 #ifndef offsetof
26560 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26561 #endif
26562 typedef struct { char x; int y; } ac__type_alignof_;
26563 int
26564 main ()
26565 {
26566 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26567 test_array [0] = 0
26568
26569   ;
26570   return 0;
26571 }
26572 _ACEOF
26573 rm -f conftest.$ac_objext
26574 if { (ac_try="$ac_compile"
26575 case "(($ac_try" in
26576   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26577   *) ac_try_echo=$ac_try;;
26578 esac
26579 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26580 $as_echo "$ac_try_echo") >&5
26581   (eval "$ac_compile") 2>conftest.er1
26582   ac_status=$?
26583   grep -v '^ *+' conftest.er1 >conftest.err
26584   rm -f conftest.er1
26585   cat conftest.err >&5
26586   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26587   (exit $ac_status); } && {
26588          test -z "$ac_c_werror_flag" ||
26589          test ! -s conftest.err
26590        } && test -s conftest.$ac_objext; then
26591   ac_lo=0 ac_mid=0
26592   while :; do
26593     cat >conftest.$ac_ext <<_ACEOF
26594 /* confdefs.h.  */
26595 _ACEOF
26596 cat confdefs.h >>conftest.$ac_ext
26597 cat >>conftest.$ac_ext <<_ACEOF
26598 /* end confdefs.h.  */
26599 $ac_includes_default
26600 #ifndef offsetof
26601 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26602 #endif
26603 typedef struct { char x; int y; } ac__type_alignof_;
26604 int
26605 main ()
26606 {
26607 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26608 test_array [0] = 0
26609
26610   ;
26611   return 0;
26612 }
26613 _ACEOF
26614 rm -f conftest.$ac_objext
26615 if { (ac_try="$ac_compile"
26616 case "(($ac_try" in
26617   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26618   *) ac_try_echo=$ac_try;;
26619 esac
26620 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26621 $as_echo "$ac_try_echo") >&5
26622   (eval "$ac_compile") 2>conftest.er1
26623   ac_status=$?
26624   grep -v '^ *+' conftest.er1 >conftest.err
26625   rm -f conftest.er1
26626   cat conftest.err >&5
26627   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26628   (exit $ac_status); } && {
26629          test -z "$ac_c_werror_flag" ||
26630          test ! -s conftest.err
26631        } && test -s conftest.$ac_objext; then
26632   ac_hi=$ac_mid; break
26633 else
26634   $as_echo "$as_me: failed program was:" >&5
26635 sed 's/^/| /' conftest.$ac_ext >&5
26636
26637         ac_lo=`expr $ac_mid + 1`
26638                         if test $ac_lo -le $ac_mid; then
26639                           ac_lo= ac_hi=
26640                           break
26641                         fi
26642                         ac_mid=`expr 2 '*' $ac_mid + 1`
26643 fi
26644
26645 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26646   done
26647 else
26648   $as_echo "$as_me: failed program was:" >&5
26649 sed 's/^/| /' conftest.$ac_ext >&5
26650
26651         cat >conftest.$ac_ext <<_ACEOF
26652 /* confdefs.h.  */
26653 _ACEOF
26654 cat confdefs.h >>conftest.$ac_ext
26655 cat >>conftest.$ac_ext <<_ACEOF
26656 /* end confdefs.h.  */
26657 $ac_includes_default
26658 #ifndef offsetof
26659 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26660 #endif
26661 typedef struct { char x; int y; } ac__type_alignof_;
26662 int
26663 main ()
26664 {
26665 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26666 test_array [0] = 0
26667
26668   ;
26669   return 0;
26670 }
26671 _ACEOF
26672 rm -f conftest.$ac_objext
26673 if { (ac_try="$ac_compile"
26674 case "(($ac_try" in
26675   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26676   *) ac_try_echo=$ac_try;;
26677 esac
26678 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26679 $as_echo "$ac_try_echo") >&5
26680   (eval "$ac_compile") 2>conftest.er1
26681   ac_status=$?
26682   grep -v '^ *+' conftest.er1 >conftest.err
26683   rm -f conftest.er1
26684   cat conftest.err >&5
26685   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26686   (exit $ac_status); } && {
26687          test -z "$ac_c_werror_flag" ||
26688          test ! -s conftest.err
26689        } && test -s conftest.$ac_objext; then
26690   ac_hi=-1 ac_mid=-1
26691   while :; do
26692     cat >conftest.$ac_ext <<_ACEOF
26693 /* confdefs.h.  */
26694 _ACEOF
26695 cat confdefs.h >>conftest.$ac_ext
26696 cat >>conftest.$ac_ext <<_ACEOF
26697 /* end confdefs.h.  */
26698 $ac_includes_default
26699 #ifndef offsetof
26700 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26701 #endif
26702 typedef struct { char x; int y; } ac__type_alignof_;
26703 int
26704 main ()
26705 {
26706 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26707 test_array [0] = 0
26708
26709   ;
26710   return 0;
26711 }
26712 _ACEOF
26713 rm -f conftest.$ac_objext
26714 if { (ac_try="$ac_compile"
26715 case "(($ac_try" in
26716   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26717   *) ac_try_echo=$ac_try;;
26718 esac
26719 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26720 $as_echo "$ac_try_echo") >&5
26721   (eval "$ac_compile") 2>conftest.er1
26722   ac_status=$?
26723   grep -v '^ *+' conftest.er1 >conftest.err
26724   rm -f conftest.er1
26725   cat conftest.err >&5
26726   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26727   (exit $ac_status); } && {
26728          test -z "$ac_c_werror_flag" ||
26729          test ! -s conftest.err
26730        } && test -s conftest.$ac_objext; then
26731   ac_lo=$ac_mid; break
26732 else
26733   $as_echo "$as_me: failed program was:" >&5
26734 sed 's/^/| /' conftest.$ac_ext >&5
26735
26736         ac_hi=`expr '(' $ac_mid ')' - 1`
26737                         if test $ac_mid -le $ac_hi; then
26738                           ac_lo= ac_hi=
26739                           break
26740                         fi
26741                         ac_mid=`expr 2 '*' $ac_mid`
26742 fi
26743
26744 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26745   done
26746 else
26747   $as_echo "$as_me: failed program was:" >&5
26748 sed 's/^/| /' conftest.$ac_ext >&5
26749
26750         ac_lo= ac_hi=
26751 fi
26752
26753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26754 fi
26755
26756 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26757 # Binary search between lo and hi bounds.
26758 while test "x$ac_lo" != "x$ac_hi"; do
26759   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26760   cat >conftest.$ac_ext <<_ACEOF
26761 /* confdefs.h.  */
26762 _ACEOF
26763 cat confdefs.h >>conftest.$ac_ext
26764 cat >>conftest.$ac_ext <<_ACEOF
26765 /* end confdefs.h.  */
26766 $ac_includes_default
26767 #ifndef offsetof
26768 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26769 #endif
26770 typedef struct { char x; int y; } ac__type_alignof_;
26771 int
26772 main ()
26773 {
26774 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26775 test_array [0] = 0
26776
26777   ;
26778   return 0;
26779 }
26780 _ACEOF
26781 rm -f conftest.$ac_objext
26782 if { (ac_try="$ac_compile"
26783 case "(($ac_try" in
26784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26785   *) ac_try_echo=$ac_try;;
26786 esac
26787 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26788 $as_echo "$ac_try_echo") >&5
26789   (eval "$ac_compile") 2>conftest.er1
26790   ac_status=$?
26791   grep -v '^ *+' conftest.er1 >conftest.err
26792   rm -f conftest.er1
26793   cat conftest.err >&5
26794   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26795   (exit $ac_status); } && {
26796          test -z "$ac_c_werror_flag" ||
26797          test ! -s conftest.err
26798        } && test -s conftest.$ac_objext; then
26799   ac_hi=$ac_mid
26800 else
26801   $as_echo "$as_me: failed program was:" >&5
26802 sed 's/^/| /' conftest.$ac_ext >&5
26803
26804         ac_lo=`expr '(' $ac_mid ')' + 1`
26805 fi
26806
26807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26808 done
26809 case $ac_lo in
26810 ?*) ac_cv_alignof_int=$ac_lo;;
26811 '') if test "$ac_cv_type_int" = yes; then
26812      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26813 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26814 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26815 See \`config.log' for more details." >&5
26816 $as_echo "$as_me: error: cannot compute alignment of int
26817 See \`config.log' for more details." >&2;}
26818    { (exit 77); exit 77; }; }; }
26819    else
26820      ac_cv_alignof_int=0
26821    fi ;;
26822 esac
26823 else
26824   cat >conftest.$ac_ext <<_ACEOF
26825 /* confdefs.h.  */
26826 _ACEOF
26827 cat confdefs.h >>conftest.$ac_ext
26828 cat >>conftest.$ac_ext <<_ACEOF
26829 /* end confdefs.h.  */
26830 $ac_includes_default
26831 #ifndef offsetof
26832 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26833 #endif
26834 typedef struct { char x; int y; } ac__type_alignof_;
26835 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26836 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26837 #include <stdio.h>
26838 #include <stdlib.h>
26839 int
26840 main ()
26841 {
26842
26843   FILE *f = fopen ("conftest.val", "w");
26844   if (! f)
26845     return 1;
26846   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26847     {
26848       long int i = longval ();
26849       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26850         return 1;
26851       fprintf (f, "%ld", i);
26852     }
26853   else
26854     {
26855       unsigned long int i = ulongval ();
26856       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26857         return 1;
26858       fprintf (f, "%lu", i);
26859     }
26860   /* Do not output a trailing newline, as this causes \r\n confusion
26861      on some platforms.  */
26862   return ferror (f) || fclose (f) != 0;
26863
26864   ;
26865   return 0;
26866 }
26867 _ACEOF
26868 rm -f conftest$ac_exeext
26869 if { (ac_try="$ac_link"
26870 case "(($ac_try" in
26871   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26872   *) ac_try_echo=$ac_try;;
26873 esac
26874 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26875 $as_echo "$ac_try_echo") >&5
26876   (eval "$ac_link") 2>&5
26877   ac_status=$?
26878   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26879   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26880   { (case "(($ac_try" in
26881   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26882   *) ac_try_echo=$ac_try;;
26883 esac
26884 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26885 $as_echo "$ac_try_echo") >&5
26886   (eval "$ac_try") 2>&5
26887   ac_status=$?
26888   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26889   (exit $ac_status); }; }; then
26890   ac_cv_alignof_int=`cat conftest.val`
26891 else
26892   $as_echo "$as_me: program exited with status $ac_status" >&5
26893 $as_echo "$as_me: failed program was:" >&5
26894 sed 's/^/| /' conftest.$ac_ext >&5
26895
26896 ( exit $ac_status )
26897 if test "$ac_cv_type_int" = yes; then
26898      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26899 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26900 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26901 See \`config.log' for more details." >&5
26902 $as_echo "$as_me: error: cannot compute alignment of int
26903 See \`config.log' for more details." >&2;}
26904    { (exit 77); exit 77; }; }; }
26905    else
26906      ac_cv_alignof_int=0
26907    fi
26908 fi
26909 rm -rf conftest.dSYM
26910 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26911 fi
26912 rm -f conftest.val
26913 fi
26914 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
26915 $as_echo "$ac_cv_alignof_int" >&6; }
26916
26917
26918
26919 cat >>confdefs.h <<_ACEOF
26920 #define ALIGNOF_INT $ac_cv_alignof_int
26921 _ACEOF
26922
26923
26924 # The cast to long int works around a bug in the HP C Compiler,
26925 # see AC_CHECK_SIZEOF for more information.
26926 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
26927 $as_echo_n "checking alignment of long... " >&6; }
26928 if test "${ac_cv_alignof_long+set}" = set; then
26929   $as_echo_n "(cached) " >&6
26930 else
26931   if test "$cross_compiling" = yes; then
26932   # Depending upon the size, compute the lo and hi bounds.
26933 cat >conftest.$ac_ext <<_ACEOF
26934 /* confdefs.h.  */
26935 _ACEOF
26936 cat confdefs.h >>conftest.$ac_ext
26937 cat >>conftest.$ac_ext <<_ACEOF
26938 /* end confdefs.h.  */
26939 $ac_includes_default
26940 #ifndef offsetof
26941 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26942 #endif
26943 typedef struct { char x; long y; } ac__type_alignof_;
26944 int
26945 main ()
26946 {
26947 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26948 test_array [0] = 0
26949
26950   ;
26951   return 0;
26952 }
26953 _ACEOF
26954 rm -f conftest.$ac_objext
26955 if { (ac_try="$ac_compile"
26956 case "(($ac_try" in
26957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26958   *) ac_try_echo=$ac_try;;
26959 esac
26960 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26961 $as_echo "$ac_try_echo") >&5
26962   (eval "$ac_compile") 2>conftest.er1
26963   ac_status=$?
26964   grep -v '^ *+' conftest.er1 >conftest.err
26965   rm -f conftest.er1
26966   cat conftest.err >&5
26967   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26968   (exit $ac_status); } && {
26969          test -z "$ac_c_werror_flag" ||
26970          test ! -s conftest.err
26971        } && test -s conftest.$ac_objext; then
26972   ac_lo=0 ac_mid=0
26973   while :; do
26974     cat >conftest.$ac_ext <<_ACEOF
26975 /* confdefs.h.  */
26976 _ACEOF
26977 cat confdefs.h >>conftest.$ac_ext
26978 cat >>conftest.$ac_ext <<_ACEOF
26979 /* end confdefs.h.  */
26980 $ac_includes_default
26981 #ifndef offsetof
26982 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26983 #endif
26984 typedef struct { char x; long y; } ac__type_alignof_;
26985 int
26986 main ()
26987 {
26988 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26989 test_array [0] = 0
26990
26991   ;
26992   return 0;
26993 }
26994 _ACEOF
26995 rm -f conftest.$ac_objext
26996 if { (ac_try="$ac_compile"
26997 case "(($ac_try" in
26998   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26999   *) ac_try_echo=$ac_try;;
27000 esac
27001 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27002 $as_echo "$ac_try_echo") >&5
27003   (eval "$ac_compile") 2>conftest.er1
27004   ac_status=$?
27005   grep -v '^ *+' conftest.er1 >conftest.err
27006   rm -f conftest.er1
27007   cat conftest.err >&5
27008   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27009   (exit $ac_status); } && {
27010          test -z "$ac_c_werror_flag" ||
27011          test ! -s conftest.err
27012        } && test -s conftest.$ac_objext; then
27013   ac_hi=$ac_mid; break
27014 else
27015   $as_echo "$as_me: failed program was:" >&5
27016 sed 's/^/| /' conftest.$ac_ext >&5
27017
27018         ac_lo=`expr $ac_mid + 1`
27019                         if test $ac_lo -le $ac_mid; then
27020                           ac_lo= ac_hi=
27021                           break
27022                         fi
27023                         ac_mid=`expr 2 '*' $ac_mid + 1`
27024 fi
27025
27026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27027   done
27028 else
27029   $as_echo "$as_me: failed program was:" >&5
27030 sed 's/^/| /' conftest.$ac_ext >&5
27031
27032         cat >conftest.$ac_ext <<_ACEOF
27033 /* confdefs.h.  */
27034 _ACEOF
27035 cat confdefs.h >>conftest.$ac_ext
27036 cat >>conftest.$ac_ext <<_ACEOF
27037 /* end confdefs.h.  */
27038 $ac_includes_default
27039 #ifndef offsetof
27040 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27041 #endif
27042 typedef struct { char x; long y; } ac__type_alignof_;
27043 int
27044 main ()
27045 {
27046 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
27047 test_array [0] = 0
27048
27049   ;
27050   return 0;
27051 }
27052 _ACEOF
27053 rm -f conftest.$ac_objext
27054 if { (ac_try="$ac_compile"
27055 case "(($ac_try" in
27056   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27057   *) ac_try_echo=$ac_try;;
27058 esac
27059 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27060 $as_echo "$ac_try_echo") >&5
27061   (eval "$ac_compile") 2>conftest.er1
27062   ac_status=$?
27063   grep -v '^ *+' conftest.er1 >conftest.err
27064   rm -f conftest.er1
27065   cat conftest.err >&5
27066   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27067   (exit $ac_status); } && {
27068          test -z "$ac_c_werror_flag" ||
27069          test ! -s conftest.err
27070        } && test -s conftest.$ac_objext; then
27071   ac_hi=-1 ac_mid=-1
27072   while :; do
27073     cat >conftest.$ac_ext <<_ACEOF
27074 /* confdefs.h.  */
27075 _ACEOF
27076 cat confdefs.h >>conftest.$ac_ext
27077 cat >>conftest.$ac_ext <<_ACEOF
27078 /* end confdefs.h.  */
27079 $ac_includes_default
27080 #ifndef offsetof
27081 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27082 #endif
27083 typedef struct { char x; long y; } ac__type_alignof_;
27084 int
27085 main ()
27086 {
27087 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
27088 test_array [0] = 0
27089
27090   ;
27091   return 0;
27092 }
27093 _ACEOF
27094 rm -f conftest.$ac_objext
27095 if { (ac_try="$ac_compile"
27096 case "(($ac_try" in
27097   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27098   *) ac_try_echo=$ac_try;;
27099 esac
27100 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27101 $as_echo "$ac_try_echo") >&5
27102   (eval "$ac_compile") 2>conftest.er1
27103   ac_status=$?
27104   grep -v '^ *+' conftest.er1 >conftest.err
27105   rm -f conftest.er1
27106   cat conftest.err >&5
27107   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27108   (exit $ac_status); } && {
27109          test -z "$ac_c_werror_flag" ||
27110          test ! -s conftest.err
27111        } && test -s conftest.$ac_objext; then
27112   ac_lo=$ac_mid; break
27113 else
27114   $as_echo "$as_me: failed program was:" >&5
27115 sed 's/^/| /' conftest.$ac_ext >&5
27116
27117         ac_hi=`expr '(' $ac_mid ')' - 1`
27118                         if test $ac_mid -le $ac_hi; then
27119                           ac_lo= ac_hi=
27120                           break
27121                         fi
27122                         ac_mid=`expr 2 '*' $ac_mid`
27123 fi
27124
27125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27126   done
27127 else
27128   $as_echo "$as_me: failed program was:" >&5
27129 sed 's/^/| /' conftest.$ac_ext >&5
27130
27131         ac_lo= ac_hi=
27132 fi
27133
27134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27135 fi
27136
27137 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27138 # Binary search between lo and hi bounds.
27139 while test "x$ac_lo" != "x$ac_hi"; do
27140   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27141   cat >conftest.$ac_ext <<_ACEOF
27142 /* confdefs.h.  */
27143 _ACEOF
27144 cat confdefs.h >>conftest.$ac_ext
27145 cat >>conftest.$ac_ext <<_ACEOF
27146 /* end confdefs.h.  */
27147 $ac_includes_default
27148 #ifndef offsetof
27149 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27150 #endif
27151 typedef struct { char x; long y; } ac__type_alignof_;
27152 int
27153 main ()
27154 {
27155 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27156 test_array [0] = 0
27157
27158   ;
27159   return 0;
27160 }
27161 _ACEOF
27162 rm -f conftest.$ac_objext
27163 if { (ac_try="$ac_compile"
27164 case "(($ac_try" in
27165   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27166   *) ac_try_echo=$ac_try;;
27167 esac
27168 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27169 $as_echo "$ac_try_echo") >&5
27170   (eval "$ac_compile") 2>conftest.er1
27171   ac_status=$?
27172   grep -v '^ *+' conftest.er1 >conftest.err
27173   rm -f conftest.er1
27174   cat conftest.err >&5
27175   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27176   (exit $ac_status); } && {
27177          test -z "$ac_c_werror_flag" ||
27178          test ! -s conftest.err
27179        } && test -s conftest.$ac_objext; then
27180   ac_hi=$ac_mid
27181 else
27182   $as_echo "$as_me: failed program was:" >&5
27183 sed 's/^/| /' conftest.$ac_ext >&5
27184
27185         ac_lo=`expr '(' $ac_mid ')' + 1`
27186 fi
27187
27188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27189 done
27190 case $ac_lo in
27191 ?*) ac_cv_alignof_long=$ac_lo;;
27192 '') if test "$ac_cv_type_long" = yes; then
27193      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27194 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27195 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
27196 See \`config.log' for more details." >&5
27197 $as_echo "$as_me: error: cannot compute alignment of long
27198 See \`config.log' for more details." >&2;}
27199    { (exit 77); exit 77; }; }; }
27200    else
27201      ac_cv_alignof_long=0
27202    fi ;;
27203 esac
27204 else
27205   cat >conftest.$ac_ext <<_ACEOF
27206 /* confdefs.h.  */
27207 _ACEOF
27208 cat confdefs.h >>conftest.$ac_ext
27209 cat >>conftest.$ac_ext <<_ACEOF
27210 /* end confdefs.h.  */
27211 $ac_includes_default
27212 #ifndef offsetof
27213 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27214 #endif
27215 typedef struct { char x; long y; } ac__type_alignof_;
27216 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27217 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27218 #include <stdio.h>
27219 #include <stdlib.h>
27220 int
27221 main ()
27222 {
27223
27224   FILE *f = fopen ("conftest.val", "w");
27225   if (! f)
27226     return 1;
27227   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27228     {
27229       long int i = longval ();
27230       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27231         return 1;
27232       fprintf (f, "%ld", i);
27233     }
27234   else
27235     {
27236       unsigned long int i = ulongval ();
27237       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27238         return 1;
27239       fprintf (f, "%lu", i);
27240     }
27241   /* Do not output a trailing newline, as this causes \r\n confusion
27242      on some platforms.  */
27243   return ferror (f) || fclose (f) != 0;
27244
27245   ;
27246   return 0;
27247 }
27248 _ACEOF
27249 rm -f conftest$ac_exeext
27250 if { (ac_try="$ac_link"
27251 case "(($ac_try" in
27252   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27253   *) ac_try_echo=$ac_try;;
27254 esac
27255 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27256 $as_echo "$ac_try_echo") >&5
27257   (eval "$ac_link") 2>&5
27258   ac_status=$?
27259   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27260   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27261   { (case "(($ac_try" in
27262   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27263   *) ac_try_echo=$ac_try;;
27264 esac
27265 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27266 $as_echo "$ac_try_echo") >&5
27267   (eval "$ac_try") 2>&5
27268   ac_status=$?
27269   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27270   (exit $ac_status); }; }; then
27271   ac_cv_alignof_long=`cat conftest.val`
27272 else
27273   $as_echo "$as_me: program exited with status $ac_status" >&5
27274 $as_echo "$as_me: failed program was:" >&5
27275 sed 's/^/| /' conftest.$ac_ext >&5
27276
27277 ( exit $ac_status )
27278 if test "$ac_cv_type_long" = yes; then
27279      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27280 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27281 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
27282 See \`config.log' for more details." >&5
27283 $as_echo "$as_me: error: cannot compute alignment of long
27284 See \`config.log' for more details." >&2;}
27285    { (exit 77); exit 77; }; }; }
27286    else
27287      ac_cv_alignof_long=0
27288    fi
27289 fi
27290 rm -rf conftest.dSYM
27291 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27292 fi
27293 rm -f conftest.val
27294 fi
27295 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
27296 $as_echo "$ac_cv_alignof_long" >&6; }
27297
27298
27299
27300 cat >>confdefs.h <<_ACEOF
27301 #define ALIGNOF_LONG $ac_cv_alignof_long
27302 _ACEOF
27303
27304
27305 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
27306   # The cast to long int works around a bug in the HP C Compiler,
27307 # see AC_CHECK_SIZEOF for more information.
27308 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
27309 $as_echo_n "checking alignment of long long int... " >&6; }
27310 if test "${ac_cv_alignof_long_long_int+set}" = set; then
27311   $as_echo_n "(cached) " >&6
27312 else
27313   if test "$cross_compiling" = yes; then
27314   # Depending upon the size, compute the lo and hi bounds.
27315 cat >conftest.$ac_ext <<_ACEOF
27316 /* confdefs.h.  */
27317 _ACEOF
27318 cat confdefs.h >>conftest.$ac_ext
27319 cat >>conftest.$ac_ext <<_ACEOF
27320 /* end confdefs.h.  */
27321 $ac_includes_default
27322 #ifndef offsetof
27323 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27324 #endif
27325 typedef struct { char x; long long int y; } ac__type_alignof_;
27326 int
27327 main ()
27328 {
27329 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
27330 test_array [0] = 0
27331
27332   ;
27333   return 0;
27334 }
27335 _ACEOF
27336 rm -f conftest.$ac_objext
27337 if { (ac_try="$ac_compile"
27338 case "(($ac_try" in
27339   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27340   *) ac_try_echo=$ac_try;;
27341 esac
27342 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27343 $as_echo "$ac_try_echo") >&5
27344   (eval "$ac_compile") 2>conftest.er1
27345   ac_status=$?
27346   grep -v '^ *+' conftest.er1 >conftest.err
27347   rm -f conftest.er1
27348   cat conftest.err >&5
27349   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27350   (exit $ac_status); } && {
27351          test -z "$ac_c_werror_flag" ||
27352          test ! -s conftest.err
27353        } && test -s conftest.$ac_objext; then
27354   ac_lo=0 ac_mid=0
27355   while :; do
27356     cat >conftest.$ac_ext <<_ACEOF
27357 /* confdefs.h.  */
27358 _ACEOF
27359 cat confdefs.h >>conftest.$ac_ext
27360 cat >>conftest.$ac_ext <<_ACEOF
27361 /* end confdefs.h.  */
27362 $ac_includes_default
27363 #ifndef offsetof
27364 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27365 #endif
27366 typedef struct { char x; long long int y; } ac__type_alignof_;
27367 int
27368 main ()
27369 {
27370 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27371 test_array [0] = 0
27372
27373   ;
27374   return 0;
27375 }
27376 _ACEOF
27377 rm -f conftest.$ac_objext
27378 if { (ac_try="$ac_compile"
27379 case "(($ac_try" in
27380   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27381   *) ac_try_echo=$ac_try;;
27382 esac
27383 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27384 $as_echo "$ac_try_echo") >&5
27385   (eval "$ac_compile") 2>conftest.er1
27386   ac_status=$?
27387   grep -v '^ *+' conftest.er1 >conftest.err
27388   rm -f conftest.er1
27389   cat conftest.err >&5
27390   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27391   (exit $ac_status); } && {
27392          test -z "$ac_c_werror_flag" ||
27393          test ! -s conftest.err
27394        } && test -s conftest.$ac_objext; then
27395   ac_hi=$ac_mid; break
27396 else
27397   $as_echo "$as_me: failed program was:" >&5
27398 sed 's/^/| /' conftest.$ac_ext >&5
27399
27400         ac_lo=`expr $ac_mid + 1`
27401                         if test $ac_lo -le $ac_mid; then
27402                           ac_lo= ac_hi=
27403                           break
27404                         fi
27405                         ac_mid=`expr 2 '*' $ac_mid + 1`
27406 fi
27407
27408 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27409   done
27410 else
27411   $as_echo "$as_me: failed program was:" >&5
27412 sed 's/^/| /' conftest.$ac_ext >&5
27413
27414         cat >conftest.$ac_ext <<_ACEOF
27415 /* confdefs.h.  */
27416 _ACEOF
27417 cat confdefs.h >>conftest.$ac_ext
27418 cat >>conftest.$ac_ext <<_ACEOF
27419 /* end confdefs.h.  */
27420 $ac_includes_default
27421 #ifndef offsetof
27422 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27423 #endif
27424 typedef struct { char x; long long int y; } ac__type_alignof_;
27425 int
27426 main ()
27427 {
27428 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
27429 test_array [0] = 0
27430
27431   ;
27432   return 0;
27433 }
27434 _ACEOF
27435 rm -f conftest.$ac_objext
27436 if { (ac_try="$ac_compile"
27437 case "(($ac_try" in
27438   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27439   *) ac_try_echo=$ac_try;;
27440 esac
27441 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27442 $as_echo "$ac_try_echo") >&5
27443   (eval "$ac_compile") 2>conftest.er1
27444   ac_status=$?
27445   grep -v '^ *+' conftest.er1 >conftest.err
27446   rm -f conftest.er1
27447   cat conftest.err >&5
27448   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27449   (exit $ac_status); } && {
27450          test -z "$ac_c_werror_flag" ||
27451          test ! -s conftest.err
27452        } && test -s conftest.$ac_objext; then
27453   ac_hi=-1 ac_mid=-1
27454   while :; do
27455     cat >conftest.$ac_ext <<_ACEOF
27456 /* confdefs.h.  */
27457 _ACEOF
27458 cat confdefs.h >>conftest.$ac_ext
27459 cat >>conftest.$ac_ext <<_ACEOF
27460 /* end confdefs.h.  */
27461 $ac_includes_default
27462 #ifndef offsetof
27463 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27464 #endif
27465 typedef struct { char x; long long int y; } ac__type_alignof_;
27466 int
27467 main ()
27468 {
27469 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
27470 test_array [0] = 0
27471
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   ac_lo=$ac_mid; break
27495 else
27496   $as_echo "$as_me: failed program was:" >&5
27497 sed 's/^/| /' conftest.$ac_ext >&5
27498
27499         ac_hi=`expr '(' $ac_mid ')' - 1`
27500                         if test $ac_mid -le $ac_hi; then
27501                           ac_lo= ac_hi=
27502                           break
27503                         fi
27504                         ac_mid=`expr 2 '*' $ac_mid`
27505 fi
27506
27507 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27508   done
27509 else
27510   $as_echo "$as_me: failed program was:" >&5
27511 sed 's/^/| /' conftest.$ac_ext >&5
27512
27513         ac_lo= ac_hi=
27514 fi
27515
27516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27517 fi
27518
27519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27520 # Binary search between lo and hi bounds.
27521 while test "x$ac_lo" != "x$ac_hi"; do
27522   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27523   cat >conftest.$ac_ext <<_ACEOF
27524 /* confdefs.h.  */
27525 _ACEOF
27526 cat confdefs.h >>conftest.$ac_ext
27527 cat >>conftest.$ac_ext <<_ACEOF
27528 /* end confdefs.h.  */
27529 $ac_includes_default
27530 #ifndef offsetof
27531 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27532 #endif
27533 typedef struct { char x; long long int y; } ac__type_alignof_;
27534 int
27535 main ()
27536 {
27537 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27538 test_array [0] = 0
27539
27540   ;
27541   return 0;
27542 }
27543 _ACEOF
27544 rm -f conftest.$ac_objext
27545 if { (ac_try="$ac_compile"
27546 case "(($ac_try" in
27547   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27548   *) ac_try_echo=$ac_try;;
27549 esac
27550 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27551 $as_echo "$ac_try_echo") >&5
27552   (eval "$ac_compile") 2>conftest.er1
27553   ac_status=$?
27554   grep -v '^ *+' conftest.er1 >conftest.err
27555   rm -f conftest.er1
27556   cat conftest.err >&5
27557   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27558   (exit $ac_status); } && {
27559          test -z "$ac_c_werror_flag" ||
27560          test ! -s conftest.err
27561        } && test -s conftest.$ac_objext; then
27562   ac_hi=$ac_mid
27563 else
27564   $as_echo "$as_me: failed program was:" >&5
27565 sed 's/^/| /' conftest.$ac_ext >&5
27566
27567         ac_lo=`expr '(' $ac_mid ')' + 1`
27568 fi
27569
27570 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27571 done
27572 case $ac_lo in
27573 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
27574 '') if test "$ac_cv_type_long_long_int" = yes; then
27575      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27576 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27577 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
27578 See \`config.log' for more details." >&5
27579 $as_echo "$as_me: error: cannot compute alignment of long long int
27580 See \`config.log' for more details." >&2;}
27581    { (exit 77); exit 77; }; }; }
27582    else
27583      ac_cv_alignof_long_long_int=0
27584    fi ;;
27585 esac
27586 else
27587   cat >conftest.$ac_ext <<_ACEOF
27588 /* confdefs.h.  */
27589 _ACEOF
27590 cat confdefs.h >>conftest.$ac_ext
27591 cat >>conftest.$ac_ext <<_ACEOF
27592 /* end confdefs.h.  */
27593 $ac_includes_default
27594 #ifndef offsetof
27595 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27596 #endif
27597 typedef struct { char x; long long int y; } ac__type_alignof_;
27598 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27599 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27600 #include <stdio.h>
27601 #include <stdlib.h>
27602 int
27603 main ()
27604 {
27605
27606   FILE *f = fopen ("conftest.val", "w");
27607   if (! f)
27608     return 1;
27609   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27610     {
27611       long int i = longval ();
27612       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27613         return 1;
27614       fprintf (f, "%ld", i);
27615     }
27616   else
27617     {
27618       unsigned long int i = ulongval ();
27619       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27620         return 1;
27621       fprintf (f, "%lu", i);
27622     }
27623   /* Do not output a trailing newline, as this causes \r\n confusion
27624      on some platforms.  */
27625   return ferror (f) || fclose (f) != 0;
27626
27627   ;
27628   return 0;
27629 }
27630 _ACEOF
27631 rm -f conftest$ac_exeext
27632 if { (ac_try="$ac_link"
27633 case "(($ac_try" in
27634   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27635   *) ac_try_echo=$ac_try;;
27636 esac
27637 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27638 $as_echo "$ac_try_echo") >&5
27639   (eval "$ac_link") 2>&5
27640   ac_status=$?
27641   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27642   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27643   { (case "(($ac_try" in
27644   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27645   *) ac_try_echo=$ac_try;;
27646 esac
27647 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27648 $as_echo "$ac_try_echo") >&5
27649   (eval "$ac_try") 2>&5
27650   ac_status=$?
27651   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27652   (exit $ac_status); }; }; then
27653   ac_cv_alignof_long_long_int=`cat conftest.val`
27654 else
27655   $as_echo "$as_me: program exited with status $ac_status" >&5
27656 $as_echo "$as_me: failed program was:" >&5
27657 sed 's/^/| /' conftest.$ac_ext >&5
27658
27659 ( exit $ac_status )
27660 if test "$ac_cv_type_long_long_int" = yes; then
27661      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27662 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27663 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
27664 See \`config.log' for more details." >&5
27665 $as_echo "$as_me: error: cannot compute alignment of long long int
27666 See \`config.log' for more details." >&2;}
27667    { (exit 77); exit 77; }; }; }
27668    else
27669      ac_cv_alignof_long_long_int=0
27670    fi
27671 fi
27672 rm -rf conftest.dSYM
27673 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27674 fi
27675 rm -f conftest.val
27676 fi
27677 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
27678 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
27679
27680
27681
27682 cat >>confdefs.h <<_ACEOF
27683 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
27684 _ACEOF
27685
27686
27687 fi
27688 # The cast to long int works around a bug in the HP C Compiler,
27689 # see AC_CHECK_SIZEOF for more information.
27690 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
27691 $as_echo_n "checking alignment of double... " >&6; }
27692 if test "${ac_cv_alignof_double+set}" = set; then
27693   $as_echo_n "(cached) " >&6
27694 else
27695   if test "$cross_compiling" = yes; then
27696   # Depending upon the size, compute the lo and hi bounds.
27697 cat >conftest.$ac_ext <<_ACEOF
27698 /* confdefs.h.  */
27699 _ACEOF
27700 cat confdefs.h >>conftest.$ac_ext
27701 cat >>conftest.$ac_ext <<_ACEOF
27702 /* end confdefs.h.  */
27703 $ac_includes_default
27704 #ifndef offsetof
27705 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27706 #endif
27707 typedef struct { char x; double y; } ac__type_alignof_;
27708 int
27709 main ()
27710 {
27711 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
27712 test_array [0] = 0
27713
27714   ;
27715   return 0;
27716 }
27717 _ACEOF
27718 rm -f conftest.$ac_objext
27719 if { (ac_try="$ac_compile"
27720 case "(($ac_try" in
27721   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27722   *) ac_try_echo=$ac_try;;
27723 esac
27724 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27725 $as_echo "$ac_try_echo") >&5
27726   (eval "$ac_compile") 2>conftest.er1
27727   ac_status=$?
27728   grep -v '^ *+' conftest.er1 >conftest.err
27729   rm -f conftest.er1
27730   cat conftest.err >&5
27731   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27732   (exit $ac_status); } && {
27733          test -z "$ac_c_werror_flag" ||
27734          test ! -s conftest.err
27735        } && test -s conftest.$ac_objext; then
27736   ac_lo=0 ac_mid=0
27737   while :; do
27738     cat >conftest.$ac_ext <<_ACEOF
27739 /* confdefs.h.  */
27740 _ACEOF
27741 cat confdefs.h >>conftest.$ac_ext
27742 cat >>conftest.$ac_ext <<_ACEOF
27743 /* end confdefs.h.  */
27744 $ac_includes_default
27745 #ifndef offsetof
27746 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27747 #endif
27748 typedef struct { char x; double y; } ac__type_alignof_;
27749 int
27750 main ()
27751 {
27752 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27753 test_array [0] = 0
27754
27755   ;
27756   return 0;
27757 }
27758 _ACEOF
27759 rm -f conftest.$ac_objext
27760 if { (ac_try="$ac_compile"
27761 case "(($ac_try" in
27762   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27763   *) ac_try_echo=$ac_try;;
27764 esac
27765 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27766 $as_echo "$ac_try_echo") >&5
27767   (eval "$ac_compile") 2>conftest.er1
27768   ac_status=$?
27769   grep -v '^ *+' conftest.er1 >conftest.err
27770   rm -f conftest.er1
27771   cat conftest.err >&5
27772   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27773   (exit $ac_status); } && {
27774          test -z "$ac_c_werror_flag" ||
27775          test ! -s conftest.err
27776        } && test -s conftest.$ac_objext; then
27777   ac_hi=$ac_mid; break
27778 else
27779   $as_echo "$as_me: failed program was:" >&5
27780 sed 's/^/| /' conftest.$ac_ext >&5
27781
27782         ac_lo=`expr $ac_mid + 1`
27783                         if test $ac_lo -le $ac_mid; then
27784                           ac_lo= ac_hi=
27785                           break
27786                         fi
27787                         ac_mid=`expr 2 '*' $ac_mid + 1`
27788 fi
27789
27790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27791   done
27792 else
27793   $as_echo "$as_me: failed program was:" >&5
27794 sed 's/^/| /' conftest.$ac_ext >&5
27795
27796         cat >conftest.$ac_ext <<_ACEOF
27797 /* confdefs.h.  */
27798 _ACEOF
27799 cat confdefs.h >>conftest.$ac_ext
27800 cat >>conftest.$ac_ext <<_ACEOF
27801 /* end confdefs.h.  */
27802 $ac_includes_default
27803 #ifndef offsetof
27804 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27805 #endif
27806 typedef struct { char x; double y; } ac__type_alignof_;
27807 int
27808 main ()
27809 {
27810 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
27811 test_array [0] = 0
27812
27813   ;
27814   return 0;
27815 }
27816 _ACEOF
27817 rm -f conftest.$ac_objext
27818 if { (ac_try="$ac_compile"
27819 case "(($ac_try" in
27820   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27821   *) ac_try_echo=$ac_try;;
27822 esac
27823 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27824 $as_echo "$ac_try_echo") >&5
27825   (eval "$ac_compile") 2>conftest.er1
27826   ac_status=$?
27827   grep -v '^ *+' conftest.er1 >conftest.err
27828   rm -f conftest.er1
27829   cat conftest.err >&5
27830   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27831   (exit $ac_status); } && {
27832          test -z "$ac_c_werror_flag" ||
27833          test ! -s conftest.err
27834        } && test -s conftest.$ac_objext; then
27835   ac_hi=-1 ac_mid=-1
27836   while :; do
27837     cat >conftest.$ac_ext <<_ACEOF
27838 /* confdefs.h.  */
27839 _ACEOF
27840 cat confdefs.h >>conftest.$ac_ext
27841 cat >>conftest.$ac_ext <<_ACEOF
27842 /* end confdefs.h.  */
27843 $ac_includes_default
27844 #ifndef offsetof
27845 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27846 #endif
27847 typedef struct { char x; double y; } ac__type_alignof_;
27848 int
27849 main ()
27850 {
27851 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
27852 test_array [0] = 0
27853
27854   ;
27855   return 0;
27856 }
27857 _ACEOF
27858 rm -f conftest.$ac_objext
27859 if { (ac_try="$ac_compile"
27860 case "(($ac_try" in
27861   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27862   *) ac_try_echo=$ac_try;;
27863 esac
27864 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27865 $as_echo "$ac_try_echo") >&5
27866   (eval "$ac_compile") 2>conftest.er1
27867   ac_status=$?
27868   grep -v '^ *+' conftest.er1 >conftest.err
27869   rm -f conftest.er1
27870   cat conftest.err >&5
27871   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27872   (exit $ac_status); } && {
27873          test -z "$ac_c_werror_flag" ||
27874          test ! -s conftest.err
27875        } && test -s conftest.$ac_objext; then
27876   ac_lo=$ac_mid; break
27877 else
27878   $as_echo "$as_me: failed program was:" >&5
27879 sed 's/^/| /' conftest.$ac_ext >&5
27880
27881         ac_hi=`expr '(' $ac_mid ')' - 1`
27882                         if test $ac_mid -le $ac_hi; then
27883                           ac_lo= ac_hi=
27884                           break
27885                         fi
27886                         ac_mid=`expr 2 '*' $ac_mid`
27887 fi
27888
27889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27890   done
27891 else
27892   $as_echo "$as_me: failed program was:" >&5
27893 sed 's/^/| /' conftest.$ac_ext >&5
27894
27895         ac_lo= ac_hi=
27896 fi
27897
27898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27899 fi
27900
27901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27902 # Binary search between lo and hi bounds.
27903 while test "x$ac_lo" != "x$ac_hi"; do
27904   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27905   cat >conftest.$ac_ext <<_ACEOF
27906 /* confdefs.h.  */
27907 _ACEOF
27908 cat confdefs.h >>conftest.$ac_ext
27909 cat >>conftest.$ac_ext <<_ACEOF
27910 /* end confdefs.h.  */
27911 $ac_includes_default
27912 #ifndef offsetof
27913 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27914 #endif
27915 typedef struct { char x; double y; } ac__type_alignof_;
27916 int
27917 main ()
27918 {
27919 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27920 test_array [0] = 0
27921
27922   ;
27923   return 0;
27924 }
27925 _ACEOF
27926 rm -f conftest.$ac_objext
27927 if { (ac_try="$ac_compile"
27928 case "(($ac_try" in
27929   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27930   *) ac_try_echo=$ac_try;;
27931 esac
27932 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27933 $as_echo "$ac_try_echo") >&5
27934   (eval "$ac_compile") 2>conftest.er1
27935   ac_status=$?
27936   grep -v '^ *+' conftest.er1 >conftest.err
27937   rm -f conftest.er1
27938   cat conftest.err >&5
27939   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27940   (exit $ac_status); } && {
27941          test -z "$ac_c_werror_flag" ||
27942          test ! -s conftest.err
27943        } && test -s conftest.$ac_objext; then
27944   ac_hi=$ac_mid
27945 else
27946   $as_echo "$as_me: failed program was:" >&5
27947 sed 's/^/| /' conftest.$ac_ext >&5
27948
27949         ac_lo=`expr '(' $ac_mid ')' + 1`
27950 fi
27951
27952 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27953 done
27954 case $ac_lo in
27955 ?*) ac_cv_alignof_double=$ac_lo;;
27956 '') if test "$ac_cv_type_double" = yes; then
27957      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27958 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27959 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27960 See \`config.log' for more details." >&5
27961 $as_echo "$as_me: error: cannot compute alignment of double
27962 See \`config.log' for more details." >&2;}
27963    { (exit 77); exit 77; }; }; }
27964    else
27965      ac_cv_alignof_double=0
27966    fi ;;
27967 esac
27968 else
27969   cat >conftest.$ac_ext <<_ACEOF
27970 /* confdefs.h.  */
27971 _ACEOF
27972 cat confdefs.h >>conftest.$ac_ext
27973 cat >>conftest.$ac_ext <<_ACEOF
27974 /* end confdefs.h.  */
27975 $ac_includes_default
27976 #ifndef offsetof
27977 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27978 #endif
27979 typedef struct { char x; double y; } ac__type_alignof_;
27980 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27981 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27982 #include <stdio.h>
27983 #include <stdlib.h>
27984 int
27985 main ()
27986 {
27987
27988   FILE *f = fopen ("conftest.val", "w");
27989   if (! f)
27990     return 1;
27991   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27992     {
27993       long int i = longval ();
27994       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27995         return 1;
27996       fprintf (f, "%ld", i);
27997     }
27998   else
27999     {
28000       unsigned long int i = ulongval ();
28001       if (i != ((long int) offsetof (ac__type_alignof_, y)))
28002         return 1;
28003       fprintf (f, "%lu", i);
28004     }
28005   /* Do not output a trailing newline, as this causes \r\n confusion
28006      on some platforms.  */
28007   return ferror (f) || fclose (f) != 0;
28008
28009   ;
28010   return 0;
28011 }
28012 _ACEOF
28013 rm -f conftest$ac_exeext
28014 if { (ac_try="$ac_link"
28015 case "(($ac_try" in
28016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28017   *) ac_try_echo=$ac_try;;
28018 esac
28019 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28020 $as_echo "$ac_try_echo") >&5
28021   (eval "$ac_link") 2>&5
28022   ac_status=$?
28023   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28024   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28025   { (case "(($ac_try" in
28026   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28027   *) ac_try_echo=$ac_try;;
28028 esac
28029 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28030 $as_echo "$ac_try_echo") >&5
28031   (eval "$ac_try") 2>&5
28032   ac_status=$?
28033   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28034   (exit $ac_status); }; }; then
28035   ac_cv_alignof_double=`cat conftest.val`
28036 else
28037   $as_echo "$as_me: program exited with status $ac_status" >&5
28038 $as_echo "$as_me: failed program was:" >&5
28039 sed 's/^/| /' conftest.$ac_ext >&5
28040
28041 ( exit $ac_status )
28042 if test "$ac_cv_type_double" = yes; then
28043      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
28044 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28045 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
28046 See \`config.log' for more details." >&5
28047 $as_echo "$as_me: error: cannot compute alignment of double
28048 See \`config.log' for more details." >&2;}
28049    { (exit 77); exit 77; }; }; }
28050    else
28051      ac_cv_alignof_double=0
28052    fi
28053 fi
28054 rm -rf conftest.dSYM
28055 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28056 fi
28057 rm -f conftest.val
28058 fi
28059 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
28060 $as_echo "$ac_cv_alignof_double" >&6; }
28061
28062
28063
28064 cat >>confdefs.h <<_ACEOF
28065 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
28066 _ACEOF
28067
28068
28069
28070 # Compute maximum alignment of any basic type.
28071 # We assume long's alignment is at least as strong as char, short, or int;
28072 # but we must check long long (if it exists) and double.
28073
28074 MAX_ALIGNOF=$ac_cv_alignof_long
28075 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
28076   MAX_ALIGNOF=$ac_cv_alignof_double
28077 fi
28078 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
28079   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
28080 fi
28081
28082 cat >>confdefs.h <<_ACEOF
28083 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
28084 _ACEOF
28085
28086
28087
28088 # Some platforms predefine the types int8, int16, etc.  Only check
28089 # a (hopefully) representative subset.
28090 { $as_echo "$as_me:$LINENO: checking for int8" >&5
28091 $as_echo_n "checking for int8... " >&6; }
28092 if test "${ac_cv_type_int8+set}" = set; then
28093   $as_echo_n "(cached) " >&6
28094 else
28095   ac_cv_type_int8=no
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 #include <stdio.h>
28103
28104 int
28105 main ()
28106 {
28107 if (sizeof (int8))
28108        return 0;
28109   ;
28110   return 0;
28111 }
28112 _ACEOF
28113 rm -f conftest.$ac_objext
28114 if { (ac_try="$ac_compile"
28115 case "(($ac_try" in
28116   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28117   *) ac_try_echo=$ac_try;;
28118 esac
28119 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28120 $as_echo "$ac_try_echo") >&5
28121   (eval "$ac_compile") 2>conftest.er1
28122   ac_status=$?
28123   grep -v '^ *+' conftest.er1 >conftest.err
28124   rm -f conftest.er1
28125   cat conftest.err >&5
28126   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28127   (exit $ac_status); } && {
28128          test -z "$ac_c_werror_flag" ||
28129          test ! -s conftest.err
28130        } && test -s conftest.$ac_objext; then
28131   cat >conftest.$ac_ext <<_ACEOF
28132 /* confdefs.h.  */
28133 _ACEOF
28134 cat confdefs.h >>conftest.$ac_ext
28135 cat >>conftest.$ac_ext <<_ACEOF
28136 /* end confdefs.h.  */
28137 #include <stdio.h>
28138
28139 int
28140 main ()
28141 {
28142 if (sizeof ((int8)))
28143           return 0;
28144   ;
28145   return 0;
28146 }
28147 _ACEOF
28148 rm -f conftest.$ac_objext
28149 if { (ac_try="$ac_compile"
28150 case "(($ac_try" in
28151   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28152   *) ac_try_echo=$ac_try;;
28153 esac
28154 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28155 $as_echo "$ac_try_echo") >&5
28156   (eval "$ac_compile") 2>conftest.er1
28157   ac_status=$?
28158   grep -v '^ *+' conftest.er1 >conftest.err
28159   rm -f conftest.er1
28160   cat conftest.err >&5
28161   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28162   (exit $ac_status); } && {
28163          test -z "$ac_c_werror_flag" ||
28164          test ! -s conftest.err
28165        } && test -s conftest.$ac_objext; then
28166   :
28167 else
28168   $as_echo "$as_me: failed program was:" >&5
28169 sed 's/^/| /' conftest.$ac_ext >&5
28170
28171         ac_cv_type_int8=yes
28172 fi
28173
28174 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28175 else
28176   $as_echo "$as_me: failed program was:" >&5
28177 sed 's/^/| /' conftest.$ac_ext >&5
28178
28179
28180 fi
28181
28182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28183 fi
28184 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
28185 $as_echo "$ac_cv_type_int8" >&6; }
28186 if test "x$ac_cv_type_int8" = x""yes; then
28187
28188 cat >>confdefs.h <<_ACEOF
28189 #define HAVE_INT8 1
28190 _ACEOF
28191
28192
28193 fi
28194 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
28195 $as_echo_n "checking for uint8... " >&6; }
28196 if test "${ac_cv_type_uint8+set}" = set; then
28197   $as_echo_n "(cached) " >&6
28198 else
28199   ac_cv_type_uint8=no
28200 cat >conftest.$ac_ext <<_ACEOF
28201 /* confdefs.h.  */
28202 _ACEOF
28203 cat confdefs.h >>conftest.$ac_ext
28204 cat >>conftest.$ac_ext <<_ACEOF
28205 /* end confdefs.h.  */
28206 #include <stdio.h>
28207
28208 int
28209 main ()
28210 {
28211 if (sizeof (uint8))
28212        return 0;
28213   ;
28214   return 0;
28215 }
28216 _ACEOF
28217 rm -f conftest.$ac_objext
28218 if { (ac_try="$ac_compile"
28219 case "(($ac_try" in
28220   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28221   *) ac_try_echo=$ac_try;;
28222 esac
28223 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28224 $as_echo "$ac_try_echo") >&5
28225   (eval "$ac_compile") 2>conftest.er1
28226   ac_status=$?
28227   grep -v '^ *+' conftest.er1 >conftest.err
28228   rm -f conftest.er1
28229   cat conftest.err >&5
28230   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28231   (exit $ac_status); } && {
28232          test -z "$ac_c_werror_flag" ||
28233          test ! -s conftest.err
28234        } && test -s conftest.$ac_objext; then
28235   cat >conftest.$ac_ext <<_ACEOF
28236 /* confdefs.h.  */
28237 _ACEOF
28238 cat confdefs.h >>conftest.$ac_ext
28239 cat >>conftest.$ac_ext <<_ACEOF
28240 /* end confdefs.h.  */
28241 #include <stdio.h>
28242
28243 int
28244 main ()
28245 {
28246 if (sizeof ((uint8)))
28247           return 0;
28248   ;
28249   return 0;
28250 }
28251 _ACEOF
28252 rm -f conftest.$ac_objext
28253 if { (ac_try="$ac_compile"
28254 case "(($ac_try" in
28255   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28256   *) ac_try_echo=$ac_try;;
28257 esac
28258 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28259 $as_echo "$ac_try_echo") >&5
28260   (eval "$ac_compile") 2>conftest.er1
28261   ac_status=$?
28262   grep -v '^ *+' conftest.er1 >conftest.err
28263   rm -f conftest.er1
28264   cat conftest.err >&5
28265   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28266   (exit $ac_status); } && {
28267          test -z "$ac_c_werror_flag" ||
28268          test ! -s conftest.err
28269        } && test -s conftest.$ac_objext; then
28270   :
28271 else
28272   $as_echo "$as_me: failed program was:" >&5
28273 sed 's/^/| /' conftest.$ac_ext >&5
28274
28275         ac_cv_type_uint8=yes
28276 fi
28277
28278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28279 else
28280   $as_echo "$as_me: failed program was:" >&5
28281 sed 's/^/| /' conftest.$ac_ext >&5
28282
28283
28284 fi
28285
28286 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28287 fi
28288 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
28289 $as_echo "$ac_cv_type_uint8" >&6; }
28290 if test "x$ac_cv_type_uint8" = x""yes; then
28291
28292 cat >>confdefs.h <<_ACEOF
28293 #define HAVE_UINT8 1
28294 _ACEOF
28295
28296
28297 fi
28298 { $as_echo "$as_me:$LINENO: checking for int64" >&5
28299 $as_echo_n "checking for int64... " >&6; }
28300 if test "${ac_cv_type_int64+set}" = set; then
28301   $as_echo_n "(cached) " >&6
28302 else
28303   ac_cv_type_int64=no
28304 cat >conftest.$ac_ext <<_ACEOF
28305 /* confdefs.h.  */
28306 _ACEOF
28307 cat confdefs.h >>conftest.$ac_ext
28308 cat >>conftest.$ac_ext <<_ACEOF
28309 /* end confdefs.h.  */
28310 #include <stdio.h>
28311
28312 int
28313 main ()
28314 {
28315 if (sizeof (int64))
28316        return 0;
28317   ;
28318   return 0;
28319 }
28320 _ACEOF
28321 rm -f conftest.$ac_objext
28322 if { (ac_try="$ac_compile"
28323 case "(($ac_try" in
28324   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28325   *) ac_try_echo=$ac_try;;
28326 esac
28327 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28328 $as_echo "$ac_try_echo") >&5
28329   (eval "$ac_compile") 2>conftest.er1
28330   ac_status=$?
28331   grep -v '^ *+' conftest.er1 >conftest.err
28332   rm -f conftest.er1
28333   cat conftest.err >&5
28334   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28335   (exit $ac_status); } && {
28336          test -z "$ac_c_werror_flag" ||
28337          test ! -s conftest.err
28338        } && test -s conftest.$ac_objext; then
28339   cat >conftest.$ac_ext <<_ACEOF
28340 /* confdefs.h.  */
28341 _ACEOF
28342 cat confdefs.h >>conftest.$ac_ext
28343 cat >>conftest.$ac_ext <<_ACEOF
28344 /* end confdefs.h.  */
28345 #include <stdio.h>
28346
28347 int
28348 main ()
28349 {
28350 if (sizeof ((int64)))
28351           return 0;
28352   ;
28353   return 0;
28354 }
28355 _ACEOF
28356 rm -f conftest.$ac_objext
28357 if { (ac_try="$ac_compile"
28358 case "(($ac_try" in
28359   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28360   *) ac_try_echo=$ac_try;;
28361 esac
28362 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28363 $as_echo "$ac_try_echo") >&5
28364   (eval "$ac_compile") 2>conftest.er1
28365   ac_status=$?
28366   grep -v '^ *+' conftest.er1 >conftest.err
28367   rm -f conftest.er1
28368   cat conftest.err >&5
28369   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28370   (exit $ac_status); } && {
28371          test -z "$ac_c_werror_flag" ||
28372          test ! -s conftest.err
28373        } && test -s conftest.$ac_objext; then
28374   :
28375 else
28376   $as_echo "$as_me: failed program was:" >&5
28377 sed 's/^/| /' conftest.$ac_ext >&5
28378
28379         ac_cv_type_int64=yes
28380 fi
28381
28382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28383 else
28384   $as_echo "$as_me: failed program was:" >&5
28385 sed 's/^/| /' conftest.$ac_ext >&5
28386
28387
28388 fi
28389
28390 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28391 fi
28392 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
28393 $as_echo "$ac_cv_type_int64" >&6; }
28394 if test "x$ac_cv_type_int64" = x""yes; then
28395
28396 cat >>confdefs.h <<_ACEOF
28397 #define HAVE_INT64 1
28398 _ACEOF
28399
28400
28401 fi
28402 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
28403 $as_echo_n "checking for uint64... " >&6; }
28404 if test "${ac_cv_type_uint64+set}" = set; then
28405   $as_echo_n "(cached) " >&6
28406 else
28407   ac_cv_type_uint64=no
28408 cat >conftest.$ac_ext <<_ACEOF
28409 /* confdefs.h.  */
28410 _ACEOF
28411 cat confdefs.h >>conftest.$ac_ext
28412 cat >>conftest.$ac_ext <<_ACEOF
28413 /* end confdefs.h.  */
28414 #include <stdio.h>
28415
28416 int
28417 main ()
28418 {
28419 if (sizeof (uint64))
28420        return 0;
28421   ;
28422   return 0;
28423 }
28424 _ACEOF
28425 rm -f conftest.$ac_objext
28426 if { (ac_try="$ac_compile"
28427 case "(($ac_try" in
28428   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28429   *) ac_try_echo=$ac_try;;
28430 esac
28431 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28432 $as_echo "$ac_try_echo") >&5
28433   (eval "$ac_compile") 2>conftest.er1
28434   ac_status=$?
28435   grep -v '^ *+' conftest.er1 >conftest.err
28436   rm -f conftest.er1
28437   cat conftest.err >&5
28438   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28439   (exit $ac_status); } && {
28440          test -z "$ac_c_werror_flag" ||
28441          test ! -s conftest.err
28442        } && test -s conftest.$ac_objext; then
28443   cat >conftest.$ac_ext <<_ACEOF
28444 /* confdefs.h.  */
28445 _ACEOF
28446 cat confdefs.h >>conftest.$ac_ext
28447 cat >>conftest.$ac_ext <<_ACEOF
28448 /* end confdefs.h.  */
28449 #include <stdio.h>
28450
28451 int
28452 main ()
28453 {
28454 if (sizeof ((uint64)))
28455           return 0;
28456   ;
28457   return 0;
28458 }
28459 _ACEOF
28460 rm -f conftest.$ac_objext
28461 if { (ac_try="$ac_compile"
28462 case "(($ac_try" in
28463   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28464   *) ac_try_echo=$ac_try;;
28465 esac
28466 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28467 $as_echo "$ac_try_echo") >&5
28468   (eval "$ac_compile") 2>conftest.er1
28469   ac_status=$?
28470   grep -v '^ *+' conftest.er1 >conftest.err
28471   rm -f conftest.er1
28472   cat conftest.err >&5
28473   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28474   (exit $ac_status); } && {
28475          test -z "$ac_c_werror_flag" ||
28476          test ! -s conftest.err
28477        } && test -s conftest.$ac_objext; then
28478   :
28479 else
28480   $as_echo "$as_me: failed program was:" >&5
28481 sed 's/^/| /' conftest.$ac_ext >&5
28482
28483         ac_cv_type_uint64=yes
28484 fi
28485
28486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28487 else
28488   $as_echo "$as_me: failed program was:" >&5
28489 sed 's/^/| /' conftest.$ac_ext >&5
28490
28491
28492 fi
28493
28494 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28495 fi
28496 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
28497 $as_echo "$ac_cv_type_uint64" >&6; }
28498 if test "x$ac_cv_type_uint64" = x""yes; then
28499
28500 cat >>confdefs.h <<_ACEOF
28501 #define HAVE_UINT64 1
28502 _ACEOF
28503
28504
28505 fi
28506
28507
28508 # We also check for sig_atomic_t, which *should* be defined per ANSI
28509 # C, but is missing on some old platforms.
28510 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
28511 $as_echo_n "checking for sig_atomic_t... " >&6; }
28512 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
28513   $as_echo_n "(cached) " >&6
28514 else
28515   ac_cv_type_sig_atomic_t=no
28516 cat >conftest.$ac_ext <<_ACEOF
28517 /* confdefs.h.  */
28518 _ACEOF
28519 cat confdefs.h >>conftest.$ac_ext
28520 cat >>conftest.$ac_ext <<_ACEOF
28521 /* end confdefs.h.  */
28522 #include <signal.h>
28523
28524 int
28525 main ()
28526 {
28527 if (sizeof (sig_atomic_t))
28528        return 0;
28529   ;
28530   return 0;
28531 }
28532 _ACEOF
28533 rm -f conftest.$ac_objext
28534 if { (ac_try="$ac_compile"
28535 case "(($ac_try" in
28536   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28537   *) ac_try_echo=$ac_try;;
28538 esac
28539 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28540 $as_echo "$ac_try_echo") >&5
28541   (eval "$ac_compile") 2>conftest.er1
28542   ac_status=$?
28543   grep -v '^ *+' conftest.er1 >conftest.err
28544   rm -f conftest.er1
28545   cat conftest.err >&5
28546   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28547   (exit $ac_status); } && {
28548          test -z "$ac_c_werror_flag" ||
28549          test ! -s conftest.err
28550        } && test -s conftest.$ac_objext; then
28551   cat >conftest.$ac_ext <<_ACEOF
28552 /* confdefs.h.  */
28553 _ACEOF
28554 cat confdefs.h >>conftest.$ac_ext
28555 cat >>conftest.$ac_ext <<_ACEOF
28556 /* end confdefs.h.  */
28557 #include <signal.h>
28558
28559 int
28560 main ()
28561 {
28562 if (sizeof ((sig_atomic_t)))
28563           return 0;
28564   ;
28565   return 0;
28566 }
28567 _ACEOF
28568 rm -f conftest.$ac_objext
28569 if { (ac_try="$ac_compile"
28570 case "(($ac_try" in
28571   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28572   *) ac_try_echo=$ac_try;;
28573 esac
28574 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28575 $as_echo "$ac_try_echo") >&5
28576   (eval "$ac_compile") 2>conftest.er1
28577   ac_status=$?
28578   grep -v '^ *+' conftest.er1 >conftest.err
28579   rm -f conftest.er1
28580   cat conftest.err >&5
28581   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28582   (exit $ac_status); } && {
28583          test -z "$ac_c_werror_flag" ||
28584          test ! -s conftest.err
28585        } && test -s conftest.$ac_objext; then
28586   :
28587 else
28588   $as_echo "$as_me: failed program was:" >&5
28589 sed 's/^/| /' conftest.$ac_ext >&5
28590
28591         ac_cv_type_sig_atomic_t=yes
28592 fi
28593
28594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28595 else
28596   $as_echo "$as_me: failed program was:" >&5
28597 sed 's/^/| /' conftest.$ac_ext >&5
28598
28599
28600 fi
28601
28602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28603 fi
28604 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
28605 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
28606 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
28607
28608 cat >>confdefs.h <<_ACEOF
28609 #define HAVE_SIG_ATOMIC_T 1
28610 _ACEOF
28611
28612
28613 fi
28614
28615
28616
28617 if test "$PORTNAME" != "win32"
28618 then
28619 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
28620 $as_echo_n "checking for POSIX signal interface... " >&6; }
28621 if test "${pgac_cv_func_posix_signals+set}" = set; then
28622   $as_echo_n "(cached) " >&6
28623 else
28624   cat >conftest.$ac_ext <<_ACEOF
28625 /* confdefs.h.  */
28626 _ACEOF
28627 cat confdefs.h >>conftest.$ac_ext
28628 cat >>conftest.$ac_ext <<_ACEOF
28629 /* end confdefs.h.  */
28630 #include <signal.h>
28631
28632 int
28633 main ()
28634 {
28635 struct sigaction act, oact;
28636 sigemptyset(&act.sa_mask);
28637 act.sa_flags = SA_RESTART;
28638 sigaction(0, &act, &oact);
28639   ;
28640   return 0;
28641 }
28642 _ACEOF
28643 rm -f conftest.$ac_objext conftest$ac_exeext
28644 if { (ac_try="$ac_link"
28645 case "(($ac_try" in
28646   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28647   *) ac_try_echo=$ac_try;;
28648 esac
28649 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28650 $as_echo "$ac_try_echo") >&5
28651   (eval "$ac_link") 2>conftest.er1
28652   ac_status=$?
28653   grep -v '^ *+' conftest.er1 >conftest.err
28654   rm -f conftest.er1
28655   cat conftest.err >&5
28656   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28657   (exit $ac_status); } && {
28658          test -z "$ac_c_werror_flag" ||
28659          test ! -s conftest.err
28660        } && test -s conftest$ac_exeext && {
28661          test "$cross_compiling" = yes ||
28662          $as_test_x conftest$ac_exeext
28663        }; then
28664   pgac_cv_func_posix_signals=yes
28665 else
28666   $as_echo "$as_me: failed program was:" >&5
28667 sed 's/^/| /' conftest.$ac_ext >&5
28668
28669         pgac_cv_func_posix_signals=no
28670 fi
28671
28672 rm -rf conftest.dSYM
28673 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28674       conftest$ac_exeext conftest.$ac_ext
28675 fi
28676 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
28677 $as_echo "$pgac_cv_func_posix_signals" >&6; }
28678 if test x"$pgac_cv_func_posix_signals" = xyes ; then
28679
28680 cat >>confdefs.h <<\_ACEOF
28681 #define HAVE_POSIX_SIGNALS 1
28682 _ACEOF
28683
28684 fi
28685 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
28686
28687 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
28688   { { $as_echo "$as_me:$LINENO: error:
28689 Thread-safety requires POSIX signals, which are not supported by this
28690 operating system;  use --disable-thread-safety to disable thread safety." >&5
28691 $as_echo "$as_me: error:
28692 Thread-safety requires POSIX signals, which are not supported by this
28693 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
28694    { (exit 1); exit 1; }; }
28695 fi
28696 fi
28697
28698
28699 # Select semaphore implementation type.
28700 if test "$PORTNAME" != "win32"; then
28701   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
28702
28703 cat >>confdefs.h <<\_ACEOF
28704 #define USE_NAMED_POSIX_SEMAPHORES 1
28705 _ACEOF
28706
28707     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28708   else
28709     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
28710
28711 cat >>confdefs.h <<\_ACEOF
28712 #define USE_UNNAMED_POSIX_SEMAPHORES 1
28713 _ACEOF
28714
28715       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28716     else
28717
28718 cat >>confdefs.h <<\_ACEOF
28719 #define USE_SYSV_SEMAPHORES 1
28720 _ACEOF
28721
28722       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
28723     fi
28724   fi
28725 else
28726
28727 cat >>confdefs.h <<\_ACEOF
28728 #define USE_WIN32_SEMAPHORES 1
28729 _ACEOF
28730
28731   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
28732 fi
28733
28734
28735 # Select shared-memory implementation type.
28736 if test "$PORTNAME" != "win32"; then
28737
28738 cat >>confdefs.h <<\_ACEOF
28739 #define USE_SYSV_SHARED_MEMORY 1
28740 _ACEOF
28741
28742   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
28743 else
28744
28745 cat >>confdefs.h <<\_ACEOF
28746 #define USE_WIN32_SHARED_MEMORY 1
28747 _ACEOF
28748
28749   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
28750 fi
28751
28752 # Select latch implementation type.
28753 if test "$PORTNAME" != "win32"; then
28754   LATCH_IMPLEMENTATION="src/backend/port/unix_latch.c"
28755 else
28756   LATCH_IMPLEMENTATION="src/backend/port/win32_latch.c"
28757 fi
28758
28759 # If not set in template file, set bytes to use libc memset()
28760 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
28761   MEMSET_LOOP_LIMIT=1024
28762 fi
28763
28764 cat >>confdefs.h <<_ACEOF
28765 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
28766 _ACEOF
28767
28768
28769
28770 if test "$enable_nls" = yes ; then
28771
28772   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
28773 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
28774 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28775   $as_echo_n "(cached) " >&6
28776 else
28777   ac_func_search_save_LIBS=$LIBS
28778 cat >conftest.$ac_ext <<_ACEOF
28779 /* confdefs.h.  */
28780 _ACEOF
28781 cat confdefs.h >>conftest.$ac_ext
28782 cat >>conftest.$ac_ext <<_ACEOF
28783 /* end confdefs.h.  */
28784
28785 /* Override any GCC internal prototype to avoid an error.
28786    Use char because int might match the return type of a GCC
28787    builtin and then its argument prototype would still apply.  */
28788 #ifdef __cplusplus
28789 extern "C"
28790 #endif
28791 char bind_textdomain_codeset ();
28792 int
28793 main ()
28794 {
28795 return bind_textdomain_codeset ();
28796   ;
28797   return 0;
28798 }
28799 _ACEOF
28800 for ac_lib in '' intl; do
28801   if test -z "$ac_lib"; then
28802     ac_res="none required"
28803   else
28804     ac_res=-l$ac_lib
28805     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
28806   fi
28807   rm -f conftest.$ac_objext conftest$ac_exeext
28808 if { (ac_try="$ac_link"
28809 case "(($ac_try" in
28810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28811   *) ac_try_echo=$ac_try;;
28812 esac
28813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28814 $as_echo "$ac_try_echo") >&5
28815   (eval "$ac_link") 2>conftest.er1
28816   ac_status=$?
28817   grep -v '^ *+' conftest.er1 >conftest.err
28818   rm -f conftest.er1
28819   cat conftest.err >&5
28820   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28821   (exit $ac_status); } && {
28822          test -z "$ac_c_werror_flag" ||
28823          test ! -s conftest.err
28824        } && test -s conftest$ac_exeext && {
28825          test "$cross_compiling" = yes ||
28826          $as_test_x conftest$ac_exeext
28827        }; then
28828   ac_cv_search_bind_textdomain_codeset=$ac_res
28829 else
28830   $as_echo "$as_me: failed program was:" >&5
28831 sed 's/^/| /' conftest.$ac_ext >&5
28832
28833
28834 fi
28835
28836 rm -rf conftest.dSYM
28837 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28838       conftest$ac_exeext
28839   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28840   break
28841 fi
28842 done
28843 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28844   :
28845 else
28846   ac_cv_search_bind_textdomain_codeset=no
28847 fi
28848 rm conftest.$ac_ext
28849 LIBS=$ac_func_search_save_LIBS
28850 fi
28851 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
28852 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
28853 ac_res=$ac_cv_search_bind_textdomain_codeset
28854 if test "$ac_res" != no; then
28855   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28856
28857 else
28858   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
28859 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
28860    { (exit 1); exit 1; }; }
28861 fi
28862
28863   if test "${ac_cv_header_libintl_h+set}" = set; then
28864   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28865 $as_echo_n "checking for libintl.h... " >&6; }
28866 if test "${ac_cv_header_libintl_h+set}" = set; then
28867   $as_echo_n "(cached) " >&6
28868 fi
28869 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28870 $as_echo "$ac_cv_header_libintl_h" >&6; }
28871 else
28872   # Is the header compilable?
28873 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
28874 $as_echo_n "checking libintl.h usability... " >&6; }
28875 cat >conftest.$ac_ext <<_ACEOF
28876 /* confdefs.h.  */
28877 _ACEOF
28878 cat confdefs.h >>conftest.$ac_ext
28879 cat >>conftest.$ac_ext <<_ACEOF
28880 /* end confdefs.h.  */
28881 $ac_includes_default
28882 #include <libintl.h>
28883 _ACEOF
28884 rm -f conftest.$ac_objext
28885 if { (ac_try="$ac_compile"
28886 case "(($ac_try" in
28887   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28888   *) ac_try_echo=$ac_try;;
28889 esac
28890 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28891 $as_echo "$ac_try_echo") >&5
28892   (eval "$ac_compile") 2>conftest.er1
28893   ac_status=$?
28894   grep -v '^ *+' conftest.er1 >conftest.err
28895   rm -f conftest.er1
28896   cat conftest.err >&5
28897   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28898   (exit $ac_status); } && {
28899          test -z "$ac_c_werror_flag" ||
28900          test ! -s conftest.err
28901        } && test -s conftest.$ac_objext; then
28902   ac_header_compiler=yes
28903 else
28904   $as_echo "$as_me: failed program was:" >&5
28905 sed 's/^/| /' conftest.$ac_ext >&5
28906
28907         ac_header_compiler=no
28908 fi
28909
28910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28911 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28912 $as_echo "$ac_header_compiler" >&6; }
28913
28914 # Is the header present?
28915 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
28916 $as_echo_n "checking libintl.h presence... " >&6; }
28917 cat >conftest.$ac_ext <<_ACEOF
28918 /* confdefs.h.  */
28919 _ACEOF
28920 cat confdefs.h >>conftest.$ac_ext
28921 cat >>conftest.$ac_ext <<_ACEOF
28922 /* end confdefs.h.  */
28923 #include <libintl.h>
28924 _ACEOF
28925 if { (ac_try="$ac_cpp conftest.$ac_ext"
28926 case "(($ac_try" in
28927   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28928   *) ac_try_echo=$ac_try;;
28929 esac
28930 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28931 $as_echo "$ac_try_echo") >&5
28932   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28933   ac_status=$?
28934   grep -v '^ *+' conftest.er1 >conftest.err
28935   rm -f conftest.er1
28936   cat conftest.err >&5
28937   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28938   (exit $ac_status); } >/dev/null && {
28939          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28940          test ! -s conftest.err
28941        }; then
28942   ac_header_preproc=yes
28943 else
28944   $as_echo "$as_me: failed program was:" >&5
28945 sed 's/^/| /' conftest.$ac_ext >&5
28946
28947   ac_header_preproc=no
28948 fi
28949
28950 rm -f conftest.err conftest.$ac_ext
28951 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28952 $as_echo "$ac_header_preproc" >&6; }
28953
28954 # So?  What about this header?
28955 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28956   yes:no: )
28957     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28958 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28959     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
28960 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
28961     ac_header_preproc=yes
28962     ;;
28963   no:yes:* )
28964     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
28965 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
28966     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
28967 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
28968     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
28969 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
28970     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
28971 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28972     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
28973 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
28974     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
28975 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
28976     ( cat <<\_ASBOX
28977 ## ---------------------------------------- ##
28978 ## Report this to pgsql-bugs@postgresql.org ##
28979 ## ---------------------------------------- ##
28980 _ASBOX
28981      ) | sed "s/^/$as_me: WARNING:     /" >&2
28982     ;;
28983 esac
28984 { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28985 $as_echo_n "checking for libintl.h... " >&6; }
28986 if test "${ac_cv_header_libintl_h+set}" = set; then
28987   $as_echo_n "(cached) " >&6
28988 else
28989   ac_cv_header_libintl_h=$ac_header_preproc
28990 fi
28991 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28992 $as_echo "$ac_cv_header_libintl_h" >&6; }
28993
28994 fi
28995 if test "x$ac_cv_header_libintl_h" = x""yes; then
28996   :
28997 else
28998   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
28999 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
29000    { (exit 1); exit 1; }; }
29001 fi
29002
29003
29004   for ac_prog in msgfmt
29005 do
29006   # Extract the first word of "$ac_prog", so it can be a program name with args.
29007 set dummy $ac_prog; ac_word=$2
29008 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29009 $as_echo_n "checking for $ac_word... " >&6; }
29010 if test "${ac_cv_prog_MSGFMT+set}" = set; then
29011   $as_echo_n "(cached) " >&6
29012 else
29013   if test -n "$MSGFMT"; then
29014   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
29015 else
29016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29017 for as_dir in $PATH
29018 do
29019   IFS=$as_save_IFS
29020   test -z "$as_dir" && as_dir=.
29021   for ac_exec_ext in '' $ac_executable_extensions; do
29022   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29023     ac_cv_prog_MSGFMT="$ac_prog"
29024     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29025     break 2
29026   fi
29027 done
29028 done
29029 IFS=$as_save_IFS
29030
29031 fi
29032 fi
29033 MSGFMT=$ac_cv_prog_MSGFMT
29034 if test -n "$MSGFMT"; then
29035   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
29036 $as_echo "$MSGFMT" >&6; }
29037 else
29038   { $as_echo "$as_me:$LINENO: result: no" >&5
29039 $as_echo "no" >&6; }
29040 fi
29041
29042
29043   test -n "$MSGFMT" && break
29044 done
29045
29046   if test -z "$MSGFMT"; then
29047     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
29048 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
29049    { (exit 1); exit 1; }; }
29050   fi
29051   { $as_echo "$as_me:$LINENO: checking for msgfmt flags" >&5
29052 $as_echo_n "checking for msgfmt flags... " >&6; }
29053 if test "${pgac_cv_msgfmt_flags+set}" = set; then
29054   $as_echo_n "(cached) " >&6
29055 else
29056   if test x"$MSGFMT" != x"" && "$MSGFMT" --version 2>&1 | grep "GNU" >/dev/null; then
29057     pgac_cv_msgfmt_flags=-c
29058 fi
29059 fi
29060 { $as_echo "$as_me:$LINENO: result: $pgac_cv_msgfmt_flags" >&5
29061 $as_echo "$pgac_cv_msgfmt_flags" >&6; }
29062   MSGFMT_FLAGS=$pgac_cv_msgfmt_flags
29063
29064   for ac_prog in msgmerge
29065 do
29066   # Extract the first word of "$ac_prog", so it can be a program name with args.
29067 set dummy $ac_prog; ac_word=$2
29068 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29069 $as_echo_n "checking for $ac_word... " >&6; }
29070 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
29071   $as_echo_n "(cached) " >&6
29072 else
29073   if test -n "$MSGMERGE"; then
29074   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
29075 else
29076 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29077 for as_dir in $PATH
29078 do
29079   IFS=$as_save_IFS
29080   test -z "$as_dir" && as_dir=.
29081   for ac_exec_ext in '' $ac_executable_extensions; do
29082   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29083     ac_cv_prog_MSGMERGE="$ac_prog"
29084     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29085     break 2
29086   fi
29087 done
29088 done
29089 IFS=$as_save_IFS
29090
29091 fi
29092 fi
29093 MSGMERGE=$ac_cv_prog_MSGMERGE
29094 if test -n "$MSGMERGE"; then
29095   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
29096 $as_echo "$MSGMERGE" >&6; }
29097 else
29098   { $as_echo "$as_me:$LINENO: result: no" >&5
29099 $as_echo "no" >&6; }
29100 fi
29101
29102
29103   test -n "$MSGMERGE" && break
29104 done
29105
29106   for ac_prog in xgettext
29107 do
29108   # Extract the first word of "$ac_prog", so it can be a program name with args.
29109 set dummy $ac_prog; ac_word=$2
29110 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29111 $as_echo_n "checking for $ac_word... " >&6; }
29112 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
29113   $as_echo_n "(cached) " >&6
29114 else
29115   if test -n "$XGETTEXT"; then
29116   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
29117 else
29118 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29119 for as_dir in $PATH
29120 do
29121   IFS=$as_save_IFS
29122   test -z "$as_dir" && as_dir=.
29123   for ac_exec_ext in '' $ac_executable_extensions; do
29124   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29125     ac_cv_prog_XGETTEXT="$ac_prog"
29126     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29127     break 2
29128   fi
29129 done
29130 done
29131 IFS=$as_save_IFS
29132
29133 fi
29134 fi
29135 XGETTEXT=$ac_cv_prog_XGETTEXT
29136 if test -n "$XGETTEXT"; then
29137   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
29138 $as_echo "$XGETTEXT" >&6; }
29139 else
29140   { $as_echo "$as_me:$LINENO: result: no" >&5
29141 $as_echo "no" >&6; }
29142 fi
29143
29144
29145   test -n "$XGETTEXT" && break
29146 done
29147
29148
29149 fi
29150
29151 # Check for Tcl configuration script tclConfig.sh
29152 if test "$with_tcl" = yes; then
29153     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
29154 do
29155   # Extract the first word of "$ac_prog", so it can be a program name with args.
29156 set dummy $ac_prog; ac_word=$2
29157 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29158 $as_echo_n "checking for $ac_word... " >&6; }
29159 if test "${ac_cv_path_TCLSH+set}" = set; then
29160   $as_echo_n "(cached) " >&6
29161 else
29162   case $TCLSH in
29163   [\\/]* | ?:[\\/]*)
29164   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
29165   ;;
29166   *)
29167   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29168 for as_dir in $PATH
29169 do
29170   IFS=$as_save_IFS
29171   test -z "$as_dir" && as_dir=.
29172   for ac_exec_ext in '' $ac_executable_extensions; do
29173   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29174     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
29175     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29176     break 2
29177   fi
29178 done
29179 done
29180 IFS=$as_save_IFS
29181
29182   ;;
29183 esac
29184 fi
29185 TCLSH=$ac_cv_path_TCLSH
29186 if test -n "$TCLSH"; then
29187   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
29188 $as_echo "$TCLSH" >&6; }
29189 else
29190   { $as_echo "$as_me:$LINENO: result: no" >&5
29191 $as_echo "no" >&6; }
29192 fi
29193
29194
29195   test -n "$TCLSH" && break
29196 done
29197
29198 if test x"$TCLSH" = x""; then
29199   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
29200 $as_echo "$as_me: error: Tcl shell not found" >&2;}
29201    { (exit 1); exit 1; }; }
29202 fi
29203
29204 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
29205 $as_echo_n "checking for tclConfig.sh... " >&6; }
29206 # Let user override test
29207 if test -z "$TCL_CONFIG_SH"; then
29208     pgac_test_dirs="$with_tclconfig"
29209
29210     set X $pgac_test_dirs; shift
29211     if test $# -eq 0; then
29212         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
29213 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
29214    { (exit 1); exit 1; }; }
29215         set X `echo 'puts $auto_path' | $TCLSH`; shift
29216     fi
29217
29218     for pgac_dir do
29219         if test -r "$pgac_dir/tclConfig.sh"; then
29220             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
29221             break
29222         fi
29223     done
29224 fi
29225
29226 if test -z "$TCL_CONFIG_SH"; then
29227     { $as_echo "$as_me:$LINENO: result: no" >&5
29228 $as_echo "no" >&6; }
29229     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
29230 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
29231    { (exit 1); exit 1; }; }
29232 else
29233     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
29234 $as_echo "$TCL_CONFIG_SH" >&6; }
29235 fi
29236
29237
29238
29239     . "$TCL_CONFIG_SH"
29240 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
29241 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
29242 eval TCL_LIBS=\"$TCL_LIBS\"
29243 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
29244 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
29245
29246         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
29247     ac_save_CPPFLAGS=$CPPFLAGS
29248     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
29249     if test "${ac_cv_header_tcl_h+set}" = set; then
29250   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
29251 $as_echo_n "checking for tcl.h... " >&6; }
29252 if test "${ac_cv_header_tcl_h+set}" = set; then
29253   $as_echo_n "(cached) " >&6
29254 fi
29255 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
29256 $as_echo "$ac_cv_header_tcl_h" >&6; }
29257 else
29258   # Is the header compilable?
29259 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
29260 $as_echo_n "checking tcl.h usability... " >&6; }
29261 cat >conftest.$ac_ext <<_ACEOF
29262 /* confdefs.h.  */
29263 _ACEOF
29264 cat confdefs.h >>conftest.$ac_ext
29265 cat >>conftest.$ac_ext <<_ACEOF
29266 /* end confdefs.h.  */
29267 $ac_includes_default
29268 #include <tcl.h>
29269 _ACEOF
29270 rm -f conftest.$ac_objext
29271 if { (ac_try="$ac_compile"
29272 case "(($ac_try" in
29273   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29274   *) ac_try_echo=$ac_try;;
29275 esac
29276 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29277 $as_echo "$ac_try_echo") >&5
29278   (eval "$ac_compile") 2>conftest.er1
29279   ac_status=$?
29280   grep -v '^ *+' conftest.er1 >conftest.err
29281   rm -f conftest.er1
29282   cat conftest.err >&5
29283   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29284   (exit $ac_status); } && {
29285          test -z "$ac_c_werror_flag" ||
29286          test ! -s conftest.err
29287        } && test -s conftest.$ac_objext; then
29288   ac_header_compiler=yes
29289 else
29290   $as_echo "$as_me: failed program was:" >&5
29291 sed 's/^/| /' conftest.$ac_ext >&5
29292
29293         ac_header_compiler=no
29294 fi
29295
29296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29297 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29298 $as_echo "$ac_header_compiler" >&6; }
29299
29300 # Is the header present?
29301 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
29302 $as_echo_n "checking tcl.h presence... " >&6; }
29303 cat >conftest.$ac_ext <<_ACEOF
29304 /* confdefs.h.  */
29305 _ACEOF
29306 cat confdefs.h >>conftest.$ac_ext
29307 cat >>conftest.$ac_ext <<_ACEOF
29308 /* end confdefs.h.  */
29309 #include <tcl.h>
29310 _ACEOF
29311 if { (ac_try="$ac_cpp conftest.$ac_ext"
29312 case "(($ac_try" in
29313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29314   *) ac_try_echo=$ac_try;;
29315 esac
29316 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29317 $as_echo "$ac_try_echo") >&5
29318   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
29319   ac_status=$?
29320   grep -v '^ *+' conftest.er1 >conftest.err
29321   rm -f conftest.er1
29322   cat conftest.err >&5
29323   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29324   (exit $ac_status); } >/dev/null && {
29325          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
29326          test ! -s conftest.err
29327        }; then
29328   ac_header_preproc=yes
29329 else
29330   $as_echo "$as_me: failed program was:" >&5
29331 sed 's/^/| /' conftest.$ac_ext >&5
29332
29333   ac_header_preproc=no
29334 fi
29335
29336 rm -f conftest.err conftest.$ac_ext
29337 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29338 $as_echo "$ac_header_preproc" >&6; }
29339
29340 # So?  What about this header?
29341 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
29342   yes:no: )
29343     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
29344 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
29345     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
29346 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
29347     ac_header_preproc=yes
29348     ;;
29349   no:yes:* )
29350     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
29351 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
29352     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
29353 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
29354     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
29355 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
29356     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
29357 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
29358     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
29359 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
29360     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
29361 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
29362     ( cat <<\_ASBOX
29363 ## ---------------------------------------- ##
29364 ## Report this to pgsql-bugs@postgresql.org ##
29365 ## ---------------------------------------- ##
29366 _ASBOX
29367      ) | sed "s/^/$as_me: WARNING:     /" >&2
29368     ;;
29369 esac
29370 { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
29371 $as_echo_n "checking for tcl.h... " >&6; }
29372 if test "${ac_cv_header_tcl_h+set}" = set; then
29373   $as_echo_n "(cached) " >&6
29374 else
29375   ac_cv_header_tcl_h=$ac_header_preproc
29376 fi
29377 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
29378 $as_echo "$ac_cv_header_tcl_h" >&6; }
29379
29380 fi
29381 if test "x$ac_cv_header_tcl_h" = x""yes; then
29382   :
29383 else
29384   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
29385 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
29386    { (exit 1); exit 1; }; }
29387 fi
29388
29389
29390     CPPFLAGS=$ac_save_CPPFLAGS
29391 fi
29392
29393 # check for <perl.h>
29394 if test "$with_perl" = yes; then
29395   ac_save_CPPFLAGS=$CPPFLAGS
29396   CPPFLAGS="$CPPFLAGS -I$perl_archlibexp/CORE"
29397   { $as_echo "$as_me:$LINENO: checking for perl.h" >&5
29398 $as_echo_n "checking for perl.h... " >&6; }
29399 if test "${ac_cv_header_perl_h+set}" = set; then
29400   $as_echo_n "(cached) " >&6
29401 else
29402   cat >conftest.$ac_ext <<_ACEOF
29403 /* confdefs.h.  */
29404 _ACEOF
29405 cat confdefs.h >>conftest.$ac_ext
29406 cat >>conftest.$ac_ext <<_ACEOF
29407 /* end confdefs.h.  */
29408 #include <EXTERN.h>
29409
29410 #include <perl.h>
29411 _ACEOF
29412 rm -f conftest.$ac_objext
29413 if { (ac_try="$ac_compile"
29414 case "(($ac_try" in
29415   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29416   *) ac_try_echo=$ac_try;;
29417 esac
29418 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29419 $as_echo "$ac_try_echo") >&5
29420   (eval "$ac_compile") 2>conftest.er1
29421   ac_status=$?
29422   grep -v '^ *+' conftest.er1 >conftest.err
29423   rm -f conftest.er1
29424   cat conftest.err >&5
29425   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29426   (exit $ac_status); } && {
29427          test -z "$ac_c_werror_flag" ||
29428          test ! -s conftest.err
29429        } && test -s conftest.$ac_objext; then
29430   ac_cv_header_perl_h=yes
29431 else
29432   $as_echo "$as_me: failed program was:" >&5
29433 sed 's/^/| /' conftest.$ac_ext >&5
29434
29435         ac_cv_header_perl_h=no
29436 fi
29437
29438 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29439 fi
29440 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_perl_h" >&5
29441 $as_echo "$ac_cv_header_perl_h" >&6; }
29442 if test "x$ac_cv_header_perl_h" = x""yes; then
29443   :
29444 else
29445   { { $as_echo "$as_me:$LINENO: error: header file <perl.h> is required for Perl" >&5
29446 $as_echo "$as_me: error: header file <perl.h> is required for Perl" >&2;}
29447    { (exit 1); exit 1; }; }
29448 fi
29449
29450
29451   # While we're at it, check that we can link to libperl.
29452   # On most platforms, if perl.h is there then libperl.so will be too, but at
29453   # this writing Debian packages them separately.  There is no known reason to
29454   # waste cycles on separate probes for the Tcl or Python libraries, though.
29455   pgac_save_LIBS=$LIBS
29456   LIBS="$perl_embed_ldflags"
29457   { $as_echo "$as_me:$LINENO: checking for libperl" >&5
29458 $as_echo_n "checking for libperl... " >&6; }
29459   cat >conftest.$ac_ext <<_ACEOF
29460 /* confdefs.h.  */
29461 _ACEOF
29462 cat confdefs.h >>conftest.$ac_ext
29463 cat >>conftest.$ac_ext <<_ACEOF
29464 /* end confdefs.h.  */
29465
29466 #include <EXTERN.h>
29467 #include <perl.h>
29468
29469 int
29470 main ()
29471 {
29472 perl_alloc();
29473   ;
29474   return 0;
29475 }
29476 _ACEOF
29477 rm -f conftest.$ac_objext conftest$ac_exeext
29478 if { (ac_try="$ac_link"
29479 case "(($ac_try" in
29480   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29481   *) ac_try_echo=$ac_try;;
29482 esac
29483 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29484 $as_echo "$ac_try_echo") >&5
29485   (eval "$ac_link") 2>conftest.er1
29486   ac_status=$?
29487   grep -v '^ *+' conftest.er1 >conftest.err
29488   rm -f conftest.er1
29489   cat conftest.err >&5
29490   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29491   (exit $ac_status); } && {
29492          test -z "$ac_c_werror_flag" ||
29493          test ! -s conftest.err
29494        } && test -s conftest$ac_exeext && {
29495          test "$cross_compiling" = yes ||
29496          $as_test_x conftest$ac_exeext
29497        }; then
29498   { $as_echo "$as_me:$LINENO: result: yes" >&5
29499 $as_echo "yes" >&6; }
29500 else
29501   $as_echo "$as_me: failed program was:" >&5
29502 sed 's/^/| /' conftest.$ac_ext >&5
29503
29504         { $as_echo "$as_me:$LINENO: result: no" >&5
29505 $as_echo "no" >&6; }
29506      { { $as_echo "$as_me:$LINENO: error: libperl library is required for Perl" >&5
29507 $as_echo "$as_me: error: libperl library is required for Perl" >&2;}
29508    { (exit 1); exit 1; }; }
29509 fi
29510
29511 rm -rf conftest.dSYM
29512 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
29513       conftest$ac_exeext conftest.$ac_ext
29514   LIBS=$pgac_save_LIBS
29515   CPPFLAGS=$ac_save_CPPFLAGS
29516 fi
29517
29518 # check for <Python.h>
29519 if test "$with_python" = yes; then
29520   ac_save_CPPFLAGS=$CPPFLAGS
29521   CPPFLAGS="$python_includespec $CPPFLAGS"
29522   if test "${ac_cv_header_Python_h+set}" = set; then
29523   { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
29524 $as_echo_n "checking for Python.h... " >&6; }
29525 if test "${ac_cv_header_Python_h+set}" = set; then
29526   $as_echo_n "(cached) " >&6
29527 fi
29528 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
29529 $as_echo "$ac_cv_header_Python_h" >&6; }
29530 else
29531   # Is the header compilable?
29532 { $as_echo "$as_me:$LINENO: checking Python.h usability" >&5
29533 $as_echo_n "checking Python.h usability... " >&6; }
29534 cat >conftest.$ac_ext <<_ACEOF
29535 /* confdefs.h.  */
29536 _ACEOF
29537 cat confdefs.h >>conftest.$ac_ext
29538 cat >>conftest.$ac_ext <<_ACEOF
29539 /* end confdefs.h.  */
29540 $ac_includes_default
29541 #include <Python.h>
29542 _ACEOF
29543 rm -f conftest.$ac_objext
29544 if { (ac_try="$ac_compile"
29545 case "(($ac_try" in
29546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29547   *) ac_try_echo=$ac_try;;
29548 esac
29549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29550 $as_echo "$ac_try_echo") >&5
29551   (eval "$ac_compile") 2>conftest.er1
29552   ac_status=$?
29553   grep -v '^ *+' conftest.er1 >conftest.err
29554   rm -f conftest.er1
29555   cat conftest.err >&5
29556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29557   (exit $ac_status); } && {
29558          test -z "$ac_c_werror_flag" ||
29559          test ! -s conftest.err
29560        } && test -s conftest.$ac_objext; then
29561   ac_header_compiler=yes
29562 else
29563   $as_echo "$as_me: failed program was:" >&5
29564 sed 's/^/| /' conftest.$ac_ext >&5
29565
29566         ac_header_compiler=no
29567 fi
29568
29569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29570 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29571 $as_echo "$ac_header_compiler" >&6; }
29572
29573 # Is the header present?
29574 { $as_echo "$as_me:$LINENO: checking Python.h presence" >&5
29575 $as_echo_n "checking Python.h presence... " >&6; }
29576 cat >conftest.$ac_ext <<_ACEOF
29577 /* confdefs.h.  */
29578 _ACEOF
29579 cat confdefs.h >>conftest.$ac_ext
29580 cat >>conftest.$ac_ext <<_ACEOF
29581 /* end confdefs.h.  */
29582 #include <Python.h>
29583 _ACEOF
29584 if { (ac_try="$ac_cpp conftest.$ac_ext"
29585 case "(($ac_try" in
29586   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29587   *) ac_try_echo=$ac_try;;
29588 esac
29589 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29590 $as_echo "$ac_try_echo") >&5
29591   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
29592   ac_status=$?
29593   grep -v '^ *+' conftest.er1 >conftest.err
29594   rm -f conftest.er1
29595   cat conftest.err >&5
29596   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29597   (exit $ac_status); } >/dev/null && {
29598          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
29599          test ! -s conftest.err
29600        }; then
29601   ac_header_preproc=yes
29602 else
29603   $as_echo "$as_me: failed program was:" >&5
29604 sed 's/^/| /' conftest.$ac_ext >&5
29605
29606   ac_header_preproc=no
29607 fi
29608
29609 rm -f conftest.err conftest.$ac_ext
29610 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29611 $as_echo "$ac_header_preproc" >&6; }
29612
29613 # So?  What about this header?
29614 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
29615   yes:no: )
29616     { $as_echo "$as_me:$LINENO: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&5
29617 $as_echo "$as_me: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
29618     { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the compiler's result" >&5
29619 $as_echo "$as_me: WARNING: Python.h: proceeding with the compiler's result" >&2;}
29620     ac_header_preproc=yes
29621     ;;
29622   no:yes:* )
29623     { $as_echo "$as_me:$LINENO: WARNING: Python.h: present but cannot be compiled" >&5
29624 $as_echo "$as_me: WARNING: Python.h: present but cannot be compiled" >&2;}
29625     { $as_echo "$as_me:$LINENO: WARNING: Python.h:     check for missing prerequisite headers?" >&5
29626 $as_echo "$as_me: WARNING: Python.h:     check for missing prerequisite headers?" >&2;}
29627     { $as_echo "$as_me:$LINENO: WARNING: Python.h: see the Autoconf documentation" >&5
29628 $as_echo "$as_me: WARNING: Python.h: see the Autoconf documentation" >&2;}
29629     { $as_echo "$as_me:$LINENO: WARNING: Python.h:     section \"Present But Cannot Be Compiled\"" >&5
29630 $as_echo "$as_me: WARNING: Python.h:     section \"Present But Cannot Be Compiled\"" >&2;}
29631     { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the preprocessor's result" >&5
29632 $as_echo "$as_me: WARNING: Python.h: proceeding with the preprocessor's result" >&2;}
29633     { $as_echo "$as_me:$LINENO: WARNING: Python.h: in the future, the compiler will take precedence" >&5
29634 $as_echo "$as_me: WARNING: Python.h: in the future, the compiler will take precedence" >&2;}
29635     ( cat <<\_ASBOX
29636 ## ---------------------------------------- ##
29637 ## Report this to pgsql-bugs@postgresql.org ##
29638 ## ---------------------------------------- ##
29639 _ASBOX
29640      ) | sed "s/^/$as_me: WARNING:     /" >&2
29641     ;;
29642 esac
29643 { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
29644 $as_echo_n "checking for Python.h... " >&6; }
29645 if test "${ac_cv_header_Python_h+set}" = set; then
29646   $as_echo_n "(cached) " >&6
29647 else
29648   ac_cv_header_Python_h=$ac_header_preproc
29649 fi
29650 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
29651 $as_echo "$ac_cv_header_Python_h" >&6; }
29652
29653 fi
29654 if test "x$ac_cv_header_Python_h" = x""yes; then
29655   :
29656 else
29657   { { $as_echo "$as_me:$LINENO: error: header file <Python.h> is required for Python" >&5
29658 $as_echo "$as_me: error: header file <Python.h> is required for Python" >&2;}
29659    { (exit 1); exit 1; }; }
29660 fi
29661
29662
29663   CPPFLAGS=$ac_save_CPPFLAGS
29664 fi
29665
29666 #
29667 # Check for DocBook and tools
29668 #
29669 for ac_prog in onsgmls nsgmls
29670 do
29671   # Extract the first word of "$ac_prog", so it can be a program name with args.
29672 set dummy $ac_prog; ac_word=$2
29673 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29674 $as_echo_n "checking for $ac_word... " >&6; }
29675 if test "${ac_cv_prog_NSGMLS+set}" = set; then
29676   $as_echo_n "(cached) " >&6
29677 else
29678   if test -n "$NSGMLS"; then
29679   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
29680 else
29681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29682 for as_dir in $PATH
29683 do
29684   IFS=$as_save_IFS
29685   test -z "$as_dir" && as_dir=.
29686   for ac_exec_ext in '' $ac_executable_extensions; do
29687   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29688     ac_cv_prog_NSGMLS="$ac_prog"
29689     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29690     break 2
29691   fi
29692 done
29693 done
29694 IFS=$as_save_IFS
29695
29696 fi
29697 fi
29698 NSGMLS=$ac_cv_prog_NSGMLS
29699 if test -n "$NSGMLS"; then
29700   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
29701 $as_echo "$NSGMLS" >&6; }
29702 else
29703   { $as_echo "$as_me:$LINENO: result: no" >&5
29704 $as_echo "no" >&6; }
29705 fi
29706
29707
29708   test -n "$NSGMLS" && break
29709 done
29710
29711 for ac_prog in openjade jade
29712 do
29713   # Extract the first word of "$ac_prog", so it can be a program name with args.
29714 set dummy $ac_prog; ac_word=$2
29715 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29716 $as_echo_n "checking for $ac_word... " >&6; }
29717 if test "${ac_cv_prog_JADE+set}" = set; then
29718   $as_echo_n "(cached) " >&6
29719 else
29720   if test -n "$JADE"; then
29721   ac_cv_prog_JADE="$JADE" # Let the user override the test.
29722 else
29723 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29724 for as_dir in $PATH
29725 do
29726   IFS=$as_save_IFS
29727   test -z "$as_dir" && as_dir=.
29728   for ac_exec_ext in '' $ac_executable_extensions; do
29729   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29730     ac_cv_prog_JADE="$ac_prog"
29731     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29732     break 2
29733   fi
29734 done
29735 done
29736 IFS=$as_save_IFS
29737
29738 fi
29739 fi
29740 JADE=$ac_cv_prog_JADE
29741 if test -n "$JADE"; then
29742   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
29743 $as_echo "$JADE" >&6; }
29744 else
29745   { $as_echo "$as_me:$LINENO: result: no" >&5
29746 $as_echo "no" >&6; }
29747 fi
29748
29749
29750   test -n "$JADE" && break
29751 done
29752
29753
29754 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
29755 $as_echo_n "checking for DocBook V4.2... " >&6; }
29756 if test "${pgac_cv_check_docbook+set}" = set; then
29757   $as_echo_n "(cached) " >&6
29758 else
29759   cat >conftest.sgml <<EOF
29760 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
29761 <book>
29762  <title>test</title>
29763  <chapter>
29764   <title>random</title>
29765    <sect1>
29766     <title>testsect</title>
29767     <para>text</para>
29768   </sect1>
29769  </chapter>
29770 </book>
29771 EOF
29772
29773 pgac_cv_check_docbook=no
29774
29775 if test -n "$NSGMLS"; then
29776   $NSGMLS -s conftest.sgml 1>&5 2>&1
29777   if test $? -eq 0; then
29778     pgac_cv_check_docbook=yes
29779   fi
29780 fi
29781 rm -f conftest.sgml
29782 fi
29783 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
29784 $as_echo "$pgac_cv_check_docbook" >&6; }
29785
29786 have_docbook=$pgac_cv_check_docbook
29787
29788
29789 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
29790 $as_echo_n "checking for DocBook stylesheets... " >&6; }
29791 if test "${pgac_cv_path_stylesheets+set}" = set; then
29792   $as_echo_n "(cached) " >&6
29793 else
29794   if test -n "$DOCBOOKSTYLE"; then
29795   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
29796 else
29797   for pgac_prefix in /usr /usr/local /opt /sw; do
29798     for pgac_infix in share lib; do
29799       for pgac_postfix in \
29800         sgml/stylesheets/nwalsh-modular \
29801         sgml/stylesheets/docbook \
29802         sgml/stylesheets/dsssl/docbook \
29803         sgml/docbook-dsssl \
29804         sgml/docbook/dsssl/modular \
29805         sgml/docbook/stylesheet/dsssl/modular \
29806         sgml/docbook/dsssl-stylesheets \
29807         sgml/dsssl/docbook-dsssl-nwalsh
29808       do
29809         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
29810         if test -r "$pgac_candidate/html/docbook.dsl" \
29811            && test -r "$pgac_candidate/print/docbook.dsl"
29812         then
29813           pgac_cv_path_stylesheets=$pgac_candidate
29814           break 3
29815         fi
29816       done
29817     done
29818   done
29819 fi
29820 fi
29821
29822 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
29823
29824 if test -n "$DOCBOOKSTYLE"; then
29825   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
29826 $as_echo "$DOCBOOKSTYLE" >&6; }
29827 else
29828   { $as_echo "$as_me:$LINENO: result: no" >&5
29829 $as_echo "no" >&6; }
29830 fi
29831 if test -n "$DOCBOOKSTYLE" -a -r "$DOCBOOKSTYLE/bin/collateindex.pl"; then
29832   COLLATEINDEX="$DOCBOOKSTYLE/bin/collateindex.pl"
29833
29834 else
29835   # Extract the first word of "collateindex.pl", so it can be a program name with args.
29836 set dummy collateindex.pl; ac_word=$2
29837 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29838 $as_echo_n "checking for $ac_word... " >&6; }
29839 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
29840   $as_echo_n "(cached) " >&6
29841 else
29842   case $COLLATEINDEX in
29843   [\\/]* | ?:[\\/]*)
29844   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
29845   ;;
29846   *)
29847   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29848 for as_dir in $PATH
29849 do
29850   IFS=$as_save_IFS
29851   test -z "$as_dir" && as_dir=.
29852   for ac_exec_ext in '' $ac_executable_extensions; do
29853   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29854     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
29855     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29856     break 2
29857   fi
29858 done
29859 done
29860 IFS=$as_save_IFS
29861
29862   ;;
29863 esac
29864 fi
29865 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
29866 if test -n "$COLLATEINDEX"; then
29867   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
29868 $as_echo "$COLLATEINDEX" >&6; }
29869 else
29870   { $as_echo "$as_me:$LINENO: result: no" >&5
29871 $as_echo "no" >&6; }
29872 fi
29873
29874
29875 fi
29876 for ac_prog in xsltproc
29877 do
29878   # Extract the first word of "$ac_prog", so it can be a program name with args.
29879 set dummy $ac_prog; ac_word=$2
29880 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29881 $as_echo_n "checking for $ac_word... " >&6; }
29882 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
29883   $as_echo_n "(cached) " >&6
29884 else
29885   if test -n "$XSLTPROC"; then
29886   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
29887 else
29888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29889 for as_dir in $PATH
29890 do
29891   IFS=$as_save_IFS
29892   test -z "$as_dir" && as_dir=.
29893   for ac_exec_ext in '' $ac_executable_extensions; do
29894   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29895     ac_cv_prog_XSLTPROC="$ac_prog"
29896     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29897     break 2
29898   fi
29899 done
29900 done
29901 IFS=$as_save_IFS
29902
29903 fi
29904 fi
29905 XSLTPROC=$ac_cv_prog_XSLTPROC
29906 if test -n "$XSLTPROC"; then
29907   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
29908 $as_echo "$XSLTPROC" >&6; }
29909 else
29910   { $as_echo "$as_me:$LINENO: result: no" >&5
29911 $as_echo "no" >&6; }
29912 fi
29913
29914
29915   test -n "$XSLTPROC" && break
29916 done
29917
29918 for ac_prog in osx sgml2xml sx
29919 do
29920   # Extract the first word of "$ac_prog", so it can be a program name with args.
29921 set dummy $ac_prog; ac_word=$2
29922 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29923 $as_echo_n "checking for $ac_word... " >&6; }
29924 if test "${ac_cv_prog_OSX+set}" = set; then
29925   $as_echo_n "(cached) " >&6
29926 else
29927   if test -n "$OSX"; then
29928   ac_cv_prog_OSX="$OSX" # Let the user override the test.
29929 else
29930 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29931 for as_dir in $PATH
29932 do
29933   IFS=$as_save_IFS
29934   test -z "$as_dir" && as_dir=.
29935   for ac_exec_ext in '' $ac_executable_extensions; do
29936   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29937     ac_cv_prog_OSX="$ac_prog"
29938     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29939     break 2
29940   fi
29941 done
29942 done
29943 IFS=$as_save_IFS
29944
29945 fi
29946 fi
29947 OSX=$ac_cv_prog_OSX
29948 if test -n "$OSX"; then
29949   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
29950 $as_echo "$OSX" >&6; }
29951 else
29952   { $as_echo "$as_me:$LINENO: result: no" >&5
29953 $as_echo "no" >&6; }
29954 fi
29955
29956
29957   test -n "$OSX" && break
29958 done
29959
29960
29961 # Thread testing
29962
29963 # We have to run the thread test near the end so we have all our symbols
29964 # defined.  Cross compiling throws a warning.
29965 #
29966 if test "$enable_thread_safety" = yes; then
29967 if test "$PORTNAME" != "win32"
29968 then
29969 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
29970 $as_echo_n "checking thread safety of required library functions... " >&6; }
29971
29972 _CFLAGS="$CFLAGS"
29973 _LIBS="$LIBS"
29974 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
29975 LIBS="$LIBS $PTHREAD_LIBS"
29976 if test "$cross_compiling" = yes; then
29977   { $as_echo "$as_me:$LINENO: result: maybe" >&5
29978 $as_echo "maybe" >&6; }
29979   { $as_echo "$as_me:$LINENO: WARNING:
29980 *** Skipping thread test program because of cross-compile build.
29981 *** Run the program in src/test/thread on the target machine.
29982 " >&5
29983 $as_echo "$as_me: WARNING:
29984 *** Skipping thread test program because of cross-compile build.
29985 *** Run the program in src/test/thread on the target machine.
29986 " >&2;}
29987 else
29988   cat >conftest.$ac_ext <<_ACEOF
29989 /* confdefs.h.  */
29990 _ACEOF
29991 cat confdefs.h >>conftest.$ac_ext
29992 cat >>conftest.$ac_ext <<_ACEOF
29993 /* end confdefs.h.  */
29994 #include "$srcdir/src/test/thread/thread_test.c"
29995 _ACEOF
29996 rm -f conftest$ac_exeext
29997 if { (ac_try="$ac_link"
29998 case "(($ac_try" in
29999   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30000   *) ac_try_echo=$ac_try;;
30001 esac
30002 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30003 $as_echo "$ac_try_echo") >&5
30004   (eval "$ac_link") 2>&5
30005   ac_status=$?
30006   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30007   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
30008   { (case "(($ac_try" in
30009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30010   *) ac_try_echo=$ac_try;;
30011 esac
30012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30013 $as_echo "$ac_try_echo") >&5
30014   (eval "$ac_try") 2>&5
30015   ac_status=$?
30016   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30017   (exit $ac_status); }; }; then
30018   { $as_echo "$as_me:$LINENO: result: yes" >&5
30019 $as_echo "yes" >&6; }
30020 else
30021   $as_echo "$as_me: program exited with status $ac_status" >&5
30022 $as_echo "$as_me: failed program was:" >&5
30023 sed 's/^/| /' conftest.$ac_ext >&5
30024
30025 ( exit $ac_status )
30026 { $as_echo "$as_me:$LINENO: result: no" >&5
30027 $as_echo "no" >&6; }
30028   { { $as_echo "$as_me:$LINENO: error: thread test program failed
30029 This platform is not thread-safe.  Check the file 'config.log' or compile
30030 and run src/test/thread/thread_test for the exact reason.
30031 Use --disable-thread-safety to disable thread safety." >&5
30032 $as_echo "$as_me: error: thread test program failed
30033 This platform is not thread-safe.  Check the file 'config.log' or compile
30034 and run src/test/thread/thread_test for the exact reason.
30035 Use --disable-thread-safety to disable thread safety." >&2;}
30036    { (exit 1); exit 1; }; }
30037 fi
30038 rm -rf conftest.dSYM
30039 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
30040 fi
30041
30042
30043 CFLAGS="$_CFLAGS"
30044 LIBS="$_LIBS"
30045 else
30046 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
30047 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
30048 fi
30049 fi
30050
30051 # If compiler will take -Wl,--as-needed (or various platform-specific
30052 # spellings thereof) then add that to LDFLAGS.  This is much easier than
30053 # trying to filter LIBS to the minimum for each executable.
30054 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
30055 # libreadline; therefore we postpone testing it until we know what library
30056 # dependencies readline has.  The test code will try to link with $LIBS.
30057 if test "$with_readline" = yes; then
30058   link_test_func=readline
30059 else
30060   link_test_func=exit
30061 fi
30062
30063 if test "$PORTNAME" = "darwin"; then
30064   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
30065 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
30066 if test "${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+set}" = set; then
30067   $as_echo_n "(cached) " >&6
30068 else
30069   pgac_save_LDFLAGS=$LDFLAGS
30070 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
30071 if test "$cross_compiling" = yes; then
30072   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
30073 else
30074   cat >conftest.$ac_ext <<_ACEOF
30075 /* confdefs.h.  */
30076 _ACEOF
30077 cat confdefs.h >>conftest.$ac_ext
30078 cat >>conftest.$ac_ext <<_ACEOF
30079 /* end confdefs.h.  */
30080 extern void $link_test_func (); void (*fptr) () = $link_test_func;
30081 int
30082 main ()
30083 {
30084
30085   ;
30086   return 0;
30087 }
30088 _ACEOF
30089 rm -f conftest$ac_exeext
30090 if { (ac_try="$ac_link"
30091 case "(($ac_try" in
30092   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30093   *) ac_try_echo=$ac_try;;
30094 esac
30095 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30096 $as_echo "$ac_try_echo") >&5
30097   (eval "$ac_link") 2>&5
30098   ac_status=$?
30099   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30100   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
30101   { (case "(($ac_try" in
30102   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30103   *) ac_try_echo=$ac_try;;
30104 esac
30105 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30106 $as_echo "$ac_try_echo") >&5
30107   (eval "$ac_try") 2>&5
30108   ac_status=$?
30109   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30110   (exit $ac_status); }; }; then
30111   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
30112 else
30113   $as_echo "$as_me: program exited with status $ac_status" >&5
30114 $as_echo "$as_me: failed program was:" >&5
30115 sed 's/^/| /' conftest.$ac_ext >&5
30116
30117 ( exit $ac_status )
30118 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
30119 fi
30120 rm -rf conftest.dSYM
30121 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
30122 fi
30123
30124
30125 LDFLAGS="$pgac_save_LDFLAGS"
30126 fi
30127 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
30128 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
30129 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
30130   LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
30131 fi
30132
30133 elif test "$PORTNAME" = "openbsd"; then
30134   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-Bdynamic" >&5
30135 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
30136 if test "${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+set}" = set; then
30137   $as_echo_n "(cached) " >&6
30138 else
30139   pgac_save_LDFLAGS=$LDFLAGS
30140 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
30141 if test "$cross_compiling" = yes; then
30142   pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
30143 else
30144   cat >conftest.$ac_ext <<_ACEOF
30145 /* confdefs.h.  */
30146 _ACEOF
30147 cat confdefs.h >>conftest.$ac_ext
30148 cat >>conftest.$ac_ext <<_ACEOF
30149 /* end confdefs.h.  */
30150 extern void $link_test_func (); void (*fptr) () = $link_test_func;
30151 int
30152 main ()
30153 {
30154
30155   ;
30156   return 0;
30157 }
30158 _ACEOF
30159 rm -f conftest$ac_exeext
30160 if { (ac_try="$ac_link"
30161 case "(($ac_try" in
30162   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30163   *) ac_try_echo=$ac_try;;
30164 esac
30165 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30166 $as_echo "$ac_try_echo") >&5
30167   (eval "$ac_link") 2>&5
30168   ac_status=$?
30169   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30170   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
30171   { (case "(($ac_try" in
30172   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30173   *) ac_try_echo=$ac_try;;
30174 esac
30175 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30176 $as_echo "$ac_try_echo") >&5
30177   (eval "$ac_try") 2>&5
30178   ac_status=$?
30179   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30180   (exit $ac_status); }; }; then
30181   pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
30182 else
30183   $as_echo "$as_me: program exited with status $ac_status" >&5
30184 $as_echo "$as_me: failed program was:" >&5
30185 sed 's/^/| /' conftest.$ac_ext >&5
30186
30187 ( exit $ac_status )
30188 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
30189 fi
30190 rm -rf conftest.dSYM
30191 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
30192 fi
30193
30194
30195 LDFLAGS="$pgac_save_LDFLAGS"
30196 fi
30197 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
30198 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
30199 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
30200   LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
30201 fi
30202
30203 else
30204   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,--as-needed" >&5
30205 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
30206 if test "${pgac_cv_prog_cc_ldflags__Wl___as_needed+set}" = set; then
30207   $as_echo_n "(cached) " >&6
30208 else
30209   pgac_save_LDFLAGS=$LDFLAGS
30210 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
30211 if test "$cross_compiling" = yes; then
30212   pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
30213 else
30214   cat >conftest.$ac_ext <<_ACEOF
30215 /* confdefs.h.  */
30216 _ACEOF
30217 cat confdefs.h >>conftest.$ac_ext
30218 cat >>conftest.$ac_ext <<_ACEOF
30219 /* end confdefs.h.  */
30220 extern void $link_test_func (); void (*fptr) () = $link_test_func;
30221 int
30222 main ()
30223 {
30224
30225   ;
30226   return 0;
30227 }
30228 _ACEOF
30229 rm -f conftest$ac_exeext
30230 if { (ac_try="$ac_link"
30231 case "(($ac_try" in
30232   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30233   *) ac_try_echo=$ac_try;;
30234 esac
30235 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30236 $as_echo "$ac_try_echo") >&5
30237   (eval "$ac_link") 2>&5
30238   ac_status=$?
30239   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30240   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
30241   { (case "(($ac_try" in
30242   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30243   *) ac_try_echo=$ac_try;;
30244 esac
30245 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
30246 $as_echo "$ac_try_echo") >&5
30247   (eval "$ac_try") 2>&5
30248   ac_status=$?
30249   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
30250   (exit $ac_status); }; }; then
30251   pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
30252 else
30253   $as_echo "$as_me: program exited with status $ac_status" >&5
30254 $as_echo "$as_me: failed program was:" >&5
30255 sed 's/^/| /' conftest.$ac_ext >&5
30256
30257 ( exit $ac_status )
30258 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
30259 fi
30260 rm -rf conftest.dSYM
30261 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
30262 fi
30263
30264
30265 LDFLAGS="$pgac_save_LDFLAGS"
30266 fi
30267 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
30268 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
30269 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
30270   LDFLAGS="$LDFLAGS -Wl,--as-needed"
30271 fi
30272
30273 fi
30274
30275 # Create compiler version string
30276 if test x"$GCC" = x"yes" ; then
30277   cc_string=`${CC} --version | sed q`
30278   case $cc_string in [A-Za-z]*) ;; *) cc_string="GCC $cc_string";; esac
30279 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
30280   cc_string=`${CC} -V 2>&1 | sed q`
30281 else
30282   cc_string=$CC
30283 fi
30284
30285
30286 cat >>confdefs.h <<_ACEOF
30287 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
30288 _ACEOF
30289
30290
30291 # Supply a numeric version string for use by 3rd party add-ons
30292 # awk -F is a regex on some platforms, and not on others, so make "." a tab
30293 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
30294 tr '.' '        ' |
30295 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
30296
30297 cat >>confdefs.h <<_ACEOF
30298 #define PG_VERSION_NUM $PG_VERSION_NUM
30299 _ACEOF
30300
30301
30302
30303 # Begin output steps
30304
30305 { $as_echo "$as_me:$LINENO: using compiler=$cc_string" >&5
30306 $as_echo "$as_me: using compiler=$cc_string" >&6;}
30307 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
30308 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
30309 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
30310 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
30311 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
30312 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
30313
30314 # prepare build tree if outside source tree
30315 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
30316 # Note 2: /bin/pwd might be better than shell's built-in at getting
30317 #         a symlink-free name.
30318 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
30319   vpath_build=no
30320 else
30321   vpath_build=yes
30322   if test "$no_create" != yes; then
30323     $as_echo_n "preparing build tree... " >&6
30324     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
30325     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
30326       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
30327 $as_echo "$as_me: error: failed" >&2;}
30328    { (exit 1); exit 1; }; }
30329     { $as_echo "$as_me:$LINENO: result: done" >&5
30330 $as_echo "done" >&6; }
30331   fi
30332 fi
30333
30334
30335
30336 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
30337
30338
30339 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}"
30340
30341
30342 if test "$PORTNAME" = "win32"; then
30343 ac_config_commands="$ac_config_commands check_win32_symlinks"
30344
30345 fi
30346
30347 ac_config_headers="$ac_config_headers src/include/pg_config.h"
30348
30349
30350 ac_config_headers="$ac_config_headers src/include/pg_config_ext.h"
30351
30352
30353 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
30354
30355
30356 cat >confcache <<\_ACEOF
30357 # This file is a shell script that caches the results of configure
30358 # tests run on this system so they can be shared between configure
30359 # scripts and configure runs, see configure's option --config-cache.
30360 # It is not useful on other systems.  If it contains results you don't
30361 # want to keep, you may remove or edit it.
30362 #
30363 # config.status only pays attention to the cache file if you give it
30364 # the --recheck option to rerun configure.
30365 #
30366 # `ac_cv_env_foo' variables (set or unset) will be overridden when
30367 # loading this file, other *unset* `ac_cv_foo' will be assigned the
30368 # following values.
30369
30370 _ACEOF
30371
30372 # The following way of writing the cache mishandles newlines in values,
30373 # but we know of no workaround that is simple, portable, and efficient.
30374 # So, we kill variables containing newlines.
30375 # Ultrix sh set writes to stderr and can't be redirected directly,
30376 # and sets the high bit in the cache file unless we assign to the vars.
30377 (
30378   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
30379     eval ac_val=\$$ac_var
30380     case $ac_val in #(
30381     *${as_nl}*)
30382       case $ac_var in #(
30383       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
30384 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
30385       esac
30386       case $ac_var in #(
30387       _ | IFS | as_nl) ;; #(
30388       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
30389       *) $as_unset $ac_var ;;
30390       esac ;;
30391     esac
30392   done
30393
30394   (set) 2>&1 |
30395     case $as_nl`(ac_space=' '; set) 2>&1` in #(
30396     *${as_nl}ac_space=\ *)
30397       # `set' does not quote correctly, so add quotes (double-quote
30398       # substitution turns \\\\ into \\, and sed turns \\ into \).
30399       sed -n \
30400         "s/'/'\\\\''/g;
30401           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
30402       ;; #(
30403     *)
30404       # `set' quotes correctly as required by POSIX, so do not add quotes.
30405       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
30406       ;;
30407     esac |
30408     sort
30409 ) |
30410   sed '
30411      /^ac_cv_env_/b end
30412      t clear
30413      :clear
30414      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
30415      t end
30416      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
30417      :end' >>confcache
30418 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
30419   if test -w "$cache_file"; then
30420     test "x$cache_file" != "x/dev/null" &&
30421       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
30422 $as_echo "$as_me: updating cache $cache_file" >&6;}
30423     cat confcache >$cache_file
30424   else
30425     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
30426 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
30427   fi
30428 fi
30429 rm -f confcache
30430
30431 test "x$prefix" = xNONE && prefix=$ac_default_prefix
30432 # Let make expand exec_prefix.
30433 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
30434
30435 DEFS=-DHAVE_CONFIG_H
30436
30437 ac_libobjs=
30438 ac_ltlibobjs=
30439 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
30440   # 1. Remove the extension, and $U if already installed.
30441   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
30442   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
30443   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
30444   #    will be set to the directory where LIBOBJS objects are built.
30445   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
30446   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
30447 done
30448 LIBOBJS=$ac_libobjs
30449
30450 LTLIBOBJS=$ac_ltlibobjs
30451
30452
30453
30454
30455 : ${CONFIG_STATUS=./config.status}
30456 ac_write_fail=0
30457 ac_clean_files_save=$ac_clean_files
30458 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
30459 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
30460 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
30461 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30462 #! $SHELL
30463 # Generated by $as_me.
30464 # Run this file to recreate the current configuration.
30465 # Compiler output produced by configure, useful for debugging
30466 # configure, is in config.log if it exists.
30467
30468 debug=false
30469 ac_cs_recheck=false
30470 ac_cs_silent=false
30471 SHELL=\${CONFIG_SHELL-$SHELL}
30472 _ACEOF
30473
30474 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30475 ## --------------------- ##
30476 ## M4sh Initialization.  ##
30477 ## --------------------- ##
30478
30479 # Be more Bourne compatible
30480 DUALCASE=1; export DUALCASE # for MKS sh
30481 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
30482   emulate sh
30483   NULLCMD=:
30484   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
30485   # is contrary to our usage.  Disable this feature.
30486   alias -g '${1+"$@"}'='"$@"'
30487   setopt NO_GLOB_SUBST
30488 else
30489   case `(set -o) 2>/dev/null` in
30490   *posix*) set -o posix ;;
30491 esac
30492
30493 fi
30494
30495
30496
30497
30498 # PATH needs CR
30499 # Avoid depending upon Character Ranges.
30500 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
30501 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
30502 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
30503 as_cr_digits='0123456789'
30504 as_cr_alnum=$as_cr_Letters$as_cr_digits
30505
30506 as_nl='
30507 '
30508 export as_nl
30509 # Printing a long string crashes Solaris 7 /usr/bin/printf.
30510 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
30511 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
30512 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
30513 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
30514   as_echo='printf %s\n'
30515   as_echo_n='printf %s'
30516 else
30517   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
30518     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
30519     as_echo_n='/usr/ucb/echo -n'
30520   else
30521     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
30522     as_echo_n_body='eval
30523       arg=$1;
30524       case $arg in
30525       *"$as_nl"*)
30526         expr "X$arg" : "X\\(.*\\)$as_nl";
30527         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
30528       esac;
30529       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
30530     '
30531     export as_echo_n_body
30532     as_echo_n='sh -c $as_echo_n_body as_echo'
30533   fi
30534   export as_echo_body
30535   as_echo='sh -c $as_echo_body as_echo'
30536 fi
30537
30538 # The user is always right.
30539 if test "${PATH_SEPARATOR+set}" != set; then
30540   PATH_SEPARATOR=:
30541   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
30542     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
30543       PATH_SEPARATOR=';'
30544   }
30545 fi
30546
30547 # Support unset when possible.
30548 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
30549   as_unset=unset
30550 else
30551   as_unset=false
30552 fi
30553
30554
30555 # IFS
30556 # We need space, tab and new line, in precisely that order.  Quoting is
30557 # there to prevent editors from complaining about space-tab.
30558 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
30559 # splitting by setting IFS to empty value.)
30560 IFS=" ""        $as_nl"
30561
30562 # Find who we are.  Look in the path if we contain no directory separator.
30563 case $0 in
30564   *[\\/]* ) as_myself=$0 ;;
30565   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30566 for as_dir in $PATH
30567 do
30568   IFS=$as_save_IFS
30569   test -z "$as_dir" && as_dir=.
30570   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
30571 done
30572 IFS=$as_save_IFS
30573
30574      ;;
30575 esac
30576 # We did not find ourselves, most probably we were run as `sh COMMAND'
30577 # in which case we are not to be found in the path.
30578 if test "x$as_myself" = x; then
30579   as_myself=$0
30580 fi
30581 if test ! -f "$as_myself"; then
30582   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
30583   { (exit 1); exit 1; }
30584 fi
30585
30586 # Work around bugs in pre-3.0 UWIN ksh.
30587 for as_var in ENV MAIL MAILPATH
30588 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
30589 done
30590 PS1='$ '
30591 PS2='> '
30592 PS4='+ '
30593
30594 # NLS nuisances.
30595 LC_ALL=C
30596 export LC_ALL
30597 LANGUAGE=C
30598 export LANGUAGE
30599
30600 # Required to use basename.
30601 if expr a : '\(a\)' >/dev/null 2>&1 &&
30602    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30603   as_expr=expr
30604 else
30605   as_expr=false
30606 fi
30607
30608 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
30609   as_basename=basename
30610 else
30611   as_basename=false
30612 fi
30613
30614
30615 # Name of the executable.
30616 as_me=`$as_basename -- "$0" ||
30617 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
30618          X"$0" : 'X\(//\)$' \| \
30619          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
30620 $as_echo X/"$0" |
30621     sed '/^.*\/\([^/][^/]*\)\/*$/{
30622             s//\1/
30623             q
30624           }
30625           /^X\/\(\/\/\)$/{
30626             s//\1/
30627             q
30628           }
30629           /^X\/\(\/\).*/{
30630             s//\1/
30631             q
30632           }
30633           s/.*/./; q'`
30634
30635 # CDPATH.
30636 $as_unset CDPATH
30637
30638
30639
30640   as_lineno_1=$LINENO
30641   as_lineno_2=$LINENO
30642   test "x$as_lineno_1" != "x$as_lineno_2" &&
30643   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
30644
30645   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
30646   # uniformly replaced by the line number.  The first 'sed' inserts a
30647   # line-number line after each line using $LINENO; the second 'sed'
30648   # does the real work.  The second script uses 'N' to pair each
30649   # line-number line with the line containing $LINENO, and appends
30650   # trailing '-' during substitution so that $LINENO is not a special
30651   # case at line end.
30652   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
30653   # scripts with optimization help from Paolo Bonzini.  Blame Lee
30654   # E. McMahon (1931-1989) for sed's syntax.  :-)
30655   sed -n '
30656     p
30657     /[$]LINENO/=
30658   ' <$as_myself |
30659     sed '
30660       s/[$]LINENO.*/&-/
30661       t lineno
30662       b
30663       :lineno
30664       N
30665       :loop
30666       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
30667       t loop
30668       s/-\n.*//
30669     ' >$as_me.lineno &&
30670   chmod +x "$as_me.lineno" ||
30671     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
30672    { (exit 1); exit 1; }; }
30673
30674   # Don't try to exec as it changes $[0], causing all sort of problems
30675   # (the dirname of $[0] is not the place where we might find the
30676   # original and so on.  Autoconf is especially sensitive to this).
30677   . "./$as_me.lineno"
30678   # Exit status is that of the last command.
30679   exit
30680 }
30681
30682
30683 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
30684   as_dirname=dirname
30685 else
30686   as_dirname=false
30687 fi
30688
30689 ECHO_C= ECHO_N= ECHO_T=
30690 case `echo -n x` in
30691 -n*)
30692   case `echo 'x\c'` in
30693   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
30694   *)   ECHO_C='\c';;
30695   esac;;
30696 *)
30697   ECHO_N='-n';;
30698 esac
30699 if expr a : '\(a\)' >/dev/null 2>&1 &&
30700    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30701   as_expr=expr
30702 else
30703   as_expr=false
30704 fi
30705
30706 rm -f conf$$ conf$$.exe conf$$.file
30707 if test -d conf$$.dir; then
30708   rm -f conf$$.dir/conf$$.file
30709 else
30710   rm -f conf$$.dir
30711   mkdir conf$$.dir 2>/dev/null
30712 fi
30713 if (echo >conf$$.file) 2>/dev/null; then
30714   if ln -s conf$$.file conf$$ 2>/dev/null; then
30715     as_ln_s='ln -s'
30716     # ... but there are two gotchas:
30717     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
30718     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
30719     # In both cases, we have to default to `cp -p'.
30720     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
30721       as_ln_s='cp -p'
30722   elif ln conf$$.file conf$$ 2>/dev/null; then
30723     as_ln_s=ln
30724   else
30725     as_ln_s='cp -p'
30726   fi
30727 else
30728   as_ln_s='cp -p'
30729 fi
30730 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
30731 rmdir conf$$.dir 2>/dev/null
30732
30733 if mkdir -p . 2>/dev/null; then
30734   as_mkdir_p=:
30735 else
30736   test -d ./-p && rmdir ./-p
30737   as_mkdir_p=false
30738 fi
30739
30740 if test -x / >/dev/null 2>&1; then
30741   as_test_x='test -x'
30742 else
30743   if ls -dL / >/dev/null 2>&1; then
30744     as_ls_L_option=L
30745   else
30746     as_ls_L_option=
30747   fi
30748   as_test_x='
30749     eval sh -c '\''
30750       if test -d "$1"; then
30751         test -d "$1/.";
30752       else
30753         case $1 in
30754         -*)set "./$1";;
30755         esac;
30756         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
30757         ???[sx]*):;;*)false;;esac;fi
30758     '\'' sh
30759   '
30760 fi
30761 as_executable_p=$as_test_x
30762
30763 # Sed expression to map a string onto a valid CPP name.
30764 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
30765
30766 # Sed expression to map a string onto a valid variable name.
30767 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
30768
30769
30770 exec 6>&1
30771
30772 # Save the log message, to keep $[0] and so on meaningful, and to
30773 # report actual input values of CONFIG_FILES etc. instead of their
30774 # values after options handling.
30775 ac_log="
30776 This file was extended by PostgreSQL $as_me 9.4devel, which was
30777 generated by GNU Autoconf 2.63.  Invocation command line was
30778
30779   CONFIG_FILES    = $CONFIG_FILES
30780   CONFIG_HEADERS  = $CONFIG_HEADERS
30781   CONFIG_LINKS    = $CONFIG_LINKS
30782   CONFIG_COMMANDS = $CONFIG_COMMANDS
30783   $ $0 $@
30784
30785 on `(hostname || uname -n) 2>/dev/null | sed 1q`
30786 "
30787
30788 _ACEOF
30789
30790 case $ac_config_files in *"
30791 "*) set x $ac_config_files; shift; ac_config_files=$*;;
30792 esac
30793
30794 case $ac_config_headers in *"
30795 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30796 esac
30797
30798
30799 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30800 # Files that config.status was made for.
30801 config_files="$ac_config_files"
30802 config_headers="$ac_config_headers"
30803 config_links="$ac_config_links"
30804 config_commands="$ac_config_commands"
30805
30806 _ACEOF
30807
30808 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30809 ac_cs_usage="\
30810 \`$as_me' instantiates files from templates according to the
30811 current configuration.
30812
30813 Usage: $0 [OPTION]... [FILE]...
30814
30815   -h, --help       print this help, then exit
30816   -V, --version    print version number and configuration settings, then exit
30817   -q, --quiet, --silent
30818                    do not print progress messages
30819   -d, --debug      don't remove temporary files
30820       --recheck    update $as_me by reconfiguring in the same conditions
30821       --file=FILE[:TEMPLATE]
30822                    instantiate the configuration file FILE
30823       --header=FILE[:TEMPLATE]
30824                    instantiate the configuration header FILE
30825
30826 Configuration files:
30827 $config_files
30828
30829 Configuration headers:
30830 $config_headers
30831
30832 Configuration links:
30833 $config_links
30834
30835 Configuration commands:
30836 $config_commands
30837
30838 Report bugs to <bug-autoconf@gnu.org>."
30839
30840 _ACEOF
30841 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30842 ac_cs_version="\\
30843 PostgreSQL config.status 9.4devel
30844 configured by $0, generated by GNU Autoconf 2.63,
30845   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
30846
30847 Copyright (C) 2008 Free Software Foundation, Inc.
30848 This config.status script is free software; the Free Software Foundation
30849 gives unlimited permission to copy, distribute and modify it."
30850
30851 ac_pwd='$ac_pwd'
30852 srcdir='$srcdir'
30853 INSTALL='$INSTALL'
30854 MKDIR_P='$MKDIR_P'
30855 AWK='$AWK'
30856 test -n "\$AWK" || AWK=awk
30857 _ACEOF
30858
30859 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30860 # The default lists apply if the user does not specify any file.
30861 ac_need_defaults=:
30862 while test $# != 0
30863 do
30864   case $1 in
30865   --*=*)
30866     ac_option=`expr "X$1" : 'X\([^=]*\)='`
30867     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30868     ac_shift=:
30869     ;;
30870   *)
30871     ac_option=$1
30872     ac_optarg=$2
30873     ac_shift=shift
30874     ;;
30875   esac
30876
30877   case $ac_option in
30878   # Handling of the options.
30879   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30880     ac_cs_recheck=: ;;
30881   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30882     $as_echo "$ac_cs_version"; exit ;;
30883   --debug | --debu | --deb | --de | --d | -d )
30884     debug=: ;;
30885   --file | --fil | --fi | --f )
30886     $ac_shift
30887     case $ac_optarg in
30888     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30889     esac
30890     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
30891     ac_need_defaults=false;;
30892   --header | --heade | --head | --hea )
30893     $ac_shift
30894     case $ac_optarg in
30895     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30896     esac
30897     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
30898     ac_need_defaults=false;;
30899   --he | --h)
30900     # Conflict between --help and --header
30901     { $as_echo "$as_me: error: ambiguous option: $1
30902 Try \`$0 --help' for more information." >&2
30903    { (exit 1); exit 1; }; };;
30904   --help | --hel | -h )
30905     $as_echo "$ac_cs_usage"; exit ;;
30906   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30907   | -silent | --silent | --silen | --sile | --sil | --si | --s)
30908     ac_cs_silent=: ;;
30909
30910   # This is an error.
30911   -*) { $as_echo "$as_me: error: unrecognized option: $1
30912 Try \`$0 --help' for more information." >&2
30913    { (exit 1); exit 1; }; } ;;
30914
30915   *) ac_config_targets="$ac_config_targets $1"
30916      ac_need_defaults=false ;;
30917
30918   esac
30919   shift
30920 done
30921
30922 ac_configure_extra_args=
30923
30924 if $ac_cs_silent; then
30925   exec 6>/dev/null
30926   ac_configure_extra_args="$ac_configure_extra_args --silent"
30927 fi
30928
30929 _ACEOF
30930 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30931 if \$ac_cs_recheck; then
30932   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30933   shift
30934   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30935   CONFIG_SHELL='$SHELL'
30936   export CONFIG_SHELL
30937   exec "\$@"
30938 fi
30939
30940 _ACEOF
30941 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30942 exec 5>>config.log
30943 {
30944   echo
30945   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30946 ## Running $as_me. ##
30947 _ASBOX
30948   $as_echo "$ac_log"
30949 } >&5
30950
30951 _ACEOF
30952 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30953 _ACEOF
30954
30955 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30956
30957 # Handling of arguments.
30958 for ac_config_target in $ac_config_targets
30959 do
30960   case $ac_config_target in
30961     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
30962     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
30963     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
30964     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
30965     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
30966     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
30967     "src/backend/port/pg_latch.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION}" ;;
30968     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
30969     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
30970     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
30971     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
30972     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
30973     "src/include/pg_config_ext.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config_ext.h" ;;
30974     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
30975
30976   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
30977 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
30978    { (exit 1); exit 1; }; };;
30979   esac
30980 done
30981
30982
30983 # If the user did not use the arguments to specify the items to instantiate,
30984 # then the envvar interface is used.  Set only those that are not.
30985 # We use the long form for the default assignment because of an extremely
30986 # bizarre bug on SunOS 4.1.3.
30987 if $ac_need_defaults; then
30988   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30989   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30990   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
30991   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30992 fi
30993
30994 # Have a temporary directory for convenience.  Make it in the build tree
30995 # simply because there is no reason against having it here, and in addition,
30996 # creating and moving files from /tmp can sometimes cause problems.
30997 # Hook for its removal unless debugging.
30998 # Note that there is a small window in which the directory will not be cleaned:
30999 # after its creation but before its name has been assigned to `$tmp'.
31000 $debug ||
31001 {
31002   tmp=
31003   trap 'exit_status=$?
31004   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
31005 ' 0
31006   trap '{ (exit 1); exit 1; }' 1 2 13 15
31007 }
31008 # Create a (secure) tmp directory for tmp files.
31009
31010 {
31011   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
31012   test -n "$tmp" && test -d "$tmp"
31013 }  ||
31014 {
31015   tmp=./conf$$-$RANDOM
31016   (umask 077 && mkdir "$tmp")
31017 } ||
31018 {
31019    $as_echo "$as_me: cannot create a temporary directory in ." >&2
31020    { (exit 1); exit 1; }
31021 }
31022
31023 # Set up the scripts for CONFIG_FILES section.
31024 # No need to generate them if there are no CONFIG_FILES.
31025 # This happens for instance with `./config.status config.h'.
31026 if test -n "$CONFIG_FILES"; then
31027
31028
31029 ac_cr='\r'
31030 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
31031 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
31032   ac_cs_awk_cr='\\r'
31033 else
31034   ac_cs_awk_cr=$ac_cr
31035 fi
31036
31037 echo 'BEGIN {' >"$tmp/subs1.awk" &&
31038 _ACEOF
31039
31040
31041 {
31042   echo "cat >conf$$subs.awk <<_ACEOF" &&
31043   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
31044   echo "_ACEOF"
31045 } >conf$$subs.sh ||
31046   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
31047 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
31048    { (exit 1); exit 1; }; }
31049 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
31050 ac_delim='%!_!# '
31051 for ac_last_try in false false false false false :; do
31052   . ./conf$$subs.sh ||
31053     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
31054 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
31055    { (exit 1); exit 1; }; }
31056
31057   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
31058   if test $ac_delim_n = $ac_delim_num; then
31059     break
31060   elif $ac_last_try; then
31061     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
31062 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
31063    { (exit 1); exit 1; }; }
31064   else
31065     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
31066   fi
31067 done
31068 rm -f conf$$subs.sh
31069
31070 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31071 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
31072 _ACEOF
31073 sed -n '
31074 h
31075 s/^/S["/; s/!.*/"]=/
31076 p
31077 g
31078 s/^[^!]*!//
31079 :repl
31080 t repl
31081 s/'"$ac_delim"'$//
31082 t delim
31083 :nl
31084 h
31085 s/\(.\{148\}\).*/\1/
31086 t more1
31087 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
31088 p
31089 n
31090 b repl
31091 :more1
31092 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
31093 p
31094 g
31095 s/.\{148\}//
31096 t nl
31097 :delim
31098 h
31099 s/\(.\{148\}\).*/\1/
31100 t more2
31101 s/["\\]/\\&/g; s/^/"/; s/$/"/
31102 p
31103 b
31104 :more2
31105 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
31106 p
31107 g
31108 s/.\{148\}//
31109 t delim
31110 ' <conf$$subs.awk | sed '
31111 /^[^""]/{
31112   N
31113   s/\n//
31114 }
31115 ' >>$CONFIG_STATUS || ac_write_fail=1
31116 rm -f conf$$subs.awk
31117 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31118 _ACAWK
31119 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
31120   for (key in S) S_is_set[key] = 1
31121   FS = "\a"
31122
31123 }
31124 {
31125   line = $ 0
31126   nfields = split(line, field, "@")
31127   substed = 0
31128   len = length(field[1])
31129   for (i = 2; i < nfields; i++) {
31130     key = field[i]
31131     keylen = length(key)
31132     if (S_is_set[key]) {
31133       value = S[key]
31134       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
31135       len += length(value) + length(field[++i])
31136       substed = 1
31137     } else
31138       len += 1 + keylen
31139   }
31140
31141   print line
31142 }
31143
31144 _ACAWK
31145 _ACEOF
31146 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31147 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
31148   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
31149 else
31150   cat
31151 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
31152   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
31153 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
31154    { (exit 1); exit 1; }; }
31155 _ACEOF
31156
31157 # VPATH may cause trouble with some makes, so we remove $(srcdir),
31158 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
31159 # trailing colons and then remove the whole line if VPATH becomes empty
31160 # (actually we leave an empty line to preserve line numbers).
31161 if test "x$srcdir" = x.; then
31162   ac_vpsub='/^[  ]*VPATH[        ]*=/{
31163 s/:*\$(srcdir):*/:/
31164 s/:*\${srcdir}:*/:/
31165 s/:*@srcdir@:*/:/
31166 s/^\([^=]*=[     ]*\):*/\1/
31167 s/:*$//
31168 s/^[^=]*=[       ]*$//
31169 }'
31170 fi
31171
31172 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31173 fi # test -n "$CONFIG_FILES"
31174
31175 # Set up the scripts for CONFIG_HEADERS section.
31176 # No need to generate them if there are no CONFIG_HEADERS.
31177 # This happens for instance with `./config.status Makefile'.
31178 if test -n "$CONFIG_HEADERS"; then
31179 cat >"$tmp/defines.awk" <<\_ACAWK ||
31180 BEGIN {
31181 _ACEOF
31182
31183 # Transform confdefs.h into an awk script `defines.awk', embedded as
31184 # here-document in config.status, that substitutes the proper values into
31185 # config.h.in to produce config.h.
31186
31187 # Create a delimiter string that does not exist in confdefs.h, to ease
31188 # handling of long lines.
31189 ac_delim='%!_!# '
31190 for ac_last_try in false false :; do
31191   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
31192   if test -z "$ac_t"; then
31193     break
31194   elif $ac_last_try; then
31195     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
31196 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
31197    { (exit 1); exit 1; }; }
31198   else
31199     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
31200   fi
31201 done
31202
31203 # For the awk script, D is an array of macro values keyed by name,
31204 # likewise P contains macro parameters if any.  Preserve backslash
31205 # newline sequences.
31206
31207 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
31208 sed -n '
31209 s/.\{148\}/&'"$ac_delim"'/g
31210 t rset
31211 :rset
31212 s/^[     ]*#[    ]*define[       ][      ]*/ /
31213 t def
31214 d
31215 :def
31216 s/\\$//
31217 t bsnl
31218 s/["\\]/\\&/g
31219 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
31220 D["\1"]=" \3"/p
31221 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
31222 d
31223 :bsnl
31224 s/["\\]/\\&/g
31225 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
31226 D["\1"]=" \3\\\\\\n"\\/p
31227 t cont
31228 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
31229 t cont
31230 d
31231 :cont
31232 n
31233 s/.\{148\}/&'"$ac_delim"'/g
31234 t clear
31235 :clear
31236 s/\\$//
31237 t bsnlc
31238 s/["\\]/\\&/g; s/^/"/; s/$/"/p
31239 d
31240 :bsnlc
31241 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
31242 b cont
31243 ' <confdefs.h | sed '
31244 s/'"$ac_delim"'/"\\\
31245 "/g' >>$CONFIG_STATUS || ac_write_fail=1
31246
31247 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31248   for (key in D) D_is_set[key] = 1
31249   FS = "\a"
31250 }
31251 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
31252   line = \$ 0
31253   split(line, arg, " ")
31254   if (arg[1] == "#") {
31255     defundef = arg[2]
31256     mac1 = arg[3]
31257   } else {
31258     defundef = substr(arg[1], 2)
31259     mac1 = arg[2]
31260   }
31261   split(mac1, mac2, "(") #)
31262   macro = mac2[1]
31263   prefix = substr(line, 1, index(line, defundef) - 1)
31264   if (D_is_set[macro]) {
31265     # Preserve the white space surrounding the "#".
31266     print prefix "define", macro P[macro] D[macro]
31267     next
31268   } else {
31269     # Replace #undef with comments.  This is necessary, for example,
31270     # in the case of _POSIX_SOURCE, which is predefined and required
31271     # on some systems where configure will not decide to define it.
31272     if (defundef == "undef") {
31273       print "/*", prefix defundef, macro, "*/"
31274       next
31275     }
31276   }
31277 }
31278 { print }
31279 _ACAWK
31280 _ACEOF
31281 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31282   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
31283 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
31284    { (exit 1); exit 1; }; }
31285 fi # test -n "$CONFIG_HEADERS"
31286
31287
31288 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
31289 shift
31290 for ac_tag
31291 do
31292   case $ac_tag in
31293   :[FHLC]) ac_mode=$ac_tag; continue;;
31294   esac
31295   case $ac_mode$ac_tag in
31296   :[FHL]*:*);;
31297   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
31298 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
31299    { (exit 1); exit 1; }; };;
31300   :[FH]-) ac_tag=-:-;;
31301   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
31302   esac
31303   ac_save_IFS=$IFS
31304   IFS=:
31305   set x $ac_tag
31306   IFS=$ac_save_IFS
31307   shift
31308   ac_file=$1
31309   shift
31310
31311   case $ac_mode in
31312   :L) ac_source=$1;;
31313   :[FH])
31314     ac_file_inputs=
31315     for ac_f
31316     do
31317       case $ac_f in
31318       -) ac_f="$tmp/stdin";;
31319       *) # Look for the file first in the build tree, then in the source tree
31320          # (if the path is not absolute).  The absolute path cannot be DOS-style,
31321          # because $ac_f cannot contain `:'.
31322          test -f "$ac_f" ||
31323            case $ac_f in
31324            [\\/$]*) false;;
31325            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
31326            esac ||
31327            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
31328 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
31329    { (exit 1); exit 1; }; };;
31330       esac
31331       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
31332       ac_file_inputs="$ac_file_inputs '$ac_f'"
31333     done
31334
31335     # Let's still pretend it is `configure' which instantiates (i.e., don't
31336     # use $as_me), people would be surprised to read:
31337     #    /* config.h.  Generated by config.status.  */
31338     configure_input='Generated from '`
31339           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
31340         `' by configure.'
31341     if test x"$ac_file" != x-; then
31342       configure_input="$ac_file.  $configure_input"
31343       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
31344 $as_echo "$as_me: creating $ac_file" >&6;}
31345     fi
31346     # Neutralize special characters interpreted by sed in replacement strings.
31347     case $configure_input in #(
31348     *\&* | *\|* | *\\* )
31349        ac_sed_conf_input=`$as_echo "$configure_input" |
31350        sed 's/[\\\\&|]/\\\\&/g'`;; #(
31351     *) ac_sed_conf_input=$configure_input;;
31352     esac
31353
31354     case $ac_tag in
31355     *:-:* | *:-) cat >"$tmp/stdin" \
31356       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31357 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31358    { (exit 1); exit 1; }; } ;;
31359     esac
31360     ;;
31361   esac
31362
31363   ac_dir=`$as_dirname -- "$ac_file" ||
31364 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31365          X"$ac_file" : 'X\(//\)[^/]' \| \
31366          X"$ac_file" : 'X\(//\)$' \| \
31367          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
31368 $as_echo X"$ac_file" |
31369     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31370             s//\1/
31371             q
31372           }
31373           /^X\(\/\/\)[^/].*/{
31374             s//\1/
31375             q
31376           }
31377           /^X\(\/\/\)$/{
31378             s//\1/
31379             q
31380           }
31381           /^X\(\/\).*/{
31382             s//\1/
31383             q
31384           }
31385           s/.*/./; q'`
31386   { as_dir="$ac_dir"
31387   case $as_dir in #(
31388   -*) as_dir=./$as_dir;;
31389   esac
31390   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
31391     as_dirs=
31392     while :; do
31393       case $as_dir in #(
31394       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
31395       *) as_qdir=$as_dir;;
31396       esac
31397       as_dirs="'$as_qdir' $as_dirs"
31398       as_dir=`$as_dirname -- "$as_dir" ||
31399 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31400          X"$as_dir" : 'X\(//\)[^/]' \| \
31401          X"$as_dir" : 'X\(//\)$' \| \
31402          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
31403 $as_echo X"$as_dir" |
31404     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31405             s//\1/
31406             q
31407           }
31408           /^X\(\/\/\)[^/].*/{
31409             s//\1/
31410             q
31411           }
31412           /^X\(\/\/\)$/{
31413             s//\1/
31414             q
31415           }
31416           /^X\(\/\).*/{
31417             s//\1/
31418             q
31419           }
31420           s/.*/./; q'`
31421       test -d "$as_dir" && break
31422     done
31423     test -z "$as_dirs" || eval "mkdir $as_dirs"
31424   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
31425 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
31426    { (exit 1); exit 1; }; }; }
31427   ac_builddir=.
31428
31429 case "$ac_dir" in
31430 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
31431 *)
31432   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
31433   # A ".." for each directory in $ac_dir_suffix.
31434   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
31435   case $ac_top_builddir_sub in
31436   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
31437   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
31438   esac ;;
31439 esac
31440 ac_abs_top_builddir=$ac_pwd
31441 ac_abs_builddir=$ac_pwd$ac_dir_suffix
31442 # for backward compatibility:
31443 ac_top_builddir=$ac_top_build_prefix
31444
31445 case $srcdir in
31446   .)  # We are building in place.
31447     ac_srcdir=.
31448     ac_top_srcdir=$ac_top_builddir_sub
31449     ac_abs_top_srcdir=$ac_pwd ;;
31450   [\\/]* | ?:[\\/]* )  # Absolute name.
31451     ac_srcdir=$srcdir$ac_dir_suffix;
31452     ac_top_srcdir=$srcdir
31453     ac_abs_top_srcdir=$srcdir ;;
31454   *) # Relative name.
31455     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
31456     ac_top_srcdir=$ac_top_build_prefix$srcdir
31457     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
31458 esac
31459 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
31460
31461
31462   case $ac_mode in
31463   :F)
31464   #
31465   # CONFIG_FILE
31466   #
31467
31468   case $INSTALL in
31469   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
31470   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
31471   esac
31472   ac_MKDIR_P=$MKDIR_P
31473   case $MKDIR_P in
31474   [\\/$]* | ?:[\\/]* ) ;;
31475   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
31476   esac
31477 _ACEOF
31478
31479 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31480 # If the template does not know about datarootdir, expand it.
31481 # FIXME: This hack should be removed a few years after 2.60.
31482 ac_datarootdir_hack=; ac_datarootdir_seen=
31483
31484 ac_sed_dataroot='
31485 /datarootdir/ {
31486   p
31487   q
31488 }
31489 /@datadir@/p
31490 /@docdir@/p
31491 /@infodir@/p
31492 /@localedir@/p
31493 /@mandir@/p
31494 '
31495 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
31496 *datarootdir*) ac_datarootdir_seen=yes;;
31497 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
31498   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
31499 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
31500 _ACEOF
31501 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31502   ac_datarootdir_hack='
31503   s&@datadir@&$datadir&g
31504   s&@docdir@&$docdir&g
31505   s&@infodir@&$infodir&g
31506   s&@localedir@&$localedir&g
31507   s&@mandir@&$mandir&g
31508     s&\\\${datarootdir}&$datarootdir&g' ;;
31509 esac
31510 _ACEOF
31511
31512 # Neutralize VPATH when `$srcdir' = `.'.
31513 # Shell code in configure.ac might set extrasub.
31514 # FIXME: do we really want to maintain this feature?
31515 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31516 ac_sed_extra="$ac_vpsub
31517 $extrasub
31518 _ACEOF
31519 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31520 :t
31521 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
31522 s|@configure_input@|$ac_sed_conf_input|;t t
31523 s&@top_builddir@&$ac_top_builddir_sub&;t t
31524 s&@top_build_prefix@&$ac_top_build_prefix&;t t
31525 s&@srcdir@&$ac_srcdir&;t t
31526 s&@abs_srcdir@&$ac_abs_srcdir&;t t
31527 s&@top_srcdir@&$ac_top_srcdir&;t t
31528 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
31529 s&@builddir@&$ac_builddir&;t t
31530 s&@abs_builddir@&$ac_abs_builddir&;t t
31531 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
31532 s&@INSTALL@&$ac_INSTALL&;t t
31533 s&@MKDIR_P@&$ac_MKDIR_P&;t t
31534 $ac_datarootdir_hack
31535 "
31536 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
31537   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31538 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31539    { (exit 1); exit 1; }; }
31540
31541 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
31542   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
31543   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
31544   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
31545 which seems to be undefined.  Please make sure it is defined." >&5
31546 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
31547 which seems to be undefined.  Please make sure it is defined." >&2;}
31548
31549   rm -f "$tmp/stdin"
31550   case $ac_file in
31551   -) cat "$tmp/out" && rm -f "$tmp/out";;
31552   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
31553   esac \
31554   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31555 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31556    { (exit 1); exit 1; }; }
31557  ;;
31558   :H)
31559   #
31560   # CONFIG_HEADER
31561   #
31562   if test x"$ac_file" != x-; then
31563     {
31564       $as_echo "/* $configure_input  */" \
31565       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
31566     } >"$tmp/config.h" \
31567       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31568 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31569    { (exit 1); exit 1; }; }
31570     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
31571       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
31572 $as_echo "$as_me: $ac_file is unchanged" >&6;}
31573     else
31574       rm -f "$ac_file"
31575       mv "$tmp/config.h" "$ac_file" \
31576         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31577 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31578    { (exit 1); exit 1; }; }
31579     fi
31580   else
31581     $as_echo "/* $configure_input  */" \
31582       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
31583       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
31584 $as_echo "$as_me: error: could not create -" >&2;}
31585    { (exit 1); exit 1; }; }
31586   fi
31587  ;;
31588   :L)
31589   #
31590   # CONFIG_LINK
31591   #
31592
31593   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
31594     :
31595   else
31596     # Prefer the file from the source tree if names are identical.
31597     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
31598       ac_source=$srcdir/$ac_source
31599     fi
31600
31601     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
31602 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
31603
31604     if test ! -r "$ac_source"; then
31605       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
31606 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
31607    { (exit 1); exit 1; }; }
31608     fi
31609     rm -f "$ac_file"
31610
31611     # Try a relative symlink, then a hard link, then a copy.
31612     case $srcdir in
31613     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
31614         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
31615     esac
31616     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
31617       ln "$ac_source" "$ac_file" 2>/dev/null ||
31618       cp -p "$ac_source" "$ac_file" ||
31619       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
31620 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
31621    { (exit 1); exit 1; }; }
31622   fi
31623  ;;
31624   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
31625 $as_echo "$as_me: executing $ac_file commands" >&6;}
31626  ;;
31627   esac
31628
31629
31630   case $ac_file$ac_mode in
31631     "check_win32_symlinks":C)
31632 # Links sometimes fail undetected on Mingw -
31633 # so here we detect it and warn the user
31634 for FILE in $CONFIG_LINKS
31635  do
31636         # test -e works for symlinks in the MinGW console
31637         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
31638 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
31639  done
31640  ;;
31641     "src/include/pg_config.h":H)
31642 # Update timestamp for pg_config.h (see Makefile.global)
31643 echo >src/include/stamp-h
31644  ;;
31645     "src/include/pg_config_ext.h":H)
31646 # Update timestamp for pg_config_ext.h (see Makefile.global)
31647 echo >src/include/stamp-ext-h
31648  ;;
31649     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
31650
31651   esac
31652 done # for ac_tag
31653
31654
31655 { (exit 0); exit 0; }
31656 _ACEOF
31657 chmod +x $CONFIG_STATUS
31658 ac_clean_files=$ac_clean_files_save
31659
31660 test $ac_write_fail = 0 ||
31661   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
31662 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
31663    { (exit 1); exit 1; }; }
31664
31665
31666 # configure is writing to config.log, and then calls config.status.
31667 # config.status does its own redirection, appending to config.log.
31668 # Unfortunately, on DOS this fails, as config.log is still kept open
31669 # by configure, so config.status won't be able to write to it; its
31670 # output is simply discarded.  So we exec the FD to /dev/null,
31671 # effectively closing config.log, so it can be properly (re)opened and
31672 # appended to by config.status.  When coming back to configure, we
31673 # need to make the FD available again.
31674 if test "$no_create" != yes; then
31675   ac_cs_success=:
31676   ac_config_status_args=
31677   test "$silent" = yes &&
31678     ac_config_status_args="$ac_config_status_args --quiet"
31679   exec 5>/dev/null
31680   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
31681   exec 5>>config.log
31682   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
31683   # would make configure fail if this is the last instruction.
31684   $ac_cs_success || { (exit 1); exit 1; }
31685 fi
31686 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
31687   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
31688 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
31689 fi
31690