]> granicus.if.org Git - postgresql/blob - configure
Document that max_locks_per_transaction might need to be increased for
[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.3devel.
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-2012, 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.3devel'
602 PACKAGE_STRING='PostgreSQL 9.3devel'
603 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
604
605 ac_unique_file="src/backend/access/common/heaptuple.c"
606 ac_default_prefix=/usr/local/pgsql
607 # Factoring default headers for most tests.
608 ac_includes_default="\
609 #include <stdio.h>
610 #ifdef HAVE_SYS_TYPES_H
611 # include <sys/types.h>
612 #endif
613 #ifdef HAVE_SYS_STAT_H
614 # include <sys/stat.h>
615 #endif
616 #ifdef STDC_HEADERS
617 # include <stdlib.h>
618 # include <stddef.h>
619 #else
620 # ifdef HAVE_STDLIB_H
621 #  include <stdlib.h>
622 # endif
623 #endif
624 #ifdef HAVE_STRING_H
625 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
626 #  include <memory.h>
627 # endif
628 # include <string.h>
629 #endif
630 #ifdef HAVE_STRINGS_H
631 # include <strings.h>
632 #endif
633 #ifdef HAVE_INTTYPES_H
634 # include <inttypes.h>
635 #endif
636 #ifdef HAVE_STDINT_H
637 # include <stdint.h>
638 #endif
639 #ifdef HAVE_UNISTD_H
640 # include <unistd.h>
641 #endif"
642
643 ac_subst_vars='LTLIBOBJS
644 vpath_build
645 OSX
646 XSLTPROC
647 COLLATEINDEX
648 DOCBOOKSTYLE
649 have_docbook
650 JADE
651 NSGMLS
652 TCL_SHLIB_LD_LIBS
653 TCL_SHARED_BUILD
654 TCL_LIB_SPEC
655 TCL_LIBS
656 TCL_LIB_FILE
657 TCL_INCLUDE_SPEC
658 TCL_CONFIG_SH
659 TCLSH
660 XGETTEXT
661 MSGMERGE
662 MSGFMT
663 HAVE_POSIX_SIGNALS
664 LDAP_LIBS_BE
665 LDAP_LIBS_FE
666 PTHREAD_CFLAGS
667 PTHREAD_LIBS
668 PTHREAD_CC
669 acx_pthread_config
670 have_win32_dbghelp
671 HAVE_IPV6
672 LIBOBJS
673 OSSP_UUID_LIBS
674 ZIC
675 python_additional_libs
676 python_libspec
677 python_libdir
678 python_includespec
679 python_configdir
680 python_version
681 python_majorversion
682 PYTHON
683 perl_embed_ldflags
684 perl_useshrplib
685 perl_privlibexp
686 perl_archlibexp
687 PERL
688 FLEXFLAGS
689 FLEX
690 BISONFLAGS
691 BISON
692 MKDIR_P
693 AWK
694 LN_S
695 TAR
696 install_bin
697 INSTALL_DATA
698 INSTALL_SCRIPT
699 INSTALL_PROGRAM
700 WINDRES
701 DLLWRAP
702 DLLTOOL
703 AR
704 STRIP_SHARED_LIB
705 STRIP_STATIC_LIB
706 STRIP
707 RANLIB
708 ld_R_works
709 with_gnu_ld
710 LD
711 LDFLAGS_SL
712 LDFLAGS_EX
713 ELF_SYS
714 EGREP
715 GREP
716 with_zlib
717 with_system_tzdata
718 with_libxslt
719 with_libxml
720 XML2_CONFIG
721 with_ossp_uuid
722 with_selinux
723 with_openssl
724 krb_srvtab
725 with_python
726 with_perl
727 with_tcl
728 enable_thread_safety
729 INCLUDES
730 autodepend
731 TAS
732 GCC
733 CPP
734 SUN_STUDIO_CC
735 OBJEXT
736 EXEEXT
737 ac_ct_CC
738 CPPFLAGS
739 LDFLAGS
740 CFLAGS
741 CC
742 enable_dtrace
743 DTRACEFLAGS
744 DTRACE
745 enable_coverage
746 GENHTML
747 LCOV
748 GCOV
749 enable_debug
750 enable_rpath
751 default_port
752 WANTED_LANGUAGES
753 enable_nls
754 PORTNAME
755 host_os
756 host_vendor
757 host_cpu
758 host
759 build_os
760 build_vendor
761 build_cpu
762 build
763 PG_MAJORVERSION
764 configure_args
765 target_alias
766 host_alias
767 build_alias
768 LIBS
769 ECHO_T
770 ECHO_N
771 ECHO_C
772 DEFS
773 mandir
774 localedir
775 libdir
776 psdir
777 pdfdir
778 dvidir
779 htmldir
780 infodir
781 docdir
782 oldincludedir
783 includedir
784 localstatedir
785 sharedstatedir
786 sysconfdir
787 datadir
788 datarootdir
789 libexecdir
790 sbindir
791 bindir
792 program_transform_name
793 prefix
794 exec_prefix
795 PACKAGE_BUGREPORT
796 PACKAGE_STRING
797 PACKAGE_VERSION
798 PACKAGE_TARNAME
799 PACKAGE_NAME
800 PATH_SEPARATOR
801 SHELL'
802 ac_subst_files=''
803 ac_user_opts='
804 enable_option_checking
805 with_template
806 with_includes
807 with_libraries
808 with_libs
809 enable_integer_datetimes
810 enable_nls
811 with_pgport
812 enable_rpath
813 enable_spinlocks
814 enable_debug
815 enable_profiling
816 enable_coverage
817 enable_dtrace
818 with_blocksize
819 with_segsize
820 with_wal_blocksize
821 with_wal_segsize
822 with_CC
823 enable_depend
824 enable_cassert
825 enable_thread_safety
826 with_tcl
827 with_tclconfig
828 with_perl
829 with_python
830 with_gssapi
831 with_krb5
832 with_krb_srvnam
833 with_pam
834 with_ldap
835 with_bonjour
836 with_openssl
837 with_selinux
838 with_readline
839 with_libedit_preferred
840 with_ossp_uuid
841 with_libxml
842 with_libxslt
843 with_system_tzdata
844 with_zlib
845 with_gnu_ld
846 enable_largefile
847 enable_float4_byval
848 enable_float8_byval
849 '
850       ac_precious_vars='build_alias
851 host_alias
852 target_alias
853 CC
854 CFLAGS
855 LDFLAGS
856 LIBS
857 CPPFLAGS
858 CPP
859 LDFLAGS_EX
860 LDFLAGS_SL
861 DOCBOOKSTYLE'
862
863
864 # Initialize some variables set by options.
865 ac_init_help=
866 ac_init_version=false
867 ac_unrecognized_opts=
868 ac_unrecognized_sep=
869 # The variables have the same names as the options, with
870 # dashes changed to underlines.
871 cache_file=/dev/null
872 exec_prefix=NONE
873 no_create=
874 no_recursion=
875 prefix=NONE
876 program_prefix=NONE
877 program_suffix=NONE
878 program_transform_name=s,x,x,
879 silent=
880 site=
881 srcdir=
882 verbose=
883 x_includes=NONE
884 x_libraries=NONE
885
886 # Installation directory options.
887 # These are left unexpanded so users can "make install exec_prefix=/foo"
888 # and all the variables that are supposed to be based on exec_prefix
889 # by default will actually change.
890 # Use braces instead of parens because sh, perl, etc. also accept them.
891 # (The list follows the same order as the GNU Coding Standards.)
892 bindir='${exec_prefix}/bin'
893 sbindir='${exec_prefix}/sbin'
894 libexecdir='${exec_prefix}/libexec'
895 datarootdir='${prefix}/share'
896 datadir='${datarootdir}'
897 sysconfdir='${prefix}/etc'
898 sharedstatedir='${prefix}/com'
899 localstatedir='${prefix}/var'
900 includedir='${prefix}/include'
901 oldincludedir='/usr/include'
902 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
903 infodir='${datarootdir}/info'
904 htmldir='${docdir}'
905 dvidir='${docdir}'
906 pdfdir='${docdir}'
907 psdir='${docdir}'
908 libdir='${exec_prefix}/lib'
909 localedir='${datarootdir}/locale'
910 mandir='${datarootdir}/man'
911
912 ac_prev=
913 ac_dashdash=
914 for ac_option
915 do
916   # If the previous option needs an argument, assign it.
917   if test -n "$ac_prev"; then
918     eval $ac_prev=\$ac_option
919     ac_prev=
920     continue
921   fi
922
923   case $ac_option in
924   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
925   *)    ac_optarg=yes ;;
926   esac
927
928   # Accept the important Cygnus configure options, so we can diagnose typos.
929
930   case $ac_dashdash$ac_option in
931   --)
932     ac_dashdash=yes ;;
933
934   -bindir | --bindir | --bindi | --bind | --bin | --bi)
935     ac_prev=bindir ;;
936   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
937     bindir=$ac_optarg ;;
938
939   -build | --build | --buil | --bui | --bu)
940     ac_prev=build_alias ;;
941   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
942     build_alias=$ac_optarg ;;
943
944   -cache-file | --cache-file | --cache-fil | --cache-fi \
945   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
946     ac_prev=cache_file ;;
947   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
948   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
949     cache_file=$ac_optarg ;;
950
951   --config-cache | -C)
952     cache_file=config.cache ;;
953
954   -datadir | --datadir | --datadi | --datad)
955     ac_prev=datadir ;;
956   -datadir=* | --datadir=* | --datadi=* | --datad=*)
957     datadir=$ac_optarg ;;
958
959   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
960   | --dataroo | --dataro | --datar)
961     ac_prev=datarootdir ;;
962   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
963   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
964     datarootdir=$ac_optarg ;;
965
966   -disable-* | --disable-*)
967     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
968     # Reject names that are not valid shell variable names.
969     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
970       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
971    { (exit 1); exit 1; }; }
972     ac_useropt_orig=$ac_useropt
973     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
974     case $ac_user_opts in
975       *"
976 "enable_$ac_useropt"
977 "*) ;;
978       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
979          ac_unrecognized_sep=', ';;
980     esac
981     eval enable_$ac_useropt=no ;;
982
983   -docdir | --docdir | --docdi | --doc | --do)
984     ac_prev=docdir ;;
985   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
986     docdir=$ac_optarg ;;
987
988   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
989     ac_prev=dvidir ;;
990   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
991     dvidir=$ac_optarg ;;
992
993   -enable-* | --enable-*)
994     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
995     # Reject names that are not valid shell variable names.
996     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
997       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
998    { (exit 1); exit 1; }; }
999     ac_useropt_orig=$ac_useropt
1000     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1001     case $ac_user_opts in
1002       *"
1003 "enable_$ac_useropt"
1004 "*) ;;
1005       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1006          ac_unrecognized_sep=', ';;
1007     esac
1008     eval enable_$ac_useropt=\$ac_optarg ;;
1009
1010   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1011   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1012   | --exec | --exe | --ex)
1013     ac_prev=exec_prefix ;;
1014   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1015   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1016   | --exec=* | --exe=* | --ex=*)
1017     exec_prefix=$ac_optarg ;;
1018
1019   -gas | --gas | --ga | --g)
1020     # Obsolete; use --with-gas.
1021     with_gas=yes ;;
1022
1023   -help | --help | --hel | --he | -h)
1024     ac_init_help=long ;;
1025   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1026     ac_init_help=recursive ;;
1027   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1028     ac_init_help=short ;;
1029
1030   -host | --host | --hos | --ho)
1031     ac_prev=host_alias ;;
1032   -host=* | --host=* | --hos=* | --ho=*)
1033     host_alias=$ac_optarg ;;
1034
1035   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1036     ac_prev=htmldir ;;
1037   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1038   | --ht=*)
1039     htmldir=$ac_optarg ;;
1040
1041   -includedir | --includedir | --includedi | --included | --include \
1042   | --includ | --inclu | --incl | --inc)
1043     ac_prev=includedir ;;
1044   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1045   | --includ=* | --inclu=* | --incl=* | --inc=*)
1046     includedir=$ac_optarg ;;
1047
1048   -infodir | --infodir | --infodi | --infod | --info | --inf)
1049     ac_prev=infodir ;;
1050   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1051     infodir=$ac_optarg ;;
1052
1053   -libdir | --libdir | --libdi | --libd)
1054     ac_prev=libdir ;;
1055   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1056     libdir=$ac_optarg ;;
1057
1058   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1059   | --libexe | --libex | --libe)
1060     ac_prev=libexecdir ;;
1061   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1062   | --libexe=* | --libex=* | --libe=*)
1063     libexecdir=$ac_optarg ;;
1064
1065   -localedir | --localedir | --localedi | --localed | --locale)
1066     ac_prev=localedir ;;
1067   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1068     localedir=$ac_optarg ;;
1069
1070   -localstatedir | --localstatedir | --localstatedi | --localstated \
1071   | --localstate | --localstat | --localsta | --localst | --locals)
1072     ac_prev=localstatedir ;;
1073   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1074   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1075     localstatedir=$ac_optarg ;;
1076
1077   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1078     ac_prev=mandir ;;
1079   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1080     mandir=$ac_optarg ;;
1081
1082   -nfp | --nfp | --nf)
1083     # Obsolete; use --without-fp.
1084     with_fp=no ;;
1085
1086   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1087   | --no-cr | --no-c | -n)
1088     no_create=yes ;;
1089
1090   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1091   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1092     no_recursion=yes ;;
1093
1094   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1095   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1096   | --oldin | --oldi | --old | --ol | --o)
1097     ac_prev=oldincludedir ;;
1098   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1099   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1100   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1101     oldincludedir=$ac_optarg ;;
1102
1103   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1104     ac_prev=prefix ;;
1105   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1106     prefix=$ac_optarg ;;
1107
1108   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1109   | --program-pre | --program-pr | --program-p)
1110     ac_prev=program_prefix ;;
1111   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1112   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1113     program_prefix=$ac_optarg ;;
1114
1115   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1116   | --program-suf | --program-su | --program-s)
1117     ac_prev=program_suffix ;;
1118   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1119   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1120     program_suffix=$ac_optarg ;;
1121
1122   -program-transform-name | --program-transform-name \
1123   | --program-transform-nam | --program-transform-na \
1124   | --program-transform-n | --program-transform- \
1125   | --program-transform | --program-transfor \
1126   | --program-transfo | --program-transf \
1127   | --program-trans | --program-tran \
1128   | --progr-tra | --program-tr | --program-t)
1129     ac_prev=program_transform_name ;;
1130   -program-transform-name=* | --program-transform-name=* \
1131   | --program-transform-nam=* | --program-transform-na=* \
1132   | --program-transform-n=* | --program-transform-=* \
1133   | --program-transform=* | --program-transfor=* \
1134   | --program-transfo=* | --program-transf=* \
1135   | --program-trans=* | --program-tran=* \
1136   | --progr-tra=* | --program-tr=* | --program-t=*)
1137     program_transform_name=$ac_optarg ;;
1138
1139   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1140     ac_prev=pdfdir ;;
1141   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1142     pdfdir=$ac_optarg ;;
1143
1144   -psdir | --psdir | --psdi | --psd | --ps)
1145     ac_prev=psdir ;;
1146   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1147     psdir=$ac_optarg ;;
1148
1149   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1150   | -silent | --silent | --silen | --sile | --sil)
1151     silent=yes ;;
1152
1153   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1154     ac_prev=sbindir ;;
1155   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1156   | --sbi=* | --sb=*)
1157     sbindir=$ac_optarg ;;
1158
1159   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1160   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1161   | --sharedst | --shareds | --shared | --share | --shar \
1162   | --sha | --sh)
1163     ac_prev=sharedstatedir ;;
1164   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1165   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1166   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1167   | --sha=* | --sh=*)
1168     sharedstatedir=$ac_optarg ;;
1169
1170   -site | --site | --sit)
1171     ac_prev=site ;;
1172   -site=* | --site=* | --sit=*)
1173     site=$ac_optarg ;;
1174
1175   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1176     ac_prev=srcdir ;;
1177   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1178     srcdir=$ac_optarg ;;
1179
1180   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1181   | --syscon | --sysco | --sysc | --sys | --sy)
1182     ac_prev=sysconfdir ;;
1183   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1184   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1185     sysconfdir=$ac_optarg ;;
1186
1187   -target | --target | --targe | --targ | --tar | --ta | --t)
1188     ac_prev=target_alias ;;
1189   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1190     target_alias=$ac_optarg ;;
1191
1192   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1193     verbose=yes ;;
1194
1195   -version | --version | --versio | --versi | --vers | -V)
1196     ac_init_version=: ;;
1197
1198   -with-* | --with-*)
1199     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1200     # Reject names that are not valid shell variable names.
1201     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1202       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1203    { (exit 1); exit 1; }; }
1204     ac_useropt_orig=$ac_useropt
1205     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1206     case $ac_user_opts in
1207       *"
1208 "with_$ac_useropt"
1209 "*) ;;
1210       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1211          ac_unrecognized_sep=', ';;
1212     esac
1213     eval with_$ac_useropt=\$ac_optarg ;;
1214
1215   -without-* | --without-*)
1216     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1217     # Reject names that are not valid shell variable names.
1218     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1219       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1220    { (exit 1); exit 1; }; }
1221     ac_useropt_orig=$ac_useropt
1222     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1223     case $ac_user_opts in
1224       *"
1225 "with_$ac_useropt"
1226 "*) ;;
1227       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1228          ac_unrecognized_sep=', ';;
1229     esac
1230     eval with_$ac_useropt=no ;;
1231
1232   --x)
1233     # Obsolete; use --with-x.
1234     with_x=yes ;;
1235
1236   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1237   | --x-incl | --x-inc | --x-in | --x-i)
1238     ac_prev=x_includes ;;
1239   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1240   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1241     x_includes=$ac_optarg ;;
1242
1243   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1244   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1245     ac_prev=x_libraries ;;
1246   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1247   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1248     x_libraries=$ac_optarg ;;
1249
1250   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1251 Try \`$0 --help' for more information." >&2
1252    { (exit 1); exit 1; }; }
1253     ;;
1254
1255   *=*)
1256     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1257     # Reject names that are not valid shell variable names.
1258     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1259       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1260    { (exit 1); exit 1; }; }
1261     eval $ac_envvar=\$ac_optarg
1262     export $ac_envvar ;;
1263
1264   *)
1265     # FIXME: should be removed in autoconf 3.0.
1266     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1267     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1268       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1269     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1270     ;;
1271
1272   esac
1273 done
1274
1275 if test -n "$ac_prev"; then
1276   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1277   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1278    { (exit 1); exit 1; }; }
1279 fi
1280
1281 if test -n "$ac_unrecognized_opts"; then
1282   case $enable_option_checking in
1283     no) ;;
1284     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1285    { (exit 1); exit 1; }; } ;;
1286     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1287   esac
1288 fi
1289
1290 # Check all directory arguments for consistency.
1291 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1292                 datadir sysconfdir sharedstatedir localstatedir includedir \
1293                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1294                 libdir localedir mandir
1295 do
1296   eval ac_val=\$$ac_var
1297   # Remove trailing slashes.
1298   case $ac_val in
1299     */ )
1300       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1301       eval $ac_var=\$ac_val;;
1302   esac
1303   # Be sure to have absolute directory names.
1304   case $ac_val in
1305     [\\/$]* | ?:[\\/]* )  continue;;
1306     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1307   esac
1308   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1309    { (exit 1); exit 1; }; }
1310 done
1311
1312 # There might be people who depend on the old broken behavior: `$host'
1313 # used to hold the argument of --host etc.
1314 # FIXME: To remove some day.
1315 build=$build_alias
1316 host=$host_alias
1317 target=$target_alias
1318
1319 # FIXME: To remove some day.
1320 if test "x$host_alias" != x; then
1321   if test "x$build_alias" = x; then
1322     cross_compiling=maybe
1323     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1324     If a cross compiler is detected then cross compile mode will be used." >&2
1325   elif test "x$build_alias" != "x$host_alias"; then
1326     cross_compiling=yes
1327   fi
1328 fi
1329
1330 ac_tool_prefix=
1331 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1332
1333 test "$silent" = yes && exec 6>/dev/null
1334
1335
1336 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1337 ac_ls_di=`ls -di .` &&
1338 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1339   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1340    { (exit 1); exit 1; }; }
1341 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1342   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1343    { (exit 1); exit 1; }; }
1344
1345
1346 # Find the source files, if location was not specified.
1347 if test -z "$srcdir"; then
1348   ac_srcdir_defaulted=yes
1349   # Try the directory containing this script, then the parent directory.
1350   ac_confdir=`$as_dirname -- "$as_myself" ||
1351 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1352          X"$as_myself" : 'X\(//\)[^/]' \| \
1353          X"$as_myself" : 'X\(//\)$' \| \
1354          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1355 $as_echo X"$as_myself" |
1356     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1357             s//\1/
1358             q
1359           }
1360           /^X\(\/\/\)[^/].*/{
1361             s//\1/
1362             q
1363           }
1364           /^X\(\/\/\)$/{
1365             s//\1/
1366             q
1367           }
1368           /^X\(\/\).*/{
1369             s//\1/
1370             q
1371           }
1372           s/.*/./; q'`
1373   srcdir=$ac_confdir
1374   if test ! -r "$srcdir/$ac_unique_file"; then
1375     srcdir=..
1376   fi
1377 else
1378   ac_srcdir_defaulted=no
1379 fi
1380 if test ! -r "$srcdir/$ac_unique_file"; then
1381   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1382   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1383    { (exit 1); exit 1; }; }
1384 fi
1385 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1386 ac_abs_confdir=`(
1387         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1388    { (exit 1); exit 1; }; }
1389         pwd)`
1390 # When building in place, set srcdir=.
1391 if test "$ac_abs_confdir" = "$ac_pwd"; then
1392   srcdir=.
1393 fi
1394 # Remove unnecessary trailing slashes from srcdir.
1395 # Double slashes in file names in object file debugging info
1396 # mess up M-x gdb in Emacs.
1397 case $srcdir in
1398 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1399 esac
1400 for ac_var in $ac_precious_vars; do
1401   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1402   eval ac_env_${ac_var}_value=\$${ac_var}
1403   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1404   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1405 done
1406
1407 #
1408 # Report the --help message.
1409 #
1410 if test "$ac_init_help" = "long"; then
1411   # Omit some internal or obsolete options to make the list less imposing.
1412   # This message is too long to be a string in the A/UX 3.1 sh.
1413   cat <<_ACEOF
1414 \`configure' configures PostgreSQL 9.3devel to adapt to many kinds of systems.
1415
1416 Usage: $0 [OPTION]... [VAR=VALUE]...
1417
1418 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1419 VAR=VALUE.  See below for descriptions of some of the useful variables.
1420
1421 Defaults for the options are specified in brackets.
1422
1423 Configuration:
1424   -h, --help              display this help and exit
1425       --help=short        display options specific to this package
1426       --help=recursive    display the short help of all the included packages
1427   -V, --version           display version information and exit
1428   -q, --quiet, --silent   do not print \`checking...' messages
1429       --cache-file=FILE   cache test results in FILE [disabled]
1430   -C, --config-cache      alias for \`--cache-file=config.cache'
1431   -n, --no-create         do not create output files
1432       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1433
1434 Installation directories:
1435   --prefix=PREFIX         install architecture-independent files in PREFIX
1436                           [$ac_default_prefix]
1437   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1438                           [PREFIX]
1439
1440 By default, \`make install' will install all the files in
1441 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1442 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1443 for instance \`--prefix=\$HOME'.
1444
1445 For better control, use the options below.
1446
1447 Fine tuning of the installation directories:
1448   --bindir=DIR            user executables [EPREFIX/bin]
1449   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1450   --libexecdir=DIR        program executables [EPREFIX/libexec]
1451   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1452   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1453   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1454   --libdir=DIR            object code libraries [EPREFIX/lib]
1455   --includedir=DIR        C header files [PREFIX/include]
1456   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1457   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1458   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1459   --infodir=DIR           info documentation [DATAROOTDIR/info]
1460   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1461   --mandir=DIR            man documentation [DATAROOTDIR/man]
1462   --docdir=DIR            documentation root [DATAROOTDIR/doc/postgresql]
1463   --htmldir=DIR           html documentation [DOCDIR]
1464   --dvidir=DIR            dvi documentation [DOCDIR]
1465   --pdfdir=DIR            pdf documentation [DOCDIR]
1466   --psdir=DIR             ps documentation [DOCDIR]
1467 _ACEOF
1468
1469   cat <<\_ACEOF
1470
1471 System types:
1472   --build=BUILD     configure for building on BUILD [guessed]
1473   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1474 _ACEOF
1475 fi
1476
1477 if test -n "$ac_init_help"; then
1478   case $ac_init_help in
1479      short | recursive ) echo "Configuration of PostgreSQL 9.3devel:";;
1480    esac
1481   cat <<\_ACEOF
1482
1483 Optional Features:
1484   --disable-option-checking  ignore unrecognized --enable/--with options
1485   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1486   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1487   --disable-integer-datetimes
1488                           disable 64-bit integer date/time support
1489   --enable-nls[=LANGUAGES]
1490                           enable Native Language Support
1491   --disable-rpath         do not embed shared library search path in
1492                           executables
1493   --disable-spinlocks     do not use spinlocks
1494   --enable-debug          build with debugging symbols (-g)
1495   --enable-profiling      build with profiling enabled
1496   --enable-coverage       build with coverage testing instrumentation
1497   --enable-dtrace         build with DTrace support
1498   --enable-depend         turn on automatic dependency tracking
1499   --enable-cassert        enable assertion checks (for debugging)
1500   --disable-thread-safety disable thread-safety in client libraries
1501   --disable-largefile     omit support for large files
1502   --disable-float4-byval  disable float4 passed by value
1503   --disable-float8-byval  disable float8 passed by value
1504
1505 Optional Packages:
1506   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1507   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1508   --with-template=NAME    override operating system template
1509   --with-includes=DIRS    look for additional header files in DIRS
1510   --with-libraries=DIRS   look for additional libraries in DIRS
1511   --with-libs=DIRS        alternative spelling of --with-libraries
1512   --with-pgport=PORTNUM   set default port number [5432]
1513   --with-blocksize=BLOCKSIZE
1514                           set table block size in kB [8]
1515   --with-segsize=SEGSIZE  set table segment size in GB [1]
1516   --with-wal-blocksize=BLOCKSIZE
1517                           set WAL block size in kB [8]
1518   --with-wal-segsize=SEGSIZE
1519                           set WAL segment size in MB [16]
1520   --with-CC=CMD           set compiler (deprecated)
1521   --with-tcl              build Tcl modules (PL/Tcl)
1522   --with-tclconfig=DIR    tclConfig.sh is in DIR
1523   --with-perl             build Perl modules (PL/Perl)
1524   --with-python           build Python modules (PL/Python)
1525   --with-gssapi           build with GSSAPI support
1526   --with-krb5             build with Kerberos 5 support
1527   --with-krb-srvnam=NAME  default service principal name in Kerberos
1528                           [postgres]
1529   --with-pam              build with PAM support
1530   --with-ldap             build with LDAP support
1531   --with-bonjour          build with Bonjour support
1532   --with-openssl          build with OpenSSL support
1533   --with-selinux          build with SELinux support
1534   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1535   --with-libedit-preferred
1536                           prefer BSD Libedit over GNU Readline
1537   --with-ossp-uuid        build contrib/uuid-ossp, requires OSSP UUID library
1538   --with-libxml           build with XML support
1539   --with-libxslt          use XSLT support when building contrib/xml2
1540   --with-system-tzdata=DIR
1541                           use system time zone data in DIR
1542   --without-zlib          do not use Zlib
1543   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1544
1545 Some influential environment variables:
1546   CC          C compiler command
1547   CFLAGS      C compiler flags
1548   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1549               nonstandard directory <lib dir>
1550   LIBS        libraries to pass to the linker, e.g. -l<library>
1551   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1552               you have headers in a nonstandard directory <include dir>
1553   CPP         C preprocessor
1554   LDFLAGS_EX  extra linker flags for linking executables only
1555   LDFLAGS_SL  extra linker flags for linking shared libraries only
1556   DOCBOOKSTYLE
1557               location of DocBook stylesheets
1558
1559 Use these variables to override the choices made by `configure' or to help
1560 it to find libraries and programs with nonstandard names/locations.
1561
1562 Report bugs to <pgsql-bugs@postgresql.org>.
1563 _ACEOF
1564 ac_status=$?
1565 fi
1566
1567 if test "$ac_init_help" = "recursive"; then
1568   # If there are subdirs, report their specific --help.
1569   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1570     test -d "$ac_dir" ||
1571       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1572       continue
1573     ac_builddir=.
1574
1575 case "$ac_dir" in
1576 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1577 *)
1578   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1579   # A ".." for each directory in $ac_dir_suffix.
1580   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1581   case $ac_top_builddir_sub in
1582   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1583   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1584   esac ;;
1585 esac
1586 ac_abs_top_builddir=$ac_pwd
1587 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1588 # for backward compatibility:
1589 ac_top_builddir=$ac_top_build_prefix
1590
1591 case $srcdir in
1592   .)  # We are building in place.
1593     ac_srcdir=.
1594     ac_top_srcdir=$ac_top_builddir_sub
1595     ac_abs_top_srcdir=$ac_pwd ;;
1596   [\\/]* | ?:[\\/]* )  # Absolute name.
1597     ac_srcdir=$srcdir$ac_dir_suffix;
1598     ac_top_srcdir=$srcdir
1599     ac_abs_top_srcdir=$srcdir ;;
1600   *) # Relative name.
1601     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1602     ac_top_srcdir=$ac_top_build_prefix$srcdir
1603     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1604 esac
1605 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1606
1607     cd "$ac_dir" || { ac_status=$?; continue; }
1608     # Check for guested configure.
1609     if test -f "$ac_srcdir/configure.gnu"; then
1610       echo &&
1611       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1612     elif test -f "$ac_srcdir/configure"; then
1613       echo &&
1614       $SHELL "$ac_srcdir/configure" --help=recursive
1615     else
1616       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1617     fi || ac_status=$?
1618     cd "$ac_pwd" || { ac_status=$?; break; }
1619   done
1620 fi
1621
1622 test -n "$ac_init_help" && exit $ac_status
1623 if $ac_init_version; then
1624   cat <<\_ACEOF
1625 PostgreSQL configure 9.3devel
1626 generated by GNU Autoconf 2.63
1627
1628 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1629 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1630 This configure script is free software; the Free Software Foundation
1631 gives unlimited permission to copy, distribute and modify it.
1632
1633 Copyright (c) 1996-2012, PostgreSQL Global Development Group
1634 _ACEOF
1635   exit
1636 fi
1637 cat >config.log <<_ACEOF
1638 This file contains any messages produced by compilers while
1639 running configure, to aid debugging if configure makes a mistake.
1640
1641 It was created by PostgreSQL $as_me 9.3devel, which was
1642 generated by GNU Autoconf 2.63.  Invocation command line was
1643
1644   $ $0 $@
1645
1646 _ACEOF
1647 exec 5>>config.log
1648 {
1649 cat <<_ASUNAME
1650 ## --------- ##
1651 ## Platform. ##
1652 ## --------- ##
1653
1654 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1655 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1656 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1657 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1658 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1659
1660 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1661 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1662
1663 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1664 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1665 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1666 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1667 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1668 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1669 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1670
1671 _ASUNAME
1672
1673 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1674 for as_dir in $PATH
1675 do
1676   IFS=$as_save_IFS
1677   test -z "$as_dir" && as_dir=.
1678   $as_echo "PATH: $as_dir"
1679 done
1680 IFS=$as_save_IFS
1681
1682 } >&5
1683
1684 cat >&5 <<_ACEOF
1685
1686
1687 ## ----------- ##
1688 ## Core tests. ##
1689 ## ----------- ##
1690
1691 _ACEOF
1692
1693
1694 # Keep a trace of the command line.
1695 # Strip out --no-create and --no-recursion so they do not pile up.
1696 # Strip out --silent because we don't want to record it for future runs.
1697 # Also quote any args containing shell meta-characters.
1698 # Make two passes to allow for proper duplicate-argument suppression.
1699 ac_configure_args=
1700 ac_configure_args0=
1701 ac_configure_args1=
1702 ac_must_keep_next=false
1703 for ac_pass in 1 2
1704 do
1705   for ac_arg
1706   do
1707     case $ac_arg in
1708     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1709     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1710     | -silent | --silent | --silen | --sile | --sil)
1711       continue ;;
1712     *\'*)
1713       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1714     esac
1715     case $ac_pass in
1716     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1717     2)
1718       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1719       if test $ac_must_keep_next = true; then
1720         ac_must_keep_next=false # Got value, back to normal.
1721       else
1722         case $ac_arg in
1723           *=* | --config-cache | -C | -disable-* | --disable-* \
1724           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1725           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1726           | -with-* | --with-* | -without-* | --without-* | --x)
1727             case "$ac_configure_args0 " in
1728               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1729             esac
1730             ;;
1731           -* ) ac_must_keep_next=true ;;
1732         esac
1733       fi
1734       ac_configure_args="$ac_configure_args '$ac_arg'"
1735       ;;
1736     esac
1737   done
1738 done
1739 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1740 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1741
1742 # When interrupted or exit'd, cleanup temporary files, and complete
1743 # config.log.  We remove comments because anyway the quotes in there
1744 # would cause problems or look ugly.
1745 # WARNING: Use '\'' to represent an apostrophe within the trap.
1746 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1747 trap 'exit_status=$?
1748   # Save into config.log some information that might help in debugging.
1749   {
1750     echo
1751
1752     cat <<\_ASBOX
1753 ## ---------------- ##
1754 ## Cache variables. ##
1755 ## ---------------- ##
1756 _ASBOX
1757     echo
1758     # The following way of writing the cache mishandles newlines in values,
1759 (
1760   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1761     eval ac_val=\$$ac_var
1762     case $ac_val in #(
1763     *${as_nl}*)
1764       case $ac_var in #(
1765       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1766 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1767       esac
1768       case $ac_var in #(
1769       _ | IFS | as_nl) ;; #(
1770       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1771       *) $as_unset $ac_var ;;
1772       esac ;;
1773     esac
1774   done
1775   (set) 2>&1 |
1776     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1777     *${as_nl}ac_space=\ *)
1778       sed -n \
1779         "s/'\''/'\''\\\\'\'''\''/g;
1780           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1781       ;; #(
1782     *)
1783       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1784       ;;
1785     esac |
1786     sort
1787 )
1788     echo
1789
1790     cat <<\_ASBOX
1791 ## ----------------- ##
1792 ## Output variables. ##
1793 ## ----------------- ##
1794 _ASBOX
1795     echo
1796     for ac_var in $ac_subst_vars
1797     do
1798       eval ac_val=\$$ac_var
1799       case $ac_val in
1800       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1801       esac
1802       $as_echo "$ac_var='\''$ac_val'\''"
1803     done | sort
1804     echo
1805
1806     if test -n "$ac_subst_files"; then
1807       cat <<\_ASBOX
1808 ## ------------------- ##
1809 ## File substitutions. ##
1810 ## ------------------- ##
1811 _ASBOX
1812       echo
1813       for ac_var in $ac_subst_files
1814       do
1815         eval ac_val=\$$ac_var
1816         case $ac_val in
1817         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1818         esac
1819         $as_echo "$ac_var='\''$ac_val'\''"
1820       done | sort
1821       echo
1822     fi
1823
1824     if test -s confdefs.h; then
1825       cat <<\_ASBOX
1826 ## ----------- ##
1827 ## confdefs.h. ##
1828 ## ----------- ##
1829 _ASBOX
1830       echo
1831       cat confdefs.h
1832       echo
1833     fi
1834     test "$ac_signal" != 0 &&
1835       $as_echo "$as_me: caught signal $ac_signal"
1836     $as_echo "$as_me: exit $exit_status"
1837   } >&5
1838   rm -f core *.core core.conftest.* &&
1839     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1840     exit $exit_status
1841 ' 0
1842 for ac_signal in 1 2 13 15; do
1843   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1844 done
1845 ac_signal=0
1846
1847 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1848 rm -f -r conftest* confdefs.h
1849
1850 # Predefined preprocessor variables.
1851
1852 cat >>confdefs.h <<_ACEOF
1853 #define PACKAGE_NAME "$PACKAGE_NAME"
1854 _ACEOF
1855
1856
1857 cat >>confdefs.h <<_ACEOF
1858 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1859 _ACEOF
1860
1861
1862 cat >>confdefs.h <<_ACEOF
1863 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1864 _ACEOF
1865
1866
1867 cat >>confdefs.h <<_ACEOF
1868 #define PACKAGE_STRING "$PACKAGE_STRING"
1869 _ACEOF
1870
1871
1872 cat >>confdefs.h <<_ACEOF
1873 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1874 _ACEOF
1875
1876
1877 # Let the site file select an alternate cache file if it wants to.
1878 # Prefer an explicitly selected file to automatically selected ones.
1879 ac_site_file1=NONE
1880 ac_site_file2=NONE
1881 if test -n "$CONFIG_SITE"; then
1882   ac_site_file1=$CONFIG_SITE
1883 elif test "x$prefix" != xNONE; then
1884   ac_site_file1=$prefix/share/config.site
1885   ac_site_file2=$prefix/etc/config.site
1886 else
1887   ac_site_file1=$ac_default_prefix/share/config.site
1888   ac_site_file2=$ac_default_prefix/etc/config.site
1889 fi
1890 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1891 do
1892   test "x$ac_site_file" = xNONE && continue
1893   if test -r "$ac_site_file"; then
1894     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1895 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1896     sed 's/^/| /' "$ac_site_file" >&5
1897     . "$ac_site_file"
1898   fi
1899 done
1900
1901 if test -r "$cache_file"; then
1902   # Some versions of bash will fail to source /dev/null (special
1903   # files actually), so we avoid doing that.
1904   if test -f "$cache_file"; then
1905     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1906 $as_echo "$as_me: loading cache $cache_file" >&6;}
1907     case $cache_file in
1908       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1909       *)                      . "./$cache_file";;
1910     esac
1911   fi
1912 else
1913   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1914 $as_echo "$as_me: creating cache $cache_file" >&6;}
1915   >$cache_file
1916 fi
1917
1918 # Check that the precious variables saved in the cache have kept the same
1919 # value.
1920 ac_cache_corrupted=false
1921 for ac_var in $ac_precious_vars; do
1922   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1923   eval ac_new_set=\$ac_env_${ac_var}_set
1924   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1925   eval ac_new_val=\$ac_env_${ac_var}_value
1926   case $ac_old_set,$ac_new_set in
1927     set,)
1928       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1929 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1930       ac_cache_corrupted=: ;;
1931     ,set)
1932       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1933 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1934       ac_cache_corrupted=: ;;
1935     ,);;
1936     *)
1937       if test "x$ac_old_val" != "x$ac_new_val"; then
1938         # differences in whitespace do not lead to failure.
1939         ac_old_val_w=`echo x $ac_old_val`
1940         ac_new_val_w=`echo x $ac_new_val`
1941         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1942           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1943 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1944           ac_cache_corrupted=:
1945         else
1946           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1947 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1948           eval $ac_var=\$ac_old_val
1949         fi
1950         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1951 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1952         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1953 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1954       fi;;
1955   esac
1956   # Pass precious variables to config.status.
1957   if test "$ac_new_set" = set; then
1958     case $ac_new_val in
1959     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1960     *) ac_arg=$ac_var=$ac_new_val ;;
1961     esac
1962     case " $ac_configure_args " in
1963       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1964       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1965     esac
1966   fi
1967 done
1968 if $ac_cache_corrupted; then
1969   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1970 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1971   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1972 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1973   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1974 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1975    { (exit 1); exit 1; }; }
1976 fi
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002 ac_ext=c
2003 ac_cpp='$CPP $CPPFLAGS'
2004 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2005 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2006 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2007
2008
2009
2010
2011
2012
2013 ac_aux_dir=
2014 for ac_dir in config "$srcdir"/config; do
2015   if test -f "$ac_dir/install-sh"; then
2016     ac_aux_dir=$ac_dir
2017     ac_install_sh="$ac_aux_dir/install-sh -c"
2018     break
2019   elif test -f "$ac_dir/install.sh"; then
2020     ac_aux_dir=$ac_dir
2021     ac_install_sh="$ac_aux_dir/install.sh -c"
2022     break
2023   elif test -f "$ac_dir/shtool"; then
2024     ac_aux_dir=$ac_dir
2025     ac_install_sh="$ac_aux_dir/shtool install -c"
2026     break
2027   fi
2028 done
2029 if test -z "$ac_aux_dir"; then
2030   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2031 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2032    { (exit 1); exit 1; }; }
2033 fi
2034
2035 # These three variables are undocumented and unsupported,
2036 # and are intended to be withdrawn in a future Autoconf release.
2037 # They can cause serious problems if a builder's source tree is in a directory
2038 # whose full name contains unusual characters.
2039 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2040 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2041 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2042
2043
2044
2045 configure_args=$ac_configure_args
2046
2047
2048
2049 cat >>confdefs.h <<_ACEOF
2050 #define PG_VERSION "$PACKAGE_VERSION"
2051 _ACEOF
2052
2053 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2054
2055
2056 cat >>confdefs.h <<_ACEOF
2057 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2058 _ACEOF
2059
2060
2061 # Make sure we can run config.sub.
2062 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2063   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2064 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2065    { (exit 1); exit 1; }; }
2066
2067 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2068 $as_echo_n "checking build system type... " >&6; }
2069 if test "${ac_cv_build+set}" = set; then
2070   $as_echo_n "(cached) " >&6
2071 else
2072   ac_build_alias=$build_alias
2073 test "x$ac_build_alias" = x &&
2074   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2075 test "x$ac_build_alias" = x &&
2076   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2077 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2078    { (exit 1); exit 1; }; }
2079 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2080   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2081 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2082    { (exit 1); exit 1; }; }
2083
2084 fi
2085 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2086 $as_echo "$ac_cv_build" >&6; }
2087 case $ac_cv_build in
2088 *-*-*) ;;
2089 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2090 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2091    { (exit 1); exit 1; }; };;
2092 esac
2093 build=$ac_cv_build
2094 ac_save_IFS=$IFS; IFS='-'
2095 set x $ac_cv_build
2096 shift
2097 build_cpu=$1
2098 build_vendor=$2
2099 shift; shift
2100 # Remember, the first character of IFS is used to create $*,
2101 # except with old shells:
2102 build_os=$*
2103 IFS=$ac_save_IFS
2104 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2105
2106
2107 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2108 $as_echo_n "checking host system type... " >&6; }
2109 if test "${ac_cv_host+set}" = set; then
2110   $as_echo_n "(cached) " >&6
2111 else
2112   if test "x$host_alias" = x; then
2113   ac_cv_host=$ac_cv_build
2114 else
2115   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2116     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2117 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2118    { (exit 1); exit 1; }; }
2119 fi
2120
2121 fi
2122 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2123 $as_echo "$ac_cv_host" >&6; }
2124 case $ac_cv_host in
2125 *-*-*) ;;
2126 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2127 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2128    { (exit 1); exit 1; }; };;
2129 esac
2130 host=$ac_cv_host
2131 ac_save_IFS=$IFS; IFS='-'
2132 set x $ac_cv_host
2133 shift
2134 host_cpu=$1
2135 host_vendor=$2
2136 shift; shift
2137 # Remember, the first character of IFS is used to create $*,
2138 # except with old shells:
2139 host_os=$*
2140 IFS=$ac_save_IFS
2141 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2142
2143
2144
2145 template=
2146 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2147 $as_echo_n "checking which template to use... " >&6; }
2148
2149
2150
2151
2152 # Check whether --with-template was given.
2153 if test "${with_template+set}" = set; then
2154   withval=$with_template;
2155   case $withval in
2156     yes)
2157       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2158 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2159    { (exit 1); exit 1; }; }
2160       ;;
2161     no)
2162       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2163 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2164    { (exit 1); exit 1; }; }
2165       ;;
2166     *)
2167
2168   case $withval in
2169     list)   echo; ls "$srcdir/src/template"; exit;;
2170     *)      if test -f "$srcdir/src/template/$with_template" ; then
2171               template=$withval
2172             else
2173               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2174 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2175    { (exit 1); exit 1; }; }
2176             fi;;
2177   esac
2178
2179       ;;
2180   esac
2181
2182 else
2183
2184 # --with-template not given
2185
2186 case $host_os in
2187      aix*) template=aix ;;
2188   cygwin*) template=cygwin ;;
2189   darwin*) template=darwin ;;
2190 dragonfly*) template=netbsd ;;
2191  freebsd*) template=freebsd ;;
2192     hpux*) template=hpux ;;
2193     irix*) template=irix ;;
2194  linux*|gnu*|k*bsd*-gnu)
2195            template=linux ;;
2196    mingw*) template=win32 ;;
2197   netbsd*) template=netbsd ;;
2198  openbsd*) template=openbsd ;;
2199      osf*) template=osf ;;
2200      sco*) template=sco ;;
2201  solaris*) template=solaris ;;
2202    sysv5*) template=unixware ;;
2203 esac
2204
2205   if test x"$template" = x"" ; then
2206     { { $as_echo "$as_me:$LINENO: error:
2207 *******************************************************************
2208 PostgreSQL has apparently not been ported to your platform yet.
2209 To try a manual configuration, look into the src/template directory
2210 for a similar platform and use the '--with-template=' option.
2211
2212 Please also contact <pgsql-bugs@postgresql.org> to see about
2213 rectifying this.  Include the above 'checking host system type...'
2214 line.
2215 *******************************************************************
2216 " >&5
2217 $as_echo "$as_me: error:
2218 *******************************************************************
2219 PostgreSQL has apparently not been ported to your platform yet.
2220 To try a manual configuration, look into the src/template directory
2221 for a similar platform and use the '--with-template=' option.
2222
2223 Please also contact <pgsql-bugs@postgresql.org> to see about
2224 rectifying this.  Include the above 'checking host system type...'
2225 line.
2226 *******************************************************************
2227 " >&2;}
2228    { (exit 1); exit 1; }; }
2229   fi
2230
2231
2232 fi
2233
2234
2235
2236 { $as_echo "$as_me:$LINENO: result: $template" >&5
2237 $as_echo "$template" >&6; }
2238
2239 PORTNAME=$template
2240
2241
2242 # Initialize default assumption that we do not need separate assembly code
2243 # for TAS (test-and-set).  This can be overridden by the template file
2244 # when it's executed.
2245 need_tas=no
2246 tas_file=dummy.s
2247
2248
2249
2250 ##
2251 ## Command line options
2252 ##
2253
2254 #
2255 # Add non-standard directories to the include path
2256 #
2257
2258
2259
2260 # Check whether --with-includes was given.
2261 if test "${with_includes+set}" = set; then
2262   withval=$with_includes;
2263   case $withval in
2264     yes)
2265       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2266 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2267    { (exit 1); exit 1; }; }
2268       ;;
2269     no)
2270       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2271 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2272    { (exit 1); exit 1; }; }
2273       ;;
2274     *)
2275
2276       ;;
2277   esac
2278
2279 fi
2280
2281
2282
2283
2284 #
2285 # Add non-standard directories to the library search path
2286 #
2287
2288
2289
2290 # Check whether --with-libraries was given.
2291 if test "${with_libraries+set}" = set; then
2292   withval=$with_libraries;
2293   case $withval in
2294     yes)
2295       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2296 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2297    { (exit 1); exit 1; }; }
2298       ;;
2299     no)
2300       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2301 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2302    { (exit 1); exit 1; }; }
2303       ;;
2304     *)
2305       LIBRARY_DIRS=$withval
2306       ;;
2307   esac
2308
2309 fi
2310
2311
2312
2313
2314
2315
2316 # Check whether --with-libs was given.
2317 if test "${with_libs+set}" = set; then
2318   withval=$with_libs;
2319   case $withval in
2320     yes)
2321       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2322 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2323    { (exit 1); exit 1; }; }
2324       ;;
2325     no)
2326       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2327 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2328    { (exit 1); exit 1; }; }
2329       ;;
2330     *)
2331       LIBRARY_DIRS=$withval
2332       ;;
2333   esac
2334
2335 fi
2336
2337
2338
2339
2340 #
2341 # 64-bit integer date/time storage: enabled by default.
2342 #
2343 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2344 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2345
2346
2347 # Check whether --enable-integer-datetimes was given.
2348 if test "${enable_integer_datetimes+set}" = set; then
2349   enableval=$enable_integer_datetimes;
2350   case $enableval in
2351     yes)
2352
2353 cat >>confdefs.h <<\_ACEOF
2354 #define USE_INTEGER_DATETIMES 1
2355 _ACEOF
2356
2357       ;;
2358     no)
2359       :
2360       ;;
2361     *)
2362       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2363 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2364    { (exit 1); exit 1; }; }
2365       ;;
2366   esac
2367
2368 else
2369   enable_integer_datetimes=yes
2370
2371 cat >>confdefs.h <<\_ACEOF
2372 #define USE_INTEGER_DATETIMES 1
2373 _ACEOF
2374
2375 fi
2376
2377
2378 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2379 $as_echo "$enable_integer_datetimes" >&6; }
2380
2381
2382 #
2383 # NLS
2384 #
2385 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2386 $as_echo_n "checking whether NLS is wanted... " >&6; }
2387
2388
2389 # Check whether --enable-nls was given.
2390 if test "${enable_nls+set}" = set; then
2391   enableval=$enable_nls;
2392   case $enableval in
2393     yes)
2394       :
2395       ;;
2396     no)
2397       :
2398       ;;
2399     *)
2400       enable_nls=yes
2401 WANTED_LANGUAGES=$enableval
2402       ;;
2403   esac
2404
2405 else
2406   enable_nls=no
2407 fi
2408
2409
2410
2411 if test "$enable_nls" = yes; then
2412
2413 cat >>confdefs.h <<\_ACEOF
2414 #define ENABLE_NLS 1
2415 _ACEOF
2416
2417 fi
2418
2419 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2420 $as_echo "$enable_nls" >&6; }
2421
2422
2423
2424 #
2425 # Default port number (--with-pgport), default 5432
2426 #
2427 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2428 $as_echo_n "checking for default port number... " >&6; }
2429
2430
2431
2432 # Check whether --with-pgport was given.
2433 if test "${with_pgport+set}" = set; then
2434   withval=$with_pgport;
2435   case $withval in
2436     yes)
2437       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2438 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2439    { (exit 1); exit 1; }; }
2440       ;;
2441     no)
2442       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2443 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2444    { (exit 1); exit 1; }; }
2445       ;;
2446     *)
2447       default_port=$withval
2448       ;;
2449   esac
2450
2451 else
2452   default_port=5432
2453 fi
2454
2455
2456 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2457 $as_echo "$default_port" >&6; }
2458 # Need both of these because some places want an integer and some a string
2459
2460 cat >>confdefs.h <<_ACEOF
2461 #define DEF_PGPORT ${default_port}
2462 _ACEOF
2463
2464
2465 cat >>confdefs.h <<_ACEOF
2466 #define DEF_PGPORT_STR "${default_port}"
2467 _ACEOF
2468
2469
2470
2471 #
2472 # '-rpath'-like feature can be disabled
2473 #
2474
2475
2476 # Check whether --enable-rpath was given.
2477 if test "${enable_rpath+set}" = set; then
2478   enableval=$enable_rpath;
2479   case $enableval in
2480     yes)
2481       :
2482       ;;
2483     no)
2484       :
2485       ;;
2486     *)
2487       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2488 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2489    { (exit 1); exit 1; }; }
2490       ;;
2491   esac
2492
2493 else
2494   enable_rpath=yes
2495
2496 fi
2497
2498
2499
2500
2501 #
2502 # Spinlocks
2503 #
2504
2505
2506 # Check whether --enable-spinlocks was given.
2507 if test "${enable_spinlocks+set}" = set; then
2508   enableval=$enable_spinlocks;
2509   case $enableval in
2510     yes)
2511       :
2512       ;;
2513     no)
2514       :
2515       ;;
2516     *)
2517       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2518 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2519    { (exit 1); exit 1; }; }
2520       ;;
2521   esac
2522
2523 else
2524   enable_spinlocks=yes
2525
2526 fi
2527
2528
2529
2530 #
2531 # --enable-debug adds -g to compiler flags
2532 #
2533
2534
2535 # Check whether --enable-debug was given.
2536 if test "${enable_debug+set}" = set; then
2537   enableval=$enable_debug;
2538   case $enableval in
2539     yes)
2540       :
2541       ;;
2542     no)
2543       :
2544       ;;
2545     *)
2546       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2547 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2548    { (exit 1); exit 1; }; }
2549       ;;
2550   esac
2551
2552 else
2553   enable_debug=no
2554
2555 fi
2556
2557
2558
2559
2560 #
2561 # --enable-profiling enables gcc profiling
2562 #
2563
2564
2565 # Check whether --enable-profiling was given.
2566 if test "${enable_profiling+set}" = set; then
2567   enableval=$enable_profiling;
2568   case $enableval in
2569     yes)
2570       :
2571       ;;
2572     no)
2573       :
2574       ;;
2575     *)
2576       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2577 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2578    { (exit 1); exit 1; }; }
2579       ;;
2580   esac
2581
2582 else
2583   enable_profiling=no
2584
2585 fi
2586
2587
2588
2589 #
2590 # --enable-coverage enables generation of code coverage metrics with gcov
2591 #
2592
2593
2594 # Check whether --enable-coverage was given.
2595 if test "${enable_coverage+set}" = set; then
2596   enableval=$enable_coverage;
2597   case $enableval in
2598     yes)
2599       for ac_prog in gcov
2600 do
2601   # Extract the first word of "$ac_prog", so it can be a program name with args.
2602 set dummy $ac_prog; ac_word=$2
2603 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2604 $as_echo_n "checking for $ac_word... " >&6; }
2605 if test "${ac_cv_prog_GCOV+set}" = set; then
2606   $as_echo_n "(cached) " >&6
2607 else
2608   if test -n "$GCOV"; then
2609   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2610 else
2611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2612 for as_dir in $PATH
2613 do
2614   IFS=$as_save_IFS
2615   test -z "$as_dir" && as_dir=.
2616   for ac_exec_ext in '' $ac_executable_extensions; do
2617   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2618     ac_cv_prog_GCOV="$ac_prog"
2619     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2620     break 2
2621   fi
2622 done
2623 done
2624 IFS=$as_save_IFS
2625
2626 fi
2627 fi
2628 GCOV=$ac_cv_prog_GCOV
2629 if test -n "$GCOV"; then
2630   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2631 $as_echo "$GCOV" >&6; }
2632 else
2633   { $as_echo "$as_me:$LINENO: result: no" >&5
2634 $as_echo "no" >&6; }
2635 fi
2636
2637
2638   test -n "$GCOV" && break
2639 done
2640
2641 if test -z "$GCOV"; then
2642   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2643 $as_echo "$as_me: error: gcov not found" >&2;}
2644    { (exit 1); exit 1; }; }
2645 fi
2646 for ac_prog in lcov
2647 do
2648   # Extract the first word of "$ac_prog", so it can be a program name with args.
2649 set dummy $ac_prog; ac_word=$2
2650 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2651 $as_echo_n "checking for $ac_word... " >&6; }
2652 if test "${ac_cv_prog_LCOV+set}" = set; then
2653   $as_echo_n "(cached) " >&6
2654 else
2655   if test -n "$LCOV"; then
2656   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2657 else
2658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2659 for as_dir in $PATH
2660 do
2661   IFS=$as_save_IFS
2662   test -z "$as_dir" && as_dir=.
2663   for ac_exec_ext in '' $ac_executable_extensions; do
2664   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2665     ac_cv_prog_LCOV="$ac_prog"
2666     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2667     break 2
2668   fi
2669 done
2670 done
2671 IFS=$as_save_IFS
2672
2673 fi
2674 fi
2675 LCOV=$ac_cv_prog_LCOV
2676 if test -n "$LCOV"; then
2677   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2678 $as_echo "$LCOV" >&6; }
2679 else
2680   { $as_echo "$as_me:$LINENO: result: no" >&5
2681 $as_echo "no" >&6; }
2682 fi
2683
2684
2685   test -n "$LCOV" && break
2686 done
2687
2688 if test -z "$LCOV"; then
2689   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2690 $as_echo "$as_me: error: lcov not found" >&2;}
2691    { (exit 1); exit 1; }; }
2692 fi
2693 for ac_prog in genhtml
2694 do
2695   # Extract the first word of "$ac_prog", so it can be a program name with args.
2696 set dummy $ac_prog; ac_word=$2
2697 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2698 $as_echo_n "checking for $ac_word... " >&6; }
2699 if test "${ac_cv_prog_GENHTML+set}" = set; then
2700   $as_echo_n "(cached) " >&6
2701 else
2702   if test -n "$GENHTML"; then
2703   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2704 else
2705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2706 for as_dir in $PATH
2707 do
2708   IFS=$as_save_IFS
2709   test -z "$as_dir" && as_dir=.
2710   for ac_exec_ext in '' $ac_executable_extensions; do
2711   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2712     ac_cv_prog_GENHTML="$ac_prog"
2713     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2714     break 2
2715   fi
2716 done
2717 done
2718 IFS=$as_save_IFS
2719
2720 fi
2721 fi
2722 GENHTML=$ac_cv_prog_GENHTML
2723 if test -n "$GENHTML"; then
2724   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2725 $as_echo "$GENHTML" >&6; }
2726 else
2727   { $as_echo "$as_me:$LINENO: result: no" >&5
2728 $as_echo "no" >&6; }
2729 fi
2730
2731
2732   test -n "$GENHTML" && break
2733 done
2734
2735 if test -z "$GENHTML"; then
2736   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2737 $as_echo "$as_me: error: genhtml not found" >&2;}
2738    { (exit 1); exit 1; }; }
2739 fi
2740       ;;
2741     no)
2742       :
2743       ;;
2744     *)
2745       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2746 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2747    { (exit 1); exit 1; }; }
2748       ;;
2749   esac
2750
2751 else
2752   enable_coverage=no
2753
2754 fi
2755
2756
2757
2758
2759 #
2760 # DTrace
2761 #
2762
2763
2764 # Check whether --enable-dtrace was given.
2765 if test "${enable_dtrace+set}" = set; then
2766   enableval=$enable_dtrace;
2767   case $enableval in
2768     yes)
2769       for ac_prog in dtrace
2770 do
2771   # Extract the first word of "$ac_prog", so it can be a program name with args.
2772 set dummy $ac_prog; ac_word=$2
2773 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2774 $as_echo_n "checking for $ac_word... " >&6; }
2775 if test "${ac_cv_prog_DTRACE+set}" = set; then
2776   $as_echo_n "(cached) " >&6
2777 else
2778   if test -n "$DTRACE"; then
2779   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2780 else
2781 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2782 for as_dir in $PATH
2783 do
2784   IFS=$as_save_IFS
2785   test -z "$as_dir" && as_dir=.
2786   for ac_exec_ext in '' $ac_executable_extensions; do
2787   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2788     ac_cv_prog_DTRACE="$ac_prog"
2789     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2790     break 2
2791   fi
2792 done
2793 done
2794 IFS=$as_save_IFS
2795
2796 fi
2797 fi
2798 DTRACE=$ac_cv_prog_DTRACE
2799 if test -n "$DTRACE"; then
2800   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2801 $as_echo "$DTRACE" >&6; }
2802 else
2803   { $as_echo "$as_me:$LINENO: result: no" >&5
2804 $as_echo "no" >&6; }
2805 fi
2806
2807
2808   test -n "$DTRACE" && break
2809 done
2810
2811 if test -z "$DTRACE"; then
2812   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2813 $as_echo "$as_me: error: dtrace not found" >&2;}
2814    { (exit 1); exit 1; }; }
2815 fi
2816
2817       ;;
2818     no)
2819       :
2820       ;;
2821     *)
2822       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2823 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2824    { (exit 1); exit 1; }; }
2825       ;;
2826   esac
2827
2828 else
2829   enable_dtrace=no
2830
2831 fi
2832
2833
2834
2835
2836 #
2837 # Block size
2838 #
2839 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2840 $as_echo_n "checking for block size... " >&6; }
2841
2842
2843
2844 # Check whether --with-blocksize was given.
2845 if test "${with_blocksize+set}" = set; then
2846   withval=$with_blocksize;
2847   case $withval in
2848     yes)
2849       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2850 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2851    { (exit 1); exit 1; }; }
2852       ;;
2853     no)
2854       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2855 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2856    { (exit 1); exit 1; }; }
2857       ;;
2858     *)
2859       blocksize=$withval
2860       ;;
2861   esac
2862
2863 else
2864   blocksize=8
2865 fi
2866
2867
2868 case ${blocksize} in
2869   1) BLCKSZ=1024;;
2870   2) BLCKSZ=2048;;
2871   4) BLCKSZ=4096;;
2872   8) BLCKSZ=8192;;
2873  16) BLCKSZ=16384;;
2874  32) BLCKSZ=32768;;
2875   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2876 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2877    { (exit 1); exit 1; }; }
2878 esac
2879 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2880 $as_echo "${blocksize}kB" >&6; }
2881
2882
2883 cat >>confdefs.h <<_ACEOF
2884 #define BLCKSZ ${BLCKSZ}
2885 _ACEOF
2886
2887
2888 #
2889 # Relation segment size
2890 #
2891 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2892 $as_echo_n "checking for segment size... " >&6; }
2893
2894
2895
2896 # Check whether --with-segsize was given.
2897 if test "${with_segsize+set}" = set; then
2898   withval=$with_segsize;
2899   case $withval in
2900     yes)
2901       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2902 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2903    { (exit 1); exit 1; }; }
2904       ;;
2905     no)
2906       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2907 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2908    { (exit 1); exit 1; }; }
2909       ;;
2910     *)
2911       segsize=$withval
2912       ;;
2913   esac
2914
2915 else
2916   segsize=1
2917 fi
2918
2919
2920 # this expression is set up to avoid unnecessary integer overflow
2921 # blocksize is already guaranteed to be a factor of 1024
2922 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2923 test $? -eq 0 || exit 1
2924 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2925 $as_echo "${segsize}GB" >&6; }
2926
2927
2928 cat >>confdefs.h <<_ACEOF
2929 #define RELSEG_SIZE ${RELSEG_SIZE}
2930 _ACEOF
2931
2932
2933 #
2934 # WAL block size
2935 #
2936 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2937 $as_echo_n "checking for WAL block size... " >&6; }
2938
2939
2940
2941 # Check whether --with-wal-blocksize was given.
2942 if test "${with_wal_blocksize+set}" = set; then
2943   withval=$with_wal_blocksize;
2944   case $withval in
2945     yes)
2946       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2947 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2948    { (exit 1); exit 1; }; }
2949       ;;
2950     no)
2951       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2952 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2953    { (exit 1); exit 1; }; }
2954       ;;
2955     *)
2956       wal_blocksize=$withval
2957       ;;
2958   esac
2959
2960 else
2961   wal_blocksize=8
2962 fi
2963
2964
2965 case ${wal_blocksize} in
2966   1) XLOG_BLCKSZ=1024;;
2967   2) XLOG_BLCKSZ=2048;;
2968   4) XLOG_BLCKSZ=4096;;
2969   8) XLOG_BLCKSZ=8192;;
2970  16) XLOG_BLCKSZ=16384;;
2971  32) XLOG_BLCKSZ=32768;;
2972  64) XLOG_BLCKSZ=65536;;
2973   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
2974 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
2975    { (exit 1); exit 1; }; }
2976 esac
2977 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
2978 $as_echo "${wal_blocksize}kB" >&6; }
2979
2980
2981 cat >>confdefs.h <<_ACEOF
2982 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
2983 _ACEOF
2984
2985
2986 #
2987 # WAL segment size
2988 #
2989 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
2990 $as_echo_n "checking for WAL segment size... " >&6; }
2991
2992
2993
2994 # Check whether --with-wal-segsize was given.
2995 if test "${with_wal_segsize+set}" = set; then
2996   withval=$with_wal_segsize;
2997   case $withval in
2998     yes)
2999       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3000 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3001    { (exit 1); exit 1; }; }
3002       ;;
3003     no)
3004       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3005 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3006    { (exit 1); exit 1; }; }
3007       ;;
3008     *)
3009       wal_segsize=$withval
3010       ;;
3011   esac
3012
3013 else
3014   wal_segsize=16
3015 fi
3016
3017
3018 case ${wal_segsize} in
3019   1) ;;
3020   2) ;;
3021   4) ;;
3022   8) ;;
3023  16) ;;
3024  32) ;;
3025  64) ;;
3026   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3027 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3028    { (exit 1); exit 1; }; }
3029 esac
3030 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3031 $as_echo "${wal_segsize}MB" >&6; }
3032
3033
3034 cat >>confdefs.h <<_ACEOF
3035 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3036 _ACEOF
3037
3038
3039 #
3040 # C compiler
3041 #
3042
3043 # For historical reasons you can also use --with-CC to specify the C compiler
3044 # to use, although the standard way to do this is to set the CC environment
3045 # variable.
3046
3047
3048
3049 # Check whether --with-CC was given.
3050 if test "${with_CC+set}" = set; then
3051   withval=$with_CC;
3052   case $withval in
3053     yes)
3054       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3055 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3056    { (exit 1); exit 1; }; }
3057       ;;
3058     no)
3059       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3060 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3061    { (exit 1); exit 1; }; }
3062       ;;
3063     *)
3064       CC=$with_CC
3065       ;;
3066   esac
3067
3068 fi
3069
3070
3071
3072 case $template in
3073   aix) pgac_cc_list="gcc xlc";;
3074  irix) pgac_cc_list="cc";; # no gcc
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 # Some versions of GCC support some additional useful warning flags.
3948 # Check whether they are supported, and add them to CFLAGS if so.
3949 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
3950 # but has its own.  Also check other compiler-specific flags here.
3951
3952 if test "$GCC" = yes -a "$ICC" = no; then
3953   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
3954   # These work in some but not all gcc versions
3955   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wdeclaration-after-statement" >&5
3956 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
3957 if test "${pgac_cv_prog_cc_cflags__Wdeclaration_after_statement+set}" = set; then
3958   $as_echo_n "(cached) " >&6
3959 else
3960   pgac_save_CFLAGS=$CFLAGS
3961 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
3962 ac_save_c_werror_flag=$ac_c_werror_flag
3963 ac_c_werror_flag=yes
3964 cat >conftest.$ac_ext <<_ACEOF
3965 /* confdefs.h.  */
3966 _ACEOF
3967 cat confdefs.h >>conftest.$ac_ext
3968 cat >>conftest.$ac_ext <<_ACEOF
3969 /* end confdefs.h.  */
3970
3971 int
3972 main ()
3973 {
3974
3975   ;
3976   return 0;
3977 }
3978 _ACEOF
3979 rm -f conftest.$ac_objext
3980 if { (ac_try="$ac_compile"
3981 case "(($ac_try" in
3982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3983   *) ac_try_echo=$ac_try;;
3984 esac
3985 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3986 $as_echo "$ac_try_echo") >&5
3987   (eval "$ac_compile") 2>conftest.er1
3988   ac_status=$?
3989   grep -v '^ *+' conftest.er1 >conftest.err
3990   rm -f conftest.er1
3991   cat conftest.err >&5
3992   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3993   (exit $ac_status); } && {
3994          test -z "$ac_c_werror_flag" ||
3995          test ! -s conftest.err
3996        } && test -s conftest.$ac_objext; then
3997   pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=yes
3998 else
3999   $as_echo "$as_me: failed program was:" >&5
4000 sed 's/^/| /' conftest.$ac_ext >&5
4001
4002         pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=no
4003 fi
4004
4005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4006 ac_c_werror_flag=$ac_save_c_werror_flag
4007 CFLAGS="$pgac_save_CFLAGS"
4008 fi
4009 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&5
4010 $as_echo "$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&6; }
4011 if test x"$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" = x"yes"; then
4012   CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4013 fi
4014
4015   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wendif-labels" >&5
4016 $as_echo_n "checking whether $CC supports -Wendif-labels... " >&6; }
4017 if test "${pgac_cv_prog_cc_cflags__Wendif_labels+set}" = set; then
4018   $as_echo_n "(cached) " >&6
4019 else
4020   pgac_save_CFLAGS=$CFLAGS
4021 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4022 ac_save_c_werror_flag=$ac_c_werror_flag
4023 ac_c_werror_flag=yes
4024 cat >conftest.$ac_ext <<_ACEOF
4025 /* confdefs.h.  */
4026 _ACEOF
4027 cat confdefs.h >>conftest.$ac_ext
4028 cat >>conftest.$ac_ext <<_ACEOF
4029 /* end confdefs.h.  */
4030
4031 int
4032 main ()
4033 {
4034
4035   ;
4036   return 0;
4037 }
4038 _ACEOF
4039 rm -f conftest.$ac_objext
4040 if { (ac_try="$ac_compile"
4041 case "(($ac_try" in
4042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4043   *) ac_try_echo=$ac_try;;
4044 esac
4045 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4046 $as_echo "$ac_try_echo") >&5
4047   (eval "$ac_compile") 2>conftest.er1
4048   ac_status=$?
4049   grep -v '^ *+' conftest.er1 >conftest.err
4050   rm -f conftest.er1
4051   cat conftest.err >&5
4052   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4053   (exit $ac_status); } && {
4054          test -z "$ac_c_werror_flag" ||
4055          test ! -s conftest.err
4056        } && test -s conftest.$ac_objext; then
4057   pgac_cv_prog_cc_cflags__Wendif_labels=yes
4058 else
4059   $as_echo "$as_me: failed program was:" >&5
4060 sed 's/^/| /' conftest.$ac_ext >&5
4061
4062         pgac_cv_prog_cc_cflags__Wendif_labels=no
4063 fi
4064
4065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4066 ac_c_werror_flag=$ac_save_c_werror_flag
4067 CFLAGS="$pgac_save_CFLAGS"
4068 fi
4069 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wendif_labels" >&5
4070 $as_echo "$pgac_cv_prog_cc_cflags__Wendif_labels" >&6; }
4071 if test x"$pgac_cv_prog_cc_cflags__Wendif_labels" = x"yes"; then
4072   CFLAGS="$CFLAGS -Wendif-labels"
4073 fi
4074
4075   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wmissing-format-attribute" >&5
4076 $as_echo_n "checking whether $CC supports -Wmissing-format-attribute... " >&6; }
4077 if test "${pgac_cv_prog_cc_cflags__Wmissing_format_attribute+set}" = set; then
4078   $as_echo_n "(cached) " >&6
4079 else
4080   pgac_save_CFLAGS=$CFLAGS
4081 CFLAGS="$pgac_save_CFLAGS -Wmissing-format-attribute"
4082 ac_save_c_werror_flag=$ac_c_werror_flag
4083 ac_c_werror_flag=yes
4084 cat >conftest.$ac_ext <<_ACEOF
4085 /* confdefs.h.  */
4086 _ACEOF
4087 cat confdefs.h >>conftest.$ac_ext
4088 cat >>conftest.$ac_ext <<_ACEOF
4089 /* end confdefs.h.  */
4090
4091 int
4092 main ()
4093 {
4094
4095   ;
4096   return 0;
4097 }
4098 _ACEOF
4099 rm -f conftest.$ac_objext
4100 if { (ac_try="$ac_compile"
4101 case "(($ac_try" in
4102   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4103   *) ac_try_echo=$ac_try;;
4104 esac
4105 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4106 $as_echo "$ac_try_echo") >&5
4107   (eval "$ac_compile") 2>conftest.er1
4108   ac_status=$?
4109   grep -v '^ *+' conftest.er1 >conftest.err
4110   rm -f conftest.er1
4111   cat conftest.err >&5
4112   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4113   (exit $ac_status); } && {
4114          test -z "$ac_c_werror_flag" ||
4115          test ! -s conftest.err
4116        } && test -s conftest.$ac_objext; then
4117   pgac_cv_prog_cc_cflags__Wmissing_format_attribute=yes
4118 else
4119   $as_echo "$as_me: failed program was:" >&5
4120 sed 's/^/| /' conftest.$ac_ext >&5
4121
4122         pgac_cv_prog_cc_cflags__Wmissing_format_attribute=no
4123 fi
4124
4125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4126 ac_c_werror_flag=$ac_save_c_werror_flag
4127 CFLAGS="$pgac_save_CFLAGS"
4128 fi
4129 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wmissing_format_attribute" >&5
4130 $as_echo "$pgac_cv_prog_cc_cflags__Wmissing_format_attribute" >&6; }
4131 if test x"$pgac_cv_prog_cc_cflags__Wmissing_format_attribute" = x"yes"; then
4132   CFLAGS="$CFLAGS -Wmissing-format-attribute"
4133 fi
4134
4135   # This was included in -Wall/-Wformat in older GCC versions
4136   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wformat-security" >&5
4137 $as_echo_n "checking whether $CC supports -Wformat-security... " >&6; }
4138 if test "${pgac_cv_prog_cc_cflags__Wformat_security+set}" = set; then
4139   $as_echo_n "(cached) " >&6
4140 else
4141   pgac_save_CFLAGS=$CFLAGS
4142 CFLAGS="$pgac_save_CFLAGS -Wformat-security"
4143 ac_save_c_werror_flag=$ac_c_werror_flag
4144 ac_c_werror_flag=yes
4145 cat >conftest.$ac_ext <<_ACEOF
4146 /* confdefs.h.  */
4147 _ACEOF
4148 cat confdefs.h >>conftest.$ac_ext
4149 cat >>conftest.$ac_ext <<_ACEOF
4150 /* end confdefs.h.  */
4151
4152 int
4153 main ()
4154 {
4155
4156   ;
4157   return 0;
4158 }
4159 _ACEOF
4160 rm -f conftest.$ac_objext
4161 if { (ac_try="$ac_compile"
4162 case "(($ac_try" in
4163   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4164   *) ac_try_echo=$ac_try;;
4165 esac
4166 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4167 $as_echo "$ac_try_echo") >&5
4168   (eval "$ac_compile") 2>conftest.er1
4169   ac_status=$?
4170   grep -v '^ *+' conftest.er1 >conftest.err
4171   rm -f conftest.er1
4172   cat conftest.err >&5
4173   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4174   (exit $ac_status); } && {
4175          test -z "$ac_c_werror_flag" ||
4176          test ! -s conftest.err
4177        } && test -s conftest.$ac_objext; then
4178   pgac_cv_prog_cc_cflags__Wformat_security=yes
4179 else
4180   $as_echo "$as_me: failed program was:" >&5
4181 sed 's/^/| /' conftest.$ac_ext >&5
4182
4183         pgac_cv_prog_cc_cflags__Wformat_security=no
4184 fi
4185
4186 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4187 ac_c_werror_flag=$ac_save_c_werror_flag
4188 CFLAGS="$pgac_save_CFLAGS"
4189 fi
4190 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wformat_security" >&5
4191 $as_echo "$pgac_cv_prog_cc_cflags__Wformat_security" >&6; }
4192 if test x"$pgac_cv_prog_cc_cflags__Wformat_security" = x"yes"; then
4193   CFLAGS="$CFLAGS -Wformat-security"
4194 fi
4195
4196   # Disable strict-aliasing rules; needed for gcc 3.3+
4197   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4198 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4199 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4200   $as_echo_n "(cached) " >&6
4201 else
4202   pgac_save_CFLAGS=$CFLAGS
4203 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4204 ac_save_c_werror_flag=$ac_c_werror_flag
4205 ac_c_werror_flag=yes
4206 cat >conftest.$ac_ext <<_ACEOF
4207 /* confdefs.h.  */
4208 _ACEOF
4209 cat confdefs.h >>conftest.$ac_ext
4210 cat >>conftest.$ac_ext <<_ACEOF
4211 /* end confdefs.h.  */
4212
4213 int
4214 main ()
4215 {
4216
4217   ;
4218   return 0;
4219 }
4220 _ACEOF
4221 rm -f conftest.$ac_objext
4222 if { (ac_try="$ac_compile"
4223 case "(($ac_try" in
4224   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4225   *) ac_try_echo=$ac_try;;
4226 esac
4227 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4228 $as_echo "$ac_try_echo") >&5
4229   (eval "$ac_compile") 2>conftest.er1
4230   ac_status=$?
4231   grep -v '^ *+' conftest.er1 >conftest.err
4232   rm -f conftest.er1
4233   cat conftest.err >&5
4234   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4235   (exit $ac_status); } && {
4236          test -z "$ac_c_werror_flag" ||
4237          test ! -s conftest.err
4238        } && test -s conftest.$ac_objext; then
4239   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4240 else
4241   $as_echo "$as_me: failed program was:" >&5
4242 sed 's/^/| /' conftest.$ac_ext >&5
4243
4244         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4245 fi
4246
4247 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4248 ac_c_werror_flag=$ac_save_c_werror_flag
4249 CFLAGS="$pgac_save_CFLAGS"
4250 fi
4251 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4252 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4253 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4254   CFLAGS="$CFLAGS -fno-strict-aliasing"
4255 fi
4256
4257   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4258   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fwrapv" >&5
4259 $as_echo_n "checking whether $CC supports -fwrapv... " >&6; }
4260 if test "${pgac_cv_prog_cc_cflags__fwrapv+set}" = set; then
4261   $as_echo_n "(cached) " >&6
4262 else
4263   pgac_save_CFLAGS=$CFLAGS
4264 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4265 ac_save_c_werror_flag=$ac_c_werror_flag
4266 ac_c_werror_flag=yes
4267 cat >conftest.$ac_ext <<_ACEOF
4268 /* confdefs.h.  */
4269 _ACEOF
4270 cat confdefs.h >>conftest.$ac_ext
4271 cat >>conftest.$ac_ext <<_ACEOF
4272 /* end confdefs.h.  */
4273
4274 int
4275 main ()
4276 {
4277
4278   ;
4279   return 0;
4280 }
4281 _ACEOF
4282 rm -f conftest.$ac_objext
4283 if { (ac_try="$ac_compile"
4284 case "(($ac_try" in
4285   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4286   *) ac_try_echo=$ac_try;;
4287 esac
4288 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4289 $as_echo "$ac_try_echo") >&5
4290   (eval "$ac_compile") 2>conftest.er1
4291   ac_status=$?
4292   grep -v '^ *+' conftest.er1 >conftest.err
4293   rm -f conftest.er1
4294   cat conftest.err >&5
4295   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4296   (exit $ac_status); } && {
4297          test -z "$ac_c_werror_flag" ||
4298          test ! -s conftest.err
4299        } && test -s conftest.$ac_objext; then
4300   pgac_cv_prog_cc_cflags__fwrapv=yes
4301 else
4302   $as_echo "$as_me: failed program was:" >&5
4303 sed 's/^/| /' conftest.$ac_ext >&5
4304
4305         pgac_cv_prog_cc_cflags__fwrapv=no
4306 fi
4307
4308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4309 ac_c_werror_flag=$ac_save_c_werror_flag
4310 CFLAGS="$pgac_save_CFLAGS"
4311 fi
4312 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fwrapv" >&5
4313 $as_echo "$pgac_cv_prog_cc_cflags__fwrapv" >&6; }
4314 if test x"$pgac_cv_prog_cc_cflags__fwrapv" = x"yes"; then
4315   CFLAGS="$CFLAGS -fwrapv"
4316 fi
4317
4318   # Disable FP optimizations that cause various errors on gcc 4.5+ or maybe 4.6+
4319   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fexcess-precision=standard" >&5
4320 $as_echo_n "checking whether $CC supports -fexcess-precision=standard... " >&6; }
4321 if test "${pgac_cv_prog_cc_cflags__fexcess_precision_standard+set}" = set; then
4322   $as_echo_n "(cached) " >&6
4323 else
4324   pgac_save_CFLAGS=$CFLAGS
4325 CFLAGS="$pgac_save_CFLAGS -fexcess-precision=standard"
4326 ac_save_c_werror_flag=$ac_c_werror_flag
4327 ac_c_werror_flag=yes
4328 cat >conftest.$ac_ext <<_ACEOF
4329 /* confdefs.h.  */
4330 _ACEOF
4331 cat confdefs.h >>conftest.$ac_ext
4332 cat >>conftest.$ac_ext <<_ACEOF
4333 /* end confdefs.h.  */
4334
4335 int
4336 main ()
4337 {
4338
4339   ;
4340   return 0;
4341 }
4342 _ACEOF
4343 rm -f conftest.$ac_objext
4344 if { (ac_try="$ac_compile"
4345 case "(($ac_try" in
4346   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4347   *) ac_try_echo=$ac_try;;
4348 esac
4349 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4350 $as_echo "$ac_try_echo") >&5
4351   (eval "$ac_compile") 2>conftest.er1
4352   ac_status=$?
4353   grep -v '^ *+' conftest.er1 >conftest.err
4354   rm -f conftest.er1
4355   cat conftest.err >&5
4356   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4357   (exit $ac_status); } && {
4358          test -z "$ac_c_werror_flag" ||
4359          test ! -s conftest.err
4360        } && test -s conftest.$ac_objext; then
4361   pgac_cv_prog_cc_cflags__fexcess_precision_standard=yes
4362 else
4363   $as_echo "$as_me: failed program was:" >&5
4364 sed 's/^/| /' conftest.$ac_ext >&5
4365
4366         pgac_cv_prog_cc_cflags__fexcess_precision_standard=no
4367 fi
4368
4369 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4370 ac_c_werror_flag=$ac_save_c_werror_flag
4371 CFLAGS="$pgac_save_CFLAGS"
4372 fi
4373 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fexcess_precision_standard" >&5
4374 $as_echo "$pgac_cv_prog_cc_cflags__fexcess_precision_standard" >&6; }
4375 if test x"$pgac_cv_prog_cc_cflags__fexcess_precision_standard" = x"yes"; then
4376   CFLAGS="$CFLAGS -fexcess-precision=standard"
4377 fi
4378
4379 elif test "$ICC" = yes; then
4380   # Intel's compiler has a bug/misoptimization in checking for
4381   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4382   { $as_echo "$as_me:$LINENO: checking whether $CC supports -mp1" >&5
4383 $as_echo_n "checking whether $CC supports -mp1... " >&6; }
4384 if test "${pgac_cv_prog_cc_cflags__mp1+set}" = set; then
4385   $as_echo_n "(cached) " >&6
4386 else
4387   pgac_save_CFLAGS=$CFLAGS
4388 CFLAGS="$pgac_save_CFLAGS -mp1"
4389 ac_save_c_werror_flag=$ac_c_werror_flag
4390 ac_c_werror_flag=yes
4391 cat >conftest.$ac_ext <<_ACEOF
4392 /* confdefs.h.  */
4393 _ACEOF
4394 cat confdefs.h >>conftest.$ac_ext
4395 cat >>conftest.$ac_ext <<_ACEOF
4396 /* end confdefs.h.  */
4397
4398 int
4399 main ()
4400 {
4401
4402   ;
4403   return 0;
4404 }
4405 _ACEOF
4406 rm -f conftest.$ac_objext
4407 if { (ac_try="$ac_compile"
4408 case "(($ac_try" in
4409   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4410   *) ac_try_echo=$ac_try;;
4411 esac
4412 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4413 $as_echo "$ac_try_echo") >&5
4414   (eval "$ac_compile") 2>conftest.er1
4415   ac_status=$?
4416   grep -v '^ *+' conftest.er1 >conftest.err
4417   rm -f conftest.er1
4418   cat conftest.err >&5
4419   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4420   (exit $ac_status); } && {
4421          test -z "$ac_c_werror_flag" ||
4422          test ! -s conftest.err
4423        } && test -s conftest.$ac_objext; then
4424   pgac_cv_prog_cc_cflags__mp1=yes
4425 else
4426   $as_echo "$as_me: failed program was:" >&5
4427 sed 's/^/| /' conftest.$ac_ext >&5
4428
4429         pgac_cv_prog_cc_cflags__mp1=no
4430 fi
4431
4432 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4433 ac_c_werror_flag=$ac_save_c_werror_flag
4434 CFLAGS="$pgac_save_CFLAGS"
4435 fi
4436 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__mp1" >&5
4437 $as_echo "$pgac_cv_prog_cc_cflags__mp1" >&6; }
4438 if test x"$pgac_cv_prog_cc_cflags__mp1" = x"yes"; then
4439   CFLAGS="$CFLAGS -mp1"
4440 fi
4441
4442   # Make sure strict aliasing is off (though this is said to be the default)
4443   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4444 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4445 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4446   $as_echo_n "(cached) " >&6
4447 else
4448   pgac_save_CFLAGS=$CFLAGS
4449 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4450 ac_save_c_werror_flag=$ac_c_werror_flag
4451 ac_c_werror_flag=yes
4452 cat >conftest.$ac_ext <<_ACEOF
4453 /* confdefs.h.  */
4454 _ACEOF
4455 cat confdefs.h >>conftest.$ac_ext
4456 cat >>conftest.$ac_ext <<_ACEOF
4457 /* end confdefs.h.  */
4458
4459 int
4460 main ()
4461 {
4462
4463   ;
4464   return 0;
4465 }
4466 _ACEOF
4467 rm -f conftest.$ac_objext
4468 if { (ac_try="$ac_compile"
4469 case "(($ac_try" in
4470   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4471   *) ac_try_echo=$ac_try;;
4472 esac
4473 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4474 $as_echo "$ac_try_echo") >&5
4475   (eval "$ac_compile") 2>conftest.er1
4476   ac_status=$?
4477   grep -v '^ *+' conftest.er1 >conftest.err
4478   rm -f conftest.er1
4479   cat conftest.err >&5
4480   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4481   (exit $ac_status); } && {
4482          test -z "$ac_c_werror_flag" ||
4483          test ! -s conftest.err
4484        } && test -s conftest.$ac_objext; then
4485   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4486 else
4487   $as_echo "$as_me: failed program was:" >&5
4488 sed 's/^/| /' conftest.$ac_ext >&5
4489
4490         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4491 fi
4492
4493 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4494 ac_c_werror_flag=$ac_save_c_werror_flag
4495 CFLAGS="$pgac_save_CFLAGS"
4496 fi
4497 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4498 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4499 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4500   CFLAGS="$CFLAGS -fno-strict-aliasing"
4501 fi
4502
4503 elif test "$PORTNAME" = "aix"; then
4504   # AIX's xlc has to have strict aliasing turned off too
4505   { $as_echo "$as_me:$LINENO: checking whether $CC supports -qnoansialias" >&5
4506 $as_echo_n "checking whether $CC supports -qnoansialias... " >&6; }
4507 if test "${pgac_cv_prog_cc_cflags__qnoansialias+set}" = set; then
4508   $as_echo_n "(cached) " >&6
4509 else
4510   pgac_save_CFLAGS=$CFLAGS
4511 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4512 ac_save_c_werror_flag=$ac_c_werror_flag
4513 ac_c_werror_flag=yes
4514 cat >conftest.$ac_ext <<_ACEOF
4515 /* confdefs.h.  */
4516 _ACEOF
4517 cat confdefs.h >>conftest.$ac_ext
4518 cat >>conftest.$ac_ext <<_ACEOF
4519 /* end confdefs.h.  */
4520
4521 int
4522 main ()
4523 {
4524
4525   ;
4526   return 0;
4527 }
4528 _ACEOF
4529 rm -f conftest.$ac_objext
4530 if { (ac_try="$ac_compile"
4531 case "(($ac_try" in
4532   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4533   *) ac_try_echo=$ac_try;;
4534 esac
4535 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4536 $as_echo "$ac_try_echo") >&5
4537   (eval "$ac_compile") 2>conftest.er1
4538   ac_status=$?
4539   grep -v '^ *+' conftest.er1 >conftest.err
4540   rm -f conftest.er1
4541   cat conftest.err >&5
4542   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4543   (exit $ac_status); } && {
4544          test -z "$ac_c_werror_flag" ||
4545          test ! -s conftest.err
4546        } && test -s conftest.$ac_objext; then
4547   pgac_cv_prog_cc_cflags__qnoansialias=yes
4548 else
4549   $as_echo "$as_me: failed program was:" >&5
4550 sed 's/^/| /' conftest.$ac_ext >&5
4551
4552         pgac_cv_prog_cc_cflags__qnoansialias=no
4553 fi
4554
4555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4556 ac_c_werror_flag=$ac_save_c_werror_flag
4557 CFLAGS="$pgac_save_CFLAGS"
4558 fi
4559 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__qnoansialias" >&5
4560 $as_echo "$pgac_cv_prog_cc_cflags__qnoansialias" >&6; }
4561 if test x"$pgac_cv_prog_cc_cflags__qnoansialias" = x"yes"; then
4562   CFLAGS="$CFLAGS -qnoansialias"
4563 fi
4564
4565 elif test "$PORTNAME" = "hpux"; then
4566   # On some versions of HP-UX, libm functions do not set errno by default.
4567   # Fix that by using +Olibmerrno if the compiler recognizes it.
4568   { $as_echo "$as_me:$LINENO: checking whether $CC supports +Olibmerrno" >&5
4569 $as_echo_n "checking whether $CC supports +Olibmerrno... " >&6; }
4570 if test "${pgac_cv_prog_cc_cflags_pOlibmerrno+set}" = set; then
4571   $as_echo_n "(cached) " >&6
4572 else
4573   pgac_save_CFLAGS=$CFLAGS
4574 CFLAGS="$pgac_save_CFLAGS +Olibmerrno"
4575 ac_save_c_werror_flag=$ac_c_werror_flag
4576 ac_c_werror_flag=yes
4577 cat >conftest.$ac_ext <<_ACEOF
4578 /* confdefs.h.  */
4579 _ACEOF
4580 cat confdefs.h >>conftest.$ac_ext
4581 cat >>conftest.$ac_ext <<_ACEOF
4582 /* end confdefs.h.  */
4583
4584 int
4585 main ()
4586 {
4587
4588   ;
4589   return 0;
4590 }
4591 _ACEOF
4592 rm -f conftest.$ac_objext
4593 if { (ac_try="$ac_compile"
4594 case "(($ac_try" in
4595   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4596   *) ac_try_echo=$ac_try;;
4597 esac
4598 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4599 $as_echo "$ac_try_echo") >&5
4600   (eval "$ac_compile") 2>conftest.er1
4601   ac_status=$?
4602   grep -v '^ *+' conftest.er1 >conftest.err
4603   rm -f conftest.er1
4604   cat conftest.err >&5
4605   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4606   (exit $ac_status); } && {
4607          test -z "$ac_c_werror_flag" ||
4608          test ! -s conftest.err
4609        } && test -s conftest.$ac_objext; then
4610   pgac_cv_prog_cc_cflags_pOlibmerrno=yes
4611 else
4612   $as_echo "$as_me: failed program was:" >&5
4613 sed 's/^/| /' conftest.$ac_ext >&5
4614
4615         pgac_cv_prog_cc_cflags_pOlibmerrno=no
4616 fi
4617
4618 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4619 ac_c_werror_flag=$ac_save_c_werror_flag
4620 CFLAGS="$pgac_save_CFLAGS"
4621 fi
4622 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags_pOlibmerrno" >&5
4623 $as_echo "$pgac_cv_prog_cc_cflags_pOlibmerrno" >&6; }
4624 if test x"$pgac_cv_prog_cc_cflags_pOlibmerrno" = x"yes"; then
4625   CFLAGS="$CFLAGS +Olibmerrno"
4626 fi
4627
4628 fi
4629
4630 # supply -g if --enable-debug
4631 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4632   CFLAGS="$CFLAGS -g"
4633 fi
4634
4635 # enable code coverage if --enable-coverage
4636 if test "$enable_coverage" = yes; then
4637   if test "$GCC" = yes; then
4638     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4639   else
4640     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4641 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4642    { (exit 1); exit 1; }; }
4643   fi
4644 fi
4645
4646 # enable profiling if --enable-profiling
4647 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4648   if test "$GCC" = yes; then
4649
4650 cat >>confdefs.h <<\_ACEOF
4651 #define PROFILE_PID_DIR 1
4652 _ACEOF
4653
4654     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4655   else
4656     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4657 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4658    { (exit 1); exit 1; }; }
4659   fi
4660 fi
4661
4662 # We already have this in Makefile.win32, but configure needs it too
4663 if test "$PORTNAME" = "win32"; then
4664   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4665 fi
4666
4667 # Check if the compiler still works with the template settings
4668 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4669 $as_echo_n "checking whether the C compiler still works... " >&6; }
4670 cat >conftest.$ac_ext <<_ACEOF
4671 /* confdefs.h.  */
4672 _ACEOF
4673 cat confdefs.h >>conftest.$ac_ext
4674 cat >>conftest.$ac_ext <<_ACEOF
4675 /* end confdefs.h.  */
4676
4677 int
4678 main ()
4679 {
4680 return 0;
4681   ;
4682   return 0;
4683 }
4684 _ACEOF
4685 rm -f conftest.$ac_objext conftest$ac_exeext
4686 if { (ac_try="$ac_link"
4687 case "(($ac_try" in
4688   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4689   *) ac_try_echo=$ac_try;;
4690 esac
4691 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4692 $as_echo "$ac_try_echo") >&5
4693   (eval "$ac_link") 2>conftest.er1
4694   ac_status=$?
4695   grep -v '^ *+' conftest.er1 >conftest.err
4696   rm -f conftest.er1
4697   cat conftest.err >&5
4698   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4699   (exit $ac_status); } && {
4700          test -z "$ac_c_werror_flag" ||
4701          test ! -s conftest.err
4702        } && test -s conftest$ac_exeext && {
4703          test "$cross_compiling" = yes ||
4704          $as_test_x conftest$ac_exeext
4705        }; then
4706   { $as_echo "$as_me:$LINENO: result: yes" >&5
4707 $as_echo "yes" >&6; }
4708 else
4709   $as_echo "$as_me: failed program was:" >&5
4710 sed 's/^/| /' conftest.$ac_ext >&5
4711
4712         { $as_echo "$as_me:$LINENO: result: no" >&5
4713 $as_echo "no" >&6; }
4714    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4715 $as_echo "$as_me: error: cannot proceed" >&2;}
4716    { (exit 1); exit 1; }; }
4717 fi
4718
4719 rm -rf conftest.dSYM
4720 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4721       conftest$ac_exeext conftest.$ac_ext
4722
4723 # Defend against gcc -ffast-math
4724 if test "$GCC" = yes; then
4725 cat >conftest.$ac_ext <<_ACEOF
4726 /* confdefs.h.  */
4727 _ACEOF
4728 cat confdefs.h >>conftest.$ac_ext
4729 cat >>conftest.$ac_ext <<_ACEOF
4730 /* end confdefs.h.  */
4731
4732 int
4733 main ()
4734 {
4735 #ifdef __FAST_MATH__
4736 choke me
4737 #endif
4738   ;
4739   return 0;
4740 }
4741 _ACEOF
4742 rm -f conftest.$ac_objext
4743 if { (ac_try="$ac_compile"
4744 case "(($ac_try" in
4745   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4746   *) ac_try_echo=$ac_try;;
4747 esac
4748 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4749 $as_echo "$ac_try_echo") >&5
4750   (eval "$ac_compile") 2>conftest.er1
4751   ac_status=$?
4752   grep -v '^ *+' conftest.er1 >conftest.err
4753   rm -f conftest.er1
4754   cat conftest.err >&5
4755   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4756   (exit $ac_status); } && {
4757          test -z "$ac_c_werror_flag" ||
4758          test ! -s conftest.err
4759        } && test -s conftest.$ac_objext; then
4760   :
4761 else
4762   $as_echo "$as_me: failed program was:" >&5
4763 sed 's/^/| /' conftest.$ac_ext >&5
4764
4765         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4766 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4767    { (exit 1); exit 1; }; }
4768 fi
4769
4770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4771 fi
4772
4773 ac_ext=c
4774 ac_cpp='$CPP $CPPFLAGS'
4775 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4776 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4777 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4778 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4779 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4780 # On Suns, sometimes $CPP names a directory.
4781 if test -n "$CPP" && test -d "$CPP"; then
4782   CPP=
4783 fi
4784 if test -z "$CPP"; then
4785   if test "${ac_cv_prog_CPP+set}" = set; then
4786   $as_echo_n "(cached) " >&6
4787 else
4788       # Double quotes because CPP needs to be expanded
4789     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4790     do
4791       ac_preproc_ok=false
4792 for ac_c_preproc_warn_flag in '' yes
4793 do
4794   # Use a header file that comes with gcc, so configuring glibc
4795   # with a fresh cross-compiler works.
4796   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4797   # <limits.h> exists even on freestanding compilers.
4798   # On the NeXT, cc -E runs the code through the compiler's parser,
4799   # not just through cpp. "Syntax error" is here to catch this case.
4800   cat >conftest.$ac_ext <<_ACEOF
4801 /* confdefs.h.  */
4802 _ACEOF
4803 cat confdefs.h >>conftest.$ac_ext
4804 cat >>conftest.$ac_ext <<_ACEOF
4805 /* end confdefs.h.  */
4806 #ifdef __STDC__
4807 # include <limits.h>
4808 #else
4809 # include <assert.h>
4810 #endif
4811                      Syntax error
4812 _ACEOF
4813 if { (ac_try="$ac_cpp conftest.$ac_ext"
4814 case "(($ac_try" in
4815   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4816   *) ac_try_echo=$ac_try;;
4817 esac
4818 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4819 $as_echo "$ac_try_echo") >&5
4820   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4821   ac_status=$?
4822   grep -v '^ *+' conftest.er1 >conftest.err
4823   rm -f conftest.er1
4824   cat conftest.err >&5
4825   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4826   (exit $ac_status); } >/dev/null && {
4827          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4828          test ! -s conftest.err
4829        }; then
4830   :
4831 else
4832   $as_echo "$as_me: failed program was:" >&5
4833 sed 's/^/| /' conftest.$ac_ext >&5
4834
4835   # Broken: fails on valid input.
4836 continue
4837 fi
4838
4839 rm -f conftest.err conftest.$ac_ext
4840
4841   # OK, works on sane cases.  Now check whether nonexistent headers
4842   # can be detected and how.
4843   cat >conftest.$ac_ext <<_ACEOF
4844 /* confdefs.h.  */
4845 _ACEOF
4846 cat confdefs.h >>conftest.$ac_ext
4847 cat >>conftest.$ac_ext <<_ACEOF
4848 /* end confdefs.h.  */
4849 #include <ac_nonexistent.h>
4850 _ACEOF
4851 if { (ac_try="$ac_cpp conftest.$ac_ext"
4852 case "(($ac_try" in
4853   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4854   *) ac_try_echo=$ac_try;;
4855 esac
4856 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4857 $as_echo "$ac_try_echo") >&5
4858   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4859   ac_status=$?
4860   grep -v '^ *+' conftest.er1 >conftest.err
4861   rm -f conftest.er1
4862   cat conftest.err >&5
4863   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4864   (exit $ac_status); } >/dev/null && {
4865          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4866          test ! -s conftest.err
4867        }; then
4868   # Broken: success on invalid input.
4869 continue
4870 else
4871   $as_echo "$as_me: failed program was:" >&5
4872 sed 's/^/| /' conftest.$ac_ext >&5
4873
4874   # Passes both tests.
4875 ac_preproc_ok=:
4876 break
4877 fi
4878
4879 rm -f conftest.err conftest.$ac_ext
4880
4881 done
4882 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4883 rm -f conftest.err conftest.$ac_ext
4884 if $ac_preproc_ok; then
4885   break
4886 fi
4887
4888     done
4889     ac_cv_prog_CPP=$CPP
4890
4891 fi
4892   CPP=$ac_cv_prog_CPP
4893 else
4894   ac_cv_prog_CPP=$CPP
4895 fi
4896 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
4897 $as_echo "$CPP" >&6; }
4898 ac_preproc_ok=false
4899 for ac_c_preproc_warn_flag in '' yes
4900 do
4901   # Use a header file that comes with gcc, so configuring glibc
4902   # with a fresh cross-compiler works.
4903   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4904   # <limits.h> exists even on freestanding compilers.
4905   # On the NeXT, cc -E runs the code through the compiler's parser,
4906   # not just through cpp. "Syntax error" is here to catch this case.
4907   cat >conftest.$ac_ext <<_ACEOF
4908 /* confdefs.h.  */
4909 _ACEOF
4910 cat confdefs.h >>conftest.$ac_ext
4911 cat >>conftest.$ac_ext <<_ACEOF
4912 /* end confdefs.h.  */
4913 #ifdef __STDC__
4914 # include <limits.h>
4915 #else
4916 # include <assert.h>
4917 #endif
4918                      Syntax error
4919 _ACEOF
4920 if { (ac_try="$ac_cpp conftest.$ac_ext"
4921 case "(($ac_try" in
4922   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4923   *) ac_try_echo=$ac_try;;
4924 esac
4925 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4926 $as_echo "$ac_try_echo") >&5
4927   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4928   ac_status=$?
4929   grep -v '^ *+' conftest.er1 >conftest.err
4930   rm -f conftest.er1
4931   cat conftest.err >&5
4932   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4933   (exit $ac_status); } >/dev/null && {
4934          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4935          test ! -s conftest.err
4936        }; then
4937   :
4938 else
4939   $as_echo "$as_me: failed program was:" >&5
4940 sed 's/^/| /' conftest.$ac_ext >&5
4941
4942   # Broken: fails on valid input.
4943 continue
4944 fi
4945
4946 rm -f conftest.err conftest.$ac_ext
4947
4948   # OK, works on sane cases.  Now check whether nonexistent headers
4949   # can be detected and how.
4950   cat >conftest.$ac_ext <<_ACEOF
4951 /* confdefs.h.  */
4952 _ACEOF
4953 cat confdefs.h >>conftest.$ac_ext
4954 cat >>conftest.$ac_ext <<_ACEOF
4955 /* end confdefs.h.  */
4956 #include <ac_nonexistent.h>
4957 _ACEOF
4958 if { (ac_try="$ac_cpp conftest.$ac_ext"
4959 case "(($ac_try" in
4960   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4961   *) ac_try_echo=$ac_try;;
4962 esac
4963 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4964 $as_echo "$ac_try_echo") >&5
4965   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4966   ac_status=$?
4967   grep -v '^ *+' conftest.er1 >conftest.err
4968   rm -f conftest.er1
4969   cat conftest.err >&5
4970   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4971   (exit $ac_status); } >/dev/null && {
4972          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4973          test ! -s conftest.err
4974        }; then
4975   # Broken: success on invalid input.
4976 continue
4977 else
4978   $as_echo "$as_me: failed program was:" >&5
4979 sed 's/^/| /' conftest.$ac_ext >&5
4980
4981   # Passes both tests.
4982 ac_preproc_ok=:
4983 break
4984 fi
4985
4986 rm -f conftest.err conftest.$ac_ext
4987
4988 done
4989 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4990 rm -f conftest.err conftest.$ac_ext
4991 if $ac_preproc_ok; then
4992   :
4993 else
4994   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4995 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4996 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4997 See \`config.log' for more details." >&5
4998 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4999 See \`config.log' for more details." >&2;}
5000    { (exit 1); exit 1; }; }; }
5001 fi
5002
5003 ac_ext=c
5004 ac_cpp='$CPP $CPPFLAGS'
5005 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5006 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5007 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5008
5009
5010
5011
5012 #
5013 # Set up TAS assembly code if needed; the template file has now had its
5014 # chance to request this.
5015 #
5016 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
5017
5018
5019 if test "$need_tas" = yes ; then
5020   TAS=tas.o
5021 else
5022   TAS=""
5023 fi
5024
5025
5026
5027 #
5028 # Automatic dependency tracking
5029 #
5030
5031
5032 # Check whether --enable-depend was given.
5033 if test "${enable_depend+set}" = set; then
5034   enableval=$enable_depend;
5035   case $enableval in
5036     yes)
5037       autodepend=yes
5038       ;;
5039     no)
5040       :
5041       ;;
5042     *)
5043       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
5044 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
5045    { (exit 1); exit 1; }; }
5046       ;;
5047   esac
5048
5049 else
5050   enable_depend=no
5051
5052 fi
5053
5054
5055
5056
5057
5058 #
5059 # Enable assert checks
5060 #
5061
5062
5063 # Check whether --enable-cassert was given.
5064 if test "${enable_cassert+set}" = set; then
5065   enableval=$enable_cassert;
5066   case $enableval in
5067     yes)
5068
5069 cat >>confdefs.h <<\_ACEOF
5070 #define USE_ASSERT_CHECKING 1
5071 _ACEOF
5072
5073       ;;
5074     no)
5075       :
5076       ;;
5077     *)
5078       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
5079 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
5080    { (exit 1); exit 1; }; }
5081       ;;
5082   esac
5083
5084 else
5085   enable_cassert=no
5086
5087 fi
5088
5089
5090
5091
5092 #
5093 # Include directories
5094 #
5095 ac_save_IFS=$IFS
5096 IFS="${IFS}${PATH_SEPARATOR}"
5097 # SRCH_INC comes from the template file
5098 for dir in $with_includes $SRCH_INC; do
5099   if test -d "$dir"; then
5100     INCLUDES="$INCLUDES -I$dir"
5101   else
5102     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
5103 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
5104   fi
5105 done
5106 IFS=$ac_save_IFS
5107
5108
5109
5110 #
5111 # Library directories
5112 #
5113 ac_save_IFS=$IFS
5114 IFS="${IFS}${PATH_SEPARATOR}"
5115 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
5116 for dir in $LIBRARY_DIRS $SRCH_LIB; do
5117   if test -d "$dir"; then
5118     LIBDIRS="$LIBDIRS -L$dir"
5119   else
5120     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
5121 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
5122   fi
5123 done
5124 IFS=$ac_save_IFS
5125
5126 #
5127 # Enable thread-safe client libraries
5128 #
5129 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
5130 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
5131
5132
5133 # Check whether --enable-thread-safety was given.
5134 if test "${enable_thread_safety+set}" = set; then
5135   enableval=$enable_thread_safety;
5136   case $enableval in
5137     yes)
5138       :
5139       ;;
5140     no)
5141       :
5142       ;;
5143     *)
5144       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
5145 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
5146    { (exit 1); exit 1; }; }
5147       ;;
5148   esac
5149
5150 else
5151   enable_thread_safety=yes
5152
5153 fi
5154
5155
5156 if test "$enable_thread_safety" = yes; then
5157
5158 cat >>confdefs.h <<\_ACEOF
5159 #define ENABLE_THREAD_SAFETY 1
5160 _ACEOF
5161
5162 fi
5163 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
5164 $as_echo "$enable_thread_safety" >&6; }
5165
5166
5167 #
5168 # Optionally build Tcl modules (PL/Tcl)
5169 #
5170 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
5171 $as_echo_n "checking whether to build with Tcl... " >&6; }
5172
5173
5174
5175 # Check whether --with-tcl was given.
5176 if test "${with_tcl+set}" = set; then
5177   withval=$with_tcl;
5178   case $withval in
5179     yes)
5180       :
5181       ;;
5182     no)
5183       :
5184       ;;
5185     *)
5186       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
5187 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
5188    { (exit 1); exit 1; }; }
5189       ;;
5190   esac
5191
5192 else
5193   with_tcl=no
5194
5195 fi
5196
5197
5198 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
5199 $as_echo "$with_tcl" >&6; }
5200
5201
5202 # We see if the path to the Tcl/Tk configuration scripts is specified.
5203 # This will override the use of tclsh to find the paths to search.
5204
5205
5206
5207
5208 # Check whether --with-tclconfig was given.
5209 if test "${with_tclconfig+set}" = set; then
5210   withval=$with_tclconfig;
5211   case $withval in
5212     yes)
5213       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5214 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5215    { (exit 1); exit 1; }; }
5216       ;;
5217     no)
5218       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5219 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5220    { (exit 1); exit 1; }; }
5221       ;;
5222     *)
5223
5224       ;;
5225   esac
5226
5227 fi
5228
5229
5230
5231 #
5232 # Optionally build Perl modules (PL/Perl)
5233 #
5234 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
5235 $as_echo_n "checking whether to build Perl modules... " >&6; }
5236
5237
5238
5239 # Check whether --with-perl was given.
5240 if test "${with_perl+set}" = set; then
5241   withval=$with_perl;
5242   case $withval in
5243     yes)
5244       :
5245       ;;
5246     no)
5247       :
5248       ;;
5249     *)
5250       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
5251 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
5252    { (exit 1); exit 1; }; }
5253       ;;
5254   esac
5255
5256 else
5257   with_perl=no
5258
5259 fi
5260
5261
5262 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
5263 $as_echo "$with_perl" >&6; }
5264
5265
5266 #
5267 # Optionally build Python modules (PL/Python)
5268 #
5269 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
5270 $as_echo_n "checking whether to build Python modules... " >&6; }
5271
5272
5273
5274 # Check whether --with-python was given.
5275 if test "${with_python+set}" = set; then
5276   withval=$with_python;
5277   case $withval in
5278     yes)
5279       :
5280       ;;
5281     no)
5282       :
5283       ;;
5284     *)
5285       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5286 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5287    { (exit 1); exit 1; }; }
5288       ;;
5289   esac
5290
5291 else
5292   with_python=no
5293
5294 fi
5295
5296
5297 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5298 $as_echo "$with_python" >&6; }
5299
5300
5301 #
5302 # GSSAPI
5303 #
5304 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5305 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5306
5307
5308
5309 # Check whether --with-gssapi was given.
5310 if test "${with_gssapi+set}" = set; then
5311   withval=$with_gssapi;
5312   case $withval in
5313     yes)
5314
5315
5316 cat >>confdefs.h <<\_ACEOF
5317 #define ENABLE_GSS 1
5318 _ACEOF
5319
5320   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5321
5322       ;;
5323     no)
5324       :
5325       ;;
5326     *)
5327       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5328 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5329    { (exit 1); exit 1; }; }
5330       ;;
5331   esac
5332
5333 else
5334   with_gssapi=no
5335
5336 fi
5337
5338
5339 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5340 $as_echo "$with_gssapi" >&6; }
5341
5342 #
5343 # Kerberos 5
5344 #
5345 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5346 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5347
5348
5349
5350 # Check whether --with-krb5 was given.
5351 if test "${with_krb5+set}" = set; then
5352   withval=$with_krb5;
5353   case $withval in
5354     yes)
5355
5356
5357 cat >>confdefs.h <<\_ACEOF
5358 #define KRB5 1
5359 _ACEOF
5360
5361   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5362
5363       ;;
5364     no)
5365       :
5366       ;;
5367     *)
5368       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5369 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5370    { (exit 1); exit 1; }; }
5371       ;;
5372   esac
5373
5374 else
5375   with_krb5=no
5376
5377 fi
5378
5379
5380 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5381 $as_echo "$with_krb5" >&6; }
5382
5383
5384
5385
5386
5387 #
5388 # Kerberos configuration parameters
5389 #
5390
5391
5392
5393 # Check whether --with-krb-srvnam was given.
5394 if test "${with_krb_srvnam+set}" = set; then
5395   withval=$with_krb_srvnam;
5396   case $withval in
5397     yes)
5398       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5399 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5400    { (exit 1); exit 1; }; }
5401       ;;
5402     no)
5403       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5404 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5405    { (exit 1); exit 1; }; }
5406       ;;
5407     *)
5408
5409       ;;
5410   esac
5411
5412 else
5413   with_krb_srvnam="postgres"
5414 fi
5415
5416
5417
5418 cat >>confdefs.h <<_ACEOF
5419 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5420 _ACEOF
5421
5422
5423
5424 #
5425 # PAM
5426 #
5427 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5428 $as_echo_n "checking whether to build with PAM support... " >&6; }
5429
5430
5431
5432 # Check whether --with-pam was given.
5433 if test "${with_pam+set}" = set; then
5434   withval=$with_pam;
5435   case $withval in
5436     yes)
5437
5438 cat >>confdefs.h <<\_ACEOF
5439 #define USE_PAM 1
5440 _ACEOF
5441
5442       ;;
5443     no)
5444       :
5445       ;;
5446     *)
5447       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5448 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5449    { (exit 1); exit 1; }; }
5450       ;;
5451   esac
5452
5453 else
5454   with_pam=no
5455
5456 fi
5457
5458
5459 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5460 $as_echo "$with_pam" >&6; }
5461
5462
5463 #
5464 # LDAP
5465 #
5466 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5467 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5468
5469
5470
5471 # Check whether --with-ldap was given.
5472 if test "${with_ldap+set}" = set; then
5473   withval=$with_ldap;
5474   case $withval in
5475     yes)
5476
5477 cat >>confdefs.h <<\_ACEOF
5478 #define USE_LDAP 1
5479 _ACEOF
5480
5481       ;;
5482     no)
5483       :
5484       ;;
5485     *)
5486       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5487 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5488    { (exit 1); exit 1; }; }
5489       ;;
5490   esac
5491
5492 else
5493   with_ldap=no
5494
5495 fi
5496
5497
5498 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5499 $as_echo "$with_ldap" >&6; }
5500
5501
5502 #
5503 # Bonjour
5504 #
5505 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5506 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5507
5508
5509
5510 # Check whether --with-bonjour was given.
5511 if test "${with_bonjour+set}" = set; then
5512   withval=$with_bonjour;
5513   case $withval in
5514     yes)
5515
5516 cat >>confdefs.h <<\_ACEOF
5517 #define USE_BONJOUR 1
5518 _ACEOF
5519
5520       ;;
5521     no)
5522       :
5523       ;;
5524     *)
5525       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5526 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5527    { (exit 1); exit 1; }; }
5528       ;;
5529   esac
5530
5531 else
5532   with_bonjour=no
5533
5534 fi
5535
5536
5537 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5538 $as_echo "$with_bonjour" >&6; }
5539
5540
5541 #
5542 # OpenSSL
5543 #
5544 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5545 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5546
5547
5548
5549 # Check whether --with-openssl was given.
5550 if test "${with_openssl+set}" = set; then
5551   withval=$with_openssl;
5552   case $withval in
5553     yes)
5554
5555 cat >>confdefs.h <<\_ACEOF
5556 #define USE_SSL 1
5557 _ACEOF
5558
5559       ;;
5560     no)
5561       :
5562       ;;
5563     *)
5564       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5565 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5566    { (exit 1); exit 1; }; }
5567       ;;
5568   esac
5569
5570 else
5571   with_openssl=no
5572
5573 fi
5574
5575
5576 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5577 $as_echo "$with_openssl" >&6; }
5578
5579
5580 #
5581 # SELinux
5582 #
5583 { $as_echo "$as_me:$LINENO: checking whether to build with SELinux support" >&5
5584 $as_echo_n "checking whether to build with SELinux support... " >&6; }
5585
5586
5587
5588 # Check whether --with-selinux was given.
5589 if test "${with_selinux+set}" = set; then
5590   withval=$with_selinux;
5591   case $withval in
5592     yes)
5593       :
5594       ;;
5595     no)
5596       :
5597       ;;
5598     *)
5599       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-selinux option" >&5
5600 $as_echo "$as_me: error: no argument expected for --with-selinux option" >&2;}
5601    { (exit 1); exit 1; }; }
5602       ;;
5603   esac
5604
5605 else
5606   with_selinux=no
5607
5608 fi
5609
5610
5611
5612 { $as_echo "$as_me:$LINENO: result: $with_selinux" >&5
5613 $as_echo "$with_selinux" >&6; }
5614
5615 #
5616 # Readline
5617 #
5618
5619
5620
5621 # Check whether --with-readline was given.
5622 if test "${with_readline+set}" = set; then
5623   withval=$with_readline;
5624   case $withval in
5625     yes)
5626       :
5627       ;;
5628     no)
5629       :
5630       ;;
5631     *)
5632       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5633 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5634    { (exit 1); exit 1; }; }
5635       ;;
5636   esac
5637
5638 else
5639   with_readline=yes
5640
5641 fi
5642
5643
5644 # readline on MinGW has problems with backslashes in psql and other bugs.
5645 # This is particularly a problem with non-US code pages.
5646 # Therefore disable its use until we understand the cause. 2004-07-20
5647 if test "$PORTNAME" = "win32"; then
5648   if test "$with_readline" = yes; then
5649     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5650 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5651     with_readline=no
5652   fi
5653 fi
5654
5655
5656 #
5657 # Prefer libedit
5658 #
5659
5660
5661
5662 # Check whether --with-libedit-preferred was given.
5663 if test "${with_libedit_preferred+set}" = set; then
5664   withval=$with_libedit_preferred;
5665   case $withval in
5666     yes)
5667       :
5668       ;;
5669     no)
5670       :
5671       ;;
5672     *)
5673       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5674 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5675    { (exit 1); exit 1; }; }
5676       ;;
5677   esac
5678
5679 else
5680   with_libedit_preferred=no
5681
5682 fi
5683
5684
5685
5686
5687 #
5688 # OSSP UUID library
5689 #
5690
5691
5692
5693 # Check whether --with-ossp-uuid was given.
5694 if test "${with_ossp_uuid+set}" = set; then
5695   withval=$with_ossp_uuid;
5696   case $withval in
5697     yes)
5698       :
5699       ;;
5700     no)
5701       :
5702       ;;
5703     *)
5704       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5705 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5706    { (exit 1); exit 1; }; }
5707       ;;
5708   esac
5709
5710 else
5711   with_ossp_uuid=no
5712
5713 fi
5714
5715
5716
5717
5718
5719 #
5720 # XML
5721 #
5722
5723
5724
5725 # Check whether --with-libxml was given.
5726 if test "${with_libxml+set}" = set; then
5727   withval=$with_libxml;
5728   case $withval in
5729     yes)
5730
5731 cat >>confdefs.h <<\_ACEOF
5732 #define USE_LIBXML 1
5733 _ACEOF
5734
5735       ;;
5736     no)
5737       :
5738       ;;
5739     *)
5740       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5741 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5742    { (exit 1); exit 1; }; }
5743       ;;
5744   esac
5745
5746 else
5747   with_libxml=no
5748
5749 fi
5750
5751
5752
5753 if test "$with_libxml" = yes ; then
5754   for ac_prog in xml2-config
5755 do
5756   # Extract the first word of "$ac_prog", so it can be a program name with args.
5757 set dummy $ac_prog; ac_word=$2
5758 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5759 $as_echo_n "checking for $ac_word... " >&6; }
5760 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5761   $as_echo_n "(cached) " >&6
5762 else
5763   if test -n "$XML2_CONFIG"; then
5764   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5765 else
5766 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5767 for as_dir in $PATH
5768 do
5769   IFS=$as_save_IFS
5770   test -z "$as_dir" && as_dir=.
5771   for ac_exec_ext in '' $ac_executable_extensions; do
5772   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5773     ac_cv_prog_XML2_CONFIG="$ac_prog"
5774     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5775     break 2
5776   fi
5777 done
5778 done
5779 IFS=$as_save_IFS
5780
5781 fi
5782 fi
5783 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5784 if test -n "$XML2_CONFIG"; then
5785   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5786 $as_echo "$XML2_CONFIG" >&6; }
5787 else
5788   { $as_echo "$as_me:$LINENO: result: no" >&5
5789 $as_echo "no" >&6; }
5790 fi
5791
5792
5793   test -n "$XML2_CONFIG" && break
5794 done
5795
5796   if test -n "$XML2_CONFIG"; then
5797     for pgac_option in `$XML2_CONFIG --cflags`; do
5798       case $pgac_option in
5799         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5800       esac
5801     done
5802     for pgac_option in `$XML2_CONFIG --libs`; do
5803       case $pgac_option in
5804         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5805       esac
5806     done
5807   fi
5808 fi
5809
5810
5811
5812 #
5813 # XSLT
5814 #
5815
5816
5817
5818 # Check whether --with-libxslt was given.
5819 if test "${with_libxslt+set}" = set; then
5820   withval=$with_libxslt;
5821   case $withval in
5822     yes)
5823
5824 cat >>confdefs.h <<\_ACEOF
5825 #define USE_LIBXSLT 1
5826 _ACEOF
5827
5828       ;;
5829     no)
5830       :
5831       ;;
5832     *)
5833       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5834 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5835    { (exit 1); exit 1; }; }
5836       ;;
5837   esac
5838
5839 else
5840   with_libxslt=no
5841
5842 fi
5843
5844
5845
5846
5847
5848
5849 #
5850 # tzdata
5851 #
5852
5853
5854
5855 # Check whether --with-system-tzdata was given.
5856 if test "${with_system_tzdata+set}" = set; then
5857   withval=$with_system_tzdata;
5858   case $withval in
5859     yes)
5860       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5861 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5862    { (exit 1); exit 1; }; }
5863       ;;
5864     no)
5865       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5866 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5867    { (exit 1); exit 1; }; }
5868       ;;
5869     *)
5870
5871       ;;
5872   esac
5873
5874 fi
5875
5876
5877
5878
5879 #
5880 # Zlib
5881 #
5882
5883
5884
5885 # Check whether --with-zlib was given.
5886 if test "${with_zlib+set}" = set; then
5887   withval=$with_zlib;
5888   case $withval in
5889     yes)
5890       :
5891       ;;
5892     no)
5893       :
5894       ;;
5895     *)
5896       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5897 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5898    { (exit 1); exit 1; }; }
5899       ;;
5900   esac
5901
5902 else
5903   with_zlib=yes
5904
5905 fi
5906
5907
5908
5909
5910 #
5911 # Elf
5912 #
5913
5914 # Assume system is ELF if it predefines __ELF__ as 1,
5915 # otherwise believe host_os based default.
5916 case $host_os in
5917     freebsd1*|freebsd2*) elf=no;;
5918     freebsd3*|freebsd4*) elf=yes;;
5919 esac
5920
5921
5922 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5923 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5924 if test "${ac_cv_path_GREP+set}" = set; then
5925   $as_echo_n "(cached) " >&6
5926 else
5927   if test -z "$GREP"; then
5928   ac_path_GREP_found=false
5929   # Loop through the user's path and test for each of PROGNAME-LIST
5930   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5931 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5932 do
5933   IFS=$as_save_IFS
5934   test -z "$as_dir" && as_dir=.
5935   for ac_prog in grep ggrep; do
5936     for ac_exec_ext in '' $ac_executable_extensions; do
5937       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5938       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5939 # Check for GNU ac_path_GREP and select it if it is found.
5940   # Check for GNU $ac_path_GREP
5941 case `"$ac_path_GREP" --version 2>&1` in
5942 *GNU*)
5943   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5944 *)
5945   ac_count=0
5946   $as_echo_n 0123456789 >"conftest.in"
5947   while :
5948   do
5949     cat "conftest.in" "conftest.in" >"conftest.tmp"
5950     mv "conftest.tmp" "conftest.in"
5951     cp "conftest.in" "conftest.nl"
5952     $as_echo 'GREP' >> "conftest.nl"
5953     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5954     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5955     ac_count=`expr $ac_count + 1`
5956     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5957       # Best one so far, save it but keep looking for a better one
5958       ac_cv_path_GREP="$ac_path_GREP"
5959       ac_path_GREP_max=$ac_count
5960     fi
5961     # 10*(2^10) chars as input seems more than enough
5962     test $ac_count -gt 10 && break
5963   done
5964   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5965 esac
5966
5967       $ac_path_GREP_found && break 3
5968     done
5969   done
5970 done
5971 IFS=$as_save_IFS
5972   if test -z "$ac_cv_path_GREP"; then
5973     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5974 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5975    { (exit 1); exit 1; }; }
5976   fi
5977 else
5978   ac_cv_path_GREP=$GREP
5979 fi
5980
5981 fi
5982 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5983 $as_echo "$ac_cv_path_GREP" >&6; }
5984  GREP="$ac_cv_path_GREP"
5985
5986
5987 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
5988 $as_echo_n "checking for egrep... " >&6; }
5989 if test "${ac_cv_path_EGREP+set}" = set; then
5990   $as_echo_n "(cached) " >&6
5991 else
5992   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5993    then ac_cv_path_EGREP="$GREP -E"
5994    else
5995      if test -z "$EGREP"; then
5996   ac_path_EGREP_found=false
5997   # Loop through the user's path and test for each of PROGNAME-LIST
5998   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5999 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6000 do
6001   IFS=$as_save_IFS
6002   test -z "$as_dir" && as_dir=.
6003   for ac_prog in egrep; do
6004     for ac_exec_ext in '' $ac_executable_extensions; do
6005       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6006       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6007 # Check for GNU ac_path_EGREP and select it if it is found.
6008   # Check for GNU $ac_path_EGREP
6009 case `"$ac_path_EGREP" --version 2>&1` in
6010 *GNU*)
6011   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6012 *)
6013   ac_count=0
6014   $as_echo_n 0123456789 >"conftest.in"
6015   while :
6016   do
6017     cat "conftest.in" "conftest.in" >"conftest.tmp"
6018     mv "conftest.tmp" "conftest.in"
6019     cp "conftest.in" "conftest.nl"
6020     $as_echo 'EGREP' >> "conftest.nl"
6021     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6022     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6023     ac_count=`expr $ac_count + 1`
6024     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6025       # Best one so far, save it but keep looking for a better one
6026       ac_cv_path_EGREP="$ac_path_EGREP"
6027       ac_path_EGREP_max=$ac_count
6028     fi
6029     # 10*(2^10) chars as input seems more than enough
6030     test $ac_count -gt 10 && break
6031   done
6032   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6033 esac
6034
6035       $ac_path_EGREP_found && break 3
6036     done
6037   done
6038 done
6039 IFS=$as_save_IFS
6040   if test -z "$ac_cv_path_EGREP"; then
6041     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
6042 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
6043    { (exit 1); exit 1; }; }
6044   fi
6045 else
6046   ac_cv_path_EGREP=$EGREP
6047 fi
6048
6049    fi
6050 fi
6051 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
6052 $as_echo "$ac_cv_path_EGREP" >&6; }
6053  EGREP="$ac_cv_path_EGREP"
6054
6055
6056 cat >conftest.$ac_ext <<_ACEOF
6057 /* confdefs.h.  */
6058 _ACEOF
6059 cat confdefs.h >>conftest.$ac_ext
6060 cat >>conftest.$ac_ext <<_ACEOF
6061 /* end confdefs.h.  */
6062 #if __ELF__
6063   yes
6064 #endif
6065
6066 _ACEOF
6067 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6068   $EGREP "yes" >/dev/null 2>&1; then
6069   ELF_SYS=true
6070 else
6071   if test "X$elf" = "Xyes" ; then
6072   ELF_SYS=true
6073 else
6074   ELF_SYS=
6075 fi
6076 fi
6077 rm -f conftest*
6078
6079
6080
6081 #
6082 # Assignments
6083 #
6084
6085 CPPFLAGS="$CPPFLAGS $INCLUDES"
6086 LDFLAGS="$LDFLAGS $LIBDIRS"
6087
6088
6089
6090
6091
6092 # Check whether --with-gnu-ld was given.
6093 if test "${with_gnu_ld+set}" = set; then
6094   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
6095 else
6096   with_gnu_ld=no
6097 fi
6098
6099 ac_prog=ld
6100 if test "$GCC" = yes; then
6101   # Check if gcc -print-prog-name=ld gives a path.
6102   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
6103 $as_echo_n "checking for ld used by GCC... " >&6; }
6104   case $host in
6105   *-*-mingw*)
6106     # gcc leaves a trailing carriage return which upsets mingw
6107     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
6108   *)
6109     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
6110   esac
6111   case "$ac_prog" in
6112     # Accept absolute paths.
6113     [\\/]* | [A-Za-z]:[\\/]*)
6114       re_direlt='/[^/][^/]*/\.\./'
6115       # Canonicalize the path of ld
6116       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
6117       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
6118         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
6119       done
6120       test -z "$LD" && LD="$ac_prog"
6121       ;;
6122   "")
6123     # If it fails, then pretend we aren't using GCC.
6124     ac_prog=ld
6125     ;;
6126   *)
6127     # If it is relative, then search for the first ld in PATH.
6128     with_gnu_ld=unknown
6129     ;;
6130   esac
6131 elif test "$with_gnu_ld" = yes; then
6132   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
6133 $as_echo_n "checking for GNU ld... " >&6; }
6134 else
6135   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
6136 $as_echo_n "checking for non-GNU ld... " >&6; }
6137 fi
6138 if test "${ac_cv_path_LD+set}" = set; then
6139   $as_echo_n "(cached) " >&6
6140 else
6141   if test -z "$LD"; then
6142   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
6143   for ac_dir in $PATH; do
6144     test -z "$ac_dir" && ac_dir=.
6145     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
6146       ac_cv_path_LD="$ac_dir/$ac_prog"
6147       # Check to see if the program is GNU ld.  I'd rather use --version,
6148       # but apparently some GNU ld's only accept -v.
6149       # Break only if it was the GNU/non-GNU ld that we prefer.
6150       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
6151         test "$with_gnu_ld" != no && break
6152       else
6153         test "$with_gnu_ld" != yes && break
6154       fi
6155     fi
6156   done
6157   IFS="$ac_save_ifs"
6158 else
6159   ac_cv_path_LD="$LD" # Let the user override the test with a path.
6160 fi
6161 fi
6162
6163 LD="$ac_cv_path_LD"
6164 if test -n "$LD"; then
6165   { $as_echo "$as_me:$LINENO: result: $LD" >&5
6166 $as_echo "$LD" >&6; }
6167 else
6168   { $as_echo "$as_me:$LINENO: result: no" >&5
6169 $as_echo "no" >&6; }
6170 fi
6171 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
6172 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
6173    { (exit 1); exit 1; }; }
6174 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
6175 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
6176 if test "${ac_cv_prog_gnu_ld+set}" = set; then
6177   $as_echo_n "(cached) " >&6
6178 else
6179   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
6180 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
6181   ac_cv_prog_gnu_ld=yes
6182 else
6183   ac_cv_prog_gnu_ld=no
6184 fi
6185 fi
6186 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
6187 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
6188 with_gnu_ld=$ac_cv_prog_gnu_ld
6189
6190
6191
6192
6193 case $host_os in sysv5*)
6194   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
6195 $as_echo_n "checking whether ld -R works... " >&6; }
6196 if test "${pgac_cv_prog_ld_R+set}" = set; then
6197   $as_echo_n "(cached) " >&6
6198 else
6199
6200     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
6201     cat >conftest.$ac_ext <<_ACEOF
6202 /* confdefs.h.  */
6203 _ACEOF
6204 cat confdefs.h >>conftest.$ac_ext
6205 cat >>conftest.$ac_ext <<_ACEOF
6206 /* end confdefs.h.  */
6207
6208 int
6209 main ()
6210 {
6211
6212   ;
6213   return 0;
6214 }
6215 _ACEOF
6216 rm -f conftest.$ac_objext conftest$ac_exeext
6217 if { (ac_try="$ac_link"
6218 case "(($ac_try" in
6219   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6220   *) ac_try_echo=$ac_try;;
6221 esac
6222 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6223 $as_echo "$ac_try_echo") >&5
6224   (eval "$ac_link") 2>conftest.er1
6225   ac_status=$?
6226   grep -v '^ *+' conftest.er1 >conftest.err
6227   rm -f conftest.er1
6228   cat conftest.err >&5
6229   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6230   (exit $ac_status); } && {
6231          test -z "$ac_c_werror_flag" ||
6232          test ! -s conftest.err
6233        } && test -s conftest$ac_exeext && {
6234          test "$cross_compiling" = yes ||
6235          $as_test_x conftest$ac_exeext
6236        }; then
6237   pgac_cv_prog_ld_R=yes
6238 else
6239   $as_echo "$as_me: failed program was:" >&5
6240 sed 's/^/| /' conftest.$ac_ext >&5
6241
6242         pgac_cv_prog_ld_R=no
6243 fi
6244
6245 rm -rf conftest.dSYM
6246 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6247       conftest$ac_exeext conftest.$ac_ext
6248     LDFLAGS=$pgac_save_LDFLAGS
6249
6250 fi
6251 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
6252 $as_echo "$pgac_cv_prog_ld_R" >&6; }
6253   ld_R_works=$pgac_cv_prog_ld_R
6254
6255 esac
6256 if test -n "$ac_tool_prefix"; then
6257   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6258 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6259 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6260 $as_echo_n "checking for $ac_word... " >&6; }
6261 if test "${ac_cv_prog_RANLIB+set}" = set; then
6262   $as_echo_n "(cached) " >&6
6263 else
6264   if test -n "$RANLIB"; then
6265   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6266 else
6267 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6268 for as_dir in $PATH
6269 do
6270   IFS=$as_save_IFS
6271   test -z "$as_dir" && as_dir=.
6272   for ac_exec_ext in '' $ac_executable_extensions; do
6273   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6274     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6275     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6276     break 2
6277   fi
6278 done
6279 done
6280 IFS=$as_save_IFS
6281
6282 fi
6283 fi
6284 RANLIB=$ac_cv_prog_RANLIB
6285 if test -n "$RANLIB"; then
6286   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
6287 $as_echo "$RANLIB" >&6; }
6288 else
6289   { $as_echo "$as_me:$LINENO: result: no" >&5
6290 $as_echo "no" >&6; }
6291 fi
6292
6293
6294 fi
6295 if test -z "$ac_cv_prog_RANLIB"; then
6296   ac_ct_RANLIB=$RANLIB
6297   # Extract the first word of "ranlib", so it can be a program name with args.
6298 set dummy ranlib; ac_word=$2
6299 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6300 $as_echo_n "checking for $ac_word... " >&6; }
6301 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6302   $as_echo_n "(cached) " >&6
6303 else
6304   if test -n "$ac_ct_RANLIB"; then
6305   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6306 else
6307 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6308 for as_dir in $PATH
6309 do
6310   IFS=$as_save_IFS
6311   test -z "$as_dir" && as_dir=.
6312   for ac_exec_ext in '' $ac_executable_extensions; do
6313   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6314     ac_cv_prog_ac_ct_RANLIB="ranlib"
6315     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6316     break 2
6317   fi
6318 done
6319 done
6320 IFS=$as_save_IFS
6321
6322 fi
6323 fi
6324 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6325 if test -n "$ac_ct_RANLIB"; then
6326   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6327 $as_echo "$ac_ct_RANLIB" >&6; }
6328 else
6329   { $as_echo "$as_me:$LINENO: result: no" >&5
6330 $as_echo "no" >&6; }
6331 fi
6332
6333   if test "x$ac_ct_RANLIB" = x; then
6334     RANLIB=":"
6335   else
6336     case $cross_compiling:$ac_tool_warned in
6337 yes:)
6338 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6339 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6340 ac_tool_warned=yes ;;
6341 esac
6342     RANLIB=$ac_ct_RANLIB
6343   fi
6344 else
6345   RANLIB="$ac_cv_prog_RANLIB"
6346 fi
6347
6348
6349   if test -n "$ac_tool_prefix"; then
6350   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6351 set dummy ${ac_tool_prefix}strip; ac_word=$2
6352 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6353 $as_echo_n "checking for $ac_word... " >&6; }
6354 if test "${ac_cv_prog_STRIP+set}" = set; then
6355   $as_echo_n "(cached) " >&6
6356 else
6357   if test -n "$STRIP"; then
6358   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6359 else
6360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6361 for as_dir in $PATH
6362 do
6363   IFS=$as_save_IFS
6364   test -z "$as_dir" && as_dir=.
6365   for ac_exec_ext in '' $ac_executable_extensions; do
6366   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6367     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6368     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6369     break 2
6370   fi
6371 done
6372 done
6373 IFS=$as_save_IFS
6374
6375 fi
6376 fi
6377 STRIP=$ac_cv_prog_STRIP
6378 if test -n "$STRIP"; then
6379   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6380 $as_echo "$STRIP" >&6; }
6381 else
6382   { $as_echo "$as_me:$LINENO: result: no" >&5
6383 $as_echo "no" >&6; }
6384 fi
6385
6386
6387 fi
6388 if test -z "$ac_cv_prog_STRIP"; then
6389   ac_ct_STRIP=$STRIP
6390   # Extract the first word of "strip", so it can be a program name with args.
6391 set dummy strip; ac_word=$2
6392 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6393 $as_echo_n "checking for $ac_word... " >&6; }
6394 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6395   $as_echo_n "(cached) " >&6
6396 else
6397   if test -n "$ac_ct_STRIP"; then
6398   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6399 else
6400 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6401 for as_dir in $PATH
6402 do
6403   IFS=$as_save_IFS
6404   test -z "$as_dir" && as_dir=.
6405   for ac_exec_ext in '' $ac_executable_extensions; do
6406   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6407     ac_cv_prog_ac_ct_STRIP="strip"
6408     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6409     break 2
6410   fi
6411 done
6412 done
6413 IFS=$as_save_IFS
6414
6415 fi
6416 fi
6417 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6418 if test -n "$ac_ct_STRIP"; then
6419   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6420 $as_echo "$ac_ct_STRIP" >&6; }
6421 else
6422   { $as_echo "$as_me:$LINENO: result: no" >&5
6423 $as_echo "no" >&6; }
6424 fi
6425
6426   if test "x$ac_ct_STRIP" = x; then
6427     STRIP=":"
6428   else
6429     case $cross_compiling:$ac_tool_warned in
6430 yes:)
6431 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6432 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6433 ac_tool_warned=yes ;;
6434 esac
6435     STRIP=$ac_ct_STRIP
6436   fi
6437 else
6438   STRIP="$ac_cv_prog_STRIP"
6439 fi
6440
6441
6442   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6443 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6444   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6445     STRIP_STATIC_LIB="$STRIP -x"
6446     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6447     { $as_echo "$as_me:$LINENO: result: yes" >&5
6448 $as_echo "yes" >&6; }
6449   else
6450     case $host_os in
6451       darwin*)
6452         STRIP="$STRIP -x"
6453         STRIP_STATIC_LIB=$STRIP
6454         STRIP_SHARED_LIB=$STRIP
6455         { $as_echo "$as_me:$LINENO: result: yes" >&5
6456 $as_echo "yes" >&6; }
6457         ;;
6458       *)
6459         STRIP_STATIC_LIB=:
6460         STRIP_SHARED_LIB=:
6461         { $as_echo "$as_me:$LINENO: result: no" >&5
6462 $as_echo "no" >&6; }
6463         ;;
6464     esac
6465   fi
6466
6467
6468
6469 if test -n "$ac_tool_prefix"; then
6470   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6471 set dummy ${ac_tool_prefix}ar; ac_word=$2
6472 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6473 $as_echo_n "checking for $ac_word... " >&6; }
6474 if test "${ac_cv_prog_AR+set}" = set; then
6475   $as_echo_n "(cached) " >&6
6476 else
6477   if test -n "$AR"; then
6478   ac_cv_prog_AR="$AR" # Let the user override the test.
6479 else
6480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6481 for as_dir in $PATH
6482 do
6483   IFS=$as_save_IFS
6484   test -z "$as_dir" && as_dir=.
6485   for ac_exec_ext in '' $ac_executable_extensions; do
6486   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6487     ac_cv_prog_AR="${ac_tool_prefix}ar"
6488     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6489     break 2
6490   fi
6491 done
6492 done
6493 IFS=$as_save_IFS
6494
6495 fi
6496 fi
6497 AR=$ac_cv_prog_AR
6498 if test -n "$AR"; then
6499   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6500 $as_echo "$AR" >&6; }
6501 else
6502   { $as_echo "$as_me:$LINENO: result: no" >&5
6503 $as_echo "no" >&6; }
6504 fi
6505
6506
6507 fi
6508 if test -z "$ac_cv_prog_AR"; then
6509   ac_ct_AR=$AR
6510   # Extract the first word of "ar", so it can be a program name with args.
6511 set dummy ar; ac_word=$2
6512 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6513 $as_echo_n "checking for $ac_word... " >&6; }
6514 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6515   $as_echo_n "(cached) " >&6
6516 else
6517   if test -n "$ac_ct_AR"; then
6518   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6519 else
6520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6521 for as_dir in $PATH
6522 do
6523   IFS=$as_save_IFS
6524   test -z "$as_dir" && as_dir=.
6525   for ac_exec_ext in '' $ac_executable_extensions; do
6526   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6527     ac_cv_prog_ac_ct_AR="ar"
6528     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6529     break 2
6530   fi
6531 done
6532 done
6533 IFS=$as_save_IFS
6534
6535 fi
6536 fi
6537 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6538 if test -n "$ac_ct_AR"; then
6539   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6540 $as_echo "$ac_ct_AR" >&6; }
6541 else
6542   { $as_echo "$as_me:$LINENO: result: no" >&5
6543 $as_echo "no" >&6; }
6544 fi
6545
6546   if test "x$ac_ct_AR" = x; then
6547     AR="ar"
6548   else
6549     case $cross_compiling:$ac_tool_warned in
6550 yes:)
6551 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6552 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6553 ac_tool_warned=yes ;;
6554 esac
6555     AR=$ac_ct_AR
6556   fi
6557 else
6558   AR="$ac_cv_prog_AR"
6559 fi
6560
6561 if test "$PORTNAME" = "win32"; then
6562   if test -n "$ac_tool_prefix"; then
6563   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6564 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6565 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6566 $as_echo_n "checking for $ac_word... " >&6; }
6567 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6568   $as_echo_n "(cached) " >&6
6569 else
6570   if test -n "$DLLTOOL"; then
6571   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6572 else
6573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6574 for as_dir in $PATH
6575 do
6576   IFS=$as_save_IFS
6577   test -z "$as_dir" && as_dir=.
6578   for ac_exec_ext in '' $ac_executable_extensions; do
6579   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6580     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6581     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6582     break 2
6583   fi
6584 done
6585 done
6586 IFS=$as_save_IFS
6587
6588 fi
6589 fi
6590 DLLTOOL=$ac_cv_prog_DLLTOOL
6591 if test -n "$DLLTOOL"; then
6592   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6593 $as_echo "$DLLTOOL" >&6; }
6594 else
6595   { $as_echo "$as_me:$LINENO: result: no" >&5
6596 $as_echo "no" >&6; }
6597 fi
6598
6599
6600 fi
6601 if test -z "$ac_cv_prog_DLLTOOL"; then
6602   ac_ct_DLLTOOL=$DLLTOOL
6603   # Extract the first word of "dlltool", so it can be a program name with args.
6604 set dummy dlltool; ac_word=$2
6605 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6606 $as_echo_n "checking for $ac_word... " >&6; }
6607 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6608   $as_echo_n "(cached) " >&6
6609 else
6610   if test -n "$ac_ct_DLLTOOL"; then
6611   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6612 else
6613 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6614 for as_dir in $PATH
6615 do
6616   IFS=$as_save_IFS
6617   test -z "$as_dir" && as_dir=.
6618   for ac_exec_ext in '' $ac_executable_extensions; do
6619   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6620     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6621     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6622     break 2
6623   fi
6624 done
6625 done
6626 IFS=$as_save_IFS
6627
6628 fi
6629 fi
6630 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6631 if test -n "$ac_ct_DLLTOOL"; then
6632   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6633 $as_echo "$ac_ct_DLLTOOL" >&6; }
6634 else
6635   { $as_echo "$as_me:$LINENO: result: no" >&5
6636 $as_echo "no" >&6; }
6637 fi
6638
6639   if test "x$ac_ct_DLLTOOL" = x; then
6640     DLLTOOL="dlltool"
6641   else
6642     case $cross_compiling:$ac_tool_warned in
6643 yes:)
6644 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6645 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6646 ac_tool_warned=yes ;;
6647 esac
6648     DLLTOOL=$ac_ct_DLLTOOL
6649   fi
6650 else
6651   DLLTOOL="$ac_cv_prog_DLLTOOL"
6652 fi
6653
6654   if test -n "$ac_tool_prefix"; then
6655   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6656 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6657 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6658 $as_echo_n "checking for $ac_word... " >&6; }
6659 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6660   $as_echo_n "(cached) " >&6
6661 else
6662   if test -n "$DLLWRAP"; then
6663   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6664 else
6665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6666 for as_dir in $PATH
6667 do
6668   IFS=$as_save_IFS
6669   test -z "$as_dir" && as_dir=.
6670   for ac_exec_ext in '' $ac_executable_extensions; do
6671   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6672     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6673     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6674     break 2
6675   fi
6676 done
6677 done
6678 IFS=$as_save_IFS
6679
6680 fi
6681 fi
6682 DLLWRAP=$ac_cv_prog_DLLWRAP
6683 if test -n "$DLLWRAP"; then
6684   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6685 $as_echo "$DLLWRAP" >&6; }
6686 else
6687   { $as_echo "$as_me:$LINENO: result: no" >&5
6688 $as_echo "no" >&6; }
6689 fi
6690
6691
6692 fi
6693 if test -z "$ac_cv_prog_DLLWRAP"; then
6694   ac_ct_DLLWRAP=$DLLWRAP
6695   # Extract the first word of "dllwrap", so it can be a program name with args.
6696 set dummy dllwrap; ac_word=$2
6697 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6698 $as_echo_n "checking for $ac_word... " >&6; }
6699 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6700   $as_echo_n "(cached) " >&6
6701 else
6702   if test -n "$ac_ct_DLLWRAP"; then
6703   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6704 else
6705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6706 for as_dir in $PATH
6707 do
6708   IFS=$as_save_IFS
6709   test -z "$as_dir" && as_dir=.
6710   for ac_exec_ext in '' $ac_executable_extensions; do
6711   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6712     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6713     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6714     break 2
6715   fi
6716 done
6717 done
6718 IFS=$as_save_IFS
6719
6720 fi
6721 fi
6722 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6723 if test -n "$ac_ct_DLLWRAP"; then
6724   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6725 $as_echo "$ac_ct_DLLWRAP" >&6; }
6726 else
6727   { $as_echo "$as_me:$LINENO: result: no" >&5
6728 $as_echo "no" >&6; }
6729 fi
6730
6731   if test "x$ac_ct_DLLWRAP" = x; then
6732     DLLWRAP="dllwrap"
6733   else
6734     case $cross_compiling:$ac_tool_warned in
6735 yes:)
6736 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6737 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6738 ac_tool_warned=yes ;;
6739 esac
6740     DLLWRAP=$ac_ct_DLLWRAP
6741   fi
6742 else
6743   DLLWRAP="$ac_cv_prog_DLLWRAP"
6744 fi
6745
6746   if test -n "$ac_tool_prefix"; then
6747   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6748 set dummy ${ac_tool_prefix}windres; ac_word=$2
6749 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6750 $as_echo_n "checking for $ac_word... " >&6; }
6751 if test "${ac_cv_prog_WINDRES+set}" = set; then
6752   $as_echo_n "(cached) " >&6
6753 else
6754   if test -n "$WINDRES"; then
6755   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6756 else
6757 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6758 for as_dir in $PATH
6759 do
6760   IFS=$as_save_IFS
6761   test -z "$as_dir" && as_dir=.
6762   for ac_exec_ext in '' $ac_executable_extensions; do
6763   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6764     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6765     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6766     break 2
6767   fi
6768 done
6769 done
6770 IFS=$as_save_IFS
6771
6772 fi
6773 fi
6774 WINDRES=$ac_cv_prog_WINDRES
6775 if test -n "$WINDRES"; then
6776   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6777 $as_echo "$WINDRES" >&6; }
6778 else
6779   { $as_echo "$as_me:$LINENO: result: no" >&5
6780 $as_echo "no" >&6; }
6781 fi
6782
6783
6784 fi
6785 if test -z "$ac_cv_prog_WINDRES"; then
6786   ac_ct_WINDRES=$WINDRES
6787   # Extract the first word of "windres", so it can be a program name with args.
6788 set dummy windres; ac_word=$2
6789 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6790 $as_echo_n "checking for $ac_word... " >&6; }
6791 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6792   $as_echo_n "(cached) " >&6
6793 else
6794   if test -n "$ac_ct_WINDRES"; then
6795   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6796 else
6797 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6798 for as_dir in $PATH
6799 do
6800   IFS=$as_save_IFS
6801   test -z "$as_dir" && as_dir=.
6802   for ac_exec_ext in '' $ac_executable_extensions; do
6803   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6804     ac_cv_prog_ac_ct_WINDRES="windres"
6805     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6806     break 2
6807   fi
6808 done
6809 done
6810 IFS=$as_save_IFS
6811
6812 fi
6813 fi
6814 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6815 if test -n "$ac_ct_WINDRES"; then
6816   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6817 $as_echo "$ac_ct_WINDRES" >&6; }
6818 else
6819   { $as_echo "$as_me:$LINENO: result: no" >&5
6820 $as_echo "no" >&6; }
6821 fi
6822
6823   if test "x$ac_ct_WINDRES" = x; then
6824     WINDRES="windres"
6825   else
6826     case $cross_compiling:$ac_tool_warned in
6827 yes:)
6828 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6829 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6830 ac_tool_warned=yes ;;
6831 esac
6832     WINDRES=$ac_ct_WINDRES
6833   fi
6834 else
6835   WINDRES="$ac_cv_prog_WINDRES"
6836 fi
6837
6838 fi
6839
6840 # Find a good install program.  We prefer a C program (faster),
6841 # so one script is as good as another.  But avoid the broken or
6842 # incompatible versions:
6843 # SysV /etc/install, /usr/sbin/install
6844 # SunOS /usr/etc/install
6845 # IRIX /sbin/install
6846 # AIX /bin/install
6847 # AmigaOS /C/install, which installs bootblocks on floppy discs
6848 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6849 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
6850 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6851 # OS/2's system install, which has a completely different semantic
6852 # ./install, which can be erroneously created by make from ./install.sh.
6853 # Reject install programs that cannot install multiple files.
6854 { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
6855 $as_echo_n "checking for a BSD-compatible install... " >&6; }
6856 if test -z "$INSTALL"; then
6857 if test "${ac_cv_path_install+set}" = set; then
6858   $as_echo_n "(cached) " >&6
6859 else
6860   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6861 for as_dir in $PATH
6862 do
6863   IFS=$as_save_IFS
6864   test -z "$as_dir" && as_dir=.
6865   # Account for people who put trailing slashes in PATH elements.
6866 case $as_dir/ in
6867   ./ | .// | /cC/* | \
6868   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
6869   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
6870   /usr/ucb/* ) ;;
6871   *)
6872     # OSF1 and SCO ODT 3.0 have their own names for install.
6873     # Don't use installbsd from OSF since it installs stuff as root
6874     # by default.
6875     for ac_prog in ginstall scoinst install; do
6876       for ac_exec_ext in '' $ac_executable_extensions; do
6877         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
6878           if test $ac_prog = install &&
6879             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6880             # AIX install.  It has an incompatible calling convention.
6881             :
6882           elif test $ac_prog = install &&
6883             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6884             # program-specific install script used by HP pwplus--don't use.
6885             :
6886           else
6887             rm -rf conftest.one conftest.two conftest.dir
6888             echo one > conftest.one
6889             echo two > conftest.two
6890             mkdir conftest.dir
6891             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
6892               test -s conftest.one && test -s conftest.two &&
6893               test -s conftest.dir/conftest.one &&
6894               test -s conftest.dir/conftest.two
6895             then
6896               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
6897               break 3
6898             fi
6899           fi
6900         fi
6901       done
6902     done
6903     ;;
6904 esac
6905
6906 done
6907 IFS=$as_save_IFS
6908
6909 rm -rf conftest.one conftest.two conftest.dir
6910
6911 fi
6912   if test "${ac_cv_path_install+set}" = set; then
6913     INSTALL=$ac_cv_path_install
6914   else
6915     # As a last resort, use the slow shell script.  Don't cache a
6916     # value for INSTALL within a source directory, because that will
6917     # break other packages using the cache if that directory is
6918     # removed, or if the value is a relative name.
6919     INSTALL=$ac_install_sh
6920   fi
6921 fi
6922 { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
6923 $as_echo "$INSTALL" >&6; }
6924
6925 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
6926 # It thinks the first close brace ends the variable substitution.
6927 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
6928
6929 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
6930
6931 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
6932
6933 # When Autoconf chooses install-sh as install program it tries to generate
6934 # a relative path to it in each makefile where it subsitutes it. This clashes
6935 # with our Makefile.global concept. This workaround helps.
6936 case $INSTALL in
6937   *install-sh*) install_bin='';;
6938   *) install_bin=$INSTALL;;
6939 esac
6940
6941
6942 # Extract the first word of "tar", so it can be a program name with args.
6943 set dummy tar; ac_word=$2
6944 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6945 $as_echo_n "checking for $ac_word... " >&6; }
6946 if test "${ac_cv_path_TAR+set}" = set; then
6947   $as_echo_n "(cached) " >&6
6948 else
6949   case $TAR in
6950   [\\/]* | ?:[\\/]*)
6951   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
6952   ;;
6953   *)
6954   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6955 for as_dir in $PATH
6956 do
6957   IFS=$as_save_IFS
6958   test -z "$as_dir" && as_dir=.
6959   for ac_exec_ext in '' $ac_executable_extensions; do
6960   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6961     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
6962     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6963     break 2
6964   fi
6965 done
6966 done
6967 IFS=$as_save_IFS
6968
6969   ;;
6970 esac
6971 fi
6972 TAR=$ac_cv_path_TAR
6973 if test -n "$TAR"; then
6974   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
6975 $as_echo "$TAR" >&6; }
6976 else
6977   { $as_echo "$as_me:$LINENO: result: no" >&5
6978 $as_echo "no" >&6; }
6979 fi
6980
6981
6982 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
6983 $as_echo_n "checking whether ln -s works... " >&6; }
6984 LN_S=$as_ln_s
6985 if test "$LN_S" = "ln -s"; then
6986   { $as_echo "$as_me:$LINENO: result: yes" >&5
6987 $as_echo "yes" >&6; }
6988 else
6989   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6990 $as_echo "no, using $LN_S" >&6; }
6991 fi
6992
6993 for ac_prog in gawk mawk nawk awk
6994 do
6995   # Extract the first word of "$ac_prog", so it can be a program name with args.
6996 set dummy $ac_prog; ac_word=$2
6997 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6998 $as_echo_n "checking for $ac_word... " >&6; }
6999 if test "${ac_cv_prog_AWK+set}" = set; then
7000   $as_echo_n "(cached) " >&6
7001 else
7002   if test -n "$AWK"; then
7003   ac_cv_prog_AWK="$AWK" # Let the user override the test.
7004 else
7005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7006 for as_dir in $PATH
7007 do
7008   IFS=$as_save_IFS
7009   test -z "$as_dir" && as_dir=.
7010   for ac_exec_ext in '' $ac_executable_extensions; do
7011   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7012     ac_cv_prog_AWK="$ac_prog"
7013     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7014     break 2
7015   fi
7016 done
7017 done
7018 IFS=$as_save_IFS
7019
7020 fi
7021 fi
7022 AWK=$ac_cv_prog_AWK
7023 if test -n "$AWK"; then
7024   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
7025 $as_echo "$AWK" >&6; }
7026 else
7027   { $as_echo "$as_me:$LINENO: result: no" >&5
7028 $as_echo "no" >&6; }
7029 fi
7030
7031
7032   test -n "$AWK" && break
7033 done
7034
7035 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
7036 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
7037 if test -z "$MKDIR_P"; then
7038   if test "${ac_cv_path_mkdir+set}" = set; then
7039   $as_echo_n "(cached) " >&6
7040 else
7041   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7042 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
7043 do
7044   IFS=$as_save_IFS
7045   test -z "$as_dir" && as_dir=.
7046   for ac_prog in mkdir gmkdir; do
7047          for ac_exec_ext in '' $ac_executable_extensions; do
7048            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
7049            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
7050              'mkdir (GNU coreutils) '* | \
7051              'mkdir (coreutils) '* | \
7052              'mkdir (fileutils) '4.1*)
7053                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
7054                break 3;;
7055            esac
7056          done
7057        done
7058 done
7059 IFS=$as_save_IFS
7060
7061 fi
7062
7063   if test "${ac_cv_path_mkdir+set}" = set; then
7064     MKDIR_P="$ac_cv_path_mkdir -p"
7065   else
7066     # As a last resort, use the slow shell script.  Don't cache a
7067     # value for MKDIR_P within a source directory, because that will
7068     # break other packages using the cache if that directory is
7069     # removed, or if the value is a relative name.
7070     test -d ./--version && rmdir ./--version
7071     MKDIR_P="$ac_install_sh -d"
7072   fi
7073 fi
7074 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
7075 $as_echo "$MKDIR_P" >&6; }
7076
7077 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
7078 # a relative path to it in each makefile where it subsitutes it. This clashes
7079 # with our Makefile.global concept. This workaround helps.
7080 case $MKDIR_P in
7081   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
7082 esac
7083
7084 # Let the user override the search
7085 if test -z "$BISON"; then
7086   for ac_prog in bison
7087 do
7088   # Extract the first word of "$ac_prog", so it can be a program name with args.
7089 set dummy $ac_prog; ac_word=$2
7090 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7091 $as_echo_n "checking for $ac_word... " >&6; }
7092 if test "${ac_cv_path_BISON+set}" = set; then
7093   $as_echo_n "(cached) " >&6
7094 else
7095   case $BISON in
7096   [\\/]* | ?:[\\/]*)
7097   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
7098   ;;
7099   *)
7100   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7101 for as_dir in $PATH
7102 do
7103   IFS=$as_save_IFS
7104   test -z "$as_dir" && as_dir=.
7105   for ac_exec_ext in '' $ac_executable_extensions; do
7106   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7107     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
7108     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7109     break 2
7110   fi
7111 done
7112 done
7113 IFS=$as_save_IFS
7114
7115   ;;
7116 esac
7117 fi
7118 BISON=$ac_cv_path_BISON
7119 if test -n "$BISON"; then
7120   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
7121 $as_echo "$BISON" >&6; }
7122 else
7123   { $as_echo "$as_me:$LINENO: result: no" >&5
7124 $as_echo "no" >&6; }
7125 fi
7126
7127
7128   test -n "$BISON" && break
7129 done
7130
7131 fi
7132
7133 if test "$BISON"; then
7134   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
7135   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
7136 $as_echo "$as_me: using $pgac_bison_version" >&6;}
7137   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
7138   then
7139     { $as_echo "$as_me:$LINENO: WARNING:
7140 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
7141 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
7142 $as_echo "$as_me: WARNING:
7143 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
7144 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
7145     BISON=""
7146   fi
7147 fi
7148
7149 if test -z "$BISON"; then
7150   { $as_echo "$as_me:$LINENO: WARNING:
7151 *** Without Bison you will not be able to build PostgreSQL from Git nor
7152 *** change any of the parser definition files.  You can obtain Bison from
7153 *** a GNU mirror site.  (If you are using the official distribution of
7154 *** PostgreSQL then you do not need to worry about this, because the Bison
7155 *** output is pre-generated.)" >&5
7156 $as_echo "$as_me: WARNING:
7157 *** Without Bison you will not be able to build PostgreSQL from Git nor
7158 *** change any of the parser definition files.  You can obtain Bison from
7159 *** a GNU mirror site.  (If you are using the official distribution of
7160 *** PostgreSQL then you do not need to worry about this, because the Bison
7161 *** output is pre-generated.)" >&2;}
7162 fi
7163 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
7164
7165
7166 { $as_echo "$as_me:$LINENO: checking for flex" >&5
7167 $as_echo_n "checking for flex... " >&6; }
7168 if test "${pgac_cv_path_flex+set}" = set; then
7169   $as_echo_n "(cached) " >&6
7170 else
7171   # Let the user override the test
7172 if test -n "$FLEX"; then
7173   pgac_cv_path_flex=$FLEX
7174 else
7175   pgac_save_IFS=$IFS
7176   IFS=$PATH_SEPARATOR
7177   for pgac_dir in $PATH; do
7178     IFS=$pgac_save_IFS
7179     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
7180       pgac_dir=`pwd`
7181     fi
7182     for pgac_prog in flex lex; do
7183       pgac_candidate="$pgac_dir/$pgac_prog"
7184       if test -f "$pgac_candidate" \
7185         && $pgac_candidate --version </dev/null >/dev/null 2>&1
7186       then
7187         echo '%%'  > conftest.l
7188         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
7189           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
7190           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
7191           then
7192             pgac_cv_path_flex=$pgac_candidate
7193             break 2
7194           else
7195             { $as_echo "$as_me:$LINENO: WARNING:
7196 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
7197 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
7198 $as_echo "$as_me: WARNING:
7199 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
7200 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
7201           fi
7202         fi
7203       fi
7204     done
7205   done
7206   rm -f conftest.l lex.yy.c
7207   : ${pgac_cv_path_flex=no}
7208 fi
7209
7210 fi
7211 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
7212 $as_echo "$pgac_cv_path_flex" >&6; }
7213 if test x"$pgac_cv_path_flex" = x"no"; then
7214   { $as_echo "$as_me:$LINENO: WARNING:
7215 *** Without Flex you will not be able to build PostgreSQL from Git nor
7216 *** change any of the scanner definition files.  You can obtain Flex from
7217 *** a GNU mirror site.  (If you are using the official distribution of
7218 *** PostgreSQL then you do not need to worry about this because the Flex
7219 *** output is pre-generated.)" >&5
7220 $as_echo "$as_me: WARNING:
7221 *** Without Flex you will not be able to build PostgreSQL from Git nor
7222 *** change any of the scanner definition files.  You can obtain Flex from
7223 *** a GNU mirror site.  (If you are using the official distribution of
7224 *** PostgreSQL then you do not need to worry about this because the Flex
7225 *** output is pre-generated.)" >&2;}
7226
7227   FLEX=
7228 else
7229   FLEX=$pgac_cv_path_flex
7230   pgac_flex_version=`$FLEX --version 2>/dev/null`
7231   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
7232 $as_echo "$as_me: using $pgac_flex_version" >&6;}
7233 fi
7234
7235
7236
7237
7238
7239 # Let the user override the search
7240 if test -z "$PERL"; then
7241   # Extract the first word of "perl", so it can be a program name with args.
7242 set dummy perl; ac_word=$2
7243 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7244 $as_echo_n "checking for $ac_word... " >&6; }
7245 if test "${ac_cv_path_PERL+set}" = set; then
7246   $as_echo_n "(cached) " >&6
7247 else
7248   case $PERL in
7249   [\\/]* | ?:[\\/]*)
7250   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
7251   ;;
7252   *)
7253   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7254 for as_dir in $PATH
7255 do
7256   IFS=$as_save_IFS
7257   test -z "$as_dir" && as_dir=.
7258   for ac_exec_ext in '' $ac_executable_extensions; do
7259   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7260     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
7261     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7262     break 2
7263   fi
7264 done
7265 done
7266 IFS=$as_save_IFS
7267
7268   ;;
7269 esac
7270 fi
7271 PERL=$ac_cv_path_PERL
7272 if test -n "$PERL"; then
7273   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
7274 $as_echo "$PERL" >&6; }
7275 else
7276   { $as_echo "$as_me:$LINENO: result: no" >&5
7277 $as_echo "no" >&6; }
7278 fi
7279
7280
7281 fi
7282
7283 if test "$PERL"; then
7284   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'`
7285   { $as_echo "$as_me:$LINENO: using perl $pgac_perl_version" >&5
7286 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
7287   if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
7288     $AWK '{ if ($1 = 5 && $2 >= 8) exit 1; else exit 0;}'
7289   then
7290     { $as_echo "$as_me:$LINENO: WARNING:
7291 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
7292 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
7293 $as_echo "$as_me: WARNING:
7294 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
7295 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
7296     PERL=""
7297   fi
7298 fi
7299
7300 if test -z "$PERL"; then
7301   { $as_echo "$as_me:$LINENO: WARNING:
7302 *** Without Perl you will not be able to build PostgreSQL from Git.
7303 *** You can obtain Perl from any CPAN mirror site.
7304 *** (If you are using the official distribution of PostgreSQL then you do not
7305 *** need to worry about this, because the Perl output is pre-generated.)" >&5
7306 $as_echo "$as_me: WARNING:
7307 *** Without Perl you will not be able to build PostgreSQL from Git.
7308 *** You can obtain Perl from any CPAN mirror site.
7309 *** (If you are using the official distribution of PostgreSQL then you do not
7310 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
7311 fi
7312
7313 if test "$with_perl" = yes; then
7314   if test -z "$PERL"; then
7315     { { $as_echo "$as_me:$LINENO: error: Perl not found" >&5
7316 $as_echo "$as_me: error: Perl not found" >&2;}
7317    { (exit 1); exit 1; }; }
7318   fi
7319
7320 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
7321 $as_echo_n "checking for Perl archlibexp... " >&6; }
7322 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
7323 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
7324 $as_echo "$perl_archlibexp" >&6; }
7325 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
7326 $as_echo_n "checking for Perl privlibexp... " >&6; }
7327 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
7328 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
7329 $as_echo "$perl_privlibexp" >&6; }
7330 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
7331 $as_echo_n "checking for Perl useshrplib... " >&6; }
7332 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
7333 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
7334 $as_echo "$perl_useshrplib" >&6; }
7335
7336 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
7337 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
7338 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
7339 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
7340 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
7341 if test -z "$perl_embed_ldflags" ; then
7342         { $as_echo "$as_me:$LINENO: result: no" >&5
7343 $as_echo "no" >&6; }
7344         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
7345 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7346 installed." >&5
7347 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
7348 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7349 installed." >&2;}
7350    { (exit 1); exit 1; }; }
7351 else
7352         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
7353 $as_echo "$perl_embed_ldflags" >&6; }
7354 fi
7355
7356 fi
7357
7358 if test "$with_python" = yes; then
7359   # Extract the first word of "python", so it can be a program name with args.
7360 set dummy python; ac_word=$2
7361 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7362 $as_echo_n "checking for $ac_word... " >&6; }
7363 if test "${ac_cv_path_PYTHON+set}" = set; then
7364   $as_echo_n "(cached) " >&6
7365 else
7366   case $PYTHON in
7367   [\\/]* | ?:[\\/]*)
7368   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
7369   ;;
7370   *)
7371   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7372 for as_dir in $PATH
7373 do
7374   IFS=$as_save_IFS
7375   test -z "$as_dir" && as_dir=.
7376   for ac_exec_ext in '' $ac_executable_extensions; do
7377   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7378     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
7379     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7380     break 2
7381   fi
7382 done
7383 done
7384 IFS=$as_save_IFS
7385
7386   ;;
7387 esac
7388 fi
7389 PYTHON=$ac_cv_path_PYTHON
7390 if test -n "$PYTHON"; then
7391   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
7392 $as_echo "$PYTHON" >&6; }
7393 else
7394   { $as_echo "$as_me:$LINENO: result: no" >&5
7395 $as_echo "no" >&6; }
7396 fi
7397
7398
7399 if test x"$PYTHON" = x""; then
7400   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
7401 $as_echo "$as_me: error: Python not found" >&2;}
7402    { (exit 1); exit 1; }; }
7403 fi
7404
7405
7406 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
7407 $as_echo_n "checking for Python distutils module... " >&6; }
7408 if "${PYTHON}" -c 'import distutils' 2>&5
7409 then
7410     { $as_echo "$as_me:$LINENO: result: yes" >&5
7411 $as_echo "yes" >&6; }
7412 else
7413     { $as_echo "$as_me:$LINENO: result: no" >&5
7414 $as_echo "no" >&6; }
7415     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
7416 $as_echo "$as_me: error: distutils module not found" >&2;}
7417    { (exit 1); exit 1; }; }
7418 fi
7419 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
7420 $as_echo_n "checking Python configuration directory... " >&6; }
7421 python_majorversion=`${PYTHON} -c "import sys; print(sys.version[0])"`
7422 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
7423 python_configdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBPL'))))"`
7424 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
7425 $as_echo "$python_configdir" >&6; }
7426
7427 { $as_echo "$as_me:$LINENO: checking Python include directories" >&5
7428 $as_echo_n "checking Python include directories... " >&6; }
7429 python_includespec=`${PYTHON} -c "
7430 import distutils.sysconfig
7431 a = '-I' + distutils.sysconfig.get_python_inc(False)
7432 b = '-I' + distutils.sysconfig.get_python_inc(True)
7433 if a == b:
7434     print(a)
7435 else:
7436     print(a + ' ' + b)"`
7437 { $as_echo "$as_me:$LINENO: result: $python_includespec" >&5
7438 $as_echo "$python_includespec" >&6; }
7439
7440
7441
7442 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
7443 $as_echo_n "checking how to link an embedded Python application... " >&6; }
7444
7445 python_libdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
7446 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
7447 python_so=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
7448 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
7449
7450 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
7451 then
7452         # New way: use the official shared library
7453         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
7454         python_libspec="-L${python_libdir} -l${ldlibrary}"
7455 else
7456         # Old way: use libpython from python_configdir
7457         python_libdir="${python_configdir}"
7458         # LDVERSION was introduced in Python 3.2.
7459         python_ldversion=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDVERSION'))))"`
7460         if test x"${python_ldversion}" = x""; then
7461                 python_ldversion=$python_version
7462         fi
7463         python_libspec="-L${python_libdir} -lpython${python_ldversion}"
7464 fi
7465
7466 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
7467
7468 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
7469 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
7470
7471
7472 # threaded python is not supported on OpenBSD
7473 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7474 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7475 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7476 if test "$pythreads" = "1"; then
7477   { $as_echo "$as_me:$LINENO: result: yes" >&5
7478 $as_echo "yes" >&6; }
7479   case $host_os in
7480   openbsd*)
7481     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7482 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7483    { (exit 1); exit 1; }; }
7484     ;;
7485   esac
7486 else
7487   { $as_echo "$as_me:$LINENO: result: no" >&5
7488 $as_echo "no" >&6; }
7489 fi
7490
7491
7492 fi
7493
7494 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7495   # Extract the first word of "zic", so it can be a program name with args.
7496 set dummy zic; ac_word=$2
7497 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7498 $as_echo_n "checking for $ac_word... " >&6; }
7499 if test "${ac_cv_path_ZIC+set}" = set; then
7500   $as_echo_n "(cached) " >&6
7501 else
7502   case $ZIC in
7503   [\\/]* | ?:[\\/]*)
7504   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7505   ;;
7506   *)
7507   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7508 for as_dir in $PATH
7509 do
7510   IFS=$as_save_IFS
7511   test -z "$as_dir" && as_dir=.
7512   for ac_exec_ext in '' $ac_executable_extensions; do
7513   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7514     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7515     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7516     break 2
7517   fi
7518 done
7519 done
7520 IFS=$as_save_IFS
7521
7522   ;;
7523 esac
7524 fi
7525 ZIC=$ac_cv_path_ZIC
7526 if test -n "$ZIC"; then
7527   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7528 $as_echo "$ZIC" >&6; }
7529 else
7530   { $as_echo "$as_me:$LINENO: result: no" >&5
7531 $as_echo "no" >&6; }
7532 fi
7533
7534
7535   if test -z "$ZIC"; then
7536     { { $as_echo "$as_me:$LINENO: error:
7537 When cross-compiling, either use the option --with-system-tzdata to use
7538 existing time-zone data, or set the environment variable ZIC to a zic
7539 program to use during the build." >&5
7540 $as_echo "$as_me: error:
7541 When cross-compiling, either use the option --with-system-tzdata to use
7542 existing time-zone data, or set the environment variable ZIC to a zic
7543 program to use during the build." >&2;}
7544    { (exit 1); exit 1; }; }
7545   fi
7546 fi
7547
7548
7549 ##
7550 ## Libraries
7551 ##
7552 ## Most libraries are included only if they demonstrably provide a function
7553 ## we need, but libm is an exception: always include it, because there are
7554 ## too many compilers that play cute optimization games that will break
7555 ## probes for standard functions such as pow().
7556 ##
7557
7558
7559 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7560 $as_echo_n "checking for main in -lm... " >&6; }
7561 if test "${ac_cv_lib_m_main+set}" = set; then
7562   $as_echo_n "(cached) " >&6
7563 else
7564   ac_check_lib_save_LIBS=$LIBS
7565 LIBS="-lm  $LIBS"
7566 cat >conftest.$ac_ext <<_ACEOF
7567 /* confdefs.h.  */
7568 _ACEOF
7569 cat confdefs.h >>conftest.$ac_ext
7570 cat >>conftest.$ac_ext <<_ACEOF
7571 /* end confdefs.h.  */
7572
7573
7574 int
7575 main ()
7576 {
7577 return main ();
7578   ;
7579   return 0;
7580 }
7581 _ACEOF
7582 rm -f conftest.$ac_objext conftest$ac_exeext
7583 if { (ac_try="$ac_link"
7584 case "(($ac_try" in
7585   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7586   *) ac_try_echo=$ac_try;;
7587 esac
7588 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7589 $as_echo "$ac_try_echo") >&5
7590   (eval "$ac_link") 2>conftest.er1
7591   ac_status=$?
7592   grep -v '^ *+' conftest.er1 >conftest.err
7593   rm -f conftest.er1
7594   cat conftest.err >&5
7595   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7596   (exit $ac_status); } && {
7597          test -z "$ac_c_werror_flag" ||
7598          test ! -s conftest.err
7599        } && test -s conftest$ac_exeext && {
7600          test "$cross_compiling" = yes ||
7601          $as_test_x conftest$ac_exeext
7602        }; then
7603   ac_cv_lib_m_main=yes
7604 else
7605   $as_echo "$as_me: failed program was:" >&5
7606 sed 's/^/| /' conftest.$ac_ext >&5
7607
7608         ac_cv_lib_m_main=no
7609 fi
7610
7611 rm -rf conftest.dSYM
7612 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7613       conftest$ac_exeext conftest.$ac_ext
7614 LIBS=$ac_check_lib_save_LIBS
7615 fi
7616 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7617 $as_echo "$ac_cv_lib_m_main" >&6; }
7618 if test "x$ac_cv_lib_m_main" = x""yes; then
7619   cat >>confdefs.h <<_ACEOF
7620 #define HAVE_LIBM 1
7621 _ACEOF
7622
7623   LIBS="-lm $LIBS"
7624
7625 fi
7626
7627 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7628 $as_echo_n "checking for library containing setproctitle... " >&6; }
7629 if test "${ac_cv_search_setproctitle+set}" = set; then
7630   $as_echo_n "(cached) " >&6
7631 else
7632   ac_func_search_save_LIBS=$LIBS
7633 cat >conftest.$ac_ext <<_ACEOF
7634 /* confdefs.h.  */
7635 _ACEOF
7636 cat confdefs.h >>conftest.$ac_ext
7637 cat >>conftest.$ac_ext <<_ACEOF
7638 /* end confdefs.h.  */
7639
7640 /* Override any GCC internal prototype to avoid an error.
7641    Use char because int might match the return type of a GCC
7642    builtin and then its argument prototype would still apply.  */
7643 #ifdef __cplusplus
7644 extern "C"
7645 #endif
7646 char setproctitle ();
7647 int
7648 main ()
7649 {
7650 return setproctitle ();
7651   ;
7652   return 0;
7653 }
7654 _ACEOF
7655 for ac_lib in '' util; do
7656   if test -z "$ac_lib"; then
7657     ac_res="none required"
7658   else
7659     ac_res=-l$ac_lib
7660     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7661   fi
7662   rm -f conftest.$ac_objext conftest$ac_exeext
7663 if { (ac_try="$ac_link"
7664 case "(($ac_try" in
7665   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7666   *) ac_try_echo=$ac_try;;
7667 esac
7668 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7669 $as_echo "$ac_try_echo") >&5
7670   (eval "$ac_link") 2>conftest.er1
7671   ac_status=$?
7672   grep -v '^ *+' conftest.er1 >conftest.err
7673   rm -f conftest.er1
7674   cat conftest.err >&5
7675   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7676   (exit $ac_status); } && {
7677          test -z "$ac_c_werror_flag" ||
7678          test ! -s conftest.err
7679        } && test -s conftest$ac_exeext && {
7680          test "$cross_compiling" = yes ||
7681          $as_test_x conftest$ac_exeext
7682        }; then
7683   ac_cv_search_setproctitle=$ac_res
7684 else
7685   $as_echo "$as_me: failed program was:" >&5
7686 sed 's/^/| /' conftest.$ac_ext >&5
7687
7688
7689 fi
7690
7691 rm -rf conftest.dSYM
7692 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7693       conftest$ac_exeext
7694   if test "${ac_cv_search_setproctitle+set}" = set; then
7695   break
7696 fi
7697 done
7698 if test "${ac_cv_search_setproctitle+set}" = set; then
7699   :
7700 else
7701   ac_cv_search_setproctitle=no
7702 fi
7703 rm conftest.$ac_ext
7704 LIBS=$ac_func_search_save_LIBS
7705 fi
7706 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7707 $as_echo "$ac_cv_search_setproctitle" >&6; }
7708 ac_res=$ac_cv_search_setproctitle
7709 if test "$ac_res" != no; then
7710   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7711
7712 fi
7713
7714 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7715 $as_echo_n "checking for library containing dlopen... " >&6; }
7716 if test "${ac_cv_search_dlopen+set}" = set; then
7717   $as_echo_n "(cached) " >&6
7718 else
7719   ac_func_search_save_LIBS=$LIBS
7720 cat >conftest.$ac_ext <<_ACEOF
7721 /* confdefs.h.  */
7722 _ACEOF
7723 cat confdefs.h >>conftest.$ac_ext
7724 cat >>conftest.$ac_ext <<_ACEOF
7725 /* end confdefs.h.  */
7726
7727 /* Override any GCC internal prototype to avoid an error.
7728    Use char because int might match the return type of a GCC
7729    builtin and then its argument prototype would still apply.  */
7730 #ifdef __cplusplus
7731 extern "C"
7732 #endif
7733 char dlopen ();
7734 int
7735 main ()
7736 {
7737 return dlopen ();
7738   ;
7739   return 0;
7740 }
7741 _ACEOF
7742 for ac_lib in '' dl; do
7743   if test -z "$ac_lib"; then
7744     ac_res="none required"
7745   else
7746     ac_res=-l$ac_lib
7747     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7748   fi
7749   rm -f conftest.$ac_objext conftest$ac_exeext
7750 if { (ac_try="$ac_link"
7751 case "(($ac_try" in
7752   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7753   *) ac_try_echo=$ac_try;;
7754 esac
7755 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7756 $as_echo "$ac_try_echo") >&5
7757   (eval "$ac_link") 2>conftest.er1
7758   ac_status=$?
7759   grep -v '^ *+' conftest.er1 >conftest.err
7760   rm -f conftest.er1
7761   cat conftest.err >&5
7762   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7763   (exit $ac_status); } && {
7764          test -z "$ac_c_werror_flag" ||
7765          test ! -s conftest.err
7766        } && test -s conftest$ac_exeext && {
7767          test "$cross_compiling" = yes ||
7768          $as_test_x conftest$ac_exeext
7769        }; then
7770   ac_cv_search_dlopen=$ac_res
7771 else
7772   $as_echo "$as_me: failed program was:" >&5
7773 sed 's/^/| /' conftest.$ac_ext >&5
7774
7775
7776 fi
7777
7778 rm -rf conftest.dSYM
7779 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7780       conftest$ac_exeext
7781   if test "${ac_cv_search_dlopen+set}" = set; then
7782   break
7783 fi
7784 done
7785 if test "${ac_cv_search_dlopen+set}" = set; then
7786   :
7787 else
7788   ac_cv_search_dlopen=no
7789 fi
7790 rm conftest.$ac_ext
7791 LIBS=$ac_func_search_save_LIBS
7792 fi
7793 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7794 $as_echo "$ac_cv_search_dlopen" >&6; }
7795 ac_res=$ac_cv_search_dlopen
7796 if test "$ac_res" != no; then
7797   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7798
7799 fi
7800
7801 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7802 $as_echo_n "checking for library containing socket... " >&6; }
7803 if test "${ac_cv_search_socket+set}" = set; then
7804   $as_echo_n "(cached) " >&6
7805 else
7806   ac_func_search_save_LIBS=$LIBS
7807 cat >conftest.$ac_ext <<_ACEOF
7808 /* confdefs.h.  */
7809 _ACEOF
7810 cat confdefs.h >>conftest.$ac_ext
7811 cat >>conftest.$ac_ext <<_ACEOF
7812 /* end confdefs.h.  */
7813
7814 /* Override any GCC internal prototype to avoid an error.
7815    Use char because int might match the return type of a GCC
7816    builtin and then its argument prototype would still apply.  */
7817 #ifdef __cplusplus
7818 extern "C"
7819 #endif
7820 char socket ();
7821 int
7822 main ()
7823 {
7824 return socket ();
7825   ;
7826   return 0;
7827 }
7828 _ACEOF
7829 for ac_lib in '' socket wsock32; do
7830   if test -z "$ac_lib"; then
7831     ac_res="none required"
7832   else
7833     ac_res=-l$ac_lib
7834     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7835   fi
7836   rm -f conftest.$ac_objext conftest$ac_exeext
7837 if { (ac_try="$ac_link"
7838 case "(($ac_try" in
7839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7840   *) ac_try_echo=$ac_try;;
7841 esac
7842 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7843 $as_echo "$ac_try_echo") >&5
7844   (eval "$ac_link") 2>conftest.er1
7845   ac_status=$?
7846   grep -v '^ *+' conftest.er1 >conftest.err
7847   rm -f conftest.er1
7848   cat conftest.err >&5
7849   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7850   (exit $ac_status); } && {
7851          test -z "$ac_c_werror_flag" ||
7852          test ! -s conftest.err
7853        } && test -s conftest$ac_exeext && {
7854          test "$cross_compiling" = yes ||
7855          $as_test_x conftest$ac_exeext
7856        }; then
7857   ac_cv_search_socket=$ac_res
7858 else
7859   $as_echo "$as_me: failed program was:" >&5
7860 sed 's/^/| /' conftest.$ac_ext >&5
7861
7862
7863 fi
7864
7865 rm -rf conftest.dSYM
7866 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7867       conftest$ac_exeext
7868   if test "${ac_cv_search_socket+set}" = set; then
7869   break
7870 fi
7871 done
7872 if test "${ac_cv_search_socket+set}" = set; then
7873   :
7874 else
7875   ac_cv_search_socket=no
7876 fi
7877 rm conftest.$ac_ext
7878 LIBS=$ac_func_search_save_LIBS
7879 fi
7880 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
7881 $as_echo "$ac_cv_search_socket" >&6; }
7882 ac_res=$ac_cv_search_socket
7883 if test "$ac_res" != no; then
7884   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7885
7886 fi
7887
7888 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
7889 $as_echo_n "checking for library containing shl_load... " >&6; }
7890 if test "${ac_cv_search_shl_load+set}" = set; then
7891   $as_echo_n "(cached) " >&6
7892 else
7893   ac_func_search_save_LIBS=$LIBS
7894 cat >conftest.$ac_ext <<_ACEOF
7895 /* confdefs.h.  */
7896 _ACEOF
7897 cat confdefs.h >>conftest.$ac_ext
7898 cat >>conftest.$ac_ext <<_ACEOF
7899 /* end confdefs.h.  */
7900
7901 /* Override any GCC internal prototype to avoid an error.
7902    Use char because int might match the return type of a GCC
7903    builtin and then its argument prototype would still apply.  */
7904 #ifdef __cplusplus
7905 extern "C"
7906 #endif
7907 char shl_load ();
7908 int
7909 main ()
7910 {
7911 return shl_load ();
7912   ;
7913   return 0;
7914 }
7915 _ACEOF
7916 for ac_lib in '' dld; do
7917   if test -z "$ac_lib"; then
7918     ac_res="none required"
7919   else
7920     ac_res=-l$ac_lib
7921     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7922   fi
7923   rm -f conftest.$ac_objext conftest$ac_exeext
7924 if { (ac_try="$ac_link"
7925 case "(($ac_try" in
7926   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7927   *) ac_try_echo=$ac_try;;
7928 esac
7929 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7930 $as_echo "$ac_try_echo") >&5
7931   (eval "$ac_link") 2>conftest.er1
7932   ac_status=$?
7933   grep -v '^ *+' conftest.er1 >conftest.err
7934   rm -f conftest.er1
7935   cat conftest.err >&5
7936   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7937   (exit $ac_status); } && {
7938          test -z "$ac_c_werror_flag" ||
7939          test ! -s conftest.err
7940        } && test -s conftest$ac_exeext && {
7941          test "$cross_compiling" = yes ||
7942          $as_test_x conftest$ac_exeext
7943        }; then
7944   ac_cv_search_shl_load=$ac_res
7945 else
7946   $as_echo "$as_me: failed program was:" >&5
7947 sed 's/^/| /' conftest.$ac_ext >&5
7948
7949
7950 fi
7951
7952 rm -rf conftest.dSYM
7953 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7954       conftest$ac_exeext
7955   if test "${ac_cv_search_shl_load+set}" = set; then
7956   break
7957 fi
7958 done
7959 if test "${ac_cv_search_shl_load+set}" = set; then
7960   :
7961 else
7962   ac_cv_search_shl_load=no
7963 fi
7964 rm conftest.$ac_ext
7965 LIBS=$ac_func_search_save_LIBS
7966 fi
7967 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
7968 $as_echo "$ac_cv_search_shl_load" >&6; }
7969 ac_res=$ac_cv_search_shl_load
7970 if test "$ac_res" != no; then
7971   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7972
7973 fi
7974
7975 # We only use libld in port/dynloader/aix.c
7976 case $host_os in
7977      aix*)
7978         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
7979 $as_echo_n "checking for library containing ldopen... " >&6; }
7980 if test "${ac_cv_search_ldopen+set}" = set; then
7981   $as_echo_n "(cached) " >&6
7982 else
7983   ac_func_search_save_LIBS=$LIBS
7984 cat >conftest.$ac_ext <<_ACEOF
7985 /* confdefs.h.  */
7986 _ACEOF
7987 cat confdefs.h >>conftest.$ac_ext
7988 cat >>conftest.$ac_ext <<_ACEOF
7989 /* end confdefs.h.  */
7990
7991 /* Override any GCC internal prototype to avoid an error.
7992    Use char because int might match the return type of a GCC
7993    builtin and then its argument prototype would still apply.  */
7994 #ifdef __cplusplus
7995 extern "C"
7996 #endif
7997 char ldopen ();
7998 int
7999 main ()
8000 {
8001 return ldopen ();
8002   ;
8003   return 0;
8004 }
8005 _ACEOF
8006 for ac_lib in '' ld; do
8007   if test -z "$ac_lib"; then
8008     ac_res="none required"
8009   else
8010     ac_res=-l$ac_lib
8011     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8012   fi
8013   rm -f conftest.$ac_objext conftest$ac_exeext
8014 if { (ac_try="$ac_link"
8015 case "(($ac_try" in
8016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8017   *) ac_try_echo=$ac_try;;
8018 esac
8019 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8020 $as_echo "$ac_try_echo") >&5
8021   (eval "$ac_link") 2>conftest.er1
8022   ac_status=$?
8023   grep -v '^ *+' conftest.er1 >conftest.err
8024   rm -f conftest.er1
8025   cat conftest.err >&5
8026   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8027   (exit $ac_status); } && {
8028          test -z "$ac_c_werror_flag" ||
8029          test ! -s conftest.err
8030        } && test -s conftest$ac_exeext && {
8031          test "$cross_compiling" = yes ||
8032          $as_test_x conftest$ac_exeext
8033        }; then
8034   ac_cv_search_ldopen=$ac_res
8035 else
8036   $as_echo "$as_me: failed program was:" >&5
8037 sed 's/^/| /' conftest.$ac_ext >&5
8038
8039
8040 fi
8041
8042 rm -rf conftest.dSYM
8043 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8044       conftest$ac_exeext
8045   if test "${ac_cv_search_ldopen+set}" = set; then
8046   break
8047 fi
8048 done
8049 if test "${ac_cv_search_ldopen+set}" = set; then
8050   :
8051 else
8052   ac_cv_search_ldopen=no
8053 fi
8054 rm conftest.$ac_ext
8055 LIBS=$ac_func_search_save_LIBS
8056 fi
8057 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
8058 $as_echo "$ac_cv_search_ldopen" >&6; }
8059 ac_res=$ac_cv_search_ldopen
8060 if test "$ac_res" != no; then
8061   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8062
8063 fi
8064
8065         ;;
8066 esac
8067 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
8068 $as_echo_n "checking for library containing getopt_long... " >&6; }
8069 if test "${ac_cv_search_getopt_long+set}" = set; then
8070   $as_echo_n "(cached) " >&6
8071 else
8072   ac_func_search_save_LIBS=$LIBS
8073 cat >conftest.$ac_ext <<_ACEOF
8074 /* confdefs.h.  */
8075 _ACEOF
8076 cat confdefs.h >>conftest.$ac_ext
8077 cat >>conftest.$ac_ext <<_ACEOF
8078 /* end confdefs.h.  */
8079
8080 /* Override any GCC internal prototype to avoid an error.
8081    Use char because int might match the return type of a GCC
8082    builtin and then its argument prototype would still apply.  */
8083 #ifdef __cplusplus
8084 extern "C"
8085 #endif
8086 char getopt_long ();
8087 int
8088 main ()
8089 {
8090 return getopt_long ();
8091   ;
8092   return 0;
8093 }
8094 _ACEOF
8095 for ac_lib in '' getopt gnugetopt; do
8096   if test -z "$ac_lib"; then
8097     ac_res="none required"
8098   else
8099     ac_res=-l$ac_lib
8100     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8101   fi
8102   rm -f conftest.$ac_objext conftest$ac_exeext
8103 if { (ac_try="$ac_link"
8104 case "(($ac_try" in
8105   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8106   *) ac_try_echo=$ac_try;;
8107 esac
8108 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8109 $as_echo "$ac_try_echo") >&5
8110   (eval "$ac_link") 2>conftest.er1
8111   ac_status=$?
8112   grep -v '^ *+' conftest.er1 >conftest.err
8113   rm -f conftest.er1
8114   cat conftest.err >&5
8115   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8116   (exit $ac_status); } && {
8117          test -z "$ac_c_werror_flag" ||
8118          test ! -s conftest.err
8119        } && test -s conftest$ac_exeext && {
8120          test "$cross_compiling" = yes ||
8121          $as_test_x conftest$ac_exeext
8122        }; then
8123   ac_cv_search_getopt_long=$ac_res
8124 else
8125   $as_echo "$as_me: failed program was:" >&5
8126 sed 's/^/| /' conftest.$ac_ext >&5
8127
8128
8129 fi
8130
8131 rm -rf conftest.dSYM
8132 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8133       conftest$ac_exeext
8134   if test "${ac_cv_search_getopt_long+set}" = set; then
8135   break
8136 fi
8137 done
8138 if test "${ac_cv_search_getopt_long+set}" = set; then
8139   :
8140 else
8141   ac_cv_search_getopt_long=no
8142 fi
8143 rm conftest.$ac_ext
8144 LIBS=$ac_func_search_save_LIBS
8145 fi
8146 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
8147 $as_echo "$ac_cv_search_getopt_long" >&6; }
8148 ac_res=$ac_cv_search_getopt_long
8149 if test "$ac_res" != no; then
8150   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8151
8152 fi
8153
8154 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
8155 $as_echo_n "checking for library containing crypt... " >&6; }
8156 if test "${ac_cv_search_crypt+set}" = set; then
8157   $as_echo_n "(cached) " >&6
8158 else
8159   ac_func_search_save_LIBS=$LIBS
8160 cat >conftest.$ac_ext <<_ACEOF
8161 /* confdefs.h.  */
8162 _ACEOF
8163 cat confdefs.h >>conftest.$ac_ext
8164 cat >>conftest.$ac_ext <<_ACEOF
8165 /* end confdefs.h.  */
8166
8167 /* Override any GCC internal prototype to avoid an error.
8168    Use char because int might match the return type of a GCC
8169    builtin and then its argument prototype would still apply.  */
8170 #ifdef __cplusplus
8171 extern "C"
8172 #endif
8173 char crypt ();
8174 int
8175 main ()
8176 {
8177 return crypt ();
8178   ;
8179   return 0;
8180 }
8181 _ACEOF
8182 for ac_lib in '' crypt; do
8183   if test -z "$ac_lib"; then
8184     ac_res="none required"
8185   else
8186     ac_res=-l$ac_lib
8187     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8188   fi
8189   rm -f conftest.$ac_objext conftest$ac_exeext
8190 if { (ac_try="$ac_link"
8191 case "(($ac_try" in
8192   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8193   *) ac_try_echo=$ac_try;;
8194 esac
8195 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8196 $as_echo "$ac_try_echo") >&5
8197   (eval "$ac_link") 2>conftest.er1
8198   ac_status=$?
8199   grep -v '^ *+' conftest.er1 >conftest.err
8200   rm -f conftest.er1
8201   cat conftest.err >&5
8202   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8203   (exit $ac_status); } && {
8204          test -z "$ac_c_werror_flag" ||
8205          test ! -s conftest.err
8206        } && test -s conftest$ac_exeext && {
8207          test "$cross_compiling" = yes ||
8208          $as_test_x conftest$ac_exeext
8209        }; then
8210   ac_cv_search_crypt=$ac_res
8211 else
8212   $as_echo "$as_me: failed program was:" >&5
8213 sed 's/^/| /' conftest.$ac_ext >&5
8214
8215
8216 fi
8217
8218 rm -rf conftest.dSYM
8219 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8220       conftest$ac_exeext
8221   if test "${ac_cv_search_crypt+set}" = set; then
8222   break
8223 fi
8224 done
8225 if test "${ac_cv_search_crypt+set}" = set; then
8226   :
8227 else
8228   ac_cv_search_crypt=no
8229 fi
8230 rm conftest.$ac_ext
8231 LIBS=$ac_func_search_save_LIBS
8232 fi
8233 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
8234 $as_echo "$ac_cv_search_crypt" >&6; }
8235 ac_res=$ac_cv_search_crypt
8236 if test "$ac_res" != no; then
8237   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8238
8239 fi
8240
8241 # Solaris:
8242 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
8243 $as_echo_n "checking for library containing fdatasync... " >&6; }
8244 if test "${ac_cv_search_fdatasync+set}" = set; then
8245   $as_echo_n "(cached) " >&6
8246 else
8247   ac_func_search_save_LIBS=$LIBS
8248 cat >conftest.$ac_ext <<_ACEOF
8249 /* confdefs.h.  */
8250 _ACEOF
8251 cat confdefs.h >>conftest.$ac_ext
8252 cat >>conftest.$ac_ext <<_ACEOF
8253 /* end confdefs.h.  */
8254
8255 /* Override any GCC internal prototype to avoid an error.
8256    Use char because int might match the return type of a GCC
8257    builtin and then its argument prototype would still apply.  */
8258 #ifdef __cplusplus
8259 extern "C"
8260 #endif
8261 char fdatasync ();
8262 int
8263 main ()
8264 {
8265 return fdatasync ();
8266   ;
8267   return 0;
8268 }
8269 _ACEOF
8270 for ac_lib in '' rt posix4; do
8271   if test -z "$ac_lib"; then
8272     ac_res="none required"
8273   else
8274     ac_res=-l$ac_lib
8275     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8276   fi
8277   rm -f conftest.$ac_objext conftest$ac_exeext
8278 if { (ac_try="$ac_link"
8279 case "(($ac_try" in
8280   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8281   *) ac_try_echo=$ac_try;;
8282 esac
8283 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8284 $as_echo "$ac_try_echo") >&5
8285   (eval "$ac_link") 2>conftest.er1
8286   ac_status=$?
8287   grep -v '^ *+' conftest.er1 >conftest.err
8288   rm -f conftest.er1
8289   cat conftest.err >&5
8290   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8291   (exit $ac_status); } && {
8292          test -z "$ac_c_werror_flag" ||
8293          test ! -s conftest.err
8294        } && test -s conftest$ac_exeext && {
8295          test "$cross_compiling" = yes ||
8296          $as_test_x conftest$ac_exeext
8297        }; then
8298   ac_cv_search_fdatasync=$ac_res
8299 else
8300   $as_echo "$as_me: failed program was:" >&5
8301 sed 's/^/| /' conftest.$ac_ext >&5
8302
8303
8304 fi
8305
8306 rm -rf conftest.dSYM
8307 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8308       conftest$ac_exeext
8309   if test "${ac_cv_search_fdatasync+set}" = set; then
8310   break
8311 fi
8312 done
8313 if test "${ac_cv_search_fdatasync+set}" = set; then
8314   :
8315 else
8316   ac_cv_search_fdatasync=no
8317 fi
8318 rm conftest.$ac_ext
8319 LIBS=$ac_func_search_save_LIBS
8320 fi
8321 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
8322 $as_echo "$ac_cv_search_fdatasync" >&6; }
8323 ac_res=$ac_cv_search_fdatasync
8324 if test "$ac_res" != no; then
8325   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8326
8327 fi
8328
8329 # Required for thread_test.c on Solaris 2.5:
8330 # Other ports use it too (HP-UX) so test unconditionally
8331 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
8332 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
8333 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8334   $as_echo_n "(cached) " >&6
8335 else
8336   ac_func_search_save_LIBS=$LIBS
8337 cat >conftest.$ac_ext <<_ACEOF
8338 /* confdefs.h.  */
8339 _ACEOF
8340 cat confdefs.h >>conftest.$ac_ext
8341 cat >>conftest.$ac_ext <<_ACEOF
8342 /* end confdefs.h.  */
8343
8344 /* Override any GCC internal prototype to avoid an error.
8345    Use char because int might match the return type of a GCC
8346    builtin and then its argument prototype would still apply.  */
8347 #ifdef __cplusplus
8348 extern "C"
8349 #endif
8350 char gethostbyname_r ();
8351 int
8352 main ()
8353 {
8354 return gethostbyname_r ();
8355   ;
8356   return 0;
8357 }
8358 _ACEOF
8359 for ac_lib in '' nsl; do
8360   if test -z "$ac_lib"; then
8361     ac_res="none required"
8362   else
8363     ac_res=-l$ac_lib
8364     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8365   fi
8366   rm -f conftest.$ac_objext conftest$ac_exeext
8367 if { (ac_try="$ac_link"
8368 case "(($ac_try" in
8369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8370   *) ac_try_echo=$ac_try;;
8371 esac
8372 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8373 $as_echo "$ac_try_echo") >&5
8374   (eval "$ac_link") 2>conftest.er1
8375   ac_status=$?
8376   grep -v '^ *+' conftest.er1 >conftest.err
8377   rm -f conftest.er1
8378   cat conftest.err >&5
8379   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8380   (exit $ac_status); } && {
8381          test -z "$ac_c_werror_flag" ||
8382          test ! -s conftest.err
8383        } && test -s conftest$ac_exeext && {
8384          test "$cross_compiling" = yes ||
8385          $as_test_x conftest$ac_exeext
8386        }; then
8387   ac_cv_search_gethostbyname_r=$ac_res
8388 else
8389   $as_echo "$as_me: failed program was:" >&5
8390 sed 's/^/| /' conftest.$ac_ext >&5
8391
8392
8393 fi
8394
8395 rm -rf conftest.dSYM
8396 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8397       conftest$ac_exeext
8398   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8399   break
8400 fi
8401 done
8402 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8403   :
8404 else
8405   ac_cv_search_gethostbyname_r=no
8406 fi
8407 rm conftest.$ac_ext
8408 LIBS=$ac_func_search_save_LIBS
8409 fi
8410 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
8411 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
8412 ac_res=$ac_cv_search_gethostbyname_r
8413 if test "$ac_res" != no; then
8414   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8415
8416 fi
8417
8418 # Cygwin:
8419 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
8420 $as_echo_n "checking for library containing shmget... " >&6; }
8421 if test "${ac_cv_search_shmget+set}" = set; then
8422   $as_echo_n "(cached) " >&6
8423 else
8424   ac_func_search_save_LIBS=$LIBS
8425 cat >conftest.$ac_ext <<_ACEOF
8426 /* confdefs.h.  */
8427 _ACEOF
8428 cat confdefs.h >>conftest.$ac_ext
8429 cat >>conftest.$ac_ext <<_ACEOF
8430 /* end confdefs.h.  */
8431
8432 /* Override any GCC internal prototype to avoid an error.
8433    Use char because int might match the return type of a GCC
8434    builtin and then its argument prototype would still apply.  */
8435 #ifdef __cplusplus
8436 extern "C"
8437 #endif
8438 char shmget ();
8439 int
8440 main ()
8441 {
8442 return shmget ();
8443   ;
8444   return 0;
8445 }
8446 _ACEOF
8447 for ac_lib in '' cygipc; do
8448   if test -z "$ac_lib"; then
8449     ac_res="none required"
8450   else
8451     ac_res=-l$ac_lib
8452     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8453   fi
8454   rm -f conftest.$ac_objext conftest$ac_exeext
8455 if { (ac_try="$ac_link"
8456 case "(($ac_try" in
8457   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8458   *) ac_try_echo=$ac_try;;
8459 esac
8460 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8461 $as_echo "$ac_try_echo") >&5
8462   (eval "$ac_link") 2>conftest.er1
8463   ac_status=$?
8464   grep -v '^ *+' conftest.er1 >conftest.err
8465   rm -f conftest.er1
8466   cat conftest.err >&5
8467   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8468   (exit $ac_status); } && {
8469          test -z "$ac_c_werror_flag" ||
8470          test ! -s conftest.err
8471        } && test -s conftest$ac_exeext && {
8472          test "$cross_compiling" = yes ||
8473          $as_test_x conftest$ac_exeext
8474        }; then
8475   ac_cv_search_shmget=$ac_res
8476 else
8477   $as_echo "$as_me: failed program was:" >&5
8478 sed 's/^/| /' conftest.$ac_ext >&5
8479
8480
8481 fi
8482
8483 rm -rf conftest.dSYM
8484 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8485       conftest$ac_exeext
8486   if test "${ac_cv_search_shmget+set}" = set; then
8487   break
8488 fi
8489 done
8490 if test "${ac_cv_search_shmget+set}" = set; then
8491   :
8492 else
8493   ac_cv_search_shmget=no
8494 fi
8495 rm conftest.$ac_ext
8496 LIBS=$ac_func_search_save_LIBS
8497 fi
8498 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8499 $as_echo "$ac_cv_search_shmget" >&6; }
8500 ac_res=$ac_cv_search_shmget
8501 if test "$ac_res" != no; then
8502   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8503
8504 fi
8505
8506
8507 if test "$with_readline" = yes; then
8508
8509
8510 { $as_echo "$as_me:$LINENO: checking for library containing readline" >&5
8511 $as_echo_n "checking for library containing readline... " >&6; }
8512 if test "${pgac_cv_check_readline+set}" = set; then
8513   $as_echo_n "(cached) " >&6
8514 else
8515   pgac_cv_check_readline=no
8516 pgac_save_LIBS=$LIBS
8517 if test x"$with_libedit_preferred" != x"yes"
8518 then    READLINE_ORDER="-lreadline -ledit"
8519 else    READLINE_ORDER="-ledit -lreadline"
8520 fi
8521 for pgac_rllib in $READLINE_ORDER ; do
8522   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8523     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8524     cat >conftest.$ac_ext <<_ACEOF
8525 /* confdefs.h.  */
8526 _ACEOF
8527 cat confdefs.h >>conftest.$ac_ext
8528 cat >>conftest.$ac_ext <<_ACEOF
8529 /* end confdefs.h.  */
8530
8531 /* Override any GCC internal prototype to avoid an error.
8532    Use char because int might match the return type of a GCC
8533    builtin and then its argument prototype would still apply.  */
8534 #ifdef __cplusplus
8535 extern "C"
8536 #endif
8537 char readline ();
8538 int
8539 main ()
8540 {
8541 return readline ();
8542   ;
8543   return 0;
8544 }
8545 _ACEOF
8546 rm -f conftest.$ac_objext conftest$ac_exeext
8547 if { (ac_try="$ac_link"
8548 case "(($ac_try" in
8549   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8550   *) ac_try_echo=$ac_try;;
8551 esac
8552 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8553 $as_echo "$ac_try_echo") >&5
8554   (eval "$ac_link") 2>conftest.er1
8555   ac_status=$?
8556   grep -v '^ *+' conftest.er1 >conftest.err
8557   rm -f conftest.er1
8558   cat conftest.err >&5
8559   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8560   (exit $ac_status); } && {
8561          test -z "$ac_c_werror_flag" ||
8562          test ! -s conftest.err
8563        } && test -s conftest$ac_exeext && {
8564          test "$cross_compiling" = yes ||
8565          $as_test_x conftest$ac_exeext
8566        }; then
8567
8568       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8569       # recognize dependent libraries; assume curses is needed if we didn't
8570       # find any dependency.
8571       case $host_os in
8572         netbsd* | openbsd* | irix*)
8573           if test x"$pgac_lib" = x"" ; then
8574             pgac_lib=" -lcurses"
8575           fi ;;
8576       esac
8577
8578       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8579       break
8580
8581 else
8582   $as_echo "$as_me: failed program was:" >&5
8583 sed 's/^/| /' conftest.$ac_ext >&5
8584
8585
8586 fi
8587
8588 rm -rf conftest.dSYM
8589 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8590       conftest$ac_exeext conftest.$ac_ext
8591   done
8592   if test "$pgac_cv_check_readline" != no ; then
8593     break
8594   fi
8595 done
8596 LIBS=$pgac_save_LIBS
8597
8598 fi
8599 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_readline" >&5
8600 $as_echo "$pgac_cv_check_readline" >&6; }
8601 if test "$pgac_cv_check_readline" != no ; then
8602   LIBS="$pgac_cv_check_readline $LIBS"
8603
8604 cat >>confdefs.h <<\_ACEOF
8605 #define HAVE_LIBREADLINE 1
8606 _ACEOF
8607
8608 fi
8609
8610
8611   if test x"$pgac_cv_check_readline" = x"no"; then
8612     { { $as_echo "$as_me:$LINENO: error: readline library not found
8613 If you have readline already installed, see config.log for details on the
8614 failure.  It is possible the compiler isn't looking in the proper directory.
8615 Use --without-readline to disable readline support." >&5
8616 $as_echo "$as_me: error: readline library not found
8617 If you have readline already installed, see config.log for details on the
8618 failure.  It is possible the compiler isn't looking in the proper directory.
8619 Use --without-readline to disable readline support." >&2;}
8620    { (exit 1); exit 1; }; }
8621   fi
8622 fi
8623
8624 if test "$with_zlib" = yes; then
8625
8626 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8627 $as_echo_n "checking for inflate in -lz... " >&6; }
8628 if test "${ac_cv_lib_z_inflate+set}" = set; then
8629   $as_echo_n "(cached) " >&6
8630 else
8631   ac_check_lib_save_LIBS=$LIBS
8632 LIBS="-lz  $LIBS"
8633 cat >conftest.$ac_ext <<_ACEOF
8634 /* confdefs.h.  */
8635 _ACEOF
8636 cat confdefs.h >>conftest.$ac_ext
8637 cat >>conftest.$ac_ext <<_ACEOF
8638 /* end confdefs.h.  */
8639
8640 /* Override any GCC internal prototype to avoid an error.
8641    Use char because int might match the return type of a GCC
8642    builtin and then its argument prototype would still apply.  */
8643 #ifdef __cplusplus
8644 extern "C"
8645 #endif
8646 char inflate ();
8647 int
8648 main ()
8649 {
8650 return inflate ();
8651   ;
8652   return 0;
8653 }
8654 _ACEOF
8655 rm -f conftest.$ac_objext conftest$ac_exeext
8656 if { (ac_try="$ac_link"
8657 case "(($ac_try" in
8658   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8659   *) ac_try_echo=$ac_try;;
8660 esac
8661 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8662 $as_echo "$ac_try_echo") >&5
8663   (eval "$ac_link") 2>conftest.er1
8664   ac_status=$?
8665   grep -v '^ *+' conftest.er1 >conftest.err
8666   rm -f conftest.er1
8667   cat conftest.err >&5
8668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8669   (exit $ac_status); } && {
8670          test -z "$ac_c_werror_flag" ||
8671          test ! -s conftest.err
8672        } && test -s conftest$ac_exeext && {
8673          test "$cross_compiling" = yes ||
8674          $as_test_x conftest$ac_exeext
8675        }; then
8676   ac_cv_lib_z_inflate=yes
8677 else
8678   $as_echo "$as_me: failed program was:" >&5
8679 sed 's/^/| /' conftest.$ac_ext >&5
8680
8681         ac_cv_lib_z_inflate=no
8682 fi
8683
8684 rm -rf conftest.dSYM
8685 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8686       conftest$ac_exeext conftest.$ac_ext
8687 LIBS=$ac_check_lib_save_LIBS
8688 fi
8689 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
8690 $as_echo "$ac_cv_lib_z_inflate" >&6; }
8691 if test "x$ac_cv_lib_z_inflate" = x""yes; then
8692   cat >>confdefs.h <<_ACEOF
8693 #define HAVE_LIBZ 1
8694 _ACEOF
8695
8696   LIBS="-lz $LIBS"
8697
8698 else
8699   { { $as_echo "$as_me:$LINENO: error: zlib library not found
8700 If you have zlib already installed, see config.log for details on the
8701 failure.  It is possible the compiler isn't looking in the proper directory.
8702 Use --without-zlib to disable zlib support." >&5
8703 $as_echo "$as_me: error: zlib library not found
8704 If you have zlib already installed, see config.log for details on the
8705 failure.  It is possible the compiler isn't looking in the proper directory.
8706 Use --without-zlib to disable zlib support." >&2;}
8707    { (exit 1); exit 1; }; }
8708 fi
8709
8710 fi
8711
8712 if test "$enable_spinlocks" = yes; then
8713
8714 cat >>confdefs.h <<\_ACEOF
8715 #define HAVE_SPINLOCKS 1
8716 _ACEOF
8717
8718 else
8719   { $as_echo "$as_me:$LINENO: WARNING:
8720 *** Not using spinlocks will cause poor performance." >&5
8721 $as_echo "$as_me: WARNING:
8722 *** Not using spinlocks will cause poor performance." >&2;}
8723 fi
8724
8725 if test "$with_gssapi" = yes ; then
8726   if test "$PORTNAME" != "win32"; then
8727     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
8728 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
8729 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8730   $as_echo_n "(cached) " >&6
8731 else
8732   ac_func_search_save_LIBS=$LIBS
8733 cat >conftest.$ac_ext <<_ACEOF
8734 /* confdefs.h.  */
8735 _ACEOF
8736 cat confdefs.h >>conftest.$ac_ext
8737 cat >>conftest.$ac_ext <<_ACEOF
8738 /* end confdefs.h.  */
8739
8740 /* Override any GCC internal prototype to avoid an error.
8741    Use char because int might match the return type of a GCC
8742    builtin and then its argument prototype would still apply.  */
8743 #ifdef __cplusplus
8744 extern "C"
8745 #endif
8746 char gss_init_sec_context ();
8747 int
8748 main ()
8749 {
8750 return gss_init_sec_context ();
8751   ;
8752   return 0;
8753 }
8754 _ACEOF
8755 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
8756   if test -z "$ac_lib"; then
8757     ac_res="none required"
8758   else
8759     ac_res=-l$ac_lib
8760     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8761   fi
8762   rm -f conftest.$ac_objext conftest$ac_exeext
8763 if { (ac_try="$ac_link"
8764 case "(($ac_try" in
8765   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8766   *) ac_try_echo=$ac_try;;
8767 esac
8768 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8769 $as_echo "$ac_try_echo") >&5
8770   (eval "$ac_link") 2>conftest.er1
8771   ac_status=$?
8772   grep -v '^ *+' conftest.er1 >conftest.err
8773   rm -f conftest.er1
8774   cat conftest.err >&5
8775   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8776   (exit $ac_status); } && {
8777          test -z "$ac_c_werror_flag" ||
8778          test ! -s conftest.err
8779        } && test -s conftest$ac_exeext && {
8780          test "$cross_compiling" = yes ||
8781          $as_test_x conftest$ac_exeext
8782        }; then
8783   ac_cv_search_gss_init_sec_context=$ac_res
8784 else
8785   $as_echo "$as_me: failed program was:" >&5
8786 sed 's/^/| /' conftest.$ac_ext >&5
8787
8788
8789 fi
8790
8791 rm -rf conftest.dSYM
8792 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8793       conftest$ac_exeext
8794   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8795   break
8796 fi
8797 done
8798 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8799   :
8800 else
8801   ac_cv_search_gss_init_sec_context=no
8802 fi
8803 rm conftest.$ac_ext
8804 LIBS=$ac_func_search_save_LIBS
8805 fi
8806 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
8807 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
8808 ac_res=$ac_cv_search_gss_init_sec_context
8809 if test "$ac_res" != no; then
8810   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8811
8812 else
8813   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
8814 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
8815    { (exit 1); exit 1; }; }
8816 fi
8817
8818   else
8819     LIBS="$LIBS -lgssapi32"
8820   fi
8821 fi
8822
8823 if test "$with_krb5" = yes ; then
8824   if test "$PORTNAME" != "win32"; then
8825      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8826 $as_echo_n "checking for library containing com_err... " >&6; }
8827 if test "${ac_cv_search_com_err+set}" = set; then
8828   $as_echo_n "(cached) " >&6
8829 else
8830   ac_func_search_save_LIBS=$LIBS
8831 cat >conftest.$ac_ext <<_ACEOF
8832 /* confdefs.h.  */
8833 _ACEOF
8834 cat confdefs.h >>conftest.$ac_ext
8835 cat >>conftest.$ac_ext <<_ACEOF
8836 /* end confdefs.h.  */
8837
8838 /* Override any GCC internal prototype to avoid an error.
8839    Use char because int might match the return type of a GCC
8840    builtin and then its argument prototype would still apply.  */
8841 #ifdef __cplusplus
8842 extern "C"
8843 #endif
8844 char com_err ();
8845 int
8846 main ()
8847 {
8848 return com_err ();
8849   ;
8850   return 0;
8851 }
8852 _ACEOF
8853 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
8854   if test -z "$ac_lib"; then
8855     ac_res="none required"
8856   else
8857     ac_res=-l$ac_lib
8858     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8859   fi
8860   rm -f conftest.$ac_objext conftest$ac_exeext
8861 if { (ac_try="$ac_link"
8862 case "(($ac_try" in
8863   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8864   *) ac_try_echo=$ac_try;;
8865 esac
8866 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8867 $as_echo "$ac_try_echo") >&5
8868   (eval "$ac_link") 2>conftest.er1
8869   ac_status=$?
8870   grep -v '^ *+' conftest.er1 >conftest.err
8871   rm -f conftest.er1
8872   cat conftest.err >&5
8873   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8874   (exit $ac_status); } && {
8875          test -z "$ac_c_werror_flag" ||
8876          test ! -s conftest.err
8877        } && test -s conftest$ac_exeext && {
8878          test "$cross_compiling" = yes ||
8879          $as_test_x conftest$ac_exeext
8880        }; then
8881   ac_cv_search_com_err=$ac_res
8882 else
8883   $as_echo "$as_me: failed program was:" >&5
8884 sed 's/^/| /' conftest.$ac_ext >&5
8885
8886
8887 fi
8888
8889 rm -rf conftest.dSYM
8890 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8891       conftest$ac_exeext
8892   if test "${ac_cv_search_com_err+set}" = set; then
8893   break
8894 fi
8895 done
8896 if test "${ac_cv_search_com_err+set}" = set; then
8897   :
8898 else
8899   ac_cv_search_com_err=no
8900 fi
8901 rm conftest.$ac_ext
8902 LIBS=$ac_func_search_save_LIBS
8903 fi
8904 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8905 $as_echo "$ac_cv_search_com_err" >&6; }
8906 ac_res=$ac_cv_search_com_err
8907 if test "$ac_res" != no; then
8908   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8909
8910 else
8911   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8912 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8913    { (exit 1); exit 1; }; }
8914 fi
8915
8916      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
8917 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
8918 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8919   $as_echo_n "(cached) " >&6
8920 else
8921   ac_func_search_save_LIBS=$LIBS
8922 cat >conftest.$ac_ext <<_ACEOF
8923 /* confdefs.h.  */
8924 _ACEOF
8925 cat confdefs.h >>conftest.$ac_ext
8926 cat >>conftest.$ac_ext <<_ACEOF
8927 /* end confdefs.h.  */
8928
8929 /* Override any GCC internal prototype to avoid an error.
8930    Use char because int might match the return type of a GCC
8931    builtin and then its argument prototype would still apply.  */
8932 #ifdef __cplusplus
8933 extern "C"
8934 #endif
8935 char krb5_sendauth ();
8936 int
8937 main ()
8938 {
8939 return krb5_sendauth ();
8940   ;
8941   return 0;
8942 }
8943 _ACEOF
8944 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
8945   if test -z "$ac_lib"; then
8946     ac_res="none required"
8947   else
8948     ac_res=-l$ac_lib
8949     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8950   fi
8951   rm -f conftest.$ac_objext conftest$ac_exeext
8952 if { (ac_try="$ac_link"
8953 case "(($ac_try" in
8954   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8955   *) ac_try_echo=$ac_try;;
8956 esac
8957 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8958 $as_echo "$ac_try_echo") >&5
8959   (eval "$ac_link") 2>conftest.er1
8960   ac_status=$?
8961   grep -v '^ *+' conftest.er1 >conftest.err
8962   rm -f conftest.er1
8963   cat conftest.err >&5
8964   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8965   (exit $ac_status); } && {
8966          test -z "$ac_c_werror_flag" ||
8967          test ! -s conftest.err
8968        } && test -s conftest$ac_exeext && {
8969          test "$cross_compiling" = yes ||
8970          $as_test_x conftest$ac_exeext
8971        }; then
8972   ac_cv_search_krb5_sendauth=$ac_res
8973 else
8974   $as_echo "$as_me: failed program was:" >&5
8975 sed 's/^/| /' conftest.$ac_ext >&5
8976
8977
8978 fi
8979
8980 rm -rf conftest.dSYM
8981 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8982       conftest$ac_exeext
8983   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8984   break
8985 fi
8986 done
8987 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8988   :
8989 else
8990   ac_cv_search_krb5_sendauth=no
8991 fi
8992 rm conftest.$ac_ext
8993 LIBS=$ac_func_search_save_LIBS
8994 fi
8995 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
8996 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
8997 ac_res=$ac_cv_search_krb5_sendauth
8998 if test "$ac_res" != no; then
8999   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9000
9001 else
9002   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
9003 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
9004    { (exit 1); exit 1; }; }
9005 fi
9006
9007   else
9008      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
9009 $as_echo_n "checking for library containing com_err... " >&6; }
9010 if test "${ac_cv_search_com_err+set}" = set; then
9011   $as_echo_n "(cached) " >&6
9012 else
9013   ac_func_search_save_LIBS=$LIBS
9014 cat >conftest.$ac_ext <<_ACEOF
9015 /* confdefs.h.  */
9016 _ACEOF
9017 cat confdefs.h >>conftest.$ac_ext
9018 cat >>conftest.$ac_ext <<_ACEOF
9019 /* end confdefs.h.  */
9020
9021 /* Override any GCC internal prototype to avoid an error.
9022    Use char because int might match the return type of a GCC
9023    builtin and then its argument prototype would still apply.  */
9024 #ifdef __cplusplus
9025 extern "C"
9026 #endif
9027 char com_err ();
9028 int
9029 main ()
9030 {
9031 return com_err ();
9032   ;
9033   return 0;
9034 }
9035 _ACEOF
9036 for ac_lib in '' 'comerr32 -lkrb5_32'; do
9037   if test -z "$ac_lib"; then
9038     ac_res="none required"
9039   else
9040     ac_res=-l$ac_lib
9041     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9042   fi
9043   rm -f conftest.$ac_objext conftest$ac_exeext
9044 if { (ac_try="$ac_link"
9045 case "(($ac_try" in
9046   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9047   *) ac_try_echo=$ac_try;;
9048 esac
9049 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9050 $as_echo "$ac_try_echo") >&5
9051   (eval "$ac_link") 2>conftest.er1
9052   ac_status=$?
9053   grep -v '^ *+' conftest.er1 >conftest.err
9054   rm -f conftest.er1
9055   cat conftest.err >&5
9056   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9057   (exit $ac_status); } && {
9058          test -z "$ac_c_werror_flag" ||
9059          test ! -s conftest.err
9060        } && test -s conftest$ac_exeext && {
9061          test "$cross_compiling" = yes ||
9062          $as_test_x conftest$ac_exeext
9063        }; then
9064   ac_cv_search_com_err=$ac_res
9065 else
9066   $as_echo "$as_me: failed program was:" >&5
9067 sed 's/^/| /' conftest.$ac_ext >&5
9068
9069
9070 fi
9071
9072 rm -rf conftest.dSYM
9073 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9074       conftest$ac_exeext
9075   if test "${ac_cv_search_com_err+set}" = set; then
9076   break
9077 fi
9078 done
9079 if test "${ac_cv_search_com_err+set}" = set; then
9080   :
9081 else
9082   ac_cv_search_com_err=no
9083 fi
9084 rm conftest.$ac_ext
9085 LIBS=$ac_func_search_save_LIBS
9086 fi
9087 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
9088 $as_echo "$ac_cv_search_com_err" >&6; }
9089 ac_res=$ac_cv_search_com_err
9090 if test "$ac_res" != no; then
9091   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9092
9093 else
9094   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
9095 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
9096    { (exit 1); exit 1; }; }
9097 fi
9098
9099   fi
9100 fi
9101
9102 if test "$with_openssl" = yes ; then
9103     if test "$PORTNAME" != "win32"; then
9104
9105 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
9106 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
9107 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
9108   $as_echo_n "(cached) " >&6
9109 else
9110   ac_check_lib_save_LIBS=$LIBS
9111 LIBS="-lcrypto  $LIBS"
9112 cat >conftest.$ac_ext <<_ACEOF
9113 /* confdefs.h.  */
9114 _ACEOF
9115 cat confdefs.h >>conftest.$ac_ext
9116 cat >>conftest.$ac_ext <<_ACEOF
9117 /* end confdefs.h.  */
9118
9119 /* Override any GCC internal prototype to avoid an error.
9120    Use char because int might match the return type of a GCC
9121    builtin and then its argument prototype would still apply.  */
9122 #ifdef __cplusplus
9123 extern "C"
9124 #endif
9125 char CRYPTO_new_ex_data ();
9126 int
9127 main ()
9128 {
9129 return CRYPTO_new_ex_data ();
9130   ;
9131   return 0;
9132 }
9133 _ACEOF
9134 rm -f conftest.$ac_objext conftest$ac_exeext
9135 if { (ac_try="$ac_link"
9136 case "(($ac_try" in
9137   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9138   *) ac_try_echo=$ac_try;;
9139 esac
9140 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9141 $as_echo "$ac_try_echo") >&5
9142   (eval "$ac_link") 2>conftest.er1
9143   ac_status=$?
9144   grep -v '^ *+' conftest.er1 >conftest.err
9145   rm -f conftest.er1
9146   cat conftest.err >&5
9147   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9148   (exit $ac_status); } && {
9149          test -z "$ac_c_werror_flag" ||
9150          test ! -s conftest.err
9151        } && test -s conftest$ac_exeext && {
9152          test "$cross_compiling" = yes ||
9153          $as_test_x conftest$ac_exeext
9154        }; then
9155   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
9156 else
9157   $as_echo "$as_me: failed program was:" >&5
9158 sed 's/^/| /' conftest.$ac_ext >&5
9159
9160         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
9161 fi
9162
9163 rm -rf conftest.dSYM
9164 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9165       conftest$ac_exeext conftest.$ac_ext
9166 LIBS=$ac_check_lib_save_LIBS
9167 fi
9168 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
9169 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
9170 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
9171   cat >>confdefs.h <<_ACEOF
9172 #define HAVE_LIBCRYPTO 1
9173 _ACEOF
9174
9175   LIBS="-lcrypto $LIBS"
9176
9177 else
9178   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
9179 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
9180    { (exit 1); exit 1; }; }
9181 fi
9182
9183
9184 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
9185 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
9186 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
9187   $as_echo_n "(cached) " >&6
9188 else
9189   ac_check_lib_save_LIBS=$LIBS
9190 LIBS="-lssl  $LIBS"
9191 cat >conftest.$ac_ext <<_ACEOF
9192 /* confdefs.h.  */
9193 _ACEOF
9194 cat confdefs.h >>conftest.$ac_ext
9195 cat >>conftest.$ac_ext <<_ACEOF
9196 /* end confdefs.h.  */
9197
9198 /* Override any GCC internal prototype to avoid an error.
9199    Use char because int might match the return type of a GCC
9200    builtin and then its argument prototype would still apply.  */
9201 #ifdef __cplusplus
9202 extern "C"
9203 #endif
9204 char SSL_library_init ();
9205 int
9206 main ()
9207 {
9208 return SSL_library_init ();
9209   ;
9210   return 0;
9211 }
9212 _ACEOF
9213 rm -f conftest.$ac_objext conftest$ac_exeext
9214 if { (ac_try="$ac_link"
9215 case "(($ac_try" in
9216   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9217   *) ac_try_echo=$ac_try;;
9218 esac
9219 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9220 $as_echo "$ac_try_echo") >&5
9221   (eval "$ac_link") 2>conftest.er1
9222   ac_status=$?
9223   grep -v '^ *+' conftest.er1 >conftest.err
9224   rm -f conftest.er1
9225   cat conftest.err >&5
9226   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9227   (exit $ac_status); } && {
9228          test -z "$ac_c_werror_flag" ||
9229          test ! -s conftest.err
9230        } && test -s conftest$ac_exeext && {
9231          test "$cross_compiling" = yes ||
9232          $as_test_x conftest$ac_exeext
9233        }; then
9234   ac_cv_lib_ssl_SSL_library_init=yes
9235 else
9236   $as_echo "$as_me: failed program was:" >&5
9237 sed 's/^/| /' conftest.$ac_ext >&5
9238
9239         ac_cv_lib_ssl_SSL_library_init=no
9240 fi
9241
9242 rm -rf conftest.dSYM
9243 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9244       conftest$ac_exeext conftest.$ac_ext
9245 LIBS=$ac_check_lib_save_LIBS
9246 fi
9247 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
9248 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
9249 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
9250   cat >>confdefs.h <<_ACEOF
9251 #define HAVE_LIBSSL 1
9252 _ACEOF
9253
9254   LIBS="-lssl $LIBS"
9255
9256 else
9257   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
9258 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
9259    { (exit 1); exit 1; }; }
9260 fi
9261
9262   else
9263      { $as_echo "$as_me:$LINENO: checking for library containing CRYPTO_new_ex_data" >&5
9264 $as_echo_n "checking for library containing CRYPTO_new_ex_data... " >&6; }
9265 if test "${ac_cv_search_CRYPTO_new_ex_data+set}" = set; then
9266   $as_echo_n "(cached) " >&6
9267 else
9268   ac_func_search_save_LIBS=$LIBS
9269 cat >conftest.$ac_ext <<_ACEOF
9270 /* confdefs.h.  */
9271 _ACEOF
9272 cat confdefs.h >>conftest.$ac_ext
9273 cat >>conftest.$ac_ext <<_ACEOF
9274 /* end confdefs.h.  */
9275
9276 /* Override any GCC internal prototype to avoid an error.
9277    Use char because int might match the return type of a GCC
9278    builtin and then its argument prototype would still apply.  */
9279 #ifdef __cplusplus
9280 extern "C"
9281 #endif
9282 char CRYPTO_new_ex_data ();
9283 int
9284 main ()
9285 {
9286 return CRYPTO_new_ex_data ();
9287   ;
9288   return 0;
9289 }
9290 _ACEOF
9291 for ac_lib in '' eay32 crypto; do
9292   if test -z "$ac_lib"; then
9293     ac_res="none required"
9294   else
9295     ac_res=-l$ac_lib
9296     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9297   fi
9298   rm -f conftest.$ac_objext conftest$ac_exeext
9299 if { (ac_try="$ac_link"
9300 case "(($ac_try" in
9301   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9302   *) ac_try_echo=$ac_try;;
9303 esac
9304 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9305 $as_echo "$ac_try_echo") >&5
9306   (eval "$ac_link") 2>conftest.er1
9307   ac_status=$?
9308   grep -v '^ *+' conftest.er1 >conftest.err
9309   rm -f conftest.er1
9310   cat conftest.err >&5
9311   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9312   (exit $ac_status); } && {
9313          test -z "$ac_c_werror_flag" ||
9314          test ! -s conftest.err
9315        } && test -s conftest$ac_exeext && {
9316          test "$cross_compiling" = yes ||
9317          $as_test_x conftest$ac_exeext
9318        }; then
9319   ac_cv_search_CRYPTO_new_ex_data=$ac_res
9320 else
9321   $as_echo "$as_me: failed program was:" >&5
9322 sed 's/^/| /' conftest.$ac_ext >&5
9323
9324
9325 fi
9326
9327 rm -rf conftest.dSYM
9328 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9329       conftest$ac_exeext
9330   if test "${ac_cv_search_CRYPTO_new_ex_data+set}" = set; then
9331   break
9332 fi
9333 done
9334 if test "${ac_cv_search_CRYPTO_new_ex_data+set}" = set; then
9335   :
9336 else
9337   ac_cv_search_CRYPTO_new_ex_data=no
9338 fi
9339 rm conftest.$ac_ext
9340 LIBS=$ac_func_search_save_LIBS
9341 fi
9342 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_CRYPTO_new_ex_data" >&5
9343 $as_echo "$ac_cv_search_CRYPTO_new_ex_data" >&6; }
9344 ac_res=$ac_cv_search_CRYPTO_new_ex_data
9345 if test "$ac_res" != no; then
9346   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9347
9348 else
9349   { { $as_echo "$as_me:$LINENO: error: library 'eay32' or 'crypto' is required for OpenSSL" >&5
9350 $as_echo "$as_me: error: library 'eay32' or 'crypto' is required for OpenSSL" >&2;}
9351    { (exit 1); exit 1; }; }
9352 fi
9353
9354      { $as_echo "$as_me:$LINENO: checking for library containing SSL_library_init" >&5
9355 $as_echo_n "checking for library containing SSL_library_init... " >&6; }
9356 if test "${ac_cv_search_SSL_library_init+set}" = set; then
9357   $as_echo_n "(cached) " >&6
9358 else
9359   ac_func_search_save_LIBS=$LIBS
9360 cat >conftest.$ac_ext <<_ACEOF
9361 /* confdefs.h.  */
9362 _ACEOF
9363 cat confdefs.h >>conftest.$ac_ext
9364 cat >>conftest.$ac_ext <<_ACEOF
9365 /* end confdefs.h.  */
9366
9367 /* Override any GCC internal prototype to avoid an error.
9368    Use char because int might match the return type of a GCC
9369    builtin and then its argument prototype would still apply.  */
9370 #ifdef __cplusplus
9371 extern "C"
9372 #endif
9373 char SSL_library_init ();
9374 int
9375 main ()
9376 {
9377 return SSL_library_init ();
9378   ;
9379   return 0;
9380 }
9381 _ACEOF
9382 for ac_lib in '' ssleay32 ssl; do
9383   if test -z "$ac_lib"; then
9384     ac_res="none required"
9385   else
9386     ac_res=-l$ac_lib
9387     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9388   fi
9389   rm -f conftest.$ac_objext conftest$ac_exeext
9390 if { (ac_try="$ac_link"
9391 case "(($ac_try" in
9392   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9393   *) ac_try_echo=$ac_try;;
9394 esac
9395 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9396 $as_echo "$ac_try_echo") >&5
9397   (eval "$ac_link") 2>conftest.er1
9398   ac_status=$?
9399   grep -v '^ *+' conftest.er1 >conftest.err
9400   rm -f conftest.er1
9401   cat conftest.err >&5
9402   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9403   (exit $ac_status); } && {
9404          test -z "$ac_c_werror_flag" ||
9405          test ! -s conftest.err
9406        } && test -s conftest$ac_exeext && {
9407          test "$cross_compiling" = yes ||
9408          $as_test_x conftest$ac_exeext
9409        }; then
9410   ac_cv_search_SSL_library_init=$ac_res
9411 else
9412   $as_echo "$as_me: failed program was:" >&5
9413 sed 's/^/| /' conftest.$ac_ext >&5
9414
9415
9416 fi
9417
9418 rm -rf conftest.dSYM
9419 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9420       conftest$ac_exeext
9421   if test "${ac_cv_search_SSL_library_init+set}" = set; then
9422   break
9423 fi
9424 done
9425 if test "${ac_cv_search_SSL_library_init+set}" = set; then
9426   :
9427 else
9428   ac_cv_search_SSL_library_init=no
9429 fi
9430 rm conftest.$ac_ext
9431 LIBS=$ac_func_search_save_LIBS
9432 fi
9433 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_SSL_library_init" >&5
9434 $as_echo "$ac_cv_search_SSL_library_init" >&6; }
9435 ac_res=$ac_cv_search_SSL_library_init
9436 if test "$ac_res" != no; then
9437   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9438
9439 else
9440   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' or 'ssl' is required for OpenSSL" >&5
9441 $as_echo "$as_me: error: library 'ssleay32' or 'ssl' is required for OpenSSL" >&2;}
9442    { (exit 1); exit 1; }; }
9443 fi
9444
9445   fi
9446 fi
9447
9448 if test "$with_pam" = yes ; then
9449
9450 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
9451 $as_echo_n "checking for pam_start in -lpam... " >&6; }
9452 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
9453   $as_echo_n "(cached) " >&6
9454 else
9455   ac_check_lib_save_LIBS=$LIBS
9456 LIBS="-lpam  $LIBS"
9457 cat >conftest.$ac_ext <<_ACEOF
9458 /* confdefs.h.  */
9459 _ACEOF
9460 cat confdefs.h >>conftest.$ac_ext
9461 cat >>conftest.$ac_ext <<_ACEOF
9462 /* end confdefs.h.  */
9463
9464 /* Override any GCC internal prototype to avoid an error.
9465    Use char because int might match the return type of a GCC
9466    builtin and then its argument prototype would still apply.  */
9467 #ifdef __cplusplus
9468 extern "C"
9469 #endif
9470 char pam_start ();
9471 int
9472 main ()
9473 {
9474 return pam_start ();
9475   ;
9476   return 0;
9477 }
9478 _ACEOF
9479 rm -f conftest.$ac_objext conftest$ac_exeext
9480 if { (ac_try="$ac_link"
9481 case "(($ac_try" in
9482   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9483   *) ac_try_echo=$ac_try;;
9484 esac
9485 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9486 $as_echo "$ac_try_echo") >&5
9487   (eval "$ac_link") 2>conftest.er1
9488   ac_status=$?
9489   grep -v '^ *+' conftest.er1 >conftest.err
9490   rm -f conftest.er1
9491   cat conftest.err >&5
9492   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9493   (exit $ac_status); } && {
9494          test -z "$ac_c_werror_flag" ||
9495          test ! -s conftest.err
9496        } && test -s conftest$ac_exeext && {
9497          test "$cross_compiling" = yes ||
9498          $as_test_x conftest$ac_exeext
9499        }; then
9500   ac_cv_lib_pam_pam_start=yes
9501 else
9502   $as_echo "$as_me: failed program was:" >&5
9503 sed 's/^/| /' conftest.$ac_ext >&5
9504
9505         ac_cv_lib_pam_pam_start=no
9506 fi
9507
9508 rm -rf conftest.dSYM
9509 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9510       conftest$ac_exeext conftest.$ac_ext
9511 LIBS=$ac_check_lib_save_LIBS
9512 fi
9513 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9514 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9515 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9516   cat >>confdefs.h <<_ACEOF
9517 #define HAVE_LIBPAM 1
9518 _ACEOF
9519
9520   LIBS="-lpam $LIBS"
9521
9522 else
9523   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9524 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9525    { (exit 1); exit 1; }; }
9526 fi
9527
9528 fi
9529
9530 if test "$with_libxml" = yes ; then
9531
9532 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9533 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9534 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9535   $as_echo_n "(cached) " >&6
9536 else
9537   ac_check_lib_save_LIBS=$LIBS
9538 LIBS="-lxml2  $LIBS"
9539 cat >conftest.$ac_ext <<_ACEOF
9540 /* confdefs.h.  */
9541 _ACEOF
9542 cat confdefs.h >>conftest.$ac_ext
9543 cat >>conftest.$ac_ext <<_ACEOF
9544 /* end confdefs.h.  */
9545
9546 /* Override any GCC internal prototype to avoid an error.
9547    Use char because int might match the return type of a GCC
9548    builtin and then its argument prototype would still apply.  */
9549 #ifdef __cplusplus
9550 extern "C"
9551 #endif
9552 char xmlSaveToBuffer ();
9553 int
9554 main ()
9555 {
9556 return xmlSaveToBuffer ();
9557   ;
9558   return 0;
9559 }
9560 _ACEOF
9561 rm -f conftest.$ac_objext conftest$ac_exeext
9562 if { (ac_try="$ac_link"
9563 case "(($ac_try" in
9564   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9565   *) ac_try_echo=$ac_try;;
9566 esac
9567 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9568 $as_echo "$ac_try_echo") >&5
9569   (eval "$ac_link") 2>conftest.er1
9570   ac_status=$?
9571   grep -v '^ *+' conftest.er1 >conftest.err
9572   rm -f conftest.er1
9573   cat conftest.err >&5
9574   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9575   (exit $ac_status); } && {
9576          test -z "$ac_c_werror_flag" ||
9577          test ! -s conftest.err
9578        } && test -s conftest$ac_exeext && {
9579          test "$cross_compiling" = yes ||
9580          $as_test_x conftest$ac_exeext
9581        }; then
9582   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9583 else
9584   $as_echo "$as_me: failed program was:" >&5
9585 sed 's/^/| /' conftest.$ac_ext >&5
9586
9587         ac_cv_lib_xml2_xmlSaveToBuffer=no
9588 fi
9589
9590 rm -rf conftest.dSYM
9591 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9592       conftest$ac_exeext conftest.$ac_ext
9593 LIBS=$ac_check_lib_save_LIBS
9594 fi
9595 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9596 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9597 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9598   cat >>confdefs.h <<_ACEOF
9599 #define HAVE_LIBXML2 1
9600 _ACEOF
9601
9602   LIBS="-lxml2 $LIBS"
9603
9604 else
9605   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9606 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9607    { (exit 1); exit 1; }; }
9608 fi
9609
9610 fi
9611
9612 if test "$with_libxslt" = yes ; then
9613
9614 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9615 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9616 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9617   $as_echo_n "(cached) " >&6
9618 else
9619   ac_check_lib_save_LIBS=$LIBS
9620 LIBS="-lxslt  $LIBS"
9621 cat >conftest.$ac_ext <<_ACEOF
9622 /* confdefs.h.  */
9623 _ACEOF
9624 cat confdefs.h >>conftest.$ac_ext
9625 cat >>conftest.$ac_ext <<_ACEOF
9626 /* end confdefs.h.  */
9627
9628 /* Override any GCC internal prototype to avoid an error.
9629    Use char because int might match the return type of a GCC
9630    builtin and then its argument prototype would still apply.  */
9631 #ifdef __cplusplus
9632 extern "C"
9633 #endif
9634 char xsltCleanupGlobals ();
9635 int
9636 main ()
9637 {
9638 return xsltCleanupGlobals ();
9639   ;
9640   return 0;
9641 }
9642 _ACEOF
9643 rm -f conftest.$ac_objext conftest$ac_exeext
9644 if { (ac_try="$ac_link"
9645 case "(($ac_try" in
9646   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9647   *) ac_try_echo=$ac_try;;
9648 esac
9649 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9650 $as_echo "$ac_try_echo") >&5
9651   (eval "$ac_link") 2>conftest.er1
9652   ac_status=$?
9653   grep -v '^ *+' conftest.er1 >conftest.err
9654   rm -f conftest.er1
9655   cat conftest.err >&5
9656   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9657   (exit $ac_status); } && {
9658          test -z "$ac_c_werror_flag" ||
9659          test ! -s conftest.err
9660        } && test -s conftest$ac_exeext && {
9661          test "$cross_compiling" = yes ||
9662          $as_test_x conftest$ac_exeext
9663        }; then
9664   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9665 else
9666   $as_echo "$as_me: failed program was:" >&5
9667 sed 's/^/| /' conftest.$ac_ext >&5
9668
9669         ac_cv_lib_xslt_xsltCleanupGlobals=no
9670 fi
9671
9672 rm -rf conftest.dSYM
9673 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9674       conftest$ac_exeext conftest.$ac_ext
9675 LIBS=$ac_check_lib_save_LIBS
9676 fi
9677 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9678 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9679 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9680   cat >>confdefs.h <<_ACEOF
9681 #define HAVE_LIBXSLT 1
9682 _ACEOF
9683
9684   LIBS="-lxslt $LIBS"
9685
9686 else
9687   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
9688 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
9689    { (exit 1); exit 1; }; }
9690 fi
9691
9692 fi
9693
9694 # for contrib/sepgsql
9695 if test "$with_selinux" = yes; then
9696
9697 { $as_echo "$as_me:$LINENO: checking for selinux_status_open in -lselinux" >&5
9698 $as_echo_n "checking for selinux_status_open in -lselinux... " >&6; }
9699 if test "${ac_cv_lib_selinux_selinux_status_open+set}" = set; then
9700   $as_echo_n "(cached) " >&6
9701 else
9702   ac_check_lib_save_LIBS=$LIBS
9703 LIBS="-lselinux  $LIBS"
9704 cat >conftest.$ac_ext <<_ACEOF
9705 /* confdefs.h.  */
9706 _ACEOF
9707 cat confdefs.h >>conftest.$ac_ext
9708 cat >>conftest.$ac_ext <<_ACEOF
9709 /* end confdefs.h.  */
9710
9711 /* Override any GCC internal prototype to avoid an error.
9712    Use char because int might match the return type of a GCC
9713    builtin and then its argument prototype would still apply.  */
9714 #ifdef __cplusplus
9715 extern "C"
9716 #endif
9717 char selinux_status_open ();
9718 int
9719 main ()
9720 {
9721 return selinux_status_open ();
9722   ;
9723   return 0;
9724 }
9725 _ACEOF
9726 rm -f conftest.$ac_objext conftest$ac_exeext
9727 if { (ac_try="$ac_link"
9728 case "(($ac_try" in
9729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9730   *) ac_try_echo=$ac_try;;
9731 esac
9732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9733 $as_echo "$ac_try_echo") >&5
9734   (eval "$ac_link") 2>conftest.er1
9735   ac_status=$?
9736   grep -v '^ *+' conftest.er1 >conftest.err
9737   rm -f conftest.er1
9738   cat conftest.err >&5
9739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9740   (exit $ac_status); } && {
9741          test -z "$ac_c_werror_flag" ||
9742          test ! -s conftest.err
9743        } && test -s conftest$ac_exeext && {
9744          test "$cross_compiling" = yes ||
9745          $as_test_x conftest$ac_exeext
9746        }; then
9747   ac_cv_lib_selinux_selinux_status_open=yes
9748 else
9749   $as_echo "$as_me: failed program was:" >&5
9750 sed 's/^/| /' conftest.$ac_ext >&5
9751
9752         ac_cv_lib_selinux_selinux_status_open=no
9753 fi
9754
9755 rm -rf conftest.dSYM
9756 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9757       conftest$ac_exeext conftest.$ac_ext
9758 LIBS=$ac_check_lib_save_LIBS
9759 fi
9760 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_selinux_status_open" >&5
9761 $as_echo "$ac_cv_lib_selinux_selinux_status_open" >&6; }
9762 if test "x$ac_cv_lib_selinux_selinux_status_open" = x""yes; then
9763   cat >>confdefs.h <<_ACEOF
9764 #define HAVE_LIBSELINUX 1
9765 _ACEOF
9766
9767   LIBS="-lselinux $LIBS"
9768
9769 else
9770   { { $as_echo "$as_me:$LINENO: error: library 'libselinux', version 2.0.99 or newer, is required for SELinux support" >&5
9771 $as_echo "$as_me: error: library 'libselinux', version 2.0.99 or newer, is required for SELinux support" >&2;}
9772    { (exit 1); exit 1; }; }
9773 fi
9774
9775 fi
9776
9777 # for contrib/uuid-ossp
9778 if test "$with_ossp_uuid" = yes ; then
9779   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
9780 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
9781 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
9782   $as_echo_n "(cached) " >&6
9783 else
9784   ac_check_lib_save_LIBS=$LIBS
9785 LIBS="-lossp-uuid  $LIBS"
9786 cat >conftest.$ac_ext <<_ACEOF
9787 /* confdefs.h.  */
9788 _ACEOF
9789 cat confdefs.h >>conftest.$ac_ext
9790 cat >>conftest.$ac_ext <<_ACEOF
9791 /* end confdefs.h.  */
9792
9793 /* Override any GCC internal prototype to avoid an error.
9794    Use char because int might match the return type of a GCC
9795    builtin and then its argument prototype would still apply.  */
9796 #ifdef __cplusplus
9797 extern "C"
9798 #endif
9799 char uuid_export ();
9800 int
9801 main ()
9802 {
9803 return uuid_export ();
9804   ;
9805   return 0;
9806 }
9807 _ACEOF
9808 rm -f conftest.$ac_objext conftest$ac_exeext
9809 if { (ac_try="$ac_link"
9810 case "(($ac_try" in
9811   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9812   *) ac_try_echo=$ac_try;;
9813 esac
9814 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9815 $as_echo "$ac_try_echo") >&5
9816   (eval "$ac_link") 2>conftest.er1
9817   ac_status=$?
9818   grep -v '^ *+' conftest.er1 >conftest.err
9819   rm -f conftest.er1
9820   cat conftest.err >&5
9821   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9822   (exit $ac_status); } && {
9823          test -z "$ac_c_werror_flag" ||
9824          test ! -s conftest.err
9825        } && test -s conftest$ac_exeext && {
9826          test "$cross_compiling" = yes ||
9827          $as_test_x conftest$ac_exeext
9828        }; then
9829   ac_cv_lib_ossp_uuid_uuid_export=yes
9830 else
9831   $as_echo "$as_me: failed program was:" >&5
9832 sed 's/^/| /' conftest.$ac_ext >&5
9833
9834         ac_cv_lib_ossp_uuid_uuid_export=no
9835 fi
9836
9837 rm -rf conftest.dSYM
9838 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9839       conftest$ac_exeext conftest.$ac_ext
9840 LIBS=$ac_check_lib_save_LIBS
9841 fi
9842 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
9843 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
9844 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
9845   OSSP_UUID_LIBS="-lossp-uuid"
9846 else
9847   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
9848 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
9849 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
9850   $as_echo_n "(cached) " >&6
9851 else
9852   ac_check_lib_save_LIBS=$LIBS
9853 LIBS="-luuid  $LIBS"
9854 cat >conftest.$ac_ext <<_ACEOF
9855 /* confdefs.h.  */
9856 _ACEOF
9857 cat confdefs.h >>conftest.$ac_ext
9858 cat >>conftest.$ac_ext <<_ACEOF
9859 /* end confdefs.h.  */
9860
9861 /* Override any GCC internal prototype to avoid an error.
9862    Use char because int might match the return type of a GCC
9863    builtin and then its argument prototype would still apply.  */
9864 #ifdef __cplusplus
9865 extern "C"
9866 #endif
9867 char uuid_export ();
9868 int
9869 main ()
9870 {
9871 return uuid_export ();
9872   ;
9873   return 0;
9874 }
9875 _ACEOF
9876 rm -f conftest.$ac_objext conftest$ac_exeext
9877 if { (ac_try="$ac_link"
9878 case "(($ac_try" in
9879   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9880   *) ac_try_echo=$ac_try;;
9881 esac
9882 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9883 $as_echo "$ac_try_echo") >&5
9884   (eval "$ac_link") 2>conftest.er1
9885   ac_status=$?
9886   grep -v '^ *+' conftest.er1 >conftest.err
9887   rm -f conftest.er1
9888   cat conftest.err >&5
9889   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9890   (exit $ac_status); } && {
9891          test -z "$ac_c_werror_flag" ||
9892          test ! -s conftest.err
9893        } && test -s conftest$ac_exeext && {
9894          test "$cross_compiling" = yes ||
9895          $as_test_x conftest$ac_exeext
9896        }; then
9897   ac_cv_lib_uuid_uuid_export=yes
9898 else
9899   $as_echo "$as_me: failed program was:" >&5
9900 sed 's/^/| /' conftest.$ac_ext >&5
9901
9902         ac_cv_lib_uuid_uuid_export=no
9903 fi
9904
9905 rm -rf conftest.dSYM
9906 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9907       conftest$ac_exeext conftest.$ac_ext
9908 LIBS=$ac_check_lib_save_LIBS
9909 fi
9910 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
9911 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
9912 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
9913   OSSP_UUID_LIBS="-luuid"
9914 else
9915   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
9916 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
9917    { (exit 1); exit 1; }; }
9918 fi
9919
9920 fi
9921
9922 fi
9923
9924
9925
9926 ##
9927 ## Header files
9928 ##
9929
9930 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
9931 $as_echo_n "checking for ANSI C header files... " >&6; }
9932 if test "${ac_cv_header_stdc+set}" = set; then
9933   $as_echo_n "(cached) " >&6
9934 else
9935   cat >conftest.$ac_ext <<_ACEOF
9936 /* confdefs.h.  */
9937 _ACEOF
9938 cat confdefs.h >>conftest.$ac_ext
9939 cat >>conftest.$ac_ext <<_ACEOF
9940 /* end confdefs.h.  */
9941 #include <stdlib.h>
9942 #include <stdarg.h>
9943 #include <string.h>
9944 #include <float.h>
9945
9946 int
9947 main ()
9948 {
9949
9950   ;
9951   return 0;
9952 }
9953 _ACEOF
9954 rm -f conftest.$ac_objext
9955 if { (ac_try="$ac_compile"
9956 case "(($ac_try" in
9957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9958   *) ac_try_echo=$ac_try;;
9959 esac
9960 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9961 $as_echo "$ac_try_echo") >&5
9962   (eval "$ac_compile") 2>conftest.er1
9963   ac_status=$?
9964   grep -v '^ *+' conftest.er1 >conftest.err
9965   rm -f conftest.er1
9966   cat conftest.err >&5
9967   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9968   (exit $ac_status); } && {
9969          test -z "$ac_c_werror_flag" ||
9970          test ! -s conftest.err
9971        } && test -s conftest.$ac_objext; then
9972   ac_cv_header_stdc=yes
9973 else
9974   $as_echo "$as_me: failed program was:" >&5
9975 sed 's/^/| /' conftest.$ac_ext >&5
9976
9977         ac_cv_header_stdc=no
9978 fi
9979
9980 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9981
9982 if test $ac_cv_header_stdc = yes; then
9983   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9984   cat >conftest.$ac_ext <<_ACEOF
9985 /* confdefs.h.  */
9986 _ACEOF
9987 cat confdefs.h >>conftest.$ac_ext
9988 cat >>conftest.$ac_ext <<_ACEOF
9989 /* end confdefs.h.  */
9990 #include <string.h>
9991
9992 _ACEOF
9993 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9994   $EGREP "memchr" >/dev/null 2>&1; then
9995   :
9996 else
9997   ac_cv_header_stdc=no
9998 fi
9999 rm -f conftest*
10000
10001 fi
10002
10003 if test $ac_cv_header_stdc = yes; then
10004   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10005   cat >conftest.$ac_ext <<_ACEOF
10006 /* confdefs.h.  */
10007 _ACEOF
10008 cat confdefs.h >>conftest.$ac_ext
10009 cat >>conftest.$ac_ext <<_ACEOF
10010 /* end confdefs.h.  */
10011 #include <stdlib.h>
10012
10013 _ACEOF
10014 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10015   $EGREP "free" >/dev/null 2>&1; then
10016   :
10017 else
10018   ac_cv_header_stdc=no
10019 fi
10020 rm -f conftest*
10021
10022 fi
10023
10024 if test $ac_cv_header_stdc = yes; then
10025   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10026   if test "$cross_compiling" = yes; then
10027   :
10028 else
10029   cat >conftest.$ac_ext <<_ACEOF
10030 /* confdefs.h.  */
10031 _ACEOF
10032 cat confdefs.h >>conftest.$ac_ext
10033 cat >>conftest.$ac_ext <<_ACEOF
10034 /* end confdefs.h.  */
10035 #include <ctype.h>
10036 #include <stdlib.h>
10037 #if ((' ' & 0x0FF) == 0x020)
10038 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10039 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10040 #else
10041 # define ISLOWER(c) \
10042                    (('a' <= (c) && (c) <= 'i') \
10043                      || ('j' <= (c) && (c) <= 'r') \
10044                      || ('s' <= (c) && (c) <= 'z'))
10045 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10046 #endif
10047
10048 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10049 int
10050 main ()
10051 {
10052   int i;
10053   for (i = 0; i < 256; i++)
10054     if (XOR (islower (i), ISLOWER (i))
10055         || toupper (i) != TOUPPER (i))
10056       return 2;
10057   return 0;
10058 }
10059 _ACEOF
10060 rm -f conftest$ac_exeext
10061 if { (ac_try="$ac_link"
10062 case "(($ac_try" in
10063   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10064   *) ac_try_echo=$ac_try;;
10065 esac
10066 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10067 $as_echo "$ac_try_echo") >&5
10068   (eval "$ac_link") 2>&5
10069   ac_status=$?
10070   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10071   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10072   { (case "(($ac_try" in
10073   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10074   *) ac_try_echo=$ac_try;;
10075 esac
10076 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10077 $as_echo "$ac_try_echo") >&5
10078   (eval "$ac_try") 2>&5
10079   ac_status=$?
10080   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10081   (exit $ac_status); }; }; then
10082   :
10083 else
10084   $as_echo "$as_me: program exited with status $ac_status" >&5
10085 $as_echo "$as_me: failed program was:" >&5
10086 sed 's/^/| /' conftest.$ac_ext >&5
10087
10088 ( exit $ac_status )
10089 ac_cv_header_stdc=no
10090 fi
10091 rm -rf conftest.dSYM
10092 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10093 fi
10094
10095
10096 fi
10097 fi
10098 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
10099 $as_echo "$ac_cv_header_stdc" >&6; }
10100 if test $ac_cv_header_stdc = yes; then
10101
10102 cat >>confdefs.h <<\_ACEOF
10103 #define STDC_HEADERS 1
10104 _ACEOF
10105
10106 fi
10107
10108 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
10109
10110
10111
10112
10113
10114
10115
10116
10117
10118 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10119                   inttypes.h stdint.h unistd.h
10120 do
10121 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10122 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10123 $as_echo_n "checking for $ac_header... " >&6; }
10124 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10125   $as_echo_n "(cached) " >&6
10126 else
10127   cat >conftest.$ac_ext <<_ACEOF
10128 /* confdefs.h.  */
10129 _ACEOF
10130 cat confdefs.h >>conftest.$ac_ext
10131 cat >>conftest.$ac_ext <<_ACEOF
10132 /* end confdefs.h.  */
10133 $ac_includes_default
10134
10135 #include <$ac_header>
10136 _ACEOF
10137 rm -f conftest.$ac_objext
10138 if { (ac_try="$ac_compile"
10139 case "(($ac_try" in
10140   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10141   *) ac_try_echo=$ac_try;;
10142 esac
10143 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10144 $as_echo "$ac_try_echo") >&5
10145   (eval "$ac_compile") 2>conftest.er1
10146   ac_status=$?
10147   grep -v '^ *+' conftest.er1 >conftest.err
10148   rm -f conftest.er1
10149   cat conftest.err >&5
10150   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10151   (exit $ac_status); } && {
10152          test -z "$ac_c_werror_flag" ||
10153          test ! -s conftest.err
10154        } && test -s conftest.$ac_objext; then
10155   eval "$as_ac_Header=yes"
10156 else
10157   $as_echo "$as_me: failed program was:" >&5
10158 sed 's/^/| /' conftest.$ac_ext >&5
10159
10160         eval "$as_ac_Header=no"
10161 fi
10162
10163 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10164 fi
10165 ac_res=`eval 'as_val=${'$as_ac_Header'}
10166                  $as_echo "$as_val"'`
10167                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10168 $as_echo "$ac_res" >&6; }
10169 as_val=`eval 'as_val=${'$as_ac_Header'}
10170                  $as_echo "$as_val"'`
10171    if test "x$as_val" = x""yes; then
10172   cat >>confdefs.h <<_ACEOF
10173 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10174 _ACEOF
10175
10176 fi
10177
10178 done
10179
10180
10181
10182
10183
10184
10185
10186
10187
10188
10189
10190
10191
10192
10193
10194
10195
10196
10197
10198
10199
10200
10201
10202
10203
10204
10205
10206
10207
10208
10209 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/ucred.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h
10210 do
10211 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10212 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10213   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10214 $as_echo_n "checking for $ac_header... " >&6; }
10215 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10216   $as_echo_n "(cached) " >&6
10217 fi
10218 ac_res=`eval 'as_val=${'$as_ac_Header'}
10219                  $as_echo "$as_val"'`
10220                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10221 $as_echo "$ac_res" >&6; }
10222 else
10223   # Is the header compilable?
10224 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10225 $as_echo_n "checking $ac_header usability... " >&6; }
10226 cat >conftest.$ac_ext <<_ACEOF
10227 /* confdefs.h.  */
10228 _ACEOF
10229 cat confdefs.h >>conftest.$ac_ext
10230 cat >>conftest.$ac_ext <<_ACEOF
10231 /* end confdefs.h.  */
10232 $ac_includes_default
10233 #include <$ac_header>
10234 _ACEOF
10235 rm -f conftest.$ac_objext
10236 if { (ac_try="$ac_compile"
10237 case "(($ac_try" in
10238   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10239   *) ac_try_echo=$ac_try;;
10240 esac
10241 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10242 $as_echo "$ac_try_echo") >&5
10243   (eval "$ac_compile") 2>conftest.er1
10244   ac_status=$?
10245   grep -v '^ *+' conftest.er1 >conftest.err
10246   rm -f conftest.er1
10247   cat conftest.err >&5
10248   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10249   (exit $ac_status); } && {
10250          test -z "$ac_c_werror_flag" ||
10251          test ! -s conftest.err
10252        } && test -s conftest.$ac_objext; then
10253   ac_header_compiler=yes
10254 else
10255   $as_echo "$as_me: failed program was:" >&5
10256 sed 's/^/| /' conftest.$ac_ext >&5
10257
10258         ac_header_compiler=no
10259 fi
10260
10261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10262 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10263 $as_echo "$ac_header_compiler" >&6; }
10264
10265 # Is the header present?
10266 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10267 $as_echo_n "checking $ac_header presence... " >&6; }
10268 cat >conftest.$ac_ext <<_ACEOF
10269 /* confdefs.h.  */
10270 _ACEOF
10271 cat confdefs.h >>conftest.$ac_ext
10272 cat >>conftest.$ac_ext <<_ACEOF
10273 /* end confdefs.h.  */
10274 #include <$ac_header>
10275 _ACEOF
10276 if { (ac_try="$ac_cpp conftest.$ac_ext"
10277 case "(($ac_try" in
10278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10279   *) ac_try_echo=$ac_try;;
10280 esac
10281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10282 $as_echo "$ac_try_echo") >&5
10283   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10284   ac_status=$?
10285   grep -v '^ *+' conftest.er1 >conftest.err
10286   rm -f conftest.er1
10287   cat conftest.err >&5
10288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10289   (exit $ac_status); } >/dev/null && {
10290          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10291          test ! -s conftest.err
10292        }; then
10293   ac_header_preproc=yes
10294 else
10295   $as_echo "$as_me: failed program was:" >&5
10296 sed 's/^/| /' conftest.$ac_ext >&5
10297
10298   ac_header_preproc=no
10299 fi
10300
10301 rm -f conftest.err conftest.$ac_ext
10302 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10303 $as_echo "$ac_header_preproc" >&6; }
10304
10305 # So?  What about this header?
10306 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10307   yes:no: )
10308     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10309 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10310     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10311 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10312     ac_header_preproc=yes
10313     ;;
10314   no:yes:* )
10315     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10316 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10317     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10318 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10319     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10320 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10321     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10322 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10323     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10324 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10325     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10326 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10327     ( cat <<\_ASBOX
10328 ## ---------------------------------------- ##
10329 ## Report this to pgsql-bugs@postgresql.org ##
10330 ## ---------------------------------------- ##
10331 _ASBOX
10332      ) | sed "s/^/$as_me: WARNING:     /" >&2
10333     ;;
10334 esac
10335 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10336 $as_echo_n "checking for $ac_header... " >&6; }
10337 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10338   $as_echo_n "(cached) " >&6
10339 else
10340   eval "$as_ac_Header=\$ac_header_preproc"
10341 fi
10342 ac_res=`eval 'as_val=${'$as_ac_Header'}
10343                  $as_echo "$as_val"'`
10344                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10345 $as_echo "$ac_res" >&6; }
10346
10347 fi
10348 as_val=`eval 'as_val=${'$as_ac_Header'}
10349                  $as_echo "$as_val"'`
10350    if test "x$as_val" = x""yes; then
10351   cat >>confdefs.h <<_ACEOF
10352 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10353 _ACEOF
10354
10355 fi
10356
10357 done
10358
10359
10360 # On BSD, cpp test for net/if.h will fail unless sys/socket.h
10361 # is included first.
10362
10363 for ac_header in net/if.h
10364 do
10365 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10366 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10367 $as_echo_n "checking for $ac_header... " >&6; }
10368 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10369   $as_echo_n "(cached) " >&6
10370 else
10371   cat >conftest.$ac_ext <<_ACEOF
10372 /* confdefs.h.  */
10373 _ACEOF
10374 cat confdefs.h >>conftest.$ac_ext
10375 cat >>conftest.$ac_ext <<_ACEOF
10376 /* end confdefs.h.  */
10377 $ac_includes_default
10378 #ifdef HAVE_SYS_SOCKET_H
10379 #include <sys/socket.h>
10380 #endif
10381
10382
10383 #include <$ac_header>
10384 _ACEOF
10385 rm -f conftest.$ac_objext
10386 if { (ac_try="$ac_compile"
10387 case "(($ac_try" in
10388   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10389   *) ac_try_echo=$ac_try;;
10390 esac
10391 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10392 $as_echo "$ac_try_echo") >&5
10393   (eval "$ac_compile") 2>conftest.er1
10394   ac_status=$?
10395   grep -v '^ *+' conftest.er1 >conftest.err
10396   rm -f conftest.er1
10397   cat conftest.err >&5
10398   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10399   (exit $ac_status); } && {
10400          test -z "$ac_c_werror_flag" ||
10401          test ! -s conftest.err
10402        } && test -s conftest.$ac_objext; then
10403   eval "$as_ac_Header=yes"
10404 else
10405   $as_echo "$as_me: failed program was:" >&5
10406 sed 's/^/| /' conftest.$ac_ext >&5
10407
10408         eval "$as_ac_Header=no"
10409 fi
10410
10411 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10412 fi
10413 ac_res=`eval 'as_val=${'$as_ac_Header'}
10414                  $as_echo "$as_val"'`
10415                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10416 $as_echo "$ac_res" >&6; }
10417 as_val=`eval 'as_val=${'$as_ac_Header'}
10418                  $as_echo "$as_val"'`
10419    if test "x$as_val" = x""yes; then
10420   cat >>confdefs.h <<_ACEOF
10421 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10422 _ACEOF
10423
10424 fi
10425
10426 done
10427
10428
10429 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
10430 # netinet/in.h is included first.
10431
10432 for ac_header in netinet/in.h
10433 do
10434 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10435 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10436   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10437 $as_echo_n "checking for $ac_header... " >&6; }
10438 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10439   $as_echo_n "(cached) " >&6
10440 fi
10441 ac_res=`eval 'as_val=${'$as_ac_Header'}
10442                  $as_echo "$as_val"'`
10443                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10444 $as_echo "$ac_res" >&6; }
10445 else
10446   # Is the header compilable?
10447 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10448 $as_echo_n "checking $ac_header usability... " >&6; }
10449 cat >conftest.$ac_ext <<_ACEOF
10450 /* confdefs.h.  */
10451 _ACEOF
10452 cat confdefs.h >>conftest.$ac_ext
10453 cat >>conftest.$ac_ext <<_ACEOF
10454 /* end confdefs.h.  */
10455 $ac_includes_default
10456 #include <$ac_header>
10457 _ACEOF
10458 rm -f conftest.$ac_objext
10459 if { (ac_try="$ac_compile"
10460 case "(($ac_try" in
10461   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10462   *) ac_try_echo=$ac_try;;
10463 esac
10464 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10465 $as_echo "$ac_try_echo") >&5
10466   (eval "$ac_compile") 2>conftest.er1
10467   ac_status=$?
10468   grep -v '^ *+' conftest.er1 >conftest.err
10469   rm -f conftest.er1
10470   cat conftest.err >&5
10471   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10472   (exit $ac_status); } && {
10473          test -z "$ac_c_werror_flag" ||
10474          test ! -s conftest.err
10475        } && test -s conftest.$ac_objext; then
10476   ac_header_compiler=yes
10477 else
10478   $as_echo "$as_me: failed program was:" >&5
10479 sed 's/^/| /' conftest.$ac_ext >&5
10480
10481         ac_header_compiler=no
10482 fi
10483
10484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10485 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10486 $as_echo "$ac_header_compiler" >&6; }
10487
10488 # Is the header present?
10489 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10490 $as_echo_n "checking $ac_header presence... " >&6; }
10491 cat >conftest.$ac_ext <<_ACEOF
10492 /* confdefs.h.  */
10493 _ACEOF
10494 cat confdefs.h >>conftest.$ac_ext
10495 cat >>conftest.$ac_ext <<_ACEOF
10496 /* end confdefs.h.  */
10497 #include <$ac_header>
10498 _ACEOF
10499 if { (ac_try="$ac_cpp conftest.$ac_ext"
10500 case "(($ac_try" in
10501   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10502   *) ac_try_echo=$ac_try;;
10503 esac
10504 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10505 $as_echo "$ac_try_echo") >&5
10506   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10507   ac_status=$?
10508   grep -v '^ *+' conftest.er1 >conftest.err
10509   rm -f conftest.er1
10510   cat conftest.err >&5
10511   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10512   (exit $ac_status); } >/dev/null && {
10513          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10514          test ! -s conftest.err
10515        }; then
10516   ac_header_preproc=yes
10517 else
10518   $as_echo "$as_me: failed program was:" >&5
10519 sed 's/^/| /' conftest.$ac_ext >&5
10520
10521   ac_header_preproc=no
10522 fi
10523
10524 rm -f conftest.err conftest.$ac_ext
10525 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10526 $as_echo "$ac_header_preproc" >&6; }
10527
10528 # So?  What about this header?
10529 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10530   yes:no: )
10531     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10532 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10533     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10534 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10535     ac_header_preproc=yes
10536     ;;
10537   no:yes:* )
10538     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10539 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10540     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10541 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10542     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10543 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10544     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10545 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10546     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10547 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10548     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10549 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10550     ( cat <<\_ASBOX
10551 ## ---------------------------------------- ##
10552 ## Report this to pgsql-bugs@postgresql.org ##
10553 ## ---------------------------------------- ##
10554 _ASBOX
10555      ) | sed "s/^/$as_me: WARNING:     /" >&2
10556     ;;
10557 esac
10558 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10559 $as_echo_n "checking for $ac_header... " >&6; }
10560 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10561   $as_echo_n "(cached) " >&6
10562 else
10563   eval "$as_ac_Header=\$ac_header_preproc"
10564 fi
10565 ac_res=`eval 'as_val=${'$as_ac_Header'}
10566                  $as_echo "$as_val"'`
10567                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10568 $as_echo "$ac_res" >&6; }
10569
10570 fi
10571 as_val=`eval 'as_val=${'$as_ac_Header'}
10572                  $as_echo "$as_val"'`
10573    if test "x$as_val" = x""yes; then
10574   cat >>confdefs.h <<_ACEOF
10575 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10576 _ACEOF
10577
10578 fi
10579
10580 done
10581
10582
10583 for ac_header in netinet/tcp.h
10584 do
10585 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10586 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10587 $as_echo_n "checking for $ac_header... " >&6; }
10588 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10589   $as_echo_n "(cached) " >&6
10590 else
10591   cat >conftest.$ac_ext <<_ACEOF
10592 /* confdefs.h.  */
10593 _ACEOF
10594 cat confdefs.h >>conftest.$ac_ext
10595 cat >>conftest.$ac_ext <<_ACEOF
10596 /* end confdefs.h.  */
10597 $ac_includes_default
10598 #ifdef HAVE_NETINET_IN_H
10599 #include <netinet/in.h>
10600 #endif
10601
10602
10603 #include <$ac_header>
10604 _ACEOF
10605 rm -f conftest.$ac_objext
10606 if { (ac_try="$ac_compile"
10607 case "(($ac_try" in
10608   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10609   *) ac_try_echo=$ac_try;;
10610 esac
10611 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10612 $as_echo "$ac_try_echo") >&5
10613   (eval "$ac_compile") 2>conftest.er1
10614   ac_status=$?
10615   grep -v '^ *+' conftest.er1 >conftest.err
10616   rm -f conftest.er1
10617   cat conftest.err >&5
10618   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10619   (exit $ac_status); } && {
10620          test -z "$ac_c_werror_flag" ||
10621          test ! -s conftest.err
10622        } && test -s conftest.$ac_objext; then
10623   eval "$as_ac_Header=yes"
10624 else
10625   $as_echo "$as_me: failed program was:" >&5
10626 sed 's/^/| /' conftest.$ac_ext >&5
10627
10628         eval "$as_ac_Header=no"
10629 fi
10630
10631 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10632 fi
10633 ac_res=`eval 'as_val=${'$as_ac_Header'}
10634                  $as_echo "$as_val"'`
10635                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10636 $as_echo "$ac_res" >&6; }
10637 as_val=`eval 'as_val=${'$as_ac_Header'}
10638                  $as_echo "$as_val"'`
10639    if test "x$as_val" = x""yes; then
10640   cat >>confdefs.h <<_ACEOF
10641 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10642 _ACEOF
10643
10644 fi
10645
10646 done
10647
10648
10649 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
10650
10651 for ac_header in readline/readline.h
10652 do
10653 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10654 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10655   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10656 $as_echo_n "checking for $ac_header... " >&6; }
10657 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10658   $as_echo_n "(cached) " >&6
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 else
10665   # Is the header compilable?
10666 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10667 $as_echo_n "checking $ac_header usability... " >&6; }
10668 cat >conftest.$ac_ext <<_ACEOF
10669 /* confdefs.h.  */
10670 _ACEOF
10671 cat confdefs.h >>conftest.$ac_ext
10672 cat >>conftest.$ac_ext <<_ACEOF
10673 /* end confdefs.h.  */
10674 $ac_includes_default
10675 #include <$ac_header>
10676 _ACEOF
10677 rm -f conftest.$ac_objext
10678 if { (ac_try="$ac_compile"
10679 case "(($ac_try" in
10680   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10681   *) ac_try_echo=$ac_try;;
10682 esac
10683 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10684 $as_echo "$ac_try_echo") >&5
10685   (eval "$ac_compile") 2>conftest.er1
10686   ac_status=$?
10687   grep -v '^ *+' conftest.er1 >conftest.err
10688   rm -f conftest.er1
10689   cat conftest.err >&5
10690   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10691   (exit $ac_status); } && {
10692          test -z "$ac_c_werror_flag" ||
10693          test ! -s conftest.err
10694        } && test -s conftest.$ac_objext; then
10695   ac_header_compiler=yes
10696 else
10697   $as_echo "$as_me: failed program was:" >&5
10698 sed 's/^/| /' conftest.$ac_ext >&5
10699
10700         ac_header_compiler=no
10701 fi
10702
10703 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10704 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10705 $as_echo "$ac_header_compiler" >&6; }
10706
10707 # Is the header present?
10708 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10709 $as_echo_n "checking $ac_header presence... " >&6; }
10710 cat >conftest.$ac_ext <<_ACEOF
10711 /* confdefs.h.  */
10712 _ACEOF
10713 cat confdefs.h >>conftest.$ac_ext
10714 cat >>conftest.$ac_ext <<_ACEOF
10715 /* end confdefs.h.  */
10716 #include <$ac_header>
10717 _ACEOF
10718 if { (ac_try="$ac_cpp conftest.$ac_ext"
10719 case "(($ac_try" in
10720   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10721   *) ac_try_echo=$ac_try;;
10722 esac
10723 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10724 $as_echo "$ac_try_echo") >&5
10725   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10726   ac_status=$?
10727   grep -v '^ *+' conftest.er1 >conftest.err
10728   rm -f conftest.er1
10729   cat conftest.err >&5
10730   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10731   (exit $ac_status); } >/dev/null && {
10732          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10733          test ! -s conftest.err
10734        }; then
10735   ac_header_preproc=yes
10736 else
10737   $as_echo "$as_me: failed program was:" >&5
10738 sed 's/^/| /' conftest.$ac_ext >&5
10739
10740   ac_header_preproc=no
10741 fi
10742
10743 rm -f conftest.err conftest.$ac_ext
10744 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10745 $as_echo "$ac_header_preproc" >&6; }
10746
10747 # So?  What about this header?
10748 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10749   yes:no: )
10750     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10751 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10752     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10753 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10754     ac_header_preproc=yes
10755     ;;
10756   no:yes:* )
10757     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10758 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10759     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10760 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10761     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10762 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10763     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10764 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10765     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10766 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10767     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10768 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10769     ( cat <<\_ASBOX
10770 ## ---------------------------------------- ##
10771 ## Report this to pgsql-bugs@postgresql.org ##
10772 ## ---------------------------------------- ##
10773 _ASBOX
10774      ) | sed "s/^/$as_me: WARNING:     /" >&2
10775     ;;
10776 esac
10777 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10778 $as_echo_n "checking for $ac_header... " >&6; }
10779 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10780   $as_echo_n "(cached) " >&6
10781 else
10782   eval "$as_ac_Header=\$ac_header_preproc"
10783 fi
10784 ac_res=`eval 'as_val=${'$as_ac_Header'}
10785                  $as_echo "$as_val"'`
10786                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10787 $as_echo "$ac_res" >&6; }
10788
10789 fi
10790 as_val=`eval 'as_val=${'$as_ac_Header'}
10791                  $as_echo "$as_val"'`
10792    if test "x$as_val" = x""yes; then
10793   cat >>confdefs.h <<_ACEOF
10794 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10795 _ACEOF
10796
10797 else
10798
10799 for ac_header in readline.h
10800 do
10801 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10802 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10803   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10804 $as_echo_n "checking for $ac_header... " >&6; }
10805 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10806   $as_echo_n "(cached) " >&6
10807 fi
10808 ac_res=`eval 'as_val=${'$as_ac_Header'}
10809                  $as_echo "$as_val"'`
10810                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10811 $as_echo "$ac_res" >&6; }
10812 else
10813   # Is the header compilable?
10814 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10815 $as_echo_n "checking $ac_header usability... " >&6; }
10816 cat >conftest.$ac_ext <<_ACEOF
10817 /* confdefs.h.  */
10818 _ACEOF
10819 cat confdefs.h >>conftest.$ac_ext
10820 cat >>conftest.$ac_ext <<_ACEOF
10821 /* end confdefs.h.  */
10822 $ac_includes_default
10823 #include <$ac_header>
10824 _ACEOF
10825 rm -f conftest.$ac_objext
10826 if { (ac_try="$ac_compile"
10827 case "(($ac_try" in
10828   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10829   *) ac_try_echo=$ac_try;;
10830 esac
10831 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10832 $as_echo "$ac_try_echo") >&5
10833   (eval "$ac_compile") 2>conftest.er1
10834   ac_status=$?
10835   grep -v '^ *+' conftest.er1 >conftest.err
10836   rm -f conftest.er1
10837   cat conftest.err >&5
10838   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10839   (exit $ac_status); } && {
10840          test -z "$ac_c_werror_flag" ||
10841          test ! -s conftest.err
10842        } && test -s conftest.$ac_objext; then
10843   ac_header_compiler=yes
10844 else
10845   $as_echo "$as_me: failed program was:" >&5
10846 sed 's/^/| /' conftest.$ac_ext >&5
10847
10848         ac_header_compiler=no
10849 fi
10850
10851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10852 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10853 $as_echo "$ac_header_compiler" >&6; }
10854
10855 # Is the header present?
10856 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10857 $as_echo_n "checking $ac_header presence... " >&6; }
10858 cat >conftest.$ac_ext <<_ACEOF
10859 /* confdefs.h.  */
10860 _ACEOF
10861 cat confdefs.h >>conftest.$ac_ext
10862 cat >>conftest.$ac_ext <<_ACEOF
10863 /* end confdefs.h.  */
10864 #include <$ac_header>
10865 _ACEOF
10866 if { (ac_try="$ac_cpp conftest.$ac_ext"
10867 case "(($ac_try" in
10868   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10869   *) ac_try_echo=$ac_try;;
10870 esac
10871 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10872 $as_echo "$ac_try_echo") >&5
10873   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10874   ac_status=$?
10875   grep -v '^ *+' conftest.er1 >conftest.err
10876   rm -f conftest.er1
10877   cat conftest.err >&5
10878   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10879   (exit $ac_status); } >/dev/null && {
10880          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10881          test ! -s conftest.err
10882        }; then
10883   ac_header_preproc=yes
10884 else
10885   $as_echo "$as_me: failed program was:" >&5
10886 sed 's/^/| /' conftest.$ac_ext >&5
10887
10888   ac_header_preproc=no
10889 fi
10890
10891 rm -f conftest.err conftest.$ac_ext
10892 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10893 $as_echo "$ac_header_preproc" >&6; }
10894
10895 # So?  What about this header?
10896 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10897   yes:no: )
10898     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10899 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10900     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10901 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10902     ac_header_preproc=yes
10903     ;;
10904   no:yes:* )
10905     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10906 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10907     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10908 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10909     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10910 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10911     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10912 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10913     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10914 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10915     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10916 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10917     ( cat <<\_ASBOX
10918 ## ---------------------------------------- ##
10919 ## Report this to pgsql-bugs@postgresql.org ##
10920 ## ---------------------------------------- ##
10921 _ASBOX
10922      ) | sed "s/^/$as_me: WARNING:     /" >&2
10923     ;;
10924 esac
10925 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10926 $as_echo_n "checking for $ac_header... " >&6; }
10927 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10928   $as_echo_n "(cached) " >&6
10929 else
10930   eval "$as_ac_Header=\$ac_header_preproc"
10931 fi
10932 ac_res=`eval 'as_val=${'$as_ac_Header'}
10933                  $as_echo "$as_val"'`
10934                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10935 $as_echo "$ac_res" >&6; }
10936
10937 fi
10938 as_val=`eval 'as_val=${'$as_ac_Header'}
10939                  $as_echo "$as_val"'`
10940    if test "x$as_val" = x""yes; then
10941   cat >>confdefs.h <<_ACEOF
10942 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10943 _ACEOF
10944
10945 else
10946   { { $as_echo "$as_me:$LINENO: error: readline header not found
10947 If you have readline already installed, see config.log for details on the
10948 failure.  It is possible the compiler isn't looking in the proper directory.
10949 Use --without-readline to disable readline support." >&5
10950 $as_echo "$as_me: error: readline header not found
10951 If you have readline already installed, see config.log for details on the
10952 failure.  It is possible the compiler isn't looking in the proper directory.
10953 Use --without-readline to disable readline support." >&2;}
10954    { (exit 1); exit 1; }; }
10955 fi
10956
10957 done
10958
10959 fi
10960
10961 done
10962
10963
10964 for ac_header in readline/history.h
10965 do
10966 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10967 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10968   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10969 $as_echo_n "checking for $ac_header... " >&6; }
10970 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10971   $as_echo_n "(cached) " >&6
10972 fi
10973 ac_res=`eval 'as_val=${'$as_ac_Header'}
10974                  $as_echo "$as_val"'`
10975                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10976 $as_echo "$ac_res" >&6; }
10977 else
10978   # Is the header compilable?
10979 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10980 $as_echo_n "checking $ac_header usability... " >&6; }
10981 cat >conftest.$ac_ext <<_ACEOF
10982 /* confdefs.h.  */
10983 _ACEOF
10984 cat confdefs.h >>conftest.$ac_ext
10985 cat >>conftest.$ac_ext <<_ACEOF
10986 /* end confdefs.h.  */
10987 $ac_includes_default
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   ac_header_compiler=yes
11009 else
11010   $as_echo "$as_me: failed program was:" >&5
11011 sed 's/^/| /' conftest.$ac_ext >&5
11012
11013         ac_header_compiler=no
11014 fi
11015
11016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11017 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11018 $as_echo "$ac_header_compiler" >&6; }
11019
11020 # Is the header present?
11021 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11022 $as_echo_n "checking $ac_header presence... " >&6; }
11023 cat >conftest.$ac_ext <<_ACEOF
11024 /* confdefs.h.  */
11025 _ACEOF
11026 cat confdefs.h >>conftest.$ac_ext
11027 cat >>conftest.$ac_ext <<_ACEOF
11028 /* end confdefs.h.  */
11029 #include <$ac_header>
11030 _ACEOF
11031 if { (ac_try="$ac_cpp conftest.$ac_ext"
11032 case "(($ac_try" in
11033   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11034   *) ac_try_echo=$ac_try;;
11035 esac
11036 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11037 $as_echo "$ac_try_echo") >&5
11038   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11039   ac_status=$?
11040   grep -v '^ *+' conftest.er1 >conftest.err
11041   rm -f conftest.er1
11042   cat conftest.err >&5
11043   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11044   (exit $ac_status); } >/dev/null && {
11045          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11046          test ! -s conftest.err
11047        }; then
11048   ac_header_preproc=yes
11049 else
11050   $as_echo "$as_me: failed program was:" >&5
11051 sed 's/^/| /' conftest.$ac_ext >&5
11052
11053   ac_header_preproc=no
11054 fi
11055
11056 rm -f conftest.err conftest.$ac_ext
11057 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11058 $as_echo "$ac_header_preproc" >&6; }
11059
11060 # So?  What about this header?
11061 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11062   yes:no: )
11063     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11064 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11065     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11066 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11067     ac_header_preproc=yes
11068     ;;
11069   no:yes:* )
11070     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11071 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11072     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11073 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11074     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11075 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11076     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11077 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11078     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11079 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11080     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11081 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11082     ( cat <<\_ASBOX
11083 ## ---------------------------------------- ##
11084 ## Report this to pgsql-bugs@postgresql.org ##
11085 ## ---------------------------------------- ##
11086 _ASBOX
11087      ) | sed "s/^/$as_me: WARNING:     /" >&2
11088     ;;
11089 esac
11090 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11091 $as_echo_n "checking for $ac_header... " >&6; }
11092 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11093   $as_echo_n "(cached) " >&6
11094 else
11095   eval "$as_ac_Header=\$ac_header_preproc"
11096 fi
11097 ac_res=`eval 'as_val=${'$as_ac_Header'}
11098                  $as_echo "$as_val"'`
11099                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11100 $as_echo "$ac_res" >&6; }
11101
11102 fi
11103 as_val=`eval 'as_val=${'$as_ac_Header'}
11104                  $as_echo "$as_val"'`
11105    if test "x$as_val" = x""yes; then
11106   cat >>confdefs.h <<_ACEOF
11107 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11108 _ACEOF
11109
11110 else
11111
11112 for ac_header in history.h
11113 do
11114 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11115 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11116   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11117 $as_echo_n "checking for $ac_header... " >&6; }
11118 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11119   $as_echo_n "(cached) " >&6
11120 fi
11121 ac_res=`eval 'as_val=${'$as_ac_Header'}
11122                  $as_echo "$as_val"'`
11123                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11124 $as_echo "$ac_res" >&6; }
11125 else
11126   # Is the header compilable?
11127 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11128 $as_echo_n "checking $ac_header usability... " >&6; }
11129 cat >conftest.$ac_ext <<_ACEOF
11130 /* confdefs.h.  */
11131 _ACEOF
11132 cat confdefs.h >>conftest.$ac_ext
11133 cat >>conftest.$ac_ext <<_ACEOF
11134 /* end confdefs.h.  */
11135 $ac_includes_default
11136 #include <$ac_header>
11137 _ACEOF
11138 rm -f conftest.$ac_objext
11139 if { (ac_try="$ac_compile"
11140 case "(($ac_try" in
11141   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11142   *) ac_try_echo=$ac_try;;
11143 esac
11144 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11145 $as_echo "$ac_try_echo") >&5
11146   (eval "$ac_compile") 2>conftest.er1
11147   ac_status=$?
11148   grep -v '^ *+' conftest.er1 >conftest.err
11149   rm -f conftest.er1
11150   cat conftest.err >&5
11151   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11152   (exit $ac_status); } && {
11153          test -z "$ac_c_werror_flag" ||
11154          test ! -s conftest.err
11155        } && test -s conftest.$ac_objext; then
11156   ac_header_compiler=yes
11157 else
11158   $as_echo "$as_me: failed program was:" >&5
11159 sed 's/^/| /' conftest.$ac_ext >&5
11160
11161         ac_header_compiler=no
11162 fi
11163
11164 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11165 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11166 $as_echo "$ac_header_compiler" >&6; }
11167
11168 # Is the header present?
11169 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11170 $as_echo_n "checking $ac_header presence... " >&6; }
11171 cat >conftest.$ac_ext <<_ACEOF
11172 /* confdefs.h.  */
11173 _ACEOF
11174 cat confdefs.h >>conftest.$ac_ext
11175 cat >>conftest.$ac_ext <<_ACEOF
11176 /* end confdefs.h.  */
11177 #include <$ac_header>
11178 _ACEOF
11179 if { (ac_try="$ac_cpp conftest.$ac_ext"
11180 case "(($ac_try" in
11181   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11182   *) ac_try_echo=$ac_try;;
11183 esac
11184 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11185 $as_echo "$ac_try_echo") >&5
11186   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11187   ac_status=$?
11188   grep -v '^ *+' conftest.er1 >conftest.err
11189   rm -f conftest.er1
11190   cat conftest.err >&5
11191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11192   (exit $ac_status); } >/dev/null && {
11193          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11194          test ! -s conftest.err
11195        }; then
11196   ac_header_preproc=yes
11197 else
11198   $as_echo "$as_me: failed program was:" >&5
11199 sed 's/^/| /' conftest.$ac_ext >&5
11200
11201   ac_header_preproc=no
11202 fi
11203
11204 rm -f conftest.err conftest.$ac_ext
11205 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11206 $as_echo "$ac_header_preproc" >&6; }
11207
11208 # So?  What about this header?
11209 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11210   yes:no: )
11211     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11212 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11213     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11214 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11215     ac_header_preproc=yes
11216     ;;
11217   no:yes:* )
11218     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11219 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11220     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11221 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11222     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11223 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11224     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11225 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11226     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11227 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11228     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11229 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11230     ( cat <<\_ASBOX
11231 ## ---------------------------------------- ##
11232 ## Report this to pgsql-bugs@postgresql.org ##
11233 ## ---------------------------------------- ##
11234 _ASBOX
11235      ) | sed "s/^/$as_me: WARNING:     /" >&2
11236     ;;
11237 esac
11238 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11239 $as_echo_n "checking for $ac_header... " >&6; }
11240 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11241   $as_echo_n "(cached) " >&6
11242 else
11243   eval "$as_ac_Header=\$ac_header_preproc"
11244 fi
11245 ac_res=`eval 'as_val=${'$as_ac_Header'}
11246                  $as_echo "$as_val"'`
11247                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11248 $as_echo "$ac_res" >&6; }
11249
11250 fi
11251 as_val=`eval 'as_val=${'$as_ac_Header'}
11252                  $as_echo "$as_val"'`
11253    if test "x$as_val" = x""yes; then
11254   cat >>confdefs.h <<_ACEOF
11255 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11256 _ACEOF
11257
11258 else
11259   { { $as_echo "$as_me:$LINENO: error: history header not found
11260 If you have readline already installed, see config.log for details on the
11261 failure.  It is possible the compiler isn't looking in the proper directory.
11262 Use --without-readline to disable readline support." >&5
11263 $as_echo "$as_me: error: history header not found
11264 If you have readline already installed, see config.log for details on the
11265 failure.  It is possible the compiler isn't looking in the proper directory.
11266 Use --without-readline to disable readline support." >&2;}
11267    { (exit 1); exit 1; }; }
11268 fi
11269
11270 done
11271
11272 fi
11273
11274 done
11275
11276 fi
11277
11278 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
11279 # Some installations of libedit usurp /usr/include/readline/, which seems
11280 # bad practice, since in combined installations readline will have its headers
11281 # there.  We might have to resort to AC_EGREP checks to make sure we found
11282 # the proper header...
11283
11284 for ac_header in editline/readline.h
11285 do
11286 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11287 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11288   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11289 $as_echo_n "checking for $ac_header... " >&6; }
11290 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11291   $as_echo_n "(cached) " >&6
11292 fi
11293 ac_res=`eval 'as_val=${'$as_ac_Header'}
11294                  $as_echo "$as_val"'`
11295                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11296 $as_echo "$ac_res" >&6; }
11297 else
11298   # Is the header compilable?
11299 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11300 $as_echo_n "checking $ac_header usability... " >&6; }
11301 cat >conftest.$ac_ext <<_ACEOF
11302 /* confdefs.h.  */
11303 _ACEOF
11304 cat confdefs.h >>conftest.$ac_ext
11305 cat >>conftest.$ac_ext <<_ACEOF
11306 /* end confdefs.h.  */
11307 $ac_includes_default
11308 #include <$ac_header>
11309 _ACEOF
11310 rm -f conftest.$ac_objext
11311 if { (ac_try="$ac_compile"
11312 case "(($ac_try" in
11313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11314   *) ac_try_echo=$ac_try;;
11315 esac
11316 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11317 $as_echo "$ac_try_echo") >&5
11318   (eval "$ac_compile") 2>conftest.er1
11319   ac_status=$?
11320   grep -v '^ *+' conftest.er1 >conftest.err
11321   rm -f conftest.er1
11322   cat conftest.err >&5
11323   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11324   (exit $ac_status); } && {
11325          test -z "$ac_c_werror_flag" ||
11326          test ! -s conftest.err
11327        } && test -s conftest.$ac_objext; then
11328   ac_header_compiler=yes
11329 else
11330   $as_echo "$as_me: failed program was:" >&5
11331 sed 's/^/| /' conftest.$ac_ext >&5
11332
11333         ac_header_compiler=no
11334 fi
11335
11336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11337 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11338 $as_echo "$ac_header_compiler" >&6; }
11339
11340 # Is the header present?
11341 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11342 $as_echo_n "checking $ac_header presence... " >&6; }
11343 cat >conftest.$ac_ext <<_ACEOF
11344 /* confdefs.h.  */
11345 _ACEOF
11346 cat confdefs.h >>conftest.$ac_ext
11347 cat >>conftest.$ac_ext <<_ACEOF
11348 /* end confdefs.h.  */
11349 #include <$ac_header>
11350 _ACEOF
11351 if { (ac_try="$ac_cpp conftest.$ac_ext"
11352 case "(($ac_try" in
11353   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11354   *) ac_try_echo=$ac_try;;
11355 esac
11356 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11357 $as_echo "$ac_try_echo") >&5
11358   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11359   ac_status=$?
11360   grep -v '^ *+' conftest.er1 >conftest.err
11361   rm -f conftest.er1
11362   cat conftest.err >&5
11363   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11364   (exit $ac_status); } >/dev/null && {
11365          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11366          test ! -s conftest.err
11367        }; then
11368   ac_header_preproc=yes
11369 else
11370   $as_echo "$as_me: failed program was:" >&5
11371 sed 's/^/| /' conftest.$ac_ext >&5
11372
11373   ac_header_preproc=no
11374 fi
11375
11376 rm -f conftest.err conftest.$ac_ext
11377 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11378 $as_echo "$ac_header_preproc" >&6; }
11379
11380 # So?  What about this header?
11381 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11382   yes:no: )
11383     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11384 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11385     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11386 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11387     ac_header_preproc=yes
11388     ;;
11389   no:yes:* )
11390     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11391 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11392     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11393 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11394     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11395 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11396     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11397 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11398     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11399 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11400     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11401 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11402     ( cat <<\_ASBOX
11403 ## ---------------------------------------- ##
11404 ## Report this to pgsql-bugs@postgresql.org ##
11405 ## ---------------------------------------- ##
11406 _ASBOX
11407      ) | sed "s/^/$as_me: WARNING:     /" >&2
11408     ;;
11409 esac
11410 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11411 $as_echo_n "checking for $ac_header... " >&6; }
11412 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11413   $as_echo_n "(cached) " >&6
11414 else
11415   eval "$as_ac_Header=\$ac_header_preproc"
11416 fi
11417 ac_res=`eval 'as_val=${'$as_ac_Header'}
11418                  $as_echo "$as_val"'`
11419                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11420 $as_echo "$ac_res" >&6; }
11421
11422 fi
11423 as_val=`eval 'as_val=${'$as_ac_Header'}
11424                  $as_echo "$as_val"'`
11425    if test "x$as_val" = x""yes; then
11426   cat >>confdefs.h <<_ACEOF
11427 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11428 _ACEOF
11429
11430 else
11431
11432 for ac_header in readline.h
11433 do
11434 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11435 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11436   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11437 $as_echo_n "checking for $ac_header... " >&6; }
11438 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11439   $as_echo_n "(cached) " >&6
11440 fi
11441 ac_res=`eval 'as_val=${'$as_ac_Header'}
11442                  $as_echo "$as_val"'`
11443                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11444 $as_echo "$ac_res" >&6; }
11445 else
11446   # Is the header compilable?
11447 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11448 $as_echo_n "checking $ac_header usability... " >&6; }
11449 cat >conftest.$ac_ext <<_ACEOF
11450 /* confdefs.h.  */
11451 _ACEOF
11452 cat confdefs.h >>conftest.$ac_ext
11453 cat >>conftest.$ac_ext <<_ACEOF
11454 /* end confdefs.h.  */
11455 $ac_includes_default
11456 #include <$ac_header>
11457 _ACEOF
11458 rm -f conftest.$ac_objext
11459 if { (ac_try="$ac_compile"
11460 case "(($ac_try" in
11461   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11462   *) ac_try_echo=$ac_try;;
11463 esac
11464 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11465 $as_echo "$ac_try_echo") >&5
11466   (eval "$ac_compile") 2>conftest.er1
11467   ac_status=$?
11468   grep -v '^ *+' conftest.er1 >conftest.err
11469   rm -f conftest.er1
11470   cat conftest.err >&5
11471   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11472   (exit $ac_status); } && {
11473          test -z "$ac_c_werror_flag" ||
11474          test ! -s conftest.err
11475        } && test -s conftest.$ac_objext; then
11476   ac_header_compiler=yes
11477 else
11478   $as_echo "$as_me: failed program was:" >&5
11479 sed 's/^/| /' conftest.$ac_ext >&5
11480
11481         ac_header_compiler=no
11482 fi
11483
11484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11485 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11486 $as_echo "$ac_header_compiler" >&6; }
11487
11488 # Is the header present?
11489 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11490 $as_echo_n "checking $ac_header presence... " >&6; }
11491 cat >conftest.$ac_ext <<_ACEOF
11492 /* confdefs.h.  */
11493 _ACEOF
11494 cat confdefs.h >>conftest.$ac_ext
11495 cat >>conftest.$ac_ext <<_ACEOF
11496 /* end confdefs.h.  */
11497 #include <$ac_header>
11498 _ACEOF
11499 if { (ac_try="$ac_cpp conftest.$ac_ext"
11500 case "(($ac_try" in
11501   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11502   *) ac_try_echo=$ac_try;;
11503 esac
11504 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11505 $as_echo "$ac_try_echo") >&5
11506   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11507   ac_status=$?
11508   grep -v '^ *+' conftest.er1 >conftest.err
11509   rm -f conftest.er1
11510   cat conftest.err >&5
11511   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11512   (exit $ac_status); } >/dev/null && {
11513          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11514          test ! -s conftest.err
11515        }; then
11516   ac_header_preproc=yes
11517 else
11518   $as_echo "$as_me: failed program was:" >&5
11519 sed 's/^/| /' conftest.$ac_ext >&5
11520
11521   ac_header_preproc=no
11522 fi
11523
11524 rm -f conftest.err conftest.$ac_ext
11525 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11526 $as_echo "$ac_header_preproc" >&6; }
11527
11528 # So?  What about this header?
11529 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11530   yes:no: )
11531     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11532 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11533     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11534 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11535     ac_header_preproc=yes
11536     ;;
11537   no:yes:* )
11538     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11539 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11540     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11541 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11542     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11543 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11544     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11545 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11546     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11547 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11548     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11549 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11550     ( cat <<\_ASBOX
11551 ## ---------------------------------------- ##
11552 ## Report this to pgsql-bugs@postgresql.org ##
11553 ## ---------------------------------------- ##
11554 _ASBOX
11555      ) | sed "s/^/$as_me: WARNING:     /" >&2
11556     ;;
11557 esac
11558 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11559 $as_echo_n "checking for $ac_header... " >&6; }
11560 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11561   $as_echo_n "(cached) " >&6
11562 else
11563   eval "$as_ac_Header=\$ac_header_preproc"
11564 fi
11565 ac_res=`eval 'as_val=${'$as_ac_Header'}
11566                  $as_echo "$as_val"'`
11567                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11568 $as_echo "$ac_res" >&6; }
11569
11570 fi
11571 as_val=`eval 'as_val=${'$as_ac_Header'}
11572                  $as_echo "$as_val"'`
11573    if test "x$as_val" = x""yes; then
11574   cat >>confdefs.h <<_ACEOF
11575 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11576 _ACEOF
11577
11578 else
11579
11580 for ac_header in readline/readline.h
11581 do
11582 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11583 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11584   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11585 $as_echo_n "checking for $ac_header... " >&6; }
11586 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11587   $as_echo_n "(cached) " >&6
11588 fi
11589 ac_res=`eval 'as_val=${'$as_ac_Header'}
11590                  $as_echo "$as_val"'`
11591                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11592 $as_echo "$ac_res" >&6; }
11593 else
11594   # Is the header compilable?
11595 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11596 $as_echo_n "checking $ac_header usability... " >&6; }
11597 cat >conftest.$ac_ext <<_ACEOF
11598 /* confdefs.h.  */
11599 _ACEOF
11600 cat confdefs.h >>conftest.$ac_ext
11601 cat >>conftest.$ac_ext <<_ACEOF
11602 /* end confdefs.h.  */
11603 $ac_includes_default
11604 #include <$ac_header>
11605 _ACEOF
11606 rm -f conftest.$ac_objext
11607 if { (ac_try="$ac_compile"
11608 case "(($ac_try" in
11609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11610   *) ac_try_echo=$ac_try;;
11611 esac
11612 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11613 $as_echo "$ac_try_echo") >&5
11614   (eval "$ac_compile") 2>conftest.er1
11615   ac_status=$?
11616   grep -v '^ *+' conftest.er1 >conftest.err
11617   rm -f conftest.er1
11618   cat conftest.err >&5
11619   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11620   (exit $ac_status); } && {
11621          test -z "$ac_c_werror_flag" ||
11622          test ! -s conftest.err
11623        } && test -s conftest.$ac_objext; then
11624   ac_header_compiler=yes
11625 else
11626   $as_echo "$as_me: failed program was:" >&5
11627 sed 's/^/| /' conftest.$ac_ext >&5
11628
11629         ac_header_compiler=no
11630 fi
11631
11632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11633 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11634 $as_echo "$ac_header_compiler" >&6; }
11635
11636 # Is the header present?
11637 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11638 $as_echo_n "checking $ac_header presence... " >&6; }
11639 cat >conftest.$ac_ext <<_ACEOF
11640 /* confdefs.h.  */
11641 _ACEOF
11642 cat confdefs.h >>conftest.$ac_ext
11643 cat >>conftest.$ac_ext <<_ACEOF
11644 /* end confdefs.h.  */
11645 #include <$ac_header>
11646 _ACEOF
11647 if { (ac_try="$ac_cpp conftest.$ac_ext"
11648 case "(($ac_try" in
11649   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11650   *) ac_try_echo=$ac_try;;
11651 esac
11652 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11653 $as_echo "$ac_try_echo") >&5
11654   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11655   ac_status=$?
11656   grep -v '^ *+' conftest.er1 >conftest.err
11657   rm -f conftest.er1
11658   cat conftest.err >&5
11659   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11660   (exit $ac_status); } >/dev/null && {
11661          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11662          test ! -s conftest.err
11663        }; then
11664   ac_header_preproc=yes
11665 else
11666   $as_echo "$as_me: failed program was:" >&5
11667 sed 's/^/| /' conftest.$ac_ext >&5
11668
11669   ac_header_preproc=no
11670 fi
11671
11672 rm -f conftest.err conftest.$ac_ext
11673 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11674 $as_echo "$ac_header_preproc" >&6; }
11675
11676 # So?  What about this header?
11677 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11678   yes:no: )
11679     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11680 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11681     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11682 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11683     ac_header_preproc=yes
11684     ;;
11685   no:yes:* )
11686     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11687 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11688     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11689 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11690     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11691 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11692     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11693 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11694     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11695 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11696     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11697 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11698     ( cat <<\_ASBOX
11699 ## ---------------------------------------- ##
11700 ## Report this to pgsql-bugs@postgresql.org ##
11701 ## ---------------------------------------- ##
11702 _ASBOX
11703      ) | sed "s/^/$as_me: WARNING:     /" >&2
11704     ;;
11705 esac
11706 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11707 $as_echo_n "checking for $ac_header... " >&6; }
11708 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11709   $as_echo_n "(cached) " >&6
11710 else
11711   eval "$as_ac_Header=\$ac_header_preproc"
11712 fi
11713 ac_res=`eval 'as_val=${'$as_ac_Header'}
11714                  $as_echo "$as_val"'`
11715                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11716 $as_echo "$ac_res" >&6; }
11717
11718 fi
11719 as_val=`eval 'as_val=${'$as_ac_Header'}
11720                  $as_echo "$as_val"'`
11721    if test "x$as_val" = x""yes; then
11722   cat >>confdefs.h <<_ACEOF
11723 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11724 _ACEOF
11725
11726 else
11727   { { $as_echo "$as_me:$LINENO: error: readline header not found
11728 If you have libedit already installed, see config.log for details on the
11729 failure.  It is possible the compiler isn't looking in the proper directory.
11730 Use --without-readline to disable libedit support." >&5
11731 $as_echo "$as_me: error: readline header not found
11732 If you have libedit already installed, see config.log for details on the
11733 failure.  It is possible the compiler isn't looking in the proper directory.
11734 Use --without-readline to disable libedit support." >&2;}
11735    { (exit 1); exit 1; }; }
11736 fi
11737
11738 done
11739
11740 fi
11741
11742 done
11743
11744 fi
11745
11746 done
11747
11748 # Note: in a libedit installation, history.h is sometimes a dummy, and may
11749 # not be there at all.  Hence, don't complain if not found.  We must check
11750 # though, since in yet other versions it is an independent header.
11751
11752 for ac_header in editline/history.h
11753 do
11754 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11755 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11756   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11757 $as_echo_n "checking for $ac_header... " >&6; }
11758 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11759   $as_echo_n "(cached) " >&6
11760 fi
11761 ac_res=`eval 'as_val=${'$as_ac_Header'}
11762                  $as_echo "$as_val"'`
11763                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11764 $as_echo "$ac_res" >&6; }
11765 else
11766   # Is the header compilable?
11767 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11768 $as_echo_n "checking $ac_header usability... " >&6; }
11769 cat >conftest.$ac_ext <<_ACEOF
11770 /* confdefs.h.  */
11771 _ACEOF
11772 cat confdefs.h >>conftest.$ac_ext
11773 cat >>conftest.$ac_ext <<_ACEOF
11774 /* end confdefs.h.  */
11775 $ac_includes_default
11776 #include <$ac_header>
11777 _ACEOF
11778 rm -f conftest.$ac_objext
11779 if { (ac_try="$ac_compile"
11780 case "(($ac_try" in
11781   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11782   *) ac_try_echo=$ac_try;;
11783 esac
11784 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11785 $as_echo "$ac_try_echo") >&5
11786   (eval "$ac_compile") 2>conftest.er1
11787   ac_status=$?
11788   grep -v '^ *+' conftest.er1 >conftest.err
11789   rm -f conftest.er1
11790   cat conftest.err >&5
11791   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11792   (exit $ac_status); } && {
11793          test -z "$ac_c_werror_flag" ||
11794          test ! -s conftest.err
11795        } && test -s conftest.$ac_objext; then
11796   ac_header_compiler=yes
11797 else
11798   $as_echo "$as_me: failed program was:" >&5
11799 sed 's/^/| /' conftest.$ac_ext >&5
11800
11801         ac_header_compiler=no
11802 fi
11803
11804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11805 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11806 $as_echo "$ac_header_compiler" >&6; }
11807
11808 # Is the header present?
11809 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11810 $as_echo_n "checking $ac_header presence... " >&6; }
11811 cat >conftest.$ac_ext <<_ACEOF
11812 /* confdefs.h.  */
11813 _ACEOF
11814 cat confdefs.h >>conftest.$ac_ext
11815 cat >>conftest.$ac_ext <<_ACEOF
11816 /* end confdefs.h.  */
11817 #include <$ac_header>
11818 _ACEOF
11819 if { (ac_try="$ac_cpp conftest.$ac_ext"
11820 case "(($ac_try" in
11821   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11822   *) ac_try_echo=$ac_try;;
11823 esac
11824 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11825 $as_echo "$ac_try_echo") >&5
11826   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11827   ac_status=$?
11828   grep -v '^ *+' conftest.er1 >conftest.err
11829   rm -f conftest.er1
11830   cat conftest.err >&5
11831   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11832   (exit $ac_status); } >/dev/null && {
11833          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11834          test ! -s conftest.err
11835        }; then
11836   ac_header_preproc=yes
11837 else
11838   $as_echo "$as_me: failed program was:" >&5
11839 sed 's/^/| /' conftest.$ac_ext >&5
11840
11841   ac_header_preproc=no
11842 fi
11843
11844 rm -f conftest.err conftest.$ac_ext
11845 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11846 $as_echo "$ac_header_preproc" >&6; }
11847
11848 # So?  What about this header?
11849 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11850   yes:no: )
11851     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11852 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11853     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11854 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11855     ac_header_preproc=yes
11856     ;;
11857   no:yes:* )
11858     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11859 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11860     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11861 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11862     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11863 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11864     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11865 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11866     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11867 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11868     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11869 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11870     ( cat <<\_ASBOX
11871 ## ---------------------------------------- ##
11872 ## Report this to pgsql-bugs@postgresql.org ##
11873 ## ---------------------------------------- ##
11874 _ASBOX
11875      ) | sed "s/^/$as_me: WARNING:     /" >&2
11876     ;;
11877 esac
11878 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11879 $as_echo_n "checking for $ac_header... " >&6; }
11880 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11881   $as_echo_n "(cached) " >&6
11882 else
11883   eval "$as_ac_Header=\$ac_header_preproc"
11884 fi
11885 ac_res=`eval 'as_val=${'$as_ac_Header'}
11886                  $as_echo "$as_val"'`
11887                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11888 $as_echo "$ac_res" >&6; }
11889
11890 fi
11891 as_val=`eval 'as_val=${'$as_ac_Header'}
11892                  $as_echo "$as_val"'`
11893    if test "x$as_val" = x""yes; then
11894   cat >>confdefs.h <<_ACEOF
11895 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11896 _ACEOF
11897
11898 else
11899
11900 for ac_header in history.h
11901 do
11902 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11903 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11904   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11905 $as_echo_n "checking for $ac_header... " >&6; }
11906 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11907   $as_echo_n "(cached) " >&6
11908 fi
11909 ac_res=`eval 'as_val=${'$as_ac_Header'}
11910                  $as_echo "$as_val"'`
11911                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11912 $as_echo "$ac_res" >&6; }
11913 else
11914   # Is the header compilable?
11915 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11916 $as_echo_n "checking $ac_header usability... " >&6; }
11917 cat >conftest.$ac_ext <<_ACEOF
11918 /* confdefs.h.  */
11919 _ACEOF
11920 cat confdefs.h >>conftest.$ac_ext
11921 cat >>conftest.$ac_ext <<_ACEOF
11922 /* end confdefs.h.  */
11923 $ac_includes_default
11924 #include <$ac_header>
11925 _ACEOF
11926 rm -f conftest.$ac_objext
11927 if { (ac_try="$ac_compile"
11928 case "(($ac_try" in
11929   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11930   *) ac_try_echo=$ac_try;;
11931 esac
11932 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11933 $as_echo "$ac_try_echo") >&5
11934   (eval "$ac_compile") 2>conftest.er1
11935   ac_status=$?
11936   grep -v '^ *+' conftest.er1 >conftest.err
11937   rm -f conftest.er1
11938   cat conftest.err >&5
11939   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11940   (exit $ac_status); } && {
11941          test -z "$ac_c_werror_flag" ||
11942          test ! -s conftest.err
11943        } && test -s conftest.$ac_objext; then
11944   ac_header_compiler=yes
11945 else
11946   $as_echo "$as_me: failed program was:" >&5
11947 sed 's/^/| /' conftest.$ac_ext >&5
11948
11949         ac_header_compiler=no
11950 fi
11951
11952 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11953 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11954 $as_echo "$ac_header_compiler" >&6; }
11955
11956 # Is the header present?
11957 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11958 $as_echo_n "checking $ac_header presence... " >&6; }
11959 cat >conftest.$ac_ext <<_ACEOF
11960 /* confdefs.h.  */
11961 _ACEOF
11962 cat confdefs.h >>conftest.$ac_ext
11963 cat >>conftest.$ac_ext <<_ACEOF
11964 /* end confdefs.h.  */
11965 #include <$ac_header>
11966 _ACEOF
11967 if { (ac_try="$ac_cpp conftest.$ac_ext"
11968 case "(($ac_try" in
11969   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11970   *) ac_try_echo=$ac_try;;
11971 esac
11972 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11973 $as_echo "$ac_try_echo") >&5
11974   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11975   ac_status=$?
11976   grep -v '^ *+' conftest.er1 >conftest.err
11977   rm -f conftest.er1
11978   cat conftest.err >&5
11979   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11980   (exit $ac_status); } >/dev/null && {
11981          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11982          test ! -s conftest.err
11983        }; then
11984   ac_header_preproc=yes
11985 else
11986   $as_echo "$as_me: failed program was:" >&5
11987 sed 's/^/| /' conftest.$ac_ext >&5
11988
11989   ac_header_preproc=no
11990 fi
11991
11992 rm -f conftest.err conftest.$ac_ext
11993 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11994 $as_echo "$ac_header_preproc" >&6; }
11995
11996 # So?  What about this header?
11997 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11998   yes:no: )
11999     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12000 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12001     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12002 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12003     ac_header_preproc=yes
12004     ;;
12005   no:yes:* )
12006     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12007 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12008     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12009 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12010     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12011 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12012     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12013 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12014     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12015 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12016     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12017 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12018     ( cat <<\_ASBOX
12019 ## ---------------------------------------- ##
12020 ## Report this to pgsql-bugs@postgresql.org ##
12021 ## ---------------------------------------- ##
12022 _ASBOX
12023      ) | sed "s/^/$as_me: WARNING:     /" >&2
12024     ;;
12025 esac
12026 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12027 $as_echo_n "checking for $ac_header... " >&6; }
12028 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12029   $as_echo_n "(cached) " >&6
12030 else
12031   eval "$as_ac_Header=\$ac_header_preproc"
12032 fi
12033 ac_res=`eval 'as_val=${'$as_ac_Header'}
12034                  $as_echo "$as_val"'`
12035                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12036 $as_echo "$ac_res" >&6; }
12037
12038 fi
12039 as_val=`eval 'as_val=${'$as_ac_Header'}
12040                  $as_echo "$as_val"'`
12041    if test "x$as_val" = x""yes; then
12042   cat >>confdefs.h <<_ACEOF
12043 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12044 _ACEOF
12045
12046 else
12047
12048 for ac_header in readline/history.h
12049 do
12050 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12051 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12052   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12053 $as_echo_n "checking for $ac_header... " >&6; }
12054 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12055   $as_echo_n "(cached) " >&6
12056 fi
12057 ac_res=`eval 'as_val=${'$as_ac_Header'}
12058                  $as_echo "$as_val"'`
12059                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12060 $as_echo "$ac_res" >&6; }
12061 else
12062   # Is the header compilable?
12063 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12064 $as_echo_n "checking $ac_header usability... " >&6; }
12065 cat >conftest.$ac_ext <<_ACEOF
12066 /* confdefs.h.  */
12067 _ACEOF
12068 cat confdefs.h >>conftest.$ac_ext
12069 cat >>conftest.$ac_ext <<_ACEOF
12070 /* end confdefs.h.  */
12071 $ac_includes_default
12072 #include <$ac_header>
12073 _ACEOF
12074 rm -f conftest.$ac_objext
12075 if { (ac_try="$ac_compile"
12076 case "(($ac_try" in
12077   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12078   *) ac_try_echo=$ac_try;;
12079 esac
12080 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12081 $as_echo "$ac_try_echo") >&5
12082   (eval "$ac_compile") 2>conftest.er1
12083   ac_status=$?
12084   grep -v '^ *+' conftest.er1 >conftest.err
12085   rm -f conftest.er1
12086   cat conftest.err >&5
12087   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12088   (exit $ac_status); } && {
12089          test -z "$ac_c_werror_flag" ||
12090          test ! -s conftest.err
12091        } && test -s conftest.$ac_objext; then
12092   ac_header_compiler=yes
12093 else
12094   $as_echo "$as_me: failed program was:" >&5
12095 sed 's/^/| /' conftest.$ac_ext >&5
12096
12097         ac_header_compiler=no
12098 fi
12099
12100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12101 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12102 $as_echo "$ac_header_compiler" >&6; }
12103
12104 # Is the header present?
12105 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12106 $as_echo_n "checking $ac_header presence... " >&6; }
12107 cat >conftest.$ac_ext <<_ACEOF
12108 /* confdefs.h.  */
12109 _ACEOF
12110 cat confdefs.h >>conftest.$ac_ext
12111 cat >>conftest.$ac_ext <<_ACEOF
12112 /* end confdefs.h.  */
12113 #include <$ac_header>
12114 _ACEOF
12115 if { (ac_try="$ac_cpp conftest.$ac_ext"
12116 case "(($ac_try" in
12117   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12118   *) ac_try_echo=$ac_try;;
12119 esac
12120 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12121 $as_echo "$ac_try_echo") >&5
12122   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12123   ac_status=$?
12124   grep -v '^ *+' conftest.er1 >conftest.err
12125   rm -f conftest.er1
12126   cat conftest.err >&5
12127   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12128   (exit $ac_status); } >/dev/null && {
12129          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12130          test ! -s conftest.err
12131        }; then
12132   ac_header_preproc=yes
12133 else
12134   $as_echo "$as_me: failed program was:" >&5
12135 sed 's/^/| /' conftest.$ac_ext >&5
12136
12137   ac_header_preproc=no
12138 fi
12139
12140 rm -f conftest.err conftest.$ac_ext
12141 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12142 $as_echo "$ac_header_preproc" >&6; }
12143
12144 # So?  What about this header?
12145 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12146   yes:no: )
12147     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12148 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12149     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12150 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12151     ac_header_preproc=yes
12152     ;;
12153   no:yes:* )
12154     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12155 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12156     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12157 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12158     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12159 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12160     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12161 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12162     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12163 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12164     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12165 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12166     ( cat <<\_ASBOX
12167 ## ---------------------------------------- ##
12168 ## Report this to pgsql-bugs@postgresql.org ##
12169 ## ---------------------------------------- ##
12170 _ASBOX
12171      ) | sed "s/^/$as_me: WARNING:     /" >&2
12172     ;;
12173 esac
12174 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12175 $as_echo_n "checking for $ac_header... " >&6; }
12176 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12177   $as_echo_n "(cached) " >&6
12178 else
12179   eval "$as_ac_Header=\$ac_header_preproc"
12180 fi
12181 ac_res=`eval 'as_val=${'$as_ac_Header'}
12182                  $as_echo "$as_val"'`
12183                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12184 $as_echo "$ac_res" >&6; }
12185
12186 fi
12187 as_val=`eval 'as_val=${'$as_ac_Header'}
12188                  $as_echo "$as_val"'`
12189    if test "x$as_val" = x""yes; then
12190   cat >>confdefs.h <<_ACEOF
12191 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12192 _ACEOF
12193
12194 fi
12195
12196 done
12197
12198 fi
12199
12200 done
12201
12202 fi
12203
12204 done
12205
12206 fi
12207
12208 if test "$with_zlib" = yes; then
12209   if test "${ac_cv_header_zlib_h+set}" = set; then
12210   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
12211 $as_echo_n "checking for zlib.h... " >&6; }
12212 if test "${ac_cv_header_zlib_h+set}" = set; then
12213   $as_echo_n "(cached) " >&6
12214 fi
12215 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
12216 $as_echo "$ac_cv_header_zlib_h" >&6; }
12217 else
12218   # Is the header compilable?
12219 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
12220 $as_echo_n "checking zlib.h usability... " >&6; }
12221 cat >conftest.$ac_ext <<_ACEOF
12222 /* confdefs.h.  */
12223 _ACEOF
12224 cat confdefs.h >>conftest.$ac_ext
12225 cat >>conftest.$ac_ext <<_ACEOF
12226 /* end confdefs.h.  */
12227 $ac_includes_default
12228 #include <zlib.h>
12229 _ACEOF
12230 rm -f conftest.$ac_objext
12231 if { (ac_try="$ac_compile"
12232 case "(($ac_try" in
12233   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12234   *) ac_try_echo=$ac_try;;
12235 esac
12236 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12237 $as_echo "$ac_try_echo") >&5
12238   (eval "$ac_compile") 2>conftest.er1
12239   ac_status=$?
12240   grep -v '^ *+' conftest.er1 >conftest.err
12241   rm -f conftest.er1
12242   cat conftest.err >&5
12243   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12244   (exit $ac_status); } && {
12245          test -z "$ac_c_werror_flag" ||
12246          test ! -s conftest.err
12247        } && test -s conftest.$ac_objext; then
12248   ac_header_compiler=yes
12249 else
12250   $as_echo "$as_me: failed program was:" >&5
12251 sed 's/^/| /' conftest.$ac_ext >&5
12252
12253         ac_header_compiler=no
12254 fi
12255
12256 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12257 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12258 $as_echo "$ac_header_compiler" >&6; }
12259
12260 # Is the header present?
12261 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
12262 $as_echo_n "checking zlib.h presence... " >&6; }
12263 cat >conftest.$ac_ext <<_ACEOF
12264 /* confdefs.h.  */
12265 _ACEOF
12266 cat confdefs.h >>conftest.$ac_ext
12267 cat >>conftest.$ac_ext <<_ACEOF
12268 /* end confdefs.h.  */
12269 #include <zlib.h>
12270 _ACEOF
12271 if { (ac_try="$ac_cpp conftest.$ac_ext"
12272 case "(($ac_try" in
12273   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12274   *) ac_try_echo=$ac_try;;
12275 esac
12276 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12277 $as_echo "$ac_try_echo") >&5
12278   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12279   ac_status=$?
12280   grep -v '^ *+' conftest.er1 >conftest.err
12281   rm -f conftest.er1
12282   cat conftest.err >&5
12283   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12284   (exit $ac_status); } >/dev/null && {
12285          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12286          test ! -s conftest.err
12287        }; then
12288   ac_header_preproc=yes
12289 else
12290   $as_echo "$as_me: failed program was:" >&5
12291 sed 's/^/| /' conftest.$ac_ext >&5
12292
12293   ac_header_preproc=no
12294 fi
12295
12296 rm -f conftest.err conftest.$ac_ext
12297 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12298 $as_echo "$ac_header_preproc" >&6; }
12299
12300 # So?  What about this header?
12301 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12302   yes:no: )
12303     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12304 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12305     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
12306 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
12307     ac_header_preproc=yes
12308     ;;
12309   no:yes:* )
12310     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
12311 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
12312     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
12313 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
12314     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
12315 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
12316     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
12317 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12318     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
12319 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
12320     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
12321 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
12322     ( cat <<\_ASBOX
12323 ## ---------------------------------------- ##
12324 ## Report this to pgsql-bugs@postgresql.org ##
12325 ## ---------------------------------------- ##
12326 _ASBOX
12327      ) | sed "s/^/$as_me: WARNING:     /" >&2
12328     ;;
12329 esac
12330 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
12331 $as_echo_n "checking for zlib.h... " >&6; }
12332 if test "${ac_cv_header_zlib_h+set}" = set; then
12333   $as_echo_n "(cached) " >&6
12334 else
12335   ac_cv_header_zlib_h=$ac_header_preproc
12336 fi
12337 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
12338 $as_echo "$ac_cv_header_zlib_h" >&6; }
12339
12340 fi
12341 if test "x$ac_cv_header_zlib_h" = x""yes; then
12342   :
12343 else
12344   { { $as_echo "$as_me:$LINENO: error: zlib header not found
12345 If you have zlib already installed, see config.log for details on the
12346 failure.  It is possible the compiler isn't looking in the proper directory.
12347 Use --without-zlib to disable zlib support." >&5
12348 $as_echo "$as_me: error: zlib header not found
12349 If you have zlib already installed, see config.log for details on the
12350 failure.  It is possible the compiler isn't looking in the proper directory.
12351 Use --without-zlib to disable zlib support." >&2;}
12352    { (exit 1); exit 1; }; }
12353 fi
12354
12355
12356 fi
12357
12358 if test "$with_gssapi" = yes ; then
12359
12360 for ac_header in gssapi/gssapi.h
12361 do
12362 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12363 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12364   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12365 $as_echo_n "checking for $ac_header... " >&6; }
12366 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12367   $as_echo_n "(cached) " >&6
12368 fi
12369 ac_res=`eval 'as_val=${'$as_ac_Header'}
12370                  $as_echo "$as_val"'`
12371                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12372 $as_echo "$ac_res" >&6; }
12373 else
12374   # Is the header compilable?
12375 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12376 $as_echo_n "checking $ac_header usability... " >&6; }
12377 cat >conftest.$ac_ext <<_ACEOF
12378 /* confdefs.h.  */
12379 _ACEOF
12380 cat confdefs.h >>conftest.$ac_ext
12381 cat >>conftest.$ac_ext <<_ACEOF
12382 /* end confdefs.h.  */
12383 $ac_includes_default
12384 #include <$ac_header>
12385 _ACEOF
12386 rm -f conftest.$ac_objext
12387 if { (ac_try="$ac_compile"
12388 case "(($ac_try" in
12389   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12390   *) ac_try_echo=$ac_try;;
12391 esac
12392 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12393 $as_echo "$ac_try_echo") >&5
12394   (eval "$ac_compile") 2>conftest.er1
12395   ac_status=$?
12396   grep -v '^ *+' conftest.er1 >conftest.err
12397   rm -f conftest.er1
12398   cat conftest.err >&5
12399   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12400   (exit $ac_status); } && {
12401          test -z "$ac_c_werror_flag" ||
12402          test ! -s conftest.err
12403        } && test -s conftest.$ac_objext; then
12404   ac_header_compiler=yes
12405 else
12406   $as_echo "$as_me: failed program was:" >&5
12407 sed 's/^/| /' conftest.$ac_ext >&5
12408
12409         ac_header_compiler=no
12410 fi
12411
12412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12413 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12414 $as_echo "$ac_header_compiler" >&6; }
12415
12416 # Is the header present?
12417 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12418 $as_echo_n "checking $ac_header presence... " >&6; }
12419 cat >conftest.$ac_ext <<_ACEOF
12420 /* confdefs.h.  */
12421 _ACEOF
12422 cat confdefs.h >>conftest.$ac_ext
12423 cat >>conftest.$ac_ext <<_ACEOF
12424 /* end confdefs.h.  */
12425 #include <$ac_header>
12426 _ACEOF
12427 if { (ac_try="$ac_cpp conftest.$ac_ext"
12428 case "(($ac_try" in
12429   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12430   *) ac_try_echo=$ac_try;;
12431 esac
12432 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12433 $as_echo "$ac_try_echo") >&5
12434   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12435   ac_status=$?
12436   grep -v '^ *+' conftest.er1 >conftest.err
12437   rm -f conftest.er1
12438   cat conftest.err >&5
12439   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12440   (exit $ac_status); } >/dev/null && {
12441          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12442          test ! -s conftest.err
12443        }; then
12444   ac_header_preproc=yes
12445 else
12446   $as_echo "$as_me: failed program was:" >&5
12447 sed 's/^/| /' conftest.$ac_ext >&5
12448
12449   ac_header_preproc=no
12450 fi
12451
12452 rm -f conftest.err conftest.$ac_ext
12453 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12454 $as_echo "$ac_header_preproc" >&6; }
12455
12456 # So?  What about this header?
12457 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12458   yes:no: )
12459     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12460 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12461     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12462 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12463     ac_header_preproc=yes
12464     ;;
12465   no:yes:* )
12466     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12467 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12468     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12469 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12470     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12471 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12472     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12473 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12474     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12475 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12476     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12477 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12478     ( cat <<\_ASBOX
12479 ## ---------------------------------------- ##
12480 ## Report this to pgsql-bugs@postgresql.org ##
12481 ## ---------------------------------------- ##
12482 _ASBOX
12483      ) | sed "s/^/$as_me: WARNING:     /" >&2
12484     ;;
12485 esac
12486 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12487 $as_echo_n "checking for $ac_header... " >&6; }
12488 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12489   $as_echo_n "(cached) " >&6
12490 else
12491   eval "$as_ac_Header=\$ac_header_preproc"
12492 fi
12493 ac_res=`eval 'as_val=${'$as_ac_Header'}
12494                  $as_echo "$as_val"'`
12495                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12496 $as_echo "$ac_res" >&6; }
12497
12498 fi
12499 as_val=`eval 'as_val=${'$as_ac_Header'}
12500                  $as_echo "$as_val"'`
12501    if test "x$as_val" = x""yes; then
12502   cat >>confdefs.h <<_ACEOF
12503 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12504 _ACEOF
12505
12506 else
12507
12508 for ac_header in gssapi.h
12509 do
12510 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12511 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12512   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12513 $as_echo_n "checking for $ac_header... " >&6; }
12514 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12515   $as_echo_n "(cached) " >&6
12516 fi
12517 ac_res=`eval 'as_val=${'$as_ac_Header'}
12518                  $as_echo "$as_val"'`
12519                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12520 $as_echo "$ac_res" >&6; }
12521 else
12522   # Is the header compilable?
12523 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12524 $as_echo_n "checking $ac_header usability... " >&6; }
12525 cat >conftest.$ac_ext <<_ACEOF
12526 /* confdefs.h.  */
12527 _ACEOF
12528 cat confdefs.h >>conftest.$ac_ext
12529 cat >>conftest.$ac_ext <<_ACEOF
12530 /* end confdefs.h.  */
12531 $ac_includes_default
12532 #include <$ac_header>
12533 _ACEOF
12534 rm -f conftest.$ac_objext
12535 if { (ac_try="$ac_compile"
12536 case "(($ac_try" in
12537   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12538   *) ac_try_echo=$ac_try;;
12539 esac
12540 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12541 $as_echo "$ac_try_echo") >&5
12542   (eval "$ac_compile") 2>conftest.er1
12543   ac_status=$?
12544   grep -v '^ *+' conftest.er1 >conftest.err
12545   rm -f conftest.er1
12546   cat conftest.err >&5
12547   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12548   (exit $ac_status); } && {
12549          test -z "$ac_c_werror_flag" ||
12550          test ! -s conftest.err
12551        } && test -s conftest.$ac_objext; then
12552   ac_header_compiler=yes
12553 else
12554   $as_echo "$as_me: failed program was:" >&5
12555 sed 's/^/| /' conftest.$ac_ext >&5
12556
12557         ac_header_compiler=no
12558 fi
12559
12560 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12561 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12562 $as_echo "$ac_header_compiler" >&6; }
12563
12564 # Is the header present?
12565 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12566 $as_echo_n "checking $ac_header presence... " >&6; }
12567 cat >conftest.$ac_ext <<_ACEOF
12568 /* confdefs.h.  */
12569 _ACEOF
12570 cat confdefs.h >>conftest.$ac_ext
12571 cat >>conftest.$ac_ext <<_ACEOF
12572 /* end confdefs.h.  */
12573 #include <$ac_header>
12574 _ACEOF
12575 if { (ac_try="$ac_cpp conftest.$ac_ext"
12576 case "(($ac_try" in
12577   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12578   *) ac_try_echo=$ac_try;;
12579 esac
12580 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12581 $as_echo "$ac_try_echo") >&5
12582   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12583   ac_status=$?
12584   grep -v '^ *+' conftest.er1 >conftest.err
12585   rm -f conftest.er1
12586   cat conftest.err >&5
12587   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12588   (exit $ac_status); } >/dev/null && {
12589          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12590          test ! -s conftest.err
12591        }; then
12592   ac_header_preproc=yes
12593 else
12594   $as_echo "$as_me: failed program was:" >&5
12595 sed 's/^/| /' conftest.$ac_ext >&5
12596
12597   ac_header_preproc=no
12598 fi
12599
12600 rm -f conftest.err conftest.$ac_ext
12601 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12602 $as_echo "$ac_header_preproc" >&6; }
12603
12604 # So?  What about this header?
12605 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12606   yes:no: )
12607     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12608 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12609     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12610 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12611     ac_header_preproc=yes
12612     ;;
12613   no:yes:* )
12614     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12615 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12616     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12617 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12618     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12619 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12620     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12621 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12622     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12623 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12624     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12625 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12626     ( cat <<\_ASBOX
12627 ## ---------------------------------------- ##
12628 ## Report this to pgsql-bugs@postgresql.org ##
12629 ## ---------------------------------------- ##
12630 _ASBOX
12631      ) | sed "s/^/$as_me: WARNING:     /" >&2
12632     ;;
12633 esac
12634 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12635 $as_echo_n "checking for $ac_header... " >&6; }
12636 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12637   $as_echo_n "(cached) " >&6
12638 else
12639   eval "$as_ac_Header=\$ac_header_preproc"
12640 fi
12641 ac_res=`eval 'as_val=${'$as_ac_Header'}
12642                  $as_echo "$as_val"'`
12643                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12644 $as_echo "$ac_res" >&6; }
12645
12646 fi
12647 as_val=`eval 'as_val=${'$as_ac_Header'}
12648                  $as_echo "$as_val"'`
12649    if test "x$as_val" = x""yes; then
12650   cat >>confdefs.h <<_ACEOF
12651 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12652 _ACEOF
12653
12654 else
12655   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
12656 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
12657    { (exit 1); exit 1; }; }
12658 fi
12659
12660 done
12661
12662 fi
12663
12664 done
12665
12666 fi
12667
12668 if test "$with_krb5" = yes ; then
12669   if test "${ac_cv_header_krb5_h+set}" = set; then
12670   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12671 $as_echo_n "checking for krb5.h... " >&6; }
12672 if test "${ac_cv_header_krb5_h+set}" = set; then
12673   $as_echo_n "(cached) " >&6
12674 fi
12675 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12676 $as_echo "$ac_cv_header_krb5_h" >&6; }
12677 else
12678   # Is the header compilable?
12679 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
12680 $as_echo_n "checking krb5.h usability... " >&6; }
12681 cat >conftest.$ac_ext <<_ACEOF
12682 /* confdefs.h.  */
12683 _ACEOF
12684 cat confdefs.h >>conftest.$ac_ext
12685 cat >>conftest.$ac_ext <<_ACEOF
12686 /* end confdefs.h.  */
12687 $ac_includes_default
12688 #include <krb5.h>
12689 _ACEOF
12690 rm -f conftest.$ac_objext
12691 if { (ac_try="$ac_compile"
12692 case "(($ac_try" in
12693   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12694   *) ac_try_echo=$ac_try;;
12695 esac
12696 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12697 $as_echo "$ac_try_echo") >&5
12698   (eval "$ac_compile") 2>conftest.er1
12699   ac_status=$?
12700   grep -v '^ *+' conftest.er1 >conftest.err
12701   rm -f conftest.er1
12702   cat conftest.err >&5
12703   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12704   (exit $ac_status); } && {
12705          test -z "$ac_c_werror_flag" ||
12706          test ! -s conftest.err
12707        } && test -s conftest.$ac_objext; then
12708   ac_header_compiler=yes
12709 else
12710   $as_echo "$as_me: failed program was:" >&5
12711 sed 's/^/| /' conftest.$ac_ext >&5
12712
12713         ac_header_compiler=no
12714 fi
12715
12716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12717 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12718 $as_echo "$ac_header_compiler" >&6; }
12719
12720 # Is the header present?
12721 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
12722 $as_echo_n "checking krb5.h presence... " >&6; }
12723 cat >conftest.$ac_ext <<_ACEOF
12724 /* confdefs.h.  */
12725 _ACEOF
12726 cat confdefs.h >>conftest.$ac_ext
12727 cat >>conftest.$ac_ext <<_ACEOF
12728 /* end confdefs.h.  */
12729 #include <krb5.h>
12730 _ACEOF
12731 if { (ac_try="$ac_cpp conftest.$ac_ext"
12732 case "(($ac_try" in
12733   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12734   *) ac_try_echo=$ac_try;;
12735 esac
12736 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12737 $as_echo "$ac_try_echo") >&5
12738   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12739   ac_status=$?
12740   grep -v '^ *+' conftest.er1 >conftest.err
12741   rm -f conftest.er1
12742   cat conftest.err >&5
12743   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12744   (exit $ac_status); } >/dev/null && {
12745          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12746          test ! -s conftest.err
12747        }; then
12748   ac_header_preproc=yes
12749 else
12750   $as_echo "$as_me: failed program was:" >&5
12751 sed 's/^/| /' conftest.$ac_ext >&5
12752
12753   ac_header_preproc=no
12754 fi
12755
12756 rm -f conftest.err conftest.$ac_ext
12757 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12758 $as_echo "$ac_header_preproc" >&6; }
12759
12760 # So?  What about this header?
12761 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12762   yes:no: )
12763     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
12764 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12765     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
12766 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
12767     ac_header_preproc=yes
12768     ;;
12769   no:yes:* )
12770     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
12771 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
12772     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
12773 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
12774     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
12775 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
12776     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
12777 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12778     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
12779 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
12780     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
12781 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
12782     ( cat <<\_ASBOX
12783 ## ---------------------------------------- ##
12784 ## Report this to pgsql-bugs@postgresql.org ##
12785 ## ---------------------------------------- ##
12786 _ASBOX
12787      ) | sed "s/^/$as_me: WARNING:     /" >&2
12788     ;;
12789 esac
12790 { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12791 $as_echo_n "checking for krb5.h... " >&6; }
12792 if test "${ac_cv_header_krb5_h+set}" = set; then
12793   $as_echo_n "(cached) " >&6
12794 else
12795   ac_cv_header_krb5_h=$ac_header_preproc
12796 fi
12797 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12798 $as_echo "$ac_cv_header_krb5_h" >&6; }
12799
12800 fi
12801 if test "x$ac_cv_header_krb5_h" = x""yes; then
12802   :
12803 else
12804   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
12805 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
12806    { (exit 1); exit 1; }; }
12807 fi
12808
12809
12810 fi
12811
12812 if test "$with_openssl" = yes ; then
12813   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12814   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12815 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12816 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12817   $as_echo_n "(cached) " >&6
12818 fi
12819 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12820 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12821 else
12822   # Is the header compilable?
12823 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
12824 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
12825 cat >conftest.$ac_ext <<_ACEOF
12826 /* confdefs.h.  */
12827 _ACEOF
12828 cat confdefs.h >>conftest.$ac_ext
12829 cat >>conftest.$ac_ext <<_ACEOF
12830 /* end confdefs.h.  */
12831 $ac_includes_default
12832 #include <openssl/ssl.h>
12833 _ACEOF
12834 rm -f conftest.$ac_objext
12835 if { (ac_try="$ac_compile"
12836 case "(($ac_try" in
12837   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12838   *) ac_try_echo=$ac_try;;
12839 esac
12840 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12841 $as_echo "$ac_try_echo") >&5
12842   (eval "$ac_compile") 2>conftest.er1
12843   ac_status=$?
12844   grep -v '^ *+' conftest.er1 >conftest.err
12845   rm -f conftest.er1
12846   cat conftest.err >&5
12847   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12848   (exit $ac_status); } && {
12849          test -z "$ac_c_werror_flag" ||
12850          test ! -s conftest.err
12851        } && test -s conftest.$ac_objext; then
12852   ac_header_compiler=yes
12853 else
12854   $as_echo "$as_me: failed program was:" >&5
12855 sed 's/^/| /' conftest.$ac_ext >&5
12856
12857         ac_header_compiler=no
12858 fi
12859
12860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12861 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12862 $as_echo "$ac_header_compiler" >&6; }
12863
12864 # Is the header present?
12865 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
12866 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
12867 cat >conftest.$ac_ext <<_ACEOF
12868 /* confdefs.h.  */
12869 _ACEOF
12870 cat confdefs.h >>conftest.$ac_ext
12871 cat >>conftest.$ac_ext <<_ACEOF
12872 /* end confdefs.h.  */
12873 #include <openssl/ssl.h>
12874 _ACEOF
12875 if { (ac_try="$ac_cpp conftest.$ac_ext"
12876 case "(($ac_try" in
12877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12878   *) ac_try_echo=$ac_try;;
12879 esac
12880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12881 $as_echo "$ac_try_echo") >&5
12882   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12883   ac_status=$?
12884   grep -v '^ *+' conftest.er1 >conftest.err
12885   rm -f conftest.er1
12886   cat conftest.err >&5
12887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12888   (exit $ac_status); } >/dev/null && {
12889          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12890          test ! -s conftest.err
12891        }; then
12892   ac_header_preproc=yes
12893 else
12894   $as_echo "$as_me: failed program was:" >&5
12895 sed 's/^/| /' conftest.$ac_ext >&5
12896
12897   ac_header_preproc=no
12898 fi
12899
12900 rm -f conftest.err conftest.$ac_ext
12901 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12902 $as_echo "$ac_header_preproc" >&6; }
12903
12904 # So?  What about this header?
12905 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12906   yes:no: )
12907     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
12908 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12909     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
12910 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
12911     ac_header_preproc=yes
12912     ;;
12913   no:yes:* )
12914     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
12915 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
12916     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
12917 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
12918     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
12919 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
12920     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
12921 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12922     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
12923 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
12924     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
12925 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
12926     ( cat <<\_ASBOX
12927 ## ---------------------------------------- ##
12928 ## Report this to pgsql-bugs@postgresql.org ##
12929 ## ---------------------------------------- ##
12930 _ASBOX
12931      ) | sed "s/^/$as_me: WARNING:     /" >&2
12932     ;;
12933 esac
12934 { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12935 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12936 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12937   $as_echo_n "(cached) " >&6
12938 else
12939   ac_cv_header_openssl_ssl_h=$ac_header_preproc
12940 fi
12941 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12942 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12943
12944 fi
12945 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
12946   :
12947 else
12948   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
12949 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
12950    { (exit 1); exit 1; }; }
12951 fi
12952
12953
12954   if test "${ac_cv_header_openssl_err_h+set}" = set; then
12955   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12956 $as_echo_n "checking for openssl/err.h... " >&6; }
12957 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12958   $as_echo_n "(cached) " >&6
12959 fi
12960 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12961 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12962 else
12963   # Is the header compilable?
12964 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
12965 $as_echo_n "checking openssl/err.h usability... " >&6; }
12966 cat >conftest.$ac_ext <<_ACEOF
12967 /* confdefs.h.  */
12968 _ACEOF
12969 cat confdefs.h >>conftest.$ac_ext
12970 cat >>conftest.$ac_ext <<_ACEOF
12971 /* end confdefs.h.  */
12972 $ac_includes_default
12973 #include <openssl/err.h>
12974 _ACEOF
12975 rm -f conftest.$ac_objext
12976 if { (ac_try="$ac_compile"
12977 case "(($ac_try" in
12978   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12979   *) ac_try_echo=$ac_try;;
12980 esac
12981 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12982 $as_echo "$ac_try_echo") >&5
12983   (eval "$ac_compile") 2>conftest.er1
12984   ac_status=$?
12985   grep -v '^ *+' conftest.er1 >conftest.err
12986   rm -f conftest.er1
12987   cat conftest.err >&5
12988   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12989   (exit $ac_status); } && {
12990          test -z "$ac_c_werror_flag" ||
12991          test ! -s conftest.err
12992        } && test -s conftest.$ac_objext; then
12993   ac_header_compiler=yes
12994 else
12995   $as_echo "$as_me: failed program was:" >&5
12996 sed 's/^/| /' conftest.$ac_ext >&5
12997
12998         ac_header_compiler=no
12999 fi
13000
13001 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13002 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13003 $as_echo "$ac_header_compiler" >&6; }
13004
13005 # Is the header present?
13006 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
13007 $as_echo_n "checking openssl/err.h presence... " >&6; }
13008 cat >conftest.$ac_ext <<_ACEOF
13009 /* confdefs.h.  */
13010 _ACEOF
13011 cat confdefs.h >>conftest.$ac_ext
13012 cat >>conftest.$ac_ext <<_ACEOF
13013 /* end confdefs.h.  */
13014 #include <openssl/err.h>
13015 _ACEOF
13016 if { (ac_try="$ac_cpp conftest.$ac_ext"
13017 case "(($ac_try" in
13018   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13019   *) ac_try_echo=$ac_try;;
13020 esac
13021 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13022 $as_echo "$ac_try_echo") >&5
13023   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13024   ac_status=$?
13025   grep -v '^ *+' conftest.er1 >conftest.err
13026   rm -f conftest.er1
13027   cat conftest.err >&5
13028   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13029   (exit $ac_status); } >/dev/null && {
13030          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13031          test ! -s conftest.err
13032        }; then
13033   ac_header_preproc=yes
13034 else
13035   $as_echo "$as_me: failed program was:" >&5
13036 sed 's/^/| /' conftest.$ac_ext >&5
13037
13038   ac_header_preproc=no
13039 fi
13040
13041 rm -f conftest.err conftest.$ac_ext
13042 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13043 $as_echo "$ac_header_preproc" >&6; }
13044
13045 # So?  What about this header?
13046 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13047   yes:no: )
13048     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
13049 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13050     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
13051 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
13052     ac_header_preproc=yes
13053     ;;
13054   no:yes:* )
13055     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
13056 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
13057     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
13058 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
13059     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
13060 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
13061     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
13062 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13063     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
13064 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
13065     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
13066 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
13067     ( cat <<\_ASBOX
13068 ## ---------------------------------------- ##
13069 ## Report this to pgsql-bugs@postgresql.org ##
13070 ## ---------------------------------------- ##
13071 _ASBOX
13072      ) | sed "s/^/$as_me: WARNING:     /" >&2
13073     ;;
13074 esac
13075 { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
13076 $as_echo_n "checking for openssl/err.h... " >&6; }
13077 if test "${ac_cv_header_openssl_err_h+set}" = set; then
13078   $as_echo_n "(cached) " >&6
13079 else
13080   ac_cv_header_openssl_err_h=$ac_header_preproc
13081 fi
13082 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
13083 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
13084
13085 fi
13086 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
13087   :
13088 else
13089   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
13090 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
13091    { (exit 1); exit 1; }; }
13092 fi
13093
13094
13095 fi
13096
13097 if test "$with_pam" = yes ; then
13098
13099 for ac_header in security/pam_appl.h
13100 do
13101 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13102 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13103   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13104 $as_echo_n "checking for $ac_header... " >&6; }
13105 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13106   $as_echo_n "(cached) " >&6
13107 fi
13108 ac_res=`eval 'as_val=${'$as_ac_Header'}
13109                  $as_echo "$as_val"'`
13110                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13111 $as_echo "$ac_res" >&6; }
13112 else
13113   # Is the header compilable?
13114 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13115 $as_echo_n "checking $ac_header usability... " >&6; }
13116 cat >conftest.$ac_ext <<_ACEOF
13117 /* confdefs.h.  */
13118 _ACEOF
13119 cat confdefs.h >>conftest.$ac_ext
13120 cat >>conftest.$ac_ext <<_ACEOF
13121 /* end confdefs.h.  */
13122 $ac_includes_default
13123 #include <$ac_header>
13124 _ACEOF
13125 rm -f conftest.$ac_objext
13126 if { (ac_try="$ac_compile"
13127 case "(($ac_try" in
13128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13129   *) ac_try_echo=$ac_try;;
13130 esac
13131 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13132 $as_echo "$ac_try_echo") >&5
13133   (eval "$ac_compile") 2>conftest.er1
13134   ac_status=$?
13135   grep -v '^ *+' conftest.er1 >conftest.err
13136   rm -f conftest.er1
13137   cat conftest.err >&5
13138   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13139   (exit $ac_status); } && {
13140          test -z "$ac_c_werror_flag" ||
13141          test ! -s conftest.err
13142        } && test -s conftest.$ac_objext; then
13143   ac_header_compiler=yes
13144 else
13145   $as_echo "$as_me: failed program was:" >&5
13146 sed 's/^/| /' conftest.$ac_ext >&5
13147
13148         ac_header_compiler=no
13149 fi
13150
13151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13152 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13153 $as_echo "$ac_header_compiler" >&6; }
13154
13155 # Is the header present?
13156 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13157 $as_echo_n "checking $ac_header presence... " >&6; }
13158 cat >conftest.$ac_ext <<_ACEOF
13159 /* confdefs.h.  */
13160 _ACEOF
13161 cat confdefs.h >>conftest.$ac_ext
13162 cat >>conftest.$ac_ext <<_ACEOF
13163 /* end confdefs.h.  */
13164 #include <$ac_header>
13165 _ACEOF
13166 if { (ac_try="$ac_cpp conftest.$ac_ext"
13167 case "(($ac_try" in
13168   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13169   *) ac_try_echo=$ac_try;;
13170 esac
13171 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13172 $as_echo "$ac_try_echo") >&5
13173   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13174   ac_status=$?
13175   grep -v '^ *+' conftest.er1 >conftest.err
13176   rm -f conftest.er1
13177   cat conftest.err >&5
13178   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13179   (exit $ac_status); } >/dev/null && {
13180          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13181          test ! -s conftest.err
13182        }; then
13183   ac_header_preproc=yes
13184 else
13185   $as_echo "$as_me: failed program was:" >&5
13186 sed 's/^/| /' conftest.$ac_ext >&5
13187
13188   ac_header_preproc=no
13189 fi
13190
13191 rm -f conftest.err conftest.$ac_ext
13192 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13193 $as_echo "$ac_header_preproc" >&6; }
13194
13195 # So?  What about this header?
13196 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13197   yes:no: )
13198     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13199 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13200     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13201 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13202     ac_header_preproc=yes
13203     ;;
13204   no:yes:* )
13205     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13206 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13207     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13208 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13209     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13210 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13211     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13212 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13213     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13214 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13215     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13216 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13217     ( cat <<\_ASBOX
13218 ## ---------------------------------------- ##
13219 ## Report this to pgsql-bugs@postgresql.org ##
13220 ## ---------------------------------------- ##
13221 _ASBOX
13222      ) | sed "s/^/$as_me: WARNING:     /" >&2
13223     ;;
13224 esac
13225 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13226 $as_echo_n "checking for $ac_header... " >&6; }
13227 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13228   $as_echo_n "(cached) " >&6
13229 else
13230   eval "$as_ac_Header=\$ac_header_preproc"
13231 fi
13232 ac_res=`eval 'as_val=${'$as_ac_Header'}
13233                  $as_echo "$as_val"'`
13234                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13235 $as_echo "$ac_res" >&6; }
13236
13237 fi
13238 as_val=`eval 'as_val=${'$as_ac_Header'}
13239                  $as_echo "$as_val"'`
13240    if test "x$as_val" = x""yes; then
13241   cat >>confdefs.h <<_ACEOF
13242 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13243 _ACEOF
13244
13245 else
13246
13247 for ac_header in pam/pam_appl.h
13248 do
13249 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13250 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13251   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13252 $as_echo_n "checking for $ac_header... " >&6; }
13253 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13254   $as_echo_n "(cached) " >&6
13255 fi
13256 ac_res=`eval 'as_val=${'$as_ac_Header'}
13257                  $as_echo "$as_val"'`
13258                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13259 $as_echo "$ac_res" >&6; }
13260 else
13261   # Is the header compilable?
13262 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13263 $as_echo_n "checking $ac_header usability... " >&6; }
13264 cat >conftest.$ac_ext <<_ACEOF
13265 /* confdefs.h.  */
13266 _ACEOF
13267 cat confdefs.h >>conftest.$ac_ext
13268 cat >>conftest.$ac_ext <<_ACEOF
13269 /* end confdefs.h.  */
13270 $ac_includes_default
13271 #include <$ac_header>
13272 _ACEOF
13273 rm -f conftest.$ac_objext
13274 if { (ac_try="$ac_compile"
13275 case "(($ac_try" in
13276   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13277   *) ac_try_echo=$ac_try;;
13278 esac
13279 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13280 $as_echo "$ac_try_echo") >&5
13281   (eval "$ac_compile") 2>conftest.er1
13282   ac_status=$?
13283   grep -v '^ *+' conftest.er1 >conftest.err
13284   rm -f conftest.er1
13285   cat conftest.err >&5
13286   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13287   (exit $ac_status); } && {
13288          test -z "$ac_c_werror_flag" ||
13289          test ! -s conftest.err
13290        } && test -s conftest.$ac_objext; then
13291   ac_header_compiler=yes
13292 else
13293   $as_echo "$as_me: failed program was:" >&5
13294 sed 's/^/| /' conftest.$ac_ext >&5
13295
13296         ac_header_compiler=no
13297 fi
13298
13299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13300 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13301 $as_echo "$ac_header_compiler" >&6; }
13302
13303 # Is the header present?
13304 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13305 $as_echo_n "checking $ac_header presence... " >&6; }
13306 cat >conftest.$ac_ext <<_ACEOF
13307 /* confdefs.h.  */
13308 _ACEOF
13309 cat confdefs.h >>conftest.$ac_ext
13310 cat >>conftest.$ac_ext <<_ACEOF
13311 /* end confdefs.h.  */
13312 #include <$ac_header>
13313 _ACEOF
13314 if { (ac_try="$ac_cpp conftest.$ac_ext"
13315 case "(($ac_try" in
13316   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13317   *) ac_try_echo=$ac_try;;
13318 esac
13319 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13320 $as_echo "$ac_try_echo") >&5
13321   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13322   ac_status=$?
13323   grep -v '^ *+' conftest.er1 >conftest.err
13324   rm -f conftest.er1
13325   cat conftest.err >&5
13326   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13327   (exit $ac_status); } >/dev/null && {
13328          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13329          test ! -s conftest.err
13330        }; then
13331   ac_header_preproc=yes
13332 else
13333   $as_echo "$as_me: failed program was:" >&5
13334 sed 's/^/| /' conftest.$ac_ext >&5
13335
13336   ac_header_preproc=no
13337 fi
13338
13339 rm -f conftest.err conftest.$ac_ext
13340 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13341 $as_echo "$ac_header_preproc" >&6; }
13342
13343 # So?  What about this header?
13344 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13345   yes:no: )
13346     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13347 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13348     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13349 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13350     ac_header_preproc=yes
13351     ;;
13352   no:yes:* )
13353     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13354 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13355     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13356 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13357     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13358 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13359     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13360 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13361     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13362 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13363     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13364 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13365     ( cat <<\_ASBOX
13366 ## ---------------------------------------- ##
13367 ## Report this to pgsql-bugs@postgresql.org ##
13368 ## ---------------------------------------- ##
13369 _ASBOX
13370      ) | sed "s/^/$as_me: WARNING:     /" >&2
13371     ;;
13372 esac
13373 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13374 $as_echo_n "checking for $ac_header... " >&6; }
13375 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13376   $as_echo_n "(cached) " >&6
13377 else
13378   eval "$as_ac_Header=\$ac_header_preproc"
13379 fi
13380 ac_res=`eval 'as_val=${'$as_ac_Header'}
13381                  $as_echo "$as_val"'`
13382                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13383 $as_echo "$ac_res" >&6; }
13384
13385 fi
13386 as_val=`eval 'as_val=${'$as_ac_Header'}
13387                  $as_echo "$as_val"'`
13388    if test "x$as_val" = x""yes; then
13389   cat >>confdefs.h <<_ACEOF
13390 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13391 _ACEOF
13392
13393 else
13394   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
13395 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
13396    { (exit 1); exit 1; }; }
13397 fi
13398
13399 done
13400
13401 fi
13402
13403 done
13404
13405 fi
13406
13407 if test "$with_libxml" = yes ; then
13408   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13409   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13410 $as_echo_n "checking for libxml/parser.h... " >&6; }
13411 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13412   $as_echo_n "(cached) " >&6
13413 fi
13414 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13415 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13416 else
13417   # Is the header compilable?
13418 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
13419 $as_echo_n "checking libxml/parser.h usability... " >&6; }
13420 cat >conftest.$ac_ext <<_ACEOF
13421 /* confdefs.h.  */
13422 _ACEOF
13423 cat confdefs.h >>conftest.$ac_ext
13424 cat >>conftest.$ac_ext <<_ACEOF
13425 /* end confdefs.h.  */
13426 $ac_includes_default
13427 #include <libxml/parser.h>
13428 _ACEOF
13429 rm -f conftest.$ac_objext
13430 if { (ac_try="$ac_compile"
13431 case "(($ac_try" in
13432   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13433   *) ac_try_echo=$ac_try;;
13434 esac
13435 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13436 $as_echo "$ac_try_echo") >&5
13437   (eval "$ac_compile") 2>conftest.er1
13438   ac_status=$?
13439   grep -v '^ *+' conftest.er1 >conftest.err
13440   rm -f conftest.er1
13441   cat conftest.err >&5
13442   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13443   (exit $ac_status); } && {
13444          test -z "$ac_c_werror_flag" ||
13445          test ! -s conftest.err
13446        } && test -s conftest.$ac_objext; then
13447   ac_header_compiler=yes
13448 else
13449   $as_echo "$as_me: failed program was:" >&5
13450 sed 's/^/| /' conftest.$ac_ext >&5
13451
13452         ac_header_compiler=no
13453 fi
13454
13455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13456 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13457 $as_echo "$ac_header_compiler" >&6; }
13458
13459 # Is the header present?
13460 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
13461 $as_echo_n "checking libxml/parser.h presence... " >&6; }
13462 cat >conftest.$ac_ext <<_ACEOF
13463 /* confdefs.h.  */
13464 _ACEOF
13465 cat confdefs.h >>conftest.$ac_ext
13466 cat >>conftest.$ac_ext <<_ACEOF
13467 /* end confdefs.h.  */
13468 #include <libxml/parser.h>
13469 _ACEOF
13470 if { (ac_try="$ac_cpp conftest.$ac_ext"
13471 case "(($ac_try" in
13472   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13473   *) ac_try_echo=$ac_try;;
13474 esac
13475 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13476 $as_echo "$ac_try_echo") >&5
13477   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13478   ac_status=$?
13479   grep -v '^ *+' conftest.er1 >conftest.err
13480   rm -f conftest.er1
13481   cat conftest.err >&5
13482   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13483   (exit $ac_status); } >/dev/null && {
13484          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13485          test ! -s conftest.err
13486        }; then
13487   ac_header_preproc=yes
13488 else
13489   $as_echo "$as_me: failed program was:" >&5
13490 sed 's/^/| /' conftest.$ac_ext >&5
13491
13492   ac_header_preproc=no
13493 fi
13494
13495 rm -f conftest.err conftest.$ac_ext
13496 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13497 $as_echo "$ac_header_preproc" >&6; }
13498
13499 # So?  What about this header?
13500 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13501   yes:no: )
13502     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13503 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13504     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13505 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13506     ac_header_preproc=yes
13507     ;;
13508   no:yes:* )
13509     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13510 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13511     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13512 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13513     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13514 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13515     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13516 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13517     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13518 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13519     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13520 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13521     ( cat <<\_ASBOX
13522 ## ---------------------------------------- ##
13523 ## Report this to pgsql-bugs@postgresql.org ##
13524 ## ---------------------------------------- ##
13525 _ASBOX
13526      ) | sed "s/^/$as_me: WARNING:     /" >&2
13527     ;;
13528 esac
13529 { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13530 $as_echo_n "checking for libxml/parser.h... " >&6; }
13531 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13532   $as_echo_n "(cached) " >&6
13533 else
13534   ac_cv_header_libxml_parser_h=$ac_header_preproc
13535 fi
13536 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13537 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13538
13539 fi
13540 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13541   :
13542 else
13543   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13544 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13545    { (exit 1); exit 1; }; }
13546 fi
13547
13548
13549 fi
13550
13551 if test "$with_libxslt" = yes ; then
13552   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13553   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13554 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13555 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13556   $as_echo_n "(cached) " >&6
13557 fi
13558 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13559 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13560 else
13561   # Is the header compilable?
13562 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13563 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13564 cat >conftest.$ac_ext <<_ACEOF
13565 /* confdefs.h.  */
13566 _ACEOF
13567 cat confdefs.h >>conftest.$ac_ext
13568 cat >>conftest.$ac_ext <<_ACEOF
13569 /* end confdefs.h.  */
13570 $ac_includes_default
13571 #include <libxslt/xslt.h>
13572 _ACEOF
13573 rm -f conftest.$ac_objext
13574 if { (ac_try="$ac_compile"
13575 case "(($ac_try" in
13576   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13577   *) ac_try_echo=$ac_try;;
13578 esac
13579 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13580 $as_echo "$ac_try_echo") >&5
13581   (eval "$ac_compile") 2>conftest.er1
13582   ac_status=$?
13583   grep -v '^ *+' conftest.er1 >conftest.err
13584   rm -f conftest.er1
13585   cat conftest.err >&5
13586   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13587   (exit $ac_status); } && {
13588          test -z "$ac_c_werror_flag" ||
13589          test ! -s conftest.err
13590        } && test -s conftest.$ac_objext; then
13591   ac_header_compiler=yes
13592 else
13593   $as_echo "$as_me: failed program was:" >&5
13594 sed 's/^/| /' conftest.$ac_ext >&5
13595
13596         ac_header_compiler=no
13597 fi
13598
13599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13600 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13601 $as_echo "$ac_header_compiler" >&6; }
13602
13603 # Is the header present?
13604 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13605 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13606 cat >conftest.$ac_ext <<_ACEOF
13607 /* confdefs.h.  */
13608 _ACEOF
13609 cat confdefs.h >>conftest.$ac_ext
13610 cat >>conftest.$ac_ext <<_ACEOF
13611 /* end confdefs.h.  */
13612 #include <libxslt/xslt.h>
13613 _ACEOF
13614 if { (ac_try="$ac_cpp conftest.$ac_ext"
13615 case "(($ac_try" in
13616   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13617   *) ac_try_echo=$ac_try;;
13618 esac
13619 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13620 $as_echo "$ac_try_echo") >&5
13621   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13622   ac_status=$?
13623   grep -v '^ *+' conftest.er1 >conftest.err
13624   rm -f conftest.er1
13625   cat conftest.err >&5
13626   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13627   (exit $ac_status); } >/dev/null && {
13628          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13629          test ! -s conftest.err
13630        }; then
13631   ac_header_preproc=yes
13632 else
13633   $as_echo "$as_me: failed program was:" >&5
13634 sed 's/^/| /' conftest.$ac_ext >&5
13635
13636   ac_header_preproc=no
13637 fi
13638
13639 rm -f conftest.err conftest.$ac_ext
13640 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13641 $as_echo "$ac_header_preproc" >&6; }
13642
13643 # So?  What about this header?
13644 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13645   yes:no: )
13646     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
13647 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13648     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
13649 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
13650     ac_header_preproc=yes
13651     ;;
13652   no:yes:* )
13653     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
13654 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
13655     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
13656 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
13657     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
13658 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
13659     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
13660 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13661     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
13662 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
13663     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
13664 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
13665     ( cat <<\_ASBOX
13666 ## ---------------------------------------- ##
13667 ## Report this to pgsql-bugs@postgresql.org ##
13668 ## ---------------------------------------- ##
13669 _ASBOX
13670      ) | sed "s/^/$as_me: WARNING:     /" >&2
13671     ;;
13672 esac
13673 { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13674 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13675 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13676   $as_echo_n "(cached) " >&6
13677 else
13678   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
13679 fi
13680 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13681 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13682
13683 fi
13684 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
13685   :
13686 else
13687   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
13688 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
13689    { (exit 1); exit 1; }; }
13690 fi
13691
13692
13693 fi
13694
13695 if test "$with_ldap" = yes ; then
13696   if test "$PORTNAME" != "win32"; then
13697
13698 for ac_header in ldap.h
13699 do
13700 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13701 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13702   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13703 $as_echo_n "checking for $ac_header... " >&6; }
13704 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13705   $as_echo_n "(cached) " >&6
13706 fi
13707 ac_res=`eval 'as_val=${'$as_ac_Header'}
13708                  $as_echo "$as_val"'`
13709                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13710 $as_echo "$ac_res" >&6; }
13711 else
13712   # Is the header compilable?
13713 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13714 $as_echo_n "checking $ac_header usability... " >&6; }
13715 cat >conftest.$ac_ext <<_ACEOF
13716 /* confdefs.h.  */
13717 _ACEOF
13718 cat confdefs.h >>conftest.$ac_ext
13719 cat >>conftest.$ac_ext <<_ACEOF
13720 /* end confdefs.h.  */
13721 $ac_includes_default
13722 #include <$ac_header>
13723 _ACEOF
13724 rm -f conftest.$ac_objext
13725 if { (ac_try="$ac_compile"
13726 case "(($ac_try" in
13727   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13728   *) ac_try_echo=$ac_try;;
13729 esac
13730 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13731 $as_echo "$ac_try_echo") >&5
13732   (eval "$ac_compile") 2>conftest.er1
13733   ac_status=$?
13734   grep -v '^ *+' conftest.er1 >conftest.err
13735   rm -f conftest.er1
13736   cat conftest.err >&5
13737   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13738   (exit $ac_status); } && {
13739          test -z "$ac_c_werror_flag" ||
13740          test ! -s conftest.err
13741        } && test -s conftest.$ac_objext; then
13742   ac_header_compiler=yes
13743 else
13744   $as_echo "$as_me: failed program was:" >&5
13745 sed 's/^/| /' conftest.$ac_ext >&5
13746
13747         ac_header_compiler=no
13748 fi
13749
13750 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13751 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13752 $as_echo "$ac_header_compiler" >&6; }
13753
13754 # Is the header present?
13755 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13756 $as_echo_n "checking $ac_header presence... " >&6; }
13757 cat >conftest.$ac_ext <<_ACEOF
13758 /* confdefs.h.  */
13759 _ACEOF
13760 cat confdefs.h >>conftest.$ac_ext
13761 cat >>conftest.$ac_ext <<_ACEOF
13762 /* end confdefs.h.  */
13763 #include <$ac_header>
13764 _ACEOF
13765 if { (ac_try="$ac_cpp conftest.$ac_ext"
13766 case "(($ac_try" in
13767   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13768   *) ac_try_echo=$ac_try;;
13769 esac
13770 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13771 $as_echo "$ac_try_echo") >&5
13772   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13773   ac_status=$?
13774   grep -v '^ *+' conftest.er1 >conftest.err
13775   rm -f conftest.er1
13776   cat conftest.err >&5
13777   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13778   (exit $ac_status); } >/dev/null && {
13779          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13780          test ! -s conftest.err
13781        }; then
13782   ac_header_preproc=yes
13783 else
13784   $as_echo "$as_me: failed program was:" >&5
13785 sed 's/^/| /' conftest.$ac_ext >&5
13786
13787   ac_header_preproc=no
13788 fi
13789
13790 rm -f conftest.err conftest.$ac_ext
13791 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13792 $as_echo "$ac_header_preproc" >&6; }
13793
13794 # So?  What about this header?
13795 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13796   yes:no: )
13797     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13798 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13799     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13800 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13801     ac_header_preproc=yes
13802     ;;
13803   no:yes:* )
13804     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13805 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13806     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13807 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13808     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13809 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13810     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13811 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13812     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13813 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13814     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13815 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13816     ( cat <<\_ASBOX
13817 ## ---------------------------------------- ##
13818 ## Report this to pgsql-bugs@postgresql.org ##
13819 ## ---------------------------------------- ##
13820 _ASBOX
13821      ) | sed "s/^/$as_me: WARNING:     /" >&2
13822     ;;
13823 esac
13824 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13825 $as_echo_n "checking for $ac_header... " >&6; }
13826 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13827   $as_echo_n "(cached) " >&6
13828 else
13829   eval "$as_ac_Header=\$ac_header_preproc"
13830 fi
13831 ac_res=`eval 'as_val=${'$as_ac_Header'}
13832                  $as_echo "$as_val"'`
13833                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13834 $as_echo "$ac_res" >&6; }
13835
13836 fi
13837 as_val=`eval 'as_val=${'$as_ac_Header'}
13838                  $as_echo "$as_val"'`
13839    if test "x$as_val" = x""yes; then
13840   cat >>confdefs.h <<_ACEOF
13841 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13842 _ACEOF
13843
13844 else
13845   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
13846 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
13847    { (exit 1); exit 1; }; }
13848 fi
13849
13850 done
13851
13852   else
13853
13854 for ac_header in winldap.h
13855 do
13856 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13857 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13858 $as_echo_n "checking for $ac_header... " >&6; }
13859 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13860   $as_echo_n "(cached) " >&6
13861 else
13862   cat >conftest.$ac_ext <<_ACEOF
13863 /* confdefs.h.  */
13864 _ACEOF
13865 cat confdefs.h >>conftest.$ac_ext
13866 cat >>conftest.$ac_ext <<_ACEOF
13867 /* end confdefs.h.  */
13868 $ac_includes_default
13869 #include <windows.h>
13870
13871
13872 #include <$ac_header>
13873 _ACEOF
13874 rm -f conftest.$ac_objext
13875 if { (ac_try="$ac_compile"
13876 case "(($ac_try" in
13877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13878   *) ac_try_echo=$ac_try;;
13879 esac
13880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13881 $as_echo "$ac_try_echo") >&5
13882   (eval "$ac_compile") 2>conftest.er1
13883   ac_status=$?
13884   grep -v '^ *+' conftest.er1 >conftest.err
13885   rm -f conftest.er1
13886   cat conftest.err >&5
13887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13888   (exit $ac_status); } && {
13889          test -z "$ac_c_werror_flag" ||
13890          test ! -s conftest.err
13891        } && test -s conftest.$ac_objext; then
13892   eval "$as_ac_Header=yes"
13893 else
13894   $as_echo "$as_me: failed program was:" >&5
13895 sed 's/^/| /' conftest.$ac_ext >&5
13896
13897         eval "$as_ac_Header=no"
13898 fi
13899
13900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13901 fi
13902 ac_res=`eval 'as_val=${'$as_ac_Header'}
13903                  $as_echo "$as_val"'`
13904                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13905 $as_echo "$ac_res" >&6; }
13906 as_val=`eval 'as_val=${'$as_ac_Header'}
13907                  $as_echo "$as_val"'`
13908    if test "x$as_val" = x""yes; then
13909   cat >>confdefs.h <<_ACEOF
13910 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13911 _ACEOF
13912
13913 else
13914   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
13915 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
13916    { (exit 1); exit 1; }; }
13917 fi
13918
13919 done
13920
13921   fi
13922 fi
13923
13924 if test "$with_bonjour" = yes ; then
13925   if test "${ac_cv_header_dns_sd_h+set}" = set; then
13926   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13927 $as_echo_n "checking for dns_sd.h... " >&6; }
13928 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13929   $as_echo_n "(cached) " >&6
13930 fi
13931 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13932 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13933 else
13934   # Is the header compilable?
13935 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
13936 $as_echo_n "checking dns_sd.h usability... " >&6; }
13937 cat >conftest.$ac_ext <<_ACEOF
13938 /* confdefs.h.  */
13939 _ACEOF
13940 cat confdefs.h >>conftest.$ac_ext
13941 cat >>conftest.$ac_ext <<_ACEOF
13942 /* end confdefs.h.  */
13943 $ac_includes_default
13944 #include <dns_sd.h>
13945 _ACEOF
13946 rm -f conftest.$ac_objext
13947 if { (ac_try="$ac_compile"
13948 case "(($ac_try" in
13949   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13950   *) ac_try_echo=$ac_try;;
13951 esac
13952 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13953 $as_echo "$ac_try_echo") >&5
13954   (eval "$ac_compile") 2>conftest.er1
13955   ac_status=$?
13956   grep -v '^ *+' conftest.er1 >conftest.err
13957   rm -f conftest.er1
13958   cat conftest.err >&5
13959   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13960   (exit $ac_status); } && {
13961          test -z "$ac_c_werror_flag" ||
13962          test ! -s conftest.err
13963        } && test -s conftest.$ac_objext; then
13964   ac_header_compiler=yes
13965 else
13966   $as_echo "$as_me: failed program was:" >&5
13967 sed 's/^/| /' conftest.$ac_ext >&5
13968
13969         ac_header_compiler=no
13970 fi
13971
13972 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13973 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13974 $as_echo "$ac_header_compiler" >&6; }
13975
13976 # Is the header present?
13977 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
13978 $as_echo_n "checking dns_sd.h presence... " >&6; }
13979 cat >conftest.$ac_ext <<_ACEOF
13980 /* confdefs.h.  */
13981 _ACEOF
13982 cat confdefs.h >>conftest.$ac_ext
13983 cat >>conftest.$ac_ext <<_ACEOF
13984 /* end confdefs.h.  */
13985 #include <dns_sd.h>
13986 _ACEOF
13987 if { (ac_try="$ac_cpp conftest.$ac_ext"
13988 case "(($ac_try" in
13989   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13990   *) ac_try_echo=$ac_try;;
13991 esac
13992 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13993 $as_echo "$ac_try_echo") >&5
13994   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13995   ac_status=$?
13996   grep -v '^ *+' conftest.er1 >conftest.err
13997   rm -f conftest.er1
13998   cat conftest.err >&5
13999   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14000   (exit $ac_status); } >/dev/null && {
14001          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14002          test ! -s conftest.err
14003        }; then
14004   ac_header_preproc=yes
14005 else
14006   $as_echo "$as_me: failed program was:" >&5
14007 sed 's/^/| /' conftest.$ac_ext >&5
14008
14009   ac_header_preproc=no
14010 fi
14011
14012 rm -f conftest.err conftest.$ac_ext
14013 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14014 $as_echo "$ac_header_preproc" >&6; }
14015
14016 # So?  What about this header?
14017 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14018   yes:no: )
14019     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
14020 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14021     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
14022 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
14023     ac_header_preproc=yes
14024     ;;
14025   no:yes:* )
14026     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
14027 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
14028     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
14029 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
14030     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
14031 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
14032     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
14033 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
14034     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
14035 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
14036     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
14037 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
14038     ( cat <<\_ASBOX
14039 ## ---------------------------------------- ##
14040 ## Report this to pgsql-bugs@postgresql.org ##
14041 ## ---------------------------------------- ##
14042 _ASBOX
14043      ) | sed "s/^/$as_me: WARNING:     /" >&2
14044     ;;
14045 esac
14046 { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
14047 $as_echo_n "checking for dns_sd.h... " >&6; }
14048 if test "${ac_cv_header_dns_sd_h+set}" = set; then
14049   $as_echo_n "(cached) " >&6
14050 else
14051   ac_cv_header_dns_sd_h=$ac_header_preproc
14052 fi
14053 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
14054 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
14055
14056 fi
14057 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
14058   :
14059 else
14060   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
14061 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
14062    { (exit 1); exit 1; }; }
14063 fi
14064
14065
14066 fi
14067
14068 # for contrib/uuid-ossp
14069 if test "$with_ossp_uuid" = yes ; then
14070
14071 for ac_header in ossp/uuid.h
14072 do
14073 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14074 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14075   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14076 $as_echo_n "checking for $ac_header... " >&6; }
14077 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14078   $as_echo_n "(cached) " >&6
14079 fi
14080 ac_res=`eval 'as_val=${'$as_ac_Header'}
14081                  $as_echo "$as_val"'`
14082                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14083 $as_echo "$ac_res" >&6; }
14084 else
14085   # Is the header compilable?
14086 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14087 $as_echo_n "checking $ac_header usability... " >&6; }
14088 cat >conftest.$ac_ext <<_ACEOF
14089 /* confdefs.h.  */
14090 _ACEOF
14091 cat confdefs.h >>conftest.$ac_ext
14092 cat >>conftest.$ac_ext <<_ACEOF
14093 /* end confdefs.h.  */
14094 $ac_includes_default
14095 #include <$ac_header>
14096 _ACEOF
14097 rm -f conftest.$ac_objext
14098 if { (ac_try="$ac_compile"
14099 case "(($ac_try" in
14100   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14101   *) ac_try_echo=$ac_try;;
14102 esac
14103 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14104 $as_echo "$ac_try_echo") >&5
14105   (eval "$ac_compile") 2>conftest.er1
14106   ac_status=$?
14107   grep -v '^ *+' conftest.er1 >conftest.err
14108   rm -f conftest.er1
14109   cat conftest.err >&5
14110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14111   (exit $ac_status); } && {
14112          test -z "$ac_c_werror_flag" ||
14113          test ! -s conftest.err
14114        } && test -s conftest.$ac_objext; then
14115   ac_header_compiler=yes
14116 else
14117   $as_echo "$as_me: failed program was:" >&5
14118 sed 's/^/| /' conftest.$ac_ext >&5
14119
14120         ac_header_compiler=no
14121 fi
14122
14123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14124 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14125 $as_echo "$ac_header_compiler" >&6; }
14126
14127 # Is the header present?
14128 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14129 $as_echo_n "checking $ac_header presence... " >&6; }
14130 cat >conftest.$ac_ext <<_ACEOF
14131 /* confdefs.h.  */
14132 _ACEOF
14133 cat confdefs.h >>conftest.$ac_ext
14134 cat >>conftest.$ac_ext <<_ACEOF
14135 /* end confdefs.h.  */
14136 #include <$ac_header>
14137 _ACEOF
14138 if { (ac_try="$ac_cpp conftest.$ac_ext"
14139 case "(($ac_try" in
14140   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14141   *) ac_try_echo=$ac_try;;
14142 esac
14143 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14144 $as_echo "$ac_try_echo") >&5
14145   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14146   ac_status=$?
14147   grep -v '^ *+' conftest.er1 >conftest.err
14148   rm -f conftest.er1
14149   cat conftest.err >&5
14150   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14151   (exit $ac_status); } >/dev/null && {
14152          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14153          test ! -s conftest.err
14154        }; then
14155   ac_header_preproc=yes
14156 else
14157   $as_echo "$as_me: failed program was:" >&5
14158 sed 's/^/| /' conftest.$ac_ext >&5
14159
14160   ac_header_preproc=no
14161 fi
14162
14163 rm -f conftest.err conftest.$ac_ext
14164 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14165 $as_echo "$ac_header_preproc" >&6; }
14166
14167 # So?  What about this header?
14168 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14169   yes:no: )
14170     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14171 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14172     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14173 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14174     ac_header_preproc=yes
14175     ;;
14176   no:yes:* )
14177     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14178 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14179     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14180 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14181     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14182 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14183     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14184 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14185     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14186 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14187     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14188 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14189     ( cat <<\_ASBOX
14190 ## ---------------------------------------- ##
14191 ## Report this to pgsql-bugs@postgresql.org ##
14192 ## ---------------------------------------- ##
14193 _ASBOX
14194      ) | sed "s/^/$as_me: WARNING:     /" >&2
14195     ;;
14196 esac
14197 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14198 $as_echo_n "checking for $ac_header... " >&6; }
14199 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14200   $as_echo_n "(cached) " >&6
14201 else
14202   eval "$as_ac_Header=\$ac_header_preproc"
14203 fi
14204 ac_res=`eval 'as_val=${'$as_ac_Header'}
14205                  $as_echo "$as_val"'`
14206                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14207 $as_echo "$ac_res" >&6; }
14208
14209 fi
14210 as_val=`eval 'as_val=${'$as_ac_Header'}
14211                  $as_echo "$as_val"'`
14212    if test "x$as_val" = x""yes; then
14213   cat >>confdefs.h <<_ACEOF
14214 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14215 _ACEOF
14216
14217 else
14218
14219
14220 for ac_header in uuid.h
14221 do
14222 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14223 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14224   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14225 $as_echo_n "checking for $ac_header... " >&6; }
14226 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14227   $as_echo_n "(cached) " >&6
14228 fi
14229 ac_res=`eval 'as_val=${'$as_ac_Header'}
14230                  $as_echo "$as_val"'`
14231                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14232 $as_echo "$ac_res" >&6; }
14233 else
14234   # Is the header compilable?
14235 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14236 $as_echo_n "checking $ac_header usability... " >&6; }
14237 cat >conftest.$ac_ext <<_ACEOF
14238 /* confdefs.h.  */
14239 _ACEOF
14240 cat confdefs.h >>conftest.$ac_ext
14241 cat >>conftest.$ac_ext <<_ACEOF
14242 /* end confdefs.h.  */
14243 $ac_includes_default
14244 #include <$ac_header>
14245 _ACEOF
14246 rm -f conftest.$ac_objext
14247 if { (ac_try="$ac_compile"
14248 case "(($ac_try" in
14249   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14250   *) ac_try_echo=$ac_try;;
14251 esac
14252 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14253 $as_echo "$ac_try_echo") >&5
14254   (eval "$ac_compile") 2>conftest.er1
14255   ac_status=$?
14256   grep -v '^ *+' conftest.er1 >conftest.err
14257   rm -f conftest.er1
14258   cat conftest.err >&5
14259   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14260   (exit $ac_status); } && {
14261          test -z "$ac_c_werror_flag" ||
14262          test ! -s conftest.err
14263        } && test -s conftest.$ac_objext; then
14264   ac_header_compiler=yes
14265 else
14266   $as_echo "$as_me: failed program was:" >&5
14267 sed 's/^/| /' conftest.$ac_ext >&5
14268
14269         ac_header_compiler=no
14270 fi
14271
14272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14273 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14274 $as_echo "$ac_header_compiler" >&6; }
14275
14276 # Is the header present?
14277 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14278 $as_echo_n "checking $ac_header presence... " >&6; }
14279 cat >conftest.$ac_ext <<_ACEOF
14280 /* confdefs.h.  */
14281 _ACEOF
14282 cat confdefs.h >>conftest.$ac_ext
14283 cat >>conftest.$ac_ext <<_ACEOF
14284 /* end confdefs.h.  */
14285 #include <$ac_header>
14286 _ACEOF
14287 if { (ac_try="$ac_cpp conftest.$ac_ext"
14288 case "(($ac_try" in
14289   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14290   *) ac_try_echo=$ac_try;;
14291 esac
14292 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14293 $as_echo "$ac_try_echo") >&5
14294   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14295   ac_status=$?
14296   grep -v '^ *+' conftest.er1 >conftest.err
14297   rm -f conftest.er1
14298   cat conftest.err >&5
14299   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14300   (exit $ac_status); } >/dev/null && {
14301          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14302          test ! -s conftest.err
14303        }; then
14304   ac_header_preproc=yes
14305 else
14306   $as_echo "$as_me: failed program was:" >&5
14307 sed 's/^/| /' conftest.$ac_ext >&5
14308
14309   ac_header_preproc=no
14310 fi
14311
14312 rm -f conftest.err conftest.$ac_ext
14313 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14314 $as_echo "$ac_header_preproc" >&6; }
14315
14316 # So?  What about this header?
14317 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14318   yes:no: )
14319     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14320 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14321     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14322 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14323     ac_header_preproc=yes
14324     ;;
14325   no:yes:* )
14326     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14327 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14328     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14329 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14330     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14331 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14332     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14333 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14334     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14335 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14336     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14337 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14338     ( cat <<\_ASBOX
14339 ## ---------------------------------------- ##
14340 ## Report this to pgsql-bugs@postgresql.org ##
14341 ## ---------------------------------------- ##
14342 _ASBOX
14343      ) | sed "s/^/$as_me: WARNING:     /" >&2
14344     ;;
14345 esac
14346 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14347 $as_echo_n "checking for $ac_header... " >&6; }
14348 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14349   $as_echo_n "(cached) " >&6
14350 else
14351   eval "$as_ac_Header=\$ac_header_preproc"
14352 fi
14353 ac_res=`eval 'as_val=${'$as_ac_Header'}
14354                  $as_echo "$as_val"'`
14355                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14356 $as_echo "$ac_res" >&6; }
14357
14358 fi
14359 as_val=`eval 'as_val=${'$as_ac_Header'}
14360                  $as_echo "$as_val"'`
14361    if test "x$as_val" = x""yes; then
14362   cat >>confdefs.h <<_ACEOF
14363 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14364 _ACEOF
14365
14366 else
14367   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
14368 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
14369    { (exit 1); exit 1; }; }
14370 fi
14371
14372 done
14373
14374 fi
14375
14376 done
14377
14378 fi
14379
14380 if test "$PORTNAME" = "win32" ; then
14381
14382 for ac_header in crtdefs.h
14383 do
14384 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14385 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14386   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14387 $as_echo_n "checking for $ac_header... " >&6; }
14388 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14389   $as_echo_n "(cached) " >&6
14390 fi
14391 ac_res=`eval 'as_val=${'$as_ac_Header'}
14392                  $as_echo "$as_val"'`
14393                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14394 $as_echo "$ac_res" >&6; }
14395 else
14396   # Is the header compilable?
14397 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14398 $as_echo_n "checking $ac_header usability... " >&6; }
14399 cat >conftest.$ac_ext <<_ACEOF
14400 /* confdefs.h.  */
14401 _ACEOF
14402 cat confdefs.h >>conftest.$ac_ext
14403 cat >>conftest.$ac_ext <<_ACEOF
14404 /* end confdefs.h.  */
14405 $ac_includes_default
14406 #include <$ac_header>
14407 _ACEOF
14408 rm -f conftest.$ac_objext
14409 if { (ac_try="$ac_compile"
14410 case "(($ac_try" in
14411   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14412   *) ac_try_echo=$ac_try;;
14413 esac
14414 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14415 $as_echo "$ac_try_echo") >&5
14416   (eval "$ac_compile") 2>conftest.er1
14417   ac_status=$?
14418   grep -v '^ *+' conftest.er1 >conftest.err
14419   rm -f conftest.er1
14420   cat conftest.err >&5
14421   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14422   (exit $ac_status); } && {
14423          test -z "$ac_c_werror_flag" ||
14424          test ! -s conftest.err
14425        } && test -s conftest.$ac_objext; then
14426   ac_header_compiler=yes
14427 else
14428   $as_echo "$as_me: failed program was:" >&5
14429 sed 's/^/| /' conftest.$ac_ext >&5
14430
14431         ac_header_compiler=no
14432 fi
14433
14434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14435 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14436 $as_echo "$ac_header_compiler" >&6; }
14437
14438 # Is the header present?
14439 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14440 $as_echo_n "checking $ac_header presence... " >&6; }
14441 cat >conftest.$ac_ext <<_ACEOF
14442 /* confdefs.h.  */
14443 _ACEOF
14444 cat confdefs.h >>conftest.$ac_ext
14445 cat >>conftest.$ac_ext <<_ACEOF
14446 /* end confdefs.h.  */
14447 #include <$ac_header>
14448 _ACEOF
14449 if { (ac_try="$ac_cpp conftest.$ac_ext"
14450 case "(($ac_try" in
14451   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14452   *) ac_try_echo=$ac_try;;
14453 esac
14454 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14455 $as_echo "$ac_try_echo") >&5
14456   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14457   ac_status=$?
14458   grep -v '^ *+' conftest.er1 >conftest.err
14459   rm -f conftest.er1
14460   cat conftest.err >&5
14461   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14462   (exit $ac_status); } >/dev/null && {
14463          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14464          test ! -s conftest.err
14465        }; then
14466   ac_header_preproc=yes
14467 else
14468   $as_echo "$as_me: failed program was:" >&5
14469 sed 's/^/| /' conftest.$ac_ext >&5
14470
14471   ac_header_preproc=no
14472 fi
14473
14474 rm -f conftest.err conftest.$ac_ext
14475 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14476 $as_echo "$ac_header_preproc" >&6; }
14477
14478 # So?  What about this header?
14479 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14480   yes:no: )
14481     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14482 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14483     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14484 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14485     ac_header_preproc=yes
14486     ;;
14487   no:yes:* )
14488     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14489 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14490     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14491 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14492     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14493 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14494     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14495 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14496     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14497 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14498     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14499 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14500     ( cat <<\_ASBOX
14501 ## ---------------------------------------- ##
14502 ## Report this to pgsql-bugs@postgresql.org ##
14503 ## ---------------------------------------- ##
14504 _ASBOX
14505      ) | sed "s/^/$as_me: WARNING:     /" >&2
14506     ;;
14507 esac
14508 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14509 $as_echo_n "checking for $ac_header... " >&6; }
14510 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14511   $as_echo_n "(cached) " >&6
14512 else
14513   eval "$as_ac_Header=\$ac_header_preproc"
14514 fi
14515 ac_res=`eval 'as_val=${'$as_ac_Header'}
14516                  $as_echo "$as_val"'`
14517                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14518 $as_echo "$ac_res" >&6; }
14519
14520 fi
14521 as_val=`eval 'as_val=${'$as_ac_Header'}
14522                  $as_echo "$as_val"'`
14523    if test "x$as_val" = x""yes; then
14524   cat >>confdefs.h <<_ACEOF
14525 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14526 _ACEOF
14527
14528 fi
14529
14530 done
14531
14532 fi
14533
14534 ##
14535 ## Types, structures, compiler characteristics
14536 ##
14537
14538
14539  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
14540 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
14541 if test "${ac_cv_c_bigendian+set}" = set; then
14542   $as_echo_n "(cached) " >&6
14543 else
14544   ac_cv_c_bigendian=unknown
14545     # See if we're dealing with a universal compiler.
14546     cat >conftest.$ac_ext <<_ACEOF
14547 /* confdefs.h.  */
14548 _ACEOF
14549 cat confdefs.h >>conftest.$ac_ext
14550 cat >>conftest.$ac_ext <<_ACEOF
14551 /* end confdefs.h.  */
14552 #ifndef __APPLE_CC__
14553                not a universal capable compiler
14554              #endif
14555              typedef int dummy;
14556
14557 _ACEOF
14558 rm -f conftest.$ac_objext
14559 if { (ac_try="$ac_compile"
14560 case "(($ac_try" in
14561   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14562   *) ac_try_echo=$ac_try;;
14563 esac
14564 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14565 $as_echo "$ac_try_echo") >&5
14566   (eval "$ac_compile") 2>conftest.er1
14567   ac_status=$?
14568   grep -v '^ *+' conftest.er1 >conftest.err
14569   rm -f conftest.er1
14570   cat conftest.err >&5
14571   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14572   (exit $ac_status); } && {
14573          test -z "$ac_c_werror_flag" ||
14574          test ! -s conftest.err
14575        } && test -s conftest.$ac_objext; then
14576
14577         # Check for potential -arch flags.  It is not universal unless
14578         # there are some -arch flags.  Note that *ppc* also matches
14579         # ppc64.  This check is also rather less than ideal.
14580         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
14581           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
14582         esac
14583 else
14584   $as_echo "$as_me: failed program was:" >&5
14585 sed 's/^/| /' conftest.$ac_ext >&5
14586
14587
14588 fi
14589
14590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14591     if test $ac_cv_c_bigendian = unknown; then
14592       # See if sys/param.h defines the BYTE_ORDER macro.
14593       cat >conftest.$ac_ext <<_ACEOF
14594 /* confdefs.h.  */
14595 _ACEOF
14596 cat confdefs.h >>conftest.$ac_ext
14597 cat >>conftest.$ac_ext <<_ACEOF
14598 /* end confdefs.h.  */
14599 #include <sys/types.h>
14600              #include <sys/param.h>
14601
14602 int
14603 main ()
14604 {
14605 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14606                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14607                      && LITTLE_ENDIAN)
14608               bogus endian macros
14609              #endif
14610
14611   ;
14612   return 0;
14613 }
14614 _ACEOF
14615 rm -f conftest.$ac_objext
14616 if { (ac_try="$ac_compile"
14617 case "(($ac_try" in
14618   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14619   *) ac_try_echo=$ac_try;;
14620 esac
14621 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14622 $as_echo "$ac_try_echo") >&5
14623   (eval "$ac_compile") 2>conftest.er1
14624   ac_status=$?
14625   grep -v '^ *+' conftest.er1 >conftest.err
14626   rm -f conftest.er1
14627   cat conftest.err >&5
14628   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14629   (exit $ac_status); } && {
14630          test -z "$ac_c_werror_flag" ||
14631          test ! -s conftest.err
14632        } && test -s conftest.$ac_objext; then
14633   # It does; now see whether it defined to BIG_ENDIAN or not.
14634          cat >conftest.$ac_ext <<_ACEOF
14635 /* confdefs.h.  */
14636 _ACEOF
14637 cat confdefs.h >>conftest.$ac_ext
14638 cat >>conftest.$ac_ext <<_ACEOF
14639 /* end confdefs.h.  */
14640 #include <sys/types.h>
14641                 #include <sys/param.h>
14642
14643 int
14644 main ()
14645 {
14646 #if BYTE_ORDER != BIG_ENDIAN
14647                  not big endian
14648                 #endif
14649
14650   ;
14651   return 0;
14652 }
14653 _ACEOF
14654 rm -f conftest.$ac_objext
14655 if { (ac_try="$ac_compile"
14656 case "(($ac_try" in
14657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14658   *) ac_try_echo=$ac_try;;
14659 esac
14660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14661 $as_echo "$ac_try_echo") >&5
14662   (eval "$ac_compile") 2>conftest.er1
14663   ac_status=$?
14664   grep -v '^ *+' conftest.er1 >conftest.err
14665   rm -f conftest.er1
14666   cat conftest.err >&5
14667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14668   (exit $ac_status); } && {
14669          test -z "$ac_c_werror_flag" ||
14670          test ! -s conftest.err
14671        } && test -s conftest.$ac_objext; then
14672   ac_cv_c_bigendian=yes
14673 else
14674   $as_echo "$as_me: failed program was:" >&5
14675 sed 's/^/| /' conftest.$ac_ext >&5
14676
14677         ac_cv_c_bigendian=no
14678 fi
14679
14680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14681 else
14682   $as_echo "$as_me: failed program was:" >&5
14683 sed 's/^/| /' conftest.$ac_ext >&5
14684
14685
14686 fi
14687
14688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14689     fi
14690     if test $ac_cv_c_bigendian = unknown; then
14691       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14692       cat >conftest.$ac_ext <<_ACEOF
14693 /* confdefs.h.  */
14694 _ACEOF
14695 cat confdefs.h >>conftest.$ac_ext
14696 cat >>conftest.$ac_ext <<_ACEOF
14697 /* end confdefs.h.  */
14698 #include <limits.h>
14699
14700 int
14701 main ()
14702 {
14703 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14704               bogus endian macros
14705              #endif
14706
14707   ;
14708   return 0;
14709 }
14710 _ACEOF
14711 rm -f conftest.$ac_objext
14712 if { (ac_try="$ac_compile"
14713 case "(($ac_try" in
14714   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14715   *) ac_try_echo=$ac_try;;
14716 esac
14717 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14718 $as_echo "$ac_try_echo") >&5
14719   (eval "$ac_compile") 2>conftest.er1
14720   ac_status=$?
14721   grep -v '^ *+' conftest.er1 >conftest.err
14722   rm -f conftest.er1
14723   cat conftest.err >&5
14724   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14725   (exit $ac_status); } && {
14726          test -z "$ac_c_werror_flag" ||
14727          test ! -s conftest.err
14728        } && test -s conftest.$ac_objext; then
14729   # It does; now see whether it defined to _BIG_ENDIAN or not.
14730          cat >conftest.$ac_ext <<_ACEOF
14731 /* confdefs.h.  */
14732 _ACEOF
14733 cat confdefs.h >>conftest.$ac_ext
14734 cat >>conftest.$ac_ext <<_ACEOF
14735 /* end confdefs.h.  */
14736 #include <limits.h>
14737
14738 int
14739 main ()
14740 {
14741 #ifndef _BIG_ENDIAN
14742                  not big endian
14743                 #endif
14744
14745   ;
14746   return 0;
14747 }
14748 _ACEOF
14749 rm -f conftest.$ac_objext
14750 if { (ac_try="$ac_compile"
14751 case "(($ac_try" in
14752   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14753   *) ac_try_echo=$ac_try;;
14754 esac
14755 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14756 $as_echo "$ac_try_echo") >&5
14757   (eval "$ac_compile") 2>conftest.er1
14758   ac_status=$?
14759   grep -v '^ *+' conftest.er1 >conftest.err
14760   rm -f conftest.er1
14761   cat conftest.err >&5
14762   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14763   (exit $ac_status); } && {
14764          test -z "$ac_c_werror_flag" ||
14765          test ! -s conftest.err
14766        } && test -s conftest.$ac_objext; then
14767   ac_cv_c_bigendian=yes
14768 else
14769   $as_echo "$as_me: failed program was:" >&5
14770 sed 's/^/| /' conftest.$ac_ext >&5
14771
14772         ac_cv_c_bigendian=no
14773 fi
14774
14775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14776 else
14777   $as_echo "$as_me: failed program was:" >&5
14778 sed 's/^/| /' conftest.$ac_ext >&5
14779
14780
14781 fi
14782
14783 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14784     fi
14785     if test $ac_cv_c_bigendian = unknown; then
14786       # Compile a test program.
14787       if test "$cross_compiling" = yes; then
14788   # Try to guess by grepping values from an object file.
14789          cat >conftest.$ac_ext <<_ACEOF
14790 /* confdefs.h.  */
14791 _ACEOF
14792 cat confdefs.h >>conftest.$ac_ext
14793 cat >>conftest.$ac_ext <<_ACEOF
14794 /* end confdefs.h.  */
14795 short int ascii_mm[] =
14796                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14797                 short int ascii_ii[] =
14798                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14799                 int use_ascii (int i) {
14800                   return ascii_mm[i] + ascii_ii[i];
14801                 }
14802                 short int ebcdic_ii[] =
14803                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14804                 short int ebcdic_mm[] =
14805                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14806                 int use_ebcdic (int i) {
14807                   return ebcdic_mm[i] + ebcdic_ii[i];
14808                 }
14809                 extern int foo;
14810
14811 int
14812 main ()
14813 {
14814 return use_ascii (foo) == use_ebcdic (foo);
14815   ;
14816   return 0;
14817 }
14818 _ACEOF
14819 rm -f conftest.$ac_objext
14820 if { (ac_try="$ac_compile"
14821 case "(($ac_try" in
14822   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14823   *) ac_try_echo=$ac_try;;
14824 esac
14825 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14826 $as_echo "$ac_try_echo") >&5
14827   (eval "$ac_compile") 2>conftest.er1
14828   ac_status=$?
14829   grep -v '^ *+' conftest.er1 >conftest.err
14830   rm -f conftest.er1
14831   cat conftest.err >&5
14832   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14833   (exit $ac_status); } && {
14834          test -z "$ac_c_werror_flag" ||
14835          test ! -s conftest.err
14836        } && test -s conftest.$ac_objext; then
14837   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14838               ac_cv_c_bigendian=yes
14839             fi
14840             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14841               if test "$ac_cv_c_bigendian" = unknown; then
14842                 ac_cv_c_bigendian=no
14843               else
14844                 # finding both strings is unlikely to happen, but who knows?
14845                 ac_cv_c_bigendian=unknown
14846               fi
14847             fi
14848 else
14849   $as_echo "$as_me: failed program was:" >&5
14850 sed 's/^/| /' conftest.$ac_ext >&5
14851
14852
14853 fi
14854
14855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14856 else
14857   cat >conftest.$ac_ext <<_ACEOF
14858 /* confdefs.h.  */
14859 _ACEOF
14860 cat confdefs.h >>conftest.$ac_ext
14861 cat >>conftest.$ac_ext <<_ACEOF
14862 /* end confdefs.h.  */
14863 $ac_includes_default
14864 int
14865 main ()
14866 {
14867
14868              /* Are we little or big endian?  From Harbison&Steele.  */
14869              union
14870              {
14871                long int l;
14872                char c[sizeof (long int)];
14873              } u;
14874              u.l = 1;
14875              return u.c[sizeof (long int) - 1] == 1;
14876
14877   ;
14878   return 0;
14879 }
14880 _ACEOF
14881 rm -f conftest$ac_exeext
14882 if { (ac_try="$ac_link"
14883 case "(($ac_try" in
14884   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14885   *) ac_try_echo=$ac_try;;
14886 esac
14887 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14888 $as_echo "$ac_try_echo") >&5
14889   (eval "$ac_link") 2>&5
14890   ac_status=$?
14891   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14892   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14893   { (case "(($ac_try" in
14894   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14895   *) ac_try_echo=$ac_try;;
14896 esac
14897 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14898 $as_echo "$ac_try_echo") >&5
14899   (eval "$ac_try") 2>&5
14900   ac_status=$?
14901   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14902   (exit $ac_status); }; }; then
14903   ac_cv_c_bigendian=no
14904 else
14905   $as_echo "$as_me: program exited with status $ac_status" >&5
14906 $as_echo "$as_me: failed program was:" >&5
14907 sed 's/^/| /' conftest.$ac_ext >&5
14908
14909 ( exit $ac_status )
14910 ac_cv_c_bigendian=yes
14911 fi
14912 rm -rf conftest.dSYM
14913 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14914 fi
14915
14916
14917     fi
14918 fi
14919 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14920 $as_echo "$ac_cv_c_bigendian" >&6; }
14921  case $ac_cv_c_bigendian in #(
14922    yes)
14923      cat >>confdefs.h <<\_ACEOF
14924 #define WORDS_BIGENDIAN 1
14925 _ACEOF
14926 ;; #(
14927    no)
14928       ;; #(
14929    universal)
14930
14931 cat >>confdefs.h <<\_ACEOF
14932 #define AC_APPLE_UNIVERSAL_BUILD 1
14933 _ACEOF
14934
14935      ;; #(
14936    *)
14937      { { $as_echo "$as_me:$LINENO: error: unknown endianness
14938  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14939 $as_echo "$as_me: error: unknown endianness
14940  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14941    { (exit 1); exit 1; }; } ;;
14942  esac
14943
14944 { $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14945 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14946 if test "${ac_cv_c_const+set}" = set; then
14947   $as_echo_n "(cached) " >&6
14948 else
14949   cat >conftest.$ac_ext <<_ACEOF
14950 /* confdefs.h.  */
14951 _ACEOF
14952 cat confdefs.h >>conftest.$ac_ext
14953 cat >>conftest.$ac_ext <<_ACEOF
14954 /* end confdefs.h.  */
14955
14956 int
14957 main ()
14958 {
14959 /* FIXME: Include the comments suggested by Paul. */
14960 #ifndef __cplusplus
14961   /* Ultrix mips cc rejects this.  */
14962   typedef int charset[2];
14963   const charset cs;
14964   /* SunOS 4.1.1 cc rejects this.  */
14965   char const *const *pcpcc;
14966   char **ppc;
14967   /* NEC SVR4.0.2 mips cc rejects this.  */
14968   struct point {int x, y;};
14969   static struct point const zero = {0,0};
14970   /* AIX XL C 1.02.0.0 rejects this.
14971      It does not let you subtract one const X* pointer from another in
14972      an arm of an if-expression whose if-part is not a constant
14973      expression */
14974   const char *g = "string";
14975   pcpcc = &g + (g ? g-g : 0);
14976   /* HPUX 7.0 cc rejects these. */
14977   ++pcpcc;
14978   ppc = (char**) pcpcc;
14979   pcpcc = (char const *const *) ppc;
14980   { /* SCO 3.2v4 cc rejects this.  */
14981     char *t;
14982     char const *s = 0 ? (char *) 0 : (char const *) 0;
14983
14984     *t++ = 0;
14985     if (s) return 0;
14986   }
14987   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14988     int x[] = {25, 17};
14989     const int *foo = &x[0];
14990     ++foo;
14991   }
14992   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14993     typedef const int *iptr;
14994     iptr p = 0;
14995     ++p;
14996   }
14997   { /* AIX XL C 1.02.0.0 rejects this saying
14998        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14999     struct s { int j; const int *ap[3]; };
15000     struct s *b; b->j = 5;
15001   }
15002   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
15003     const int foo = 10;
15004     if (!foo) return 0;
15005   }
15006   return !cs[0] && !zero.x;
15007 #endif
15008
15009   ;
15010   return 0;
15011 }
15012 _ACEOF
15013 rm -f conftest.$ac_objext
15014 if { (ac_try="$ac_compile"
15015 case "(($ac_try" in
15016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15017   *) ac_try_echo=$ac_try;;
15018 esac
15019 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15020 $as_echo "$ac_try_echo") >&5
15021   (eval "$ac_compile") 2>conftest.er1
15022   ac_status=$?
15023   grep -v '^ *+' conftest.er1 >conftest.err
15024   rm -f conftest.er1
15025   cat conftest.err >&5
15026   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15027   (exit $ac_status); } && {
15028          test -z "$ac_c_werror_flag" ||
15029          test ! -s conftest.err
15030        } && test -s conftest.$ac_objext; then
15031   ac_cv_c_const=yes
15032 else
15033   $as_echo "$as_me: failed program was:" >&5
15034 sed 's/^/| /' conftest.$ac_ext >&5
15035
15036         ac_cv_c_const=no
15037 fi
15038
15039 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15040 fi
15041 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
15042 $as_echo "$ac_cv_c_const" >&6; }
15043 if test $ac_cv_c_const = no; then
15044
15045 cat >>confdefs.h <<\_ACEOF
15046 #define const /**/
15047 _ACEOF
15048
15049 fi
15050
15051 { $as_echo "$as_me:$LINENO: checking for inline" >&5
15052 $as_echo_n "checking for inline... " >&6; }
15053 if test "${ac_cv_c_inline+set}" = set; then
15054   $as_echo_n "(cached) " >&6
15055 else
15056   ac_cv_c_inline=no
15057 for ac_kw in inline __inline__ __inline; do
15058   cat >conftest.$ac_ext <<_ACEOF
15059 /* confdefs.h.  */
15060 _ACEOF
15061 cat confdefs.h >>conftest.$ac_ext
15062 cat >>conftest.$ac_ext <<_ACEOF
15063 /* end confdefs.h.  */
15064 #ifndef __cplusplus
15065 typedef int foo_t;
15066 static $ac_kw foo_t static_foo () {return 0; }
15067 $ac_kw foo_t foo () {return 0; }
15068 #endif
15069
15070 _ACEOF
15071 rm -f conftest.$ac_objext
15072 if { (ac_try="$ac_compile"
15073 case "(($ac_try" in
15074   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15075   *) ac_try_echo=$ac_try;;
15076 esac
15077 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15078 $as_echo "$ac_try_echo") >&5
15079   (eval "$ac_compile") 2>conftest.er1
15080   ac_status=$?
15081   grep -v '^ *+' conftest.er1 >conftest.err
15082   rm -f conftest.er1
15083   cat conftest.err >&5
15084   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15085   (exit $ac_status); } && {
15086          test -z "$ac_c_werror_flag" ||
15087          test ! -s conftest.err
15088        } && test -s conftest.$ac_objext; then
15089   ac_cv_c_inline=$ac_kw
15090 else
15091   $as_echo "$as_me: failed program was:" >&5
15092 sed 's/^/| /' conftest.$ac_ext >&5
15093
15094
15095 fi
15096
15097 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15098   test "$ac_cv_c_inline" != no && break
15099 done
15100
15101 fi
15102 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
15103 $as_echo "$ac_cv_c_inline" >&6; }
15104
15105
15106 case $ac_cv_c_inline in
15107   inline | yes) ;;
15108   *)
15109     case $ac_cv_c_inline in
15110       no) ac_val=;;
15111       *) ac_val=$ac_cv_c_inline;;
15112     esac
15113     cat >>confdefs.h <<_ACEOF
15114 #ifndef __cplusplus
15115 #define inline $ac_val
15116 #endif
15117 _ACEOF
15118     ;;
15119 esac
15120
15121 { $as_echo "$as_me:$LINENO: checking for quiet inline (no complaint if unreferenced)" >&5
15122 $as_echo_n "checking for quiet inline (no complaint if unreferenced)... " >&6; }
15123 if test "${pgac_cv_c_inline_quietly+set}" = set; then
15124   $as_echo_n "(cached) " >&6
15125 else
15126   pgac_cv_c_inline_quietly=no
15127   if test "$ac_cv_c_inline" != no; then
15128     pgac_c_inline_save_werror=$ac_c_werror_flag
15129     ac_c_werror_flag=yes
15130     cat >conftest.$ac_ext <<_ACEOF
15131 /* confdefs.h.  */
15132 _ACEOF
15133 cat confdefs.h >>conftest.$ac_ext
15134 cat >>conftest.$ac_ext <<_ACEOF
15135 /* end confdefs.h.  */
15136 static inline int fun () {return 0;}
15137 int
15138 main ()
15139 {
15140
15141   ;
15142   return 0;
15143 }
15144 _ACEOF
15145 rm -f conftest.$ac_objext conftest$ac_exeext
15146 if { (ac_try="$ac_link"
15147 case "(($ac_try" in
15148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15149   *) ac_try_echo=$ac_try;;
15150 esac
15151 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15152 $as_echo "$ac_try_echo") >&5
15153   (eval "$ac_link") 2>conftest.er1
15154   ac_status=$?
15155   grep -v '^ *+' conftest.er1 >conftest.err
15156   rm -f conftest.er1
15157   cat conftest.err >&5
15158   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15159   (exit $ac_status); } && {
15160          test -z "$ac_c_werror_flag" ||
15161          test ! -s conftest.err
15162        } && test -s conftest$ac_exeext && {
15163          test "$cross_compiling" = yes ||
15164          $as_test_x conftest$ac_exeext
15165        }; then
15166   pgac_cv_c_inline_quietly=yes
15167 else
15168   $as_echo "$as_me: failed program was:" >&5
15169 sed 's/^/| /' conftest.$ac_ext >&5
15170
15171
15172 fi
15173
15174 rm -rf conftest.dSYM
15175 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15176       conftest$ac_exeext conftest.$ac_ext
15177     ac_c_werror_flag=$pgac_c_inline_save_werror
15178   fi
15179 fi
15180 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_inline_quietly" >&5
15181 $as_echo "$pgac_cv_c_inline_quietly" >&6; }
15182 if test "$pgac_cv_c_inline_quietly" != no; then
15183
15184 cat >>confdefs.h <<_ACEOF
15185 #define USE_INLINE 1
15186 _ACEOF
15187
15188 fi
15189
15190 { $as_echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
15191 $as_echo_n "checking for preprocessor stringizing operator... " >&6; }
15192 if test "${ac_cv_c_stringize+set}" = set; then
15193   $as_echo_n "(cached) " >&6
15194 else
15195   cat >conftest.$ac_ext <<_ACEOF
15196 /* confdefs.h.  */
15197 _ACEOF
15198 cat confdefs.h >>conftest.$ac_ext
15199 cat >>conftest.$ac_ext <<_ACEOF
15200 /* end confdefs.h.  */
15201 #define x(y) #y
15202
15203 char *s = x(teststring);
15204 _ACEOF
15205 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15206   $EGREP "#teststring" >/dev/null 2>&1; then
15207   ac_cv_c_stringize=no
15208 else
15209   ac_cv_c_stringize=yes
15210 fi
15211 rm -f conftest*
15212
15213 fi
15214 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
15215 $as_echo "$ac_cv_c_stringize" >&6; }
15216 if test $ac_cv_c_stringize = yes; then
15217
15218 cat >>confdefs.h <<\_ACEOF
15219 #define HAVE_STRINGIZE 1
15220 _ACEOF
15221
15222 fi
15223
15224
15225   { $as_echo "$as_me:$LINENO: checking for flexible array members" >&5
15226 $as_echo_n "checking for flexible array members... " >&6; }
15227 if test "${ac_cv_c_flexmember+set}" = set; then
15228   $as_echo_n "(cached) " >&6
15229 else
15230   cat >conftest.$ac_ext <<_ACEOF
15231 /* confdefs.h.  */
15232 _ACEOF
15233 cat confdefs.h >>conftest.$ac_ext
15234 cat >>conftest.$ac_ext <<_ACEOF
15235 /* end confdefs.h.  */
15236 #include <stdlib.h>
15237             #include <stdio.h>
15238             #include <stddef.h>
15239             struct s { int n; double d[]; };
15240 int
15241 main ()
15242 {
15243 int m = getchar ();
15244             struct s *p = malloc (offsetof (struct s, d)
15245                                   + m * sizeof (double));
15246             p->d[0] = 0.0;
15247             return p->d != (double *) NULL;
15248   ;
15249   return 0;
15250 }
15251 _ACEOF
15252 rm -f conftest.$ac_objext
15253 if { (ac_try="$ac_compile"
15254 case "(($ac_try" in
15255   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15256   *) ac_try_echo=$ac_try;;
15257 esac
15258 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15259 $as_echo "$ac_try_echo") >&5
15260   (eval "$ac_compile") 2>conftest.er1
15261   ac_status=$?
15262   grep -v '^ *+' conftest.er1 >conftest.err
15263   rm -f conftest.er1
15264   cat conftest.err >&5
15265   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15266   (exit $ac_status); } && {
15267          test -z "$ac_c_werror_flag" ||
15268          test ! -s conftest.err
15269        } && test -s conftest.$ac_objext; then
15270   ac_cv_c_flexmember=yes
15271 else
15272   $as_echo "$as_me: failed program was:" >&5
15273 sed 's/^/| /' conftest.$ac_ext >&5
15274
15275         ac_cv_c_flexmember=no
15276 fi
15277
15278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15279 fi
15280 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_flexmember" >&5
15281 $as_echo "$ac_cv_c_flexmember" >&6; }
15282   if test $ac_cv_c_flexmember = yes; then
15283
15284 cat >>confdefs.h <<\_ACEOF
15285 #define FLEXIBLE_ARRAY_MEMBER /**/
15286 _ACEOF
15287
15288   else
15289     cat >>confdefs.h <<\_ACEOF
15290 #define FLEXIBLE_ARRAY_MEMBER 1
15291 _ACEOF
15292
15293   fi
15294
15295 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
15296 $as_echo_n "checking for signed types... " >&6; }
15297 if test "${pgac_cv_c_signed+set}" = set; then
15298   $as_echo_n "(cached) " >&6
15299 else
15300   cat >conftest.$ac_ext <<_ACEOF
15301 /* confdefs.h.  */
15302 _ACEOF
15303 cat confdefs.h >>conftest.$ac_ext
15304 cat >>conftest.$ac_ext <<_ACEOF
15305 /* end confdefs.h.  */
15306
15307 int
15308 main ()
15309 {
15310 signed char c; signed short s; signed int i;
15311   ;
15312   return 0;
15313 }
15314 _ACEOF
15315 rm -f conftest.$ac_objext
15316 if { (ac_try="$ac_compile"
15317 case "(($ac_try" in
15318   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15319   *) ac_try_echo=$ac_try;;
15320 esac
15321 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15322 $as_echo "$ac_try_echo") >&5
15323   (eval "$ac_compile") 2>conftest.er1
15324   ac_status=$?
15325   grep -v '^ *+' conftest.er1 >conftest.err
15326   rm -f conftest.er1
15327   cat conftest.err >&5
15328   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15329   (exit $ac_status); } && {
15330          test -z "$ac_c_werror_flag" ||
15331          test ! -s conftest.err
15332        } && test -s conftest.$ac_objext; then
15333   pgac_cv_c_signed=yes
15334 else
15335   $as_echo "$as_me: failed program was:" >&5
15336 sed 's/^/| /' conftest.$ac_ext >&5
15337
15338         pgac_cv_c_signed=no
15339 fi
15340
15341 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15342 fi
15343 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
15344 $as_echo "$pgac_cv_c_signed" >&6; }
15345 if test x"$pgac_cv_c_signed" = xno ; then
15346
15347 cat >>confdefs.h <<\_ACEOF
15348 #define signed /**/
15349 _ACEOF
15350
15351 fi
15352 { $as_echo "$as_me:$LINENO: checking for working volatile" >&5
15353 $as_echo_n "checking for working volatile... " >&6; }
15354 if test "${ac_cv_c_volatile+set}" = set; then
15355   $as_echo_n "(cached) " >&6
15356 else
15357   cat >conftest.$ac_ext <<_ACEOF
15358 /* confdefs.h.  */
15359 _ACEOF
15360 cat confdefs.h >>conftest.$ac_ext
15361 cat >>conftest.$ac_ext <<_ACEOF
15362 /* end confdefs.h.  */
15363
15364 int
15365 main ()
15366 {
15367
15368 volatile int x;
15369 int * volatile y = (int *) 0;
15370 return !x && !y;
15371   ;
15372   return 0;
15373 }
15374 _ACEOF
15375 rm -f conftest.$ac_objext
15376 if { (ac_try="$ac_compile"
15377 case "(($ac_try" in
15378   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15379   *) ac_try_echo=$ac_try;;
15380 esac
15381 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15382 $as_echo "$ac_try_echo") >&5
15383   (eval "$ac_compile") 2>conftest.er1
15384   ac_status=$?
15385   grep -v '^ *+' conftest.er1 >conftest.err
15386   rm -f conftest.er1
15387   cat conftest.err >&5
15388   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15389   (exit $ac_status); } && {
15390          test -z "$ac_c_werror_flag" ||
15391          test ! -s conftest.err
15392        } && test -s conftest.$ac_objext; then
15393   ac_cv_c_volatile=yes
15394 else
15395   $as_echo "$as_me: failed program was:" >&5
15396 sed 's/^/| /' conftest.$ac_ext >&5
15397
15398         ac_cv_c_volatile=no
15399 fi
15400
15401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15402 fi
15403 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
15404 $as_echo "$ac_cv_c_volatile" >&6; }
15405 if test $ac_cv_c_volatile = no; then
15406
15407 cat >>confdefs.h <<\_ACEOF
15408 #define volatile /**/
15409 _ACEOF
15410
15411 fi
15412
15413 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
15414 $as_echo_n "checking for __func__... " >&6; }
15415 if test "${pgac_cv_funcname_func_support+set}" = set; then
15416   $as_echo_n "(cached) " >&6
15417 else
15418   cat >conftest.$ac_ext <<_ACEOF
15419 /* confdefs.h.  */
15420 _ACEOF
15421 cat confdefs.h >>conftest.$ac_ext
15422 cat >>conftest.$ac_ext <<_ACEOF
15423 /* end confdefs.h.  */
15424 #include <stdio.h>
15425 int
15426 main ()
15427 {
15428 printf("%s\n", __func__);
15429   ;
15430   return 0;
15431 }
15432 _ACEOF
15433 rm -f conftest.$ac_objext
15434 if { (ac_try="$ac_compile"
15435 case "(($ac_try" in
15436   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15437   *) ac_try_echo=$ac_try;;
15438 esac
15439 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15440 $as_echo "$ac_try_echo") >&5
15441   (eval "$ac_compile") 2>conftest.er1
15442   ac_status=$?
15443   grep -v '^ *+' conftest.er1 >conftest.err
15444   rm -f conftest.er1
15445   cat conftest.err >&5
15446   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15447   (exit $ac_status); } && {
15448          test -z "$ac_c_werror_flag" ||
15449          test ! -s conftest.err
15450        } && test -s conftest.$ac_objext; then
15451   pgac_cv_funcname_func_support=yes
15452 else
15453   $as_echo "$as_me: failed program was:" >&5
15454 sed 's/^/| /' conftest.$ac_ext >&5
15455
15456         pgac_cv_funcname_func_support=no
15457 fi
15458
15459 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15460 fi
15461 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
15462 $as_echo "$pgac_cv_funcname_func_support" >&6; }
15463 if test x"$pgac_cv_funcname_func_support" = xyes ; then
15464
15465 cat >>confdefs.h <<\_ACEOF
15466 #define HAVE_FUNCNAME__FUNC 1
15467 _ACEOF
15468
15469 else
15470 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
15471 $as_echo_n "checking for __FUNCTION__... " >&6; }
15472 if test "${pgac_cv_funcname_function_support+set}" = set; then
15473   $as_echo_n "(cached) " >&6
15474 else
15475   cat >conftest.$ac_ext <<_ACEOF
15476 /* confdefs.h.  */
15477 _ACEOF
15478 cat confdefs.h >>conftest.$ac_ext
15479 cat >>conftest.$ac_ext <<_ACEOF
15480 /* end confdefs.h.  */
15481 #include <stdio.h>
15482 int
15483 main ()
15484 {
15485 printf("%s\n", __FUNCTION__);
15486   ;
15487   return 0;
15488 }
15489 _ACEOF
15490 rm -f conftest.$ac_objext
15491 if { (ac_try="$ac_compile"
15492 case "(($ac_try" in
15493   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15494   *) ac_try_echo=$ac_try;;
15495 esac
15496 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15497 $as_echo "$ac_try_echo") >&5
15498   (eval "$ac_compile") 2>conftest.er1
15499   ac_status=$?
15500   grep -v '^ *+' conftest.er1 >conftest.err
15501   rm -f conftest.er1
15502   cat conftest.err >&5
15503   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15504   (exit $ac_status); } && {
15505          test -z "$ac_c_werror_flag" ||
15506          test ! -s conftest.err
15507        } && test -s conftest.$ac_objext; then
15508   pgac_cv_funcname_function_support=yes
15509 else
15510   $as_echo "$as_me: failed program was:" >&5
15511 sed 's/^/| /' conftest.$ac_ext >&5
15512
15513         pgac_cv_funcname_function_support=no
15514 fi
15515
15516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15517 fi
15518 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
15519 $as_echo "$pgac_cv_funcname_function_support" >&6; }
15520 if test x"$pgac_cv_funcname_function_support" = xyes ; then
15521
15522 cat >>confdefs.h <<\_ACEOF
15523 #define HAVE_FUNCNAME__FUNCTION 1
15524 _ACEOF
15525
15526 fi
15527 fi
15528 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
15529 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
15530 if test "${ac_cv_struct_tm+set}" = set; then
15531   $as_echo_n "(cached) " >&6
15532 else
15533   cat >conftest.$ac_ext <<_ACEOF
15534 /* confdefs.h.  */
15535 _ACEOF
15536 cat confdefs.h >>conftest.$ac_ext
15537 cat >>conftest.$ac_ext <<_ACEOF
15538 /* end confdefs.h.  */
15539 #include <sys/types.h>
15540 #include <time.h>
15541
15542 int
15543 main ()
15544 {
15545 struct tm tm;
15546                                      int *p = &tm.tm_sec;
15547                                      return !p;
15548   ;
15549   return 0;
15550 }
15551 _ACEOF
15552 rm -f conftest.$ac_objext
15553 if { (ac_try="$ac_compile"
15554 case "(($ac_try" in
15555   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15556   *) ac_try_echo=$ac_try;;
15557 esac
15558 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15559 $as_echo "$ac_try_echo") >&5
15560   (eval "$ac_compile") 2>conftest.er1
15561   ac_status=$?
15562   grep -v '^ *+' conftest.er1 >conftest.err
15563   rm -f conftest.er1
15564   cat conftest.err >&5
15565   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15566   (exit $ac_status); } && {
15567          test -z "$ac_c_werror_flag" ||
15568          test ! -s conftest.err
15569        } && test -s conftest.$ac_objext; then
15570   ac_cv_struct_tm=time.h
15571 else
15572   $as_echo "$as_me: failed program was:" >&5
15573 sed 's/^/| /' conftest.$ac_ext >&5
15574
15575         ac_cv_struct_tm=sys/time.h
15576 fi
15577
15578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15579 fi
15580 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
15581 $as_echo "$ac_cv_struct_tm" >&6; }
15582 if test $ac_cv_struct_tm = sys/time.h; then
15583
15584 cat >>confdefs.h <<\_ACEOF
15585 #define TM_IN_SYS_TIME 1
15586 _ACEOF
15587
15588 fi
15589
15590 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
15591 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
15592 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
15593   $as_echo_n "(cached) " >&6
15594 else
15595   cat >conftest.$ac_ext <<_ACEOF
15596 /* confdefs.h.  */
15597 _ACEOF
15598 cat confdefs.h >>conftest.$ac_ext
15599 cat >>conftest.$ac_ext <<_ACEOF
15600 /* end confdefs.h.  */
15601 #include <sys/types.h>
15602 #include <$ac_cv_struct_tm>
15603
15604
15605 int
15606 main ()
15607 {
15608 static struct tm ac_aggr;
15609 if (ac_aggr.tm_zone)
15610 return 0;
15611   ;
15612   return 0;
15613 }
15614 _ACEOF
15615 rm -f conftest.$ac_objext
15616 if { (ac_try="$ac_compile"
15617 case "(($ac_try" in
15618   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15619   *) ac_try_echo=$ac_try;;
15620 esac
15621 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15622 $as_echo "$ac_try_echo") >&5
15623   (eval "$ac_compile") 2>conftest.er1
15624   ac_status=$?
15625   grep -v '^ *+' conftest.er1 >conftest.err
15626   rm -f conftest.er1
15627   cat conftest.err >&5
15628   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15629   (exit $ac_status); } && {
15630          test -z "$ac_c_werror_flag" ||
15631          test ! -s conftest.err
15632        } && test -s conftest.$ac_objext; then
15633   ac_cv_member_struct_tm_tm_zone=yes
15634 else
15635   $as_echo "$as_me: failed program was:" >&5
15636 sed 's/^/| /' conftest.$ac_ext >&5
15637
15638         cat >conftest.$ac_ext <<_ACEOF
15639 /* confdefs.h.  */
15640 _ACEOF
15641 cat confdefs.h >>conftest.$ac_ext
15642 cat >>conftest.$ac_ext <<_ACEOF
15643 /* end confdefs.h.  */
15644 #include <sys/types.h>
15645 #include <$ac_cv_struct_tm>
15646
15647
15648 int
15649 main ()
15650 {
15651 static struct tm ac_aggr;
15652 if (sizeof ac_aggr.tm_zone)
15653 return 0;
15654   ;
15655   return 0;
15656 }
15657 _ACEOF
15658 rm -f conftest.$ac_objext
15659 if { (ac_try="$ac_compile"
15660 case "(($ac_try" in
15661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15662   *) ac_try_echo=$ac_try;;
15663 esac
15664 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15665 $as_echo "$ac_try_echo") >&5
15666   (eval "$ac_compile") 2>conftest.er1
15667   ac_status=$?
15668   grep -v '^ *+' conftest.er1 >conftest.err
15669   rm -f conftest.er1
15670   cat conftest.err >&5
15671   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15672   (exit $ac_status); } && {
15673          test -z "$ac_c_werror_flag" ||
15674          test ! -s conftest.err
15675        } && test -s conftest.$ac_objext; then
15676   ac_cv_member_struct_tm_tm_zone=yes
15677 else
15678   $as_echo "$as_me: failed program was:" >&5
15679 sed 's/^/| /' conftest.$ac_ext >&5
15680
15681         ac_cv_member_struct_tm_tm_zone=no
15682 fi
15683
15684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15685 fi
15686
15687 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15688 fi
15689 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
15690 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
15691 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
15692
15693 cat >>confdefs.h <<_ACEOF
15694 #define HAVE_STRUCT_TM_TM_ZONE 1
15695 _ACEOF
15696
15697
15698 fi
15699
15700 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15701
15702 cat >>confdefs.h <<\_ACEOF
15703 #define HAVE_TM_ZONE 1
15704 _ACEOF
15705
15706 fi
15707 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
15708 $as_echo_n "checking for tzname... " >&6; }
15709 if test "${ac_cv_var_tzname+set}" = set; then
15710   $as_echo_n "(cached) " >&6
15711 else
15712   cat >conftest.$ac_ext <<_ACEOF
15713 /* confdefs.h.  */
15714 _ACEOF
15715 cat confdefs.h >>conftest.$ac_ext
15716 cat >>conftest.$ac_ext <<_ACEOF
15717 /* end confdefs.h.  */
15718 #include <time.h>
15719 #ifndef tzname /* For SGI.  */
15720 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
15721 #endif
15722
15723 int
15724 main ()
15725 {
15726 atoi(*tzname);
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   ac_cv_var_tzname=yes
15753 else
15754   $as_echo "$as_me: failed program was:" >&5
15755 sed 's/^/| /' conftest.$ac_ext >&5
15756
15757         ac_cv_var_tzname=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: $ac_cv_var_tzname" >&5
15765 $as_echo "$ac_cv_var_tzname" >&6; }
15766 if test $ac_cv_var_tzname = yes; then
15767
15768 cat >>confdefs.h <<\_ACEOF
15769 #define HAVE_TZNAME 1
15770 _ACEOF
15771
15772 fi
15773
15774 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
15775 $as_echo_n "checking for union semun... " >&6; }
15776 if test "${ac_cv_type_union_semun+set}" = set; then
15777   $as_echo_n "(cached) " >&6
15778 else
15779   ac_cv_type_union_semun=no
15780 cat >conftest.$ac_ext <<_ACEOF
15781 /* confdefs.h.  */
15782 _ACEOF
15783 cat confdefs.h >>conftest.$ac_ext
15784 cat >>conftest.$ac_ext <<_ACEOF
15785 /* end confdefs.h.  */
15786 #include <sys/types.h>
15787 #include <sys/ipc.h>
15788 #include <sys/sem.h>
15789
15790 int
15791 main ()
15792 {
15793 if (sizeof (union semun))
15794        return 0;
15795   ;
15796   return 0;
15797 }
15798 _ACEOF
15799 rm -f conftest.$ac_objext
15800 if { (ac_try="$ac_compile"
15801 case "(($ac_try" in
15802   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15803   *) ac_try_echo=$ac_try;;
15804 esac
15805 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15806 $as_echo "$ac_try_echo") >&5
15807   (eval "$ac_compile") 2>conftest.er1
15808   ac_status=$?
15809   grep -v '^ *+' conftest.er1 >conftest.err
15810   rm -f conftest.er1
15811   cat conftest.err >&5
15812   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15813   (exit $ac_status); } && {
15814          test -z "$ac_c_werror_flag" ||
15815          test ! -s conftest.err
15816        } && test -s conftest.$ac_objext; then
15817   cat >conftest.$ac_ext <<_ACEOF
15818 /* confdefs.h.  */
15819 _ACEOF
15820 cat confdefs.h >>conftest.$ac_ext
15821 cat >>conftest.$ac_ext <<_ACEOF
15822 /* end confdefs.h.  */
15823 #include <sys/types.h>
15824 #include <sys/ipc.h>
15825 #include <sys/sem.h>
15826
15827 int
15828 main ()
15829 {
15830 if (sizeof ((union semun)))
15831           return 0;
15832   ;
15833   return 0;
15834 }
15835 _ACEOF
15836 rm -f conftest.$ac_objext
15837 if { (ac_try="$ac_compile"
15838 case "(($ac_try" in
15839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15840   *) ac_try_echo=$ac_try;;
15841 esac
15842 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15843 $as_echo "$ac_try_echo") >&5
15844   (eval "$ac_compile") 2>conftest.er1
15845   ac_status=$?
15846   grep -v '^ *+' conftest.er1 >conftest.err
15847   rm -f conftest.er1
15848   cat conftest.err >&5
15849   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15850   (exit $ac_status); } && {
15851          test -z "$ac_c_werror_flag" ||
15852          test ! -s conftest.err
15853        } && test -s conftest.$ac_objext; then
15854   :
15855 else
15856   $as_echo "$as_me: failed program was:" >&5
15857 sed 's/^/| /' conftest.$ac_ext >&5
15858
15859         ac_cv_type_union_semun=yes
15860 fi
15861
15862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15863 else
15864   $as_echo "$as_me: failed program was:" >&5
15865 sed 's/^/| /' conftest.$ac_ext >&5
15866
15867
15868 fi
15869
15870 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15871 fi
15872 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
15873 $as_echo "$ac_cv_type_union_semun" >&6; }
15874 if test "x$ac_cv_type_union_semun" = x""yes; then
15875
15876 cat >>confdefs.h <<_ACEOF
15877 #define HAVE_UNION_SEMUN 1
15878 _ACEOF
15879
15880
15881 fi
15882
15883 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
15884 $as_echo_n "checking for struct sockaddr_un... " >&6; }
15885 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
15886   $as_echo_n "(cached) " >&6
15887 else
15888   ac_cv_type_struct_sockaddr_un=no
15889 cat >conftest.$ac_ext <<_ACEOF
15890 /* confdefs.h.  */
15891 _ACEOF
15892 cat confdefs.h >>conftest.$ac_ext
15893 cat >>conftest.$ac_ext <<_ACEOF
15894 /* end confdefs.h.  */
15895 #include <sys/types.h>
15896 #ifdef HAVE_SYS_UN_H
15897 #include <sys/un.h>
15898 #endif
15899
15900
15901 int
15902 main ()
15903 {
15904 if (sizeof (struct sockaddr_un))
15905        return 0;
15906   ;
15907   return 0;
15908 }
15909 _ACEOF
15910 rm -f conftest.$ac_objext
15911 if { (ac_try="$ac_compile"
15912 case "(($ac_try" in
15913   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15914   *) ac_try_echo=$ac_try;;
15915 esac
15916 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15917 $as_echo "$ac_try_echo") >&5
15918   (eval "$ac_compile") 2>conftest.er1
15919   ac_status=$?
15920   grep -v '^ *+' conftest.er1 >conftest.err
15921   rm -f conftest.er1
15922   cat conftest.err >&5
15923   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15924   (exit $ac_status); } && {
15925          test -z "$ac_c_werror_flag" ||
15926          test ! -s conftest.err
15927        } && test -s conftest.$ac_objext; then
15928   cat >conftest.$ac_ext <<_ACEOF
15929 /* confdefs.h.  */
15930 _ACEOF
15931 cat confdefs.h >>conftest.$ac_ext
15932 cat >>conftest.$ac_ext <<_ACEOF
15933 /* end confdefs.h.  */
15934 #include <sys/types.h>
15935 #ifdef HAVE_SYS_UN_H
15936 #include <sys/un.h>
15937 #endif
15938
15939
15940 int
15941 main ()
15942 {
15943 if (sizeof ((struct sockaddr_un)))
15944           return 0;
15945   ;
15946   return 0;
15947 }
15948 _ACEOF
15949 rm -f conftest.$ac_objext
15950 if { (ac_try="$ac_compile"
15951 case "(($ac_try" in
15952   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15953   *) ac_try_echo=$ac_try;;
15954 esac
15955 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15956 $as_echo "$ac_try_echo") >&5
15957   (eval "$ac_compile") 2>conftest.er1
15958   ac_status=$?
15959   grep -v '^ *+' conftest.er1 >conftest.err
15960   rm -f conftest.er1
15961   cat conftest.err >&5
15962   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15963   (exit $ac_status); } && {
15964          test -z "$ac_c_werror_flag" ||
15965          test ! -s conftest.err
15966        } && test -s conftest.$ac_objext; then
15967   :
15968 else
15969   $as_echo "$as_me: failed program was:" >&5
15970 sed 's/^/| /' conftest.$ac_ext >&5
15971
15972         ac_cv_type_struct_sockaddr_un=yes
15973 fi
15974
15975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15976 else
15977   $as_echo "$as_me: failed program was:" >&5
15978 sed 's/^/| /' conftest.$ac_ext >&5
15979
15980
15981 fi
15982
15983 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15984 fi
15985 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
15986 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
15987 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
15988
15989 cat >>confdefs.h <<\_ACEOF
15990 #define HAVE_UNIX_SOCKETS 1
15991 _ACEOF
15992
15993 fi
15994
15995 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
15996 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
15997 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
15998   $as_echo_n "(cached) " >&6
15999 else
16000   ac_cv_type_struct_sockaddr_storage=no
16001 cat >conftest.$ac_ext <<_ACEOF
16002 /* confdefs.h.  */
16003 _ACEOF
16004 cat confdefs.h >>conftest.$ac_ext
16005 cat >>conftest.$ac_ext <<_ACEOF
16006 /* end confdefs.h.  */
16007 #include <sys/types.h>
16008 #ifdef HAVE_SYS_SOCKET_H
16009 #include <sys/socket.h>
16010 #endif
16011
16012
16013 int
16014 main ()
16015 {
16016 if (sizeof (struct sockaddr_storage))
16017        return 0;
16018   ;
16019   return 0;
16020 }
16021 _ACEOF
16022 rm -f conftest.$ac_objext
16023 if { (ac_try="$ac_compile"
16024 case "(($ac_try" in
16025   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16026   *) ac_try_echo=$ac_try;;
16027 esac
16028 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16029 $as_echo "$ac_try_echo") >&5
16030   (eval "$ac_compile") 2>conftest.er1
16031   ac_status=$?
16032   grep -v '^ *+' conftest.er1 >conftest.err
16033   rm -f conftest.er1
16034   cat conftest.err >&5
16035   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16036   (exit $ac_status); } && {
16037          test -z "$ac_c_werror_flag" ||
16038          test ! -s conftest.err
16039        } && test -s conftest.$ac_objext; then
16040   cat >conftest.$ac_ext <<_ACEOF
16041 /* confdefs.h.  */
16042 _ACEOF
16043 cat confdefs.h >>conftest.$ac_ext
16044 cat >>conftest.$ac_ext <<_ACEOF
16045 /* end confdefs.h.  */
16046 #include <sys/types.h>
16047 #ifdef HAVE_SYS_SOCKET_H
16048 #include <sys/socket.h>
16049 #endif
16050
16051
16052 int
16053 main ()
16054 {
16055 if (sizeof ((struct sockaddr_storage)))
16056           return 0;
16057   ;
16058   return 0;
16059 }
16060 _ACEOF
16061 rm -f conftest.$ac_objext
16062 if { (ac_try="$ac_compile"
16063 case "(($ac_try" in
16064   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16065   *) ac_try_echo=$ac_try;;
16066 esac
16067 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16068 $as_echo "$ac_try_echo") >&5
16069   (eval "$ac_compile") 2>conftest.er1
16070   ac_status=$?
16071   grep -v '^ *+' conftest.er1 >conftest.err
16072   rm -f conftest.er1
16073   cat conftest.err >&5
16074   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16075   (exit $ac_status); } && {
16076          test -z "$ac_c_werror_flag" ||
16077          test ! -s conftest.err
16078        } && test -s conftest.$ac_objext; then
16079   :
16080 else
16081   $as_echo "$as_me: failed program was:" >&5
16082 sed 's/^/| /' conftest.$ac_ext >&5
16083
16084         ac_cv_type_struct_sockaddr_storage=yes
16085 fi
16086
16087 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16088 else
16089   $as_echo "$as_me: failed program was:" >&5
16090 sed 's/^/| /' conftest.$ac_ext >&5
16091
16092
16093 fi
16094
16095 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16096 fi
16097 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
16098 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
16099 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
16100
16101 cat >>confdefs.h <<_ACEOF
16102 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
16103 _ACEOF
16104
16105
16106 fi
16107
16108 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
16109 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
16110 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
16111   $as_echo_n "(cached) " >&6
16112 else
16113   cat >conftest.$ac_ext <<_ACEOF
16114 /* confdefs.h.  */
16115 _ACEOF
16116 cat confdefs.h >>conftest.$ac_ext
16117 cat >>conftest.$ac_ext <<_ACEOF
16118 /* end confdefs.h.  */
16119 #include <sys/types.h>
16120 #ifdef HAVE_SYS_SOCKET_H
16121 #include <sys/socket.h>
16122 #endif
16123
16124
16125 int
16126 main ()
16127 {
16128 static struct sockaddr_storage ac_aggr;
16129 if (ac_aggr.ss_family)
16130 return 0;
16131   ;
16132   return 0;
16133 }
16134 _ACEOF
16135 rm -f conftest.$ac_objext
16136 if { (ac_try="$ac_compile"
16137 case "(($ac_try" in
16138   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16139   *) ac_try_echo=$ac_try;;
16140 esac
16141 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16142 $as_echo "$ac_try_echo") >&5
16143   (eval "$ac_compile") 2>conftest.er1
16144   ac_status=$?
16145   grep -v '^ *+' conftest.er1 >conftest.err
16146   rm -f conftest.er1
16147   cat conftest.err >&5
16148   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16149   (exit $ac_status); } && {
16150          test -z "$ac_c_werror_flag" ||
16151          test ! -s conftest.err
16152        } && test -s conftest.$ac_objext; then
16153   ac_cv_member_struct_sockaddr_storage_ss_family=yes
16154 else
16155   $as_echo "$as_me: failed program was:" >&5
16156 sed 's/^/| /' conftest.$ac_ext >&5
16157
16158         cat >conftest.$ac_ext <<_ACEOF
16159 /* confdefs.h.  */
16160 _ACEOF
16161 cat confdefs.h >>conftest.$ac_ext
16162 cat >>conftest.$ac_ext <<_ACEOF
16163 /* end confdefs.h.  */
16164 #include <sys/types.h>
16165 #ifdef HAVE_SYS_SOCKET_H
16166 #include <sys/socket.h>
16167 #endif
16168
16169
16170 int
16171 main ()
16172 {
16173 static struct sockaddr_storage ac_aggr;
16174 if (sizeof ac_aggr.ss_family)
16175 return 0;
16176   ;
16177   return 0;
16178 }
16179 _ACEOF
16180 rm -f conftest.$ac_objext
16181 if { (ac_try="$ac_compile"
16182 case "(($ac_try" in
16183   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16184   *) ac_try_echo=$ac_try;;
16185 esac
16186 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16187 $as_echo "$ac_try_echo") >&5
16188   (eval "$ac_compile") 2>conftest.er1
16189   ac_status=$?
16190   grep -v '^ *+' conftest.er1 >conftest.err
16191   rm -f conftest.er1
16192   cat conftest.err >&5
16193   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16194   (exit $ac_status); } && {
16195          test -z "$ac_c_werror_flag" ||
16196          test ! -s conftest.err
16197        } && test -s conftest.$ac_objext; then
16198   ac_cv_member_struct_sockaddr_storage_ss_family=yes
16199 else
16200   $as_echo "$as_me: failed program was:" >&5
16201 sed 's/^/| /' conftest.$ac_ext >&5
16202
16203         ac_cv_member_struct_sockaddr_storage_ss_family=no
16204 fi
16205
16206 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16207 fi
16208
16209 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16210 fi
16211 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
16212 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
16213 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
16214
16215 cat >>confdefs.h <<_ACEOF
16216 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
16217 _ACEOF
16218
16219
16220 fi
16221 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
16222 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
16223 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
16224   $as_echo_n "(cached) " >&6
16225 else
16226   cat >conftest.$ac_ext <<_ACEOF
16227 /* confdefs.h.  */
16228 _ACEOF
16229 cat confdefs.h >>conftest.$ac_ext
16230 cat >>conftest.$ac_ext <<_ACEOF
16231 /* end confdefs.h.  */
16232 #include <sys/types.h>
16233 #ifdef HAVE_SYS_SOCKET_H
16234 #include <sys/socket.h>
16235 #endif
16236
16237
16238 int
16239 main ()
16240 {
16241 static struct sockaddr_storage ac_aggr;
16242 if (ac_aggr.__ss_family)
16243 return 0;
16244   ;
16245   return 0;
16246 }
16247 _ACEOF
16248 rm -f conftest.$ac_objext
16249 if { (ac_try="$ac_compile"
16250 case "(($ac_try" in
16251   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16252   *) ac_try_echo=$ac_try;;
16253 esac
16254 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16255 $as_echo "$ac_try_echo") >&5
16256   (eval "$ac_compile") 2>conftest.er1
16257   ac_status=$?
16258   grep -v '^ *+' conftest.er1 >conftest.err
16259   rm -f conftest.er1
16260   cat conftest.err >&5
16261   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16262   (exit $ac_status); } && {
16263          test -z "$ac_c_werror_flag" ||
16264          test ! -s conftest.err
16265        } && test -s conftest.$ac_objext; then
16266   ac_cv_member_struct_sockaddr_storage___ss_family=yes
16267 else
16268   $as_echo "$as_me: failed program was:" >&5
16269 sed 's/^/| /' conftest.$ac_ext >&5
16270
16271         cat >conftest.$ac_ext <<_ACEOF
16272 /* confdefs.h.  */
16273 _ACEOF
16274 cat confdefs.h >>conftest.$ac_ext
16275 cat >>conftest.$ac_ext <<_ACEOF
16276 /* end confdefs.h.  */
16277 #include <sys/types.h>
16278 #ifdef HAVE_SYS_SOCKET_H
16279 #include <sys/socket.h>
16280 #endif
16281
16282
16283 int
16284 main ()
16285 {
16286 static struct sockaddr_storage ac_aggr;
16287 if (sizeof ac_aggr.__ss_family)
16288 return 0;
16289   ;
16290   return 0;
16291 }
16292 _ACEOF
16293 rm -f conftest.$ac_objext
16294 if { (ac_try="$ac_compile"
16295 case "(($ac_try" in
16296   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16297   *) ac_try_echo=$ac_try;;
16298 esac
16299 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16300 $as_echo "$ac_try_echo") >&5
16301   (eval "$ac_compile") 2>conftest.er1
16302   ac_status=$?
16303   grep -v '^ *+' conftest.er1 >conftest.err
16304   rm -f conftest.er1
16305   cat conftest.err >&5
16306   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16307   (exit $ac_status); } && {
16308          test -z "$ac_c_werror_flag" ||
16309          test ! -s conftest.err
16310        } && test -s conftest.$ac_objext; then
16311   ac_cv_member_struct_sockaddr_storage___ss_family=yes
16312 else
16313   $as_echo "$as_me: failed program was:" >&5
16314 sed 's/^/| /' conftest.$ac_ext >&5
16315
16316         ac_cv_member_struct_sockaddr_storage___ss_family=no
16317 fi
16318
16319 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16320 fi
16321
16322 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16323 fi
16324 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
16325 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
16326 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
16327
16328 cat >>confdefs.h <<_ACEOF
16329 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
16330 _ACEOF
16331
16332
16333 fi
16334 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
16335 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
16336 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
16337   $as_echo_n "(cached) " >&6
16338 else
16339   cat >conftest.$ac_ext <<_ACEOF
16340 /* confdefs.h.  */
16341 _ACEOF
16342 cat confdefs.h >>conftest.$ac_ext
16343 cat >>conftest.$ac_ext <<_ACEOF
16344 /* end confdefs.h.  */
16345 #include <sys/types.h>
16346 #ifdef HAVE_SYS_SOCKET_H
16347 #include <sys/socket.h>
16348 #endif
16349
16350
16351 int
16352 main ()
16353 {
16354 static struct sockaddr_storage ac_aggr;
16355 if (ac_aggr.ss_len)
16356 return 0;
16357   ;
16358   return 0;
16359 }
16360 _ACEOF
16361 rm -f conftest.$ac_objext
16362 if { (ac_try="$ac_compile"
16363 case "(($ac_try" in
16364   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16365   *) ac_try_echo=$ac_try;;
16366 esac
16367 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16368 $as_echo "$ac_try_echo") >&5
16369   (eval "$ac_compile") 2>conftest.er1
16370   ac_status=$?
16371   grep -v '^ *+' conftest.er1 >conftest.err
16372   rm -f conftest.er1
16373   cat conftest.err >&5
16374   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16375   (exit $ac_status); } && {
16376          test -z "$ac_c_werror_flag" ||
16377          test ! -s conftest.err
16378        } && test -s conftest.$ac_objext; then
16379   ac_cv_member_struct_sockaddr_storage_ss_len=yes
16380 else
16381   $as_echo "$as_me: failed program was:" >&5
16382 sed 's/^/| /' conftest.$ac_ext >&5
16383
16384         cat >conftest.$ac_ext <<_ACEOF
16385 /* confdefs.h.  */
16386 _ACEOF
16387 cat confdefs.h >>conftest.$ac_ext
16388 cat >>conftest.$ac_ext <<_ACEOF
16389 /* end confdefs.h.  */
16390 #include <sys/types.h>
16391 #ifdef HAVE_SYS_SOCKET_H
16392 #include <sys/socket.h>
16393 #endif
16394
16395
16396 int
16397 main ()
16398 {
16399 static struct sockaddr_storage ac_aggr;
16400 if (sizeof ac_aggr.ss_len)
16401 return 0;
16402   ;
16403   return 0;
16404 }
16405 _ACEOF
16406 rm -f conftest.$ac_objext
16407 if { (ac_try="$ac_compile"
16408 case "(($ac_try" in
16409   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16410   *) ac_try_echo=$ac_try;;
16411 esac
16412 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16413 $as_echo "$ac_try_echo") >&5
16414   (eval "$ac_compile") 2>conftest.er1
16415   ac_status=$?
16416   grep -v '^ *+' conftest.er1 >conftest.err
16417   rm -f conftest.er1
16418   cat conftest.err >&5
16419   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16420   (exit $ac_status); } && {
16421          test -z "$ac_c_werror_flag" ||
16422          test ! -s conftest.err
16423        } && test -s conftest.$ac_objext; then
16424   ac_cv_member_struct_sockaddr_storage_ss_len=yes
16425 else
16426   $as_echo "$as_me: failed program was:" >&5
16427 sed 's/^/| /' conftest.$ac_ext >&5
16428
16429         ac_cv_member_struct_sockaddr_storage_ss_len=no
16430 fi
16431
16432 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16433 fi
16434
16435 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16436 fi
16437 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
16438 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
16439 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
16440
16441 cat >>confdefs.h <<_ACEOF
16442 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
16443 _ACEOF
16444
16445
16446 fi
16447 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
16448 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
16449 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
16450   $as_echo_n "(cached) " >&6
16451 else
16452   cat >conftest.$ac_ext <<_ACEOF
16453 /* confdefs.h.  */
16454 _ACEOF
16455 cat confdefs.h >>conftest.$ac_ext
16456 cat >>conftest.$ac_ext <<_ACEOF
16457 /* end confdefs.h.  */
16458 #include <sys/types.h>
16459 #ifdef HAVE_SYS_SOCKET_H
16460 #include <sys/socket.h>
16461 #endif
16462
16463
16464 int
16465 main ()
16466 {
16467 static struct sockaddr_storage ac_aggr;
16468 if (ac_aggr.__ss_len)
16469 return 0;
16470   ;
16471   return 0;
16472 }
16473 _ACEOF
16474 rm -f conftest.$ac_objext
16475 if { (ac_try="$ac_compile"
16476 case "(($ac_try" in
16477   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16478   *) ac_try_echo=$ac_try;;
16479 esac
16480 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16481 $as_echo "$ac_try_echo") >&5
16482   (eval "$ac_compile") 2>conftest.er1
16483   ac_status=$?
16484   grep -v '^ *+' conftest.er1 >conftest.err
16485   rm -f conftest.er1
16486   cat conftest.err >&5
16487   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16488   (exit $ac_status); } && {
16489          test -z "$ac_c_werror_flag" ||
16490          test ! -s conftest.err
16491        } && test -s conftest.$ac_objext; then
16492   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16493 else
16494   $as_echo "$as_me: failed program was:" >&5
16495 sed 's/^/| /' conftest.$ac_ext >&5
16496
16497         cat >conftest.$ac_ext <<_ACEOF
16498 /* confdefs.h.  */
16499 _ACEOF
16500 cat confdefs.h >>conftest.$ac_ext
16501 cat >>conftest.$ac_ext <<_ACEOF
16502 /* end confdefs.h.  */
16503 #include <sys/types.h>
16504 #ifdef HAVE_SYS_SOCKET_H
16505 #include <sys/socket.h>
16506 #endif
16507
16508
16509 int
16510 main ()
16511 {
16512 static struct sockaddr_storage ac_aggr;
16513 if (sizeof ac_aggr.__ss_len)
16514 return 0;
16515   ;
16516   return 0;
16517 }
16518 _ACEOF
16519 rm -f conftest.$ac_objext
16520 if { (ac_try="$ac_compile"
16521 case "(($ac_try" in
16522   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16523   *) ac_try_echo=$ac_try;;
16524 esac
16525 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16526 $as_echo "$ac_try_echo") >&5
16527   (eval "$ac_compile") 2>conftest.er1
16528   ac_status=$?
16529   grep -v '^ *+' conftest.er1 >conftest.err
16530   rm -f conftest.er1
16531   cat conftest.err >&5
16532   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16533   (exit $ac_status); } && {
16534          test -z "$ac_c_werror_flag" ||
16535          test ! -s conftest.err
16536        } && test -s conftest.$ac_objext; then
16537   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16538 else
16539   $as_echo "$as_me: failed program was:" >&5
16540 sed 's/^/| /' conftest.$ac_ext >&5
16541
16542         ac_cv_member_struct_sockaddr_storage___ss_len=no
16543 fi
16544
16545 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16546 fi
16547
16548 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16549 fi
16550 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
16551 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
16552 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
16553
16554 cat >>confdefs.h <<_ACEOF
16555 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
16556 _ACEOF
16557
16558
16559 fi
16560 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
16561 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
16562 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
16563   $as_echo_n "(cached) " >&6
16564 else
16565   cat >conftest.$ac_ext <<_ACEOF
16566 /* confdefs.h.  */
16567 _ACEOF
16568 cat confdefs.h >>conftest.$ac_ext
16569 cat >>conftest.$ac_ext <<_ACEOF
16570 /* end confdefs.h.  */
16571 #include <sys/types.h>
16572 #ifdef HAVE_SYS_SOCKET_H
16573 #include <sys/socket.h>
16574 #endif
16575
16576
16577 int
16578 main ()
16579 {
16580 static struct sockaddr ac_aggr;
16581 if (ac_aggr.sa_len)
16582 return 0;
16583   ;
16584   return 0;
16585 }
16586 _ACEOF
16587 rm -f conftest.$ac_objext
16588 if { (ac_try="$ac_compile"
16589 case "(($ac_try" in
16590   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16591   *) ac_try_echo=$ac_try;;
16592 esac
16593 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16594 $as_echo "$ac_try_echo") >&5
16595   (eval "$ac_compile") 2>conftest.er1
16596   ac_status=$?
16597   grep -v '^ *+' conftest.er1 >conftest.err
16598   rm -f conftest.er1
16599   cat conftest.err >&5
16600   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16601   (exit $ac_status); } && {
16602          test -z "$ac_c_werror_flag" ||
16603          test ! -s conftest.err
16604        } && test -s conftest.$ac_objext; then
16605   ac_cv_member_struct_sockaddr_sa_len=yes
16606 else
16607   $as_echo "$as_me: failed program was:" >&5
16608 sed 's/^/| /' conftest.$ac_ext >&5
16609
16610         cat >conftest.$ac_ext <<_ACEOF
16611 /* confdefs.h.  */
16612 _ACEOF
16613 cat confdefs.h >>conftest.$ac_ext
16614 cat >>conftest.$ac_ext <<_ACEOF
16615 /* end confdefs.h.  */
16616 #include <sys/types.h>
16617 #ifdef HAVE_SYS_SOCKET_H
16618 #include <sys/socket.h>
16619 #endif
16620
16621
16622 int
16623 main ()
16624 {
16625 static struct sockaddr ac_aggr;
16626 if (sizeof ac_aggr.sa_len)
16627 return 0;
16628   ;
16629   return 0;
16630 }
16631 _ACEOF
16632 rm -f conftest.$ac_objext
16633 if { (ac_try="$ac_compile"
16634 case "(($ac_try" in
16635   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16636   *) ac_try_echo=$ac_try;;
16637 esac
16638 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16639 $as_echo "$ac_try_echo") >&5
16640   (eval "$ac_compile") 2>conftest.er1
16641   ac_status=$?
16642   grep -v '^ *+' conftest.er1 >conftest.err
16643   rm -f conftest.er1
16644   cat conftest.err >&5
16645   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16646   (exit $ac_status); } && {
16647          test -z "$ac_c_werror_flag" ||
16648          test ! -s conftest.err
16649        } && test -s conftest.$ac_objext; then
16650   ac_cv_member_struct_sockaddr_sa_len=yes
16651 else
16652   $as_echo "$as_me: failed program was:" >&5
16653 sed 's/^/| /' conftest.$ac_ext >&5
16654
16655         ac_cv_member_struct_sockaddr_sa_len=no
16656 fi
16657
16658 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16659 fi
16660
16661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16662 fi
16663 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
16664 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
16665 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
16666
16667 cat >>confdefs.h <<_ACEOF
16668 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
16669 _ACEOF
16670
16671
16672 fi
16673
16674 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
16675 $as_echo_n "checking for struct addrinfo... " >&6; }
16676 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
16677   $as_echo_n "(cached) " >&6
16678 else
16679   ac_cv_type_struct_addrinfo=no
16680 cat >conftest.$ac_ext <<_ACEOF
16681 /* confdefs.h.  */
16682 _ACEOF
16683 cat confdefs.h >>conftest.$ac_ext
16684 cat >>conftest.$ac_ext <<_ACEOF
16685 /* end confdefs.h.  */
16686 #include <sys/types.h>
16687 #include <sys/socket.h>
16688 #include <netdb.h>
16689
16690
16691 int
16692 main ()
16693 {
16694 if (sizeof (struct addrinfo))
16695        return 0;
16696   ;
16697   return 0;
16698 }
16699 _ACEOF
16700 rm -f conftest.$ac_objext
16701 if { (ac_try="$ac_compile"
16702 case "(($ac_try" in
16703   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16704   *) ac_try_echo=$ac_try;;
16705 esac
16706 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16707 $as_echo "$ac_try_echo") >&5
16708   (eval "$ac_compile") 2>conftest.er1
16709   ac_status=$?
16710   grep -v '^ *+' conftest.er1 >conftest.err
16711   rm -f conftest.er1
16712   cat conftest.err >&5
16713   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16714   (exit $ac_status); } && {
16715          test -z "$ac_c_werror_flag" ||
16716          test ! -s conftest.err
16717        } && test -s conftest.$ac_objext; then
16718   cat >conftest.$ac_ext <<_ACEOF
16719 /* confdefs.h.  */
16720 _ACEOF
16721 cat confdefs.h >>conftest.$ac_ext
16722 cat >>conftest.$ac_ext <<_ACEOF
16723 /* end confdefs.h.  */
16724 #include <sys/types.h>
16725 #include <sys/socket.h>
16726 #include <netdb.h>
16727
16728
16729 int
16730 main ()
16731 {
16732 if (sizeof ((struct addrinfo)))
16733           return 0;
16734   ;
16735   return 0;
16736 }
16737 _ACEOF
16738 rm -f conftest.$ac_objext
16739 if { (ac_try="$ac_compile"
16740 case "(($ac_try" in
16741   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16742   *) ac_try_echo=$ac_try;;
16743 esac
16744 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16745 $as_echo "$ac_try_echo") >&5
16746   (eval "$ac_compile") 2>conftest.er1
16747   ac_status=$?
16748   grep -v '^ *+' conftest.er1 >conftest.err
16749   rm -f conftest.er1
16750   cat conftest.err >&5
16751   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16752   (exit $ac_status); } && {
16753          test -z "$ac_c_werror_flag" ||
16754          test ! -s conftest.err
16755        } && test -s conftest.$ac_objext; then
16756   :
16757 else
16758   $as_echo "$as_me: failed program was:" >&5
16759 sed 's/^/| /' conftest.$ac_ext >&5
16760
16761         ac_cv_type_struct_addrinfo=yes
16762 fi
16763
16764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16765 else
16766   $as_echo "$as_me: failed program was:" >&5
16767 sed 's/^/| /' conftest.$ac_ext >&5
16768
16769
16770 fi
16771
16772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16773 fi
16774 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
16775 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
16776 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
16777
16778 cat >>confdefs.h <<_ACEOF
16779 #define HAVE_STRUCT_ADDRINFO 1
16780 _ACEOF
16781
16782
16783 fi
16784
16785
16786   { $as_echo "$as_me:$LINENO: checking for intptr_t" >&5
16787 $as_echo_n "checking for intptr_t... " >&6; }
16788 if test "${ac_cv_type_intptr_t+set}" = set; then
16789   $as_echo_n "(cached) " >&6
16790 else
16791   ac_cv_type_intptr_t=no
16792 cat >conftest.$ac_ext <<_ACEOF
16793 /* confdefs.h.  */
16794 _ACEOF
16795 cat confdefs.h >>conftest.$ac_ext
16796 cat >>conftest.$ac_ext <<_ACEOF
16797 /* end confdefs.h.  */
16798 $ac_includes_default
16799 int
16800 main ()
16801 {
16802 if (sizeof (intptr_t))
16803        return 0;
16804   ;
16805   return 0;
16806 }
16807 _ACEOF
16808 rm -f conftest.$ac_objext
16809 if { (ac_try="$ac_compile"
16810 case "(($ac_try" in
16811   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16812   *) ac_try_echo=$ac_try;;
16813 esac
16814 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16815 $as_echo "$ac_try_echo") >&5
16816   (eval "$ac_compile") 2>conftest.er1
16817   ac_status=$?
16818   grep -v '^ *+' conftest.er1 >conftest.err
16819   rm -f conftest.er1
16820   cat conftest.err >&5
16821   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16822   (exit $ac_status); } && {
16823          test -z "$ac_c_werror_flag" ||
16824          test ! -s conftest.err
16825        } && test -s conftest.$ac_objext; then
16826   cat >conftest.$ac_ext <<_ACEOF
16827 /* confdefs.h.  */
16828 _ACEOF
16829 cat confdefs.h >>conftest.$ac_ext
16830 cat >>conftest.$ac_ext <<_ACEOF
16831 /* end confdefs.h.  */
16832 $ac_includes_default
16833 int
16834 main ()
16835 {
16836 if (sizeof ((intptr_t)))
16837           return 0;
16838   ;
16839   return 0;
16840 }
16841 _ACEOF
16842 rm -f conftest.$ac_objext
16843 if { (ac_try="$ac_compile"
16844 case "(($ac_try" in
16845   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16846   *) ac_try_echo=$ac_try;;
16847 esac
16848 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16849 $as_echo "$ac_try_echo") >&5
16850   (eval "$ac_compile") 2>conftest.er1
16851   ac_status=$?
16852   grep -v '^ *+' conftest.er1 >conftest.err
16853   rm -f conftest.er1
16854   cat conftest.err >&5
16855   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16856   (exit $ac_status); } && {
16857          test -z "$ac_c_werror_flag" ||
16858          test ! -s conftest.err
16859        } && test -s conftest.$ac_objext; then
16860   :
16861 else
16862   $as_echo "$as_me: failed program was:" >&5
16863 sed 's/^/| /' conftest.$ac_ext >&5
16864
16865         ac_cv_type_intptr_t=yes
16866 fi
16867
16868 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16869 else
16870   $as_echo "$as_me: failed program was:" >&5
16871 sed 's/^/| /' conftest.$ac_ext >&5
16872
16873
16874 fi
16875
16876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16877 fi
16878 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
16879 $as_echo "$ac_cv_type_intptr_t" >&6; }
16880 if test "x$ac_cv_type_intptr_t" = x""yes; then
16881
16882 cat >>confdefs.h <<\_ACEOF
16883 #define HAVE_INTPTR_T 1
16884 _ACEOF
16885
16886 else
16887   for ac_type in 'int' 'long int' 'long long int'; do
16888        cat >conftest.$ac_ext <<_ACEOF
16889 /* confdefs.h.  */
16890 _ACEOF
16891 cat confdefs.h >>conftest.$ac_ext
16892 cat >>conftest.$ac_ext <<_ACEOF
16893 /* end confdefs.h.  */
16894 $ac_includes_default
16895 int
16896 main ()
16897 {
16898 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16899 test_array [0] = 0
16900
16901   ;
16902   return 0;
16903 }
16904 _ACEOF
16905 rm -f conftest.$ac_objext
16906 if { (ac_try="$ac_compile"
16907 case "(($ac_try" in
16908   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16909   *) ac_try_echo=$ac_try;;
16910 esac
16911 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16912 $as_echo "$ac_try_echo") >&5
16913   (eval "$ac_compile") 2>conftest.er1
16914   ac_status=$?
16915   grep -v '^ *+' conftest.er1 >conftest.err
16916   rm -f conftest.er1
16917   cat conftest.err >&5
16918   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16919   (exit $ac_status); } && {
16920          test -z "$ac_c_werror_flag" ||
16921          test ! -s conftest.err
16922        } && test -s conftest.$ac_objext; then
16923
16924 cat >>confdefs.h <<_ACEOF
16925 #define intptr_t $ac_type
16926 _ACEOF
16927
16928           ac_type=
16929 else
16930   $as_echo "$as_me: failed program was:" >&5
16931 sed 's/^/| /' conftest.$ac_ext >&5
16932
16933
16934 fi
16935
16936 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16937        test -z "$ac_type" && break
16938      done
16939 fi
16940
16941
16942
16943   { $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
16944 $as_echo_n "checking for uintptr_t... " >&6; }
16945 if test "${ac_cv_type_uintptr_t+set}" = set; then
16946   $as_echo_n "(cached) " >&6
16947 else
16948   ac_cv_type_uintptr_t=no
16949 cat >conftest.$ac_ext <<_ACEOF
16950 /* confdefs.h.  */
16951 _ACEOF
16952 cat confdefs.h >>conftest.$ac_ext
16953 cat >>conftest.$ac_ext <<_ACEOF
16954 /* end confdefs.h.  */
16955 $ac_includes_default
16956 int
16957 main ()
16958 {
16959 if (sizeof (uintptr_t))
16960        return 0;
16961   ;
16962   return 0;
16963 }
16964 _ACEOF
16965 rm -f conftest.$ac_objext
16966 if { (ac_try="$ac_compile"
16967 case "(($ac_try" in
16968   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16969   *) ac_try_echo=$ac_try;;
16970 esac
16971 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16972 $as_echo "$ac_try_echo") >&5
16973   (eval "$ac_compile") 2>conftest.er1
16974   ac_status=$?
16975   grep -v '^ *+' conftest.er1 >conftest.err
16976   rm -f conftest.er1
16977   cat conftest.err >&5
16978   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16979   (exit $ac_status); } && {
16980          test -z "$ac_c_werror_flag" ||
16981          test ! -s conftest.err
16982        } && test -s conftest.$ac_objext; then
16983   cat >conftest.$ac_ext <<_ACEOF
16984 /* confdefs.h.  */
16985 _ACEOF
16986 cat confdefs.h >>conftest.$ac_ext
16987 cat >>conftest.$ac_ext <<_ACEOF
16988 /* end confdefs.h.  */
16989 $ac_includes_default
16990 int
16991 main ()
16992 {
16993 if (sizeof ((uintptr_t)))
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   :
17018 else
17019   $as_echo "$as_me: failed program was:" >&5
17020 sed 's/^/| /' conftest.$ac_ext >&5
17021
17022         ac_cv_type_uintptr_t=yes
17023 fi
17024
17025 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17026 else
17027   $as_echo "$as_me: failed program was:" >&5
17028 sed 's/^/| /' conftest.$ac_ext >&5
17029
17030
17031 fi
17032
17033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17034 fi
17035 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
17036 $as_echo "$ac_cv_type_uintptr_t" >&6; }
17037 if test "x$ac_cv_type_uintptr_t" = x""yes; then
17038
17039 cat >>confdefs.h <<\_ACEOF
17040 #define HAVE_UINTPTR_T 1
17041 _ACEOF
17042
17043 else
17044   for ac_type in 'unsigned int' 'unsigned long int' \
17045         'unsigned long long int'; do
17046        cat >conftest.$ac_ext <<_ACEOF
17047 /* confdefs.h.  */
17048 _ACEOF
17049 cat confdefs.h >>conftest.$ac_ext
17050 cat >>conftest.$ac_ext <<_ACEOF
17051 /* end confdefs.h.  */
17052 $ac_includes_default
17053 int
17054 main ()
17055 {
17056 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
17057 test_array [0] = 0
17058
17059   ;
17060   return 0;
17061 }
17062 _ACEOF
17063 rm -f conftest.$ac_objext
17064 if { (ac_try="$ac_compile"
17065 case "(($ac_try" in
17066   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17067   *) ac_try_echo=$ac_try;;
17068 esac
17069 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17070 $as_echo "$ac_try_echo") >&5
17071   (eval "$ac_compile") 2>conftest.er1
17072   ac_status=$?
17073   grep -v '^ *+' conftest.er1 >conftest.err
17074   rm -f conftest.er1
17075   cat conftest.err >&5
17076   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17077   (exit $ac_status); } && {
17078          test -z "$ac_c_werror_flag" ||
17079          test ! -s conftest.err
17080        } && test -s conftest.$ac_objext; then
17081
17082 cat >>confdefs.h <<_ACEOF
17083 #define uintptr_t $ac_type
17084 _ACEOF
17085
17086           ac_type=
17087 else
17088   $as_echo "$as_me: failed program was:" >&5
17089 sed 's/^/| /' conftest.$ac_ext >&5
17090
17091
17092 fi
17093
17094 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17095        test -z "$ac_type" && break
17096      done
17097 fi
17098
17099
17100
17101   { $as_echo "$as_me:$LINENO: checking for long long int" >&5
17102 $as_echo_n "checking for long long int... " >&6; }
17103 if test "${ac_cv_type_long_long_int+set}" = set; then
17104   $as_echo_n "(cached) " >&6
17105 else
17106   cat >conftest.$ac_ext <<_ACEOF
17107
17108   /* confdefs.h.  */
17109 _ACEOF
17110 cat confdefs.h >>conftest.$ac_ext
17111 cat >>conftest.$ac_ext <<_ACEOF
17112 /* end confdefs.h.  */
17113 /* For now, do not test the preprocessor; as of 2007 there are too many
17114          implementations with broken preprocessors.  Perhaps this can
17115          be revisited in 2012.  In the meantime, code should not expect
17116          #if to work with literals wider than 32 bits.  */
17117       /* Test literals.  */
17118       long long int ll = 9223372036854775807ll;
17119       long long int nll = -9223372036854775807LL;
17120       unsigned long long int ull = 18446744073709551615ULL;
17121       /* Test constant expressions.   */
17122       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17123                      ? 1 : -1)];
17124       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17125                      ? 1 : -1)];
17126       int i = 63;
17127 int
17128 main ()
17129 {
17130 /* Test availability of runtime routines for shift and division.  */
17131       long long int llmax = 9223372036854775807ll;
17132       unsigned long long int ullmax = 18446744073709551615ull;
17133       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17134               | (llmax / ll) | (llmax % ll)
17135               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17136               | (ullmax / ull) | (ullmax % ull));
17137   ;
17138   return 0;
17139 }
17140
17141 _ACEOF
17142 rm -f conftest.$ac_objext conftest$ac_exeext
17143 if { (ac_try="$ac_link"
17144 case "(($ac_try" in
17145   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17146   *) ac_try_echo=$ac_try;;
17147 esac
17148 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17149 $as_echo "$ac_try_echo") >&5
17150   (eval "$ac_link") 2>conftest.er1
17151   ac_status=$?
17152   grep -v '^ *+' conftest.er1 >conftest.err
17153   rm -f conftest.er1
17154   cat conftest.err >&5
17155   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17156   (exit $ac_status); } && {
17157          test -z "$ac_c_werror_flag" ||
17158          test ! -s conftest.err
17159        } && test -s conftest$ac_exeext && {
17160          test "$cross_compiling" = yes ||
17161          $as_test_x conftest$ac_exeext
17162        }; then
17163                         if test "$cross_compiling" = yes; then
17164   ac_cv_type_long_long_int=yes
17165 else
17166   cat >conftest.$ac_ext <<_ACEOF
17167 /* confdefs.h.  */
17168 _ACEOF
17169 cat confdefs.h >>conftest.$ac_ext
17170 cat >>conftest.$ac_ext <<_ACEOF
17171 /* end confdefs.h.  */
17172 #include <limits.h>
17173                #ifndef LLONG_MAX
17174                # define HALF \
17175                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17176                # define LLONG_MAX (HALF - 1 + HALF)
17177                #endif
17178 int
17179 main ()
17180 {
17181 long long int n = 1;
17182                int i;
17183                for (i = 0; ; i++)
17184                  {
17185                    long long int m = n << i;
17186                    if (m >> i != n)
17187                      return 1;
17188                    if (LLONG_MAX / 2 < m)
17189                      break;
17190                  }
17191                return 0;
17192   ;
17193   return 0;
17194 }
17195 _ACEOF
17196 rm -f conftest$ac_exeext
17197 if { (ac_try="$ac_link"
17198 case "(($ac_try" in
17199   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17200   *) ac_try_echo=$ac_try;;
17201 esac
17202 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17203 $as_echo "$ac_try_echo") >&5
17204   (eval "$ac_link") 2>&5
17205   ac_status=$?
17206   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17207   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17208   { (case "(($ac_try" in
17209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17210   *) ac_try_echo=$ac_try;;
17211 esac
17212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17213 $as_echo "$ac_try_echo") >&5
17214   (eval "$ac_try") 2>&5
17215   ac_status=$?
17216   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17217   (exit $ac_status); }; }; then
17218   ac_cv_type_long_long_int=yes
17219 else
17220   $as_echo "$as_me: program exited with status $ac_status" >&5
17221 $as_echo "$as_me: failed program was:" >&5
17222 sed 's/^/| /' conftest.$ac_ext >&5
17223
17224 ( exit $ac_status )
17225 ac_cv_type_long_long_int=no
17226 fi
17227 rm -rf conftest.dSYM
17228 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17229 fi
17230
17231
17232 else
17233   $as_echo "$as_me: failed program was:" >&5
17234 sed 's/^/| /' conftest.$ac_ext >&5
17235
17236         ac_cv_type_long_long_int=no
17237 fi
17238
17239 rm -rf conftest.dSYM
17240 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17241       conftest$ac_exeext conftest.$ac_ext
17242 fi
17243 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
17244 $as_echo "$ac_cv_type_long_long_int" >&6; }
17245   if test $ac_cv_type_long_long_int = yes; then
17246
17247 cat >>confdefs.h <<\_ACEOF
17248 #define HAVE_LONG_LONG_INT 1
17249 _ACEOF
17250
17251   fi
17252
17253
17254 { $as_echo "$as_me:$LINENO: checking for locale_t" >&5
17255 $as_echo_n "checking for locale_t... " >&6; }
17256 if test "${pgac_cv_type_locale_t+set}" = set; then
17257   $as_echo_n "(cached) " >&6
17258 else
17259   cat >conftest.$ac_ext <<_ACEOF
17260 /* confdefs.h.  */
17261 _ACEOF
17262 cat confdefs.h >>conftest.$ac_ext
17263 cat >>conftest.$ac_ext <<_ACEOF
17264 /* end confdefs.h.  */
17265 #include <locale.h>
17266 locale_t x;
17267 int
17268 main ()
17269 {
17270
17271   ;
17272   return 0;
17273 }
17274 _ACEOF
17275 rm -f conftest.$ac_objext
17276 if { (ac_try="$ac_compile"
17277 case "(($ac_try" in
17278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17279   *) ac_try_echo=$ac_try;;
17280 esac
17281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17282 $as_echo "$ac_try_echo") >&5
17283   (eval "$ac_compile") 2>conftest.er1
17284   ac_status=$?
17285   grep -v '^ *+' conftest.er1 >conftest.err
17286   rm -f conftest.er1
17287   cat conftest.err >&5
17288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17289   (exit $ac_status); } && {
17290          test -z "$ac_c_werror_flag" ||
17291          test ! -s conftest.err
17292        } && test -s conftest.$ac_objext; then
17293   pgac_cv_type_locale_t=yes
17294 else
17295   $as_echo "$as_me: failed program was:" >&5
17296 sed 's/^/| /' conftest.$ac_ext >&5
17297
17298         cat >conftest.$ac_ext <<_ACEOF
17299 /* confdefs.h.  */
17300 _ACEOF
17301 cat confdefs.h >>conftest.$ac_ext
17302 cat >>conftest.$ac_ext <<_ACEOF
17303 /* end confdefs.h.  */
17304 #include <xlocale.h>
17305 locale_t x;
17306 int
17307 main ()
17308 {
17309
17310   ;
17311   return 0;
17312 }
17313 _ACEOF
17314 rm -f conftest.$ac_objext
17315 if { (ac_try="$ac_compile"
17316 case "(($ac_try" in
17317   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17318   *) ac_try_echo=$ac_try;;
17319 esac
17320 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17321 $as_echo "$ac_try_echo") >&5
17322   (eval "$ac_compile") 2>conftest.er1
17323   ac_status=$?
17324   grep -v '^ *+' conftest.er1 >conftest.err
17325   rm -f conftest.er1
17326   cat conftest.err >&5
17327   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17328   (exit $ac_status); } && {
17329          test -z "$ac_c_werror_flag" ||
17330          test ! -s conftest.err
17331        } && test -s conftest.$ac_objext; then
17332   pgac_cv_type_locale_t='yes (in xlocale.h)'
17333 else
17334   $as_echo "$as_me: failed program was:" >&5
17335 sed 's/^/| /' conftest.$ac_ext >&5
17336
17337         pgac_cv_type_locale_t=no
17338 fi
17339
17340 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17341 fi
17342
17343 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17344 fi
17345 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_locale_t" >&5
17346 $as_echo "$pgac_cv_type_locale_t" >&6; }
17347 if test "$pgac_cv_type_locale_t" != no; then
17348
17349 cat >>confdefs.h <<\_ACEOF
17350 #define HAVE_LOCALE_T 1
17351 _ACEOF
17352
17353 fi
17354 if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then
17355
17356 cat >>confdefs.h <<\_ACEOF
17357 #define LOCALE_T_IN_XLOCALE 1
17358 _ACEOF
17359
17360 fi
17361
17362 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
17363 $as_echo_n "checking for struct cmsgcred... " >&6; }
17364 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
17365   $as_echo_n "(cached) " >&6
17366 else
17367   ac_cv_type_struct_cmsgcred=no
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 #include <sys/socket.h>
17375 #ifdef HAVE_SYS_UCRED_H
17376 #include <sys/ucred.h>
17377 #endif
17378
17379 int
17380 main ()
17381 {
17382 if (sizeof (struct cmsgcred))
17383        return 0;
17384   ;
17385   return 0;
17386 }
17387 _ACEOF
17388 rm -f conftest.$ac_objext
17389 if { (ac_try="$ac_compile"
17390 case "(($ac_try" in
17391   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17392   *) ac_try_echo=$ac_try;;
17393 esac
17394 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17395 $as_echo "$ac_try_echo") >&5
17396   (eval "$ac_compile") 2>conftest.er1
17397   ac_status=$?
17398   grep -v '^ *+' conftest.er1 >conftest.err
17399   rm -f conftest.er1
17400   cat conftest.err >&5
17401   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17402   (exit $ac_status); } && {
17403          test -z "$ac_c_werror_flag" ||
17404          test ! -s conftest.err
17405        } && test -s conftest.$ac_objext; then
17406   cat >conftest.$ac_ext <<_ACEOF
17407 /* confdefs.h.  */
17408 _ACEOF
17409 cat confdefs.h >>conftest.$ac_ext
17410 cat >>conftest.$ac_ext <<_ACEOF
17411 /* end confdefs.h.  */
17412 #include <sys/socket.h>
17413 #ifdef HAVE_SYS_UCRED_H
17414 #include <sys/ucred.h>
17415 #endif
17416
17417 int
17418 main ()
17419 {
17420 if (sizeof ((struct cmsgcred)))
17421           return 0;
17422   ;
17423   return 0;
17424 }
17425 _ACEOF
17426 rm -f conftest.$ac_objext
17427 if { (ac_try="$ac_compile"
17428 case "(($ac_try" in
17429   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17430   *) ac_try_echo=$ac_try;;
17431 esac
17432 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17433 $as_echo "$ac_try_echo") >&5
17434   (eval "$ac_compile") 2>conftest.er1
17435   ac_status=$?
17436   grep -v '^ *+' conftest.er1 >conftest.err
17437   rm -f conftest.er1
17438   cat conftest.err >&5
17439   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17440   (exit $ac_status); } && {
17441          test -z "$ac_c_werror_flag" ||
17442          test ! -s conftest.err
17443        } && test -s conftest.$ac_objext; then
17444   :
17445 else
17446   $as_echo "$as_me: failed program was:" >&5
17447 sed 's/^/| /' conftest.$ac_ext >&5
17448
17449         ac_cv_type_struct_cmsgcred=yes
17450 fi
17451
17452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17453 else
17454   $as_echo "$as_me: failed program was:" >&5
17455 sed 's/^/| /' conftest.$ac_ext >&5
17456
17457
17458 fi
17459
17460 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17461 fi
17462 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
17463 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
17464 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
17465
17466 cat >>confdefs.h <<_ACEOF
17467 #define HAVE_STRUCT_CMSGCRED 1
17468 _ACEOF
17469
17470
17471 fi
17472
17473
17474 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
17475 $as_echo_n "checking for struct option... " >&6; }
17476 if test "${ac_cv_type_struct_option+set}" = set; then
17477   $as_echo_n "(cached) " >&6
17478 else
17479   ac_cv_type_struct_option=no
17480 cat >conftest.$ac_ext <<_ACEOF
17481 /* confdefs.h.  */
17482 _ACEOF
17483 cat confdefs.h >>conftest.$ac_ext
17484 cat >>conftest.$ac_ext <<_ACEOF
17485 /* end confdefs.h.  */
17486 #ifdef HAVE_GETOPT_H
17487 #include <getopt.h>
17488 #endif
17489
17490 int
17491 main ()
17492 {
17493 if (sizeof (struct option))
17494        return 0;
17495   ;
17496   return 0;
17497 }
17498 _ACEOF
17499 rm -f conftest.$ac_objext
17500 if { (ac_try="$ac_compile"
17501 case "(($ac_try" in
17502   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17503   *) ac_try_echo=$ac_try;;
17504 esac
17505 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17506 $as_echo "$ac_try_echo") >&5
17507   (eval "$ac_compile") 2>conftest.er1
17508   ac_status=$?
17509   grep -v '^ *+' conftest.er1 >conftest.err
17510   rm -f conftest.er1
17511   cat conftest.err >&5
17512   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17513   (exit $ac_status); } && {
17514          test -z "$ac_c_werror_flag" ||
17515          test ! -s conftest.err
17516        } && test -s conftest.$ac_objext; then
17517   cat >conftest.$ac_ext <<_ACEOF
17518 /* confdefs.h.  */
17519 _ACEOF
17520 cat confdefs.h >>conftest.$ac_ext
17521 cat >>conftest.$ac_ext <<_ACEOF
17522 /* end confdefs.h.  */
17523 #ifdef HAVE_GETOPT_H
17524 #include <getopt.h>
17525 #endif
17526
17527 int
17528 main ()
17529 {
17530 if (sizeof ((struct option)))
17531           return 0;
17532   ;
17533   return 0;
17534 }
17535 _ACEOF
17536 rm -f conftest.$ac_objext
17537 if { (ac_try="$ac_compile"
17538 case "(($ac_try" in
17539   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17540   *) ac_try_echo=$ac_try;;
17541 esac
17542 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17543 $as_echo "$ac_try_echo") >&5
17544   (eval "$ac_compile") 2>conftest.er1
17545   ac_status=$?
17546   grep -v '^ *+' conftest.er1 >conftest.err
17547   rm -f conftest.er1
17548   cat conftest.err >&5
17549   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17550   (exit $ac_status); } && {
17551          test -z "$ac_c_werror_flag" ||
17552          test ! -s conftest.err
17553        } && test -s conftest.$ac_objext; then
17554   :
17555 else
17556   $as_echo "$as_me: failed program was:" >&5
17557 sed 's/^/| /' conftest.$ac_ext >&5
17558
17559         ac_cv_type_struct_option=yes
17560 fi
17561
17562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17563 else
17564   $as_echo "$as_me: failed program was:" >&5
17565 sed 's/^/| /' conftest.$ac_ext >&5
17566
17567
17568 fi
17569
17570 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17571 fi
17572 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
17573 $as_echo "$ac_cv_type_struct_option" >&6; }
17574 if test "x$ac_cv_type_struct_option" = x""yes; then
17575
17576 cat >>confdefs.h <<_ACEOF
17577 #define HAVE_STRUCT_OPTION 1
17578 _ACEOF
17579
17580
17581 fi
17582
17583
17584 if test "$with_zlib" = yes; then
17585   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
17586   # did not).  While we could work around the lack of z_streamp, it
17587   # seems unwise to encourage people to use such old zlib versions...
17588   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
17589 $as_echo_n "checking for z_streamp... " >&6; }
17590 if test "${ac_cv_type_z_streamp+set}" = set; then
17591   $as_echo_n "(cached) " >&6
17592 else
17593   ac_cv_type_z_streamp=no
17594 cat >conftest.$ac_ext <<_ACEOF
17595 /* confdefs.h.  */
17596 _ACEOF
17597 cat confdefs.h >>conftest.$ac_ext
17598 cat >>conftest.$ac_ext <<_ACEOF
17599 /* end confdefs.h.  */
17600 #include <zlib.h>
17601
17602 int
17603 main ()
17604 {
17605 if (sizeof (z_streamp))
17606        return 0;
17607   ;
17608   return 0;
17609 }
17610 _ACEOF
17611 rm -f conftest.$ac_objext
17612 if { (ac_try="$ac_compile"
17613 case "(($ac_try" in
17614   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17615   *) ac_try_echo=$ac_try;;
17616 esac
17617 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17618 $as_echo "$ac_try_echo") >&5
17619   (eval "$ac_compile") 2>conftest.er1
17620   ac_status=$?
17621   grep -v '^ *+' conftest.er1 >conftest.err
17622   rm -f conftest.er1
17623   cat conftest.err >&5
17624   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17625   (exit $ac_status); } && {
17626          test -z "$ac_c_werror_flag" ||
17627          test ! -s conftest.err
17628        } && test -s conftest.$ac_objext; then
17629   cat >conftest.$ac_ext <<_ACEOF
17630 /* confdefs.h.  */
17631 _ACEOF
17632 cat confdefs.h >>conftest.$ac_ext
17633 cat >>conftest.$ac_ext <<_ACEOF
17634 /* end confdefs.h.  */
17635 #include <zlib.h>
17636
17637 int
17638 main ()
17639 {
17640 if (sizeof ((z_streamp)))
17641           return 0;
17642   ;
17643   return 0;
17644 }
17645 _ACEOF
17646 rm -f conftest.$ac_objext
17647 if { (ac_try="$ac_compile"
17648 case "(($ac_try" in
17649   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17650   *) ac_try_echo=$ac_try;;
17651 esac
17652 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17653 $as_echo "$ac_try_echo") >&5
17654   (eval "$ac_compile") 2>conftest.er1
17655   ac_status=$?
17656   grep -v '^ *+' conftest.er1 >conftest.err
17657   rm -f conftest.er1
17658   cat conftest.err >&5
17659   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17660   (exit $ac_status); } && {
17661          test -z "$ac_c_werror_flag" ||
17662          test ! -s conftest.err
17663        } && test -s conftest.$ac_objext; then
17664   :
17665 else
17666   $as_echo "$as_me: failed program was:" >&5
17667 sed 's/^/| /' conftest.$ac_ext >&5
17668
17669         ac_cv_type_z_streamp=yes
17670 fi
17671
17672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17673 else
17674   $as_echo "$as_me: failed program was:" >&5
17675 sed 's/^/| /' conftest.$ac_ext >&5
17676
17677
17678 fi
17679
17680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17681 fi
17682 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
17683 $as_echo "$ac_cv_type_z_streamp" >&6; }
17684 if test "x$ac_cv_type_z_streamp" = x""yes; then
17685   :
17686 else
17687   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
17688 Use --without-zlib to disable zlib support." >&5
17689 $as_echo "$as_me: error: zlib version is too old
17690 Use --without-zlib to disable zlib support." >&2;}
17691    { (exit 1); exit 1; }; }
17692 fi
17693
17694 fi
17695
17696 if test "$with_krb5" = yes; then
17697 # Check for differences between MIT and Heimdal (KTH) releases
17698   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
17699 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
17700 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
17701   $as_echo_n "(cached) " >&6
17702 else
17703   cat >conftest.$ac_ext <<_ACEOF
17704 /* confdefs.h.  */
17705 _ACEOF
17706 cat confdefs.h >>conftest.$ac_ext
17707 cat >>conftest.$ac_ext <<_ACEOF
17708 /* end confdefs.h.  */
17709 #include <krb5.h>
17710
17711 int
17712 main ()
17713 {
17714 static krb5_ticket ac_aggr;
17715 if (ac_aggr.enc_part2)
17716 return 0;
17717   ;
17718   return 0;
17719 }
17720 _ACEOF
17721 rm -f conftest.$ac_objext
17722 if { (ac_try="$ac_compile"
17723 case "(($ac_try" in
17724   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17725   *) ac_try_echo=$ac_try;;
17726 esac
17727 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17728 $as_echo "$ac_try_echo") >&5
17729   (eval "$ac_compile") 2>conftest.er1
17730   ac_status=$?
17731   grep -v '^ *+' conftest.er1 >conftest.err
17732   rm -f conftest.er1
17733   cat conftest.err >&5
17734   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17735   (exit $ac_status); } && {
17736          test -z "$ac_c_werror_flag" ||
17737          test ! -s conftest.err
17738        } && test -s conftest.$ac_objext; then
17739   ac_cv_member_krb5_ticket_enc_part2=yes
17740 else
17741   $as_echo "$as_me: failed program was:" >&5
17742 sed 's/^/| /' conftest.$ac_ext >&5
17743
17744         cat >conftest.$ac_ext <<_ACEOF
17745 /* confdefs.h.  */
17746 _ACEOF
17747 cat confdefs.h >>conftest.$ac_ext
17748 cat >>conftest.$ac_ext <<_ACEOF
17749 /* end confdefs.h.  */
17750 #include <krb5.h>
17751
17752 int
17753 main ()
17754 {
17755 static krb5_ticket ac_aggr;
17756 if (sizeof ac_aggr.enc_part2)
17757 return 0;
17758   ;
17759   return 0;
17760 }
17761 _ACEOF
17762 rm -f conftest.$ac_objext
17763 if { (ac_try="$ac_compile"
17764 case "(($ac_try" in
17765   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17766   *) ac_try_echo=$ac_try;;
17767 esac
17768 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17769 $as_echo "$ac_try_echo") >&5
17770   (eval "$ac_compile") 2>conftest.er1
17771   ac_status=$?
17772   grep -v '^ *+' conftest.er1 >conftest.err
17773   rm -f conftest.er1
17774   cat conftest.err >&5
17775   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17776   (exit $ac_status); } && {
17777          test -z "$ac_c_werror_flag" ||
17778          test ! -s conftest.err
17779        } && test -s conftest.$ac_objext; then
17780   ac_cv_member_krb5_ticket_enc_part2=yes
17781 else
17782   $as_echo "$as_me: failed program was:" >&5
17783 sed 's/^/| /' conftest.$ac_ext >&5
17784
17785         ac_cv_member_krb5_ticket_enc_part2=no
17786 fi
17787
17788 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17789 fi
17790
17791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17792 fi
17793 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
17794 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
17795 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
17796
17797 cat >>confdefs.h <<_ACEOF
17798 #define HAVE_KRB5_TICKET_ENC_PART2 1
17799 _ACEOF
17800
17801
17802 else
17803   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
17804 $as_echo_n "checking for krb5_ticket.client... " >&6; }
17805 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
17806   $as_echo_n "(cached) " >&6
17807 else
17808   cat >conftest.$ac_ext <<_ACEOF
17809 /* confdefs.h.  */
17810 _ACEOF
17811 cat confdefs.h >>conftest.$ac_ext
17812 cat >>conftest.$ac_ext <<_ACEOF
17813 /* end confdefs.h.  */
17814 #include <krb5.h>
17815
17816 int
17817 main ()
17818 {
17819 static krb5_ticket ac_aggr;
17820 if (ac_aggr.client)
17821 return 0;
17822   ;
17823   return 0;
17824 }
17825 _ACEOF
17826 rm -f conftest.$ac_objext
17827 if { (ac_try="$ac_compile"
17828 case "(($ac_try" in
17829   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17830   *) ac_try_echo=$ac_try;;
17831 esac
17832 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17833 $as_echo "$ac_try_echo") >&5
17834   (eval "$ac_compile") 2>conftest.er1
17835   ac_status=$?
17836   grep -v '^ *+' conftest.er1 >conftest.err
17837   rm -f conftest.er1
17838   cat conftest.err >&5
17839   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17840   (exit $ac_status); } && {
17841          test -z "$ac_c_werror_flag" ||
17842          test ! -s conftest.err
17843        } && test -s conftest.$ac_objext; then
17844   ac_cv_member_krb5_ticket_client=yes
17845 else
17846   $as_echo "$as_me: failed program was:" >&5
17847 sed 's/^/| /' conftest.$ac_ext >&5
17848
17849         cat >conftest.$ac_ext <<_ACEOF
17850 /* confdefs.h.  */
17851 _ACEOF
17852 cat confdefs.h >>conftest.$ac_ext
17853 cat >>conftest.$ac_ext <<_ACEOF
17854 /* end confdefs.h.  */
17855 #include <krb5.h>
17856
17857 int
17858 main ()
17859 {
17860 static krb5_ticket ac_aggr;
17861 if (sizeof ac_aggr.client)
17862 return 0;
17863   ;
17864   return 0;
17865 }
17866 _ACEOF
17867 rm -f conftest.$ac_objext
17868 if { (ac_try="$ac_compile"
17869 case "(($ac_try" in
17870   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17871   *) ac_try_echo=$ac_try;;
17872 esac
17873 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17874 $as_echo "$ac_try_echo") >&5
17875   (eval "$ac_compile") 2>conftest.er1
17876   ac_status=$?
17877   grep -v '^ *+' conftest.er1 >conftest.err
17878   rm -f conftest.er1
17879   cat conftest.err >&5
17880   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17881   (exit $ac_status); } && {
17882          test -z "$ac_c_werror_flag" ||
17883          test ! -s conftest.err
17884        } && test -s conftest.$ac_objext; then
17885   ac_cv_member_krb5_ticket_client=yes
17886 else
17887   $as_echo "$as_me: failed program was:" >&5
17888 sed 's/^/| /' conftest.$ac_ext >&5
17889
17890         ac_cv_member_krb5_ticket_client=no
17891 fi
17892
17893 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17894 fi
17895
17896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17897 fi
17898 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
17899 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
17900 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
17901
17902 cat >>confdefs.h <<_ACEOF
17903 #define HAVE_KRB5_TICKET_CLIENT 1
17904 _ACEOF
17905
17906
17907 else
17908   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
17909 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
17910    { (exit 1); exit 1; }; }
17911 fi
17912
17913 fi
17914
17915   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
17916 $as_echo_n "checking for krb5_error.text.data... " >&6; }
17917 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
17918   $as_echo_n "(cached) " >&6
17919 else
17920   cat >conftest.$ac_ext <<_ACEOF
17921 /* confdefs.h.  */
17922 _ACEOF
17923 cat confdefs.h >>conftest.$ac_ext
17924 cat >>conftest.$ac_ext <<_ACEOF
17925 /* end confdefs.h.  */
17926 #include <krb5.h>
17927
17928 int
17929 main ()
17930 {
17931 static krb5_error ac_aggr;
17932 if (ac_aggr.text.data)
17933 return 0;
17934   ;
17935   return 0;
17936 }
17937 _ACEOF
17938 rm -f conftest.$ac_objext
17939 if { (ac_try="$ac_compile"
17940 case "(($ac_try" in
17941   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17942   *) ac_try_echo=$ac_try;;
17943 esac
17944 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17945 $as_echo "$ac_try_echo") >&5
17946   (eval "$ac_compile") 2>conftest.er1
17947   ac_status=$?
17948   grep -v '^ *+' conftest.er1 >conftest.err
17949   rm -f conftest.er1
17950   cat conftest.err >&5
17951   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17952   (exit $ac_status); } && {
17953          test -z "$ac_c_werror_flag" ||
17954          test ! -s conftest.err
17955        } && test -s conftest.$ac_objext; then
17956   ac_cv_member_krb5_error_text_data=yes
17957 else
17958   $as_echo "$as_me: failed program was:" >&5
17959 sed 's/^/| /' conftest.$ac_ext >&5
17960
17961         cat >conftest.$ac_ext <<_ACEOF
17962 /* confdefs.h.  */
17963 _ACEOF
17964 cat confdefs.h >>conftest.$ac_ext
17965 cat >>conftest.$ac_ext <<_ACEOF
17966 /* end confdefs.h.  */
17967 #include <krb5.h>
17968
17969 int
17970 main ()
17971 {
17972 static krb5_error ac_aggr;
17973 if (sizeof ac_aggr.text.data)
17974 return 0;
17975   ;
17976   return 0;
17977 }
17978 _ACEOF
17979 rm -f conftest.$ac_objext
17980 if { (ac_try="$ac_compile"
17981 case "(($ac_try" in
17982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17983   *) ac_try_echo=$ac_try;;
17984 esac
17985 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17986 $as_echo "$ac_try_echo") >&5
17987   (eval "$ac_compile") 2>conftest.er1
17988   ac_status=$?
17989   grep -v '^ *+' conftest.er1 >conftest.err
17990   rm -f conftest.er1
17991   cat conftest.err >&5
17992   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17993   (exit $ac_status); } && {
17994          test -z "$ac_c_werror_flag" ||
17995          test ! -s conftest.err
17996        } && test -s conftest.$ac_objext; then
17997   ac_cv_member_krb5_error_text_data=yes
17998 else
17999   $as_echo "$as_me: failed program was:" >&5
18000 sed 's/^/| /' conftest.$ac_ext >&5
18001
18002         ac_cv_member_krb5_error_text_data=no
18003 fi
18004
18005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18006 fi
18007
18008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18009 fi
18010 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
18011 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
18012 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
18013
18014 cat >>confdefs.h <<_ACEOF
18015 #define HAVE_KRB5_ERROR_TEXT_DATA 1
18016 _ACEOF
18017
18018
18019 else
18020   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
18021 $as_echo_n "checking for krb5_error.e_data... " >&6; }
18022 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
18023   $as_echo_n "(cached) " >&6
18024 else
18025   cat >conftest.$ac_ext <<_ACEOF
18026 /* confdefs.h.  */
18027 _ACEOF
18028 cat confdefs.h >>conftest.$ac_ext
18029 cat >>conftest.$ac_ext <<_ACEOF
18030 /* end confdefs.h.  */
18031 #include <krb5.h>
18032
18033 int
18034 main ()
18035 {
18036 static krb5_error ac_aggr;
18037 if (ac_aggr.e_data)
18038 return 0;
18039   ;
18040   return 0;
18041 }
18042 _ACEOF
18043 rm -f conftest.$ac_objext
18044 if { (ac_try="$ac_compile"
18045 case "(($ac_try" in
18046   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18047   *) ac_try_echo=$ac_try;;
18048 esac
18049 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18050 $as_echo "$ac_try_echo") >&5
18051   (eval "$ac_compile") 2>conftest.er1
18052   ac_status=$?
18053   grep -v '^ *+' conftest.er1 >conftest.err
18054   rm -f conftest.er1
18055   cat conftest.err >&5
18056   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18057   (exit $ac_status); } && {
18058          test -z "$ac_c_werror_flag" ||
18059          test ! -s conftest.err
18060        } && test -s conftest.$ac_objext; then
18061   ac_cv_member_krb5_error_e_data=yes
18062 else
18063   $as_echo "$as_me: failed program was:" >&5
18064 sed 's/^/| /' conftest.$ac_ext >&5
18065
18066         cat >conftest.$ac_ext <<_ACEOF
18067 /* confdefs.h.  */
18068 _ACEOF
18069 cat confdefs.h >>conftest.$ac_ext
18070 cat >>conftest.$ac_ext <<_ACEOF
18071 /* end confdefs.h.  */
18072 #include <krb5.h>
18073
18074 int
18075 main ()
18076 {
18077 static krb5_error ac_aggr;
18078 if (sizeof ac_aggr.e_data)
18079 return 0;
18080   ;
18081   return 0;
18082 }
18083 _ACEOF
18084 rm -f conftest.$ac_objext
18085 if { (ac_try="$ac_compile"
18086 case "(($ac_try" in
18087   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18088   *) ac_try_echo=$ac_try;;
18089 esac
18090 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18091 $as_echo "$ac_try_echo") >&5
18092   (eval "$ac_compile") 2>conftest.er1
18093   ac_status=$?
18094   grep -v '^ *+' conftest.er1 >conftest.err
18095   rm -f conftest.er1
18096   cat conftest.err >&5
18097   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18098   (exit $ac_status); } && {
18099          test -z "$ac_c_werror_flag" ||
18100          test ! -s conftest.err
18101        } && test -s conftest.$ac_objext; then
18102   ac_cv_member_krb5_error_e_data=yes
18103 else
18104   $as_echo "$as_me: failed program was:" >&5
18105 sed 's/^/| /' conftest.$ac_ext >&5
18106
18107         ac_cv_member_krb5_error_e_data=no
18108 fi
18109
18110 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18111 fi
18112
18113 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18114 fi
18115 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
18116 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
18117 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
18118
18119 cat >>confdefs.h <<_ACEOF
18120 #define HAVE_KRB5_ERROR_E_DATA 1
18121 _ACEOF
18122
18123
18124 else
18125   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
18126 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
18127    { (exit 1); exit 1; }; }
18128 fi
18129
18130 fi
18131
18132
18133 # Win32 requires headers to be loaded for __stdcall, so can't use
18134 # AC_CHECK_FUNCS here.
18135   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
18136 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
18137   cat >conftest.$ac_ext <<_ACEOF
18138 /* confdefs.h.  */
18139 _ACEOF
18140 cat confdefs.h >>conftest.$ac_ext
18141 cat >>conftest.$ac_ext <<_ACEOF
18142 /* end confdefs.h.  */
18143 #include <krb5.h>
18144 int
18145 main ()
18146 {
18147 krb5_free_unparsed_name(NULL,NULL);
18148   ;
18149   return 0;
18150 }
18151 _ACEOF
18152 rm -f conftest.$ac_objext conftest$ac_exeext
18153 if { (ac_try="$ac_link"
18154 case "(($ac_try" in
18155   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18156   *) ac_try_echo=$ac_try;;
18157 esac
18158 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18159 $as_echo "$ac_try_echo") >&5
18160   (eval "$ac_link") 2>conftest.er1
18161   ac_status=$?
18162   grep -v '^ *+' conftest.er1 >conftest.err
18163   rm -f conftest.er1
18164   cat conftest.err >&5
18165   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18166   (exit $ac_status); } && {
18167          test -z "$ac_c_werror_flag" ||
18168          test ! -s conftest.err
18169        } && test -s conftest$ac_exeext && {
18170          test "$cross_compiling" = yes ||
18171          $as_test_x conftest$ac_exeext
18172        }; then
18173
18174 cat >>confdefs.h <<\_ACEOF
18175 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
18176 _ACEOF
18177
18178 { $as_echo "$as_me:$LINENO: result: yes" >&5
18179 $as_echo "yes" >&6; }
18180 else
18181   $as_echo "$as_me: failed program was:" >&5
18182 sed 's/^/| /' conftest.$ac_ext >&5
18183
18184         { $as_echo "$as_me:$LINENO: result: no" >&5
18185 $as_echo "no" >&6; }
18186 fi
18187
18188 rm -rf conftest.dSYM
18189 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18190       conftest$ac_exeext conftest.$ac_ext
18191 fi
18192
18193 # On PPC, check if assembler supports LWARX instruction's mutex hint bit
18194 case $host_cpu in
18195   ppc*|powerpc*)
18196     { $as_echo "$as_me:$LINENO: checking whether assembler supports lwarx hint bit" >&5
18197 $as_echo_n "checking whether assembler supports lwarx hint bit... " >&6; }
18198     cat >conftest.$ac_ext <<_ACEOF
18199 /* confdefs.h.  */
18200 _ACEOF
18201 cat confdefs.h >>conftest.$ac_ext
18202 cat >>conftest.$ac_ext <<_ACEOF
18203 /* end confdefs.h.  */
18204
18205 int
18206 main ()
18207 {
18208 int a = 0; int *p = &a; int r;
18209          __asm__ __volatile__ (" lwarx %0,0,%1,1\n" : "=&r"(r) : "r"(p));
18210   ;
18211   return 0;
18212 }
18213 _ACEOF
18214 rm -f conftest.$ac_objext
18215 if { (ac_try="$ac_compile"
18216 case "(($ac_try" in
18217   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18218   *) ac_try_echo=$ac_try;;
18219 esac
18220 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18221 $as_echo "$ac_try_echo") >&5
18222   (eval "$ac_compile") 2>conftest.er1
18223   ac_status=$?
18224   grep -v '^ *+' conftest.er1 >conftest.err
18225   rm -f conftest.er1
18226   cat conftest.err >&5
18227   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18228   (exit $ac_status); } && {
18229          test -z "$ac_c_werror_flag" ||
18230          test ! -s conftest.err
18231        } && test -s conftest.$ac_objext; then
18232   pgac_cv_have_ppc_mutex_hint=yes
18233 else
18234   $as_echo "$as_me: failed program was:" >&5
18235 sed 's/^/| /' conftest.$ac_ext >&5
18236
18237         pgac_cv_have_ppc_mutex_hint=no
18238 fi
18239
18240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18241     { $as_echo "$as_me:$LINENO: result: $pgac_cv_have_ppc_mutex_hint" >&5
18242 $as_echo "$pgac_cv_have_ppc_mutex_hint" >&6; }
18243     if test x"$pgac_cv_have_ppc_mutex_hint" = xyes ; then
18244
18245 cat >>confdefs.h <<\_ACEOF
18246 #define HAVE_PPC_LWARX_MUTEX_HINT 1
18247 _ACEOF
18248
18249     fi
18250   ;;
18251 esac
18252
18253 # Check largefile support.  You might think this is a system service not a
18254 # compiler characteristic, but you'd be wrong.  We must check this before
18255 # probing existence of related functions such as fseeko, since the largefile
18256 # defines can affect what is generated for that.
18257 if test "$PORTNAME" != "win32"; then
18258    # Check whether --enable-largefile was given.
18259 if test "${enable_largefile+set}" = set; then
18260   enableval=$enable_largefile;
18261 fi
18262
18263 if test "$enable_largefile" != no; then
18264
18265   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
18266 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
18267 if test "${ac_cv_sys_largefile_CC+set}" = set; then
18268   $as_echo_n "(cached) " >&6
18269 else
18270   ac_cv_sys_largefile_CC=no
18271      if test "$GCC" != yes; then
18272        ac_save_CC=$CC
18273        while :; do
18274          # IRIX 6.2 and later do not support large files by default,
18275          # so use the C compiler's -n32 option if that helps.
18276          cat >conftest.$ac_ext <<_ACEOF
18277 /* confdefs.h.  */
18278 _ACEOF
18279 cat confdefs.h >>conftest.$ac_ext
18280 cat >>conftest.$ac_ext <<_ACEOF
18281 /* end confdefs.h.  */
18282 #include <sys/types.h>
18283  /* Check that off_t can represent 2**63 - 1 correctly.
18284     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18285     since some C++ compilers masquerading as C compilers
18286     incorrectly reject 9223372036854775807.  */
18287 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18288   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18289                        && LARGE_OFF_T % 2147483647 == 1)
18290                       ? 1 : -1];
18291 int
18292 main ()
18293 {
18294
18295   ;
18296   return 0;
18297 }
18298 _ACEOF
18299          rm -f conftest.$ac_objext
18300 if { (ac_try="$ac_compile"
18301 case "(($ac_try" in
18302   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18303   *) ac_try_echo=$ac_try;;
18304 esac
18305 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18306 $as_echo "$ac_try_echo") >&5
18307   (eval "$ac_compile") 2>conftest.er1
18308   ac_status=$?
18309   grep -v '^ *+' conftest.er1 >conftest.err
18310   rm -f conftest.er1
18311   cat conftest.err >&5
18312   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18313   (exit $ac_status); } && {
18314          test -z "$ac_c_werror_flag" ||
18315          test ! -s conftest.err
18316        } && test -s conftest.$ac_objext; then
18317   break
18318 else
18319   $as_echo "$as_me: failed program was:" >&5
18320 sed 's/^/| /' conftest.$ac_ext >&5
18321
18322
18323 fi
18324
18325 rm -f core conftest.err conftest.$ac_objext
18326          CC="$CC -n32"
18327          rm -f conftest.$ac_objext
18328 if { (ac_try="$ac_compile"
18329 case "(($ac_try" in
18330   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18331   *) ac_try_echo=$ac_try;;
18332 esac
18333 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18334 $as_echo "$ac_try_echo") >&5
18335   (eval "$ac_compile") 2>conftest.er1
18336   ac_status=$?
18337   grep -v '^ *+' conftest.er1 >conftest.err
18338   rm -f conftest.er1
18339   cat conftest.err >&5
18340   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18341   (exit $ac_status); } && {
18342          test -z "$ac_c_werror_flag" ||
18343          test ! -s conftest.err
18344        } && test -s conftest.$ac_objext; then
18345   ac_cv_sys_largefile_CC=' -n32'; break
18346 else
18347   $as_echo "$as_me: failed program was:" >&5
18348 sed 's/^/| /' conftest.$ac_ext >&5
18349
18350
18351 fi
18352
18353 rm -f core conftest.err conftest.$ac_objext
18354          break
18355        done
18356        CC=$ac_save_CC
18357        rm -f conftest.$ac_ext
18358     fi
18359 fi
18360 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
18361 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
18362   if test "$ac_cv_sys_largefile_CC" != no; then
18363     CC=$CC$ac_cv_sys_largefile_CC
18364   fi
18365
18366   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
18367 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
18368 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
18369   $as_echo_n "(cached) " >&6
18370 else
18371   while :; do
18372   cat >conftest.$ac_ext <<_ACEOF
18373 /* confdefs.h.  */
18374 _ACEOF
18375 cat confdefs.h >>conftest.$ac_ext
18376 cat >>conftest.$ac_ext <<_ACEOF
18377 /* end confdefs.h.  */
18378 #include <sys/types.h>
18379  /* Check that off_t can represent 2**63 - 1 correctly.
18380     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18381     since some C++ compilers masquerading as C compilers
18382     incorrectly reject 9223372036854775807.  */
18383 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18384   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18385                        && LARGE_OFF_T % 2147483647 == 1)
18386                       ? 1 : -1];
18387 int
18388 main ()
18389 {
18390
18391   ;
18392   return 0;
18393 }
18394 _ACEOF
18395 rm -f conftest.$ac_objext
18396 if { (ac_try="$ac_compile"
18397 case "(($ac_try" in
18398   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18399   *) ac_try_echo=$ac_try;;
18400 esac
18401 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18402 $as_echo "$ac_try_echo") >&5
18403   (eval "$ac_compile") 2>conftest.er1
18404   ac_status=$?
18405   grep -v '^ *+' conftest.er1 >conftest.err
18406   rm -f conftest.er1
18407   cat conftest.err >&5
18408   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18409   (exit $ac_status); } && {
18410          test -z "$ac_c_werror_flag" ||
18411          test ! -s conftest.err
18412        } && test -s conftest.$ac_objext; then
18413   ac_cv_sys_file_offset_bits=no; break
18414 else
18415   $as_echo "$as_me: failed program was:" >&5
18416 sed 's/^/| /' conftest.$ac_ext >&5
18417
18418
18419 fi
18420
18421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18422   cat >conftest.$ac_ext <<_ACEOF
18423 /* confdefs.h.  */
18424 _ACEOF
18425 cat confdefs.h >>conftest.$ac_ext
18426 cat >>conftest.$ac_ext <<_ACEOF
18427 /* end confdefs.h.  */
18428 #define _FILE_OFFSET_BITS 64
18429 #include <sys/types.h>
18430  /* Check that off_t can represent 2**63 - 1 correctly.
18431     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18432     since some C++ compilers masquerading as C compilers
18433     incorrectly reject 9223372036854775807.  */
18434 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18435   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18436                        && LARGE_OFF_T % 2147483647 == 1)
18437                       ? 1 : -1];
18438 int
18439 main ()
18440 {
18441
18442   ;
18443   return 0;
18444 }
18445 _ACEOF
18446 rm -f conftest.$ac_objext
18447 if { (ac_try="$ac_compile"
18448 case "(($ac_try" in
18449   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18450   *) ac_try_echo=$ac_try;;
18451 esac
18452 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18453 $as_echo "$ac_try_echo") >&5
18454   (eval "$ac_compile") 2>conftest.er1
18455   ac_status=$?
18456   grep -v '^ *+' conftest.er1 >conftest.err
18457   rm -f conftest.er1
18458   cat conftest.err >&5
18459   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18460   (exit $ac_status); } && {
18461          test -z "$ac_c_werror_flag" ||
18462          test ! -s conftest.err
18463        } && test -s conftest.$ac_objext; then
18464   ac_cv_sys_file_offset_bits=64; break
18465 else
18466   $as_echo "$as_me: failed program was:" >&5
18467 sed 's/^/| /' conftest.$ac_ext >&5
18468
18469
18470 fi
18471
18472 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18473   ac_cv_sys_file_offset_bits=unknown
18474   break
18475 done
18476 fi
18477 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
18478 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
18479 case $ac_cv_sys_file_offset_bits in #(
18480   no | unknown) ;;
18481   *)
18482 cat >>confdefs.h <<_ACEOF
18483 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
18484 _ACEOF
18485 ;;
18486 esac
18487 rm -rf conftest*
18488   if test $ac_cv_sys_file_offset_bits = unknown; then
18489     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
18490 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
18491 if test "${ac_cv_sys_large_files+set}" = set; then
18492   $as_echo_n "(cached) " >&6
18493 else
18494   while :; do
18495   cat >conftest.$ac_ext <<_ACEOF
18496 /* confdefs.h.  */
18497 _ACEOF
18498 cat confdefs.h >>conftest.$ac_ext
18499 cat >>conftest.$ac_ext <<_ACEOF
18500 /* end confdefs.h.  */
18501 #include <sys/types.h>
18502  /* Check that off_t can represent 2**63 - 1 correctly.
18503     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18504     since some C++ compilers masquerading as C compilers
18505     incorrectly reject 9223372036854775807.  */
18506 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18507   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18508                        && LARGE_OFF_T % 2147483647 == 1)
18509                       ? 1 : -1];
18510 int
18511 main ()
18512 {
18513
18514   ;
18515   return 0;
18516 }
18517 _ACEOF
18518 rm -f conftest.$ac_objext
18519 if { (ac_try="$ac_compile"
18520 case "(($ac_try" in
18521   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18522   *) ac_try_echo=$ac_try;;
18523 esac
18524 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18525 $as_echo "$ac_try_echo") >&5
18526   (eval "$ac_compile") 2>conftest.er1
18527   ac_status=$?
18528   grep -v '^ *+' conftest.er1 >conftest.err
18529   rm -f conftest.er1
18530   cat conftest.err >&5
18531   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18532   (exit $ac_status); } && {
18533          test -z "$ac_c_werror_flag" ||
18534          test ! -s conftest.err
18535        } && test -s conftest.$ac_objext; then
18536   ac_cv_sys_large_files=no; break
18537 else
18538   $as_echo "$as_me: failed program was:" >&5
18539 sed 's/^/| /' conftest.$ac_ext >&5
18540
18541
18542 fi
18543
18544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18545   cat >conftest.$ac_ext <<_ACEOF
18546 /* confdefs.h.  */
18547 _ACEOF
18548 cat confdefs.h >>conftest.$ac_ext
18549 cat >>conftest.$ac_ext <<_ACEOF
18550 /* end confdefs.h.  */
18551 #define _LARGE_FILES 1
18552 #include <sys/types.h>
18553  /* Check that off_t can represent 2**63 - 1 correctly.
18554     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18555     since some C++ compilers masquerading as C compilers
18556     incorrectly reject 9223372036854775807.  */
18557 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18558   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18559                        && LARGE_OFF_T % 2147483647 == 1)
18560                       ? 1 : -1];
18561 int
18562 main ()
18563 {
18564
18565   ;
18566   return 0;
18567 }
18568 _ACEOF
18569 rm -f conftest.$ac_objext
18570 if { (ac_try="$ac_compile"
18571 case "(($ac_try" in
18572   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18573   *) ac_try_echo=$ac_try;;
18574 esac
18575 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18576 $as_echo "$ac_try_echo") >&5
18577   (eval "$ac_compile") 2>conftest.er1
18578   ac_status=$?
18579   grep -v '^ *+' conftest.er1 >conftest.err
18580   rm -f conftest.er1
18581   cat conftest.err >&5
18582   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18583   (exit $ac_status); } && {
18584          test -z "$ac_c_werror_flag" ||
18585          test ! -s conftest.err
18586        } && test -s conftest.$ac_objext; then
18587   ac_cv_sys_large_files=1; break
18588 else
18589   $as_echo "$as_me: failed program was:" >&5
18590 sed 's/^/| /' conftest.$ac_ext >&5
18591
18592
18593 fi
18594
18595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18596   ac_cv_sys_large_files=unknown
18597   break
18598 done
18599 fi
18600 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
18601 $as_echo "$ac_cv_sys_large_files" >&6; }
18602 case $ac_cv_sys_large_files in #(
18603   no | unknown) ;;
18604   *)
18605 cat >>confdefs.h <<_ACEOF
18606 #define _LARGE_FILES $ac_cv_sys_large_files
18607 _ACEOF
18608 ;;
18609 esac
18610 rm -rf conftest*
18611   fi
18612 fi
18613
18614 fi
18615
18616 # Check for largefile support (must be after AC_SYS_LARGEFILE)
18617 # The cast to long int works around a bug in the HP C Compiler
18618 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18619 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18620 # This bug is HP SR number 8606223364.
18621 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
18622 $as_echo_n "checking size of off_t... " >&6; }
18623 if test "${ac_cv_sizeof_off_t+set}" = set; then
18624   $as_echo_n "(cached) " >&6
18625 else
18626   if test "$cross_compiling" = yes; then
18627   # Depending upon the size, compute the lo and hi bounds.
18628 cat >conftest.$ac_ext <<_ACEOF
18629 /* confdefs.h.  */
18630 _ACEOF
18631 cat confdefs.h >>conftest.$ac_ext
18632 cat >>conftest.$ac_ext <<_ACEOF
18633 /* end confdefs.h.  */
18634 $ac_includes_default
18635 int
18636 main ()
18637 {
18638 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
18639 test_array [0] = 0
18640
18641   ;
18642   return 0;
18643 }
18644 _ACEOF
18645 rm -f conftest.$ac_objext
18646 if { (ac_try="$ac_compile"
18647 case "(($ac_try" in
18648   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18649   *) ac_try_echo=$ac_try;;
18650 esac
18651 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18652 $as_echo "$ac_try_echo") >&5
18653   (eval "$ac_compile") 2>conftest.er1
18654   ac_status=$?
18655   grep -v '^ *+' conftest.er1 >conftest.err
18656   rm -f conftest.er1
18657   cat conftest.err >&5
18658   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18659   (exit $ac_status); } && {
18660          test -z "$ac_c_werror_flag" ||
18661          test ! -s conftest.err
18662        } && test -s conftest.$ac_objext; then
18663   ac_lo=0 ac_mid=0
18664   while :; do
18665     cat >conftest.$ac_ext <<_ACEOF
18666 /* confdefs.h.  */
18667 _ACEOF
18668 cat confdefs.h >>conftest.$ac_ext
18669 cat >>conftest.$ac_ext <<_ACEOF
18670 /* end confdefs.h.  */
18671 $ac_includes_default
18672 int
18673 main ()
18674 {
18675 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18676 test_array [0] = 0
18677
18678   ;
18679   return 0;
18680 }
18681 _ACEOF
18682 rm -f conftest.$ac_objext
18683 if { (ac_try="$ac_compile"
18684 case "(($ac_try" in
18685   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18686   *) ac_try_echo=$ac_try;;
18687 esac
18688 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18689 $as_echo "$ac_try_echo") >&5
18690   (eval "$ac_compile") 2>conftest.er1
18691   ac_status=$?
18692   grep -v '^ *+' conftest.er1 >conftest.err
18693   rm -f conftest.er1
18694   cat conftest.err >&5
18695   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18696   (exit $ac_status); } && {
18697          test -z "$ac_c_werror_flag" ||
18698          test ! -s conftest.err
18699        } && test -s conftest.$ac_objext; then
18700   ac_hi=$ac_mid; break
18701 else
18702   $as_echo "$as_me: failed program was:" >&5
18703 sed 's/^/| /' conftest.$ac_ext >&5
18704
18705         ac_lo=`expr $ac_mid + 1`
18706                         if test $ac_lo -le $ac_mid; then
18707                           ac_lo= ac_hi=
18708                           break
18709                         fi
18710                         ac_mid=`expr 2 '*' $ac_mid + 1`
18711 fi
18712
18713 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18714   done
18715 else
18716   $as_echo "$as_me: failed program was:" >&5
18717 sed 's/^/| /' conftest.$ac_ext >&5
18718
18719         cat >conftest.$ac_ext <<_ACEOF
18720 /* confdefs.h.  */
18721 _ACEOF
18722 cat confdefs.h >>conftest.$ac_ext
18723 cat >>conftest.$ac_ext <<_ACEOF
18724 /* end confdefs.h.  */
18725 $ac_includes_default
18726 int
18727 main ()
18728 {
18729 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
18730 test_array [0] = 0
18731
18732   ;
18733   return 0;
18734 }
18735 _ACEOF
18736 rm -f conftest.$ac_objext
18737 if { (ac_try="$ac_compile"
18738 case "(($ac_try" in
18739   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18740   *) ac_try_echo=$ac_try;;
18741 esac
18742 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18743 $as_echo "$ac_try_echo") >&5
18744   (eval "$ac_compile") 2>conftest.er1
18745   ac_status=$?
18746   grep -v '^ *+' conftest.er1 >conftest.err
18747   rm -f conftest.er1
18748   cat conftest.err >&5
18749   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18750   (exit $ac_status); } && {
18751          test -z "$ac_c_werror_flag" ||
18752          test ! -s conftest.err
18753        } && test -s conftest.$ac_objext; then
18754   ac_hi=-1 ac_mid=-1
18755   while :; do
18756     cat >conftest.$ac_ext <<_ACEOF
18757 /* confdefs.h.  */
18758 _ACEOF
18759 cat confdefs.h >>conftest.$ac_ext
18760 cat >>conftest.$ac_ext <<_ACEOF
18761 /* end confdefs.h.  */
18762 $ac_includes_default
18763 int
18764 main ()
18765 {
18766 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
18767 test_array [0] = 0
18768
18769   ;
18770   return 0;
18771 }
18772 _ACEOF
18773 rm -f conftest.$ac_objext
18774 if { (ac_try="$ac_compile"
18775 case "(($ac_try" in
18776   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18777   *) ac_try_echo=$ac_try;;
18778 esac
18779 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18780 $as_echo "$ac_try_echo") >&5
18781   (eval "$ac_compile") 2>conftest.er1
18782   ac_status=$?
18783   grep -v '^ *+' conftest.er1 >conftest.err
18784   rm -f conftest.er1
18785   cat conftest.err >&5
18786   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18787   (exit $ac_status); } && {
18788          test -z "$ac_c_werror_flag" ||
18789          test ! -s conftest.err
18790        } && test -s conftest.$ac_objext; then
18791   ac_lo=$ac_mid; break
18792 else
18793   $as_echo "$as_me: failed program was:" >&5
18794 sed 's/^/| /' conftest.$ac_ext >&5
18795
18796         ac_hi=`expr '(' $ac_mid ')' - 1`
18797                         if test $ac_mid -le $ac_hi; then
18798                           ac_lo= ac_hi=
18799                           break
18800                         fi
18801                         ac_mid=`expr 2 '*' $ac_mid`
18802 fi
18803
18804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18805   done
18806 else
18807   $as_echo "$as_me: failed program was:" >&5
18808 sed 's/^/| /' conftest.$ac_ext >&5
18809
18810         ac_lo= ac_hi=
18811 fi
18812
18813 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18814 fi
18815
18816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18817 # Binary search between lo and hi bounds.
18818 while test "x$ac_lo" != "x$ac_hi"; do
18819   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18820   cat >conftest.$ac_ext <<_ACEOF
18821 /* confdefs.h.  */
18822 _ACEOF
18823 cat confdefs.h >>conftest.$ac_ext
18824 cat >>conftest.$ac_ext <<_ACEOF
18825 /* end confdefs.h.  */
18826 $ac_includes_default
18827 int
18828 main ()
18829 {
18830 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18831 test_array [0] = 0
18832
18833   ;
18834   return 0;
18835 }
18836 _ACEOF
18837 rm -f conftest.$ac_objext
18838 if { (ac_try="$ac_compile"
18839 case "(($ac_try" in
18840   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18841   *) ac_try_echo=$ac_try;;
18842 esac
18843 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18844 $as_echo "$ac_try_echo") >&5
18845   (eval "$ac_compile") 2>conftest.er1
18846   ac_status=$?
18847   grep -v '^ *+' conftest.er1 >conftest.err
18848   rm -f conftest.er1
18849   cat conftest.err >&5
18850   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18851   (exit $ac_status); } && {
18852          test -z "$ac_c_werror_flag" ||
18853          test ! -s conftest.err
18854        } && test -s conftest.$ac_objext; then
18855   ac_hi=$ac_mid
18856 else
18857   $as_echo "$as_me: failed program was:" >&5
18858 sed 's/^/| /' conftest.$ac_ext >&5
18859
18860         ac_lo=`expr '(' $ac_mid ')' + 1`
18861 fi
18862
18863 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18864 done
18865 case $ac_lo in
18866 ?*) ac_cv_sizeof_off_t=$ac_lo;;
18867 '') if test "$ac_cv_type_off_t" = yes; then
18868      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18869 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18870 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18871 See \`config.log' for more details." >&5
18872 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18873 See \`config.log' for more details." >&2;}
18874    { (exit 77); exit 77; }; }; }
18875    else
18876      ac_cv_sizeof_off_t=0
18877    fi ;;
18878 esac
18879 else
18880   cat >conftest.$ac_ext <<_ACEOF
18881 /* confdefs.h.  */
18882 _ACEOF
18883 cat confdefs.h >>conftest.$ac_ext
18884 cat >>conftest.$ac_ext <<_ACEOF
18885 /* end confdefs.h.  */
18886 $ac_includes_default
18887 static long int longval () { return (long int) (sizeof (off_t)); }
18888 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
18889 #include <stdio.h>
18890 #include <stdlib.h>
18891 int
18892 main ()
18893 {
18894
18895   FILE *f = fopen ("conftest.val", "w");
18896   if (! f)
18897     return 1;
18898   if (((long int) (sizeof (off_t))) < 0)
18899     {
18900       long int i = longval ();
18901       if (i != ((long int) (sizeof (off_t))))
18902         return 1;
18903       fprintf (f, "%ld", i);
18904     }
18905   else
18906     {
18907       unsigned long int i = ulongval ();
18908       if (i != ((long int) (sizeof (off_t))))
18909         return 1;
18910       fprintf (f, "%lu", i);
18911     }
18912   /* Do not output a trailing newline, as this causes \r\n confusion
18913      on some platforms.  */
18914   return ferror (f) || fclose (f) != 0;
18915
18916   ;
18917   return 0;
18918 }
18919 _ACEOF
18920 rm -f conftest$ac_exeext
18921 if { (ac_try="$ac_link"
18922 case "(($ac_try" in
18923   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18924   *) ac_try_echo=$ac_try;;
18925 esac
18926 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18927 $as_echo "$ac_try_echo") >&5
18928   (eval "$ac_link") 2>&5
18929   ac_status=$?
18930   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18931   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18932   { (case "(($ac_try" in
18933   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18934   *) ac_try_echo=$ac_try;;
18935 esac
18936 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18937 $as_echo "$ac_try_echo") >&5
18938   (eval "$ac_try") 2>&5
18939   ac_status=$?
18940   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18941   (exit $ac_status); }; }; then
18942   ac_cv_sizeof_off_t=`cat conftest.val`
18943 else
18944   $as_echo "$as_me: program exited with status $ac_status" >&5
18945 $as_echo "$as_me: failed program was:" >&5
18946 sed 's/^/| /' conftest.$ac_ext >&5
18947
18948 ( exit $ac_status )
18949 if test "$ac_cv_type_off_t" = yes; then
18950      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18951 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18952 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18953 See \`config.log' for more details." >&5
18954 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18955 See \`config.log' for more details." >&2;}
18956    { (exit 77); exit 77; }; }; }
18957    else
18958      ac_cv_sizeof_off_t=0
18959    fi
18960 fi
18961 rm -rf conftest.dSYM
18962 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18963 fi
18964 rm -f conftest.val
18965 fi
18966 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
18967 $as_echo "$ac_cv_sizeof_off_t" >&6; }
18968
18969
18970
18971 cat >>confdefs.h <<_ACEOF
18972 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
18973 _ACEOF
18974
18975
18976
18977 # If we don't have largefile support, can't handle segsize >= 2GB.
18978 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
18979    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
18980 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
18981    { (exit 1); exit 1; }; }
18982 fi
18983
18984
18985 ##
18986 ## Functions, global variables
18987 ##
18988
18989 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
18990 $as_echo_n "checking for int timezone... " >&6; }
18991 if test "${pgac_cv_var_int_timezone+set}" = set; then
18992   $as_echo_n "(cached) " >&6
18993 else
18994   cat >conftest.$ac_ext <<_ACEOF
18995 /* confdefs.h.  */
18996 _ACEOF
18997 cat confdefs.h >>conftest.$ac_ext
18998 cat >>conftest.$ac_ext <<_ACEOF
18999 /* end confdefs.h.  */
19000 #include <time.h>
19001 int res;
19002 int
19003 main ()
19004 {
19005 #ifndef __CYGWIN__
19006 res = timezone / 60;
19007 #else
19008 res = _timezone / 60;
19009 #endif
19010   ;
19011   return 0;
19012 }
19013 _ACEOF
19014 rm -f conftest.$ac_objext conftest$ac_exeext
19015 if { (ac_try="$ac_link"
19016 case "(($ac_try" in
19017   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19018   *) ac_try_echo=$ac_try;;
19019 esac
19020 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19021 $as_echo "$ac_try_echo") >&5
19022   (eval "$ac_link") 2>conftest.er1
19023   ac_status=$?
19024   grep -v '^ *+' conftest.er1 >conftest.err
19025   rm -f conftest.er1
19026   cat conftest.err >&5
19027   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19028   (exit $ac_status); } && {
19029          test -z "$ac_c_werror_flag" ||
19030          test ! -s conftest.err
19031        } && test -s conftest$ac_exeext && {
19032          test "$cross_compiling" = yes ||
19033          $as_test_x conftest$ac_exeext
19034        }; then
19035   pgac_cv_var_int_timezone=yes
19036 else
19037   $as_echo "$as_me: failed program was:" >&5
19038 sed 's/^/| /' conftest.$ac_ext >&5
19039
19040         pgac_cv_var_int_timezone=no
19041 fi
19042
19043 rm -rf conftest.dSYM
19044 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19045       conftest$ac_exeext conftest.$ac_ext
19046 fi
19047 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
19048 $as_echo "$pgac_cv_var_int_timezone" >&6; }
19049 if test x"$pgac_cv_var_int_timezone" = xyes ; then
19050
19051 cat >>confdefs.h <<\_ACEOF
19052 #define HAVE_INT_TIMEZONE /**/
19053 _ACEOF
19054
19055 fi
19056 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
19057 $as_echo_n "checking types of arguments for accept()... " >&6; }
19058  if test "${ac_cv_func_accept_return+set}" = set; then
19059   $as_echo_n "(cached) " >&6
19060 else
19061    if test "${ac_cv_func_accept_arg1+set}" = set; then
19062   $as_echo_n "(cached) " >&6
19063 else
19064     if test "${ac_cv_func_accept_arg2+set}" = set; then
19065   $as_echo_n "(cached) " >&6
19066 else
19067      if test "${ac_cv_func_accept_arg3+set}" = set; then
19068   $as_echo_n "(cached) " >&6
19069 else
19070       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET WSAAPI'; do
19071       for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
19072        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
19073         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
19074          cat >conftest.$ac_ext <<_ACEOF
19075 /* confdefs.h.  */
19076 _ACEOF
19077 cat confdefs.h >>conftest.$ac_ext
19078 cat >>conftest.$ac_ext <<_ACEOF
19079 /* end confdefs.h.  */
19080 #ifdef HAVE_SYS_TYPES_H
19081 #include <sys/types.h>
19082 #endif
19083 #ifdef HAVE_SYS_SOCKET_H
19084 #include <sys/socket.h>
19085 #endif
19086 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
19087 int
19088 main ()
19089 {
19090
19091   ;
19092   return 0;
19093 }
19094 _ACEOF
19095 rm -f conftest.$ac_objext
19096 if { (ac_try="$ac_compile"
19097 case "(($ac_try" in
19098   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19099   *) ac_try_echo=$ac_try;;
19100 esac
19101 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19102 $as_echo "$ac_try_echo") >&5
19103   (eval "$ac_compile") 2>conftest.er1
19104   ac_status=$?
19105   grep -v '^ *+' conftest.er1 >conftest.err
19106   rm -f conftest.er1
19107   cat conftest.err >&5
19108   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19109   (exit $ac_status); } && {
19110          test -z "$ac_c_werror_flag" ||
19111          test ! -s conftest.err
19112        } && test -s conftest.$ac_objext; then
19113   ac_not_found=no; break 4
19114 else
19115   $as_echo "$as_me: failed program was:" >&5
19116 sed 's/^/| /' conftest.$ac_ext >&5
19117
19118         ac_not_found=yes
19119 fi
19120
19121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19122        done
19123       done
19124      done
19125     done
19126     if test "$ac_not_found" = yes; then
19127       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
19128 $as_echo "$as_me: error: could not determine argument types" >&2;}
19129    { (exit 1); exit 1; }; }
19130     fi
19131     if test "$ac_cv_func_accept_arg3" = "void"; then
19132       ac_cv_func_accept_arg3=int
19133     fi
19134
19135 fi
19136
19137 fi
19138
19139 fi
19140
19141 fi
19142  { $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
19143 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
19144
19145 cat >>confdefs.h <<_ACEOF
19146 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
19147 _ACEOF
19148
19149
19150 cat >>confdefs.h <<_ACEOF
19151 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
19152 _ACEOF
19153
19154
19155 cat >>confdefs.h <<_ACEOF
19156 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
19157 _ACEOF
19158
19159
19160 cat >>confdefs.h <<_ACEOF
19161 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
19162 _ACEOF
19163
19164
19165 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
19166 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
19167 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
19168   $as_echo_n "(cached) " >&6
19169 else
19170   cat >conftest.$ac_ext <<_ACEOF
19171 /* confdefs.h.  */
19172 _ACEOF
19173 cat confdefs.h >>conftest.$ac_ext
19174 cat >>conftest.$ac_ext <<_ACEOF
19175 /* end confdefs.h.  */
19176 #include <sys/time.h>
19177 int
19178 main ()
19179 {
19180 struct timeval *tp;
19181 struct timezone *tzp;
19182 gettimeofday(tp,tzp);
19183   ;
19184   return 0;
19185 }
19186 _ACEOF
19187 rm -f conftest.$ac_objext
19188 if { (ac_try="$ac_compile"
19189 case "(($ac_try" in
19190   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19191   *) ac_try_echo=$ac_try;;
19192 esac
19193 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19194 $as_echo "$ac_try_echo") >&5
19195   (eval "$ac_compile") 2>conftest.er1
19196   ac_status=$?
19197   grep -v '^ *+' conftest.er1 >conftest.err
19198   rm -f conftest.er1
19199   cat conftest.err >&5
19200   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19201   (exit $ac_status); } && {
19202          test -z "$ac_c_werror_flag" ||
19203          test ! -s conftest.err
19204        } && test -s conftest.$ac_objext; then
19205   pgac_cv_func_gettimeofday_1arg=no
19206 else
19207   $as_echo "$as_me: failed program was:" >&5
19208 sed 's/^/| /' conftest.$ac_ext >&5
19209
19210         pgac_cv_func_gettimeofday_1arg=yes
19211 fi
19212
19213 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19214 fi
19215 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
19216 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
19217 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
19218
19219 cat >>confdefs.h <<\_ACEOF
19220 #define GETTIMEOFDAY_1ARG /**/
19221 _ACEOF
19222
19223 fi
19224
19225
19226
19227
19228
19229
19230
19231
19232
19233
19234
19235
19236
19237
19238
19239
19240
19241
19242
19243
19244
19245
19246
19247 for ac_func in cbrt dlopen fdatasync getifaddrs getpeerucred getrlimit memmove poll pstat readlink setproctitle setsid sigprocmask symlink sync_file_range towlower utime utimes wcstombs wcstombs_l
19248 do
19249 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19250 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19251 $as_echo_n "checking for $ac_func... " >&6; }
19252 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19253   $as_echo_n "(cached) " >&6
19254 else
19255   cat >conftest.$ac_ext <<_ACEOF
19256 /* confdefs.h.  */
19257 _ACEOF
19258 cat confdefs.h >>conftest.$ac_ext
19259 cat >>conftest.$ac_ext <<_ACEOF
19260 /* end confdefs.h.  */
19261 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19262    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19263 #define $ac_func innocuous_$ac_func
19264
19265 /* System header to define __stub macros and hopefully few prototypes,
19266     which can conflict with char $ac_func (); below.
19267     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19268     <limits.h> exists even on freestanding compilers.  */
19269
19270 #ifdef __STDC__
19271 # include <limits.h>
19272 #else
19273 # include <assert.h>
19274 #endif
19275
19276 #undef $ac_func
19277
19278 /* Override any GCC internal prototype to avoid an error.
19279    Use char because int might match the return type of a GCC
19280    builtin and then its argument prototype would still apply.  */
19281 #ifdef __cplusplus
19282 extern "C"
19283 #endif
19284 char $ac_func ();
19285 /* The GNU C library defines this for functions which it implements
19286     to always fail with ENOSYS.  Some functions are actually named
19287     something starting with __ and the normal name is an alias.  */
19288 #if defined __stub_$ac_func || defined __stub___$ac_func
19289 choke me
19290 #endif
19291
19292 int
19293 main ()
19294 {
19295 return $ac_func ();
19296   ;
19297   return 0;
19298 }
19299 _ACEOF
19300 rm -f conftest.$ac_objext conftest$ac_exeext
19301 if { (ac_try="$ac_link"
19302 case "(($ac_try" in
19303   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19304   *) ac_try_echo=$ac_try;;
19305 esac
19306 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19307 $as_echo "$ac_try_echo") >&5
19308   (eval "$ac_link") 2>conftest.er1
19309   ac_status=$?
19310   grep -v '^ *+' conftest.er1 >conftest.err
19311   rm -f conftest.er1
19312   cat conftest.err >&5
19313   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19314   (exit $ac_status); } && {
19315          test -z "$ac_c_werror_flag" ||
19316          test ! -s conftest.err
19317        } && test -s conftest$ac_exeext && {
19318          test "$cross_compiling" = yes ||
19319          $as_test_x conftest$ac_exeext
19320        }; then
19321   eval "$as_ac_var=yes"
19322 else
19323   $as_echo "$as_me: failed program was:" >&5
19324 sed 's/^/| /' conftest.$ac_ext >&5
19325
19326         eval "$as_ac_var=no"
19327 fi
19328
19329 rm -rf conftest.dSYM
19330 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19331       conftest$ac_exeext conftest.$ac_ext
19332 fi
19333 ac_res=`eval 'as_val=${'$as_ac_var'}
19334                  $as_echo "$as_val"'`
19335                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19336 $as_echo "$ac_res" >&6; }
19337 as_val=`eval 'as_val=${'$as_ac_var'}
19338                  $as_echo "$as_val"'`
19339    if test "x$as_val" = x""yes; then
19340   cat >>confdefs.h <<_ACEOF
19341 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19342 _ACEOF
19343
19344 fi
19345 done
19346
19347
19348
19349 for ac_func in fseeko
19350 do
19351 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19352 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19353 $as_echo_n "checking for $ac_func... " >&6; }
19354 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19355   $as_echo_n "(cached) " >&6
19356 else
19357   cat >conftest.$ac_ext <<_ACEOF
19358 /* confdefs.h.  */
19359 _ACEOF
19360 cat confdefs.h >>conftest.$ac_ext
19361 cat >>conftest.$ac_ext <<_ACEOF
19362 /* end confdefs.h.  */
19363 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19364    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19365 #define $ac_func innocuous_$ac_func
19366
19367 /* System header to define __stub macros and hopefully few prototypes,
19368     which can conflict with char $ac_func (); below.
19369     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19370     <limits.h> exists even on freestanding compilers.  */
19371
19372 #ifdef __STDC__
19373 # include <limits.h>
19374 #else
19375 # include <assert.h>
19376 #endif
19377
19378 #undef $ac_func
19379
19380 /* Override any GCC internal prototype to avoid an error.
19381    Use char because int might match the return type of a GCC
19382    builtin and then its argument prototype would still apply.  */
19383 #ifdef __cplusplus
19384 extern "C"
19385 #endif
19386 char $ac_func ();
19387 /* The GNU C library defines this for functions which it implements
19388     to always fail with ENOSYS.  Some functions are actually named
19389     something starting with __ and the normal name is an alias.  */
19390 #if defined __stub_$ac_func || defined __stub___$ac_func
19391 choke me
19392 #endif
19393
19394 int
19395 main ()
19396 {
19397 return $ac_func ();
19398   ;
19399   return 0;
19400 }
19401 _ACEOF
19402 rm -f conftest.$ac_objext 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>conftest.er1
19411   ac_status=$?
19412   grep -v '^ *+' conftest.er1 >conftest.err
19413   rm -f conftest.er1
19414   cat conftest.err >&5
19415   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19416   (exit $ac_status); } && {
19417          test -z "$ac_c_werror_flag" ||
19418          test ! -s conftest.err
19419        } && test -s conftest$ac_exeext && {
19420          test "$cross_compiling" = yes ||
19421          $as_test_x conftest$ac_exeext
19422        }; then
19423   eval "$as_ac_var=yes"
19424 else
19425   $as_echo "$as_me: failed program was:" >&5
19426 sed 's/^/| /' conftest.$ac_ext >&5
19427
19428         eval "$as_ac_var=no"
19429 fi
19430
19431 rm -rf conftest.dSYM
19432 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19433       conftest$ac_exeext conftest.$ac_ext
19434 fi
19435 ac_res=`eval 'as_val=${'$as_ac_var'}
19436                  $as_echo "$as_val"'`
19437                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19438 $as_echo "$ac_res" >&6; }
19439 as_val=`eval 'as_val=${'$as_ac_var'}
19440                  $as_echo "$as_val"'`
19441    if test "x$as_val" = x""yes; then
19442   cat >>confdefs.h <<_ACEOF
19443 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19444 _ACEOF
19445
19446 else
19447   case " $LIBOBJS " in
19448   *" $ac_func.$ac_objext "* ) ;;
19449   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19450  ;;
19451 esac
19452
19453 fi
19454 done
19455
19456
19457 case $host_os in
19458         # NetBSD uses a custom fseeko/ftello built on fsetpos/fgetpos
19459         # Mingw uses macros to access Win32 API calls
19460         netbsd*|mingw*)
19461
19462 cat >>confdefs.h <<\_ACEOF
19463 #define HAVE_FSEEKO 1
19464 _ACEOF
19465
19466                 ac_cv_func_fseeko=yes;;
19467         *)
19468                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
19469 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
19470 if test "${ac_cv_sys_largefile_source+set}" = set; then
19471   $as_echo_n "(cached) " >&6
19472 else
19473   while :; do
19474   cat >conftest.$ac_ext <<_ACEOF
19475 /* confdefs.h.  */
19476 _ACEOF
19477 cat confdefs.h >>conftest.$ac_ext
19478 cat >>conftest.$ac_ext <<_ACEOF
19479 /* end confdefs.h.  */
19480 #include <sys/types.h> /* for off_t */
19481      #include <stdio.h>
19482 int
19483 main ()
19484 {
19485 int (*fp) (FILE *, off_t, int) = fseeko;
19486      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19487   ;
19488   return 0;
19489 }
19490 _ACEOF
19491 rm -f conftest.$ac_objext conftest$ac_exeext
19492 if { (ac_try="$ac_link"
19493 case "(($ac_try" in
19494   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19495   *) ac_try_echo=$ac_try;;
19496 esac
19497 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19498 $as_echo "$ac_try_echo") >&5
19499   (eval "$ac_link") 2>conftest.er1
19500   ac_status=$?
19501   grep -v '^ *+' conftest.er1 >conftest.err
19502   rm -f conftest.er1
19503   cat conftest.err >&5
19504   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19505   (exit $ac_status); } && {
19506          test -z "$ac_c_werror_flag" ||
19507          test ! -s conftest.err
19508        } && test -s conftest$ac_exeext && {
19509          test "$cross_compiling" = yes ||
19510          $as_test_x conftest$ac_exeext
19511        }; then
19512   ac_cv_sys_largefile_source=no; break
19513 else
19514   $as_echo "$as_me: failed program was:" >&5
19515 sed 's/^/| /' conftest.$ac_ext >&5
19516
19517
19518 fi
19519
19520 rm -rf conftest.dSYM
19521 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19522       conftest$ac_exeext conftest.$ac_ext
19523   cat >conftest.$ac_ext <<_ACEOF
19524 /* confdefs.h.  */
19525 _ACEOF
19526 cat confdefs.h >>conftest.$ac_ext
19527 cat >>conftest.$ac_ext <<_ACEOF
19528 /* end confdefs.h.  */
19529 #define _LARGEFILE_SOURCE 1
19530 #include <sys/types.h> /* for off_t */
19531      #include <stdio.h>
19532 int
19533 main ()
19534 {
19535 int (*fp) (FILE *, off_t, int) = fseeko;
19536      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19537   ;
19538   return 0;
19539 }
19540 _ACEOF
19541 rm -f conftest.$ac_objext conftest$ac_exeext
19542 if { (ac_try="$ac_link"
19543 case "(($ac_try" in
19544   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19545   *) ac_try_echo=$ac_try;;
19546 esac
19547 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19548 $as_echo "$ac_try_echo") >&5
19549   (eval "$ac_link") 2>conftest.er1
19550   ac_status=$?
19551   grep -v '^ *+' conftest.er1 >conftest.err
19552   rm -f conftest.er1
19553   cat conftest.err >&5
19554   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19555   (exit $ac_status); } && {
19556          test -z "$ac_c_werror_flag" ||
19557          test ! -s conftest.err
19558        } && test -s conftest$ac_exeext && {
19559          test "$cross_compiling" = yes ||
19560          $as_test_x conftest$ac_exeext
19561        }; then
19562   ac_cv_sys_largefile_source=1; break
19563 else
19564   $as_echo "$as_me: failed program was:" >&5
19565 sed 's/^/| /' conftest.$ac_ext >&5
19566
19567
19568 fi
19569
19570 rm -rf conftest.dSYM
19571 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19572       conftest$ac_exeext conftest.$ac_ext
19573   ac_cv_sys_largefile_source=unknown
19574   break
19575 done
19576 fi
19577 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
19578 $as_echo "$ac_cv_sys_largefile_source" >&6; }
19579 case $ac_cv_sys_largefile_source in #(
19580   no | unknown) ;;
19581   *)
19582 cat >>confdefs.h <<_ACEOF
19583 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
19584 _ACEOF
19585 ;;
19586 esac
19587 rm -rf conftest*
19588
19589 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
19590 # in glibc 2.1.3, but that breaks too many other things.
19591 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
19592 if test $ac_cv_sys_largefile_source != unknown; then
19593
19594 cat >>confdefs.h <<\_ACEOF
19595 #define HAVE_FSEEKO 1
19596 _ACEOF
19597
19598 fi
19599 ;;
19600 esac
19601
19602 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
19603 # by calling it, 2009-04-02
19604 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
19605 if test "$PORTNAME" != "solaris"; then
19606
19607 for ac_func in posix_fadvise
19608 do
19609 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19610 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19611 $as_echo_n "checking for $ac_func... " >&6; }
19612 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19613   $as_echo_n "(cached) " >&6
19614 else
19615   cat >conftest.$ac_ext <<_ACEOF
19616 /* confdefs.h.  */
19617 _ACEOF
19618 cat confdefs.h >>conftest.$ac_ext
19619 cat >>conftest.$ac_ext <<_ACEOF
19620 /* end confdefs.h.  */
19621 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19622    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19623 #define $ac_func innocuous_$ac_func
19624
19625 /* System header to define __stub macros and hopefully few prototypes,
19626     which can conflict with char $ac_func (); below.
19627     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19628     <limits.h> exists even on freestanding compilers.  */
19629
19630 #ifdef __STDC__
19631 # include <limits.h>
19632 #else
19633 # include <assert.h>
19634 #endif
19635
19636 #undef $ac_func
19637
19638 /* Override any GCC internal prototype to avoid an error.
19639    Use char because int might match the return type of a GCC
19640    builtin and then its argument prototype would still apply.  */
19641 #ifdef __cplusplus
19642 extern "C"
19643 #endif
19644 char $ac_func ();
19645 /* The GNU C library defines this for functions which it implements
19646     to always fail with ENOSYS.  Some functions are actually named
19647     something starting with __ and the normal name is an alias.  */
19648 #if defined __stub_$ac_func || defined __stub___$ac_func
19649 choke me
19650 #endif
19651
19652 int
19653 main ()
19654 {
19655 return $ac_func ();
19656   ;
19657   return 0;
19658 }
19659 _ACEOF
19660 rm -f conftest.$ac_objext conftest$ac_exeext
19661 if { (ac_try="$ac_link"
19662 case "(($ac_try" in
19663   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19664   *) ac_try_echo=$ac_try;;
19665 esac
19666 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19667 $as_echo "$ac_try_echo") >&5
19668   (eval "$ac_link") 2>conftest.er1
19669   ac_status=$?
19670   grep -v '^ *+' conftest.er1 >conftest.err
19671   rm -f conftest.er1
19672   cat conftest.err >&5
19673   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19674   (exit $ac_status); } && {
19675          test -z "$ac_c_werror_flag" ||
19676          test ! -s conftest.err
19677        } && test -s conftest$ac_exeext && {
19678          test "$cross_compiling" = yes ||
19679          $as_test_x conftest$ac_exeext
19680        }; then
19681   eval "$as_ac_var=yes"
19682 else
19683   $as_echo "$as_me: failed program was:" >&5
19684 sed 's/^/| /' conftest.$ac_ext >&5
19685
19686         eval "$as_ac_var=no"
19687 fi
19688
19689 rm -rf conftest.dSYM
19690 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19691       conftest$ac_exeext conftest.$ac_ext
19692 fi
19693 ac_res=`eval 'as_val=${'$as_ac_var'}
19694                  $as_echo "$as_val"'`
19695                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19696 $as_echo "$ac_res" >&6; }
19697 as_val=`eval 'as_val=${'$as_ac_var'}
19698                  $as_echo "$as_val"'`
19699    if test "x$as_val" = x""yes; then
19700   cat >>confdefs.h <<_ACEOF
19701 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19702 _ACEOF
19703
19704 fi
19705 done
19706
19707 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
19708 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
19709 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
19710   $as_echo_n "(cached) " >&6
19711 else
19712   cat >conftest.$ac_ext <<_ACEOF
19713 /* confdefs.h.  */
19714 _ACEOF
19715 cat confdefs.h >>conftest.$ac_ext
19716 cat >>conftest.$ac_ext <<_ACEOF
19717 /* end confdefs.h.  */
19718 #include <fcntl.h>
19719
19720 int
19721 main ()
19722 {
19723 #ifndef posix_fadvise
19724   (void) posix_fadvise;
19725 #endif
19726
19727   ;
19728   return 0;
19729 }
19730 _ACEOF
19731 rm -f conftest.$ac_objext
19732 if { (ac_try="$ac_compile"
19733 case "(($ac_try" in
19734   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19735   *) ac_try_echo=$ac_try;;
19736 esac
19737 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19738 $as_echo "$ac_try_echo") >&5
19739   (eval "$ac_compile") 2>conftest.er1
19740   ac_status=$?
19741   grep -v '^ *+' conftest.er1 >conftest.err
19742   rm -f conftest.er1
19743   cat conftest.err >&5
19744   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19745   (exit $ac_status); } && {
19746          test -z "$ac_c_werror_flag" ||
19747          test ! -s conftest.err
19748        } && test -s conftest.$ac_objext; then
19749   ac_cv_have_decl_posix_fadvise=yes
19750 else
19751   $as_echo "$as_me: failed program was:" >&5
19752 sed 's/^/| /' conftest.$ac_ext >&5
19753
19754         ac_cv_have_decl_posix_fadvise=no
19755 fi
19756
19757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19758 fi
19759 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
19760 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
19761 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
19762
19763 cat >>confdefs.h <<_ACEOF
19764 #define HAVE_DECL_POSIX_FADVISE 1
19765 _ACEOF
19766
19767
19768 else
19769   cat >>confdefs.h <<_ACEOF
19770 #define HAVE_DECL_POSIX_FADVISE 0
19771 _ACEOF
19772
19773
19774 fi
19775
19776
19777 fi
19778
19779 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
19780 $as_echo_n "checking whether fdatasync is declared... " >&6; }
19781 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
19782   $as_echo_n "(cached) " >&6
19783 else
19784   cat >conftest.$ac_ext <<_ACEOF
19785 /* confdefs.h.  */
19786 _ACEOF
19787 cat confdefs.h >>conftest.$ac_ext
19788 cat >>conftest.$ac_ext <<_ACEOF
19789 /* end confdefs.h.  */
19790 #include <unistd.h>
19791
19792 int
19793 main ()
19794 {
19795 #ifndef fdatasync
19796   (void) fdatasync;
19797 #endif
19798
19799   ;
19800   return 0;
19801 }
19802 _ACEOF
19803 rm -f conftest.$ac_objext
19804 if { (ac_try="$ac_compile"
19805 case "(($ac_try" in
19806   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19807   *) ac_try_echo=$ac_try;;
19808 esac
19809 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19810 $as_echo "$ac_try_echo") >&5
19811   (eval "$ac_compile") 2>conftest.er1
19812   ac_status=$?
19813   grep -v '^ *+' conftest.er1 >conftest.err
19814   rm -f conftest.er1
19815   cat conftest.err >&5
19816   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19817   (exit $ac_status); } && {
19818          test -z "$ac_c_werror_flag" ||
19819          test ! -s conftest.err
19820        } && test -s conftest.$ac_objext; then
19821   ac_cv_have_decl_fdatasync=yes
19822 else
19823   $as_echo "$as_me: failed program was:" >&5
19824 sed 's/^/| /' conftest.$ac_ext >&5
19825
19826         ac_cv_have_decl_fdatasync=no
19827 fi
19828
19829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19830 fi
19831 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
19832 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
19833 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
19834
19835 cat >>confdefs.h <<_ACEOF
19836 #define HAVE_DECL_FDATASYNC 1
19837 _ACEOF
19838
19839
19840 else
19841   cat >>confdefs.h <<_ACEOF
19842 #define HAVE_DECL_FDATASYNC 0
19843 _ACEOF
19844
19845
19846 fi
19847
19848
19849 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
19850 $as_echo_n "checking whether strlcat is declared... " >&6; }
19851 if test "${ac_cv_have_decl_strlcat+set}" = set; then
19852   $as_echo_n "(cached) " >&6
19853 else
19854   cat >conftest.$ac_ext <<_ACEOF
19855 /* confdefs.h.  */
19856 _ACEOF
19857 cat confdefs.h >>conftest.$ac_ext
19858 cat >>conftest.$ac_ext <<_ACEOF
19859 /* end confdefs.h.  */
19860 $ac_includes_default
19861 int
19862 main ()
19863 {
19864 #ifndef strlcat
19865   (void) strlcat;
19866 #endif
19867
19868   ;
19869   return 0;
19870 }
19871 _ACEOF
19872 rm -f conftest.$ac_objext
19873 if { (ac_try="$ac_compile"
19874 case "(($ac_try" in
19875   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19876   *) ac_try_echo=$ac_try;;
19877 esac
19878 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19879 $as_echo "$ac_try_echo") >&5
19880   (eval "$ac_compile") 2>conftest.er1
19881   ac_status=$?
19882   grep -v '^ *+' conftest.er1 >conftest.err
19883   rm -f conftest.er1
19884   cat conftest.err >&5
19885   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19886   (exit $ac_status); } && {
19887          test -z "$ac_c_werror_flag" ||
19888          test ! -s conftest.err
19889        } && test -s conftest.$ac_objext; then
19890   ac_cv_have_decl_strlcat=yes
19891 else
19892   $as_echo "$as_me: failed program was:" >&5
19893 sed 's/^/| /' conftest.$ac_ext >&5
19894
19895         ac_cv_have_decl_strlcat=no
19896 fi
19897
19898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19899 fi
19900 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
19901 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
19902 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
19903
19904 cat >>confdefs.h <<_ACEOF
19905 #define HAVE_DECL_STRLCAT 1
19906 _ACEOF
19907
19908
19909 else
19910   cat >>confdefs.h <<_ACEOF
19911 #define HAVE_DECL_STRLCAT 0
19912 _ACEOF
19913
19914
19915 fi
19916 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
19917 $as_echo_n "checking whether strlcpy is declared... " >&6; }
19918 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
19919   $as_echo_n "(cached) " >&6
19920 else
19921   cat >conftest.$ac_ext <<_ACEOF
19922 /* confdefs.h.  */
19923 _ACEOF
19924 cat confdefs.h >>conftest.$ac_ext
19925 cat >>conftest.$ac_ext <<_ACEOF
19926 /* end confdefs.h.  */
19927 $ac_includes_default
19928 int
19929 main ()
19930 {
19931 #ifndef strlcpy
19932   (void) strlcpy;
19933 #endif
19934
19935   ;
19936   return 0;
19937 }
19938 _ACEOF
19939 rm -f conftest.$ac_objext
19940 if { (ac_try="$ac_compile"
19941 case "(($ac_try" in
19942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19943   *) ac_try_echo=$ac_try;;
19944 esac
19945 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19946 $as_echo "$ac_try_echo") >&5
19947   (eval "$ac_compile") 2>conftest.er1
19948   ac_status=$?
19949   grep -v '^ *+' conftest.er1 >conftest.err
19950   rm -f conftest.er1
19951   cat conftest.err >&5
19952   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19953   (exit $ac_status); } && {
19954          test -z "$ac_c_werror_flag" ||
19955          test ! -s conftest.err
19956        } && test -s conftest.$ac_objext; then
19957   ac_cv_have_decl_strlcpy=yes
19958 else
19959   $as_echo "$as_me: failed program was:" >&5
19960 sed 's/^/| /' conftest.$ac_ext >&5
19961
19962         ac_cv_have_decl_strlcpy=no
19963 fi
19964
19965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19966 fi
19967 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
19968 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
19969 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
19970
19971 cat >>confdefs.h <<_ACEOF
19972 #define HAVE_DECL_STRLCPY 1
19973 _ACEOF
19974
19975
19976 else
19977   cat >>confdefs.h <<_ACEOF
19978 #define HAVE_DECL_STRLCPY 0
19979 _ACEOF
19980
19981
19982 fi
19983
19984
19985 # This is probably only present on Darwin, but may as well check always
19986 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
19987 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
19988 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
19989   $as_echo_n "(cached) " >&6
19990 else
19991   cat >conftest.$ac_ext <<_ACEOF
19992 /* confdefs.h.  */
19993 _ACEOF
19994 cat confdefs.h >>conftest.$ac_ext
19995 cat >>conftest.$ac_ext <<_ACEOF
19996 /* end confdefs.h.  */
19997 #include <fcntl.h>
19998
19999 int
20000 main ()
20001 {
20002 #ifndef F_FULLFSYNC
20003   (void) F_FULLFSYNC;
20004 #endif
20005
20006   ;
20007   return 0;
20008 }
20009 _ACEOF
20010 rm -f conftest.$ac_objext
20011 if { (ac_try="$ac_compile"
20012 case "(($ac_try" in
20013   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20014   *) ac_try_echo=$ac_try;;
20015 esac
20016 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20017 $as_echo "$ac_try_echo") >&5
20018   (eval "$ac_compile") 2>conftest.er1
20019   ac_status=$?
20020   grep -v '^ *+' conftest.er1 >conftest.err
20021   rm -f conftest.er1
20022   cat conftest.err >&5
20023   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20024   (exit $ac_status); } && {
20025          test -z "$ac_c_werror_flag" ||
20026          test ! -s conftest.err
20027        } && test -s conftest.$ac_objext; then
20028   ac_cv_have_decl_F_FULLFSYNC=yes
20029 else
20030   $as_echo "$as_me: failed program was:" >&5
20031 sed 's/^/| /' conftest.$ac_ext >&5
20032
20033         ac_cv_have_decl_F_FULLFSYNC=no
20034 fi
20035
20036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20037 fi
20038 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
20039 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
20040 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
20041
20042 cat >>confdefs.h <<_ACEOF
20043 #define HAVE_DECL_F_FULLFSYNC 1
20044 _ACEOF
20045
20046
20047 else
20048   cat >>confdefs.h <<_ACEOF
20049 #define HAVE_DECL_F_FULLFSYNC 0
20050 _ACEOF
20051
20052
20053 fi
20054
20055
20056
20057 HAVE_IPV6=no
20058 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
20059 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
20060 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
20061   $as_echo_n "(cached) " >&6
20062 else
20063   ac_cv_type_struct_sockaddr_in6=no
20064 cat >conftest.$ac_ext <<_ACEOF
20065 /* confdefs.h.  */
20066 _ACEOF
20067 cat confdefs.h >>conftest.$ac_ext
20068 cat >>conftest.$ac_ext <<_ACEOF
20069 /* end confdefs.h.  */
20070 $ac_includes_default
20071 #include <netinet/in.h>
20072
20073 int
20074 main ()
20075 {
20076 if (sizeof (struct sockaddr_in6))
20077        return 0;
20078   ;
20079   return 0;
20080 }
20081 _ACEOF
20082 rm -f conftest.$ac_objext
20083 if { (ac_try="$ac_compile"
20084 case "(($ac_try" in
20085   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20086   *) ac_try_echo=$ac_try;;
20087 esac
20088 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20089 $as_echo "$ac_try_echo") >&5
20090   (eval "$ac_compile") 2>conftest.er1
20091   ac_status=$?
20092   grep -v '^ *+' conftest.er1 >conftest.err
20093   rm -f conftest.er1
20094   cat conftest.err >&5
20095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20096   (exit $ac_status); } && {
20097          test -z "$ac_c_werror_flag" ||
20098          test ! -s conftest.err
20099        } && test -s conftest.$ac_objext; then
20100   cat >conftest.$ac_ext <<_ACEOF
20101 /* confdefs.h.  */
20102 _ACEOF
20103 cat confdefs.h >>conftest.$ac_ext
20104 cat >>conftest.$ac_ext <<_ACEOF
20105 /* end confdefs.h.  */
20106 $ac_includes_default
20107 #include <netinet/in.h>
20108
20109 int
20110 main ()
20111 {
20112 if (sizeof ((struct sockaddr_in6)))
20113           return 0;
20114   ;
20115   return 0;
20116 }
20117 _ACEOF
20118 rm -f conftest.$ac_objext
20119 if { (ac_try="$ac_compile"
20120 case "(($ac_try" in
20121   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20122   *) ac_try_echo=$ac_try;;
20123 esac
20124 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20125 $as_echo "$ac_try_echo") >&5
20126   (eval "$ac_compile") 2>conftest.er1
20127   ac_status=$?
20128   grep -v '^ *+' conftest.er1 >conftest.err
20129   rm -f conftest.er1
20130   cat conftest.err >&5
20131   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20132   (exit $ac_status); } && {
20133          test -z "$ac_c_werror_flag" ||
20134          test ! -s conftest.err
20135        } && test -s conftest.$ac_objext; then
20136   :
20137 else
20138   $as_echo "$as_me: failed program was:" >&5
20139 sed 's/^/| /' conftest.$ac_ext >&5
20140
20141         ac_cv_type_struct_sockaddr_in6=yes
20142 fi
20143
20144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20145 else
20146   $as_echo "$as_me: failed program was:" >&5
20147 sed 's/^/| /' conftest.$ac_ext >&5
20148
20149
20150 fi
20151
20152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20153 fi
20154 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
20155 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
20156 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
20157
20158 cat >>confdefs.h <<\_ACEOF
20159 #define HAVE_IPV6 1
20160 _ACEOF
20161
20162          HAVE_IPV6=yes
20163 fi
20164
20165
20166
20167 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
20168 $as_echo_n "checking for PS_STRINGS... " >&6; }
20169 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
20170   $as_echo_n "(cached) " >&6
20171 else
20172   cat >conftest.$ac_ext <<_ACEOF
20173 /* confdefs.h.  */
20174 _ACEOF
20175 cat confdefs.h >>conftest.$ac_ext
20176 cat >>conftest.$ac_ext <<_ACEOF
20177 /* end confdefs.h.  */
20178 #include <machine/vmparam.h>
20179 #include <sys/exec.h>
20180
20181 int
20182 main ()
20183 {
20184 PS_STRINGS->ps_nargvstr = 1;
20185 PS_STRINGS->ps_argvstr = "foo";
20186   ;
20187   return 0;
20188 }
20189 _ACEOF
20190 rm -f conftest.$ac_objext conftest$ac_exeext
20191 if { (ac_try="$ac_link"
20192 case "(($ac_try" in
20193   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20194   *) ac_try_echo=$ac_try;;
20195 esac
20196 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20197 $as_echo "$ac_try_echo") >&5
20198   (eval "$ac_link") 2>conftest.er1
20199   ac_status=$?
20200   grep -v '^ *+' conftest.er1 >conftest.err
20201   rm -f conftest.er1
20202   cat conftest.err >&5
20203   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20204   (exit $ac_status); } && {
20205          test -z "$ac_c_werror_flag" ||
20206          test ! -s conftest.err
20207        } && test -s conftest$ac_exeext && {
20208          test "$cross_compiling" = yes ||
20209          $as_test_x conftest$ac_exeext
20210        }; then
20211   pgac_cv_var_PS_STRINGS=yes
20212 else
20213   $as_echo "$as_me: failed program was:" >&5
20214 sed 's/^/| /' conftest.$ac_ext >&5
20215
20216         pgac_cv_var_PS_STRINGS=no
20217 fi
20218
20219 rm -rf conftest.dSYM
20220 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20221       conftest$ac_exeext conftest.$ac_ext
20222 fi
20223 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
20224 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
20225 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
20226
20227 cat >>confdefs.h <<\_ACEOF
20228 #define HAVE_PS_STRINGS /**/
20229 _ACEOF
20230
20231 fi
20232
20233
20234 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
20235 # is missing.  Yes, there are machines that have only one.  We may
20236 # also decide to use snprintf.c if snprintf() is present but does not
20237 # have all the features we need --- see below.
20238
20239 if test "$PORTNAME" = "win32"; then
20240   # Win32 gets snprintf.c built unconditionally.
20241   #
20242   # To properly translate all NLS languages strings, we must support the
20243   # *printf() %$ format, which allows *printf() arguments to be selected
20244   # by position in the translated string.
20245   #
20246   # libintl versions < 0.13 use the native *printf() functions, and Win32
20247   # *printf() doesn't understand %$, so we must use our /port versions,
20248   # which do understand %$. libintl versions >= 0.13 include their own
20249   # *printf versions on Win32.  The libintl 0.13 release note text is:
20250   #
20251   #   C format strings with positions, as they arise when a translator
20252   #   needs to reorder a sentence, are now supported on all platforms.
20253   #   On those few platforms (NetBSD and Woe32) for which the native
20254   #   printf()/fprintf()/... functions don't support such format
20255   #   strings, replacements are provided through <libintl.h>.
20256   #
20257   # We could use libintl >= 0.13's *printf() if we were sure that we had
20258   # a litint >= 0.13 at runtime, but seeing that there is no clean way
20259   # to guarantee that, it is best to just use our own, so we are sure to
20260   # get %$ support. In include/port.h we disable the *printf() macros
20261   # that might have been defined by libintl.
20262   #
20263   # We do this unconditionally whether NLS is used or not so we are sure
20264   # that all Win32 libraries and binaries behave the same.
20265   pgac_need_repl_snprintf=yes
20266 else
20267   pgac_need_repl_snprintf=no
20268
20269 for ac_func in snprintf
20270 do
20271 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20272 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20273 $as_echo_n "checking for $ac_func... " >&6; }
20274 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20275   $as_echo_n "(cached) " >&6
20276 else
20277   cat >conftest.$ac_ext <<_ACEOF
20278 /* confdefs.h.  */
20279 _ACEOF
20280 cat confdefs.h >>conftest.$ac_ext
20281 cat >>conftest.$ac_ext <<_ACEOF
20282 /* end confdefs.h.  */
20283 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20284    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20285 #define $ac_func innocuous_$ac_func
20286
20287 /* System header to define __stub macros and hopefully few prototypes,
20288     which can conflict with char $ac_func (); below.
20289     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20290     <limits.h> exists even on freestanding compilers.  */
20291
20292 #ifdef __STDC__
20293 # include <limits.h>
20294 #else
20295 # include <assert.h>
20296 #endif
20297
20298 #undef $ac_func
20299
20300 /* Override any GCC internal prototype to avoid an error.
20301    Use char because int might match the return type of a GCC
20302    builtin and then its argument prototype would still apply.  */
20303 #ifdef __cplusplus
20304 extern "C"
20305 #endif
20306 char $ac_func ();
20307 /* The GNU C library defines this for functions which it implements
20308     to always fail with ENOSYS.  Some functions are actually named
20309     something starting with __ and the normal name is an alias.  */
20310 #if defined __stub_$ac_func || defined __stub___$ac_func
20311 choke me
20312 #endif
20313
20314 int
20315 main ()
20316 {
20317 return $ac_func ();
20318   ;
20319   return 0;
20320 }
20321 _ACEOF
20322 rm -f conftest.$ac_objext conftest$ac_exeext
20323 if { (ac_try="$ac_link"
20324 case "(($ac_try" in
20325   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20326   *) ac_try_echo=$ac_try;;
20327 esac
20328 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20329 $as_echo "$ac_try_echo") >&5
20330   (eval "$ac_link") 2>conftest.er1
20331   ac_status=$?
20332   grep -v '^ *+' conftest.er1 >conftest.err
20333   rm -f conftest.er1
20334   cat conftest.err >&5
20335   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20336   (exit $ac_status); } && {
20337          test -z "$ac_c_werror_flag" ||
20338          test ! -s conftest.err
20339        } && test -s conftest$ac_exeext && {
20340          test "$cross_compiling" = yes ||
20341          $as_test_x conftest$ac_exeext
20342        }; then
20343   eval "$as_ac_var=yes"
20344 else
20345   $as_echo "$as_me: failed program was:" >&5
20346 sed 's/^/| /' conftest.$ac_ext >&5
20347
20348         eval "$as_ac_var=no"
20349 fi
20350
20351 rm -rf conftest.dSYM
20352 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20353       conftest$ac_exeext conftest.$ac_ext
20354 fi
20355 ac_res=`eval 'as_val=${'$as_ac_var'}
20356                  $as_echo "$as_val"'`
20357                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20358 $as_echo "$ac_res" >&6; }
20359 as_val=`eval 'as_val=${'$as_ac_var'}
20360                  $as_echo "$as_val"'`
20361    if test "x$as_val" = x""yes; then
20362   cat >>confdefs.h <<_ACEOF
20363 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20364 _ACEOF
20365
20366 else
20367   pgac_need_repl_snprintf=yes
20368 fi
20369 done
20370
20371
20372 for ac_func in vsnprintf
20373 do
20374 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20375 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20376 $as_echo_n "checking for $ac_func... " >&6; }
20377 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20378   $as_echo_n "(cached) " >&6
20379 else
20380   cat >conftest.$ac_ext <<_ACEOF
20381 /* confdefs.h.  */
20382 _ACEOF
20383 cat confdefs.h >>conftest.$ac_ext
20384 cat >>conftest.$ac_ext <<_ACEOF
20385 /* end confdefs.h.  */
20386 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20387    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20388 #define $ac_func innocuous_$ac_func
20389
20390 /* System header to define __stub macros and hopefully few prototypes,
20391     which can conflict with char $ac_func (); below.
20392     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20393     <limits.h> exists even on freestanding compilers.  */
20394
20395 #ifdef __STDC__
20396 # include <limits.h>
20397 #else
20398 # include <assert.h>
20399 #endif
20400
20401 #undef $ac_func
20402
20403 /* Override any GCC internal prototype to avoid an error.
20404    Use char because int might match the return type of a GCC
20405    builtin and then its argument prototype would still apply.  */
20406 #ifdef __cplusplus
20407 extern "C"
20408 #endif
20409 char $ac_func ();
20410 /* The GNU C library defines this for functions which it implements
20411     to always fail with ENOSYS.  Some functions are actually named
20412     something starting with __ and the normal name is an alias.  */
20413 #if defined __stub_$ac_func || defined __stub___$ac_func
20414 choke me
20415 #endif
20416
20417 int
20418 main ()
20419 {
20420 return $ac_func ();
20421   ;
20422   return 0;
20423 }
20424 _ACEOF
20425 rm -f conftest.$ac_objext conftest$ac_exeext
20426 if { (ac_try="$ac_link"
20427 case "(($ac_try" in
20428   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20429   *) ac_try_echo=$ac_try;;
20430 esac
20431 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20432 $as_echo "$ac_try_echo") >&5
20433   (eval "$ac_link") 2>conftest.er1
20434   ac_status=$?
20435   grep -v '^ *+' conftest.er1 >conftest.err
20436   rm -f conftest.er1
20437   cat conftest.err >&5
20438   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20439   (exit $ac_status); } && {
20440          test -z "$ac_c_werror_flag" ||
20441          test ! -s conftest.err
20442        } && test -s conftest$ac_exeext && {
20443          test "$cross_compiling" = yes ||
20444          $as_test_x conftest$ac_exeext
20445        }; then
20446   eval "$as_ac_var=yes"
20447 else
20448   $as_echo "$as_me: failed program was:" >&5
20449 sed 's/^/| /' conftest.$ac_ext >&5
20450
20451         eval "$as_ac_var=no"
20452 fi
20453
20454 rm -rf conftest.dSYM
20455 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20456       conftest$ac_exeext conftest.$ac_ext
20457 fi
20458 ac_res=`eval 'as_val=${'$as_ac_var'}
20459                  $as_echo "$as_val"'`
20460                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20461 $as_echo "$ac_res" >&6; }
20462 as_val=`eval 'as_val=${'$as_ac_var'}
20463                  $as_echo "$as_val"'`
20464    if test "x$as_val" = x""yes; then
20465   cat >>confdefs.h <<_ACEOF
20466 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20467 _ACEOF
20468
20469 else
20470   pgac_need_repl_snprintf=yes
20471 fi
20472 done
20473
20474 fi
20475
20476
20477 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
20478 # include/c.h will provide declarations.  Note this is a separate test
20479 # from whether the functions exist in the C library --- there are
20480 # systems that have the functions but don't bother to declare them :-(
20481
20482 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
20483 $as_echo_n "checking whether snprintf is declared... " >&6; }
20484 if test "${ac_cv_have_decl_snprintf+set}" = set; then
20485   $as_echo_n "(cached) " >&6
20486 else
20487   cat >conftest.$ac_ext <<_ACEOF
20488 /* confdefs.h.  */
20489 _ACEOF
20490 cat confdefs.h >>conftest.$ac_ext
20491 cat >>conftest.$ac_ext <<_ACEOF
20492 /* end confdefs.h.  */
20493 $ac_includes_default
20494 int
20495 main ()
20496 {
20497 #ifndef snprintf
20498   (void) snprintf;
20499 #endif
20500
20501   ;
20502   return 0;
20503 }
20504 _ACEOF
20505 rm -f conftest.$ac_objext
20506 if { (ac_try="$ac_compile"
20507 case "(($ac_try" in
20508   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20509   *) ac_try_echo=$ac_try;;
20510 esac
20511 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20512 $as_echo "$ac_try_echo") >&5
20513   (eval "$ac_compile") 2>conftest.er1
20514   ac_status=$?
20515   grep -v '^ *+' conftest.er1 >conftest.err
20516   rm -f conftest.er1
20517   cat conftest.err >&5
20518   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20519   (exit $ac_status); } && {
20520          test -z "$ac_c_werror_flag" ||
20521          test ! -s conftest.err
20522        } && test -s conftest.$ac_objext; then
20523   ac_cv_have_decl_snprintf=yes
20524 else
20525   $as_echo "$as_me: failed program was:" >&5
20526 sed 's/^/| /' conftest.$ac_ext >&5
20527
20528         ac_cv_have_decl_snprintf=no
20529 fi
20530
20531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20532 fi
20533 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
20534 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
20535 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
20536
20537 cat >>confdefs.h <<_ACEOF
20538 #define HAVE_DECL_SNPRINTF 1
20539 _ACEOF
20540
20541
20542 else
20543   cat >>confdefs.h <<_ACEOF
20544 #define HAVE_DECL_SNPRINTF 0
20545 _ACEOF
20546
20547
20548 fi
20549 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
20550 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
20551 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
20552   $as_echo_n "(cached) " >&6
20553 else
20554   cat >conftest.$ac_ext <<_ACEOF
20555 /* confdefs.h.  */
20556 _ACEOF
20557 cat confdefs.h >>conftest.$ac_ext
20558 cat >>conftest.$ac_ext <<_ACEOF
20559 /* end confdefs.h.  */
20560 $ac_includes_default
20561 int
20562 main ()
20563 {
20564 #ifndef vsnprintf
20565   (void) vsnprintf;
20566 #endif
20567
20568   ;
20569   return 0;
20570 }
20571 _ACEOF
20572 rm -f conftest.$ac_objext
20573 if { (ac_try="$ac_compile"
20574 case "(($ac_try" in
20575   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20576   *) ac_try_echo=$ac_try;;
20577 esac
20578 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20579 $as_echo "$ac_try_echo") >&5
20580   (eval "$ac_compile") 2>conftest.er1
20581   ac_status=$?
20582   grep -v '^ *+' conftest.er1 >conftest.err
20583   rm -f conftest.er1
20584   cat conftest.err >&5
20585   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20586   (exit $ac_status); } && {
20587          test -z "$ac_c_werror_flag" ||
20588          test ! -s conftest.err
20589        } && test -s conftest.$ac_objext; then
20590   ac_cv_have_decl_vsnprintf=yes
20591 else
20592   $as_echo "$as_me: failed program was:" >&5
20593 sed 's/^/| /' conftest.$ac_ext >&5
20594
20595         ac_cv_have_decl_vsnprintf=no
20596 fi
20597
20598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20599 fi
20600 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
20601 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
20602 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
20603
20604 cat >>confdefs.h <<_ACEOF
20605 #define HAVE_DECL_VSNPRINTF 1
20606 _ACEOF
20607
20608
20609 else
20610   cat >>confdefs.h <<_ACEOF
20611 #define HAVE_DECL_VSNPRINTF 0
20612 _ACEOF
20613
20614
20615 fi
20616
20617
20618
20619
20620 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
20621 $as_echo_n "checking for isinf... " >&6; }
20622 if test "${ac_cv_func_isinf+set}" = set; then
20623   $as_echo_n "(cached) " >&6
20624 else
20625   cat >conftest.$ac_ext <<_ACEOF
20626 /* confdefs.h.  */
20627 _ACEOF
20628 cat confdefs.h >>conftest.$ac_ext
20629 cat >>conftest.$ac_ext <<_ACEOF
20630 /* end confdefs.h.  */
20631
20632 #include <math.h>
20633 double glob_double;
20634
20635 int
20636 main ()
20637 {
20638 return isinf(glob_double) ? 0 : 1;
20639   ;
20640   return 0;
20641 }
20642 _ACEOF
20643 rm -f conftest.$ac_objext conftest$ac_exeext
20644 if { (ac_try="$ac_link"
20645 case "(($ac_try" in
20646   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20647   *) ac_try_echo=$ac_try;;
20648 esac
20649 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20650 $as_echo "$ac_try_echo") >&5
20651   (eval "$ac_link") 2>conftest.er1
20652   ac_status=$?
20653   grep -v '^ *+' conftest.er1 >conftest.err
20654   rm -f conftest.er1
20655   cat conftest.err >&5
20656   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20657   (exit $ac_status); } && {
20658          test -z "$ac_c_werror_flag" ||
20659          test ! -s conftest.err
20660        } && test -s conftest$ac_exeext && {
20661          test "$cross_compiling" = yes ||
20662          $as_test_x conftest$ac_exeext
20663        }; then
20664   ac_cv_func_isinf=yes
20665 else
20666   $as_echo "$as_me: failed program was:" >&5
20667 sed 's/^/| /' conftest.$ac_ext >&5
20668
20669         ac_cv_func_isinf=no
20670 fi
20671
20672 rm -rf conftest.dSYM
20673 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20674       conftest$ac_exeext conftest.$ac_ext
20675 fi
20676 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
20677 $as_echo "$ac_cv_func_isinf" >&6; }
20678
20679 if test $ac_cv_func_isinf = yes ; then
20680
20681 cat >>confdefs.h <<\_ACEOF
20682 #define HAVE_ISINF 1
20683 _ACEOF
20684
20685 else
20686   case " $LIBOBJS " in
20687   *" isinf.$ac_objext "* ) ;;
20688   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
20689  ;;
20690 esac
20691
20692   # Look for a way to implement a substitute for isinf()
20693
20694
20695
20696
20697 for ac_func in fpclass fp_class fp_class_d class
20698 do
20699 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20700 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20701 $as_echo_n "checking for $ac_func... " >&6; }
20702 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20703   $as_echo_n "(cached) " >&6
20704 else
20705   cat >conftest.$ac_ext <<_ACEOF
20706 /* confdefs.h.  */
20707 _ACEOF
20708 cat confdefs.h >>conftest.$ac_ext
20709 cat >>conftest.$ac_ext <<_ACEOF
20710 /* end confdefs.h.  */
20711 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20712    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20713 #define $ac_func innocuous_$ac_func
20714
20715 /* System header to define __stub macros and hopefully few prototypes,
20716     which can conflict with char $ac_func (); below.
20717     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20718     <limits.h> exists even on freestanding compilers.  */
20719
20720 #ifdef __STDC__
20721 # include <limits.h>
20722 #else
20723 # include <assert.h>
20724 #endif
20725
20726 #undef $ac_func
20727
20728 /* Override any GCC internal prototype to avoid an error.
20729    Use char because int might match the return type of a GCC
20730    builtin and then its argument prototype would still apply.  */
20731 #ifdef __cplusplus
20732 extern "C"
20733 #endif
20734 char $ac_func ();
20735 /* The GNU C library defines this for functions which it implements
20736     to always fail with ENOSYS.  Some functions are actually named
20737     something starting with __ and the normal name is an alias.  */
20738 #if defined __stub_$ac_func || defined __stub___$ac_func
20739 choke me
20740 #endif
20741
20742 int
20743 main ()
20744 {
20745 return $ac_func ();
20746   ;
20747   return 0;
20748 }
20749 _ACEOF
20750 rm -f conftest.$ac_objext conftest$ac_exeext
20751 if { (ac_try="$ac_link"
20752 case "(($ac_try" in
20753   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20754   *) ac_try_echo=$ac_try;;
20755 esac
20756 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20757 $as_echo "$ac_try_echo") >&5
20758   (eval "$ac_link") 2>conftest.er1
20759   ac_status=$?
20760   grep -v '^ *+' conftest.er1 >conftest.err
20761   rm -f conftest.er1
20762   cat conftest.err >&5
20763   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20764   (exit $ac_status); } && {
20765          test -z "$ac_c_werror_flag" ||
20766          test ! -s conftest.err
20767        } && test -s conftest$ac_exeext && {
20768          test "$cross_compiling" = yes ||
20769          $as_test_x conftest$ac_exeext
20770        }; then
20771   eval "$as_ac_var=yes"
20772 else
20773   $as_echo "$as_me: failed program was:" >&5
20774 sed 's/^/| /' conftest.$ac_ext >&5
20775
20776         eval "$as_ac_var=no"
20777 fi
20778
20779 rm -rf conftest.dSYM
20780 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20781       conftest$ac_exeext conftest.$ac_ext
20782 fi
20783 ac_res=`eval 'as_val=${'$as_ac_var'}
20784                  $as_echo "$as_val"'`
20785                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20786 $as_echo "$ac_res" >&6; }
20787 as_val=`eval 'as_val=${'$as_ac_var'}
20788                  $as_echo "$as_val"'`
20789    if test "x$as_val" = x""yes; then
20790   cat >>confdefs.h <<_ACEOF
20791 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20792 _ACEOF
20793  break
20794 fi
20795 done
20796
20797 fi
20798
20799 # Some versions of libedit contain strlcpy(); so disregard that library while
20800 # checking for these standard libc functions.
20801 pgac_save_LIBS="$LIBS"
20802 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
20803
20804
20805
20806
20807
20808
20809
20810
20811
20812
20813
20814
20815 for ac_func in crypt fls getopt getrusage inet_aton random rint srandom strerror strlcat strlcpy
20816 do
20817 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20818 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20819 $as_echo_n "checking for $ac_func... " >&6; }
20820 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20821   $as_echo_n "(cached) " >&6
20822 else
20823   cat >conftest.$ac_ext <<_ACEOF
20824 /* confdefs.h.  */
20825 _ACEOF
20826 cat confdefs.h >>conftest.$ac_ext
20827 cat >>conftest.$ac_ext <<_ACEOF
20828 /* end confdefs.h.  */
20829 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20830    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20831 #define $ac_func innocuous_$ac_func
20832
20833 /* System header to define __stub macros and hopefully few prototypes,
20834     which can conflict with char $ac_func (); below.
20835     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20836     <limits.h> exists even on freestanding compilers.  */
20837
20838 #ifdef __STDC__
20839 # include <limits.h>
20840 #else
20841 # include <assert.h>
20842 #endif
20843
20844 #undef $ac_func
20845
20846 /* Override any GCC internal prototype to avoid an error.
20847    Use char because int might match the return type of a GCC
20848    builtin and then its argument prototype would still apply.  */
20849 #ifdef __cplusplus
20850 extern "C"
20851 #endif
20852 char $ac_func ();
20853 /* The GNU C library defines this for functions which it implements
20854     to always fail with ENOSYS.  Some functions are actually named
20855     something starting with __ and the normal name is an alias.  */
20856 #if defined __stub_$ac_func || defined __stub___$ac_func
20857 choke me
20858 #endif
20859
20860 int
20861 main ()
20862 {
20863 return $ac_func ();
20864   ;
20865   return 0;
20866 }
20867 _ACEOF
20868 rm -f conftest.$ac_objext conftest$ac_exeext
20869 if { (ac_try="$ac_link"
20870 case "(($ac_try" in
20871   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20872   *) ac_try_echo=$ac_try;;
20873 esac
20874 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20875 $as_echo "$ac_try_echo") >&5
20876   (eval "$ac_link") 2>conftest.er1
20877   ac_status=$?
20878   grep -v '^ *+' conftest.er1 >conftest.err
20879   rm -f conftest.er1
20880   cat conftest.err >&5
20881   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20882   (exit $ac_status); } && {
20883          test -z "$ac_c_werror_flag" ||
20884          test ! -s conftest.err
20885        } && test -s conftest$ac_exeext && {
20886          test "$cross_compiling" = yes ||
20887          $as_test_x conftest$ac_exeext
20888        }; then
20889   eval "$as_ac_var=yes"
20890 else
20891   $as_echo "$as_me: failed program was:" >&5
20892 sed 's/^/| /' conftest.$ac_ext >&5
20893
20894         eval "$as_ac_var=no"
20895 fi
20896
20897 rm -rf conftest.dSYM
20898 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20899       conftest$ac_exeext conftest.$ac_ext
20900 fi
20901 ac_res=`eval 'as_val=${'$as_ac_var'}
20902                  $as_echo "$as_val"'`
20903                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20904 $as_echo "$ac_res" >&6; }
20905 as_val=`eval 'as_val=${'$as_ac_var'}
20906                  $as_echo "$as_val"'`
20907    if test "x$as_val" = x""yes; then
20908   cat >>confdefs.h <<_ACEOF
20909 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20910 _ACEOF
20911
20912 else
20913   case " $LIBOBJS " in
20914   *" $ac_func.$ac_objext "* ) ;;
20915   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20916  ;;
20917 esac
20918
20919 fi
20920 done
20921
20922
20923
20924 case $host_os in
20925
20926         # Windows uses a specialised env handler
20927         # and doesn't need a replacement getpeereid because it doesn't use
20928         # Unix sockets.
20929         mingw*)
20930
20931 cat >>confdefs.h <<\_ACEOF
20932 #define HAVE_UNSETENV 1
20933 _ACEOF
20934
20935
20936 cat >>confdefs.h <<\_ACEOF
20937 #define HAVE_GETPEEREID 1
20938 _ACEOF
20939
20940                 ac_cv_func_unsetenv=yes
20941                 ac_cv_func_getpeereid=yes;;
20942         *)
20943
20944
20945 for ac_func in unsetenv getpeereid
20946 do
20947 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20948 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20949 $as_echo_n "checking for $ac_func... " >&6; }
20950 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20951   $as_echo_n "(cached) " >&6
20952 else
20953   cat >conftest.$ac_ext <<_ACEOF
20954 /* confdefs.h.  */
20955 _ACEOF
20956 cat confdefs.h >>conftest.$ac_ext
20957 cat >>conftest.$ac_ext <<_ACEOF
20958 /* end confdefs.h.  */
20959 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20960    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20961 #define $ac_func innocuous_$ac_func
20962
20963 /* System header to define __stub macros and hopefully few prototypes,
20964     which can conflict with char $ac_func (); below.
20965     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20966     <limits.h> exists even on freestanding compilers.  */
20967
20968 #ifdef __STDC__
20969 # include <limits.h>
20970 #else
20971 # include <assert.h>
20972 #endif
20973
20974 #undef $ac_func
20975
20976 /* Override any GCC internal prototype to avoid an error.
20977    Use char because int might match the return type of a GCC
20978    builtin and then its argument prototype would still apply.  */
20979 #ifdef __cplusplus
20980 extern "C"
20981 #endif
20982 char $ac_func ();
20983 /* The GNU C library defines this for functions which it implements
20984     to always fail with ENOSYS.  Some functions are actually named
20985     something starting with __ and the normal name is an alias.  */
20986 #if defined __stub_$ac_func || defined __stub___$ac_func
20987 choke me
20988 #endif
20989
20990 int
20991 main ()
20992 {
20993 return $ac_func ();
20994   ;
20995   return 0;
20996 }
20997 _ACEOF
20998 rm -f conftest.$ac_objext conftest$ac_exeext
20999 if { (ac_try="$ac_link"
21000 case "(($ac_try" in
21001   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21002   *) ac_try_echo=$ac_try;;
21003 esac
21004 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21005 $as_echo "$ac_try_echo") >&5
21006   (eval "$ac_link") 2>conftest.er1
21007   ac_status=$?
21008   grep -v '^ *+' conftest.er1 >conftest.err
21009   rm -f conftest.er1
21010   cat conftest.err >&5
21011   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21012   (exit $ac_status); } && {
21013          test -z "$ac_c_werror_flag" ||
21014          test ! -s conftest.err
21015        } && test -s conftest$ac_exeext && {
21016          test "$cross_compiling" = yes ||
21017          $as_test_x conftest$ac_exeext
21018        }; then
21019   eval "$as_ac_var=yes"
21020 else
21021   $as_echo "$as_me: failed program was:" >&5
21022 sed 's/^/| /' conftest.$ac_ext >&5
21023
21024         eval "$as_ac_var=no"
21025 fi
21026
21027 rm -rf conftest.dSYM
21028 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21029       conftest$ac_exeext conftest.$ac_ext
21030 fi
21031 ac_res=`eval 'as_val=${'$as_ac_var'}
21032                  $as_echo "$as_val"'`
21033                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21034 $as_echo "$ac_res" >&6; }
21035 as_val=`eval 'as_val=${'$as_ac_var'}
21036                  $as_echo "$as_val"'`
21037    if test "x$as_val" = x""yes; then
21038   cat >>confdefs.h <<_ACEOF
21039 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21040 _ACEOF
21041
21042 else
21043   case " $LIBOBJS " in
21044   *" $ac_func.$ac_objext "* ) ;;
21045   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21046  ;;
21047 esac
21048
21049 fi
21050 done
21051
21052
21053                 ;;
21054 esac
21055
21056
21057 LIBS="$pgac_save_LIBS"
21058
21059 # System's version of getaddrinfo(), if any, may be used only if we found
21060 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
21061 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
21062 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
21063 # because we want to use our own getaddrinfo.c on Windows anyway.)
21064 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
21065
21066 for ac_func in getaddrinfo
21067 do
21068 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21069 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21070 $as_echo_n "checking for $ac_func... " >&6; }
21071 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21072   $as_echo_n "(cached) " >&6
21073 else
21074   cat >conftest.$ac_ext <<_ACEOF
21075 /* confdefs.h.  */
21076 _ACEOF
21077 cat confdefs.h >>conftest.$ac_ext
21078 cat >>conftest.$ac_ext <<_ACEOF
21079 /* end confdefs.h.  */
21080 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21081    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21082 #define $ac_func innocuous_$ac_func
21083
21084 /* System header to define __stub macros and hopefully few prototypes,
21085     which can conflict with char $ac_func (); below.
21086     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21087     <limits.h> exists even on freestanding compilers.  */
21088
21089 #ifdef __STDC__
21090 # include <limits.h>
21091 #else
21092 # include <assert.h>
21093 #endif
21094
21095 #undef $ac_func
21096
21097 /* Override any GCC internal prototype to avoid an error.
21098    Use char because int might match the return type of a GCC
21099    builtin and then its argument prototype would still apply.  */
21100 #ifdef __cplusplus
21101 extern "C"
21102 #endif
21103 char $ac_func ();
21104 /* The GNU C library defines this for functions which it implements
21105     to always fail with ENOSYS.  Some functions are actually named
21106     something starting with __ and the normal name is an alias.  */
21107 #if defined __stub_$ac_func || defined __stub___$ac_func
21108 choke me
21109 #endif
21110
21111 int
21112 main ()
21113 {
21114 return $ac_func ();
21115   ;
21116   return 0;
21117 }
21118 _ACEOF
21119 rm -f conftest.$ac_objext conftest$ac_exeext
21120 if { (ac_try="$ac_link"
21121 case "(($ac_try" in
21122   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21123   *) ac_try_echo=$ac_try;;
21124 esac
21125 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21126 $as_echo "$ac_try_echo") >&5
21127   (eval "$ac_link") 2>conftest.er1
21128   ac_status=$?
21129   grep -v '^ *+' conftest.er1 >conftest.err
21130   rm -f conftest.er1
21131   cat conftest.err >&5
21132   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21133   (exit $ac_status); } && {
21134          test -z "$ac_c_werror_flag" ||
21135          test ! -s conftest.err
21136        } && test -s conftest$ac_exeext && {
21137          test "$cross_compiling" = yes ||
21138          $as_test_x conftest$ac_exeext
21139        }; then
21140   eval "$as_ac_var=yes"
21141 else
21142   $as_echo "$as_me: failed program was:" >&5
21143 sed 's/^/| /' conftest.$ac_ext >&5
21144
21145         eval "$as_ac_var=no"
21146 fi
21147
21148 rm -rf conftest.dSYM
21149 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21150       conftest$ac_exeext conftest.$ac_ext
21151 fi
21152 ac_res=`eval 'as_val=${'$as_ac_var'}
21153                  $as_echo "$as_val"'`
21154                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21155 $as_echo "$ac_res" >&6; }
21156 as_val=`eval 'as_val=${'$as_ac_var'}
21157                  $as_echo "$as_val"'`
21158    if test "x$as_val" = x""yes; then
21159   cat >>confdefs.h <<_ACEOF
21160 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21161 _ACEOF
21162
21163 else
21164   case " $LIBOBJS " in
21165   *" $ac_func.$ac_objext "* ) ;;
21166   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21167  ;;
21168 esac
21169
21170 fi
21171 done
21172
21173
21174 else
21175   case " $LIBOBJS " in
21176   *" getaddrinfo.$ac_objext "* ) ;;
21177   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
21178  ;;
21179 esac
21180
21181 fi
21182
21183 # Similarly, use system's getopt_long() only if system provides struct option.
21184 if test x"$ac_cv_type_struct_option" = xyes ; then
21185
21186 for ac_func in getopt_long
21187 do
21188 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21189 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21190 $as_echo_n "checking for $ac_func... " >&6; }
21191 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21192   $as_echo_n "(cached) " >&6
21193 else
21194   cat >conftest.$ac_ext <<_ACEOF
21195 /* confdefs.h.  */
21196 _ACEOF
21197 cat confdefs.h >>conftest.$ac_ext
21198 cat >>conftest.$ac_ext <<_ACEOF
21199 /* end confdefs.h.  */
21200 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21201    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21202 #define $ac_func innocuous_$ac_func
21203
21204 /* System header to define __stub macros and hopefully few prototypes,
21205     which can conflict with char $ac_func (); below.
21206     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21207     <limits.h> exists even on freestanding compilers.  */
21208
21209 #ifdef __STDC__
21210 # include <limits.h>
21211 #else
21212 # include <assert.h>
21213 #endif
21214
21215 #undef $ac_func
21216
21217 /* Override any GCC internal prototype to avoid an error.
21218    Use char because int might match the return type of a GCC
21219    builtin and then its argument prototype would still apply.  */
21220 #ifdef __cplusplus
21221 extern "C"
21222 #endif
21223 char $ac_func ();
21224 /* The GNU C library defines this for functions which it implements
21225     to always fail with ENOSYS.  Some functions are actually named
21226     something starting with __ and the normal name is an alias.  */
21227 #if defined __stub_$ac_func || defined __stub___$ac_func
21228 choke me
21229 #endif
21230
21231 int
21232 main ()
21233 {
21234 return $ac_func ();
21235   ;
21236   return 0;
21237 }
21238 _ACEOF
21239 rm -f conftest.$ac_objext conftest$ac_exeext
21240 if { (ac_try="$ac_link"
21241 case "(($ac_try" in
21242   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21243   *) ac_try_echo=$ac_try;;
21244 esac
21245 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21246 $as_echo "$ac_try_echo") >&5
21247   (eval "$ac_link") 2>conftest.er1
21248   ac_status=$?
21249   grep -v '^ *+' conftest.er1 >conftest.err
21250   rm -f conftest.er1
21251   cat conftest.err >&5
21252   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21253   (exit $ac_status); } && {
21254          test -z "$ac_c_werror_flag" ||
21255          test ! -s conftest.err
21256        } && test -s conftest$ac_exeext && {
21257          test "$cross_compiling" = yes ||
21258          $as_test_x conftest$ac_exeext
21259        }; then
21260   eval "$as_ac_var=yes"
21261 else
21262   $as_echo "$as_me: failed program was:" >&5
21263 sed 's/^/| /' conftest.$ac_ext >&5
21264
21265         eval "$as_ac_var=no"
21266 fi
21267
21268 rm -rf conftest.dSYM
21269 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21270       conftest$ac_exeext conftest.$ac_ext
21271 fi
21272 ac_res=`eval 'as_val=${'$as_ac_var'}
21273                  $as_echo "$as_val"'`
21274                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21275 $as_echo "$ac_res" >&6; }
21276 as_val=`eval 'as_val=${'$as_ac_var'}
21277                  $as_echo "$as_val"'`
21278    if test "x$as_val" = x""yes; then
21279   cat >>confdefs.h <<_ACEOF
21280 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21281 _ACEOF
21282
21283 else
21284   case " $LIBOBJS " in
21285   *" $ac_func.$ac_objext "* ) ;;
21286   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21287  ;;
21288 esac
21289
21290 fi
21291 done
21292
21293
21294 else
21295   case " $LIBOBJS " in
21296   *" getopt_long.$ac_objext "* ) ;;
21297   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
21298  ;;
21299 esac
21300
21301 fi
21302
21303 # Solaris' getopt() doesn't do what we want for long options, so always use
21304 # our version on that platform.
21305 if test "$PORTNAME" = "solaris"; then
21306   case " $LIBOBJS " in
21307   *" getopt.$ac_objext "* ) ;;
21308   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
21309  ;;
21310 esac
21311
21312 fi
21313
21314 # mingw has adopted a GNU-centric interpretation of optind/optreset,
21315 # so always use our version on Windows.
21316 if test "$PORTNAME" = "win32"; then
21317   case " $LIBOBJS " in
21318   *" getopt.$ac_objext "* ) ;;
21319   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
21320  ;;
21321 esac
21322
21323   case " $LIBOBJS " in
21324   *" getopt_long.$ac_objext "* ) ;;
21325   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
21326  ;;
21327 esac
21328
21329 fi
21330
21331 # Win32 support
21332 if test "$PORTNAME" = "win32"; then
21333
21334 for ac_func in gettimeofday
21335 do
21336 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21337 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21338 $as_echo_n "checking for $ac_func... " >&6; }
21339 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21340   $as_echo_n "(cached) " >&6
21341 else
21342   cat >conftest.$ac_ext <<_ACEOF
21343 /* confdefs.h.  */
21344 _ACEOF
21345 cat confdefs.h >>conftest.$ac_ext
21346 cat >>conftest.$ac_ext <<_ACEOF
21347 /* end confdefs.h.  */
21348 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21349    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21350 #define $ac_func innocuous_$ac_func
21351
21352 /* System header to define __stub macros and hopefully few prototypes,
21353     which can conflict with char $ac_func (); below.
21354     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21355     <limits.h> exists even on freestanding compilers.  */
21356
21357 #ifdef __STDC__
21358 # include <limits.h>
21359 #else
21360 # include <assert.h>
21361 #endif
21362
21363 #undef $ac_func
21364
21365 /* Override any GCC internal prototype to avoid an error.
21366    Use char because int might match the return type of a GCC
21367    builtin and then its argument prototype would still apply.  */
21368 #ifdef __cplusplus
21369 extern "C"
21370 #endif
21371 char $ac_func ();
21372 /* The GNU C library defines this for functions which it implements
21373     to always fail with ENOSYS.  Some functions are actually named
21374     something starting with __ and the normal name is an alias.  */
21375 #if defined __stub_$ac_func || defined __stub___$ac_func
21376 choke me
21377 #endif
21378
21379 int
21380 main ()
21381 {
21382 return $ac_func ();
21383   ;
21384   return 0;
21385 }
21386 _ACEOF
21387 rm -f conftest.$ac_objext conftest$ac_exeext
21388 if { (ac_try="$ac_link"
21389 case "(($ac_try" in
21390   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21391   *) ac_try_echo=$ac_try;;
21392 esac
21393 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21394 $as_echo "$ac_try_echo") >&5
21395   (eval "$ac_link") 2>conftest.er1
21396   ac_status=$?
21397   grep -v '^ *+' conftest.er1 >conftest.err
21398   rm -f conftest.er1
21399   cat conftest.err >&5
21400   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21401   (exit $ac_status); } && {
21402          test -z "$ac_c_werror_flag" ||
21403          test ! -s conftest.err
21404        } && test -s conftest$ac_exeext && {
21405          test "$cross_compiling" = yes ||
21406          $as_test_x conftest$ac_exeext
21407        }; then
21408   eval "$as_ac_var=yes"
21409 else
21410   $as_echo "$as_me: failed program was:" >&5
21411 sed 's/^/| /' conftest.$ac_ext >&5
21412
21413         eval "$as_ac_var=no"
21414 fi
21415
21416 rm -rf conftest.dSYM
21417 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21418       conftest$ac_exeext conftest.$ac_ext
21419 fi
21420 ac_res=`eval 'as_val=${'$as_ac_var'}
21421                  $as_echo "$as_val"'`
21422                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21423 $as_echo "$ac_res" >&6; }
21424 as_val=`eval 'as_val=${'$as_ac_var'}
21425                  $as_echo "$as_val"'`
21426    if test "x$as_val" = x""yes; then
21427   cat >>confdefs.h <<_ACEOF
21428 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21429 _ACEOF
21430
21431 else
21432   case " $LIBOBJS " in
21433   *" $ac_func.$ac_objext "* ) ;;
21434   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21435  ;;
21436 esac
21437
21438 fi
21439 done
21440
21441
21442   case " $LIBOBJS " in
21443   *" kill.$ac_objext "* ) ;;
21444   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
21445  ;;
21446 esac
21447
21448   case " $LIBOBJS " in
21449   *" open.$ac_objext "* ) ;;
21450   *) LIBOBJS="$LIBOBJS open.$ac_objext"
21451  ;;
21452 esac
21453
21454   case " $LIBOBJS " in
21455   *" win32env.$ac_objext "* ) ;;
21456   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
21457  ;;
21458 esac
21459
21460   case " $LIBOBJS " in
21461   *" win32error.$ac_objext "* ) ;;
21462   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
21463  ;;
21464 esac
21465
21466   case " $LIBOBJS " in
21467   *" win32setlocale.$ac_objext "* ) ;;
21468   *) LIBOBJS="$LIBOBJS win32setlocale.$ac_objext"
21469  ;;
21470 esac
21471
21472
21473 cat >>confdefs.h <<\_ACEOF
21474 #define HAVE_SYMLINK 1
21475 _ACEOF
21476
21477   { $as_echo "$as_me:$LINENO: checking for MINIDUMP_TYPE" >&5
21478 $as_echo_n "checking for MINIDUMP_TYPE... " >&6; }
21479 if test "${ac_cv_type_MINIDUMP_TYPE+set}" = set; then
21480   $as_echo_n "(cached) " >&6
21481 else
21482   ac_cv_type_MINIDUMP_TYPE=no
21483 cat >conftest.$ac_ext <<_ACEOF
21484 /* confdefs.h.  */
21485 _ACEOF
21486 cat confdefs.h >>conftest.$ac_ext
21487 cat >>conftest.$ac_ext <<_ACEOF
21488 /* end confdefs.h.  */
21489
21490 #define WIN32_LEAN_AND_MEAN
21491 #include <windows.h>
21492 #include <string.h>
21493 #include <dbghelp.h>
21494
21495 int
21496 main ()
21497 {
21498 if (sizeof (MINIDUMP_TYPE))
21499        return 0;
21500   ;
21501   return 0;
21502 }
21503 _ACEOF
21504 rm -f conftest.$ac_objext
21505 if { (ac_try="$ac_compile"
21506 case "(($ac_try" in
21507   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21508   *) ac_try_echo=$ac_try;;
21509 esac
21510 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21511 $as_echo "$ac_try_echo") >&5
21512   (eval "$ac_compile") 2>conftest.er1
21513   ac_status=$?
21514   grep -v '^ *+' conftest.er1 >conftest.err
21515   rm -f conftest.er1
21516   cat conftest.err >&5
21517   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21518   (exit $ac_status); } && {
21519          test -z "$ac_c_werror_flag" ||
21520          test ! -s conftest.err
21521        } && test -s conftest.$ac_objext; then
21522   cat >conftest.$ac_ext <<_ACEOF
21523 /* confdefs.h.  */
21524 _ACEOF
21525 cat confdefs.h >>conftest.$ac_ext
21526 cat >>conftest.$ac_ext <<_ACEOF
21527 /* end confdefs.h.  */
21528
21529 #define WIN32_LEAN_AND_MEAN
21530 #include <windows.h>
21531 #include <string.h>
21532 #include <dbghelp.h>
21533
21534 int
21535 main ()
21536 {
21537 if (sizeof ((MINIDUMP_TYPE)))
21538           return 0;
21539   ;
21540   return 0;
21541 }
21542 _ACEOF
21543 rm -f conftest.$ac_objext
21544 if { (ac_try="$ac_compile"
21545 case "(($ac_try" in
21546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21547   *) ac_try_echo=$ac_try;;
21548 esac
21549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21550 $as_echo "$ac_try_echo") >&5
21551   (eval "$ac_compile") 2>conftest.er1
21552   ac_status=$?
21553   grep -v '^ *+' conftest.er1 >conftest.err
21554   rm -f conftest.er1
21555   cat conftest.err >&5
21556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21557   (exit $ac_status); } && {
21558          test -z "$ac_c_werror_flag" ||
21559          test ! -s conftest.err
21560        } && test -s conftest.$ac_objext; then
21561   :
21562 else
21563   $as_echo "$as_me: failed program was:" >&5
21564 sed 's/^/| /' conftest.$ac_ext >&5
21565
21566         ac_cv_type_MINIDUMP_TYPE=yes
21567 fi
21568
21569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21570 else
21571   $as_echo "$as_me: failed program was:" >&5
21572 sed 's/^/| /' conftest.$ac_ext >&5
21573
21574
21575 fi
21576
21577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21578 fi
21579 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_MINIDUMP_TYPE" >&5
21580 $as_echo "$ac_cv_type_MINIDUMP_TYPE" >&6; }
21581 if test "x$ac_cv_type_MINIDUMP_TYPE" = x""yes; then
21582
21583 cat >>confdefs.h <<_ACEOF
21584 #define HAVE_MINIDUMP_TYPE 1
21585 _ACEOF
21586
21587 pgac_minidump_type=yes
21588 else
21589   pgac_minidump_type=no
21590 fi
21591
21592 fi
21593 if test x"$pgac_minidump_type" = x"yes" ; then
21594   have_win32_dbghelp=yes
21595
21596 else
21597   have_win32_dbghelp=no
21598
21599 fi
21600
21601 if test "$with_readline" = yes; then
21602   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
21603 $as_echo_n "checking for rl_completion_append_character... " >&6; }
21604 if test "${pgac_cv_var_rl_completion_append_character+set}" = set; then
21605   $as_echo_n "(cached) " >&6
21606 else
21607   cat >conftest.$ac_ext <<_ACEOF
21608 /* confdefs.h.  */
21609 _ACEOF
21610 cat confdefs.h >>conftest.$ac_ext
21611 cat >>conftest.$ac_ext <<_ACEOF
21612 /* end confdefs.h.  */
21613 #include <stdio.h>
21614 #ifdef HAVE_READLINE_READLINE_H
21615 # include <readline/readline.h>
21616 #elif defined(HAVE_READLINE_H)
21617 # include <readline.h>
21618 #endif
21619
21620 int
21621 main ()
21622 {
21623 rl_completion_append_character = 'x';
21624   ;
21625   return 0;
21626 }
21627 _ACEOF
21628 rm -f conftest.$ac_objext conftest$ac_exeext
21629 if { (ac_try="$ac_link"
21630 case "(($ac_try" in
21631   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21632   *) ac_try_echo=$ac_try;;
21633 esac
21634 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21635 $as_echo "$ac_try_echo") >&5
21636   (eval "$ac_link") 2>conftest.er1
21637   ac_status=$?
21638   grep -v '^ *+' conftest.er1 >conftest.err
21639   rm -f conftest.er1
21640   cat conftest.err >&5
21641   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21642   (exit $ac_status); } && {
21643          test -z "$ac_c_werror_flag" ||
21644          test ! -s conftest.err
21645        } && test -s conftest$ac_exeext && {
21646          test "$cross_compiling" = yes ||
21647          $as_test_x conftest$ac_exeext
21648        }; then
21649   pgac_cv_var_rl_completion_append_character=yes
21650 else
21651   $as_echo "$as_me: failed program was:" >&5
21652 sed 's/^/| /' conftest.$ac_ext >&5
21653
21654         pgac_cv_var_rl_completion_append_character=no
21655 fi
21656
21657 rm -rf conftest.dSYM
21658 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21659       conftest$ac_exeext conftest.$ac_ext
21660 fi
21661 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_rl_completion_append_character" >&5
21662 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
21663 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
21664
21665 cat >>confdefs.h <<\_ACEOF
21666 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
21667 _ACEOF
21668
21669 fi
21670
21671
21672 for ac_func in rl_completion_matches rl_filename_completion_function
21673 do
21674 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21675 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21676 $as_echo_n "checking for $ac_func... " >&6; }
21677 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21678   $as_echo_n "(cached) " >&6
21679 else
21680   cat >conftest.$ac_ext <<_ACEOF
21681 /* confdefs.h.  */
21682 _ACEOF
21683 cat confdefs.h >>conftest.$ac_ext
21684 cat >>conftest.$ac_ext <<_ACEOF
21685 /* end confdefs.h.  */
21686 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21687    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21688 #define $ac_func innocuous_$ac_func
21689
21690 /* System header to define __stub macros and hopefully few prototypes,
21691     which can conflict with char $ac_func (); below.
21692     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21693     <limits.h> exists even on freestanding compilers.  */
21694
21695 #ifdef __STDC__
21696 # include <limits.h>
21697 #else
21698 # include <assert.h>
21699 #endif
21700
21701 #undef $ac_func
21702
21703 /* Override any GCC internal prototype to avoid an error.
21704    Use char because int might match the return type of a GCC
21705    builtin and then its argument prototype would still apply.  */
21706 #ifdef __cplusplus
21707 extern "C"
21708 #endif
21709 char $ac_func ();
21710 /* The GNU C library defines this for functions which it implements
21711     to always fail with ENOSYS.  Some functions are actually named
21712     something starting with __ and the normal name is an alias.  */
21713 #if defined __stub_$ac_func || defined __stub___$ac_func
21714 choke me
21715 #endif
21716
21717 int
21718 main ()
21719 {
21720 return $ac_func ();
21721   ;
21722   return 0;
21723 }
21724 _ACEOF
21725 rm -f conftest.$ac_objext conftest$ac_exeext
21726 if { (ac_try="$ac_link"
21727 case "(($ac_try" in
21728   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21729   *) ac_try_echo=$ac_try;;
21730 esac
21731 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21732 $as_echo "$ac_try_echo") >&5
21733   (eval "$ac_link") 2>conftest.er1
21734   ac_status=$?
21735   grep -v '^ *+' conftest.er1 >conftest.err
21736   rm -f conftest.er1
21737   cat conftest.err >&5
21738   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21739   (exit $ac_status); } && {
21740          test -z "$ac_c_werror_flag" ||
21741          test ! -s conftest.err
21742        } && test -s conftest$ac_exeext && {
21743          test "$cross_compiling" = yes ||
21744          $as_test_x conftest$ac_exeext
21745        }; then
21746   eval "$as_ac_var=yes"
21747 else
21748   $as_echo "$as_me: failed program was:" >&5
21749 sed 's/^/| /' conftest.$ac_ext >&5
21750
21751         eval "$as_ac_var=no"
21752 fi
21753
21754 rm -rf conftest.dSYM
21755 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21756       conftest$ac_exeext conftest.$ac_ext
21757 fi
21758 ac_res=`eval 'as_val=${'$as_ac_var'}
21759                  $as_echo "$as_val"'`
21760                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21761 $as_echo "$ac_res" >&6; }
21762 as_val=`eval 'as_val=${'$as_ac_var'}
21763                  $as_echo "$as_val"'`
21764    if test "x$as_val" = x""yes; then
21765   cat >>confdefs.h <<_ACEOF
21766 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21767 _ACEOF
21768
21769 fi
21770 done
21771
21772
21773
21774 for ac_func in append_history history_truncate_file
21775 do
21776 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21777 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21778 $as_echo_n "checking for $ac_func... " >&6; }
21779 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21780   $as_echo_n "(cached) " >&6
21781 else
21782   cat >conftest.$ac_ext <<_ACEOF
21783 /* confdefs.h.  */
21784 _ACEOF
21785 cat confdefs.h >>conftest.$ac_ext
21786 cat >>conftest.$ac_ext <<_ACEOF
21787 /* end confdefs.h.  */
21788 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21789    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21790 #define $ac_func innocuous_$ac_func
21791
21792 /* System header to define __stub macros and hopefully few prototypes,
21793     which can conflict with char $ac_func (); below.
21794     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21795     <limits.h> exists even on freestanding compilers.  */
21796
21797 #ifdef __STDC__
21798 # include <limits.h>
21799 #else
21800 # include <assert.h>
21801 #endif
21802
21803 #undef $ac_func
21804
21805 /* Override any GCC internal prototype to avoid an error.
21806    Use char because int might match the return type of a GCC
21807    builtin and then its argument prototype would still apply.  */
21808 #ifdef __cplusplus
21809 extern "C"
21810 #endif
21811 char $ac_func ();
21812 /* The GNU C library defines this for functions which it implements
21813     to always fail with ENOSYS.  Some functions are actually named
21814     something starting with __ and the normal name is an alias.  */
21815 #if defined __stub_$ac_func || defined __stub___$ac_func
21816 choke me
21817 #endif
21818
21819 int
21820 main ()
21821 {
21822 return $ac_func ();
21823   ;
21824   return 0;
21825 }
21826 _ACEOF
21827 rm -f conftest.$ac_objext conftest$ac_exeext
21828 if { (ac_try="$ac_link"
21829 case "(($ac_try" in
21830   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21831   *) ac_try_echo=$ac_try;;
21832 esac
21833 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21834 $as_echo "$ac_try_echo") >&5
21835   (eval "$ac_link") 2>conftest.er1
21836   ac_status=$?
21837   grep -v '^ *+' conftest.er1 >conftest.err
21838   rm -f conftest.er1
21839   cat conftest.err >&5
21840   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21841   (exit $ac_status); } && {
21842          test -z "$ac_c_werror_flag" ||
21843          test ! -s conftest.err
21844        } && test -s conftest$ac_exeext && {
21845          test "$cross_compiling" = yes ||
21846          $as_test_x conftest$ac_exeext
21847        }; then
21848   eval "$as_ac_var=yes"
21849 else
21850   $as_echo "$as_me: failed program was:" >&5
21851 sed 's/^/| /' conftest.$ac_ext >&5
21852
21853         eval "$as_ac_var=no"
21854 fi
21855
21856 rm -rf conftest.dSYM
21857 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21858       conftest$ac_exeext conftest.$ac_ext
21859 fi
21860 ac_res=`eval 'as_val=${'$as_ac_var'}
21861                  $as_echo "$as_val"'`
21862                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21863 $as_echo "$ac_res" >&6; }
21864 as_val=`eval 'as_val=${'$as_ac_var'}
21865                  $as_echo "$as_val"'`
21866    if test "x$as_val" = x""yes; then
21867   cat >>confdefs.h <<_ACEOF
21868 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21869 _ACEOF
21870
21871 fi
21872 done
21873
21874 fi
21875
21876
21877 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
21878 $as_echo_n "checking for sigsetjmp... " >&6; }
21879 if test "${pgac_cv_func_sigsetjmp+set}" = set; then
21880   $as_echo_n "(cached) " >&6
21881 else
21882   cat >conftest.$ac_ext <<_ACEOF
21883 /* confdefs.h.  */
21884 _ACEOF
21885 cat confdefs.h >>conftest.$ac_ext
21886 cat >>conftest.$ac_ext <<_ACEOF
21887 /* end confdefs.h.  */
21888 #include <setjmp.h>
21889 int
21890 main ()
21891 {
21892 sigjmp_buf x; sigsetjmp(x, 1);
21893   ;
21894   return 0;
21895 }
21896 _ACEOF
21897 rm -f conftest.$ac_objext conftest$ac_exeext
21898 if { (ac_try="$ac_link"
21899 case "(($ac_try" in
21900   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21901   *) ac_try_echo=$ac_try;;
21902 esac
21903 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21904 $as_echo "$ac_try_echo") >&5
21905   (eval "$ac_link") 2>conftest.er1
21906   ac_status=$?
21907   grep -v '^ *+' conftest.er1 >conftest.err
21908   rm -f conftest.er1
21909   cat conftest.err >&5
21910   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21911   (exit $ac_status); } && {
21912          test -z "$ac_c_werror_flag" ||
21913          test ! -s conftest.err
21914        } && test -s conftest$ac_exeext && {
21915          test "$cross_compiling" = yes ||
21916          $as_test_x conftest$ac_exeext
21917        }; then
21918   pgac_cv_func_sigsetjmp=yes
21919 else
21920   $as_echo "$as_me: failed program was:" >&5
21921 sed 's/^/| /' conftest.$ac_ext >&5
21922
21923         pgac_cv_func_sigsetjmp=no
21924 fi
21925
21926 rm -rf conftest.dSYM
21927 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21928       conftest$ac_exeext conftest.$ac_ext
21929 fi
21930 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_sigsetjmp" >&5
21931 $as_echo "$pgac_cv_func_sigsetjmp" >&6; }
21932 if test x"$pgac_cv_func_sigsetjmp" = x"yes"; then
21933
21934 cat >>confdefs.h <<\_ACEOF
21935 #define HAVE_SIGSETJMP 1
21936 _ACEOF
21937
21938 fi
21939
21940 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
21941 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
21942 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
21943   $as_echo_n "(cached) " >&6
21944 else
21945   cat >conftest.$ac_ext <<_ACEOF
21946 /* confdefs.h.  */
21947 _ACEOF
21948 cat confdefs.h >>conftest.$ac_ext
21949 cat >>conftest.$ac_ext <<_ACEOF
21950 /* end confdefs.h.  */
21951 #include <signal.h>
21952 /* NetBSD declares sys_siglist in unistd.h.  */
21953 #ifdef HAVE_UNISTD_H
21954 # include <unistd.h>
21955 #endif
21956
21957
21958 int
21959 main ()
21960 {
21961 #ifndef sys_siglist
21962   (void) sys_siglist;
21963 #endif
21964
21965   ;
21966   return 0;
21967 }
21968 _ACEOF
21969 rm -f conftest.$ac_objext
21970 if { (ac_try="$ac_compile"
21971 case "(($ac_try" in
21972   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21973   *) ac_try_echo=$ac_try;;
21974 esac
21975 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21976 $as_echo "$ac_try_echo") >&5
21977   (eval "$ac_compile") 2>conftest.er1
21978   ac_status=$?
21979   grep -v '^ *+' conftest.er1 >conftest.err
21980   rm -f conftest.er1
21981   cat conftest.err >&5
21982   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21983   (exit $ac_status); } && {
21984          test -z "$ac_c_werror_flag" ||
21985          test ! -s conftest.err
21986        } && test -s conftest.$ac_objext; then
21987   ac_cv_have_decl_sys_siglist=yes
21988 else
21989   $as_echo "$as_me: failed program was:" >&5
21990 sed 's/^/| /' conftest.$ac_ext >&5
21991
21992         ac_cv_have_decl_sys_siglist=no
21993 fi
21994
21995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21996 fi
21997 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
21998 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
21999 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
22000
22001 cat >>confdefs.h <<_ACEOF
22002 #define HAVE_DECL_SYS_SIGLIST 1
22003 _ACEOF
22004
22005
22006 else
22007   cat >>confdefs.h <<_ACEOF
22008 #define HAVE_DECL_SYS_SIGLIST 0
22009 _ACEOF
22010
22011
22012 fi
22013
22014
22015
22016
22017 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
22018 $as_echo_n "checking for syslog... " >&6; }
22019 if test "${ac_cv_func_syslog+set}" = set; then
22020   $as_echo_n "(cached) " >&6
22021 else
22022   cat >conftest.$ac_ext <<_ACEOF
22023 /* confdefs.h.  */
22024 _ACEOF
22025 cat confdefs.h >>conftest.$ac_ext
22026 cat >>conftest.$ac_ext <<_ACEOF
22027 /* end confdefs.h.  */
22028 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
22029    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22030 #define syslog innocuous_syslog
22031
22032 /* System header to define __stub macros and hopefully few prototypes,
22033     which can conflict with char syslog (); below.
22034     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22035     <limits.h> exists even on freestanding compilers.  */
22036
22037 #ifdef __STDC__
22038 # include <limits.h>
22039 #else
22040 # include <assert.h>
22041 #endif
22042
22043 #undef syslog
22044
22045 /* Override any GCC internal prototype to avoid an error.
22046    Use char because int might match the return type of a GCC
22047    builtin and then its argument prototype would still apply.  */
22048 #ifdef __cplusplus
22049 extern "C"
22050 #endif
22051 char syslog ();
22052 /* The GNU C library defines this for functions which it implements
22053     to always fail with ENOSYS.  Some functions are actually named
22054     something starting with __ and the normal name is an alias.  */
22055 #if defined __stub_syslog || defined __stub___syslog
22056 choke me
22057 #endif
22058
22059 int
22060 main ()
22061 {
22062 return syslog ();
22063   ;
22064   return 0;
22065 }
22066 _ACEOF
22067 rm -f conftest.$ac_objext conftest$ac_exeext
22068 if { (ac_try="$ac_link"
22069 case "(($ac_try" in
22070   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22071   *) ac_try_echo=$ac_try;;
22072 esac
22073 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22074 $as_echo "$ac_try_echo") >&5
22075   (eval "$ac_link") 2>conftest.er1
22076   ac_status=$?
22077   grep -v '^ *+' conftest.er1 >conftest.err
22078   rm -f conftest.er1
22079   cat conftest.err >&5
22080   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22081   (exit $ac_status); } && {
22082          test -z "$ac_c_werror_flag" ||
22083          test ! -s conftest.err
22084        } && test -s conftest$ac_exeext && {
22085          test "$cross_compiling" = yes ||
22086          $as_test_x conftest$ac_exeext
22087        }; then
22088   ac_cv_func_syslog=yes
22089 else
22090   $as_echo "$as_me: failed program was:" >&5
22091 sed 's/^/| /' conftest.$ac_ext >&5
22092
22093         ac_cv_func_syslog=no
22094 fi
22095
22096 rm -rf conftest.dSYM
22097 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22098       conftest$ac_exeext conftest.$ac_ext
22099 fi
22100 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
22101 $as_echo "$ac_cv_func_syslog" >&6; }
22102 if test "x$ac_cv_func_syslog" = x""yes; then
22103   if test "${ac_cv_header_syslog_h+set}" = set; then
22104   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
22105 $as_echo_n "checking for syslog.h... " >&6; }
22106 if test "${ac_cv_header_syslog_h+set}" = set; then
22107   $as_echo_n "(cached) " >&6
22108 fi
22109 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
22110 $as_echo "$ac_cv_header_syslog_h" >&6; }
22111 else
22112   # Is the header compilable?
22113 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
22114 $as_echo_n "checking syslog.h usability... " >&6; }
22115 cat >conftest.$ac_ext <<_ACEOF
22116 /* confdefs.h.  */
22117 _ACEOF
22118 cat confdefs.h >>conftest.$ac_ext
22119 cat >>conftest.$ac_ext <<_ACEOF
22120 /* end confdefs.h.  */
22121 $ac_includes_default
22122 #include <syslog.h>
22123 _ACEOF
22124 rm -f conftest.$ac_objext
22125 if { (ac_try="$ac_compile"
22126 case "(($ac_try" in
22127   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22128   *) ac_try_echo=$ac_try;;
22129 esac
22130 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22131 $as_echo "$ac_try_echo") >&5
22132   (eval "$ac_compile") 2>conftest.er1
22133   ac_status=$?
22134   grep -v '^ *+' conftest.er1 >conftest.err
22135   rm -f conftest.er1
22136   cat conftest.err >&5
22137   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22138   (exit $ac_status); } && {
22139          test -z "$ac_c_werror_flag" ||
22140          test ! -s conftest.err
22141        } && test -s conftest.$ac_objext; then
22142   ac_header_compiler=yes
22143 else
22144   $as_echo "$as_me: failed program was:" >&5
22145 sed 's/^/| /' conftest.$ac_ext >&5
22146
22147         ac_header_compiler=no
22148 fi
22149
22150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22151 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22152 $as_echo "$ac_header_compiler" >&6; }
22153
22154 # Is the header present?
22155 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
22156 $as_echo_n "checking syslog.h presence... " >&6; }
22157 cat >conftest.$ac_ext <<_ACEOF
22158 /* confdefs.h.  */
22159 _ACEOF
22160 cat confdefs.h >>conftest.$ac_ext
22161 cat >>conftest.$ac_ext <<_ACEOF
22162 /* end confdefs.h.  */
22163 #include <syslog.h>
22164 _ACEOF
22165 if { (ac_try="$ac_cpp conftest.$ac_ext"
22166 case "(($ac_try" in
22167   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22168   *) ac_try_echo=$ac_try;;
22169 esac
22170 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22171 $as_echo "$ac_try_echo") >&5
22172   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
22173   ac_status=$?
22174   grep -v '^ *+' conftest.er1 >conftest.err
22175   rm -f conftest.er1
22176   cat conftest.err >&5
22177   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22178   (exit $ac_status); } >/dev/null && {
22179          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22180          test ! -s conftest.err
22181        }; then
22182   ac_header_preproc=yes
22183 else
22184   $as_echo "$as_me: failed program was:" >&5
22185 sed 's/^/| /' conftest.$ac_ext >&5
22186
22187   ac_header_preproc=no
22188 fi
22189
22190 rm -f conftest.err conftest.$ac_ext
22191 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22192 $as_echo "$ac_header_preproc" >&6; }
22193
22194 # So?  What about this header?
22195 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22196   yes:no: )
22197     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
22198 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22199     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
22200 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
22201     ac_header_preproc=yes
22202     ;;
22203   no:yes:* )
22204     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
22205 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
22206     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
22207 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
22208     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
22209 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
22210     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
22211 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22212     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
22213 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
22214     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
22215 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
22216     ( cat <<\_ASBOX
22217 ## ---------------------------------------- ##
22218 ## Report this to pgsql-bugs@postgresql.org ##
22219 ## ---------------------------------------- ##
22220 _ASBOX
22221      ) | sed "s/^/$as_me: WARNING:     /" >&2
22222     ;;
22223 esac
22224 { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
22225 $as_echo_n "checking for syslog.h... " >&6; }
22226 if test "${ac_cv_header_syslog_h+set}" = set; then
22227   $as_echo_n "(cached) " >&6
22228 else
22229   ac_cv_header_syslog_h=$ac_header_preproc
22230 fi
22231 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
22232 $as_echo "$ac_cv_header_syslog_h" >&6; }
22233
22234 fi
22235 if test "x$ac_cv_header_syslog_h" = x""yes; then
22236
22237 cat >>confdefs.h <<\_ACEOF
22238 #define HAVE_SYSLOG 1
22239 _ACEOF
22240
22241 fi
22242
22243
22244 fi
22245
22246
22247 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
22248 $as_echo_n "checking for opterr... " >&6; }
22249 if test "${pgac_cv_var_int_opterr+set}" = set; then
22250   $as_echo_n "(cached) " >&6
22251 else
22252   cat >conftest.$ac_ext <<_ACEOF
22253 /* confdefs.h.  */
22254 _ACEOF
22255 cat confdefs.h >>conftest.$ac_ext
22256 cat >>conftest.$ac_ext <<_ACEOF
22257 /* end confdefs.h.  */
22258 #include <unistd.h>
22259 int
22260 main ()
22261 {
22262 extern int opterr; opterr = 1;
22263   ;
22264   return 0;
22265 }
22266 _ACEOF
22267 rm -f conftest.$ac_objext conftest$ac_exeext
22268 if { (ac_try="$ac_link"
22269 case "(($ac_try" in
22270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22271   *) ac_try_echo=$ac_try;;
22272 esac
22273 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22274 $as_echo "$ac_try_echo") >&5
22275   (eval "$ac_link") 2>conftest.er1
22276   ac_status=$?
22277   grep -v '^ *+' conftest.er1 >conftest.err
22278   rm -f conftest.er1
22279   cat conftest.err >&5
22280   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22281   (exit $ac_status); } && {
22282          test -z "$ac_c_werror_flag" ||
22283          test ! -s conftest.err
22284        } && test -s conftest$ac_exeext && {
22285          test "$cross_compiling" = yes ||
22286          $as_test_x conftest$ac_exeext
22287        }; then
22288   pgac_cv_var_int_opterr=yes
22289 else
22290   $as_echo "$as_me: failed program was:" >&5
22291 sed 's/^/| /' conftest.$ac_ext >&5
22292
22293         pgac_cv_var_int_opterr=no
22294 fi
22295
22296 rm -rf conftest.dSYM
22297 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22298       conftest$ac_exeext conftest.$ac_ext
22299 fi
22300 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
22301 $as_echo "$pgac_cv_var_int_opterr" >&6; }
22302 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
22303
22304 cat >>confdefs.h <<\_ACEOF
22305 #define HAVE_INT_OPTERR 1
22306 _ACEOF
22307
22308 fi
22309
22310 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
22311 $as_echo_n "checking for optreset... " >&6; }
22312 if test "${pgac_cv_var_int_optreset+set}" = set; then
22313   $as_echo_n "(cached) " >&6
22314 else
22315   cat >conftest.$ac_ext <<_ACEOF
22316 /* confdefs.h.  */
22317 _ACEOF
22318 cat confdefs.h >>conftest.$ac_ext
22319 cat >>conftest.$ac_ext <<_ACEOF
22320 /* end confdefs.h.  */
22321 #include <unistd.h>
22322 int
22323 main ()
22324 {
22325 extern int optreset; optreset = 1;
22326   ;
22327   return 0;
22328 }
22329 _ACEOF
22330 rm -f conftest.$ac_objext conftest$ac_exeext
22331 if { (ac_try="$ac_link"
22332 case "(($ac_try" in
22333   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22334   *) ac_try_echo=$ac_try;;
22335 esac
22336 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22337 $as_echo "$ac_try_echo") >&5
22338   (eval "$ac_link") 2>conftest.er1
22339   ac_status=$?
22340   grep -v '^ *+' conftest.er1 >conftest.err
22341   rm -f conftest.er1
22342   cat conftest.err >&5
22343   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22344   (exit $ac_status); } && {
22345          test -z "$ac_c_werror_flag" ||
22346          test ! -s conftest.err
22347        } && test -s conftest$ac_exeext && {
22348          test "$cross_compiling" = yes ||
22349          $as_test_x conftest$ac_exeext
22350        }; then
22351   pgac_cv_var_int_optreset=yes
22352 else
22353   $as_echo "$as_me: failed program was:" >&5
22354 sed 's/^/| /' conftest.$ac_ext >&5
22355
22356         pgac_cv_var_int_optreset=no
22357 fi
22358
22359 rm -rf conftest.dSYM
22360 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22361       conftest$ac_exeext conftest.$ac_ext
22362 fi
22363 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
22364 $as_echo "$pgac_cv_var_int_optreset" >&6; }
22365 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
22366
22367 cat >>confdefs.h <<\_ACEOF
22368 #define HAVE_INT_OPTRESET 1
22369 _ACEOF
22370
22371 fi
22372
22373
22374
22375 for ac_func in strtoll strtoq
22376 do
22377 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22378 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22379 $as_echo_n "checking for $ac_func... " >&6; }
22380 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22381   $as_echo_n "(cached) " >&6
22382 else
22383   cat >conftest.$ac_ext <<_ACEOF
22384 /* confdefs.h.  */
22385 _ACEOF
22386 cat confdefs.h >>conftest.$ac_ext
22387 cat >>conftest.$ac_ext <<_ACEOF
22388 /* end confdefs.h.  */
22389 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22390    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22391 #define $ac_func innocuous_$ac_func
22392
22393 /* System header to define __stub macros and hopefully few prototypes,
22394     which can conflict with char $ac_func (); below.
22395     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22396     <limits.h> exists even on freestanding compilers.  */
22397
22398 #ifdef __STDC__
22399 # include <limits.h>
22400 #else
22401 # include <assert.h>
22402 #endif
22403
22404 #undef $ac_func
22405
22406 /* Override any GCC internal prototype to avoid an error.
22407    Use char because int might match the return type of a GCC
22408    builtin and then its argument prototype would still apply.  */
22409 #ifdef __cplusplus
22410 extern "C"
22411 #endif
22412 char $ac_func ();
22413 /* The GNU C library defines this for functions which it implements
22414     to always fail with ENOSYS.  Some functions are actually named
22415     something starting with __ and the normal name is an alias.  */
22416 #if defined __stub_$ac_func || defined __stub___$ac_func
22417 choke me
22418 #endif
22419
22420 int
22421 main ()
22422 {
22423 return $ac_func ();
22424   ;
22425   return 0;
22426 }
22427 _ACEOF
22428 rm -f conftest.$ac_objext conftest$ac_exeext
22429 if { (ac_try="$ac_link"
22430 case "(($ac_try" in
22431   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22432   *) ac_try_echo=$ac_try;;
22433 esac
22434 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22435 $as_echo "$ac_try_echo") >&5
22436   (eval "$ac_link") 2>conftest.er1
22437   ac_status=$?
22438   grep -v '^ *+' conftest.er1 >conftest.err
22439   rm -f conftest.er1
22440   cat conftest.err >&5
22441   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22442   (exit $ac_status); } && {
22443          test -z "$ac_c_werror_flag" ||
22444          test ! -s conftest.err
22445        } && test -s conftest$ac_exeext && {
22446          test "$cross_compiling" = yes ||
22447          $as_test_x conftest$ac_exeext
22448        }; then
22449   eval "$as_ac_var=yes"
22450 else
22451   $as_echo "$as_me: failed program was:" >&5
22452 sed 's/^/| /' conftest.$ac_ext >&5
22453
22454         eval "$as_ac_var=no"
22455 fi
22456
22457 rm -rf conftest.dSYM
22458 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22459       conftest$ac_exeext conftest.$ac_ext
22460 fi
22461 ac_res=`eval 'as_val=${'$as_ac_var'}
22462                  $as_echo "$as_val"'`
22463                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22464 $as_echo "$ac_res" >&6; }
22465 as_val=`eval 'as_val=${'$as_ac_var'}
22466                  $as_echo "$as_val"'`
22467    if test "x$as_val" = x""yes; then
22468   cat >>confdefs.h <<_ACEOF
22469 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22470 _ACEOF
22471  break
22472 fi
22473 done
22474
22475
22476
22477 for ac_func in strtoull strtouq
22478 do
22479 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22480 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22481 $as_echo_n "checking for $ac_func... " >&6; }
22482 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22483   $as_echo_n "(cached) " >&6
22484 else
22485   cat >conftest.$ac_ext <<_ACEOF
22486 /* confdefs.h.  */
22487 _ACEOF
22488 cat confdefs.h >>conftest.$ac_ext
22489 cat >>conftest.$ac_ext <<_ACEOF
22490 /* end confdefs.h.  */
22491 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22492    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22493 #define $ac_func innocuous_$ac_func
22494
22495 /* System header to define __stub macros and hopefully few prototypes,
22496     which can conflict with char $ac_func (); below.
22497     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22498     <limits.h> exists even on freestanding compilers.  */
22499
22500 #ifdef __STDC__
22501 # include <limits.h>
22502 #else
22503 # include <assert.h>
22504 #endif
22505
22506 #undef $ac_func
22507
22508 /* Override any GCC internal prototype to avoid an error.
22509    Use char because int might match the return type of a GCC
22510    builtin and then its argument prototype would still apply.  */
22511 #ifdef __cplusplus
22512 extern "C"
22513 #endif
22514 char $ac_func ();
22515 /* The GNU C library defines this for functions which it implements
22516     to always fail with ENOSYS.  Some functions are actually named
22517     something starting with __ and the normal name is an alias.  */
22518 #if defined __stub_$ac_func || defined __stub___$ac_func
22519 choke me
22520 #endif
22521
22522 int
22523 main ()
22524 {
22525 return $ac_func ();
22526   ;
22527   return 0;
22528 }
22529 _ACEOF
22530 rm -f conftest.$ac_objext conftest$ac_exeext
22531 if { (ac_try="$ac_link"
22532 case "(($ac_try" in
22533   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22534   *) ac_try_echo=$ac_try;;
22535 esac
22536 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22537 $as_echo "$ac_try_echo") >&5
22538   (eval "$ac_link") 2>conftest.er1
22539   ac_status=$?
22540   grep -v '^ *+' conftest.er1 >conftest.err
22541   rm -f conftest.er1
22542   cat conftest.err >&5
22543   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22544   (exit $ac_status); } && {
22545          test -z "$ac_c_werror_flag" ||
22546          test ! -s conftest.err
22547        } && test -s conftest$ac_exeext && {
22548          test "$cross_compiling" = yes ||
22549          $as_test_x conftest$ac_exeext
22550        }; then
22551   eval "$as_ac_var=yes"
22552 else
22553   $as_echo "$as_me: failed program was:" >&5
22554 sed 's/^/| /' conftest.$ac_ext >&5
22555
22556         eval "$as_ac_var=no"
22557 fi
22558
22559 rm -rf conftest.dSYM
22560 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22561       conftest$ac_exeext conftest.$ac_ext
22562 fi
22563 ac_res=`eval 'as_val=${'$as_ac_var'}
22564                  $as_echo "$as_val"'`
22565                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22566 $as_echo "$ac_res" >&6; }
22567 as_val=`eval 'as_val=${'$as_ac_var'}
22568                  $as_echo "$as_val"'`
22569    if test "x$as_val" = x""yes; then
22570   cat >>confdefs.h <<_ACEOF
22571 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22572 _ACEOF
22573  break
22574 fi
22575 done
22576
22577
22578 { $as_echo "$as_me:$LINENO: checking for builtin locking functions" >&5
22579 $as_echo_n "checking for builtin locking functions... " >&6; }
22580 if test "${pgac_cv_gcc_int_atomics+set}" = set; then
22581   $as_echo_n "(cached) " >&6
22582 else
22583   cat >conftest.$ac_ext <<_ACEOF
22584 /* confdefs.h.  */
22585 _ACEOF
22586 cat confdefs.h >>conftest.$ac_ext
22587 cat >>conftest.$ac_ext <<_ACEOF
22588 /* end confdefs.h.  */
22589
22590 int
22591 main ()
22592 {
22593 int lock = 0;
22594    __sync_lock_test_and_set(&lock, 1);
22595    __sync_lock_release(&lock);
22596   ;
22597   return 0;
22598 }
22599 _ACEOF
22600 rm -f conftest.$ac_objext conftest$ac_exeext
22601 if { (ac_try="$ac_link"
22602 case "(($ac_try" in
22603   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22604   *) ac_try_echo=$ac_try;;
22605 esac
22606 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22607 $as_echo "$ac_try_echo") >&5
22608   (eval "$ac_link") 2>conftest.er1
22609   ac_status=$?
22610   grep -v '^ *+' conftest.er1 >conftest.err
22611   rm -f conftest.er1
22612   cat conftest.err >&5
22613   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22614   (exit $ac_status); } && {
22615          test -z "$ac_c_werror_flag" ||
22616          test ! -s conftest.err
22617        } && test -s conftest$ac_exeext && {
22618          test "$cross_compiling" = yes ||
22619          $as_test_x conftest$ac_exeext
22620        }; then
22621   pgac_cv_gcc_int_atomics="yes"
22622 else
22623   $as_echo "$as_me: failed program was:" >&5
22624 sed 's/^/| /' conftest.$ac_ext >&5
22625
22626         pgac_cv_gcc_int_atomics="no"
22627 fi
22628
22629 rm -rf conftest.dSYM
22630 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22631       conftest$ac_exeext conftest.$ac_ext
22632 fi
22633 { $as_echo "$as_me:$LINENO: result: $pgac_cv_gcc_int_atomics" >&5
22634 $as_echo "$pgac_cv_gcc_int_atomics" >&6; }
22635 if test x"$pgac_cv_gcc_int_atomics" = x"yes"; then
22636
22637 cat >>confdefs.h <<\_ACEOF
22638 #define HAVE_GCC_INT_ATOMICS 1
22639 _ACEOF
22640
22641 fi
22642
22643
22644 #
22645 # Pthreads
22646 #
22647 # For each platform, we need to know about any special compile and link
22648 # libraries, and whether the normal C function names are thread-safe.
22649 # See the comment at the top of src/port/thread.c for more information.
22650 # WIN32 doesn't need the pthread tests;  it always uses threads
22651 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
22652
22653
22654
22655 ac_ext=c
22656 ac_cpp='$CPP $CPPFLAGS'
22657 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22658 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22659 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22660
22661 acx_pthread_ok=no
22662
22663 # We used to check for pthread.h first, but this fails if pthread.h
22664 # requires special compiler flags (e.g. on True64 or Sequent).
22665 # It gets checked for in the link test anyway.
22666
22667 # First of all, check if the user has set any of the PTHREAD_LIBS,
22668 # etcetera environment variables, and if threads linking works using
22669 # them:
22670 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
22671         save_CFLAGS="$CFLAGS"
22672         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22673         save_LIBS="$LIBS"
22674         LIBS="$PTHREAD_LIBS $LIBS"
22675         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
22676 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
22677         cat >conftest.$ac_ext <<_ACEOF
22678 /* confdefs.h.  */
22679 _ACEOF
22680 cat confdefs.h >>conftest.$ac_ext
22681 cat >>conftest.$ac_ext <<_ACEOF
22682 /* end confdefs.h.  */
22683
22684 /* Override any GCC internal prototype to avoid an error.
22685    Use char because int might match the return type of a GCC
22686    builtin and then its argument prototype would still apply.  */
22687 #ifdef __cplusplus
22688 extern "C"
22689 #endif
22690 char pthread_join ();
22691 int
22692 main ()
22693 {
22694 return pthread_join ();
22695   ;
22696   return 0;
22697 }
22698 _ACEOF
22699 rm -f conftest.$ac_objext conftest$ac_exeext
22700 if { (ac_try="$ac_link"
22701 case "(($ac_try" in
22702   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22703   *) ac_try_echo=$ac_try;;
22704 esac
22705 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22706 $as_echo "$ac_try_echo") >&5
22707   (eval "$ac_link") 2>conftest.er1
22708   ac_status=$?
22709   grep -v '^ *+' conftest.er1 >conftest.err
22710   rm -f conftest.er1
22711   cat conftest.err >&5
22712   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22713   (exit $ac_status); } && {
22714          test -z "$ac_c_werror_flag" ||
22715          test ! -s conftest.err
22716        } && test -s conftest$ac_exeext && {
22717          test "$cross_compiling" = yes ||
22718          $as_test_x conftest$ac_exeext
22719        }; then
22720   acx_pthread_ok=yes
22721 else
22722   $as_echo "$as_me: failed program was:" >&5
22723 sed 's/^/| /' conftest.$ac_ext >&5
22724
22725
22726 fi
22727
22728 rm -rf conftest.dSYM
22729 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22730       conftest$ac_exeext conftest.$ac_ext
22731         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22732 $as_echo "$acx_pthread_ok" >&6; }
22733         if test x"$acx_pthread_ok" = xno; then
22734                 PTHREAD_LIBS=""
22735                 PTHREAD_CFLAGS=""
22736         fi
22737         LIBS="$save_LIBS"
22738         CFLAGS="$save_CFLAGS"
22739 fi
22740
22741 # We must check for the threads library under a number of different
22742 # names; the ordering is very important because some systems
22743 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
22744 # libraries is broken (non-POSIX).
22745
22746 # Create a list of thread flags to try.  Items starting with a "-" are
22747 # C compiler flags, and other items are library names, except for "none"
22748 # which indicates that we try without any flags at all, and "pthread-config"
22749 # which is a program returning the flags for the Pth emulation library.
22750
22751 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
22752
22753 # The ordering *is* (sometimes) important.  Some notes on the
22754 # individual items follow:
22755
22756 # pthreads: AIX (must check this before -lpthread)
22757 # none: in case threads are in libc; should be tried before -Kthread and
22758 #       other compiler flags to prevent continual compiler warnings
22759 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
22760 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
22761 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
22762 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
22763 # -pthreads: Solaris/gcc
22764 # -mthreads: Mingw32/gcc, Lynx/gcc
22765 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
22766 #      doesn't hurt to check since this sometimes defines pthreads too;
22767 #      also defines -D_REENTRANT)
22768 # pthread: Linux, etcetera
22769 # --thread-safe: KAI C++
22770 # pthread-config: use pthread-config program (for GNU Pth library)
22771
22772 case "${host_cpu}-${host_os}" in
22773         *solaris*)
22774
22775         # On Solaris (at least, for some versions), libc contains stubbed
22776         # (non-functional) versions of the pthreads routines, so link-based
22777         # tests will erroneously succeed.  (We need to link with -pthread or
22778         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
22779         # a function called by this macro, so we could check for that, but
22780         # who knows whether they'll stub that too in a future libc.)  So,
22781         # we'll just look for -pthreads and -lpthread first:
22782
22783         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
22784         ;;
22785 esac
22786
22787 if test x"$acx_pthread_ok" = xno; then
22788 for flag in $acx_pthread_flags; do
22789
22790         tryPTHREAD_CFLAGS=""
22791         tryPTHREAD_LIBS=""
22792         case $flag in
22793                 none)
22794                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
22795 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
22796                 ;;
22797
22798                 -*)
22799                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
22800 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
22801                 tryPTHREAD_CFLAGS="$flag"
22802                 ;;
22803
22804                 pthread-config)
22805                 # skip this if we already have flags defined, for PostgreSQL
22806                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
22807                 # Extract the first word of "pthread-config", so it can be a program name with args.
22808 set dummy pthread-config; ac_word=$2
22809 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22810 $as_echo_n "checking for $ac_word... " >&6; }
22811 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
22812   $as_echo_n "(cached) " >&6
22813 else
22814   if test -n "$acx_pthread_config"; then
22815   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
22816 else
22817 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22818 for as_dir in $PATH
22819 do
22820   IFS=$as_save_IFS
22821   test -z "$as_dir" && as_dir=.
22822   for ac_exec_ext in '' $ac_executable_extensions; do
22823   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22824     ac_cv_prog_acx_pthread_config="yes"
22825     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22826     break 2
22827   fi
22828 done
22829 done
22830 IFS=$as_save_IFS
22831
22832   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
22833 fi
22834 fi
22835 acx_pthread_config=$ac_cv_prog_acx_pthread_config
22836 if test -n "$acx_pthread_config"; then
22837   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
22838 $as_echo "$acx_pthread_config" >&6; }
22839 else
22840   { $as_echo "$as_me:$LINENO: result: no" >&5
22841 $as_echo "no" >&6; }
22842 fi
22843
22844
22845                 if test x"$acx_pthread_config" = xno; then continue; fi
22846                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
22847                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
22848                 ;;
22849
22850                 *)
22851                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
22852 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
22853                 tryPTHREAD_LIBS="-l$flag"
22854                 ;;
22855         esac
22856
22857         save_LIBS="$LIBS"
22858         save_CFLAGS="$CFLAGS"
22859         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
22860         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22861
22862         # Check for various functions.  We must include pthread.h,
22863         # since some functions may be macros.  (On the Sequent, we
22864         # need a special flag -Kthread to make this header compile.)
22865         # We check for pthread_join because it is in -lpthread on IRIX
22866         # while pthread_create is in libc.  We check for pthread_attr_init
22867         # due to DEC craziness with -lpthreads.  We check for
22868         # pthread_cleanup_push because it is one of the few pthread
22869         # functions on Solaris that doesn't have a non-functional libc stub.
22870         # We try pthread_create on general principles.
22871         cat >conftest.$ac_ext <<_ACEOF
22872 /* confdefs.h.  */
22873 _ACEOF
22874 cat confdefs.h >>conftest.$ac_ext
22875 cat >>conftest.$ac_ext <<_ACEOF
22876 /* end confdefs.h.  */
22877 #include <pthread.h>
22878 int
22879 main ()
22880 {
22881 pthread_t th; pthread_join(th, 0);
22882                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
22883                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
22884   ;
22885   return 0;
22886 }
22887 _ACEOF
22888 rm -f conftest.$ac_objext conftest$ac_exeext
22889 if { (ac_try="$ac_link"
22890 case "(($ac_try" in
22891   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22892   *) ac_try_echo=$ac_try;;
22893 esac
22894 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22895 $as_echo "$ac_try_echo") >&5
22896   (eval "$ac_link") 2>conftest.er1
22897   ac_status=$?
22898   grep -v '^ *+' conftest.er1 >conftest.err
22899   rm -f conftest.er1
22900   cat conftest.err >&5
22901   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22902   (exit $ac_status); } && {
22903          test -z "$ac_c_werror_flag" ||
22904          test ! -s conftest.err
22905        } && test -s conftest$ac_exeext && {
22906          test "$cross_compiling" = yes ||
22907          $as_test_x conftest$ac_exeext
22908        }; then
22909   acx_pthread_ok=yes
22910 else
22911   $as_echo "$as_me: failed program was:" >&5
22912 sed 's/^/| /' conftest.$ac_ext >&5
22913
22914         acx_pthread_ok=no
22915 fi
22916
22917 rm -rf conftest.dSYM
22918 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22919       conftest$ac_exeext conftest.$ac_ext
22920
22921         if test "x$acx_pthread_ok" = xyes; then
22922             # Don't use options that are ignored by the compiler.
22923             # We find them by checking stderror.
22924             cat >conftest.$ac_ext <<_ACEOF
22925 int
22926 main (int argc, char **argv)
22927 {
22928   (void) argc;
22929   (void) argv;
22930   return 0;
22931 }
22932 _ACEOF
22933             rm -f conftest.$ac_objext conftest$ac_exeext
22934             # Check both linking and compiling, because they might tolerate different options.
22935             if test "`(eval $ac_link 2>&1 1>&5)`" = "" && test "`(eval $ac_compile 2>&1 1>&5)`" = ""; then
22936                 # we continue with more flags because Linux needs -lpthread
22937                 # for libpq builds on PostgreSQL.  The test above only
22938                 # tests for building binaries, not shared libraries.
22939                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
22940                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22941             else   acx_pthread_ok=no
22942             fi
22943         fi
22944
22945         LIBS="$save_LIBS"
22946         CFLAGS="$save_CFLAGS"
22947
22948         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22949 $as_echo "$acx_pthread_ok" >&6; }
22950 done
22951 fi
22952
22953 # Various other checks:
22954 if test "x$acx_pthread_ok" = xyes; then
22955         save_LIBS="$LIBS"
22956         LIBS="$PTHREAD_LIBS $LIBS"
22957         save_CFLAGS="$CFLAGS"
22958         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22959
22960         # Detect AIX lossage: threads are created detached by default
22961         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
22962         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
22963 $as_echo_n "checking for joinable pthread attribute... " >&6; }
22964         cat >conftest.$ac_ext <<_ACEOF
22965 /* confdefs.h.  */
22966 _ACEOF
22967 cat confdefs.h >>conftest.$ac_ext
22968 cat >>conftest.$ac_ext <<_ACEOF
22969 /* end confdefs.h.  */
22970 #include <pthread.h>
22971 int
22972 main ()
22973 {
22974 int attr=PTHREAD_CREATE_JOINABLE;
22975   ;
22976   return 0;
22977 }
22978 _ACEOF
22979 rm -f conftest.$ac_objext conftest$ac_exeext
22980 if { (ac_try="$ac_link"
22981 case "(($ac_try" in
22982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22983   *) ac_try_echo=$ac_try;;
22984 esac
22985 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22986 $as_echo "$ac_try_echo") >&5
22987   (eval "$ac_link") 2>conftest.er1
22988   ac_status=$?
22989   grep -v '^ *+' conftest.er1 >conftest.err
22990   rm -f conftest.er1
22991   cat conftest.err >&5
22992   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22993   (exit $ac_status); } && {
22994          test -z "$ac_c_werror_flag" ||
22995          test ! -s conftest.err
22996        } && test -s conftest$ac_exeext && {
22997          test "$cross_compiling" = yes ||
22998          $as_test_x conftest$ac_exeext
22999        }; then
23000   ok=PTHREAD_CREATE_JOINABLE
23001 else
23002   $as_echo "$as_me: failed program was:" >&5
23003 sed 's/^/| /' conftest.$ac_ext >&5
23004
23005         ok=unknown
23006 fi
23007
23008 rm -rf conftest.dSYM
23009 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23010       conftest$ac_exeext conftest.$ac_ext
23011         if test x"$ok" = xunknown; then
23012                 cat >conftest.$ac_ext <<_ACEOF
23013 /* confdefs.h.  */
23014 _ACEOF
23015 cat confdefs.h >>conftest.$ac_ext
23016 cat >>conftest.$ac_ext <<_ACEOF
23017 /* end confdefs.h.  */
23018 #include <pthread.h>
23019 int
23020 main ()
23021 {
23022 int attr=PTHREAD_CREATE_UNDETACHED;
23023   ;
23024   return 0;
23025 }
23026 _ACEOF
23027 rm -f conftest.$ac_objext conftest$ac_exeext
23028 if { (ac_try="$ac_link"
23029 case "(($ac_try" in
23030   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23031   *) ac_try_echo=$ac_try;;
23032 esac
23033 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23034 $as_echo "$ac_try_echo") >&5
23035   (eval "$ac_link") 2>conftest.er1
23036   ac_status=$?
23037   grep -v '^ *+' conftest.er1 >conftest.err
23038   rm -f conftest.er1
23039   cat conftest.err >&5
23040   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23041   (exit $ac_status); } && {
23042          test -z "$ac_c_werror_flag" ||
23043          test ! -s conftest.err
23044        } && test -s conftest$ac_exeext && {
23045          test "$cross_compiling" = yes ||
23046          $as_test_x conftest$ac_exeext
23047        }; then
23048   ok=PTHREAD_CREATE_UNDETACHED
23049 else
23050   $as_echo "$as_me: failed program was:" >&5
23051 sed 's/^/| /' conftest.$ac_ext >&5
23052
23053         ok=unknown
23054 fi
23055
23056 rm -rf conftest.dSYM
23057 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23058       conftest$ac_exeext conftest.$ac_ext
23059         fi
23060         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
23061
23062 cat >>confdefs.h <<\_ACEOF
23063 #define PTHREAD_CREATE_JOINABLE $ok
23064 _ACEOF
23065
23066         fi
23067         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
23068 $as_echo "${ok}" >&6; }
23069         if test x"$ok" = xunknown; then
23070                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
23071 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
23072         fi
23073
23074         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
23075 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
23076         flag=no
23077 # We always add these in PostgreSQL
23078 #       case "${host_cpu}-${host_os}" in
23079 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
23080 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
23081 #       esac
23082         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
23083 $as_echo "${flag}" >&6; }
23084         if test "x$flag" != xno; then
23085                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
23086         fi
23087
23088         LIBS="$save_LIBS"
23089         CFLAGS="$save_CFLAGS"
23090
23091 # Supporting cc_r would require a special CC in all places that
23092 # use libpq, and that is ugly, so we don't do it.  Users can still
23093 # define their compiler as cc_r to do thread builds of everything.
23094         # More AIX lossage: must compile with cc_r
23095         # Extract the first word of "cc_r", so it can be a program name with args.
23096 set dummy cc_r; ac_word=$2
23097 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
23098 $as_echo_n "checking for $ac_word... " >&6; }
23099 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
23100   $as_echo_n "(cached) " >&6
23101 else
23102   if test -n "$PTHREAD_CC"; then
23103   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
23104 else
23105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23106 for as_dir in $PATH
23107 do
23108   IFS=$as_save_IFS
23109   test -z "$as_dir" && as_dir=.
23110   for ac_exec_ext in '' $ac_executable_extensions; do
23111   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
23112     ac_cv_prog_PTHREAD_CC="cc_r"
23113     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
23114     break 2
23115   fi
23116 done
23117 done
23118 IFS=$as_save_IFS
23119
23120   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
23121 fi
23122 fi
23123 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
23124 if test -n "$PTHREAD_CC"; then
23125   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
23126 $as_echo "$PTHREAD_CC" >&6; }
23127 else
23128   { $as_echo "$as_me:$LINENO: result: no" >&5
23129 $as_echo "no" >&6; }
23130 fi
23131
23132
23133 else
23134         PTHREAD_CC="$CC"
23135 fi
23136
23137
23138
23139
23140
23141 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
23142 if test x"$acx_pthread_ok" = xyes; then
23143
23144 cat >>confdefs.h <<\_ACEOF
23145 #define HAVE_PTHREAD 1
23146 _ACEOF
23147
23148         :
23149 else
23150         acx_pthread_ok=no
23151
23152 fi
23153 ac_ext=c
23154 ac_cpp='$CPP $CPPFLAGS'
23155 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23156 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23157 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23158
23159         # set thread flags
23160
23161 # Some platforms use these, so just define them.  They can't hurt if they
23162 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
23163 # enables 5-arg getpwuid_r, among other things.
23164 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
23165
23166
23167 # At this point, we don't want to muck with the compiler name for threading.
23168 # Let's see who fails, perhaps AIX.  2004-04-23
23169 if test "$PTHREAD_CC" != "$CC"; then
23170 { { $as_echo "$as_me:$LINENO: error:
23171 PostgreSQL does not support platforms that require a special compiler
23172 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
23173 $as_echo "$as_me: error:
23174 PostgreSQL does not support platforms that require a special compiler
23175 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
23176    { (exit 1); exit 1; }; }
23177 fi
23178
23179 # Check for *_r functions
23180 _CFLAGS="$CFLAGS"
23181 _LIBS="$LIBS"
23182 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
23183 LIBS="$LIBS $PTHREAD_LIBS"
23184
23185 if test "$PORTNAME" != "win32"; then
23186 if test "${ac_cv_header_pthread_h+set}" = set; then
23187   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23188 $as_echo_n "checking for pthread.h... " >&6; }
23189 if test "${ac_cv_header_pthread_h+set}" = set; then
23190   $as_echo_n "(cached) " >&6
23191 fi
23192 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23193 $as_echo "$ac_cv_header_pthread_h" >&6; }
23194 else
23195   # Is the header compilable?
23196 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
23197 $as_echo_n "checking pthread.h usability... " >&6; }
23198 cat >conftest.$ac_ext <<_ACEOF
23199 /* confdefs.h.  */
23200 _ACEOF
23201 cat confdefs.h >>conftest.$ac_ext
23202 cat >>conftest.$ac_ext <<_ACEOF
23203 /* end confdefs.h.  */
23204 $ac_includes_default
23205 #include <pthread.h>
23206 _ACEOF
23207 rm -f conftest.$ac_objext
23208 if { (ac_try="$ac_compile"
23209 case "(($ac_try" in
23210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23211   *) ac_try_echo=$ac_try;;
23212 esac
23213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23214 $as_echo "$ac_try_echo") >&5
23215   (eval "$ac_compile") 2>conftest.er1
23216   ac_status=$?
23217   grep -v '^ *+' conftest.er1 >conftest.err
23218   rm -f conftest.er1
23219   cat conftest.err >&5
23220   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23221   (exit $ac_status); } && {
23222          test -z "$ac_c_werror_flag" ||
23223          test ! -s conftest.err
23224        } && test -s conftest.$ac_objext; then
23225   ac_header_compiler=yes
23226 else
23227   $as_echo "$as_me: failed program was:" >&5
23228 sed 's/^/| /' conftest.$ac_ext >&5
23229
23230         ac_header_compiler=no
23231 fi
23232
23233 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23234 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23235 $as_echo "$ac_header_compiler" >&6; }
23236
23237 # Is the header present?
23238 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
23239 $as_echo_n "checking pthread.h presence... " >&6; }
23240 cat >conftest.$ac_ext <<_ACEOF
23241 /* confdefs.h.  */
23242 _ACEOF
23243 cat confdefs.h >>conftest.$ac_ext
23244 cat >>conftest.$ac_ext <<_ACEOF
23245 /* end confdefs.h.  */
23246 #include <pthread.h>
23247 _ACEOF
23248 if { (ac_try="$ac_cpp conftest.$ac_ext"
23249 case "(($ac_try" in
23250   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23251   *) ac_try_echo=$ac_try;;
23252 esac
23253 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23254 $as_echo "$ac_try_echo") >&5
23255   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
23256   ac_status=$?
23257   grep -v '^ *+' conftest.er1 >conftest.err
23258   rm -f conftest.er1
23259   cat conftest.err >&5
23260   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23261   (exit $ac_status); } >/dev/null && {
23262          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
23263          test ! -s conftest.err
23264        }; then
23265   ac_header_preproc=yes
23266 else
23267   $as_echo "$as_me: failed program was:" >&5
23268 sed 's/^/| /' conftest.$ac_ext >&5
23269
23270   ac_header_preproc=no
23271 fi
23272
23273 rm -f conftest.err conftest.$ac_ext
23274 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23275 $as_echo "$ac_header_preproc" >&6; }
23276
23277 # So?  What about this header?
23278 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
23279   yes:no: )
23280     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
23281 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
23282     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
23283 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
23284     ac_header_preproc=yes
23285     ;;
23286   no:yes:* )
23287     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
23288 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
23289     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
23290 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
23291     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
23292 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
23293     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
23294 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
23295     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
23296 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
23297     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
23298 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
23299     ( cat <<\_ASBOX
23300 ## ---------------------------------------- ##
23301 ## Report this to pgsql-bugs@postgresql.org ##
23302 ## ---------------------------------------- ##
23303 _ASBOX
23304      ) | sed "s/^/$as_me: WARNING:     /" >&2
23305     ;;
23306 esac
23307 { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23308 $as_echo_n "checking for pthread.h... " >&6; }
23309 if test "${ac_cv_header_pthread_h+set}" = set; then
23310   $as_echo_n "(cached) " >&6
23311 else
23312   ac_cv_header_pthread_h=$ac_header_preproc
23313 fi
23314 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23315 $as_echo "$ac_cv_header_pthread_h" >&6; }
23316
23317 fi
23318 if test "x$ac_cv_header_pthread_h" = x""yes; then
23319   :
23320 else
23321   { { $as_echo "$as_me:$LINENO: error:
23322 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
23323 $as_echo "$as_me: error:
23324 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
23325    { (exit 1); exit 1; }; }
23326 fi
23327
23328
23329 fi
23330
23331
23332
23333
23334 for ac_func in strerror_r getpwuid_r gethostbyname_r
23335 do
23336 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23337 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
23338 $as_echo_n "checking for $ac_func... " >&6; }
23339 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23340   $as_echo_n "(cached) " >&6
23341 else
23342   cat >conftest.$ac_ext <<_ACEOF
23343 /* confdefs.h.  */
23344 _ACEOF
23345 cat confdefs.h >>conftest.$ac_ext
23346 cat >>conftest.$ac_ext <<_ACEOF
23347 /* end confdefs.h.  */
23348 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23349    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23350 #define $ac_func innocuous_$ac_func
23351
23352 /* System header to define __stub macros and hopefully few prototypes,
23353     which can conflict with char $ac_func (); below.
23354     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23355     <limits.h> exists even on freestanding compilers.  */
23356
23357 #ifdef __STDC__
23358 # include <limits.h>
23359 #else
23360 # include <assert.h>
23361 #endif
23362
23363 #undef $ac_func
23364
23365 /* Override any GCC internal prototype to avoid an error.
23366    Use char because int might match the return type of a GCC
23367    builtin and then its argument prototype would still apply.  */
23368 #ifdef __cplusplus
23369 extern "C"
23370 #endif
23371 char $ac_func ();
23372 /* The GNU C library defines this for functions which it implements
23373     to always fail with ENOSYS.  Some functions are actually named
23374     something starting with __ and the normal name is an alias.  */
23375 #if defined __stub_$ac_func || defined __stub___$ac_func
23376 choke me
23377 #endif
23378
23379 int
23380 main ()
23381 {
23382 return $ac_func ();
23383   ;
23384   return 0;
23385 }
23386 _ACEOF
23387 rm -f conftest.$ac_objext conftest$ac_exeext
23388 if { (ac_try="$ac_link"
23389 case "(($ac_try" in
23390   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23391   *) ac_try_echo=$ac_try;;
23392 esac
23393 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23394 $as_echo "$ac_try_echo") >&5
23395   (eval "$ac_link") 2>conftest.er1
23396   ac_status=$?
23397   grep -v '^ *+' conftest.er1 >conftest.err
23398   rm -f conftest.er1
23399   cat conftest.err >&5
23400   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23401   (exit $ac_status); } && {
23402          test -z "$ac_c_werror_flag" ||
23403          test ! -s conftest.err
23404        } && test -s conftest$ac_exeext && {
23405          test "$cross_compiling" = yes ||
23406          $as_test_x conftest$ac_exeext
23407        }; then
23408   eval "$as_ac_var=yes"
23409 else
23410   $as_echo "$as_me: failed program was:" >&5
23411 sed 's/^/| /' conftest.$ac_ext >&5
23412
23413         eval "$as_ac_var=no"
23414 fi
23415
23416 rm -rf conftest.dSYM
23417 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23418       conftest$ac_exeext conftest.$ac_ext
23419 fi
23420 ac_res=`eval 'as_val=${'$as_ac_var'}
23421                  $as_echo "$as_val"'`
23422                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23423 $as_echo "$ac_res" >&6; }
23424 as_val=`eval 'as_val=${'$as_ac_var'}
23425                  $as_echo "$as_val"'`
23426    if test "x$as_val" = x""yes; then
23427   cat >>confdefs.h <<_ACEOF
23428 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23429 _ACEOF
23430
23431 fi
23432 done
23433
23434
23435 # Do test here with the proper thread flags
23436 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
23437 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
23438 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
23439   $as_echo_n "(cached) " >&6
23440 else
23441   cat >conftest.$ac_ext <<_ACEOF
23442 /* confdefs.h.  */
23443 _ACEOF
23444 cat confdefs.h >>conftest.$ac_ext
23445 cat >>conftest.$ac_ext <<_ACEOF
23446 /* end confdefs.h.  */
23447 #include <sys/types.h>
23448 #include <pwd.h>
23449 int
23450 main ()
23451 {
23452 uid_t uid;
23453 struct passwd *space;
23454 char *buf;
23455 size_t bufsize;
23456 struct passwd **result;
23457 getpwuid_r(uid, space, buf, bufsize, result);
23458   ;
23459   return 0;
23460 }
23461 _ACEOF
23462 rm -f conftest.$ac_objext
23463 if { (ac_try="$ac_compile"
23464 case "(($ac_try" in
23465   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23466   *) ac_try_echo=$ac_try;;
23467 esac
23468 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23469 $as_echo "$ac_try_echo") >&5
23470   (eval "$ac_compile") 2>conftest.er1
23471   ac_status=$?
23472   grep -v '^ *+' conftest.er1 >conftest.err
23473   rm -f conftest.er1
23474   cat conftest.err >&5
23475   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23476   (exit $ac_status); } && {
23477          test -z "$ac_c_werror_flag" ||
23478          test ! -s conftest.err
23479        } && test -s conftest.$ac_objext; then
23480   pgac_cv_func_getpwuid_r_5arg=yes
23481 else
23482   $as_echo "$as_me: failed program was:" >&5
23483 sed 's/^/| /' conftest.$ac_ext >&5
23484
23485         pgac_cv_func_getpwuid_r_5arg=no
23486 fi
23487
23488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23489 fi
23490 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
23491 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
23492 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
23493
23494 cat >>confdefs.h <<\_ACEOF
23495 #define GETPWUID_R_5ARG /**/
23496 _ACEOF
23497
23498 fi
23499
23500 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
23501 $as_echo_n "checking whether strerror_r returns int... " >&6; }
23502 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
23503   $as_echo_n "(cached) " >&6
23504 else
23505   cat >conftest.$ac_ext <<_ACEOF
23506 /* confdefs.h.  */
23507 _ACEOF
23508 cat confdefs.h >>conftest.$ac_ext
23509 cat >>conftest.$ac_ext <<_ACEOF
23510 /* end confdefs.h.  */
23511 #include <string.h>
23512 int
23513 main ()
23514 {
23515 #ifndef _AIX
23516 int strerror_r(int, char *, size_t);
23517 #else
23518 /* Older AIX has 'int' for the third argument so we don't test the args. */
23519 int strerror_r();
23520 #endif
23521   ;
23522   return 0;
23523 }
23524 _ACEOF
23525 rm -f conftest.$ac_objext
23526 if { (ac_try="$ac_compile"
23527 case "(($ac_try" in
23528   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23529   *) ac_try_echo=$ac_try;;
23530 esac
23531 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23532 $as_echo "$ac_try_echo") >&5
23533   (eval "$ac_compile") 2>conftest.er1
23534   ac_status=$?
23535   grep -v '^ *+' conftest.er1 >conftest.err
23536   rm -f conftest.er1
23537   cat conftest.err >&5
23538   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23539   (exit $ac_status); } && {
23540          test -z "$ac_c_werror_flag" ||
23541          test ! -s conftest.err
23542        } && test -s conftest.$ac_objext; then
23543   pgac_cv_func_strerror_r_int=yes
23544 else
23545   $as_echo "$as_me: failed program was:" >&5
23546 sed 's/^/| /' conftest.$ac_ext >&5
23547
23548         pgac_cv_func_strerror_r_int=no
23549 fi
23550
23551 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23552 fi
23553 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
23554 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
23555 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
23556
23557 cat >>confdefs.h <<\_ACEOF
23558 #define STRERROR_R_INT /**/
23559 _ACEOF
23560
23561 fi
23562
23563
23564 CFLAGS="$_CFLAGS"
23565 LIBS="$_LIBS"
23566
23567 else
23568 # do not use values from template file
23569 PTHREAD_CFLAGS=
23570 PTHREAD_LIBS=
23571 fi
23572
23573
23574
23575
23576
23577 # We can test for libldap_r only after we know PTHREAD_LIBS
23578 if test "$with_ldap" = yes ; then
23579   _LIBS="$LIBS"
23580   if test "$PORTNAME" != "win32"; then
23581
23582 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
23583 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
23584 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
23585   $as_echo_n "(cached) " >&6
23586 else
23587   ac_check_lib_save_LIBS=$LIBS
23588 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
23589 cat >conftest.$ac_ext <<_ACEOF
23590 /* confdefs.h.  */
23591 _ACEOF
23592 cat confdefs.h >>conftest.$ac_ext
23593 cat >>conftest.$ac_ext <<_ACEOF
23594 /* end confdefs.h.  */
23595
23596 /* Override any GCC internal prototype to avoid an error.
23597    Use char because int might match the return type of a GCC
23598    builtin and then its argument prototype would still apply.  */
23599 #ifdef __cplusplus
23600 extern "C"
23601 #endif
23602 char ldap_bind ();
23603 int
23604 main ()
23605 {
23606 return ldap_bind ();
23607   ;
23608   return 0;
23609 }
23610 _ACEOF
23611 rm -f conftest.$ac_objext conftest$ac_exeext
23612 if { (ac_try="$ac_link"
23613 case "(($ac_try" in
23614   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23615   *) ac_try_echo=$ac_try;;
23616 esac
23617 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23618 $as_echo "$ac_try_echo") >&5
23619   (eval "$ac_link") 2>conftest.er1
23620   ac_status=$?
23621   grep -v '^ *+' conftest.er1 >conftest.err
23622   rm -f conftest.er1
23623   cat conftest.err >&5
23624   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23625   (exit $ac_status); } && {
23626          test -z "$ac_c_werror_flag" ||
23627          test ! -s conftest.err
23628        } && test -s conftest$ac_exeext && {
23629          test "$cross_compiling" = yes ||
23630          $as_test_x conftest$ac_exeext
23631        }; then
23632   ac_cv_lib_ldap_ldap_bind=yes
23633 else
23634   $as_echo "$as_me: failed program was:" >&5
23635 sed 's/^/| /' conftest.$ac_ext >&5
23636
23637         ac_cv_lib_ldap_ldap_bind=no
23638 fi
23639
23640 rm -rf conftest.dSYM
23641 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23642       conftest$ac_exeext conftest.$ac_ext
23643 LIBS=$ac_check_lib_save_LIBS
23644 fi
23645 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
23646 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
23647 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
23648   cat >>confdefs.h <<_ACEOF
23649 #define HAVE_LIBLDAP 1
23650 _ACEOF
23651
23652   LIBS="-lldap $LIBS"
23653
23654 else
23655   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
23656 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
23657    { (exit 1); exit 1; }; }
23658 fi
23659
23660     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
23661     if test "$enable_thread_safety" = yes; then
23662       # on some platforms ldap_r fails to link without PTHREAD_LIBS
23663
23664 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
23665 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
23666 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
23667   $as_echo_n "(cached) " >&6
23668 else
23669   ac_check_lib_save_LIBS=$LIBS
23670 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
23671 cat >conftest.$ac_ext <<_ACEOF
23672 /* confdefs.h.  */
23673 _ACEOF
23674 cat confdefs.h >>conftest.$ac_ext
23675 cat >>conftest.$ac_ext <<_ACEOF
23676 /* end confdefs.h.  */
23677
23678 /* Override any GCC internal prototype to avoid an error.
23679    Use char because int might match the return type of a GCC
23680    builtin and then its argument prototype would still apply.  */
23681 #ifdef __cplusplus
23682 extern "C"
23683 #endif
23684 char ldap_simple_bind ();
23685 int
23686 main ()
23687 {
23688 return ldap_simple_bind ();
23689   ;
23690   return 0;
23691 }
23692 _ACEOF
23693 rm -f conftest.$ac_objext conftest$ac_exeext
23694 if { (ac_try="$ac_link"
23695 case "(($ac_try" in
23696   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23697   *) ac_try_echo=$ac_try;;
23698 esac
23699 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23700 $as_echo "$ac_try_echo") >&5
23701   (eval "$ac_link") 2>conftest.er1
23702   ac_status=$?
23703   grep -v '^ *+' conftest.er1 >conftest.err
23704   rm -f conftest.er1
23705   cat conftest.err >&5
23706   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23707   (exit $ac_status); } && {
23708          test -z "$ac_c_werror_flag" ||
23709          test ! -s conftest.err
23710        } && test -s conftest$ac_exeext && {
23711          test "$cross_compiling" = yes ||
23712          $as_test_x conftest$ac_exeext
23713        }; then
23714   ac_cv_lib_ldap_r_ldap_simple_bind=yes
23715 else
23716   $as_echo "$as_me: failed program was:" >&5
23717 sed 's/^/| /' conftest.$ac_ext >&5
23718
23719         ac_cv_lib_ldap_r_ldap_simple_bind=no
23720 fi
23721
23722 rm -rf conftest.dSYM
23723 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23724       conftest$ac_exeext conftest.$ac_ext
23725 LIBS=$ac_check_lib_save_LIBS
23726 fi
23727 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
23728 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
23729 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
23730   cat >>confdefs.h <<_ACEOF
23731 #define HAVE_LIBLDAP_R 1
23732 _ACEOF
23733
23734   LIBS="-lldap_r $LIBS"
23735
23736 else
23737   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
23738 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
23739    { (exit 1); exit 1; }; }
23740 fi
23741
23742       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
23743     else
23744       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
23745     fi
23746   else
23747
23748 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
23749 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
23750 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
23751   $as_echo_n "(cached) " >&6
23752 else
23753   ac_check_lib_save_LIBS=$LIBS
23754 LIBS="-lwldap32  $LIBS"
23755 cat >conftest.$ac_ext <<_ACEOF
23756 /* confdefs.h.  */
23757 _ACEOF
23758 cat confdefs.h >>conftest.$ac_ext
23759 cat >>conftest.$ac_ext <<_ACEOF
23760 /* end confdefs.h.  */
23761
23762 /* Override any GCC internal prototype to avoid an error.
23763    Use char because int might match the return type of a GCC
23764    builtin and then its argument prototype would still apply.  */
23765 #ifdef __cplusplus
23766 extern "C"
23767 #endif
23768 char ldap_bind ();
23769 int
23770 main ()
23771 {
23772 return ldap_bind ();
23773   ;
23774   return 0;
23775 }
23776 _ACEOF
23777 rm -f conftest.$ac_objext conftest$ac_exeext
23778 if { (ac_try="$ac_link"
23779 case "(($ac_try" in
23780   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23781   *) ac_try_echo=$ac_try;;
23782 esac
23783 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23784 $as_echo "$ac_try_echo") >&5
23785   (eval "$ac_link") 2>conftest.er1
23786   ac_status=$?
23787   grep -v '^ *+' conftest.er1 >conftest.err
23788   rm -f conftest.er1
23789   cat conftest.err >&5
23790   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23791   (exit $ac_status); } && {
23792          test -z "$ac_c_werror_flag" ||
23793          test ! -s conftest.err
23794        } && test -s conftest$ac_exeext && {
23795          test "$cross_compiling" = yes ||
23796          $as_test_x conftest$ac_exeext
23797        }; then
23798   ac_cv_lib_wldap32_ldap_bind=yes
23799 else
23800   $as_echo "$as_me: failed program was:" >&5
23801 sed 's/^/| /' conftest.$ac_ext >&5
23802
23803         ac_cv_lib_wldap32_ldap_bind=no
23804 fi
23805
23806 rm -rf conftest.dSYM
23807 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23808       conftest$ac_exeext conftest.$ac_ext
23809 LIBS=$ac_check_lib_save_LIBS
23810 fi
23811 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
23812 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
23813 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
23814   cat >>confdefs.h <<_ACEOF
23815 #define HAVE_LIBWLDAP32 1
23816 _ACEOF
23817
23818   LIBS="-lwldap32 $LIBS"
23819
23820 else
23821   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
23822 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
23823    { (exit 1); exit 1; }; }
23824 fi
23825
23826     LDAP_LIBS_FE="-lwldap32"
23827     LDAP_LIBS_BE="-lwldap32"
23828   fi
23829   LIBS="$_LIBS"
23830 fi
23831
23832
23833
23834
23835 # This test makes sure that run tests work at all.  Sometimes a shared
23836 # library is found by the linker, but the runtime linker can't find it.
23837 # This check should come after all modifications of compiler or linker
23838 # variables, and before any other run tests.
23839 { $as_echo "$as_me:$LINENO: checking test program" >&5
23840 $as_echo_n "checking test program... " >&6; }
23841 if test "$cross_compiling" = yes; then
23842   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
23843 $as_echo "cross-compiling" >&6; }
23844 else
23845   cat >conftest.$ac_ext <<_ACEOF
23846 /* confdefs.h.  */
23847 _ACEOF
23848 cat confdefs.h >>conftest.$ac_ext
23849 cat >>conftest.$ac_ext <<_ACEOF
23850 /* end confdefs.h.  */
23851 int main() { return 0; }
23852 _ACEOF
23853 rm -f conftest$ac_exeext
23854 if { (ac_try="$ac_link"
23855 case "(($ac_try" in
23856   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23857   *) ac_try_echo=$ac_try;;
23858 esac
23859 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23860 $as_echo "$ac_try_echo") >&5
23861   (eval "$ac_link") 2>&5
23862   ac_status=$?
23863   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23864   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23865   { (case "(($ac_try" in
23866   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23867   *) ac_try_echo=$ac_try;;
23868 esac
23869 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23870 $as_echo "$ac_try_echo") >&5
23871   (eval "$ac_try") 2>&5
23872   ac_status=$?
23873   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23874   (exit $ac_status); }; }; then
23875   { $as_echo "$as_me:$LINENO: result: ok" >&5
23876 $as_echo "ok" >&6; }
23877 else
23878   $as_echo "$as_me: program exited with status $ac_status" >&5
23879 $as_echo "$as_me: failed program was:" >&5
23880 sed 's/^/| /' conftest.$ac_ext >&5
23881
23882 ( exit $ac_status )
23883 { $as_echo "$as_me:$LINENO: result: failed" >&5
23884 $as_echo "failed" >&6; }
23885 { { $as_echo "$as_me:$LINENO: error:
23886 Could not execute a simple test program.  This may be a problem
23887 related to locating shared libraries.  Check the file 'config.log'
23888 for the exact reason." >&5
23889 $as_echo "$as_me: error:
23890 Could not execute a simple test program.  This may be a problem
23891 related to locating shared libraries.  Check the file 'config.log'
23892 for the exact reason." >&2;}
23893    { (exit 1); exit 1; }; }
23894 fi
23895 rm -rf conftest.dSYM
23896 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23897 fi
23898
23899
23900
23901 # --------------------
23902 # Run tests below here
23903 # --------------------
23904
23905 # Force use of our snprintf if system's doesn't do arg control
23906 # See comment above at snprintf test for details.
23907 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
23908   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
23909 $as_echo_n "checking whether printf supports argument control... " >&6; }
23910 if test "${pgac_cv_printf_arg_control+set}" = set; then
23911   $as_echo_n "(cached) " >&6
23912 else
23913   if test "$cross_compiling" = yes; then
23914   pgac_cv_printf_arg_control=cross
23915 else
23916   cat >conftest.$ac_ext <<_ACEOF
23917 /* confdefs.h.  */
23918 _ACEOF
23919 cat confdefs.h >>conftest.$ac_ext
23920 cat >>conftest.$ac_ext <<_ACEOF
23921 /* end confdefs.h.  */
23922 #include <stdio.h>
23923 #include <string.h>
23924
23925 int main()
23926 {
23927   char buf[100];
23928
23929   /* can it swap arguments? */
23930   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
23931   if (strcmp(buf, "4 3") != 0)
23932     return 1;
23933   return 0;
23934 }
23935 _ACEOF
23936 rm -f conftest$ac_exeext
23937 if { (ac_try="$ac_link"
23938 case "(($ac_try" in
23939   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23940   *) ac_try_echo=$ac_try;;
23941 esac
23942 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23943 $as_echo "$ac_try_echo") >&5
23944   (eval "$ac_link") 2>&5
23945   ac_status=$?
23946   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23947   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23948   { (case "(($ac_try" in
23949   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23950   *) ac_try_echo=$ac_try;;
23951 esac
23952 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23953 $as_echo "$ac_try_echo") >&5
23954   (eval "$ac_try") 2>&5
23955   ac_status=$?
23956   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23957   (exit $ac_status); }; }; then
23958   pgac_cv_printf_arg_control=yes
23959 else
23960   $as_echo "$as_me: program exited with status $ac_status" >&5
23961 $as_echo "$as_me: failed program was:" >&5
23962 sed 's/^/| /' conftest.$ac_ext >&5
23963
23964 ( exit $ac_status )
23965 pgac_cv_printf_arg_control=no
23966 fi
23967 rm -rf conftest.dSYM
23968 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23969 fi
23970
23971
23972
23973 fi
23974 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
23975 $as_echo "$pgac_cv_printf_arg_control" >&6; }
23976
23977   if test $pgac_cv_printf_arg_control != yes ; then
23978     pgac_need_repl_snprintf=yes
23979   fi
23980 fi
23981
23982
23983
23984
23985 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
23986 $as_echo_n "checking whether long int is 64 bits... " >&6; }
23987 if test "${pgac_cv_type_long_int_64+set}" = set; then
23988   $as_echo_n "(cached) " >&6
23989 else
23990   if test "$cross_compiling" = yes; then
23991   # If cross-compiling, check the size reported by the compiler and
23992 # trust that the arithmetic works.
23993 cat >conftest.$ac_ext <<_ACEOF
23994 /* confdefs.h.  */
23995 _ACEOF
23996 cat confdefs.h >>conftest.$ac_ext
23997 cat >>conftest.$ac_ext <<_ACEOF
23998 /* end confdefs.h.  */
23999
24000 int
24001 main ()
24002 {
24003 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
24004 test_array [0] = 0
24005
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_type_long_int_64=yes
24029 else
24030   $as_echo "$as_me: failed program was:" >&5
24031 sed 's/^/| /' conftest.$ac_ext >&5
24032
24033         pgac_cv_type_long_int_64=no
24034 fi
24035
24036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24037 else
24038   cat >conftest.$ac_ext <<_ACEOF
24039 /* confdefs.h.  */
24040 _ACEOF
24041 cat confdefs.h >>conftest.$ac_ext
24042 cat >>conftest.$ac_ext <<_ACEOF
24043 /* end confdefs.h.  */
24044 typedef long int ac_int64;
24045
24046 /*
24047  * These are globals to discourage the compiler from folding all the
24048  * arithmetic tests down to compile-time constants.
24049  */
24050 ac_int64 a = 20000001;
24051 ac_int64 b = 40000005;
24052
24053 int does_int64_work()
24054 {
24055   ac_int64 c,d;
24056
24057   if (sizeof(ac_int64) != 8)
24058     return 0;                   /* definitely not the right size */
24059
24060   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
24061   c = a * b;
24062   d = (c + b) / b;
24063   if (d != a+1)
24064     return 0;
24065   return 1;
24066 }
24067 main() {
24068   exit(! does_int64_work());
24069 }
24070 _ACEOF
24071 rm -f conftest$ac_exeext
24072 if { (ac_try="$ac_link"
24073 case "(($ac_try" in
24074   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24075   *) ac_try_echo=$ac_try;;
24076 esac
24077 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24078 $as_echo "$ac_try_echo") >&5
24079   (eval "$ac_link") 2>&5
24080   ac_status=$?
24081   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24082   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24083   { (case "(($ac_try" in
24084   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24085   *) ac_try_echo=$ac_try;;
24086 esac
24087 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24088 $as_echo "$ac_try_echo") >&5
24089   (eval "$ac_try") 2>&5
24090   ac_status=$?
24091   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24092   (exit $ac_status); }; }; then
24093   pgac_cv_type_long_int_64=yes
24094 else
24095   $as_echo "$as_me: program exited with status $ac_status" >&5
24096 $as_echo "$as_me: failed program was:" >&5
24097 sed 's/^/| /' conftest.$ac_ext >&5
24098
24099 ( exit $ac_status )
24100 pgac_cv_type_long_int_64=no
24101 fi
24102 rm -rf conftest.dSYM
24103 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24104 fi
24105
24106
24107 fi
24108 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
24109 $as_echo "$pgac_cv_type_long_int_64" >&6; }
24110
24111 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
24112 if test x"$pgac_cv_type_long_int_64" = xyes ; then
24113
24114 cat >>confdefs.h <<\_ACEOF
24115 #define HAVE_LONG_INT_64 1
24116 _ACEOF
24117
24118 fi
24119
24120
24121 if test x"$HAVE_LONG_INT_64" = x"no" ; then
24122   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
24123 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
24124 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
24125   $as_echo_n "(cached) " >&6
24126 else
24127   if test "$cross_compiling" = yes; then
24128   # If cross-compiling, check the size reported by the compiler and
24129 # trust that the arithmetic works.
24130 cat >conftest.$ac_ext <<_ACEOF
24131 /* confdefs.h.  */
24132 _ACEOF
24133 cat confdefs.h >>conftest.$ac_ext
24134 cat >>conftest.$ac_ext <<_ACEOF
24135 /* end confdefs.h.  */
24136
24137 int
24138 main ()
24139 {
24140 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
24141 test_array [0] = 0
24142
24143   ;
24144   return 0;
24145 }
24146 _ACEOF
24147 rm -f conftest.$ac_objext
24148 if { (ac_try="$ac_compile"
24149 case "(($ac_try" in
24150   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24151   *) ac_try_echo=$ac_try;;
24152 esac
24153 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24154 $as_echo "$ac_try_echo") >&5
24155   (eval "$ac_compile") 2>conftest.er1
24156   ac_status=$?
24157   grep -v '^ *+' conftest.er1 >conftest.err
24158   rm -f conftest.er1
24159   cat conftest.err >&5
24160   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24161   (exit $ac_status); } && {
24162          test -z "$ac_c_werror_flag" ||
24163          test ! -s conftest.err
24164        } && test -s conftest.$ac_objext; then
24165   pgac_cv_type_long_long_int_64=yes
24166 else
24167   $as_echo "$as_me: failed program was:" >&5
24168 sed 's/^/| /' conftest.$ac_ext >&5
24169
24170         pgac_cv_type_long_long_int_64=no
24171 fi
24172
24173 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24174 else
24175   cat >conftest.$ac_ext <<_ACEOF
24176 /* confdefs.h.  */
24177 _ACEOF
24178 cat confdefs.h >>conftest.$ac_ext
24179 cat >>conftest.$ac_ext <<_ACEOF
24180 /* end confdefs.h.  */
24181 typedef long long int ac_int64;
24182
24183 /*
24184  * These are globals to discourage the compiler from folding all the
24185  * arithmetic tests down to compile-time constants.
24186  */
24187 ac_int64 a = 20000001;
24188 ac_int64 b = 40000005;
24189
24190 int does_int64_work()
24191 {
24192   ac_int64 c,d;
24193
24194   if (sizeof(ac_int64) != 8)
24195     return 0;                   /* definitely not the right size */
24196
24197   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
24198   c = a * b;
24199   d = (c + b) / b;
24200   if (d != a+1)
24201     return 0;
24202   return 1;
24203 }
24204 main() {
24205   exit(! does_int64_work());
24206 }
24207 _ACEOF
24208 rm -f conftest$ac_exeext
24209 if { (ac_try="$ac_link"
24210 case "(($ac_try" in
24211   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24212   *) ac_try_echo=$ac_try;;
24213 esac
24214 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24215 $as_echo "$ac_try_echo") >&5
24216   (eval "$ac_link") 2>&5
24217   ac_status=$?
24218   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24219   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24220   { (case "(($ac_try" in
24221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24222   *) ac_try_echo=$ac_try;;
24223 esac
24224 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24225 $as_echo "$ac_try_echo") >&5
24226   (eval "$ac_try") 2>&5
24227   ac_status=$?
24228   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24229   (exit $ac_status); }; }; then
24230   pgac_cv_type_long_long_int_64=yes
24231 else
24232   $as_echo "$as_me: program exited with status $ac_status" >&5
24233 $as_echo "$as_me: failed program was:" >&5
24234 sed 's/^/| /' conftest.$ac_ext >&5
24235
24236 ( exit $ac_status )
24237 pgac_cv_type_long_long_int_64=no
24238 fi
24239 rm -rf conftest.dSYM
24240 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24241 fi
24242
24243
24244 fi
24245 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
24246 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
24247
24248 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
24249 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
24250
24251 cat >>confdefs.h <<\_ACEOF
24252 #define HAVE_LONG_LONG_INT_64 1
24253 _ACEOF
24254
24255 fi
24256
24257   if test x"$HAVE_LONG_LONG_INT_64" = x"no" ; then
24258     { { $as_echo "$as_me:$LINENO: error: Cannot find a working 64-bit integer type." >&5
24259 $as_echo "$as_me: error: Cannot find a working 64-bit integer type." >&2;}
24260    { (exit 1); exit 1; }; }
24261   fi
24262 fi
24263
24264
24265
24266 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
24267   cat >conftest.$ac_ext <<_ACEOF
24268 /* confdefs.h.  */
24269 _ACEOF
24270 cat confdefs.h >>conftest.$ac_ext
24271 cat >>conftest.$ac_ext <<_ACEOF
24272 /* end confdefs.h.  */
24273
24274 #define INT64CONST(x)  x##LL
24275 long long int foo = INT64CONST(0x1234567890123456);
24276
24277 int
24278 main ()
24279 {
24280
24281   ;
24282   return 0;
24283 }
24284 _ACEOF
24285 rm -f conftest.$ac_objext
24286 if { (ac_try="$ac_compile"
24287 case "(($ac_try" in
24288   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24289   *) ac_try_echo=$ac_try;;
24290 esac
24291 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24292 $as_echo "$ac_try_echo") >&5
24293   (eval "$ac_compile") 2>conftest.er1
24294   ac_status=$?
24295   grep -v '^ *+' conftest.er1 >conftest.err
24296   rm -f conftest.er1
24297   cat conftest.err >&5
24298   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24299   (exit $ac_status); } && {
24300          test -z "$ac_c_werror_flag" ||
24301          test ! -s conftest.err
24302        } && test -s conftest.$ac_objext; then
24303
24304 cat >>confdefs.h <<\_ACEOF
24305 #define HAVE_LL_CONSTANTS 1
24306 _ACEOF
24307
24308 else
24309   $as_echo "$as_me: failed program was:" >&5
24310 sed 's/^/| /' conftest.$ac_ext >&5
24311
24312
24313 fi
24314
24315 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24316 fi
24317
24318
24319 # If we found "long int" is 64 bits, assume snprintf handles it.  If
24320 # we found we need to use "long long int", better check.  We cope with
24321 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
24322 # work, fall back to our own snprintf emulation (which we know uses %lld).
24323
24324 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
24325   if test $pgac_need_repl_snprintf = no; then
24326     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
24327 $as_echo_n "checking snprintf format for long long int... " >&6; }
24328 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
24329   $as_echo_n "(cached) " >&6
24330 else
24331   for pgac_format in '%lld' '%qd' '%I64d'; do
24332 if test "$cross_compiling" = yes; then
24333   pgac_cv_snprintf_long_long_int_format=cross; break
24334 else
24335   cat >conftest.$ac_ext <<_ACEOF
24336 /* confdefs.h.  */
24337 _ACEOF
24338 cat confdefs.h >>conftest.$ac_ext
24339 cat >>conftest.$ac_ext <<_ACEOF
24340 /* end confdefs.h.  */
24341 #include <stdio.h>
24342 typedef long long int ac_int64;
24343 #define INT64_FORMAT "$pgac_format"
24344
24345 ac_int64 a = 20000001;
24346 ac_int64 b = 40000005;
24347
24348 int does_int64_snprintf_work()
24349 {
24350   ac_int64 c;
24351   char buf[100];
24352
24353   if (sizeof(ac_int64) != 8)
24354     return 0;                   /* doesn't look like the right size */
24355
24356   c = a * b;
24357   snprintf(buf, 100, INT64_FORMAT, c);
24358   if (strcmp(buf, "800000140000005") != 0)
24359     return 0;                   /* either multiply or snprintf is busted */
24360   return 1;
24361 }
24362 main() {
24363   exit(! does_int64_snprintf_work());
24364 }
24365 _ACEOF
24366 rm -f conftest$ac_exeext
24367 if { (ac_try="$ac_link"
24368 case "(($ac_try" in
24369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24370   *) ac_try_echo=$ac_try;;
24371 esac
24372 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24373 $as_echo "$ac_try_echo") >&5
24374   (eval "$ac_link") 2>&5
24375   ac_status=$?
24376   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24377   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24378   { (case "(($ac_try" in
24379   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24380   *) ac_try_echo=$ac_try;;
24381 esac
24382 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24383 $as_echo "$ac_try_echo") >&5
24384   (eval "$ac_try") 2>&5
24385   ac_status=$?
24386   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24387   (exit $ac_status); }; }; then
24388   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
24389 else
24390   $as_echo "$as_me: program exited with status $ac_status" >&5
24391 $as_echo "$as_me: failed program was:" >&5
24392 sed 's/^/| /' conftest.$ac_ext >&5
24393
24394 fi
24395 rm -rf conftest.dSYM
24396 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24397 fi
24398
24399
24400 done
24401 fi
24402
24403 LONG_LONG_INT_FORMAT=''
24404
24405 case $pgac_cv_snprintf_long_long_int_format in
24406   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
24407 $as_echo "cannot test (not on host machine)" >&6; };;
24408   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
24409 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
24410          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
24411   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
24412 $as_echo "none" >&6; };;
24413 esac
24414     if test "$LONG_LONG_INT_FORMAT" = ""; then
24415       # Force usage of our own snprintf, since system snprintf is broken
24416       pgac_need_repl_snprintf=yes
24417       LONG_LONG_INT_FORMAT='%lld'
24418     fi
24419   else
24420     # Here if we previously decided we needed to use our own snprintf
24421     LONG_LONG_INT_FORMAT='%lld'
24422   fi
24423   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
24424   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
24425   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
24426 else
24427   # Here if we are not using 'long long int' at all
24428   INT64_FORMAT='"%ld"'
24429   UINT64_FORMAT='"%lu"'
24430 fi
24431
24432
24433 cat >>confdefs.h <<_ACEOF
24434 #define INT64_FORMAT $INT64_FORMAT
24435 _ACEOF
24436
24437
24438
24439 cat >>confdefs.h <<_ACEOF
24440 #define UINT64_FORMAT $UINT64_FORMAT
24441 _ACEOF
24442
24443
24444 # Now we have checked all the reasons to replace snprintf
24445 if test $pgac_need_repl_snprintf = yes; then
24446
24447 cat >>confdefs.h <<\_ACEOF
24448 #define USE_REPL_SNPRINTF 1
24449 _ACEOF
24450
24451   case " $LIBOBJS " in
24452   *" snprintf.$ac_objext "* ) ;;
24453   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
24454  ;;
24455 esac
24456
24457 fi
24458
24459 # Check size of void *, size_t (enables tweaks for > 32bit address space)
24460 # The cast to long int works around a bug in the HP C Compiler
24461 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24462 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24463 # This bug is HP SR number 8606223364.
24464 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
24465 $as_echo_n "checking size of void *... " >&6; }
24466 if test "${ac_cv_sizeof_void_p+set}" = set; then
24467   $as_echo_n "(cached) " >&6
24468 else
24469   if test "$cross_compiling" = yes; then
24470   # Depending upon the size, compute the lo and hi bounds.
24471 cat >conftest.$ac_ext <<_ACEOF
24472 /* confdefs.h.  */
24473 _ACEOF
24474 cat confdefs.h >>conftest.$ac_ext
24475 cat >>conftest.$ac_ext <<_ACEOF
24476 /* end confdefs.h.  */
24477 $ac_includes_default
24478 int
24479 main ()
24480 {
24481 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
24482 test_array [0] = 0
24483
24484   ;
24485   return 0;
24486 }
24487 _ACEOF
24488 rm -f conftest.$ac_objext
24489 if { (ac_try="$ac_compile"
24490 case "(($ac_try" in
24491   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24492   *) ac_try_echo=$ac_try;;
24493 esac
24494 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24495 $as_echo "$ac_try_echo") >&5
24496   (eval "$ac_compile") 2>conftest.er1
24497   ac_status=$?
24498   grep -v '^ *+' conftest.er1 >conftest.err
24499   rm -f conftest.er1
24500   cat conftest.err >&5
24501   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24502   (exit $ac_status); } && {
24503          test -z "$ac_c_werror_flag" ||
24504          test ! -s conftest.err
24505        } && test -s conftest.$ac_objext; then
24506   ac_lo=0 ac_mid=0
24507   while :; do
24508     cat >conftest.$ac_ext <<_ACEOF
24509 /* confdefs.h.  */
24510 _ACEOF
24511 cat confdefs.h >>conftest.$ac_ext
24512 cat >>conftest.$ac_ext <<_ACEOF
24513 /* end confdefs.h.  */
24514 $ac_includes_default
24515 int
24516 main ()
24517 {
24518 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24519 test_array [0] = 0
24520
24521   ;
24522   return 0;
24523 }
24524 _ACEOF
24525 rm -f conftest.$ac_objext
24526 if { (ac_try="$ac_compile"
24527 case "(($ac_try" in
24528   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24529   *) ac_try_echo=$ac_try;;
24530 esac
24531 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24532 $as_echo "$ac_try_echo") >&5
24533   (eval "$ac_compile") 2>conftest.er1
24534   ac_status=$?
24535   grep -v '^ *+' conftest.er1 >conftest.err
24536   rm -f conftest.er1
24537   cat conftest.err >&5
24538   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24539   (exit $ac_status); } && {
24540          test -z "$ac_c_werror_flag" ||
24541          test ! -s conftest.err
24542        } && test -s conftest.$ac_objext; then
24543   ac_hi=$ac_mid; break
24544 else
24545   $as_echo "$as_me: failed program was:" >&5
24546 sed 's/^/| /' conftest.$ac_ext >&5
24547
24548         ac_lo=`expr $ac_mid + 1`
24549                         if test $ac_lo -le $ac_mid; then
24550                           ac_lo= ac_hi=
24551                           break
24552                         fi
24553                         ac_mid=`expr 2 '*' $ac_mid + 1`
24554 fi
24555
24556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24557   done
24558 else
24559   $as_echo "$as_me: failed program was:" >&5
24560 sed 's/^/| /' conftest.$ac_ext >&5
24561
24562         cat >conftest.$ac_ext <<_ACEOF
24563 /* confdefs.h.  */
24564 _ACEOF
24565 cat confdefs.h >>conftest.$ac_ext
24566 cat >>conftest.$ac_ext <<_ACEOF
24567 /* end confdefs.h.  */
24568 $ac_includes_default
24569 int
24570 main ()
24571 {
24572 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
24573 test_array [0] = 0
24574
24575   ;
24576   return 0;
24577 }
24578 _ACEOF
24579 rm -f conftest.$ac_objext
24580 if { (ac_try="$ac_compile"
24581 case "(($ac_try" in
24582   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24583   *) ac_try_echo=$ac_try;;
24584 esac
24585 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24586 $as_echo "$ac_try_echo") >&5
24587   (eval "$ac_compile") 2>conftest.er1
24588   ac_status=$?
24589   grep -v '^ *+' conftest.er1 >conftest.err
24590   rm -f conftest.er1
24591   cat conftest.err >&5
24592   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24593   (exit $ac_status); } && {
24594          test -z "$ac_c_werror_flag" ||
24595          test ! -s conftest.err
24596        } && test -s conftest.$ac_objext; then
24597   ac_hi=-1 ac_mid=-1
24598   while :; do
24599     cat >conftest.$ac_ext <<_ACEOF
24600 /* confdefs.h.  */
24601 _ACEOF
24602 cat confdefs.h >>conftest.$ac_ext
24603 cat >>conftest.$ac_ext <<_ACEOF
24604 /* end confdefs.h.  */
24605 $ac_includes_default
24606 int
24607 main ()
24608 {
24609 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
24610 test_array [0] = 0
24611
24612   ;
24613   return 0;
24614 }
24615 _ACEOF
24616 rm -f conftest.$ac_objext
24617 if { (ac_try="$ac_compile"
24618 case "(($ac_try" in
24619   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24620   *) ac_try_echo=$ac_try;;
24621 esac
24622 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24623 $as_echo "$ac_try_echo") >&5
24624   (eval "$ac_compile") 2>conftest.er1
24625   ac_status=$?
24626   grep -v '^ *+' conftest.er1 >conftest.err
24627   rm -f conftest.er1
24628   cat conftest.err >&5
24629   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24630   (exit $ac_status); } && {
24631          test -z "$ac_c_werror_flag" ||
24632          test ! -s conftest.err
24633        } && test -s conftest.$ac_objext; then
24634   ac_lo=$ac_mid; break
24635 else
24636   $as_echo "$as_me: failed program was:" >&5
24637 sed 's/^/| /' conftest.$ac_ext >&5
24638
24639         ac_hi=`expr '(' $ac_mid ')' - 1`
24640                         if test $ac_mid -le $ac_hi; then
24641                           ac_lo= ac_hi=
24642                           break
24643                         fi
24644                         ac_mid=`expr 2 '*' $ac_mid`
24645 fi
24646
24647 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24648   done
24649 else
24650   $as_echo "$as_me: failed program was:" >&5
24651 sed 's/^/| /' conftest.$ac_ext >&5
24652
24653         ac_lo= ac_hi=
24654 fi
24655
24656 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24657 fi
24658
24659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24660 # Binary search between lo and hi bounds.
24661 while test "x$ac_lo" != "x$ac_hi"; do
24662   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24663   cat >conftest.$ac_ext <<_ACEOF
24664 /* confdefs.h.  */
24665 _ACEOF
24666 cat confdefs.h >>conftest.$ac_ext
24667 cat >>conftest.$ac_ext <<_ACEOF
24668 /* end confdefs.h.  */
24669 $ac_includes_default
24670 int
24671 main ()
24672 {
24673 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24674 test_array [0] = 0
24675
24676   ;
24677   return 0;
24678 }
24679 _ACEOF
24680 rm -f conftest.$ac_objext
24681 if { (ac_try="$ac_compile"
24682 case "(($ac_try" in
24683   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24684   *) ac_try_echo=$ac_try;;
24685 esac
24686 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24687 $as_echo "$ac_try_echo") >&5
24688   (eval "$ac_compile") 2>conftest.er1
24689   ac_status=$?
24690   grep -v '^ *+' conftest.er1 >conftest.err
24691   rm -f conftest.er1
24692   cat conftest.err >&5
24693   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24694   (exit $ac_status); } && {
24695          test -z "$ac_c_werror_flag" ||
24696          test ! -s conftest.err
24697        } && test -s conftest.$ac_objext; then
24698   ac_hi=$ac_mid
24699 else
24700   $as_echo "$as_me: failed program was:" >&5
24701 sed 's/^/| /' conftest.$ac_ext >&5
24702
24703         ac_lo=`expr '(' $ac_mid ')' + 1`
24704 fi
24705
24706 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24707 done
24708 case $ac_lo in
24709 ?*) ac_cv_sizeof_void_p=$ac_lo;;
24710 '') if test "$ac_cv_type_void_p" = yes; then
24711      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24712 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24713 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24714 See \`config.log' for more details." >&5
24715 $as_echo "$as_me: error: cannot compute sizeof (void *)
24716 See \`config.log' for more details." >&2;}
24717    { (exit 77); exit 77; }; }; }
24718    else
24719      ac_cv_sizeof_void_p=0
24720    fi ;;
24721 esac
24722 else
24723   cat >conftest.$ac_ext <<_ACEOF
24724 /* confdefs.h.  */
24725 _ACEOF
24726 cat confdefs.h >>conftest.$ac_ext
24727 cat >>conftest.$ac_ext <<_ACEOF
24728 /* end confdefs.h.  */
24729 $ac_includes_default
24730 static long int longval () { return (long int) (sizeof (void *)); }
24731 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
24732 #include <stdio.h>
24733 #include <stdlib.h>
24734 int
24735 main ()
24736 {
24737
24738   FILE *f = fopen ("conftest.val", "w");
24739   if (! f)
24740     return 1;
24741   if (((long int) (sizeof (void *))) < 0)
24742     {
24743       long int i = longval ();
24744       if (i != ((long int) (sizeof (void *))))
24745         return 1;
24746       fprintf (f, "%ld", i);
24747     }
24748   else
24749     {
24750       unsigned long int i = ulongval ();
24751       if (i != ((long int) (sizeof (void *))))
24752         return 1;
24753       fprintf (f, "%lu", i);
24754     }
24755   /* Do not output a trailing newline, as this causes \r\n confusion
24756      on some platforms.  */
24757   return ferror (f) || fclose (f) != 0;
24758
24759   ;
24760   return 0;
24761 }
24762 _ACEOF
24763 rm -f conftest$ac_exeext
24764 if { (ac_try="$ac_link"
24765 case "(($ac_try" in
24766   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24767   *) ac_try_echo=$ac_try;;
24768 esac
24769 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24770 $as_echo "$ac_try_echo") >&5
24771   (eval "$ac_link") 2>&5
24772   ac_status=$?
24773   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24774   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24775   { (case "(($ac_try" in
24776   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24777   *) ac_try_echo=$ac_try;;
24778 esac
24779 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24780 $as_echo "$ac_try_echo") >&5
24781   (eval "$ac_try") 2>&5
24782   ac_status=$?
24783   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24784   (exit $ac_status); }; }; then
24785   ac_cv_sizeof_void_p=`cat conftest.val`
24786 else
24787   $as_echo "$as_me: program exited with status $ac_status" >&5
24788 $as_echo "$as_me: failed program was:" >&5
24789 sed 's/^/| /' conftest.$ac_ext >&5
24790
24791 ( exit $ac_status )
24792 if test "$ac_cv_type_void_p" = yes; then
24793      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24794 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24795 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24796 See \`config.log' for more details." >&5
24797 $as_echo "$as_me: error: cannot compute sizeof (void *)
24798 See \`config.log' for more details." >&2;}
24799    { (exit 77); exit 77; }; }; }
24800    else
24801      ac_cv_sizeof_void_p=0
24802    fi
24803 fi
24804 rm -rf conftest.dSYM
24805 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24806 fi
24807 rm -f conftest.val
24808 fi
24809 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
24810 $as_echo "$ac_cv_sizeof_void_p" >&6; }
24811
24812
24813
24814 cat >>confdefs.h <<_ACEOF
24815 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
24816 _ACEOF
24817
24818
24819 # The cast to long int works around a bug in the HP C Compiler
24820 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24821 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24822 # This bug is HP SR number 8606223364.
24823 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
24824 $as_echo_n "checking size of size_t... " >&6; }
24825 if test "${ac_cv_sizeof_size_t+set}" = set; then
24826   $as_echo_n "(cached) " >&6
24827 else
24828   if test "$cross_compiling" = yes; then
24829   # Depending upon the size, compute the lo and hi bounds.
24830 cat >conftest.$ac_ext <<_ACEOF
24831 /* confdefs.h.  */
24832 _ACEOF
24833 cat confdefs.h >>conftest.$ac_ext
24834 cat >>conftest.$ac_ext <<_ACEOF
24835 /* end confdefs.h.  */
24836 $ac_includes_default
24837 int
24838 main ()
24839 {
24840 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
24841 test_array [0] = 0
24842
24843   ;
24844   return 0;
24845 }
24846 _ACEOF
24847 rm -f conftest.$ac_objext
24848 if { (ac_try="$ac_compile"
24849 case "(($ac_try" in
24850   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24851   *) ac_try_echo=$ac_try;;
24852 esac
24853 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24854 $as_echo "$ac_try_echo") >&5
24855   (eval "$ac_compile") 2>conftest.er1
24856   ac_status=$?
24857   grep -v '^ *+' conftest.er1 >conftest.err
24858   rm -f conftest.er1
24859   cat conftest.err >&5
24860   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24861   (exit $ac_status); } && {
24862          test -z "$ac_c_werror_flag" ||
24863          test ! -s conftest.err
24864        } && test -s conftest.$ac_objext; then
24865   ac_lo=0 ac_mid=0
24866   while :; do
24867     cat >conftest.$ac_ext <<_ACEOF
24868 /* confdefs.h.  */
24869 _ACEOF
24870 cat confdefs.h >>conftest.$ac_ext
24871 cat >>conftest.$ac_ext <<_ACEOF
24872 /* end confdefs.h.  */
24873 $ac_includes_default
24874 int
24875 main ()
24876 {
24877 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24878 test_array [0] = 0
24879
24880   ;
24881   return 0;
24882 }
24883 _ACEOF
24884 rm -f conftest.$ac_objext
24885 if { (ac_try="$ac_compile"
24886 case "(($ac_try" in
24887   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24888   *) ac_try_echo=$ac_try;;
24889 esac
24890 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24891 $as_echo "$ac_try_echo") >&5
24892   (eval "$ac_compile") 2>conftest.er1
24893   ac_status=$?
24894   grep -v '^ *+' conftest.er1 >conftest.err
24895   rm -f conftest.er1
24896   cat conftest.err >&5
24897   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24898   (exit $ac_status); } && {
24899          test -z "$ac_c_werror_flag" ||
24900          test ! -s conftest.err
24901        } && test -s conftest.$ac_objext; then
24902   ac_hi=$ac_mid; break
24903 else
24904   $as_echo "$as_me: failed program was:" >&5
24905 sed 's/^/| /' conftest.$ac_ext >&5
24906
24907         ac_lo=`expr $ac_mid + 1`
24908                         if test $ac_lo -le $ac_mid; then
24909                           ac_lo= ac_hi=
24910                           break
24911                         fi
24912                         ac_mid=`expr 2 '*' $ac_mid + 1`
24913 fi
24914
24915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24916   done
24917 else
24918   $as_echo "$as_me: failed program was:" >&5
24919 sed 's/^/| /' conftest.$ac_ext >&5
24920
24921         cat >conftest.$ac_ext <<_ACEOF
24922 /* confdefs.h.  */
24923 _ACEOF
24924 cat confdefs.h >>conftest.$ac_ext
24925 cat >>conftest.$ac_ext <<_ACEOF
24926 /* end confdefs.h.  */
24927 $ac_includes_default
24928 int
24929 main ()
24930 {
24931 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
24932 test_array [0] = 0
24933
24934   ;
24935   return 0;
24936 }
24937 _ACEOF
24938 rm -f conftest.$ac_objext
24939 if { (ac_try="$ac_compile"
24940 case "(($ac_try" in
24941   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24942   *) ac_try_echo=$ac_try;;
24943 esac
24944 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24945 $as_echo "$ac_try_echo") >&5
24946   (eval "$ac_compile") 2>conftest.er1
24947   ac_status=$?
24948   grep -v '^ *+' conftest.er1 >conftest.err
24949   rm -f conftest.er1
24950   cat conftest.err >&5
24951   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24952   (exit $ac_status); } && {
24953          test -z "$ac_c_werror_flag" ||
24954          test ! -s conftest.err
24955        } && test -s conftest.$ac_objext; then
24956   ac_hi=-1 ac_mid=-1
24957   while :; do
24958     cat >conftest.$ac_ext <<_ACEOF
24959 /* confdefs.h.  */
24960 _ACEOF
24961 cat confdefs.h >>conftest.$ac_ext
24962 cat >>conftest.$ac_ext <<_ACEOF
24963 /* end confdefs.h.  */
24964 $ac_includes_default
24965 int
24966 main ()
24967 {
24968 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
24969 test_array [0] = 0
24970
24971   ;
24972   return 0;
24973 }
24974 _ACEOF
24975 rm -f conftest.$ac_objext
24976 if { (ac_try="$ac_compile"
24977 case "(($ac_try" in
24978   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24979   *) ac_try_echo=$ac_try;;
24980 esac
24981 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24982 $as_echo "$ac_try_echo") >&5
24983   (eval "$ac_compile") 2>conftest.er1
24984   ac_status=$?
24985   grep -v '^ *+' conftest.er1 >conftest.err
24986   rm -f conftest.er1
24987   cat conftest.err >&5
24988   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24989   (exit $ac_status); } && {
24990          test -z "$ac_c_werror_flag" ||
24991          test ! -s conftest.err
24992        } && test -s conftest.$ac_objext; then
24993   ac_lo=$ac_mid; break
24994 else
24995   $as_echo "$as_me: failed program was:" >&5
24996 sed 's/^/| /' conftest.$ac_ext >&5
24997
24998         ac_hi=`expr '(' $ac_mid ')' - 1`
24999                         if test $ac_mid -le $ac_hi; then
25000                           ac_lo= ac_hi=
25001                           break
25002                         fi
25003                         ac_mid=`expr 2 '*' $ac_mid`
25004 fi
25005
25006 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25007   done
25008 else
25009   $as_echo "$as_me: failed program was:" >&5
25010 sed 's/^/| /' conftest.$ac_ext >&5
25011
25012         ac_lo= ac_hi=
25013 fi
25014
25015 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25016 fi
25017
25018 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25019 # Binary search between lo and hi bounds.
25020 while test "x$ac_lo" != "x$ac_hi"; do
25021   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25022   cat >conftest.$ac_ext <<_ACEOF
25023 /* confdefs.h.  */
25024 _ACEOF
25025 cat confdefs.h >>conftest.$ac_ext
25026 cat >>conftest.$ac_ext <<_ACEOF
25027 /* end confdefs.h.  */
25028 $ac_includes_default
25029 int
25030 main ()
25031 {
25032 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
25033 test_array [0] = 0
25034
25035   ;
25036   return 0;
25037 }
25038 _ACEOF
25039 rm -f conftest.$ac_objext
25040 if { (ac_try="$ac_compile"
25041 case "(($ac_try" in
25042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25043   *) ac_try_echo=$ac_try;;
25044 esac
25045 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25046 $as_echo "$ac_try_echo") >&5
25047   (eval "$ac_compile") 2>conftest.er1
25048   ac_status=$?
25049   grep -v '^ *+' conftest.er1 >conftest.err
25050   rm -f conftest.er1
25051   cat conftest.err >&5
25052   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25053   (exit $ac_status); } && {
25054          test -z "$ac_c_werror_flag" ||
25055          test ! -s conftest.err
25056        } && test -s conftest.$ac_objext; then
25057   ac_hi=$ac_mid
25058 else
25059   $as_echo "$as_me: failed program was:" >&5
25060 sed 's/^/| /' conftest.$ac_ext >&5
25061
25062         ac_lo=`expr '(' $ac_mid ')' + 1`
25063 fi
25064
25065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25066 done
25067 case $ac_lo in
25068 ?*) ac_cv_sizeof_size_t=$ac_lo;;
25069 '') if test "$ac_cv_type_size_t" = yes; then
25070      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25071 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25072 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
25073 See \`config.log' for more details." >&5
25074 $as_echo "$as_me: error: cannot compute sizeof (size_t)
25075 See \`config.log' for more details." >&2;}
25076    { (exit 77); exit 77; }; }; }
25077    else
25078      ac_cv_sizeof_size_t=0
25079    fi ;;
25080 esac
25081 else
25082   cat >conftest.$ac_ext <<_ACEOF
25083 /* confdefs.h.  */
25084 _ACEOF
25085 cat confdefs.h >>conftest.$ac_ext
25086 cat >>conftest.$ac_ext <<_ACEOF
25087 /* end confdefs.h.  */
25088 $ac_includes_default
25089 static long int longval () { return (long int) (sizeof (size_t)); }
25090 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
25091 #include <stdio.h>
25092 #include <stdlib.h>
25093 int
25094 main ()
25095 {
25096
25097   FILE *f = fopen ("conftest.val", "w");
25098   if (! f)
25099     return 1;
25100   if (((long int) (sizeof (size_t))) < 0)
25101     {
25102       long int i = longval ();
25103       if (i != ((long int) (sizeof (size_t))))
25104         return 1;
25105       fprintf (f, "%ld", i);
25106     }
25107   else
25108     {
25109       unsigned long int i = ulongval ();
25110       if (i != ((long int) (sizeof (size_t))))
25111         return 1;
25112       fprintf (f, "%lu", i);
25113     }
25114   /* Do not output a trailing newline, as this causes \r\n confusion
25115      on some platforms.  */
25116   return ferror (f) || fclose (f) != 0;
25117
25118   ;
25119   return 0;
25120 }
25121 _ACEOF
25122 rm -f conftest$ac_exeext
25123 if { (ac_try="$ac_link"
25124 case "(($ac_try" in
25125   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25126   *) ac_try_echo=$ac_try;;
25127 esac
25128 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25129 $as_echo "$ac_try_echo") >&5
25130   (eval "$ac_link") 2>&5
25131   ac_status=$?
25132   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25133   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25134   { (case "(($ac_try" in
25135   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25136   *) ac_try_echo=$ac_try;;
25137 esac
25138 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25139 $as_echo "$ac_try_echo") >&5
25140   (eval "$ac_try") 2>&5
25141   ac_status=$?
25142   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25143   (exit $ac_status); }; }; then
25144   ac_cv_sizeof_size_t=`cat conftest.val`
25145 else
25146   $as_echo "$as_me: program exited with status $ac_status" >&5
25147 $as_echo "$as_me: failed program was:" >&5
25148 sed 's/^/| /' conftest.$ac_ext >&5
25149
25150 ( exit $ac_status )
25151 if test "$ac_cv_type_size_t" = yes; then
25152      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25153 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25154 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
25155 See \`config.log' for more details." >&5
25156 $as_echo "$as_me: error: cannot compute sizeof (size_t)
25157 See \`config.log' for more details." >&2;}
25158    { (exit 77); exit 77; }; }; }
25159    else
25160      ac_cv_sizeof_size_t=0
25161    fi
25162 fi
25163 rm -rf conftest.dSYM
25164 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25165 fi
25166 rm -f conftest.val
25167 fi
25168 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
25169 $as_echo "$ac_cv_sizeof_size_t" >&6; }
25170
25171
25172
25173 cat >>confdefs.h <<_ACEOF
25174 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
25175 _ACEOF
25176
25177
25178 # The cast to long int works around a bug in the HP C Compiler
25179 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
25180 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
25181 # This bug is HP SR number 8606223364.
25182 { $as_echo "$as_me:$LINENO: checking size of long" >&5
25183 $as_echo_n "checking size of long... " >&6; }
25184 if test "${ac_cv_sizeof_long+set}" = set; then
25185   $as_echo_n "(cached) " >&6
25186 else
25187   if test "$cross_compiling" = yes; then
25188   # Depending upon the size, compute the lo and hi bounds.
25189 cat >conftest.$ac_ext <<_ACEOF
25190 /* confdefs.h.  */
25191 _ACEOF
25192 cat confdefs.h >>conftest.$ac_ext
25193 cat >>conftest.$ac_ext <<_ACEOF
25194 /* end confdefs.h.  */
25195 $ac_includes_default
25196 int
25197 main ()
25198 {
25199 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
25200 test_array [0] = 0
25201
25202   ;
25203   return 0;
25204 }
25205 _ACEOF
25206 rm -f conftest.$ac_objext
25207 if { (ac_try="$ac_compile"
25208 case "(($ac_try" in
25209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25210   *) ac_try_echo=$ac_try;;
25211 esac
25212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25213 $as_echo "$ac_try_echo") >&5
25214   (eval "$ac_compile") 2>conftest.er1
25215   ac_status=$?
25216   grep -v '^ *+' conftest.er1 >conftest.err
25217   rm -f conftest.er1
25218   cat conftest.err >&5
25219   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25220   (exit $ac_status); } && {
25221          test -z "$ac_c_werror_flag" ||
25222          test ! -s conftest.err
25223        } && test -s conftest.$ac_objext; then
25224   ac_lo=0 ac_mid=0
25225   while :; do
25226     cat >conftest.$ac_ext <<_ACEOF
25227 /* confdefs.h.  */
25228 _ACEOF
25229 cat confdefs.h >>conftest.$ac_ext
25230 cat >>conftest.$ac_ext <<_ACEOF
25231 /* end confdefs.h.  */
25232 $ac_includes_default
25233 int
25234 main ()
25235 {
25236 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25237 test_array [0] = 0
25238
25239   ;
25240   return 0;
25241 }
25242 _ACEOF
25243 rm -f conftest.$ac_objext
25244 if { (ac_try="$ac_compile"
25245 case "(($ac_try" in
25246   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25247   *) ac_try_echo=$ac_try;;
25248 esac
25249 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25250 $as_echo "$ac_try_echo") >&5
25251   (eval "$ac_compile") 2>conftest.er1
25252   ac_status=$?
25253   grep -v '^ *+' conftest.er1 >conftest.err
25254   rm -f conftest.er1
25255   cat conftest.err >&5
25256   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25257   (exit $ac_status); } && {
25258          test -z "$ac_c_werror_flag" ||
25259          test ! -s conftest.err
25260        } && test -s conftest.$ac_objext; then
25261   ac_hi=$ac_mid; break
25262 else
25263   $as_echo "$as_me: failed program was:" >&5
25264 sed 's/^/| /' conftest.$ac_ext >&5
25265
25266         ac_lo=`expr $ac_mid + 1`
25267                         if test $ac_lo -le $ac_mid; then
25268                           ac_lo= ac_hi=
25269                           break
25270                         fi
25271                         ac_mid=`expr 2 '*' $ac_mid + 1`
25272 fi
25273
25274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25275   done
25276 else
25277   $as_echo "$as_me: failed program was:" >&5
25278 sed 's/^/| /' conftest.$ac_ext >&5
25279
25280         cat >conftest.$ac_ext <<_ACEOF
25281 /* confdefs.h.  */
25282 _ACEOF
25283 cat confdefs.h >>conftest.$ac_ext
25284 cat >>conftest.$ac_ext <<_ACEOF
25285 /* end confdefs.h.  */
25286 $ac_includes_default
25287 int
25288 main ()
25289 {
25290 static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
25291 test_array [0] = 0
25292
25293   ;
25294   return 0;
25295 }
25296 _ACEOF
25297 rm -f conftest.$ac_objext
25298 if { (ac_try="$ac_compile"
25299 case "(($ac_try" in
25300   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25301   *) ac_try_echo=$ac_try;;
25302 esac
25303 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25304 $as_echo "$ac_try_echo") >&5
25305   (eval "$ac_compile") 2>conftest.er1
25306   ac_status=$?
25307   grep -v '^ *+' conftest.er1 >conftest.err
25308   rm -f conftest.er1
25309   cat conftest.err >&5
25310   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25311   (exit $ac_status); } && {
25312          test -z "$ac_c_werror_flag" ||
25313          test ! -s conftest.err
25314        } && test -s conftest.$ac_objext; then
25315   ac_hi=-1 ac_mid=-1
25316   while :; do
25317     cat >conftest.$ac_ext <<_ACEOF
25318 /* confdefs.h.  */
25319 _ACEOF
25320 cat confdefs.h >>conftest.$ac_ext
25321 cat >>conftest.$ac_ext <<_ACEOF
25322 /* end confdefs.h.  */
25323 $ac_includes_default
25324 int
25325 main ()
25326 {
25327 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
25328 test_array [0] = 0
25329
25330   ;
25331   return 0;
25332 }
25333 _ACEOF
25334 rm -f conftest.$ac_objext
25335 if { (ac_try="$ac_compile"
25336 case "(($ac_try" in
25337   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25338   *) ac_try_echo=$ac_try;;
25339 esac
25340 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25341 $as_echo "$ac_try_echo") >&5
25342   (eval "$ac_compile") 2>conftest.er1
25343   ac_status=$?
25344   grep -v '^ *+' conftest.er1 >conftest.err
25345   rm -f conftest.er1
25346   cat conftest.err >&5
25347   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25348   (exit $ac_status); } && {
25349          test -z "$ac_c_werror_flag" ||
25350          test ! -s conftest.err
25351        } && test -s conftest.$ac_objext; then
25352   ac_lo=$ac_mid; break
25353 else
25354   $as_echo "$as_me: failed program was:" >&5
25355 sed 's/^/| /' conftest.$ac_ext >&5
25356
25357         ac_hi=`expr '(' $ac_mid ')' - 1`
25358                         if test $ac_mid -le $ac_hi; then
25359                           ac_lo= ac_hi=
25360                           break
25361                         fi
25362                         ac_mid=`expr 2 '*' $ac_mid`
25363 fi
25364
25365 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25366   done
25367 else
25368   $as_echo "$as_me: failed program was:" >&5
25369 sed 's/^/| /' conftest.$ac_ext >&5
25370
25371         ac_lo= ac_hi=
25372 fi
25373
25374 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25375 fi
25376
25377 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25378 # Binary search between lo and hi bounds.
25379 while test "x$ac_lo" != "x$ac_hi"; do
25380   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25381   cat >conftest.$ac_ext <<_ACEOF
25382 /* confdefs.h.  */
25383 _ACEOF
25384 cat confdefs.h >>conftest.$ac_ext
25385 cat >>conftest.$ac_ext <<_ACEOF
25386 /* end confdefs.h.  */
25387 $ac_includes_default
25388 int
25389 main ()
25390 {
25391 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25392 test_array [0] = 0
25393
25394   ;
25395   return 0;
25396 }
25397 _ACEOF
25398 rm -f conftest.$ac_objext
25399 if { (ac_try="$ac_compile"
25400 case "(($ac_try" in
25401   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25402   *) ac_try_echo=$ac_try;;
25403 esac
25404 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25405 $as_echo "$ac_try_echo") >&5
25406   (eval "$ac_compile") 2>conftest.er1
25407   ac_status=$?
25408   grep -v '^ *+' conftest.er1 >conftest.err
25409   rm -f conftest.er1
25410   cat conftest.err >&5
25411   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25412   (exit $ac_status); } && {
25413          test -z "$ac_c_werror_flag" ||
25414          test ! -s conftest.err
25415        } && test -s conftest.$ac_objext; then
25416   ac_hi=$ac_mid
25417 else
25418   $as_echo "$as_me: failed program was:" >&5
25419 sed 's/^/| /' conftest.$ac_ext >&5
25420
25421         ac_lo=`expr '(' $ac_mid ')' + 1`
25422 fi
25423
25424 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25425 done
25426 case $ac_lo in
25427 ?*) ac_cv_sizeof_long=$ac_lo;;
25428 '') if test "$ac_cv_type_long" = yes; then
25429      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25430 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25431 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25432 See \`config.log' for more details." >&5
25433 $as_echo "$as_me: error: cannot compute sizeof (long)
25434 See \`config.log' for more details." >&2;}
25435    { (exit 77); exit 77; }; }; }
25436    else
25437      ac_cv_sizeof_long=0
25438    fi ;;
25439 esac
25440 else
25441   cat >conftest.$ac_ext <<_ACEOF
25442 /* confdefs.h.  */
25443 _ACEOF
25444 cat confdefs.h >>conftest.$ac_ext
25445 cat >>conftest.$ac_ext <<_ACEOF
25446 /* end confdefs.h.  */
25447 $ac_includes_default
25448 static long int longval () { return (long int) (sizeof (long)); }
25449 static unsigned long int ulongval () { return (long int) (sizeof (long)); }
25450 #include <stdio.h>
25451 #include <stdlib.h>
25452 int
25453 main ()
25454 {
25455
25456   FILE *f = fopen ("conftest.val", "w");
25457   if (! f)
25458     return 1;
25459   if (((long int) (sizeof (long))) < 0)
25460     {
25461       long int i = longval ();
25462       if (i != ((long int) (sizeof (long))))
25463         return 1;
25464       fprintf (f, "%ld", i);
25465     }
25466   else
25467     {
25468       unsigned long int i = ulongval ();
25469       if (i != ((long int) (sizeof (long))))
25470         return 1;
25471       fprintf (f, "%lu", i);
25472     }
25473   /* Do not output a trailing newline, as this causes \r\n confusion
25474      on some platforms.  */
25475   return ferror (f) || fclose (f) != 0;
25476
25477   ;
25478   return 0;
25479 }
25480 _ACEOF
25481 rm -f conftest$ac_exeext
25482 if { (ac_try="$ac_link"
25483 case "(($ac_try" in
25484   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25485   *) ac_try_echo=$ac_try;;
25486 esac
25487 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25488 $as_echo "$ac_try_echo") >&5
25489   (eval "$ac_link") 2>&5
25490   ac_status=$?
25491   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25492   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25493   { (case "(($ac_try" in
25494   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25495   *) ac_try_echo=$ac_try;;
25496 esac
25497 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25498 $as_echo "$ac_try_echo") >&5
25499   (eval "$ac_try") 2>&5
25500   ac_status=$?
25501   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25502   (exit $ac_status); }; }; then
25503   ac_cv_sizeof_long=`cat conftest.val`
25504 else
25505   $as_echo "$as_me: program exited with status $ac_status" >&5
25506 $as_echo "$as_me: failed program was:" >&5
25507 sed 's/^/| /' conftest.$ac_ext >&5
25508
25509 ( exit $ac_status )
25510 if test "$ac_cv_type_long" = yes; then
25511      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25512 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25513 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25514 See \`config.log' for more details." >&5
25515 $as_echo "$as_me: error: cannot compute sizeof (long)
25516 See \`config.log' for more details." >&2;}
25517    { (exit 77); exit 77; }; }; }
25518    else
25519      ac_cv_sizeof_long=0
25520    fi
25521 fi
25522 rm -rf conftest.dSYM
25523 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25524 fi
25525 rm -f conftest.val
25526 fi
25527 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
25528 $as_echo "$ac_cv_sizeof_long" >&6; }
25529
25530
25531
25532 cat >>confdefs.h <<_ACEOF
25533 #define SIZEOF_LONG $ac_cv_sizeof_long
25534 _ACEOF
25535
25536
25537
25538 # Decide whether float4 is passed by value: user-selectable, enabled by default
25539 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
25540 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
25541
25542
25543 # Check whether --enable-float4-byval was given.
25544 if test "${enable_float4_byval+set}" = set; then
25545   enableval=$enable_float4_byval;
25546   case $enableval in
25547     yes)
25548
25549 cat >>confdefs.h <<\_ACEOF
25550 #define USE_FLOAT4_BYVAL 1
25551 _ACEOF
25552
25553                float4passbyval=true
25554       ;;
25555     no)
25556       float4passbyval=false
25557       ;;
25558     *)
25559       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
25560 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
25561    { (exit 1); exit 1; }; }
25562       ;;
25563   esac
25564
25565 else
25566   enable_float4_byval=yes
25567
25568 cat >>confdefs.h <<\_ACEOF
25569 #define USE_FLOAT4_BYVAL 1
25570 _ACEOF
25571
25572                float4passbyval=true
25573 fi
25574
25575
25576 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
25577 $as_echo "$enable_float4_byval" >&6; }
25578
25579 cat >>confdefs.h <<_ACEOF
25580 #define FLOAT4PASSBYVAL $float4passbyval
25581 _ACEOF
25582
25583
25584 # Decide whether float8 is passed by value.
25585 # Note: this setting also controls int8 and related types such as timestamp.
25586 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
25587 # If not, trying to select it is an error.
25588 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
25589 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
25590 if test $ac_cv_sizeof_void_p -ge 8 ; then
25591
25592
25593 # Check whether --enable-float8-byval was given.
25594 if test "${enable_float8_byval+set}" = set; then
25595   enableval=$enable_float8_byval;
25596   case $enableval in
25597     yes)
25598       :
25599       ;;
25600     no)
25601       :
25602       ;;
25603     *)
25604       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25605 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25606    { (exit 1); exit 1; }; }
25607       ;;
25608   esac
25609
25610 else
25611   enable_float8_byval=yes
25612
25613 fi
25614
25615
25616 else
25617
25618
25619 # Check whether --enable-float8-byval was given.
25620 if test "${enable_float8_byval+set}" = set; then
25621   enableval=$enable_float8_byval;
25622   case $enableval in
25623     yes)
25624       :
25625       ;;
25626     no)
25627       :
25628       ;;
25629     *)
25630       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25631 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25632    { (exit 1); exit 1; }; }
25633       ;;
25634   esac
25635
25636 else
25637   enable_float8_byval=no
25638
25639 fi
25640
25641
25642   if test "$enable_float8_byval" = yes ; then
25643     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
25644 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
25645    { (exit 1); exit 1; }; }
25646   fi
25647 fi
25648 if test "$enable_float8_byval" = yes ; then
25649
25650 cat >>confdefs.h <<\_ACEOF
25651 #define USE_FLOAT8_BYVAL 1
25652 _ACEOF
25653
25654   float8passbyval=true
25655 else
25656   float8passbyval=false
25657 fi
25658 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
25659 $as_echo "$enable_float8_byval" >&6; }
25660
25661 cat >>confdefs.h <<_ACEOF
25662 #define FLOAT8PASSBYVAL $float8passbyval
25663 _ACEOF
25664
25665
25666 # Determine memory alignment requirements for the basic C data types.
25667
25668 # The cast to long int works around a bug in the HP C Compiler,
25669 # see AC_CHECK_SIZEOF for more information.
25670 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
25671 $as_echo_n "checking alignment of short... " >&6; }
25672 if test "${ac_cv_alignof_short+set}" = set; then
25673   $as_echo_n "(cached) " >&6
25674 else
25675   if test "$cross_compiling" = yes; then
25676   # Depending upon the size, compute the lo and hi bounds.
25677 cat >conftest.$ac_ext <<_ACEOF
25678 /* confdefs.h.  */
25679 _ACEOF
25680 cat confdefs.h >>conftest.$ac_ext
25681 cat >>conftest.$ac_ext <<_ACEOF
25682 /* end confdefs.h.  */
25683 $ac_includes_default
25684 #ifndef offsetof
25685 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25686 #endif
25687 typedef struct { char x; short y; } ac__type_alignof_;
25688 int
25689 main ()
25690 {
25691 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25692 test_array [0] = 0
25693
25694   ;
25695   return 0;
25696 }
25697 _ACEOF
25698 rm -f conftest.$ac_objext
25699 if { (ac_try="$ac_compile"
25700 case "(($ac_try" in
25701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25702   *) ac_try_echo=$ac_try;;
25703 esac
25704 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25705 $as_echo "$ac_try_echo") >&5
25706   (eval "$ac_compile") 2>conftest.er1
25707   ac_status=$?
25708   grep -v '^ *+' conftest.er1 >conftest.err
25709   rm -f conftest.er1
25710   cat conftest.err >&5
25711   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25712   (exit $ac_status); } && {
25713          test -z "$ac_c_werror_flag" ||
25714          test ! -s conftest.err
25715        } && test -s conftest.$ac_objext; then
25716   ac_lo=0 ac_mid=0
25717   while :; do
25718     cat >conftest.$ac_ext <<_ACEOF
25719 /* confdefs.h.  */
25720 _ACEOF
25721 cat confdefs.h >>conftest.$ac_ext
25722 cat >>conftest.$ac_ext <<_ACEOF
25723 /* end confdefs.h.  */
25724 $ac_includes_default
25725 #ifndef offsetof
25726 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25727 #endif
25728 typedef struct { char x; short y; } ac__type_alignof_;
25729 int
25730 main ()
25731 {
25732 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25733 test_array [0] = 0
25734
25735   ;
25736   return 0;
25737 }
25738 _ACEOF
25739 rm -f conftest.$ac_objext
25740 if { (ac_try="$ac_compile"
25741 case "(($ac_try" in
25742   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25743   *) ac_try_echo=$ac_try;;
25744 esac
25745 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25746 $as_echo "$ac_try_echo") >&5
25747   (eval "$ac_compile") 2>conftest.er1
25748   ac_status=$?
25749   grep -v '^ *+' conftest.er1 >conftest.err
25750   rm -f conftest.er1
25751   cat conftest.err >&5
25752   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25753   (exit $ac_status); } && {
25754          test -z "$ac_c_werror_flag" ||
25755          test ! -s conftest.err
25756        } && test -s conftest.$ac_objext; then
25757   ac_hi=$ac_mid; break
25758 else
25759   $as_echo "$as_me: failed program was:" >&5
25760 sed 's/^/| /' conftest.$ac_ext >&5
25761
25762         ac_lo=`expr $ac_mid + 1`
25763                         if test $ac_lo -le $ac_mid; then
25764                           ac_lo= ac_hi=
25765                           break
25766                         fi
25767                         ac_mid=`expr 2 '*' $ac_mid + 1`
25768 fi
25769
25770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25771   done
25772 else
25773   $as_echo "$as_me: failed program was:" >&5
25774 sed 's/^/| /' conftest.$ac_ext >&5
25775
25776         cat >conftest.$ac_ext <<_ACEOF
25777 /* confdefs.h.  */
25778 _ACEOF
25779 cat confdefs.h >>conftest.$ac_ext
25780 cat >>conftest.$ac_ext <<_ACEOF
25781 /* end confdefs.h.  */
25782 $ac_includes_default
25783 #ifndef offsetof
25784 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25785 #endif
25786 typedef struct { char x; short y; } ac__type_alignof_;
25787 int
25788 main ()
25789 {
25790 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25791 test_array [0] = 0
25792
25793   ;
25794   return 0;
25795 }
25796 _ACEOF
25797 rm -f conftest.$ac_objext
25798 if { (ac_try="$ac_compile"
25799 case "(($ac_try" in
25800   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25801   *) ac_try_echo=$ac_try;;
25802 esac
25803 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25804 $as_echo "$ac_try_echo") >&5
25805   (eval "$ac_compile") 2>conftest.er1
25806   ac_status=$?
25807   grep -v '^ *+' conftest.er1 >conftest.err
25808   rm -f conftest.er1
25809   cat conftest.err >&5
25810   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25811   (exit $ac_status); } && {
25812          test -z "$ac_c_werror_flag" ||
25813          test ! -s conftest.err
25814        } && test -s conftest.$ac_objext; then
25815   ac_hi=-1 ac_mid=-1
25816   while :; do
25817     cat >conftest.$ac_ext <<_ACEOF
25818 /* confdefs.h.  */
25819 _ACEOF
25820 cat confdefs.h >>conftest.$ac_ext
25821 cat >>conftest.$ac_ext <<_ACEOF
25822 /* end confdefs.h.  */
25823 $ac_includes_default
25824 #ifndef offsetof
25825 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25826 #endif
25827 typedef struct { char x; short y; } ac__type_alignof_;
25828 int
25829 main ()
25830 {
25831 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25832 test_array [0] = 0
25833
25834   ;
25835   return 0;
25836 }
25837 _ACEOF
25838 rm -f conftest.$ac_objext
25839 if { (ac_try="$ac_compile"
25840 case "(($ac_try" in
25841   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25842   *) ac_try_echo=$ac_try;;
25843 esac
25844 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25845 $as_echo "$ac_try_echo") >&5
25846   (eval "$ac_compile") 2>conftest.er1
25847   ac_status=$?
25848   grep -v '^ *+' conftest.er1 >conftest.err
25849   rm -f conftest.er1
25850   cat conftest.err >&5
25851   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25852   (exit $ac_status); } && {
25853          test -z "$ac_c_werror_flag" ||
25854          test ! -s conftest.err
25855        } && test -s conftest.$ac_objext; then
25856   ac_lo=$ac_mid; break
25857 else
25858   $as_echo "$as_me: failed program was:" >&5
25859 sed 's/^/| /' conftest.$ac_ext >&5
25860
25861         ac_hi=`expr '(' $ac_mid ')' - 1`
25862                         if test $ac_mid -le $ac_hi; then
25863                           ac_lo= ac_hi=
25864                           break
25865                         fi
25866                         ac_mid=`expr 2 '*' $ac_mid`
25867 fi
25868
25869 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25870   done
25871 else
25872   $as_echo "$as_me: failed program was:" >&5
25873 sed 's/^/| /' conftest.$ac_ext >&5
25874
25875         ac_lo= ac_hi=
25876 fi
25877
25878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25879 fi
25880
25881 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25882 # Binary search between lo and hi bounds.
25883 while test "x$ac_lo" != "x$ac_hi"; do
25884   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25885   cat >conftest.$ac_ext <<_ACEOF
25886 /* confdefs.h.  */
25887 _ACEOF
25888 cat confdefs.h >>conftest.$ac_ext
25889 cat >>conftest.$ac_ext <<_ACEOF
25890 /* end confdefs.h.  */
25891 $ac_includes_default
25892 #ifndef offsetof
25893 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25894 #endif
25895 typedef struct { char x; short y; } ac__type_alignof_;
25896 int
25897 main ()
25898 {
25899 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25900 test_array [0] = 0
25901
25902   ;
25903   return 0;
25904 }
25905 _ACEOF
25906 rm -f conftest.$ac_objext
25907 if { (ac_try="$ac_compile"
25908 case "(($ac_try" in
25909   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25910   *) ac_try_echo=$ac_try;;
25911 esac
25912 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25913 $as_echo "$ac_try_echo") >&5
25914   (eval "$ac_compile") 2>conftest.er1
25915   ac_status=$?
25916   grep -v '^ *+' conftest.er1 >conftest.err
25917   rm -f conftest.er1
25918   cat conftest.err >&5
25919   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25920   (exit $ac_status); } && {
25921          test -z "$ac_c_werror_flag" ||
25922          test ! -s conftest.err
25923        } && test -s conftest.$ac_objext; then
25924   ac_hi=$ac_mid
25925 else
25926   $as_echo "$as_me: failed program was:" >&5
25927 sed 's/^/| /' conftest.$ac_ext >&5
25928
25929         ac_lo=`expr '(' $ac_mid ')' + 1`
25930 fi
25931
25932 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25933 done
25934 case $ac_lo in
25935 ?*) ac_cv_alignof_short=$ac_lo;;
25936 '') if test "$ac_cv_type_short" = yes; then
25937      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25938 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25939 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25940 See \`config.log' for more details." >&5
25941 $as_echo "$as_me: error: cannot compute alignment of short
25942 See \`config.log' for more details." >&2;}
25943    { (exit 77); exit 77; }; }; }
25944    else
25945      ac_cv_alignof_short=0
25946    fi ;;
25947 esac
25948 else
25949   cat >conftest.$ac_ext <<_ACEOF
25950 /* confdefs.h.  */
25951 _ACEOF
25952 cat confdefs.h >>conftest.$ac_ext
25953 cat >>conftest.$ac_ext <<_ACEOF
25954 /* end confdefs.h.  */
25955 $ac_includes_default
25956 #ifndef offsetof
25957 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25958 #endif
25959 typedef struct { char x; short y; } ac__type_alignof_;
25960 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25961 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25962 #include <stdio.h>
25963 #include <stdlib.h>
25964 int
25965 main ()
25966 {
25967
25968   FILE *f = fopen ("conftest.val", "w");
25969   if (! f)
25970     return 1;
25971   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25972     {
25973       long int i = longval ();
25974       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25975         return 1;
25976       fprintf (f, "%ld", i);
25977     }
25978   else
25979     {
25980       unsigned long int i = ulongval ();
25981       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25982         return 1;
25983       fprintf (f, "%lu", i);
25984     }
25985   /* Do not output a trailing newline, as this causes \r\n confusion
25986      on some platforms.  */
25987   return ferror (f) || fclose (f) != 0;
25988
25989   ;
25990   return 0;
25991 }
25992 _ACEOF
25993 rm -f conftest$ac_exeext
25994 if { (ac_try="$ac_link"
25995 case "(($ac_try" in
25996   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25997   *) ac_try_echo=$ac_try;;
25998 esac
25999 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26000 $as_echo "$ac_try_echo") >&5
26001   (eval "$ac_link") 2>&5
26002   ac_status=$?
26003   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26004   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26005   { (case "(($ac_try" in
26006   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26007   *) ac_try_echo=$ac_try;;
26008 esac
26009 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26010 $as_echo "$ac_try_echo") >&5
26011   (eval "$ac_try") 2>&5
26012   ac_status=$?
26013   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26014   (exit $ac_status); }; }; then
26015   ac_cv_alignof_short=`cat conftest.val`
26016 else
26017   $as_echo "$as_me: program exited with status $ac_status" >&5
26018 $as_echo "$as_me: failed program was:" >&5
26019 sed 's/^/| /' conftest.$ac_ext >&5
26020
26021 ( exit $ac_status )
26022 if test "$ac_cv_type_short" = yes; then
26023      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26024 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26025 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
26026 See \`config.log' for more details." >&5
26027 $as_echo "$as_me: error: cannot compute alignment of short
26028 See \`config.log' for more details." >&2;}
26029    { (exit 77); exit 77; }; }; }
26030    else
26031      ac_cv_alignof_short=0
26032    fi
26033 fi
26034 rm -rf conftest.dSYM
26035 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26036 fi
26037 rm -f conftest.val
26038 fi
26039 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
26040 $as_echo "$ac_cv_alignof_short" >&6; }
26041
26042
26043
26044 cat >>confdefs.h <<_ACEOF
26045 #define ALIGNOF_SHORT $ac_cv_alignof_short
26046 _ACEOF
26047
26048
26049 # The cast to long int works around a bug in the HP C Compiler,
26050 # see AC_CHECK_SIZEOF for more information.
26051 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
26052 $as_echo_n "checking alignment of int... " >&6; }
26053 if test "${ac_cv_alignof_int+set}" = set; then
26054   $as_echo_n "(cached) " >&6
26055 else
26056   if test "$cross_compiling" = yes; then
26057   # Depending upon the size, compute the lo and hi bounds.
26058 cat >conftest.$ac_ext <<_ACEOF
26059 /* confdefs.h.  */
26060 _ACEOF
26061 cat confdefs.h >>conftest.$ac_ext
26062 cat >>conftest.$ac_ext <<_ACEOF
26063 /* end confdefs.h.  */
26064 $ac_includes_default
26065 #ifndef offsetof
26066 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26067 #endif
26068 typedef struct { char x; int y; } ac__type_alignof_;
26069 int
26070 main ()
26071 {
26072 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26073 test_array [0] = 0
26074
26075   ;
26076   return 0;
26077 }
26078 _ACEOF
26079 rm -f conftest.$ac_objext
26080 if { (ac_try="$ac_compile"
26081 case "(($ac_try" in
26082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26083   *) ac_try_echo=$ac_try;;
26084 esac
26085 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26086 $as_echo "$ac_try_echo") >&5
26087   (eval "$ac_compile") 2>conftest.er1
26088   ac_status=$?
26089   grep -v '^ *+' conftest.er1 >conftest.err
26090   rm -f conftest.er1
26091   cat conftest.err >&5
26092   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26093   (exit $ac_status); } && {
26094          test -z "$ac_c_werror_flag" ||
26095          test ! -s conftest.err
26096        } && test -s conftest.$ac_objext; then
26097   ac_lo=0 ac_mid=0
26098   while :; do
26099     cat >conftest.$ac_ext <<_ACEOF
26100 /* confdefs.h.  */
26101 _ACEOF
26102 cat confdefs.h >>conftest.$ac_ext
26103 cat >>conftest.$ac_ext <<_ACEOF
26104 /* end confdefs.h.  */
26105 $ac_includes_default
26106 #ifndef offsetof
26107 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26108 #endif
26109 typedef struct { char x; int y; } ac__type_alignof_;
26110 int
26111 main ()
26112 {
26113 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26114 test_array [0] = 0
26115
26116   ;
26117   return 0;
26118 }
26119 _ACEOF
26120 rm -f conftest.$ac_objext
26121 if { (ac_try="$ac_compile"
26122 case "(($ac_try" in
26123   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26124   *) ac_try_echo=$ac_try;;
26125 esac
26126 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26127 $as_echo "$ac_try_echo") >&5
26128   (eval "$ac_compile") 2>conftest.er1
26129   ac_status=$?
26130   grep -v '^ *+' conftest.er1 >conftest.err
26131   rm -f conftest.er1
26132   cat conftest.err >&5
26133   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26134   (exit $ac_status); } && {
26135          test -z "$ac_c_werror_flag" ||
26136          test ! -s conftest.err
26137        } && test -s conftest.$ac_objext; then
26138   ac_hi=$ac_mid; break
26139 else
26140   $as_echo "$as_me: failed program was:" >&5
26141 sed 's/^/| /' conftest.$ac_ext >&5
26142
26143         ac_lo=`expr $ac_mid + 1`
26144                         if test $ac_lo -le $ac_mid; then
26145                           ac_lo= ac_hi=
26146                           break
26147                         fi
26148                         ac_mid=`expr 2 '*' $ac_mid + 1`
26149 fi
26150
26151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26152   done
26153 else
26154   $as_echo "$as_me: failed program was:" >&5
26155 sed 's/^/| /' conftest.$ac_ext >&5
26156
26157         cat >conftest.$ac_ext <<_ACEOF
26158 /* confdefs.h.  */
26159 _ACEOF
26160 cat confdefs.h >>conftest.$ac_ext
26161 cat >>conftest.$ac_ext <<_ACEOF
26162 /* end confdefs.h.  */
26163 $ac_includes_default
26164 #ifndef offsetof
26165 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26166 #endif
26167 typedef struct { char x; int y; } ac__type_alignof_;
26168 int
26169 main ()
26170 {
26171 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26172 test_array [0] = 0
26173
26174   ;
26175   return 0;
26176 }
26177 _ACEOF
26178 rm -f conftest.$ac_objext
26179 if { (ac_try="$ac_compile"
26180 case "(($ac_try" in
26181   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26182   *) ac_try_echo=$ac_try;;
26183 esac
26184 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26185 $as_echo "$ac_try_echo") >&5
26186   (eval "$ac_compile") 2>conftest.er1
26187   ac_status=$?
26188   grep -v '^ *+' conftest.er1 >conftest.err
26189   rm -f conftest.er1
26190   cat conftest.err >&5
26191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26192   (exit $ac_status); } && {
26193          test -z "$ac_c_werror_flag" ||
26194          test ! -s conftest.err
26195        } && test -s conftest.$ac_objext; then
26196   ac_hi=-1 ac_mid=-1
26197   while :; do
26198     cat >conftest.$ac_ext <<_ACEOF
26199 /* confdefs.h.  */
26200 _ACEOF
26201 cat confdefs.h >>conftest.$ac_ext
26202 cat >>conftest.$ac_ext <<_ACEOF
26203 /* end confdefs.h.  */
26204 $ac_includes_default
26205 #ifndef offsetof
26206 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26207 #endif
26208 typedef struct { char x; int y; } ac__type_alignof_;
26209 int
26210 main ()
26211 {
26212 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26213 test_array [0] = 0
26214
26215   ;
26216   return 0;
26217 }
26218 _ACEOF
26219 rm -f conftest.$ac_objext
26220 if { (ac_try="$ac_compile"
26221 case "(($ac_try" in
26222   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26223   *) ac_try_echo=$ac_try;;
26224 esac
26225 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26226 $as_echo "$ac_try_echo") >&5
26227   (eval "$ac_compile") 2>conftest.er1
26228   ac_status=$?
26229   grep -v '^ *+' conftest.er1 >conftest.err
26230   rm -f conftest.er1
26231   cat conftest.err >&5
26232   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26233   (exit $ac_status); } && {
26234          test -z "$ac_c_werror_flag" ||
26235          test ! -s conftest.err
26236        } && test -s conftest.$ac_objext; then
26237   ac_lo=$ac_mid; break
26238 else
26239   $as_echo "$as_me: failed program was:" >&5
26240 sed 's/^/| /' conftest.$ac_ext >&5
26241
26242         ac_hi=`expr '(' $ac_mid ')' - 1`
26243                         if test $ac_mid -le $ac_hi; then
26244                           ac_lo= ac_hi=
26245                           break
26246                         fi
26247                         ac_mid=`expr 2 '*' $ac_mid`
26248 fi
26249
26250 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26251   done
26252 else
26253   $as_echo "$as_me: failed program was:" >&5
26254 sed 's/^/| /' conftest.$ac_ext >&5
26255
26256         ac_lo= ac_hi=
26257 fi
26258
26259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26260 fi
26261
26262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26263 # Binary search between lo and hi bounds.
26264 while test "x$ac_lo" != "x$ac_hi"; do
26265   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26266   cat >conftest.$ac_ext <<_ACEOF
26267 /* confdefs.h.  */
26268 _ACEOF
26269 cat confdefs.h >>conftest.$ac_ext
26270 cat >>conftest.$ac_ext <<_ACEOF
26271 /* end confdefs.h.  */
26272 $ac_includes_default
26273 #ifndef offsetof
26274 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26275 #endif
26276 typedef struct { char x; int y; } ac__type_alignof_;
26277 int
26278 main ()
26279 {
26280 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26281 test_array [0] = 0
26282
26283   ;
26284   return 0;
26285 }
26286 _ACEOF
26287 rm -f conftest.$ac_objext
26288 if { (ac_try="$ac_compile"
26289 case "(($ac_try" in
26290   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26291   *) ac_try_echo=$ac_try;;
26292 esac
26293 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26294 $as_echo "$ac_try_echo") >&5
26295   (eval "$ac_compile") 2>conftest.er1
26296   ac_status=$?
26297   grep -v '^ *+' conftest.er1 >conftest.err
26298   rm -f conftest.er1
26299   cat conftest.err >&5
26300   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26301   (exit $ac_status); } && {
26302          test -z "$ac_c_werror_flag" ||
26303          test ! -s conftest.err
26304        } && test -s conftest.$ac_objext; then
26305   ac_hi=$ac_mid
26306 else
26307   $as_echo "$as_me: failed program was:" >&5
26308 sed 's/^/| /' conftest.$ac_ext >&5
26309
26310         ac_lo=`expr '(' $ac_mid ')' + 1`
26311 fi
26312
26313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26314 done
26315 case $ac_lo in
26316 ?*) ac_cv_alignof_int=$ac_lo;;
26317 '') if test "$ac_cv_type_int" = yes; then
26318      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26319 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26320 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26321 See \`config.log' for more details." >&5
26322 $as_echo "$as_me: error: cannot compute alignment of int
26323 See \`config.log' for more details." >&2;}
26324    { (exit 77); exit 77; }; }; }
26325    else
26326      ac_cv_alignof_int=0
26327    fi ;;
26328 esac
26329 else
26330   cat >conftest.$ac_ext <<_ACEOF
26331 /* confdefs.h.  */
26332 _ACEOF
26333 cat confdefs.h >>conftest.$ac_ext
26334 cat >>conftest.$ac_ext <<_ACEOF
26335 /* end confdefs.h.  */
26336 $ac_includes_default
26337 #ifndef offsetof
26338 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26339 #endif
26340 typedef struct { char x; int y; } ac__type_alignof_;
26341 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26342 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26343 #include <stdio.h>
26344 #include <stdlib.h>
26345 int
26346 main ()
26347 {
26348
26349   FILE *f = fopen ("conftest.val", "w");
26350   if (! f)
26351     return 1;
26352   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26353     {
26354       long int i = longval ();
26355       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26356         return 1;
26357       fprintf (f, "%ld", i);
26358     }
26359   else
26360     {
26361       unsigned long int i = ulongval ();
26362       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26363         return 1;
26364       fprintf (f, "%lu", i);
26365     }
26366   /* Do not output a trailing newline, as this causes \r\n confusion
26367      on some platforms.  */
26368   return ferror (f) || fclose (f) != 0;
26369
26370   ;
26371   return 0;
26372 }
26373 _ACEOF
26374 rm -f conftest$ac_exeext
26375 if { (ac_try="$ac_link"
26376 case "(($ac_try" in
26377   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26378   *) ac_try_echo=$ac_try;;
26379 esac
26380 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26381 $as_echo "$ac_try_echo") >&5
26382   (eval "$ac_link") 2>&5
26383   ac_status=$?
26384   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26385   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26386   { (case "(($ac_try" in
26387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26388   *) ac_try_echo=$ac_try;;
26389 esac
26390 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26391 $as_echo "$ac_try_echo") >&5
26392   (eval "$ac_try") 2>&5
26393   ac_status=$?
26394   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26395   (exit $ac_status); }; }; then
26396   ac_cv_alignof_int=`cat conftest.val`
26397 else
26398   $as_echo "$as_me: program exited with status $ac_status" >&5
26399 $as_echo "$as_me: failed program was:" >&5
26400 sed 's/^/| /' conftest.$ac_ext >&5
26401
26402 ( exit $ac_status )
26403 if test "$ac_cv_type_int" = yes; then
26404      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26405 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26406 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26407 See \`config.log' for more details." >&5
26408 $as_echo "$as_me: error: cannot compute alignment of int
26409 See \`config.log' for more details." >&2;}
26410    { (exit 77); exit 77; }; }; }
26411    else
26412      ac_cv_alignof_int=0
26413    fi
26414 fi
26415 rm -rf conftest.dSYM
26416 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26417 fi
26418 rm -f conftest.val
26419 fi
26420 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
26421 $as_echo "$ac_cv_alignof_int" >&6; }
26422
26423
26424
26425 cat >>confdefs.h <<_ACEOF
26426 #define ALIGNOF_INT $ac_cv_alignof_int
26427 _ACEOF
26428
26429
26430 # The cast to long int works around a bug in the HP C Compiler,
26431 # see AC_CHECK_SIZEOF for more information.
26432 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
26433 $as_echo_n "checking alignment of long... " >&6; }
26434 if test "${ac_cv_alignof_long+set}" = set; then
26435   $as_echo_n "(cached) " >&6
26436 else
26437   if test "$cross_compiling" = yes; then
26438   # Depending upon the size, compute the lo and hi bounds.
26439 cat >conftest.$ac_ext <<_ACEOF
26440 /* confdefs.h.  */
26441 _ACEOF
26442 cat confdefs.h >>conftest.$ac_ext
26443 cat >>conftest.$ac_ext <<_ACEOF
26444 /* end confdefs.h.  */
26445 $ac_includes_default
26446 #ifndef offsetof
26447 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26448 #endif
26449 typedef struct { char x; long y; } ac__type_alignof_;
26450 int
26451 main ()
26452 {
26453 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26454 test_array [0] = 0
26455
26456   ;
26457   return 0;
26458 }
26459 _ACEOF
26460 rm -f conftest.$ac_objext
26461 if { (ac_try="$ac_compile"
26462 case "(($ac_try" in
26463   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26464   *) ac_try_echo=$ac_try;;
26465 esac
26466 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26467 $as_echo "$ac_try_echo") >&5
26468   (eval "$ac_compile") 2>conftest.er1
26469   ac_status=$?
26470   grep -v '^ *+' conftest.er1 >conftest.err
26471   rm -f conftest.er1
26472   cat conftest.err >&5
26473   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26474   (exit $ac_status); } && {
26475          test -z "$ac_c_werror_flag" ||
26476          test ! -s conftest.err
26477        } && test -s conftest.$ac_objext; then
26478   ac_lo=0 ac_mid=0
26479   while :; do
26480     cat >conftest.$ac_ext <<_ACEOF
26481 /* confdefs.h.  */
26482 _ACEOF
26483 cat confdefs.h >>conftest.$ac_ext
26484 cat >>conftest.$ac_ext <<_ACEOF
26485 /* end confdefs.h.  */
26486 $ac_includes_default
26487 #ifndef offsetof
26488 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26489 #endif
26490 typedef struct { char x; long y; } ac__type_alignof_;
26491 int
26492 main ()
26493 {
26494 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26495 test_array [0] = 0
26496
26497   ;
26498   return 0;
26499 }
26500 _ACEOF
26501 rm -f conftest.$ac_objext
26502 if { (ac_try="$ac_compile"
26503 case "(($ac_try" in
26504   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26505   *) ac_try_echo=$ac_try;;
26506 esac
26507 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26508 $as_echo "$ac_try_echo") >&5
26509   (eval "$ac_compile") 2>conftest.er1
26510   ac_status=$?
26511   grep -v '^ *+' conftest.er1 >conftest.err
26512   rm -f conftest.er1
26513   cat conftest.err >&5
26514   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26515   (exit $ac_status); } && {
26516          test -z "$ac_c_werror_flag" ||
26517          test ! -s conftest.err
26518        } && test -s conftest.$ac_objext; then
26519   ac_hi=$ac_mid; break
26520 else
26521   $as_echo "$as_me: failed program was:" >&5
26522 sed 's/^/| /' conftest.$ac_ext >&5
26523
26524         ac_lo=`expr $ac_mid + 1`
26525                         if test $ac_lo -le $ac_mid; then
26526                           ac_lo= ac_hi=
26527                           break
26528                         fi
26529                         ac_mid=`expr 2 '*' $ac_mid + 1`
26530 fi
26531
26532 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26533   done
26534 else
26535   $as_echo "$as_me: failed program was:" >&5
26536 sed 's/^/| /' conftest.$ac_ext >&5
26537
26538         cat >conftest.$ac_ext <<_ACEOF
26539 /* confdefs.h.  */
26540 _ACEOF
26541 cat confdefs.h >>conftest.$ac_ext
26542 cat >>conftest.$ac_ext <<_ACEOF
26543 /* end confdefs.h.  */
26544 $ac_includes_default
26545 #ifndef offsetof
26546 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26547 #endif
26548 typedef struct { char x; long y; } ac__type_alignof_;
26549 int
26550 main ()
26551 {
26552 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26553 test_array [0] = 0
26554
26555   ;
26556   return 0;
26557 }
26558 _ACEOF
26559 rm -f conftest.$ac_objext
26560 if { (ac_try="$ac_compile"
26561 case "(($ac_try" in
26562   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26563   *) ac_try_echo=$ac_try;;
26564 esac
26565 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26566 $as_echo "$ac_try_echo") >&5
26567   (eval "$ac_compile") 2>conftest.er1
26568   ac_status=$?
26569   grep -v '^ *+' conftest.er1 >conftest.err
26570   rm -f conftest.er1
26571   cat conftest.err >&5
26572   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26573   (exit $ac_status); } && {
26574          test -z "$ac_c_werror_flag" ||
26575          test ! -s conftest.err
26576        } && test -s conftest.$ac_objext; then
26577   ac_hi=-1 ac_mid=-1
26578   while :; do
26579     cat >conftest.$ac_ext <<_ACEOF
26580 /* confdefs.h.  */
26581 _ACEOF
26582 cat confdefs.h >>conftest.$ac_ext
26583 cat >>conftest.$ac_ext <<_ACEOF
26584 /* end confdefs.h.  */
26585 $ac_includes_default
26586 #ifndef offsetof
26587 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26588 #endif
26589 typedef struct { char x; long y; } ac__type_alignof_;
26590 int
26591 main ()
26592 {
26593 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26594 test_array [0] = 0
26595
26596   ;
26597   return 0;
26598 }
26599 _ACEOF
26600 rm -f conftest.$ac_objext
26601 if { (ac_try="$ac_compile"
26602 case "(($ac_try" in
26603   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26604   *) ac_try_echo=$ac_try;;
26605 esac
26606 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26607 $as_echo "$ac_try_echo") >&5
26608   (eval "$ac_compile") 2>conftest.er1
26609   ac_status=$?
26610   grep -v '^ *+' conftest.er1 >conftest.err
26611   rm -f conftest.er1
26612   cat conftest.err >&5
26613   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26614   (exit $ac_status); } && {
26615          test -z "$ac_c_werror_flag" ||
26616          test ! -s conftest.err
26617        } && test -s conftest.$ac_objext; then
26618   ac_lo=$ac_mid; break
26619 else
26620   $as_echo "$as_me: failed program was:" >&5
26621 sed 's/^/| /' conftest.$ac_ext >&5
26622
26623         ac_hi=`expr '(' $ac_mid ')' - 1`
26624                         if test $ac_mid -le $ac_hi; then
26625                           ac_lo= ac_hi=
26626                           break
26627                         fi
26628                         ac_mid=`expr 2 '*' $ac_mid`
26629 fi
26630
26631 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26632   done
26633 else
26634   $as_echo "$as_me: failed program was:" >&5
26635 sed 's/^/| /' conftest.$ac_ext >&5
26636
26637         ac_lo= ac_hi=
26638 fi
26639
26640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26641 fi
26642
26643 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26644 # Binary search between lo and hi bounds.
26645 while test "x$ac_lo" != "x$ac_hi"; do
26646   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26647   cat >conftest.$ac_ext <<_ACEOF
26648 /* confdefs.h.  */
26649 _ACEOF
26650 cat confdefs.h >>conftest.$ac_ext
26651 cat >>conftest.$ac_ext <<_ACEOF
26652 /* end confdefs.h.  */
26653 $ac_includes_default
26654 #ifndef offsetof
26655 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26656 #endif
26657 typedef struct { char x; long y; } ac__type_alignof_;
26658 int
26659 main ()
26660 {
26661 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26662 test_array [0] = 0
26663
26664   ;
26665   return 0;
26666 }
26667 _ACEOF
26668 rm -f conftest.$ac_objext
26669 if { (ac_try="$ac_compile"
26670 case "(($ac_try" in
26671   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26672   *) ac_try_echo=$ac_try;;
26673 esac
26674 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26675 $as_echo "$ac_try_echo") >&5
26676   (eval "$ac_compile") 2>conftest.er1
26677   ac_status=$?
26678   grep -v '^ *+' conftest.er1 >conftest.err
26679   rm -f conftest.er1
26680   cat conftest.err >&5
26681   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26682   (exit $ac_status); } && {
26683          test -z "$ac_c_werror_flag" ||
26684          test ! -s conftest.err
26685        } && test -s conftest.$ac_objext; then
26686   ac_hi=$ac_mid
26687 else
26688   $as_echo "$as_me: failed program was:" >&5
26689 sed 's/^/| /' conftest.$ac_ext >&5
26690
26691         ac_lo=`expr '(' $ac_mid ')' + 1`
26692 fi
26693
26694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26695 done
26696 case $ac_lo in
26697 ?*) ac_cv_alignof_long=$ac_lo;;
26698 '') if test "$ac_cv_type_long" = yes; then
26699      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26700 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26701 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26702 See \`config.log' for more details." >&5
26703 $as_echo "$as_me: error: cannot compute alignment of long
26704 See \`config.log' for more details." >&2;}
26705    { (exit 77); exit 77; }; }; }
26706    else
26707      ac_cv_alignof_long=0
26708    fi ;;
26709 esac
26710 else
26711   cat >conftest.$ac_ext <<_ACEOF
26712 /* confdefs.h.  */
26713 _ACEOF
26714 cat confdefs.h >>conftest.$ac_ext
26715 cat >>conftest.$ac_ext <<_ACEOF
26716 /* end confdefs.h.  */
26717 $ac_includes_default
26718 #ifndef offsetof
26719 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26720 #endif
26721 typedef struct { char x; long y; } ac__type_alignof_;
26722 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26723 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26724 #include <stdio.h>
26725 #include <stdlib.h>
26726 int
26727 main ()
26728 {
26729
26730   FILE *f = fopen ("conftest.val", "w");
26731   if (! f)
26732     return 1;
26733   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26734     {
26735       long int i = longval ();
26736       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26737         return 1;
26738       fprintf (f, "%ld", i);
26739     }
26740   else
26741     {
26742       unsigned long int i = ulongval ();
26743       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26744         return 1;
26745       fprintf (f, "%lu", i);
26746     }
26747   /* Do not output a trailing newline, as this causes \r\n confusion
26748      on some platforms.  */
26749   return ferror (f) || fclose (f) != 0;
26750
26751   ;
26752   return 0;
26753 }
26754 _ACEOF
26755 rm -f conftest$ac_exeext
26756 if { (ac_try="$ac_link"
26757 case "(($ac_try" in
26758   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26759   *) ac_try_echo=$ac_try;;
26760 esac
26761 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26762 $as_echo "$ac_try_echo") >&5
26763   (eval "$ac_link") 2>&5
26764   ac_status=$?
26765   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26766   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26767   { (case "(($ac_try" in
26768   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26769   *) ac_try_echo=$ac_try;;
26770 esac
26771 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26772 $as_echo "$ac_try_echo") >&5
26773   (eval "$ac_try") 2>&5
26774   ac_status=$?
26775   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26776   (exit $ac_status); }; }; then
26777   ac_cv_alignof_long=`cat conftest.val`
26778 else
26779   $as_echo "$as_me: program exited with status $ac_status" >&5
26780 $as_echo "$as_me: failed program was:" >&5
26781 sed 's/^/| /' conftest.$ac_ext >&5
26782
26783 ( exit $ac_status )
26784 if test "$ac_cv_type_long" = yes; then
26785      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26786 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26787 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26788 See \`config.log' for more details." >&5
26789 $as_echo "$as_me: error: cannot compute alignment of long
26790 See \`config.log' for more details." >&2;}
26791    { (exit 77); exit 77; }; }; }
26792    else
26793      ac_cv_alignof_long=0
26794    fi
26795 fi
26796 rm -rf conftest.dSYM
26797 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26798 fi
26799 rm -f conftest.val
26800 fi
26801 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
26802 $as_echo "$ac_cv_alignof_long" >&6; }
26803
26804
26805
26806 cat >>confdefs.h <<_ACEOF
26807 #define ALIGNOF_LONG $ac_cv_alignof_long
26808 _ACEOF
26809
26810
26811 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
26812   # The cast to long int works around a bug in the HP C Compiler,
26813 # see AC_CHECK_SIZEOF for more information.
26814 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
26815 $as_echo_n "checking alignment of long long int... " >&6; }
26816 if test "${ac_cv_alignof_long_long_int+set}" = set; then
26817   $as_echo_n "(cached) " >&6
26818 else
26819   if test "$cross_compiling" = yes; then
26820   # Depending upon the size, compute the lo and hi bounds.
26821 cat >conftest.$ac_ext <<_ACEOF
26822 /* confdefs.h.  */
26823 _ACEOF
26824 cat confdefs.h >>conftest.$ac_ext
26825 cat >>conftest.$ac_ext <<_ACEOF
26826 /* end confdefs.h.  */
26827 $ac_includes_default
26828 #ifndef offsetof
26829 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26830 #endif
26831 typedef struct { char x; long long int y; } ac__type_alignof_;
26832 int
26833 main ()
26834 {
26835 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26836 test_array [0] = 0
26837
26838   ;
26839   return 0;
26840 }
26841 _ACEOF
26842 rm -f conftest.$ac_objext
26843 if { (ac_try="$ac_compile"
26844 case "(($ac_try" in
26845   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26846   *) ac_try_echo=$ac_try;;
26847 esac
26848 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26849 $as_echo "$ac_try_echo") >&5
26850   (eval "$ac_compile") 2>conftest.er1
26851   ac_status=$?
26852   grep -v '^ *+' conftest.er1 >conftest.err
26853   rm -f conftest.er1
26854   cat conftest.err >&5
26855   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26856   (exit $ac_status); } && {
26857          test -z "$ac_c_werror_flag" ||
26858          test ! -s conftest.err
26859        } && test -s conftest.$ac_objext; then
26860   ac_lo=0 ac_mid=0
26861   while :; do
26862     cat >conftest.$ac_ext <<_ACEOF
26863 /* confdefs.h.  */
26864 _ACEOF
26865 cat confdefs.h >>conftest.$ac_ext
26866 cat >>conftest.$ac_ext <<_ACEOF
26867 /* end confdefs.h.  */
26868 $ac_includes_default
26869 #ifndef offsetof
26870 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26871 #endif
26872 typedef struct { char x; long long int y; } ac__type_alignof_;
26873 int
26874 main ()
26875 {
26876 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26877 test_array [0] = 0
26878
26879   ;
26880   return 0;
26881 }
26882 _ACEOF
26883 rm -f conftest.$ac_objext
26884 if { (ac_try="$ac_compile"
26885 case "(($ac_try" in
26886   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26887   *) ac_try_echo=$ac_try;;
26888 esac
26889 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26890 $as_echo "$ac_try_echo") >&5
26891   (eval "$ac_compile") 2>conftest.er1
26892   ac_status=$?
26893   grep -v '^ *+' conftest.er1 >conftest.err
26894   rm -f conftest.er1
26895   cat conftest.err >&5
26896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26897   (exit $ac_status); } && {
26898          test -z "$ac_c_werror_flag" ||
26899          test ! -s conftest.err
26900        } && test -s conftest.$ac_objext; then
26901   ac_hi=$ac_mid; break
26902 else
26903   $as_echo "$as_me: failed program was:" >&5
26904 sed 's/^/| /' conftest.$ac_ext >&5
26905
26906         ac_lo=`expr $ac_mid + 1`
26907                         if test $ac_lo -le $ac_mid; then
26908                           ac_lo= ac_hi=
26909                           break
26910                         fi
26911                         ac_mid=`expr 2 '*' $ac_mid + 1`
26912 fi
26913
26914 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26915   done
26916 else
26917   $as_echo "$as_me: failed program was:" >&5
26918 sed 's/^/| /' conftest.$ac_ext >&5
26919
26920         cat >conftest.$ac_ext <<_ACEOF
26921 /* confdefs.h.  */
26922 _ACEOF
26923 cat confdefs.h >>conftest.$ac_ext
26924 cat >>conftest.$ac_ext <<_ACEOF
26925 /* end confdefs.h.  */
26926 $ac_includes_default
26927 #ifndef offsetof
26928 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26929 #endif
26930 typedef struct { char x; long long int y; } ac__type_alignof_;
26931 int
26932 main ()
26933 {
26934 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26935 test_array [0] = 0
26936
26937   ;
26938   return 0;
26939 }
26940 _ACEOF
26941 rm -f conftest.$ac_objext
26942 if { (ac_try="$ac_compile"
26943 case "(($ac_try" in
26944   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26945   *) ac_try_echo=$ac_try;;
26946 esac
26947 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26948 $as_echo "$ac_try_echo") >&5
26949   (eval "$ac_compile") 2>conftest.er1
26950   ac_status=$?
26951   grep -v '^ *+' conftest.er1 >conftest.err
26952   rm -f conftest.er1
26953   cat conftest.err >&5
26954   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26955   (exit $ac_status); } && {
26956          test -z "$ac_c_werror_flag" ||
26957          test ! -s conftest.err
26958        } && test -s conftest.$ac_objext; then
26959   ac_hi=-1 ac_mid=-1
26960   while :; do
26961     cat >conftest.$ac_ext <<_ACEOF
26962 /* confdefs.h.  */
26963 _ACEOF
26964 cat confdefs.h >>conftest.$ac_ext
26965 cat >>conftest.$ac_ext <<_ACEOF
26966 /* end confdefs.h.  */
26967 $ac_includes_default
26968 #ifndef offsetof
26969 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26970 #endif
26971 typedef struct { char x; long long int y; } ac__type_alignof_;
26972 int
26973 main ()
26974 {
26975 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26976 test_array [0] = 0
26977
26978   ;
26979   return 0;
26980 }
26981 _ACEOF
26982 rm -f conftest.$ac_objext
26983 if { (ac_try="$ac_compile"
26984 case "(($ac_try" in
26985   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26986   *) ac_try_echo=$ac_try;;
26987 esac
26988 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26989 $as_echo "$ac_try_echo") >&5
26990   (eval "$ac_compile") 2>conftest.er1
26991   ac_status=$?
26992   grep -v '^ *+' conftest.er1 >conftest.err
26993   rm -f conftest.er1
26994   cat conftest.err >&5
26995   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26996   (exit $ac_status); } && {
26997          test -z "$ac_c_werror_flag" ||
26998          test ! -s conftest.err
26999        } && test -s conftest.$ac_objext; then
27000   ac_lo=$ac_mid; break
27001 else
27002   $as_echo "$as_me: failed program was:" >&5
27003 sed 's/^/| /' conftest.$ac_ext >&5
27004
27005         ac_hi=`expr '(' $ac_mid ')' - 1`
27006                         if test $ac_mid -le $ac_hi; then
27007                           ac_lo= ac_hi=
27008                           break
27009                         fi
27010                         ac_mid=`expr 2 '*' $ac_mid`
27011 fi
27012
27013 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27014   done
27015 else
27016   $as_echo "$as_me: failed program was:" >&5
27017 sed 's/^/| /' conftest.$ac_ext >&5
27018
27019         ac_lo= ac_hi=
27020 fi
27021
27022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27023 fi
27024
27025 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27026 # Binary search between lo and hi bounds.
27027 while test "x$ac_lo" != "x$ac_hi"; do
27028   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27029   cat >conftest.$ac_ext <<_ACEOF
27030 /* confdefs.h.  */
27031 _ACEOF
27032 cat confdefs.h >>conftest.$ac_ext
27033 cat >>conftest.$ac_ext <<_ACEOF
27034 /* end confdefs.h.  */
27035 $ac_includes_default
27036 #ifndef offsetof
27037 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27038 #endif
27039 typedef struct { char x; long long int y; } ac__type_alignof_;
27040 int
27041 main ()
27042 {
27043 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27044 test_array [0] = 0
27045
27046   ;
27047   return 0;
27048 }
27049 _ACEOF
27050 rm -f conftest.$ac_objext
27051 if { (ac_try="$ac_compile"
27052 case "(($ac_try" in
27053   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27054   *) ac_try_echo=$ac_try;;
27055 esac
27056 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27057 $as_echo "$ac_try_echo") >&5
27058   (eval "$ac_compile") 2>conftest.er1
27059   ac_status=$?
27060   grep -v '^ *+' conftest.er1 >conftest.err
27061   rm -f conftest.er1
27062   cat conftest.err >&5
27063   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27064   (exit $ac_status); } && {
27065          test -z "$ac_c_werror_flag" ||
27066          test ! -s conftest.err
27067        } && test -s conftest.$ac_objext; then
27068   ac_hi=$ac_mid
27069 else
27070   $as_echo "$as_me: failed program was:" >&5
27071 sed 's/^/| /' conftest.$ac_ext >&5
27072
27073         ac_lo=`expr '(' $ac_mid ')' + 1`
27074 fi
27075
27076 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27077 done
27078 case $ac_lo in
27079 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
27080 '') if test "$ac_cv_type_long_long_int" = yes; then
27081      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27082 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27083 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
27084 See \`config.log' for more details." >&5
27085 $as_echo "$as_me: error: cannot compute alignment of long long int
27086 See \`config.log' for more details." >&2;}
27087    { (exit 77); exit 77; }; }; }
27088    else
27089      ac_cv_alignof_long_long_int=0
27090    fi ;;
27091 esac
27092 else
27093   cat >conftest.$ac_ext <<_ACEOF
27094 /* confdefs.h.  */
27095 _ACEOF
27096 cat confdefs.h >>conftest.$ac_ext
27097 cat >>conftest.$ac_ext <<_ACEOF
27098 /* end confdefs.h.  */
27099 $ac_includes_default
27100 #ifndef offsetof
27101 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27102 #endif
27103 typedef struct { char x; long long int y; } ac__type_alignof_;
27104 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27105 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27106 #include <stdio.h>
27107 #include <stdlib.h>
27108 int
27109 main ()
27110 {
27111
27112   FILE *f = fopen ("conftest.val", "w");
27113   if (! f)
27114     return 1;
27115   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27116     {
27117       long int i = longval ();
27118       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27119         return 1;
27120       fprintf (f, "%ld", i);
27121     }
27122   else
27123     {
27124       unsigned long int i = ulongval ();
27125       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27126         return 1;
27127       fprintf (f, "%lu", i);
27128     }
27129   /* Do not output a trailing newline, as this causes \r\n confusion
27130      on some platforms.  */
27131   return ferror (f) || fclose (f) != 0;
27132
27133   ;
27134   return 0;
27135 }
27136 _ACEOF
27137 rm -f conftest$ac_exeext
27138 if { (ac_try="$ac_link"
27139 case "(($ac_try" in
27140   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27141   *) ac_try_echo=$ac_try;;
27142 esac
27143 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27144 $as_echo "$ac_try_echo") >&5
27145   (eval "$ac_link") 2>&5
27146   ac_status=$?
27147   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27148   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27149   { (case "(($ac_try" in
27150   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27151   *) ac_try_echo=$ac_try;;
27152 esac
27153 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27154 $as_echo "$ac_try_echo") >&5
27155   (eval "$ac_try") 2>&5
27156   ac_status=$?
27157   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27158   (exit $ac_status); }; }; then
27159   ac_cv_alignof_long_long_int=`cat conftest.val`
27160 else
27161   $as_echo "$as_me: program exited with status $ac_status" >&5
27162 $as_echo "$as_me: failed program was:" >&5
27163 sed 's/^/| /' conftest.$ac_ext >&5
27164
27165 ( exit $ac_status )
27166 if test "$ac_cv_type_long_long_int" = yes; then
27167      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27168 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27169 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
27170 See \`config.log' for more details." >&5
27171 $as_echo "$as_me: error: cannot compute alignment of long long int
27172 See \`config.log' for more details." >&2;}
27173    { (exit 77); exit 77; }; }; }
27174    else
27175      ac_cv_alignof_long_long_int=0
27176    fi
27177 fi
27178 rm -rf conftest.dSYM
27179 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27180 fi
27181 rm -f conftest.val
27182 fi
27183 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
27184 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
27185
27186
27187
27188 cat >>confdefs.h <<_ACEOF
27189 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
27190 _ACEOF
27191
27192
27193 fi
27194 # The cast to long int works around a bug in the HP C Compiler,
27195 # see AC_CHECK_SIZEOF for more information.
27196 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
27197 $as_echo_n "checking alignment of double... " >&6; }
27198 if test "${ac_cv_alignof_double+set}" = set; then
27199   $as_echo_n "(cached) " >&6
27200 else
27201   if test "$cross_compiling" = yes; then
27202   # Depending upon the size, compute the lo and hi bounds.
27203 cat >conftest.$ac_ext <<_ACEOF
27204 /* confdefs.h.  */
27205 _ACEOF
27206 cat confdefs.h >>conftest.$ac_ext
27207 cat >>conftest.$ac_ext <<_ACEOF
27208 /* end confdefs.h.  */
27209 $ac_includes_default
27210 #ifndef offsetof
27211 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27212 #endif
27213 typedef struct { char x; double y; } ac__type_alignof_;
27214 int
27215 main ()
27216 {
27217 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
27218 test_array [0] = 0
27219
27220   ;
27221   return 0;
27222 }
27223 _ACEOF
27224 rm -f conftest.$ac_objext
27225 if { (ac_try="$ac_compile"
27226 case "(($ac_try" in
27227   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27228   *) ac_try_echo=$ac_try;;
27229 esac
27230 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27231 $as_echo "$ac_try_echo") >&5
27232   (eval "$ac_compile") 2>conftest.er1
27233   ac_status=$?
27234   grep -v '^ *+' conftest.er1 >conftest.err
27235   rm -f conftest.er1
27236   cat conftest.err >&5
27237   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27238   (exit $ac_status); } && {
27239          test -z "$ac_c_werror_flag" ||
27240          test ! -s conftest.err
27241        } && test -s conftest.$ac_objext; then
27242   ac_lo=0 ac_mid=0
27243   while :; do
27244     cat >conftest.$ac_ext <<_ACEOF
27245 /* confdefs.h.  */
27246 _ACEOF
27247 cat confdefs.h >>conftest.$ac_ext
27248 cat >>conftest.$ac_ext <<_ACEOF
27249 /* end confdefs.h.  */
27250 $ac_includes_default
27251 #ifndef offsetof
27252 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27253 #endif
27254 typedef struct { char x; double y; } ac__type_alignof_;
27255 int
27256 main ()
27257 {
27258 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27259 test_array [0] = 0
27260
27261   ;
27262   return 0;
27263 }
27264 _ACEOF
27265 rm -f conftest.$ac_objext
27266 if { (ac_try="$ac_compile"
27267 case "(($ac_try" in
27268   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27269   *) ac_try_echo=$ac_try;;
27270 esac
27271 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27272 $as_echo "$ac_try_echo") >&5
27273   (eval "$ac_compile") 2>conftest.er1
27274   ac_status=$?
27275   grep -v '^ *+' conftest.er1 >conftest.err
27276   rm -f conftest.er1
27277   cat conftest.err >&5
27278   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27279   (exit $ac_status); } && {
27280          test -z "$ac_c_werror_flag" ||
27281          test ! -s conftest.err
27282        } && test -s conftest.$ac_objext; then
27283   ac_hi=$ac_mid; break
27284 else
27285   $as_echo "$as_me: failed program was:" >&5
27286 sed 's/^/| /' conftest.$ac_ext >&5
27287
27288         ac_lo=`expr $ac_mid + 1`
27289                         if test $ac_lo -le $ac_mid; then
27290                           ac_lo= ac_hi=
27291                           break
27292                         fi
27293                         ac_mid=`expr 2 '*' $ac_mid + 1`
27294 fi
27295
27296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27297   done
27298 else
27299   $as_echo "$as_me: failed program was:" >&5
27300 sed 's/^/| /' conftest.$ac_ext >&5
27301
27302         cat >conftest.$ac_ext <<_ACEOF
27303 /* confdefs.h.  */
27304 _ACEOF
27305 cat confdefs.h >>conftest.$ac_ext
27306 cat >>conftest.$ac_ext <<_ACEOF
27307 /* end confdefs.h.  */
27308 $ac_includes_default
27309 #ifndef offsetof
27310 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27311 #endif
27312 typedef struct { char x; double y; } ac__type_alignof_;
27313 int
27314 main ()
27315 {
27316 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
27317 test_array [0] = 0
27318
27319   ;
27320   return 0;
27321 }
27322 _ACEOF
27323 rm -f conftest.$ac_objext
27324 if { (ac_try="$ac_compile"
27325 case "(($ac_try" in
27326   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27327   *) ac_try_echo=$ac_try;;
27328 esac
27329 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27330 $as_echo "$ac_try_echo") >&5
27331   (eval "$ac_compile") 2>conftest.er1
27332   ac_status=$?
27333   grep -v '^ *+' conftest.er1 >conftest.err
27334   rm -f conftest.er1
27335   cat conftest.err >&5
27336   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27337   (exit $ac_status); } && {
27338          test -z "$ac_c_werror_flag" ||
27339          test ! -s conftest.err
27340        } && test -s conftest.$ac_objext; then
27341   ac_hi=-1 ac_mid=-1
27342   while :; do
27343     cat >conftest.$ac_ext <<_ACEOF
27344 /* confdefs.h.  */
27345 _ACEOF
27346 cat confdefs.h >>conftest.$ac_ext
27347 cat >>conftest.$ac_ext <<_ACEOF
27348 /* end confdefs.h.  */
27349 $ac_includes_default
27350 #ifndef offsetof
27351 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27352 #endif
27353 typedef struct { char x; double y; } ac__type_alignof_;
27354 int
27355 main ()
27356 {
27357 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
27358 test_array [0] = 0
27359
27360   ;
27361   return 0;
27362 }
27363 _ACEOF
27364 rm -f conftest.$ac_objext
27365 if { (ac_try="$ac_compile"
27366 case "(($ac_try" in
27367   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27368   *) ac_try_echo=$ac_try;;
27369 esac
27370 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27371 $as_echo "$ac_try_echo") >&5
27372   (eval "$ac_compile") 2>conftest.er1
27373   ac_status=$?
27374   grep -v '^ *+' conftest.er1 >conftest.err
27375   rm -f conftest.er1
27376   cat conftest.err >&5
27377   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27378   (exit $ac_status); } && {
27379          test -z "$ac_c_werror_flag" ||
27380          test ! -s conftest.err
27381        } && test -s conftest.$ac_objext; then
27382   ac_lo=$ac_mid; break
27383 else
27384   $as_echo "$as_me: failed program was:" >&5
27385 sed 's/^/| /' conftest.$ac_ext >&5
27386
27387         ac_hi=`expr '(' $ac_mid ')' - 1`
27388                         if test $ac_mid -le $ac_hi; then
27389                           ac_lo= ac_hi=
27390                           break
27391                         fi
27392                         ac_mid=`expr 2 '*' $ac_mid`
27393 fi
27394
27395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27396   done
27397 else
27398   $as_echo "$as_me: failed program was:" >&5
27399 sed 's/^/| /' conftest.$ac_ext >&5
27400
27401         ac_lo= ac_hi=
27402 fi
27403
27404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27405 fi
27406
27407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27408 # Binary search between lo and hi bounds.
27409 while test "x$ac_lo" != "x$ac_hi"; do
27410   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27411   cat >conftest.$ac_ext <<_ACEOF
27412 /* confdefs.h.  */
27413 _ACEOF
27414 cat confdefs.h >>conftest.$ac_ext
27415 cat >>conftest.$ac_ext <<_ACEOF
27416 /* end confdefs.h.  */
27417 $ac_includes_default
27418 #ifndef offsetof
27419 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27420 #endif
27421 typedef struct { char x; double y; } ac__type_alignof_;
27422 int
27423 main ()
27424 {
27425 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27426 test_array [0] = 0
27427
27428   ;
27429   return 0;
27430 }
27431 _ACEOF
27432 rm -f conftest.$ac_objext
27433 if { (ac_try="$ac_compile"
27434 case "(($ac_try" in
27435   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27436   *) ac_try_echo=$ac_try;;
27437 esac
27438 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27439 $as_echo "$ac_try_echo") >&5
27440   (eval "$ac_compile") 2>conftest.er1
27441   ac_status=$?
27442   grep -v '^ *+' conftest.er1 >conftest.err
27443   rm -f conftest.er1
27444   cat conftest.err >&5
27445   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27446   (exit $ac_status); } && {
27447          test -z "$ac_c_werror_flag" ||
27448          test ! -s conftest.err
27449        } && test -s conftest.$ac_objext; then
27450   ac_hi=$ac_mid
27451 else
27452   $as_echo "$as_me: failed program was:" >&5
27453 sed 's/^/| /' conftest.$ac_ext >&5
27454
27455         ac_lo=`expr '(' $ac_mid ')' + 1`
27456 fi
27457
27458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27459 done
27460 case $ac_lo in
27461 ?*) ac_cv_alignof_double=$ac_lo;;
27462 '') if test "$ac_cv_type_double" = yes; then
27463      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27464 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27465 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27466 See \`config.log' for more details." >&5
27467 $as_echo "$as_me: error: cannot compute alignment of double
27468 See \`config.log' for more details." >&2;}
27469    { (exit 77); exit 77; }; }; }
27470    else
27471      ac_cv_alignof_double=0
27472    fi ;;
27473 esac
27474 else
27475   cat >conftest.$ac_ext <<_ACEOF
27476 /* confdefs.h.  */
27477 _ACEOF
27478 cat confdefs.h >>conftest.$ac_ext
27479 cat >>conftest.$ac_ext <<_ACEOF
27480 /* end confdefs.h.  */
27481 $ac_includes_default
27482 #ifndef offsetof
27483 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27484 #endif
27485 typedef struct { char x; double y; } ac__type_alignof_;
27486 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27487 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27488 #include <stdio.h>
27489 #include <stdlib.h>
27490 int
27491 main ()
27492 {
27493
27494   FILE *f = fopen ("conftest.val", "w");
27495   if (! f)
27496     return 1;
27497   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27498     {
27499       long int i = longval ();
27500       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27501         return 1;
27502       fprintf (f, "%ld", i);
27503     }
27504   else
27505     {
27506       unsigned long int i = ulongval ();
27507       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27508         return 1;
27509       fprintf (f, "%lu", i);
27510     }
27511   /* Do not output a trailing newline, as this causes \r\n confusion
27512      on some platforms.  */
27513   return ferror (f) || fclose (f) != 0;
27514
27515   ;
27516   return 0;
27517 }
27518 _ACEOF
27519 rm -f conftest$ac_exeext
27520 if { (ac_try="$ac_link"
27521 case "(($ac_try" in
27522   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27523   *) ac_try_echo=$ac_try;;
27524 esac
27525 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27526 $as_echo "$ac_try_echo") >&5
27527   (eval "$ac_link") 2>&5
27528   ac_status=$?
27529   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27530   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27531   { (case "(($ac_try" in
27532   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27533   *) ac_try_echo=$ac_try;;
27534 esac
27535 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27536 $as_echo "$ac_try_echo") >&5
27537   (eval "$ac_try") 2>&5
27538   ac_status=$?
27539   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27540   (exit $ac_status); }; }; then
27541   ac_cv_alignof_double=`cat conftest.val`
27542 else
27543   $as_echo "$as_me: program exited with status $ac_status" >&5
27544 $as_echo "$as_me: failed program was:" >&5
27545 sed 's/^/| /' conftest.$ac_ext >&5
27546
27547 ( exit $ac_status )
27548 if test "$ac_cv_type_double" = yes; then
27549      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27550 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27551 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27552 See \`config.log' for more details." >&5
27553 $as_echo "$as_me: error: cannot compute alignment of double
27554 See \`config.log' for more details." >&2;}
27555    { (exit 77); exit 77; }; }; }
27556    else
27557      ac_cv_alignof_double=0
27558    fi
27559 fi
27560 rm -rf conftest.dSYM
27561 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27562 fi
27563 rm -f conftest.val
27564 fi
27565 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
27566 $as_echo "$ac_cv_alignof_double" >&6; }
27567
27568
27569
27570 cat >>confdefs.h <<_ACEOF
27571 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
27572 _ACEOF
27573
27574
27575
27576 # Compute maximum alignment of any basic type.
27577 # We assume long's alignment is at least as strong as char, short, or int;
27578 # but we must check long long (if it exists) and double.
27579
27580 MAX_ALIGNOF=$ac_cv_alignof_long
27581 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
27582   MAX_ALIGNOF=$ac_cv_alignof_double
27583 fi
27584 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
27585   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
27586 fi
27587
27588 cat >>confdefs.h <<_ACEOF
27589 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
27590 _ACEOF
27591
27592
27593
27594 # Some platforms predefine the types int8, int16, etc.  Only check
27595 # a (hopefully) representative subset.
27596 { $as_echo "$as_me:$LINENO: checking for int8" >&5
27597 $as_echo_n "checking for int8... " >&6; }
27598 if test "${ac_cv_type_int8+set}" = set; then
27599   $as_echo_n "(cached) " >&6
27600 else
27601   ac_cv_type_int8=no
27602 cat >conftest.$ac_ext <<_ACEOF
27603 /* confdefs.h.  */
27604 _ACEOF
27605 cat confdefs.h >>conftest.$ac_ext
27606 cat >>conftest.$ac_ext <<_ACEOF
27607 /* end confdefs.h.  */
27608 #include <stdio.h>
27609
27610 int
27611 main ()
27612 {
27613 if (sizeof (int8))
27614        return 0;
27615   ;
27616   return 0;
27617 }
27618 _ACEOF
27619 rm -f conftest.$ac_objext
27620 if { (ac_try="$ac_compile"
27621 case "(($ac_try" in
27622   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27623   *) ac_try_echo=$ac_try;;
27624 esac
27625 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27626 $as_echo "$ac_try_echo") >&5
27627   (eval "$ac_compile") 2>conftest.er1
27628   ac_status=$?
27629   grep -v '^ *+' conftest.er1 >conftest.err
27630   rm -f conftest.er1
27631   cat conftest.err >&5
27632   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27633   (exit $ac_status); } && {
27634          test -z "$ac_c_werror_flag" ||
27635          test ! -s conftest.err
27636        } && test -s conftest.$ac_objext; then
27637   cat >conftest.$ac_ext <<_ACEOF
27638 /* confdefs.h.  */
27639 _ACEOF
27640 cat confdefs.h >>conftest.$ac_ext
27641 cat >>conftest.$ac_ext <<_ACEOF
27642 /* end confdefs.h.  */
27643 #include <stdio.h>
27644
27645 int
27646 main ()
27647 {
27648 if (sizeof ((int8)))
27649           return 0;
27650   ;
27651   return 0;
27652 }
27653 _ACEOF
27654 rm -f conftest.$ac_objext
27655 if { (ac_try="$ac_compile"
27656 case "(($ac_try" in
27657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27658   *) ac_try_echo=$ac_try;;
27659 esac
27660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27661 $as_echo "$ac_try_echo") >&5
27662   (eval "$ac_compile") 2>conftest.er1
27663   ac_status=$?
27664   grep -v '^ *+' conftest.er1 >conftest.err
27665   rm -f conftest.er1
27666   cat conftest.err >&5
27667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27668   (exit $ac_status); } && {
27669          test -z "$ac_c_werror_flag" ||
27670          test ! -s conftest.err
27671        } && test -s conftest.$ac_objext; then
27672   :
27673 else
27674   $as_echo "$as_me: failed program was:" >&5
27675 sed 's/^/| /' conftest.$ac_ext >&5
27676
27677         ac_cv_type_int8=yes
27678 fi
27679
27680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27681 else
27682   $as_echo "$as_me: failed program was:" >&5
27683 sed 's/^/| /' conftest.$ac_ext >&5
27684
27685
27686 fi
27687
27688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27689 fi
27690 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
27691 $as_echo "$ac_cv_type_int8" >&6; }
27692 if test "x$ac_cv_type_int8" = x""yes; then
27693
27694 cat >>confdefs.h <<_ACEOF
27695 #define HAVE_INT8 1
27696 _ACEOF
27697
27698
27699 fi
27700 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
27701 $as_echo_n "checking for uint8... " >&6; }
27702 if test "${ac_cv_type_uint8+set}" = set; then
27703   $as_echo_n "(cached) " >&6
27704 else
27705   ac_cv_type_uint8=no
27706 cat >conftest.$ac_ext <<_ACEOF
27707 /* confdefs.h.  */
27708 _ACEOF
27709 cat confdefs.h >>conftest.$ac_ext
27710 cat >>conftest.$ac_ext <<_ACEOF
27711 /* end confdefs.h.  */
27712 #include <stdio.h>
27713
27714 int
27715 main ()
27716 {
27717 if (sizeof (uint8))
27718        return 0;
27719   ;
27720   return 0;
27721 }
27722 _ACEOF
27723 rm -f conftest.$ac_objext
27724 if { (ac_try="$ac_compile"
27725 case "(($ac_try" in
27726   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27727   *) ac_try_echo=$ac_try;;
27728 esac
27729 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27730 $as_echo "$ac_try_echo") >&5
27731   (eval "$ac_compile") 2>conftest.er1
27732   ac_status=$?
27733   grep -v '^ *+' conftest.er1 >conftest.err
27734   rm -f conftest.er1
27735   cat conftest.err >&5
27736   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27737   (exit $ac_status); } && {
27738          test -z "$ac_c_werror_flag" ||
27739          test ! -s conftest.err
27740        } && test -s conftest.$ac_objext; then
27741   cat >conftest.$ac_ext <<_ACEOF
27742 /* confdefs.h.  */
27743 _ACEOF
27744 cat confdefs.h >>conftest.$ac_ext
27745 cat >>conftest.$ac_ext <<_ACEOF
27746 /* end confdefs.h.  */
27747 #include <stdio.h>
27748
27749 int
27750 main ()
27751 {
27752 if (sizeof ((uint8)))
27753           return 0;
27754   ;
27755   return 0;
27756 }
27757 _ACEOF
27758 rm -f conftest.$ac_objext
27759 if { (ac_try="$ac_compile"
27760 case "(($ac_try" in
27761   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27762   *) ac_try_echo=$ac_try;;
27763 esac
27764 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27765 $as_echo "$ac_try_echo") >&5
27766   (eval "$ac_compile") 2>conftest.er1
27767   ac_status=$?
27768   grep -v '^ *+' conftest.er1 >conftest.err
27769   rm -f conftest.er1
27770   cat conftest.err >&5
27771   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27772   (exit $ac_status); } && {
27773          test -z "$ac_c_werror_flag" ||
27774          test ! -s conftest.err
27775        } && test -s conftest.$ac_objext; then
27776   :
27777 else
27778   $as_echo "$as_me: failed program was:" >&5
27779 sed 's/^/| /' conftest.$ac_ext >&5
27780
27781         ac_cv_type_uint8=yes
27782 fi
27783
27784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27785 else
27786   $as_echo "$as_me: failed program was:" >&5
27787 sed 's/^/| /' conftest.$ac_ext >&5
27788
27789
27790 fi
27791
27792 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27793 fi
27794 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
27795 $as_echo "$ac_cv_type_uint8" >&6; }
27796 if test "x$ac_cv_type_uint8" = x""yes; then
27797
27798 cat >>confdefs.h <<_ACEOF
27799 #define HAVE_UINT8 1
27800 _ACEOF
27801
27802
27803 fi
27804 { $as_echo "$as_me:$LINENO: checking for int64" >&5
27805 $as_echo_n "checking for int64... " >&6; }
27806 if test "${ac_cv_type_int64+set}" = set; then
27807   $as_echo_n "(cached) " >&6
27808 else
27809   ac_cv_type_int64=no
27810 cat >conftest.$ac_ext <<_ACEOF
27811 /* confdefs.h.  */
27812 _ACEOF
27813 cat confdefs.h >>conftest.$ac_ext
27814 cat >>conftest.$ac_ext <<_ACEOF
27815 /* end confdefs.h.  */
27816 #include <stdio.h>
27817
27818 int
27819 main ()
27820 {
27821 if (sizeof (int64))
27822        return 0;
27823   ;
27824   return 0;
27825 }
27826 _ACEOF
27827 rm -f conftest.$ac_objext
27828 if { (ac_try="$ac_compile"
27829 case "(($ac_try" in
27830   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27831   *) ac_try_echo=$ac_try;;
27832 esac
27833 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27834 $as_echo "$ac_try_echo") >&5
27835   (eval "$ac_compile") 2>conftest.er1
27836   ac_status=$?
27837   grep -v '^ *+' conftest.er1 >conftest.err
27838   rm -f conftest.er1
27839   cat conftest.err >&5
27840   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27841   (exit $ac_status); } && {
27842          test -z "$ac_c_werror_flag" ||
27843          test ! -s conftest.err
27844        } && test -s conftest.$ac_objext; then
27845   cat >conftest.$ac_ext <<_ACEOF
27846 /* confdefs.h.  */
27847 _ACEOF
27848 cat confdefs.h >>conftest.$ac_ext
27849 cat >>conftest.$ac_ext <<_ACEOF
27850 /* end confdefs.h.  */
27851 #include <stdio.h>
27852
27853 int
27854 main ()
27855 {
27856 if (sizeof ((int64)))
27857           return 0;
27858   ;
27859   return 0;
27860 }
27861 _ACEOF
27862 rm -f conftest.$ac_objext
27863 if { (ac_try="$ac_compile"
27864 case "(($ac_try" in
27865   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27866   *) ac_try_echo=$ac_try;;
27867 esac
27868 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27869 $as_echo "$ac_try_echo") >&5
27870   (eval "$ac_compile") 2>conftest.er1
27871   ac_status=$?
27872   grep -v '^ *+' conftest.er1 >conftest.err
27873   rm -f conftest.er1
27874   cat conftest.err >&5
27875   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27876   (exit $ac_status); } && {
27877          test -z "$ac_c_werror_flag" ||
27878          test ! -s conftest.err
27879        } && test -s conftest.$ac_objext; then
27880   :
27881 else
27882   $as_echo "$as_me: failed program was:" >&5
27883 sed 's/^/| /' conftest.$ac_ext >&5
27884
27885         ac_cv_type_int64=yes
27886 fi
27887
27888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27889 else
27890   $as_echo "$as_me: failed program was:" >&5
27891 sed 's/^/| /' conftest.$ac_ext >&5
27892
27893
27894 fi
27895
27896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27897 fi
27898 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
27899 $as_echo "$ac_cv_type_int64" >&6; }
27900 if test "x$ac_cv_type_int64" = x""yes; then
27901
27902 cat >>confdefs.h <<_ACEOF
27903 #define HAVE_INT64 1
27904 _ACEOF
27905
27906
27907 fi
27908 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
27909 $as_echo_n "checking for uint64... " >&6; }
27910 if test "${ac_cv_type_uint64+set}" = set; then
27911   $as_echo_n "(cached) " >&6
27912 else
27913   ac_cv_type_uint64=no
27914 cat >conftest.$ac_ext <<_ACEOF
27915 /* confdefs.h.  */
27916 _ACEOF
27917 cat confdefs.h >>conftest.$ac_ext
27918 cat >>conftest.$ac_ext <<_ACEOF
27919 /* end confdefs.h.  */
27920 #include <stdio.h>
27921
27922 int
27923 main ()
27924 {
27925 if (sizeof (uint64))
27926        return 0;
27927   ;
27928   return 0;
27929 }
27930 _ACEOF
27931 rm -f conftest.$ac_objext
27932 if { (ac_try="$ac_compile"
27933 case "(($ac_try" in
27934   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27935   *) ac_try_echo=$ac_try;;
27936 esac
27937 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27938 $as_echo "$ac_try_echo") >&5
27939   (eval "$ac_compile") 2>conftest.er1
27940   ac_status=$?
27941   grep -v '^ *+' conftest.er1 >conftest.err
27942   rm -f conftest.er1
27943   cat conftest.err >&5
27944   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27945   (exit $ac_status); } && {
27946          test -z "$ac_c_werror_flag" ||
27947          test ! -s conftest.err
27948        } && test -s conftest.$ac_objext; then
27949   cat >conftest.$ac_ext <<_ACEOF
27950 /* confdefs.h.  */
27951 _ACEOF
27952 cat confdefs.h >>conftest.$ac_ext
27953 cat >>conftest.$ac_ext <<_ACEOF
27954 /* end confdefs.h.  */
27955 #include <stdio.h>
27956
27957 int
27958 main ()
27959 {
27960 if (sizeof ((uint64)))
27961           return 0;
27962   ;
27963   return 0;
27964 }
27965 _ACEOF
27966 rm -f conftest.$ac_objext
27967 if { (ac_try="$ac_compile"
27968 case "(($ac_try" in
27969   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27970   *) ac_try_echo=$ac_try;;
27971 esac
27972 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27973 $as_echo "$ac_try_echo") >&5
27974   (eval "$ac_compile") 2>conftest.er1
27975   ac_status=$?
27976   grep -v '^ *+' conftest.er1 >conftest.err
27977   rm -f conftest.er1
27978   cat conftest.err >&5
27979   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27980   (exit $ac_status); } && {
27981          test -z "$ac_c_werror_flag" ||
27982          test ! -s conftest.err
27983        } && test -s conftest.$ac_objext; then
27984   :
27985 else
27986   $as_echo "$as_me: failed program was:" >&5
27987 sed 's/^/| /' conftest.$ac_ext >&5
27988
27989         ac_cv_type_uint64=yes
27990 fi
27991
27992 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27993 else
27994   $as_echo "$as_me: failed program was:" >&5
27995 sed 's/^/| /' conftest.$ac_ext >&5
27996
27997
27998 fi
27999
28000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28001 fi
28002 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
28003 $as_echo "$ac_cv_type_uint64" >&6; }
28004 if test "x$ac_cv_type_uint64" = x""yes; then
28005
28006 cat >>confdefs.h <<_ACEOF
28007 #define HAVE_UINT64 1
28008 _ACEOF
28009
28010
28011 fi
28012
28013
28014 # We also check for sig_atomic_t, which *should* be defined per ANSI
28015 # C, but is missing on some old platforms.
28016 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
28017 $as_echo_n "checking for sig_atomic_t... " >&6; }
28018 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
28019   $as_echo_n "(cached) " >&6
28020 else
28021   ac_cv_type_sig_atomic_t=no
28022 cat >conftest.$ac_ext <<_ACEOF
28023 /* confdefs.h.  */
28024 _ACEOF
28025 cat confdefs.h >>conftest.$ac_ext
28026 cat >>conftest.$ac_ext <<_ACEOF
28027 /* end confdefs.h.  */
28028 #include <signal.h>
28029
28030 int
28031 main ()
28032 {
28033 if (sizeof (sig_atomic_t))
28034        return 0;
28035   ;
28036   return 0;
28037 }
28038 _ACEOF
28039 rm -f conftest.$ac_objext
28040 if { (ac_try="$ac_compile"
28041 case "(($ac_try" in
28042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28043   *) ac_try_echo=$ac_try;;
28044 esac
28045 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28046 $as_echo "$ac_try_echo") >&5
28047   (eval "$ac_compile") 2>conftest.er1
28048   ac_status=$?
28049   grep -v '^ *+' conftest.er1 >conftest.err
28050   rm -f conftest.er1
28051   cat conftest.err >&5
28052   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28053   (exit $ac_status); } && {
28054          test -z "$ac_c_werror_flag" ||
28055          test ! -s conftest.err
28056        } && test -s conftest.$ac_objext; then
28057   cat >conftest.$ac_ext <<_ACEOF
28058 /* confdefs.h.  */
28059 _ACEOF
28060 cat confdefs.h >>conftest.$ac_ext
28061 cat >>conftest.$ac_ext <<_ACEOF
28062 /* end confdefs.h.  */
28063 #include <signal.h>
28064
28065 int
28066 main ()
28067 {
28068 if (sizeof ((sig_atomic_t)))
28069           return 0;
28070   ;
28071   return 0;
28072 }
28073 _ACEOF
28074 rm -f conftest.$ac_objext
28075 if { (ac_try="$ac_compile"
28076 case "(($ac_try" in
28077   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28078   *) ac_try_echo=$ac_try;;
28079 esac
28080 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28081 $as_echo "$ac_try_echo") >&5
28082   (eval "$ac_compile") 2>conftest.er1
28083   ac_status=$?
28084   grep -v '^ *+' conftest.er1 >conftest.err
28085   rm -f conftest.er1
28086   cat conftest.err >&5
28087   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28088   (exit $ac_status); } && {
28089          test -z "$ac_c_werror_flag" ||
28090          test ! -s conftest.err
28091        } && test -s conftest.$ac_objext; then
28092   :
28093 else
28094   $as_echo "$as_me: failed program was:" >&5
28095 sed 's/^/| /' conftest.$ac_ext >&5
28096
28097         ac_cv_type_sig_atomic_t=yes
28098 fi
28099
28100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28101 else
28102   $as_echo "$as_me: failed program was:" >&5
28103 sed 's/^/| /' conftest.$ac_ext >&5
28104
28105
28106 fi
28107
28108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28109 fi
28110 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
28111 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
28112 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
28113
28114 cat >>confdefs.h <<_ACEOF
28115 #define HAVE_SIG_ATOMIC_T 1
28116 _ACEOF
28117
28118
28119 fi
28120
28121
28122
28123 if test "$PORTNAME" != "win32"
28124 then
28125 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
28126 $as_echo_n "checking for POSIX signal interface... " >&6; }
28127 if test "${pgac_cv_func_posix_signals+set}" = set; then
28128   $as_echo_n "(cached) " >&6
28129 else
28130   cat >conftest.$ac_ext <<_ACEOF
28131 /* confdefs.h.  */
28132 _ACEOF
28133 cat confdefs.h >>conftest.$ac_ext
28134 cat >>conftest.$ac_ext <<_ACEOF
28135 /* end confdefs.h.  */
28136 #include <signal.h>
28137
28138 int
28139 main ()
28140 {
28141 struct sigaction act, oact;
28142 sigemptyset(&act.sa_mask);
28143 act.sa_flags = SA_RESTART;
28144 sigaction(0, &act, &oact);
28145   ;
28146   return 0;
28147 }
28148 _ACEOF
28149 rm -f conftest.$ac_objext conftest$ac_exeext
28150 if { (ac_try="$ac_link"
28151 case "(($ac_try" in
28152   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28153   *) ac_try_echo=$ac_try;;
28154 esac
28155 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28156 $as_echo "$ac_try_echo") >&5
28157   (eval "$ac_link") 2>conftest.er1
28158   ac_status=$?
28159   grep -v '^ *+' conftest.er1 >conftest.err
28160   rm -f conftest.er1
28161   cat conftest.err >&5
28162   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28163   (exit $ac_status); } && {
28164          test -z "$ac_c_werror_flag" ||
28165          test ! -s conftest.err
28166        } && test -s conftest$ac_exeext && {
28167          test "$cross_compiling" = yes ||
28168          $as_test_x conftest$ac_exeext
28169        }; then
28170   pgac_cv_func_posix_signals=yes
28171 else
28172   $as_echo "$as_me: failed program was:" >&5
28173 sed 's/^/| /' conftest.$ac_ext >&5
28174
28175         pgac_cv_func_posix_signals=no
28176 fi
28177
28178 rm -rf conftest.dSYM
28179 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28180       conftest$ac_exeext conftest.$ac_ext
28181 fi
28182 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
28183 $as_echo "$pgac_cv_func_posix_signals" >&6; }
28184 if test x"$pgac_cv_func_posix_signals" = xyes ; then
28185
28186 cat >>confdefs.h <<\_ACEOF
28187 #define HAVE_POSIX_SIGNALS /**/
28188 _ACEOF
28189
28190 fi
28191 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
28192
28193 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
28194   { { $as_echo "$as_me:$LINENO: error:
28195 Thread-safety requires POSIX signals, which are not supported by this
28196 operating system;  use --disable-thread-safety to disable thread safety." >&5
28197 $as_echo "$as_me: error:
28198 Thread-safety requires POSIX signals, which are not supported by this
28199 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
28200    { (exit 1); exit 1; }; }
28201 fi
28202 fi
28203
28204 # SunOS doesn't handle negative byte comparisons properly with +/- return
28205 { $as_echo "$as_me:$LINENO: checking for working memcmp" >&5
28206 $as_echo_n "checking for working memcmp... " >&6; }
28207 if test "${ac_cv_func_memcmp_working+set}" = set; then
28208   $as_echo_n "(cached) " >&6
28209 else
28210   if test "$cross_compiling" = yes; then
28211   ac_cv_func_memcmp_working=no
28212 else
28213   cat >conftest.$ac_ext <<_ACEOF
28214 /* confdefs.h.  */
28215 _ACEOF
28216 cat confdefs.h >>conftest.$ac_ext
28217 cat >>conftest.$ac_ext <<_ACEOF
28218 /* end confdefs.h.  */
28219 $ac_includes_default
28220 int
28221 main ()
28222 {
28223
28224   /* Some versions of memcmp are not 8-bit clean.  */
28225   char c0 = '\100', c1 = '\200', c2 = '\201';
28226   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
28227     return 1;
28228
28229   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
28230      or more and with at least one buffer not starting on a 4-byte boundary.
28231      William Lewis provided this test program.   */
28232   {
28233     char foo[21];
28234     char bar[21];
28235     int i;
28236     for (i = 0; i < 4; i++)
28237       {
28238         char *a = foo + i;
28239         char *b = bar + i;
28240         strcpy (a, "--------01111111");
28241         strcpy (b, "--------10000000");
28242         if (memcmp (a, b, 16) >= 0)
28243           return 1;
28244       }
28245     return 0;
28246   }
28247
28248   ;
28249   return 0;
28250 }
28251 _ACEOF
28252 rm -f conftest$ac_exeext
28253 if { (ac_try="$ac_link"
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_link") 2>&5
28261   ac_status=$?
28262   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28263   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28264   { (case "(($ac_try" in
28265   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28266   *) ac_try_echo=$ac_try;;
28267 esac
28268 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28269 $as_echo "$ac_try_echo") >&5
28270   (eval "$ac_try") 2>&5
28271   ac_status=$?
28272   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28273   (exit $ac_status); }; }; then
28274   ac_cv_func_memcmp_working=yes
28275 else
28276   $as_echo "$as_me: program exited with status $ac_status" >&5
28277 $as_echo "$as_me: failed program was:" >&5
28278 sed 's/^/| /' conftest.$ac_ext >&5
28279
28280 ( exit $ac_status )
28281 ac_cv_func_memcmp_working=no
28282 fi
28283 rm -rf conftest.dSYM
28284 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28285 fi
28286
28287
28288 fi
28289 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
28290 $as_echo "$ac_cv_func_memcmp_working" >&6; }
28291 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
28292   *" memcmp.$ac_objext "* ) ;;
28293   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
28294  ;;
28295 esac
28296
28297
28298
28299
28300 # Select semaphore implementation type.
28301 if test "$PORTNAME" != "win32"; then
28302   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
28303
28304 cat >>confdefs.h <<\_ACEOF
28305 #define USE_NAMED_POSIX_SEMAPHORES 1
28306 _ACEOF
28307
28308     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28309   else
28310     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
28311
28312 cat >>confdefs.h <<\_ACEOF
28313 #define USE_UNNAMED_POSIX_SEMAPHORES 1
28314 _ACEOF
28315
28316       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28317     else
28318
28319 cat >>confdefs.h <<\_ACEOF
28320 #define USE_SYSV_SEMAPHORES 1
28321 _ACEOF
28322
28323       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
28324     fi
28325   fi
28326 else
28327
28328 cat >>confdefs.h <<\_ACEOF
28329 #define USE_WIN32_SEMAPHORES 1
28330 _ACEOF
28331
28332   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
28333 fi
28334
28335
28336 # Select shared-memory implementation type.
28337 if test "$PORTNAME" != "win32"; then
28338
28339 cat >>confdefs.h <<\_ACEOF
28340 #define USE_SYSV_SHARED_MEMORY 1
28341 _ACEOF
28342
28343   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
28344 else
28345
28346 cat >>confdefs.h <<\_ACEOF
28347 #define USE_WIN32_SHARED_MEMORY 1
28348 _ACEOF
28349
28350   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
28351 fi
28352
28353 # Select latch implementation type.
28354 if test "$PORTNAME" != "win32"; then
28355   LATCH_IMPLEMENTATION="src/backend/port/unix_latch.c"
28356 else
28357   LATCH_IMPLEMENTATION="src/backend/port/win32_latch.c"
28358 fi
28359
28360 # If not set in template file, set bytes to use libc memset()
28361 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
28362   MEMSET_LOOP_LIMIT=1024
28363 fi
28364
28365 cat >>confdefs.h <<_ACEOF
28366 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
28367 _ACEOF
28368
28369
28370
28371 if test "$enable_nls" = yes ; then
28372
28373   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
28374 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
28375 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28376   $as_echo_n "(cached) " >&6
28377 else
28378   ac_func_search_save_LIBS=$LIBS
28379 cat >conftest.$ac_ext <<_ACEOF
28380 /* confdefs.h.  */
28381 _ACEOF
28382 cat confdefs.h >>conftest.$ac_ext
28383 cat >>conftest.$ac_ext <<_ACEOF
28384 /* end confdefs.h.  */
28385
28386 /* Override any GCC internal prototype to avoid an error.
28387    Use char because int might match the return type of a GCC
28388    builtin and then its argument prototype would still apply.  */
28389 #ifdef __cplusplus
28390 extern "C"
28391 #endif
28392 char bind_textdomain_codeset ();
28393 int
28394 main ()
28395 {
28396 return bind_textdomain_codeset ();
28397   ;
28398   return 0;
28399 }
28400 _ACEOF
28401 for ac_lib in '' intl; do
28402   if test -z "$ac_lib"; then
28403     ac_res="none required"
28404   else
28405     ac_res=-l$ac_lib
28406     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
28407   fi
28408   rm -f conftest.$ac_objext conftest$ac_exeext
28409 if { (ac_try="$ac_link"
28410 case "(($ac_try" in
28411   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28412   *) ac_try_echo=$ac_try;;
28413 esac
28414 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28415 $as_echo "$ac_try_echo") >&5
28416   (eval "$ac_link") 2>conftest.er1
28417   ac_status=$?
28418   grep -v '^ *+' conftest.er1 >conftest.err
28419   rm -f conftest.er1
28420   cat conftest.err >&5
28421   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28422   (exit $ac_status); } && {
28423          test -z "$ac_c_werror_flag" ||
28424          test ! -s conftest.err
28425        } && test -s conftest$ac_exeext && {
28426          test "$cross_compiling" = yes ||
28427          $as_test_x conftest$ac_exeext
28428        }; then
28429   ac_cv_search_bind_textdomain_codeset=$ac_res
28430 else
28431   $as_echo "$as_me: failed program was:" >&5
28432 sed 's/^/| /' conftest.$ac_ext >&5
28433
28434
28435 fi
28436
28437 rm -rf conftest.dSYM
28438 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28439       conftest$ac_exeext
28440   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28441   break
28442 fi
28443 done
28444 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28445   :
28446 else
28447   ac_cv_search_bind_textdomain_codeset=no
28448 fi
28449 rm conftest.$ac_ext
28450 LIBS=$ac_func_search_save_LIBS
28451 fi
28452 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
28453 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
28454 ac_res=$ac_cv_search_bind_textdomain_codeset
28455 if test "$ac_res" != no; then
28456   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28457
28458 else
28459   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
28460 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
28461    { (exit 1); exit 1; }; }
28462 fi
28463
28464   if test "${ac_cv_header_libintl_h+set}" = set; then
28465   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28466 $as_echo_n "checking for libintl.h... " >&6; }
28467 if test "${ac_cv_header_libintl_h+set}" = set; then
28468   $as_echo_n "(cached) " >&6
28469 fi
28470 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28471 $as_echo "$ac_cv_header_libintl_h" >&6; }
28472 else
28473   # Is the header compilable?
28474 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
28475 $as_echo_n "checking libintl.h usability... " >&6; }
28476 cat >conftest.$ac_ext <<_ACEOF
28477 /* confdefs.h.  */
28478 _ACEOF
28479 cat confdefs.h >>conftest.$ac_ext
28480 cat >>conftest.$ac_ext <<_ACEOF
28481 /* end confdefs.h.  */
28482 $ac_includes_default
28483 #include <libintl.h>
28484 _ACEOF
28485 rm -f conftest.$ac_objext
28486 if { (ac_try="$ac_compile"
28487 case "(($ac_try" in
28488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28489   *) ac_try_echo=$ac_try;;
28490 esac
28491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28492 $as_echo "$ac_try_echo") >&5
28493   (eval "$ac_compile") 2>conftest.er1
28494   ac_status=$?
28495   grep -v '^ *+' conftest.er1 >conftest.err
28496   rm -f conftest.er1
28497   cat conftest.err >&5
28498   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28499   (exit $ac_status); } && {
28500          test -z "$ac_c_werror_flag" ||
28501          test ! -s conftest.err
28502        } && test -s conftest.$ac_objext; then
28503   ac_header_compiler=yes
28504 else
28505   $as_echo "$as_me: failed program was:" >&5
28506 sed 's/^/| /' conftest.$ac_ext >&5
28507
28508         ac_header_compiler=no
28509 fi
28510
28511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28512 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28513 $as_echo "$ac_header_compiler" >&6; }
28514
28515 # Is the header present?
28516 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
28517 $as_echo_n "checking libintl.h presence... " >&6; }
28518 cat >conftest.$ac_ext <<_ACEOF
28519 /* confdefs.h.  */
28520 _ACEOF
28521 cat confdefs.h >>conftest.$ac_ext
28522 cat >>conftest.$ac_ext <<_ACEOF
28523 /* end confdefs.h.  */
28524 #include <libintl.h>
28525 _ACEOF
28526 if { (ac_try="$ac_cpp conftest.$ac_ext"
28527 case "(($ac_try" in
28528   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28529   *) ac_try_echo=$ac_try;;
28530 esac
28531 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28532 $as_echo "$ac_try_echo") >&5
28533   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28534   ac_status=$?
28535   grep -v '^ *+' conftest.er1 >conftest.err
28536   rm -f conftest.er1
28537   cat conftest.err >&5
28538   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28539   (exit $ac_status); } >/dev/null && {
28540          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28541          test ! -s conftest.err
28542        }; then
28543   ac_header_preproc=yes
28544 else
28545   $as_echo "$as_me: failed program was:" >&5
28546 sed 's/^/| /' conftest.$ac_ext >&5
28547
28548   ac_header_preproc=no
28549 fi
28550
28551 rm -f conftest.err conftest.$ac_ext
28552 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28553 $as_echo "$ac_header_preproc" >&6; }
28554
28555 # So?  What about this header?
28556 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28557   yes:no: )
28558     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28559 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28560     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
28561 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
28562     ac_header_preproc=yes
28563     ;;
28564   no:yes:* )
28565     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
28566 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
28567     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
28568 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
28569     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
28570 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
28571     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
28572 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28573     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
28574 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
28575     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
28576 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
28577     ( cat <<\_ASBOX
28578 ## ---------------------------------------- ##
28579 ## Report this to pgsql-bugs@postgresql.org ##
28580 ## ---------------------------------------- ##
28581 _ASBOX
28582      ) | sed "s/^/$as_me: WARNING:     /" >&2
28583     ;;
28584 esac
28585 { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28586 $as_echo_n "checking for libintl.h... " >&6; }
28587 if test "${ac_cv_header_libintl_h+set}" = set; then
28588   $as_echo_n "(cached) " >&6
28589 else
28590   ac_cv_header_libintl_h=$ac_header_preproc
28591 fi
28592 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28593 $as_echo "$ac_cv_header_libintl_h" >&6; }
28594
28595 fi
28596 if test "x$ac_cv_header_libintl_h" = x""yes; then
28597   :
28598 else
28599   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
28600 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
28601    { (exit 1); exit 1; }; }
28602 fi
28603
28604
28605   for ac_prog in msgfmt
28606 do
28607   # Extract the first word of "$ac_prog", so it can be a program name with args.
28608 set dummy $ac_prog; ac_word=$2
28609 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28610 $as_echo_n "checking for $ac_word... " >&6; }
28611 if test "${ac_cv_prog_MSGFMT+set}" = set; then
28612   $as_echo_n "(cached) " >&6
28613 else
28614   if test -n "$MSGFMT"; then
28615   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
28616 else
28617 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28618 for as_dir in $PATH
28619 do
28620   IFS=$as_save_IFS
28621   test -z "$as_dir" && as_dir=.
28622   for ac_exec_ext in '' $ac_executable_extensions; do
28623   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28624     ac_cv_prog_MSGFMT="$ac_prog"
28625     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28626     break 2
28627   fi
28628 done
28629 done
28630 IFS=$as_save_IFS
28631
28632 fi
28633 fi
28634 MSGFMT=$ac_cv_prog_MSGFMT
28635 if test -n "$MSGFMT"; then
28636   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
28637 $as_echo "$MSGFMT" >&6; }
28638 else
28639   { $as_echo "$as_me:$LINENO: result: no" >&5
28640 $as_echo "no" >&6; }
28641 fi
28642
28643
28644   test -n "$MSGFMT" && break
28645 done
28646
28647   if test -z "$MSGFMT"; then
28648     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
28649 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
28650    { (exit 1); exit 1; }; }
28651   fi
28652   for ac_prog in msgmerge
28653 do
28654   # Extract the first word of "$ac_prog", so it can be a program name with args.
28655 set dummy $ac_prog; ac_word=$2
28656 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28657 $as_echo_n "checking for $ac_word... " >&6; }
28658 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
28659   $as_echo_n "(cached) " >&6
28660 else
28661   if test -n "$MSGMERGE"; then
28662   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
28663 else
28664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28665 for as_dir in $PATH
28666 do
28667   IFS=$as_save_IFS
28668   test -z "$as_dir" && as_dir=.
28669   for ac_exec_ext in '' $ac_executable_extensions; do
28670   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28671     ac_cv_prog_MSGMERGE="$ac_prog"
28672     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28673     break 2
28674   fi
28675 done
28676 done
28677 IFS=$as_save_IFS
28678
28679 fi
28680 fi
28681 MSGMERGE=$ac_cv_prog_MSGMERGE
28682 if test -n "$MSGMERGE"; then
28683   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
28684 $as_echo "$MSGMERGE" >&6; }
28685 else
28686   { $as_echo "$as_me:$LINENO: result: no" >&5
28687 $as_echo "no" >&6; }
28688 fi
28689
28690
28691   test -n "$MSGMERGE" && break
28692 done
28693
28694   for ac_prog in xgettext
28695 do
28696   # Extract the first word of "$ac_prog", so it can be a program name with args.
28697 set dummy $ac_prog; ac_word=$2
28698 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28699 $as_echo_n "checking for $ac_word... " >&6; }
28700 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
28701   $as_echo_n "(cached) " >&6
28702 else
28703   if test -n "$XGETTEXT"; then
28704   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
28705 else
28706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28707 for as_dir in $PATH
28708 do
28709   IFS=$as_save_IFS
28710   test -z "$as_dir" && as_dir=.
28711   for ac_exec_ext in '' $ac_executable_extensions; do
28712   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28713     ac_cv_prog_XGETTEXT="$ac_prog"
28714     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28715     break 2
28716   fi
28717 done
28718 done
28719 IFS=$as_save_IFS
28720
28721 fi
28722 fi
28723 XGETTEXT=$ac_cv_prog_XGETTEXT
28724 if test -n "$XGETTEXT"; then
28725   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
28726 $as_echo "$XGETTEXT" >&6; }
28727 else
28728   { $as_echo "$as_me:$LINENO: result: no" >&5
28729 $as_echo "no" >&6; }
28730 fi
28731
28732
28733   test -n "$XGETTEXT" && break
28734 done
28735
28736
28737 fi
28738
28739 # Check for Tcl configuration script tclConfig.sh
28740 if test "$with_tcl" = yes; then
28741     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
28742 do
28743   # Extract the first word of "$ac_prog", so it can be a program name with args.
28744 set dummy $ac_prog; ac_word=$2
28745 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28746 $as_echo_n "checking for $ac_word... " >&6; }
28747 if test "${ac_cv_path_TCLSH+set}" = set; then
28748   $as_echo_n "(cached) " >&6
28749 else
28750   case $TCLSH in
28751   [\\/]* | ?:[\\/]*)
28752   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
28753   ;;
28754   *)
28755   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28756 for as_dir in $PATH
28757 do
28758   IFS=$as_save_IFS
28759   test -z "$as_dir" && as_dir=.
28760   for ac_exec_ext in '' $ac_executable_extensions; do
28761   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28762     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
28763     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28764     break 2
28765   fi
28766 done
28767 done
28768 IFS=$as_save_IFS
28769
28770   ;;
28771 esac
28772 fi
28773 TCLSH=$ac_cv_path_TCLSH
28774 if test -n "$TCLSH"; then
28775   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
28776 $as_echo "$TCLSH" >&6; }
28777 else
28778   { $as_echo "$as_me:$LINENO: result: no" >&5
28779 $as_echo "no" >&6; }
28780 fi
28781
28782
28783   test -n "$TCLSH" && break
28784 done
28785
28786 if test x"$TCLSH" = x""; then
28787   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
28788 $as_echo "$as_me: error: Tcl shell not found" >&2;}
28789    { (exit 1); exit 1; }; }
28790 fi
28791
28792 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
28793 $as_echo_n "checking for tclConfig.sh... " >&6; }
28794 # Let user override test
28795 if test -z "$TCL_CONFIG_SH"; then
28796     pgac_test_dirs="$with_tclconfig"
28797
28798     set X $pgac_test_dirs; shift
28799     if test $# -eq 0; then
28800         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
28801 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
28802    { (exit 1); exit 1; }; }
28803         set X `echo 'puts $auto_path' | $TCLSH`; shift
28804     fi
28805
28806     for pgac_dir do
28807         if test -r "$pgac_dir/tclConfig.sh"; then
28808             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
28809             break
28810         fi
28811     done
28812 fi
28813
28814 if test -z "$TCL_CONFIG_SH"; then
28815     { $as_echo "$as_me:$LINENO: result: no" >&5
28816 $as_echo "no" >&6; }
28817     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
28818 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
28819    { (exit 1); exit 1; }; }
28820 else
28821     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
28822 $as_echo "$TCL_CONFIG_SH" >&6; }
28823 fi
28824
28825
28826
28827     . "$TCL_CONFIG_SH"
28828 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
28829 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
28830 eval TCL_LIBS=\"$TCL_LIBS\"
28831 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
28832 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
28833
28834         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
28835     ac_save_CPPFLAGS=$CPPFLAGS
28836     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
28837     if test "${ac_cv_header_tcl_h+set}" = set; then
28838   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28839 $as_echo_n "checking for tcl.h... " >&6; }
28840 if test "${ac_cv_header_tcl_h+set}" = set; then
28841   $as_echo_n "(cached) " >&6
28842 fi
28843 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28844 $as_echo "$ac_cv_header_tcl_h" >&6; }
28845 else
28846   # Is the header compilable?
28847 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
28848 $as_echo_n "checking tcl.h usability... " >&6; }
28849 cat >conftest.$ac_ext <<_ACEOF
28850 /* confdefs.h.  */
28851 _ACEOF
28852 cat confdefs.h >>conftest.$ac_ext
28853 cat >>conftest.$ac_ext <<_ACEOF
28854 /* end confdefs.h.  */
28855 $ac_includes_default
28856 #include <tcl.h>
28857 _ACEOF
28858 rm -f conftest.$ac_objext
28859 if { (ac_try="$ac_compile"
28860 case "(($ac_try" in
28861   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28862   *) ac_try_echo=$ac_try;;
28863 esac
28864 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28865 $as_echo "$ac_try_echo") >&5
28866   (eval "$ac_compile") 2>conftest.er1
28867   ac_status=$?
28868   grep -v '^ *+' conftest.er1 >conftest.err
28869   rm -f conftest.er1
28870   cat conftest.err >&5
28871   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28872   (exit $ac_status); } && {
28873          test -z "$ac_c_werror_flag" ||
28874          test ! -s conftest.err
28875        } && test -s conftest.$ac_objext; then
28876   ac_header_compiler=yes
28877 else
28878   $as_echo "$as_me: failed program was:" >&5
28879 sed 's/^/| /' conftest.$ac_ext >&5
28880
28881         ac_header_compiler=no
28882 fi
28883
28884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28885 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28886 $as_echo "$ac_header_compiler" >&6; }
28887
28888 # Is the header present?
28889 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
28890 $as_echo_n "checking tcl.h presence... " >&6; }
28891 cat >conftest.$ac_ext <<_ACEOF
28892 /* confdefs.h.  */
28893 _ACEOF
28894 cat confdefs.h >>conftest.$ac_ext
28895 cat >>conftest.$ac_ext <<_ACEOF
28896 /* end confdefs.h.  */
28897 #include <tcl.h>
28898 _ACEOF
28899 if { (ac_try="$ac_cpp conftest.$ac_ext"
28900 case "(($ac_try" in
28901   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28902   *) ac_try_echo=$ac_try;;
28903 esac
28904 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28905 $as_echo "$ac_try_echo") >&5
28906   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28907   ac_status=$?
28908   grep -v '^ *+' conftest.er1 >conftest.err
28909   rm -f conftest.er1
28910   cat conftest.err >&5
28911   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28912   (exit $ac_status); } >/dev/null && {
28913          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28914          test ! -s conftest.err
28915        }; then
28916   ac_header_preproc=yes
28917 else
28918   $as_echo "$as_me: failed program was:" >&5
28919 sed 's/^/| /' conftest.$ac_ext >&5
28920
28921   ac_header_preproc=no
28922 fi
28923
28924 rm -f conftest.err conftest.$ac_ext
28925 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28926 $as_echo "$ac_header_preproc" >&6; }
28927
28928 # So?  What about this header?
28929 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28930   yes:no: )
28931     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28932 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28933     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
28934 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
28935     ac_header_preproc=yes
28936     ;;
28937   no:yes:* )
28938     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
28939 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
28940     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
28941 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
28942     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
28943 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
28944     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
28945 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28946     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
28947 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
28948     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
28949 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
28950     ( cat <<\_ASBOX
28951 ## ---------------------------------------- ##
28952 ## Report this to pgsql-bugs@postgresql.org ##
28953 ## ---------------------------------------- ##
28954 _ASBOX
28955      ) | sed "s/^/$as_me: WARNING:     /" >&2
28956     ;;
28957 esac
28958 { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28959 $as_echo_n "checking for tcl.h... " >&6; }
28960 if test "${ac_cv_header_tcl_h+set}" = set; then
28961   $as_echo_n "(cached) " >&6
28962 else
28963   ac_cv_header_tcl_h=$ac_header_preproc
28964 fi
28965 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28966 $as_echo "$ac_cv_header_tcl_h" >&6; }
28967
28968 fi
28969 if test "x$ac_cv_header_tcl_h" = x""yes; then
28970   :
28971 else
28972   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
28973 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
28974    { (exit 1); exit 1; }; }
28975 fi
28976
28977
28978     CPPFLAGS=$ac_save_CPPFLAGS
28979 fi
28980
28981 # check for <Python.h>
28982 if test "$with_python" = yes; then
28983   ac_save_CPPFLAGS=$CPPFLAGS
28984   CPPFLAGS="$python_includespec $CPPFLAGS"
28985   if test "${ac_cv_header_Python_h+set}" = set; then
28986   { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
28987 $as_echo_n "checking for Python.h... " >&6; }
28988 if test "${ac_cv_header_Python_h+set}" = set; then
28989   $as_echo_n "(cached) " >&6
28990 fi
28991 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
28992 $as_echo "$ac_cv_header_Python_h" >&6; }
28993 else
28994   # Is the header compilable?
28995 { $as_echo "$as_me:$LINENO: checking Python.h usability" >&5
28996 $as_echo_n "checking Python.h usability... " >&6; }
28997 cat >conftest.$ac_ext <<_ACEOF
28998 /* confdefs.h.  */
28999 _ACEOF
29000 cat confdefs.h >>conftest.$ac_ext
29001 cat >>conftest.$ac_ext <<_ACEOF
29002 /* end confdefs.h.  */
29003 $ac_includes_default
29004 #include <Python.h>
29005 _ACEOF
29006 rm -f conftest.$ac_objext
29007 if { (ac_try="$ac_compile"
29008 case "(($ac_try" in
29009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29010   *) ac_try_echo=$ac_try;;
29011 esac
29012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29013 $as_echo "$ac_try_echo") >&5
29014   (eval "$ac_compile") 2>conftest.er1
29015   ac_status=$?
29016   grep -v '^ *+' conftest.er1 >conftest.err
29017   rm -f conftest.er1
29018   cat conftest.err >&5
29019   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29020   (exit $ac_status); } && {
29021          test -z "$ac_c_werror_flag" ||
29022          test ! -s conftest.err
29023        } && test -s conftest.$ac_objext; then
29024   ac_header_compiler=yes
29025 else
29026   $as_echo "$as_me: failed program was:" >&5
29027 sed 's/^/| /' conftest.$ac_ext >&5
29028
29029         ac_header_compiler=no
29030 fi
29031
29032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29033 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29034 $as_echo "$ac_header_compiler" >&6; }
29035
29036 # Is the header present?
29037 { $as_echo "$as_me:$LINENO: checking Python.h presence" >&5
29038 $as_echo_n "checking Python.h presence... " >&6; }
29039 cat >conftest.$ac_ext <<_ACEOF
29040 /* confdefs.h.  */
29041 _ACEOF
29042 cat confdefs.h >>conftest.$ac_ext
29043 cat >>conftest.$ac_ext <<_ACEOF
29044 /* end confdefs.h.  */
29045 #include <Python.h>
29046 _ACEOF
29047 if { (ac_try="$ac_cpp conftest.$ac_ext"
29048 case "(($ac_try" in
29049   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29050   *) ac_try_echo=$ac_try;;
29051 esac
29052 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29053 $as_echo "$ac_try_echo") >&5
29054   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
29055   ac_status=$?
29056   grep -v '^ *+' conftest.er1 >conftest.err
29057   rm -f conftest.er1
29058   cat conftest.err >&5
29059   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29060   (exit $ac_status); } >/dev/null && {
29061          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
29062          test ! -s conftest.err
29063        }; then
29064   ac_header_preproc=yes
29065 else
29066   $as_echo "$as_me: failed program was:" >&5
29067 sed 's/^/| /' conftest.$ac_ext >&5
29068
29069   ac_header_preproc=no
29070 fi
29071
29072 rm -f conftest.err conftest.$ac_ext
29073 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29074 $as_echo "$ac_header_preproc" >&6; }
29075
29076 # So?  What about this header?
29077 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
29078   yes:no: )
29079     { $as_echo "$as_me:$LINENO: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&5
29080 $as_echo "$as_me: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
29081     { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the compiler's result" >&5
29082 $as_echo "$as_me: WARNING: Python.h: proceeding with the compiler's result" >&2;}
29083     ac_header_preproc=yes
29084     ;;
29085   no:yes:* )
29086     { $as_echo "$as_me:$LINENO: WARNING: Python.h: present but cannot be compiled" >&5
29087 $as_echo "$as_me: WARNING: Python.h: present but cannot be compiled" >&2;}
29088     { $as_echo "$as_me:$LINENO: WARNING: Python.h:     check for missing prerequisite headers?" >&5
29089 $as_echo "$as_me: WARNING: Python.h:     check for missing prerequisite headers?" >&2;}
29090     { $as_echo "$as_me:$LINENO: WARNING: Python.h: see the Autoconf documentation" >&5
29091 $as_echo "$as_me: WARNING: Python.h: see the Autoconf documentation" >&2;}
29092     { $as_echo "$as_me:$LINENO: WARNING: Python.h:     section \"Present But Cannot Be Compiled\"" >&5
29093 $as_echo "$as_me: WARNING: Python.h:     section \"Present But Cannot Be Compiled\"" >&2;}
29094     { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the preprocessor's result" >&5
29095 $as_echo "$as_me: WARNING: Python.h: proceeding with the preprocessor's result" >&2;}
29096     { $as_echo "$as_me:$LINENO: WARNING: Python.h: in the future, the compiler will take precedence" >&5
29097 $as_echo "$as_me: WARNING: Python.h: in the future, the compiler will take precedence" >&2;}
29098     ( cat <<\_ASBOX
29099 ## ---------------------------------------- ##
29100 ## Report this to pgsql-bugs@postgresql.org ##
29101 ## ---------------------------------------- ##
29102 _ASBOX
29103      ) | sed "s/^/$as_me: WARNING:     /" >&2
29104     ;;
29105 esac
29106 { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
29107 $as_echo_n "checking for Python.h... " >&6; }
29108 if test "${ac_cv_header_Python_h+set}" = set; then
29109   $as_echo_n "(cached) " >&6
29110 else
29111   ac_cv_header_Python_h=$ac_header_preproc
29112 fi
29113 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
29114 $as_echo "$ac_cv_header_Python_h" >&6; }
29115
29116 fi
29117 if test "x$ac_cv_header_Python_h" = x""yes; then
29118   :
29119 else
29120   { { $as_echo "$as_me:$LINENO: error: header file <Python.h> is required for Python" >&5
29121 $as_echo "$as_me: error: header file <Python.h> is required for Python" >&2;}
29122    { (exit 1); exit 1; }; }
29123 fi
29124
29125
29126   CPPFLAGS=$ac_save_CPPFLAGS
29127 fi
29128
29129 #
29130 # Check for DocBook and tools
29131 #
29132 for ac_prog in onsgmls nsgmls
29133 do
29134   # Extract the first word of "$ac_prog", so it can be a program name with args.
29135 set dummy $ac_prog; ac_word=$2
29136 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29137 $as_echo_n "checking for $ac_word... " >&6; }
29138 if test "${ac_cv_prog_NSGMLS+set}" = set; then
29139   $as_echo_n "(cached) " >&6
29140 else
29141   if test -n "$NSGMLS"; then
29142   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
29143 else
29144 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29145 for as_dir in $PATH
29146 do
29147   IFS=$as_save_IFS
29148   test -z "$as_dir" && as_dir=.
29149   for ac_exec_ext in '' $ac_executable_extensions; do
29150   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29151     ac_cv_prog_NSGMLS="$ac_prog"
29152     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29153     break 2
29154   fi
29155 done
29156 done
29157 IFS=$as_save_IFS
29158
29159 fi
29160 fi
29161 NSGMLS=$ac_cv_prog_NSGMLS
29162 if test -n "$NSGMLS"; then
29163   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
29164 $as_echo "$NSGMLS" >&6; }
29165 else
29166   { $as_echo "$as_me:$LINENO: result: no" >&5
29167 $as_echo "no" >&6; }
29168 fi
29169
29170
29171   test -n "$NSGMLS" && break
29172 done
29173
29174 for ac_prog in openjade jade
29175 do
29176   # Extract the first word of "$ac_prog", so it can be a program name with args.
29177 set dummy $ac_prog; ac_word=$2
29178 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29179 $as_echo_n "checking for $ac_word... " >&6; }
29180 if test "${ac_cv_prog_JADE+set}" = set; then
29181   $as_echo_n "(cached) " >&6
29182 else
29183   if test -n "$JADE"; then
29184   ac_cv_prog_JADE="$JADE" # Let the user override the test.
29185 else
29186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29187 for as_dir in $PATH
29188 do
29189   IFS=$as_save_IFS
29190   test -z "$as_dir" && as_dir=.
29191   for ac_exec_ext in '' $ac_executable_extensions; do
29192   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29193     ac_cv_prog_JADE="$ac_prog"
29194     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29195     break 2
29196   fi
29197 done
29198 done
29199 IFS=$as_save_IFS
29200
29201 fi
29202 fi
29203 JADE=$ac_cv_prog_JADE
29204 if test -n "$JADE"; then
29205   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
29206 $as_echo "$JADE" >&6; }
29207 else
29208   { $as_echo "$as_me:$LINENO: result: no" >&5
29209 $as_echo "no" >&6; }
29210 fi
29211
29212
29213   test -n "$JADE" && break
29214 done
29215
29216
29217 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
29218 $as_echo_n "checking for DocBook V4.2... " >&6; }
29219 if test "${pgac_cv_check_docbook+set}" = set; then
29220   $as_echo_n "(cached) " >&6
29221 else
29222   cat >conftest.sgml <<EOF
29223 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
29224 <book>
29225  <title>test</title>
29226  <chapter>
29227   <title>random</title>
29228    <sect1>
29229     <title>testsect</title>
29230     <para>text</para>
29231   </sect1>
29232  </chapter>
29233 </book>
29234 EOF
29235
29236 pgac_cv_check_docbook=no
29237
29238 if test -n "$NSGMLS"; then
29239   $NSGMLS -s conftest.sgml 1>&5 2>&1
29240   if test $? -eq 0; then
29241     pgac_cv_check_docbook=yes
29242   fi
29243 fi
29244 rm -f conftest.sgml
29245 fi
29246 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
29247 $as_echo "$pgac_cv_check_docbook" >&6; }
29248
29249 have_docbook=$pgac_cv_check_docbook
29250
29251
29252 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
29253 $as_echo_n "checking for DocBook stylesheets... " >&6; }
29254 if test "${pgac_cv_path_stylesheets+set}" = set; then
29255   $as_echo_n "(cached) " >&6
29256 else
29257   if test -n "$DOCBOOKSTYLE"; then
29258   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
29259 else
29260   for pgac_prefix in /usr /usr/local /opt /sw; do
29261     for pgac_infix in share lib; do
29262       for pgac_postfix in \
29263         sgml/stylesheets/nwalsh-modular \
29264         sgml/stylesheets/docbook \
29265         sgml/stylesheets/dsssl/docbook \
29266         sgml/docbook-dsssl \
29267         sgml/docbook/dsssl/modular \
29268         sgml/docbook/stylesheet/dsssl/modular \
29269         sgml/docbook/dsssl-stylesheets \
29270         sgml/dsssl/docbook-dsssl-nwalsh
29271       do
29272         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
29273         if test -r "$pgac_candidate/html/docbook.dsl" \
29274            && test -r "$pgac_candidate/print/docbook.dsl"
29275         then
29276           pgac_cv_path_stylesheets=$pgac_candidate
29277           break 3
29278         fi
29279       done
29280     done
29281   done
29282 fi
29283 fi
29284
29285 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
29286
29287 if test -n "$DOCBOOKSTYLE"; then
29288   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
29289 $as_echo "$DOCBOOKSTYLE" >&6; }
29290 else
29291   { $as_echo "$as_me:$LINENO: result: no" >&5
29292 $as_echo "no" >&6; }
29293 fi
29294 if test -n "$DOCBOOKSTYLE" -a -r "$DOCBOOKSTYLE/bin/collateindex.pl"; then
29295   COLLATEINDEX="$DOCBOOKSTYLE/bin/collateindex.pl"
29296
29297 else
29298   # Extract the first word of "collateindex.pl", so it can be a program name with args.
29299 set dummy collateindex.pl; ac_word=$2
29300 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29301 $as_echo_n "checking for $ac_word... " >&6; }
29302 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
29303   $as_echo_n "(cached) " >&6
29304 else
29305   case $COLLATEINDEX in
29306   [\\/]* | ?:[\\/]*)
29307   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
29308   ;;
29309   *)
29310   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29311 for as_dir in $PATH
29312 do
29313   IFS=$as_save_IFS
29314   test -z "$as_dir" && as_dir=.
29315   for ac_exec_ext in '' $ac_executable_extensions; do
29316   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29317     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
29318     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29319     break 2
29320   fi
29321 done
29322 done
29323 IFS=$as_save_IFS
29324
29325   ;;
29326 esac
29327 fi
29328 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
29329 if test -n "$COLLATEINDEX"; then
29330   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
29331 $as_echo "$COLLATEINDEX" >&6; }
29332 else
29333   { $as_echo "$as_me:$LINENO: result: no" >&5
29334 $as_echo "no" >&6; }
29335 fi
29336
29337
29338 fi
29339 for ac_prog in xsltproc
29340 do
29341   # Extract the first word of "$ac_prog", so it can be a program name with args.
29342 set dummy $ac_prog; ac_word=$2
29343 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29344 $as_echo_n "checking for $ac_word... " >&6; }
29345 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
29346   $as_echo_n "(cached) " >&6
29347 else
29348   if test -n "$XSLTPROC"; then
29349   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
29350 else
29351 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29352 for as_dir in $PATH
29353 do
29354   IFS=$as_save_IFS
29355   test -z "$as_dir" && as_dir=.
29356   for ac_exec_ext in '' $ac_executable_extensions; do
29357   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29358     ac_cv_prog_XSLTPROC="$ac_prog"
29359     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29360     break 2
29361   fi
29362 done
29363 done
29364 IFS=$as_save_IFS
29365
29366 fi
29367 fi
29368 XSLTPROC=$ac_cv_prog_XSLTPROC
29369 if test -n "$XSLTPROC"; then
29370   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
29371 $as_echo "$XSLTPROC" >&6; }
29372 else
29373   { $as_echo "$as_me:$LINENO: result: no" >&5
29374 $as_echo "no" >&6; }
29375 fi
29376
29377
29378   test -n "$XSLTPROC" && break
29379 done
29380
29381 for ac_prog in osx sgml2xml sx
29382 do
29383   # Extract the first word of "$ac_prog", so it can be a program name with args.
29384 set dummy $ac_prog; ac_word=$2
29385 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29386 $as_echo_n "checking for $ac_word... " >&6; }
29387 if test "${ac_cv_prog_OSX+set}" = set; then
29388   $as_echo_n "(cached) " >&6
29389 else
29390   if test -n "$OSX"; then
29391   ac_cv_prog_OSX="$OSX" # Let the user override the test.
29392 else
29393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29394 for as_dir in $PATH
29395 do
29396   IFS=$as_save_IFS
29397   test -z "$as_dir" && as_dir=.
29398   for ac_exec_ext in '' $ac_executable_extensions; do
29399   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29400     ac_cv_prog_OSX="$ac_prog"
29401     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29402     break 2
29403   fi
29404 done
29405 done
29406 IFS=$as_save_IFS
29407
29408 fi
29409 fi
29410 OSX=$ac_cv_prog_OSX
29411 if test -n "$OSX"; then
29412   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
29413 $as_echo "$OSX" >&6; }
29414 else
29415   { $as_echo "$as_me:$LINENO: result: no" >&5
29416 $as_echo "no" >&6; }
29417 fi
29418
29419
29420   test -n "$OSX" && break
29421 done
29422
29423
29424 # Thread testing
29425
29426 # We have to run the thread test near the end so we have all our symbols
29427 # defined.  Cross compiling throws a warning.
29428 #
29429 if test "$enable_thread_safety" = yes; then
29430 if test "$PORTNAME" != "win32"
29431 then
29432 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
29433 $as_echo_n "checking thread safety of required library functions... " >&6; }
29434
29435 _CFLAGS="$CFLAGS"
29436 _LIBS="$LIBS"
29437 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
29438 LIBS="$LIBS $PTHREAD_LIBS"
29439 if test "$cross_compiling" = yes; then
29440   { $as_echo "$as_me:$LINENO: result: maybe" >&5
29441 $as_echo "maybe" >&6; }
29442   { $as_echo "$as_me:$LINENO: WARNING:
29443 *** Skipping thread test program because of cross-compile build.
29444 *** Run the program in src/test/thread on the target machine.
29445 " >&5
29446 $as_echo "$as_me: WARNING:
29447 *** Skipping thread test program because of cross-compile build.
29448 *** Run the program in src/test/thread on the target machine.
29449 " >&2;}
29450 else
29451   cat >conftest.$ac_ext <<_ACEOF
29452 /* confdefs.h.  */
29453 _ACEOF
29454 cat confdefs.h >>conftest.$ac_ext
29455 cat >>conftest.$ac_ext <<_ACEOF
29456 /* end confdefs.h.  */
29457 #include "$srcdir/src/test/thread/thread_test.c"
29458 _ACEOF
29459 rm -f conftest$ac_exeext
29460 if { (ac_try="$ac_link"
29461 case "(($ac_try" in
29462   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29463   *) ac_try_echo=$ac_try;;
29464 esac
29465 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29466 $as_echo "$ac_try_echo") >&5
29467   (eval "$ac_link") 2>&5
29468   ac_status=$?
29469   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29470   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29471   { (case "(($ac_try" in
29472   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29473   *) ac_try_echo=$ac_try;;
29474 esac
29475 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29476 $as_echo "$ac_try_echo") >&5
29477   (eval "$ac_try") 2>&5
29478   ac_status=$?
29479   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29480   (exit $ac_status); }; }; then
29481   { $as_echo "$as_me:$LINENO: result: yes" >&5
29482 $as_echo "yes" >&6; }
29483 else
29484   $as_echo "$as_me: program exited with status $ac_status" >&5
29485 $as_echo "$as_me: failed program was:" >&5
29486 sed 's/^/| /' conftest.$ac_ext >&5
29487
29488 ( exit $ac_status )
29489 { $as_echo "$as_me:$LINENO: result: no" >&5
29490 $as_echo "no" >&6; }
29491   { { $as_echo "$as_me:$LINENO: error: thread test program failed
29492 This platform is not thread-safe.  Check the file 'config.log' or compile
29493 and run src/test/thread/thread_test for the exact reason.
29494 Use --disable-thread-safety to disable thread safety." >&5
29495 $as_echo "$as_me: error: thread test program failed
29496 This platform is not thread-safe.  Check the file 'config.log' or compile
29497 and run src/test/thread/thread_test for the exact reason.
29498 Use --disable-thread-safety to disable thread safety." >&2;}
29499    { (exit 1); exit 1; }; }
29500 fi
29501 rm -rf conftest.dSYM
29502 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29503 fi
29504
29505
29506 CFLAGS="$_CFLAGS"
29507 LIBS="$_LIBS"
29508 else
29509 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
29510 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
29511 fi
29512 fi
29513
29514 # If compiler will take -Wl,--as-needed (or various platform-specific
29515 # spellings thereof) then add that to LDFLAGS.  This is much easier than
29516 # trying to filter LIBS to the minimum for each executable.
29517 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
29518 # libreadline; therefore we postpone testing it until we know what library
29519 # dependencies readline has.  The test code will try to link with $LIBS.
29520 if test "$with_readline" = yes; then
29521   link_test_func=readline
29522 else
29523   link_test_func=exit
29524 fi
29525
29526 if test "$PORTNAME" = "darwin"; then
29527   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
29528 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
29529 if test "${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+set}" = set; then
29530   $as_echo_n "(cached) " >&6
29531 else
29532   pgac_save_LDFLAGS=$LDFLAGS
29533 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
29534 if test "$cross_compiling" = yes; then
29535   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
29536 else
29537   cat >conftest.$ac_ext <<_ACEOF
29538 /* confdefs.h.  */
29539 _ACEOF
29540 cat confdefs.h >>conftest.$ac_ext
29541 cat >>conftest.$ac_ext <<_ACEOF
29542 /* end confdefs.h.  */
29543 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29544 int
29545 main ()
29546 {
29547
29548   ;
29549   return 0;
29550 }
29551 _ACEOF
29552 rm -f conftest$ac_exeext
29553 if { (ac_try="$ac_link"
29554 case "(($ac_try" in
29555   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29556   *) ac_try_echo=$ac_try;;
29557 esac
29558 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29559 $as_echo "$ac_try_echo") >&5
29560   (eval "$ac_link") 2>&5
29561   ac_status=$?
29562   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29563   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29564   { (case "(($ac_try" in
29565   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29566   *) ac_try_echo=$ac_try;;
29567 esac
29568 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29569 $as_echo "$ac_try_echo") >&5
29570   (eval "$ac_try") 2>&5
29571   ac_status=$?
29572   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29573   (exit $ac_status); }; }; then
29574   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
29575 else
29576   $as_echo "$as_me: program exited with status $ac_status" >&5
29577 $as_echo "$as_me: failed program was:" >&5
29578 sed 's/^/| /' conftest.$ac_ext >&5
29579
29580 ( exit $ac_status )
29581 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
29582 fi
29583 rm -rf conftest.dSYM
29584 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29585 fi
29586
29587
29588 LDFLAGS="$pgac_save_LDFLAGS"
29589 fi
29590 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
29591 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
29592 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
29593   LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
29594 fi
29595
29596 elif test "$PORTNAME" = "openbsd"; then
29597   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-Bdynamic" >&5
29598 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
29599 if test "${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+set}" = set; then
29600   $as_echo_n "(cached) " >&6
29601 else
29602   pgac_save_LDFLAGS=$LDFLAGS
29603 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
29604 if test "$cross_compiling" = yes; then
29605   pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
29606 else
29607   cat >conftest.$ac_ext <<_ACEOF
29608 /* confdefs.h.  */
29609 _ACEOF
29610 cat confdefs.h >>conftest.$ac_ext
29611 cat >>conftest.$ac_ext <<_ACEOF
29612 /* end confdefs.h.  */
29613 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29614 int
29615 main ()
29616 {
29617
29618   ;
29619   return 0;
29620 }
29621 _ACEOF
29622 rm -f conftest$ac_exeext
29623 if { (ac_try="$ac_link"
29624 case "(($ac_try" in
29625   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29626   *) ac_try_echo=$ac_try;;
29627 esac
29628 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29629 $as_echo "$ac_try_echo") >&5
29630   (eval "$ac_link") 2>&5
29631   ac_status=$?
29632   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29633   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29634   { (case "(($ac_try" in
29635   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29636   *) ac_try_echo=$ac_try;;
29637 esac
29638 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29639 $as_echo "$ac_try_echo") >&5
29640   (eval "$ac_try") 2>&5
29641   ac_status=$?
29642   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29643   (exit $ac_status); }; }; then
29644   pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
29645 else
29646   $as_echo "$as_me: program exited with status $ac_status" >&5
29647 $as_echo "$as_me: failed program was:" >&5
29648 sed 's/^/| /' conftest.$ac_ext >&5
29649
29650 ( exit $ac_status )
29651 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
29652 fi
29653 rm -rf conftest.dSYM
29654 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29655 fi
29656
29657
29658 LDFLAGS="$pgac_save_LDFLAGS"
29659 fi
29660 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
29661 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
29662 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
29663   LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
29664 fi
29665
29666 else
29667   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,--as-needed" >&5
29668 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
29669 if test "${pgac_cv_prog_cc_ldflags__Wl___as_needed+set}" = set; then
29670   $as_echo_n "(cached) " >&6
29671 else
29672   pgac_save_LDFLAGS=$LDFLAGS
29673 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
29674 if test "$cross_compiling" = yes; then
29675   pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
29676 else
29677   cat >conftest.$ac_ext <<_ACEOF
29678 /* confdefs.h.  */
29679 _ACEOF
29680 cat confdefs.h >>conftest.$ac_ext
29681 cat >>conftest.$ac_ext <<_ACEOF
29682 /* end confdefs.h.  */
29683 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29684 int
29685 main ()
29686 {
29687
29688   ;
29689   return 0;
29690 }
29691 _ACEOF
29692 rm -f conftest$ac_exeext
29693 if { (ac_try="$ac_link"
29694 case "(($ac_try" in
29695   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29696   *) ac_try_echo=$ac_try;;
29697 esac
29698 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29699 $as_echo "$ac_try_echo") >&5
29700   (eval "$ac_link") 2>&5
29701   ac_status=$?
29702   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29703   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29704   { (case "(($ac_try" in
29705   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29706   *) ac_try_echo=$ac_try;;
29707 esac
29708 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29709 $as_echo "$ac_try_echo") >&5
29710   (eval "$ac_try") 2>&5
29711   ac_status=$?
29712   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29713   (exit $ac_status); }; }; then
29714   pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
29715 else
29716   $as_echo "$as_me: program exited with status $ac_status" >&5
29717 $as_echo "$as_me: failed program was:" >&5
29718 sed 's/^/| /' conftest.$ac_ext >&5
29719
29720 ( exit $ac_status )
29721 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
29722 fi
29723 rm -rf conftest.dSYM
29724 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29725 fi
29726
29727
29728 LDFLAGS="$pgac_save_LDFLAGS"
29729 fi
29730 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
29731 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
29732 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
29733   LDFLAGS="$LDFLAGS -Wl,--as-needed"
29734 fi
29735
29736 fi
29737
29738 # Create compiler version string
29739 if test x"$GCC" = x"yes" ; then
29740   cc_string=`${CC} --version | sed q`
29741   case $cc_string in [A-Za-z]*) ;; *) cc_string="GCC $cc_string";; esac
29742 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
29743   cc_string=`${CC} -V 2>&1 | sed q`
29744 else
29745   cc_string=$CC
29746 fi
29747
29748
29749 cat >>confdefs.h <<_ACEOF
29750 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
29751 _ACEOF
29752
29753
29754 # Supply a numeric version string for use by 3rd party add-ons
29755 # awk -F is a regex on some platforms, and not on others, so make "." a tab
29756 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
29757 tr '.' '        ' |
29758 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
29759
29760 cat >>confdefs.h <<_ACEOF
29761 #define PG_VERSION_NUM $PG_VERSION_NUM
29762 _ACEOF
29763
29764
29765
29766 # Begin output steps
29767
29768 { $as_echo "$as_me:$LINENO: using compiler=$cc_string" >&5
29769 $as_echo "$as_me: using compiler=$cc_string" >&6;}
29770 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
29771 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
29772 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
29773 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
29774 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
29775 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
29776
29777 # prepare build tree if outside source tree
29778 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
29779 # Note 2: /bin/pwd might be better than shell's built-in at getting
29780 #         a symlink-free name.
29781 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
29782   vpath_build=no
29783 else
29784   vpath_build=yes
29785   if test "$no_create" != yes; then
29786     $as_echo_n "preparing build tree... " >&6
29787     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
29788     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
29789       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
29790 $as_echo "$as_me: error: failed" >&2;}
29791    { (exit 1); exit 1; }; }
29792     { $as_echo "$as_me:$LINENO: result: done" >&5
29793 $as_echo "done" >&6; }
29794   fi
29795 fi
29796
29797
29798
29799 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
29800
29801
29802 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}"
29803
29804
29805 if test "$PORTNAME" = "win32"; then
29806 ac_config_commands="$ac_config_commands check_win32_symlinks"
29807
29808 fi
29809
29810 ac_config_headers="$ac_config_headers src/include/pg_config.h"
29811
29812
29813 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
29814
29815
29816 cat >confcache <<\_ACEOF
29817 # This file is a shell script that caches the results of configure
29818 # tests run on this system so they can be shared between configure
29819 # scripts and configure runs, see configure's option --config-cache.
29820 # It is not useful on other systems.  If it contains results you don't
29821 # want to keep, you may remove or edit it.
29822 #
29823 # config.status only pays attention to the cache file if you give it
29824 # the --recheck option to rerun configure.
29825 #
29826 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29827 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29828 # following values.
29829
29830 _ACEOF
29831
29832 # The following way of writing the cache mishandles newlines in values,
29833 # but we know of no workaround that is simple, portable, and efficient.
29834 # So, we kill variables containing newlines.
29835 # Ultrix sh set writes to stderr and can't be redirected directly,
29836 # and sets the high bit in the cache file unless we assign to the vars.
29837 (
29838   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29839     eval ac_val=\$$ac_var
29840     case $ac_val in #(
29841     *${as_nl}*)
29842       case $ac_var in #(
29843       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
29844 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29845       esac
29846       case $ac_var in #(
29847       _ | IFS | as_nl) ;; #(
29848       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29849       *) $as_unset $ac_var ;;
29850       esac ;;
29851     esac
29852   done
29853
29854   (set) 2>&1 |
29855     case $as_nl`(ac_space=' '; set) 2>&1` in #(
29856     *${as_nl}ac_space=\ *)
29857       # `set' does not quote correctly, so add quotes (double-quote
29858       # substitution turns \\\\ into \\, and sed turns \\ into \).
29859       sed -n \
29860         "s/'/'\\\\''/g;
29861           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29862       ;; #(
29863     *)
29864       # `set' quotes correctly as required by POSIX, so do not add quotes.
29865       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29866       ;;
29867     esac |
29868     sort
29869 ) |
29870   sed '
29871      /^ac_cv_env_/b end
29872      t clear
29873      :clear
29874      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29875      t end
29876      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29877      :end' >>confcache
29878 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29879   if test -w "$cache_file"; then
29880     test "x$cache_file" != "x/dev/null" &&
29881       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
29882 $as_echo "$as_me: updating cache $cache_file" >&6;}
29883     cat confcache >$cache_file
29884   else
29885     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
29886 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29887   fi
29888 fi
29889 rm -f confcache
29890
29891 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29892 # Let make expand exec_prefix.
29893 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29894
29895 DEFS=-DHAVE_CONFIG_H
29896
29897 ac_libobjs=
29898 ac_ltlibobjs=
29899 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29900   # 1. Remove the extension, and $U if already installed.
29901   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29902   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29903   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
29904   #    will be set to the directory where LIBOBJS objects are built.
29905   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29906   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
29907 done
29908 LIBOBJS=$ac_libobjs
29909
29910 LTLIBOBJS=$ac_ltlibobjs
29911
29912
29913
29914
29915 : ${CONFIG_STATUS=./config.status}
29916 ac_write_fail=0
29917 ac_clean_files_save=$ac_clean_files
29918 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29919 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
29920 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29921 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29922 #! $SHELL
29923 # Generated by $as_me.
29924 # Run this file to recreate the current configuration.
29925 # Compiler output produced by configure, useful for debugging
29926 # configure, is in config.log if it exists.
29927
29928 debug=false
29929 ac_cs_recheck=false
29930 ac_cs_silent=false
29931 SHELL=\${CONFIG_SHELL-$SHELL}
29932 _ACEOF
29933
29934 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29935 ## --------------------- ##
29936 ## M4sh Initialization.  ##
29937 ## --------------------- ##
29938
29939 # Be more Bourne compatible
29940 DUALCASE=1; export DUALCASE # for MKS sh
29941 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
29942   emulate sh
29943   NULLCMD=:
29944   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29945   # is contrary to our usage.  Disable this feature.
29946   alias -g '${1+"$@"}'='"$@"'
29947   setopt NO_GLOB_SUBST
29948 else
29949   case `(set -o) 2>/dev/null` in
29950   *posix*) set -o posix ;;
29951 esac
29952
29953 fi
29954
29955
29956
29957
29958 # PATH needs CR
29959 # Avoid depending upon Character Ranges.
29960 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29961 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29962 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29963 as_cr_digits='0123456789'
29964 as_cr_alnum=$as_cr_Letters$as_cr_digits
29965
29966 as_nl='
29967 '
29968 export as_nl
29969 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29970 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29971 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29972 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29973 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29974   as_echo='printf %s\n'
29975   as_echo_n='printf %s'
29976 else
29977   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29978     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29979     as_echo_n='/usr/ucb/echo -n'
29980   else
29981     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29982     as_echo_n_body='eval
29983       arg=$1;
29984       case $arg in
29985       *"$as_nl"*)
29986         expr "X$arg" : "X\\(.*\\)$as_nl";
29987         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29988       esac;
29989       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29990     '
29991     export as_echo_n_body
29992     as_echo_n='sh -c $as_echo_n_body as_echo'
29993   fi
29994   export as_echo_body
29995   as_echo='sh -c $as_echo_body as_echo'
29996 fi
29997
29998 # The user is always right.
29999 if test "${PATH_SEPARATOR+set}" != set; then
30000   PATH_SEPARATOR=:
30001   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
30002     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
30003       PATH_SEPARATOR=';'
30004   }
30005 fi
30006
30007 # Support unset when possible.
30008 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
30009   as_unset=unset
30010 else
30011   as_unset=false
30012 fi
30013
30014
30015 # IFS
30016 # We need space, tab and new line, in precisely that order.  Quoting is
30017 # there to prevent editors from complaining about space-tab.
30018 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
30019 # splitting by setting IFS to empty value.)
30020 IFS=" ""        $as_nl"
30021
30022 # Find who we are.  Look in the path if we contain no directory separator.
30023 case $0 in
30024   *[\\/]* ) as_myself=$0 ;;
30025   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30026 for as_dir in $PATH
30027 do
30028   IFS=$as_save_IFS
30029   test -z "$as_dir" && as_dir=.
30030   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
30031 done
30032 IFS=$as_save_IFS
30033
30034      ;;
30035 esac
30036 # We did not find ourselves, most probably we were run as `sh COMMAND'
30037 # in which case we are not to be found in the path.
30038 if test "x$as_myself" = x; then
30039   as_myself=$0
30040 fi
30041 if test ! -f "$as_myself"; then
30042   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
30043   { (exit 1); exit 1; }
30044 fi
30045
30046 # Work around bugs in pre-3.0 UWIN ksh.
30047 for as_var in ENV MAIL MAILPATH
30048 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
30049 done
30050 PS1='$ '
30051 PS2='> '
30052 PS4='+ '
30053
30054 # NLS nuisances.
30055 LC_ALL=C
30056 export LC_ALL
30057 LANGUAGE=C
30058 export LANGUAGE
30059
30060 # Required to use basename.
30061 if expr a : '\(a\)' >/dev/null 2>&1 &&
30062    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30063   as_expr=expr
30064 else
30065   as_expr=false
30066 fi
30067
30068 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
30069   as_basename=basename
30070 else
30071   as_basename=false
30072 fi
30073
30074
30075 # Name of the executable.
30076 as_me=`$as_basename -- "$0" ||
30077 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
30078          X"$0" : 'X\(//\)$' \| \
30079          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
30080 $as_echo X/"$0" |
30081     sed '/^.*\/\([^/][^/]*\)\/*$/{
30082             s//\1/
30083             q
30084           }
30085           /^X\/\(\/\/\)$/{
30086             s//\1/
30087             q
30088           }
30089           /^X\/\(\/\).*/{
30090             s//\1/
30091             q
30092           }
30093           s/.*/./; q'`
30094
30095 # CDPATH.
30096 $as_unset CDPATH
30097
30098
30099
30100   as_lineno_1=$LINENO
30101   as_lineno_2=$LINENO
30102   test "x$as_lineno_1" != "x$as_lineno_2" &&
30103   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
30104
30105   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
30106   # uniformly replaced by the line number.  The first 'sed' inserts a
30107   # line-number line after each line using $LINENO; the second 'sed'
30108   # does the real work.  The second script uses 'N' to pair each
30109   # line-number line with the line containing $LINENO, and appends
30110   # trailing '-' during substitution so that $LINENO is not a special
30111   # case at line end.
30112   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
30113   # scripts with optimization help from Paolo Bonzini.  Blame Lee
30114   # E. McMahon (1931-1989) for sed's syntax.  :-)
30115   sed -n '
30116     p
30117     /[$]LINENO/=
30118   ' <$as_myself |
30119     sed '
30120       s/[$]LINENO.*/&-/
30121       t lineno
30122       b
30123       :lineno
30124       N
30125       :loop
30126       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
30127       t loop
30128       s/-\n.*//
30129     ' >$as_me.lineno &&
30130   chmod +x "$as_me.lineno" ||
30131     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
30132    { (exit 1); exit 1; }; }
30133
30134   # Don't try to exec as it changes $[0], causing all sort of problems
30135   # (the dirname of $[0] is not the place where we might find the
30136   # original and so on.  Autoconf is especially sensitive to this).
30137   . "./$as_me.lineno"
30138   # Exit status is that of the last command.
30139   exit
30140 }
30141
30142
30143 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
30144   as_dirname=dirname
30145 else
30146   as_dirname=false
30147 fi
30148
30149 ECHO_C= ECHO_N= ECHO_T=
30150 case `echo -n x` in
30151 -n*)
30152   case `echo 'x\c'` in
30153   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
30154   *)   ECHO_C='\c';;
30155   esac;;
30156 *)
30157   ECHO_N='-n';;
30158 esac
30159 if expr a : '\(a\)' >/dev/null 2>&1 &&
30160    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30161   as_expr=expr
30162 else
30163   as_expr=false
30164 fi
30165
30166 rm -f conf$$ conf$$.exe conf$$.file
30167 if test -d conf$$.dir; then
30168   rm -f conf$$.dir/conf$$.file
30169 else
30170   rm -f conf$$.dir
30171   mkdir conf$$.dir 2>/dev/null
30172 fi
30173 if (echo >conf$$.file) 2>/dev/null; then
30174   if ln -s conf$$.file conf$$ 2>/dev/null; then
30175     as_ln_s='ln -s'
30176     # ... but there are two gotchas:
30177     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
30178     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
30179     # In both cases, we have to default to `cp -p'.
30180     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
30181       as_ln_s='cp -p'
30182   elif ln conf$$.file conf$$ 2>/dev/null; then
30183     as_ln_s=ln
30184   else
30185     as_ln_s='cp -p'
30186   fi
30187 else
30188   as_ln_s='cp -p'
30189 fi
30190 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
30191 rmdir conf$$.dir 2>/dev/null
30192
30193 if mkdir -p . 2>/dev/null; then
30194   as_mkdir_p=:
30195 else
30196   test -d ./-p && rmdir ./-p
30197   as_mkdir_p=false
30198 fi
30199
30200 if test -x / >/dev/null 2>&1; then
30201   as_test_x='test -x'
30202 else
30203   if ls -dL / >/dev/null 2>&1; then
30204     as_ls_L_option=L
30205   else
30206     as_ls_L_option=
30207   fi
30208   as_test_x='
30209     eval sh -c '\''
30210       if test -d "$1"; then
30211         test -d "$1/.";
30212       else
30213         case $1 in
30214         -*)set "./$1";;
30215         esac;
30216         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
30217         ???[sx]*):;;*)false;;esac;fi
30218     '\'' sh
30219   '
30220 fi
30221 as_executable_p=$as_test_x
30222
30223 # Sed expression to map a string onto a valid CPP name.
30224 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
30225
30226 # Sed expression to map a string onto a valid variable name.
30227 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
30228
30229
30230 exec 6>&1
30231
30232 # Save the log message, to keep $[0] and so on meaningful, and to
30233 # report actual input values of CONFIG_FILES etc. instead of their
30234 # values after options handling.
30235 ac_log="
30236 This file was extended by PostgreSQL $as_me 9.3devel, which was
30237 generated by GNU Autoconf 2.63.  Invocation command line was
30238
30239   CONFIG_FILES    = $CONFIG_FILES
30240   CONFIG_HEADERS  = $CONFIG_HEADERS
30241   CONFIG_LINKS    = $CONFIG_LINKS
30242   CONFIG_COMMANDS = $CONFIG_COMMANDS
30243   $ $0 $@
30244
30245 on `(hostname || uname -n) 2>/dev/null | sed 1q`
30246 "
30247
30248 _ACEOF
30249
30250 case $ac_config_files in *"
30251 "*) set x $ac_config_files; shift; ac_config_files=$*;;
30252 esac
30253
30254 case $ac_config_headers in *"
30255 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30256 esac
30257
30258
30259 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30260 # Files that config.status was made for.
30261 config_files="$ac_config_files"
30262 config_headers="$ac_config_headers"
30263 config_links="$ac_config_links"
30264 config_commands="$ac_config_commands"
30265
30266 _ACEOF
30267
30268 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30269 ac_cs_usage="\
30270 \`$as_me' instantiates files from templates according to the
30271 current configuration.
30272
30273 Usage: $0 [OPTION]... [FILE]...
30274
30275   -h, --help       print this help, then exit
30276   -V, --version    print version number and configuration settings, then exit
30277   -q, --quiet, --silent
30278                    do not print progress messages
30279   -d, --debug      don't remove temporary files
30280       --recheck    update $as_me by reconfiguring in the same conditions
30281       --file=FILE[:TEMPLATE]
30282                    instantiate the configuration file FILE
30283       --header=FILE[:TEMPLATE]
30284                    instantiate the configuration header FILE
30285
30286 Configuration files:
30287 $config_files
30288
30289 Configuration headers:
30290 $config_headers
30291
30292 Configuration links:
30293 $config_links
30294
30295 Configuration commands:
30296 $config_commands
30297
30298 Report bugs to <bug-autoconf@gnu.org>."
30299
30300 _ACEOF
30301 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30302 ac_cs_version="\\
30303 PostgreSQL config.status 9.3devel
30304 configured by $0, generated by GNU Autoconf 2.63,
30305   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
30306
30307 Copyright (C) 2008 Free Software Foundation, Inc.
30308 This config.status script is free software; the Free Software Foundation
30309 gives unlimited permission to copy, distribute and modify it."
30310
30311 ac_pwd='$ac_pwd'
30312 srcdir='$srcdir'
30313 INSTALL='$INSTALL'
30314 MKDIR_P='$MKDIR_P'
30315 AWK='$AWK'
30316 test -n "\$AWK" || AWK=awk
30317 _ACEOF
30318
30319 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30320 # The default lists apply if the user does not specify any file.
30321 ac_need_defaults=:
30322 while test $# != 0
30323 do
30324   case $1 in
30325   --*=*)
30326     ac_option=`expr "X$1" : 'X\([^=]*\)='`
30327     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30328     ac_shift=:
30329     ;;
30330   *)
30331     ac_option=$1
30332     ac_optarg=$2
30333     ac_shift=shift
30334     ;;
30335   esac
30336
30337   case $ac_option in
30338   # Handling of the options.
30339   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30340     ac_cs_recheck=: ;;
30341   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30342     $as_echo "$ac_cs_version"; exit ;;
30343   --debug | --debu | --deb | --de | --d | -d )
30344     debug=: ;;
30345   --file | --fil | --fi | --f )
30346     $ac_shift
30347     case $ac_optarg in
30348     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30349     esac
30350     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
30351     ac_need_defaults=false;;
30352   --header | --heade | --head | --hea )
30353     $ac_shift
30354     case $ac_optarg in
30355     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30356     esac
30357     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
30358     ac_need_defaults=false;;
30359   --he | --h)
30360     # Conflict between --help and --header
30361     { $as_echo "$as_me: error: ambiguous option: $1
30362 Try \`$0 --help' for more information." >&2
30363    { (exit 1); exit 1; }; };;
30364   --help | --hel | -h )
30365     $as_echo "$ac_cs_usage"; exit ;;
30366   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30367   | -silent | --silent | --silen | --sile | --sil | --si | --s)
30368     ac_cs_silent=: ;;
30369
30370   # This is an error.
30371   -*) { $as_echo "$as_me: error: unrecognized option: $1
30372 Try \`$0 --help' for more information." >&2
30373    { (exit 1); exit 1; }; } ;;
30374
30375   *) ac_config_targets="$ac_config_targets $1"
30376      ac_need_defaults=false ;;
30377
30378   esac
30379   shift
30380 done
30381
30382 ac_configure_extra_args=
30383
30384 if $ac_cs_silent; then
30385   exec 6>/dev/null
30386   ac_configure_extra_args="$ac_configure_extra_args --silent"
30387 fi
30388
30389 _ACEOF
30390 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30391 if \$ac_cs_recheck; then
30392   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30393   shift
30394   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30395   CONFIG_SHELL='$SHELL'
30396   export CONFIG_SHELL
30397   exec "\$@"
30398 fi
30399
30400 _ACEOF
30401 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30402 exec 5>>config.log
30403 {
30404   echo
30405   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30406 ## Running $as_me. ##
30407 _ASBOX
30408   $as_echo "$ac_log"
30409 } >&5
30410
30411 _ACEOF
30412 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30413 _ACEOF
30414
30415 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30416
30417 # Handling of arguments.
30418 for ac_config_target in $ac_config_targets
30419 do
30420   case $ac_config_target in
30421     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
30422     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
30423     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
30424     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
30425     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
30426     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
30427     "src/backend/port/pg_latch.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION}" ;;
30428     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
30429     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
30430     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
30431     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
30432     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
30433     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
30434
30435   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
30436 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
30437    { (exit 1); exit 1; }; };;
30438   esac
30439 done
30440
30441
30442 # If the user did not use the arguments to specify the items to instantiate,
30443 # then the envvar interface is used.  Set only those that are not.
30444 # We use the long form for the default assignment because of an extremely
30445 # bizarre bug on SunOS 4.1.3.
30446 if $ac_need_defaults; then
30447   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30448   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30449   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
30450   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30451 fi
30452
30453 # Have a temporary directory for convenience.  Make it in the build tree
30454 # simply because there is no reason against having it here, and in addition,
30455 # creating and moving files from /tmp can sometimes cause problems.
30456 # Hook for its removal unless debugging.
30457 # Note that there is a small window in which the directory will not be cleaned:
30458 # after its creation but before its name has been assigned to `$tmp'.
30459 $debug ||
30460 {
30461   tmp=
30462   trap 'exit_status=$?
30463   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
30464 ' 0
30465   trap '{ (exit 1); exit 1; }' 1 2 13 15
30466 }
30467 # Create a (secure) tmp directory for tmp files.
30468
30469 {
30470   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
30471   test -n "$tmp" && test -d "$tmp"
30472 }  ||
30473 {
30474   tmp=./conf$$-$RANDOM
30475   (umask 077 && mkdir "$tmp")
30476 } ||
30477 {
30478    $as_echo "$as_me: cannot create a temporary directory in ." >&2
30479    { (exit 1); exit 1; }
30480 }
30481
30482 # Set up the scripts for CONFIG_FILES section.
30483 # No need to generate them if there are no CONFIG_FILES.
30484 # This happens for instance with `./config.status config.h'.
30485 if test -n "$CONFIG_FILES"; then
30486
30487
30488 ac_cr='\r'
30489 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30490 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30491   ac_cs_awk_cr='\\r'
30492 else
30493   ac_cs_awk_cr=$ac_cr
30494 fi
30495
30496 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30497 _ACEOF
30498
30499
30500 {
30501   echo "cat >conf$$subs.awk <<_ACEOF" &&
30502   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30503   echo "_ACEOF"
30504 } >conf$$subs.sh ||
30505   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30506 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30507    { (exit 1); exit 1; }; }
30508 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30509 ac_delim='%!_!# '
30510 for ac_last_try in false false false false false :; do
30511   . ./conf$$subs.sh ||
30512     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30513 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30514    { (exit 1); exit 1; }; }
30515
30516   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30517   if test $ac_delim_n = $ac_delim_num; then
30518     break
30519   elif $ac_last_try; then
30520     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30521 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30522    { (exit 1); exit 1; }; }
30523   else
30524     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30525   fi
30526 done
30527 rm -f conf$$subs.sh
30528
30529 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30530 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30531 _ACEOF
30532 sed -n '
30533 h
30534 s/^/S["/; s/!.*/"]=/
30535 p
30536 g
30537 s/^[^!]*!//
30538 :repl
30539 t repl
30540 s/'"$ac_delim"'$//
30541 t delim
30542 :nl
30543 h
30544 s/\(.\{148\}\).*/\1/
30545 t more1
30546 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30547 p
30548 n
30549 b repl
30550 :more1
30551 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30552 p
30553 g
30554 s/.\{148\}//
30555 t nl
30556 :delim
30557 h
30558 s/\(.\{148\}\).*/\1/
30559 t more2
30560 s/["\\]/\\&/g; s/^/"/; s/$/"/
30561 p
30562 b
30563 :more2
30564 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30565 p
30566 g
30567 s/.\{148\}//
30568 t delim
30569 ' <conf$$subs.awk | sed '
30570 /^[^""]/{
30571   N
30572   s/\n//
30573 }
30574 ' >>$CONFIG_STATUS || ac_write_fail=1
30575 rm -f conf$$subs.awk
30576 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30577 _ACAWK
30578 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30579   for (key in S) S_is_set[key] = 1
30580   FS = "\a"
30581
30582 }
30583 {
30584   line = $ 0
30585   nfields = split(line, field, "@")
30586   substed = 0
30587   len = length(field[1])
30588   for (i = 2; i < nfields; i++) {
30589     key = field[i]
30590     keylen = length(key)
30591     if (S_is_set[key]) {
30592       value = S[key]
30593       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30594       len += length(value) + length(field[++i])
30595       substed = 1
30596     } else
30597       len += 1 + keylen
30598   }
30599
30600   print line
30601 }
30602
30603 _ACAWK
30604 _ACEOF
30605 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30606 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30607   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30608 else
30609   cat
30610 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30611   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
30612 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
30613    { (exit 1); exit 1; }; }
30614 _ACEOF
30615
30616 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30617 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30618 # trailing colons and then remove the whole line if VPATH becomes empty
30619 # (actually we leave an empty line to preserve line numbers).
30620 if test "x$srcdir" = x.; then
30621   ac_vpsub='/^[  ]*VPATH[        ]*=/{
30622 s/:*\$(srcdir):*/:/
30623 s/:*\${srcdir}:*/:/
30624 s/:*@srcdir@:*/:/
30625 s/^\([^=]*=[     ]*\):*/\1/
30626 s/:*$//
30627 s/^[^=]*=[       ]*$//
30628 }'
30629 fi
30630
30631 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30632 fi # test -n "$CONFIG_FILES"
30633
30634 # Set up the scripts for CONFIG_HEADERS section.
30635 # No need to generate them if there are no CONFIG_HEADERS.
30636 # This happens for instance with `./config.status Makefile'.
30637 if test -n "$CONFIG_HEADERS"; then
30638 cat >"$tmp/defines.awk" <<\_ACAWK ||
30639 BEGIN {
30640 _ACEOF
30641
30642 # Transform confdefs.h into an awk script `defines.awk', embedded as
30643 # here-document in config.status, that substitutes the proper values into
30644 # config.h.in to produce config.h.
30645
30646 # Create a delimiter string that does not exist in confdefs.h, to ease
30647 # handling of long lines.
30648 ac_delim='%!_!# '
30649 for ac_last_try in false false :; do
30650   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30651   if test -z "$ac_t"; then
30652     break
30653   elif $ac_last_try; then
30654     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
30655 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
30656    { (exit 1); exit 1; }; }
30657   else
30658     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30659   fi
30660 done
30661
30662 # For the awk script, D is an array of macro values keyed by name,
30663 # likewise P contains macro parameters if any.  Preserve backslash
30664 # newline sequences.
30665
30666 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30667 sed -n '
30668 s/.\{148\}/&'"$ac_delim"'/g
30669 t rset
30670 :rset
30671 s/^[     ]*#[    ]*define[       ][      ]*/ /
30672 t def
30673 d
30674 :def
30675 s/\\$//
30676 t bsnl
30677 s/["\\]/\\&/g
30678 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30679 D["\1"]=" \3"/p
30680 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
30681 d
30682 :bsnl
30683 s/["\\]/\\&/g
30684 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30685 D["\1"]=" \3\\\\\\n"\\/p
30686 t cont
30687 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30688 t cont
30689 d
30690 :cont
30691 n
30692 s/.\{148\}/&'"$ac_delim"'/g
30693 t clear
30694 :clear
30695 s/\\$//
30696 t bsnlc
30697 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30698 d
30699 :bsnlc
30700 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30701 b cont
30702 ' <confdefs.h | sed '
30703 s/'"$ac_delim"'/"\\\
30704 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30705
30706 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30707   for (key in D) D_is_set[key] = 1
30708   FS = "\a"
30709 }
30710 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30711   line = \$ 0
30712   split(line, arg, " ")
30713   if (arg[1] == "#") {
30714     defundef = arg[2]
30715     mac1 = arg[3]
30716   } else {
30717     defundef = substr(arg[1], 2)
30718     mac1 = arg[2]
30719   }
30720   split(mac1, mac2, "(") #)
30721   macro = mac2[1]
30722   prefix = substr(line, 1, index(line, defundef) - 1)
30723   if (D_is_set[macro]) {
30724     # Preserve the white space surrounding the "#".
30725     print prefix "define", macro P[macro] D[macro]
30726     next
30727   } else {
30728     # Replace #undef with comments.  This is necessary, for example,
30729     # in the case of _POSIX_SOURCE, which is predefined and required
30730     # on some systems where configure will not decide to define it.
30731     if (defundef == "undef") {
30732       print "/*", prefix defundef, macro, "*/"
30733       next
30734     }
30735   }
30736 }
30737 { print }
30738 _ACAWK
30739 _ACEOF
30740 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30741   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
30742 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
30743    { (exit 1); exit 1; }; }
30744 fi # test -n "$CONFIG_HEADERS"
30745
30746
30747 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
30748 shift
30749 for ac_tag
30750 do
30751   case $ac_tag in
30752   :[FHLC]) ac_mode=$ac_tag; continue;;
30753   esac
30754   case $ac_mode$ac_tag in
30755   :[FHL]*:*);;
30756   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
30757 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
30758    { (exit 1); exit 1; }; };;
30759   :[FH]-) ac_tag=-:-;;
30760   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30761   esac
30762   ac_save_IFS=$IFS
30763   IFS=:
30764   set x $ac_tag
30765   IFS=$ac_save_IFS
30766   shift
30767   ac_file=$1
30768   shift
30769
30770   case $ac_mode in
30771   :L) ac_source=$1;;
30772   :[FH])
30773     ac_file_inputs=
30774     for ac_f
30775     do
30776       case $ac_f in
30777       -) ac_f="$tmp/stdin";;
30778       *) # Look for the file first in the build tree, then in the source tree
30779          # (if the path is not absolute).  The absolute path cannot be DOS-style,
30780          # because $ac_f cannot contain `:'.
30781          test -f "$ac_f" ||
30782            case $ac_f in
30783            [\\/$]*) false;;
30784            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30785            esac ||
30786            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
30787 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
30788    { (exit 1); exit 1; }; };;
30789       esac
30790       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30791       ac_file_inputs="$ac_file_inputs '$ac_f'"
30792     done
30793
30794     # Let's still pretend it is `configure' which instantiates (i.e., don't
30795     # use $as_me), people would be surprised to read:
30796     #    /* config.h.  Generated by config.status.  */
30797     configure_input='Generated from '`
30798           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30799         `' by configure.'
30800     if test x"$ac_file" != x-; then
30801       configure_input="$ac_file.  $configure_input"
30802       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
30803 $as_echo "$as_me: creating $ac_file" >&6;}
30804     fi
30805     # Neutralize special characters interpreted by sed in replacement strings.
30806     case $configure_input in #(
30807     *\&* | *\|* | *\\* )
30808        ac_sed_conf_input=`$as_echo "$configure_input" |
30809        sed 's/[\\\\&|]/\\\\&/g'`;; #(
30810     *) ac_sed_conf_input=$configure_input;;
30811     esac
30812
30813     case $ac_tag in
30814     *:-:* | *:-) cat >"$tmp/stdin" \
30815       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30816 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30817    { (exit 1); exit 1; }; } ;;
30818     esac
30819     ;;
30820   esac
30821
30822   ac_dir=`$as_dirname -- "$ac_file" ||
30823 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30824          X"$ac_file" : 'X\(//\)[^/]' \| \
30825          X"$ac_file" : 'X\(//\)$' \| \
30826          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30827 $as_echo X"$ac_file" |
30828     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30829             s//\1/
30830             q
30831           }
30832           /^X\(\/\/\)[^/].*/{
30833             s//\1/
30834             q
30835           }
30836           /^X\(\/\/\)$/{
30837             s//\1/
30838             q
30839           }
30840           /^X\(\/\).*/{
30841             s//\1/
30842             q
30843           }
30844           s/.*/./; q'`
30845   { as_dir="$ac_dir"
30846   case $as_dir in #(
30847   -*) as_dir=./$as_dir;;
30848   esac
30849   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
30850     as_dirs=
30851     while :; do
30852       case $as_dir in #(
30853       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30854       *) as_qdir=$as_dir;;
30855       esac
30856       as_dirs="'$as_qdir' $as_dirs"
30857       as_dir=`$as_dirname -- "$as_dir" ||
30858 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30859          X"$as_dir" : 'X\(//\)[^/]' \| \
30860          X"$as_dir" : 'X\(//\)$' \| \
30861          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30862 $as_echo X"$as_dir" |
30863     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30864             s//\1/
30865             q
30866           }
30867           /^X\(\/\/\)[^/].*/{
30868             s//\1/
30869             q
30870           }
30871           /^X\(\/\/\)$/{
30872             s//\1/
30873             q
30874           }
30875           /^X\(\/\).*/{
30876             s//\1/
30877             q
30878           }
30879           s/.*/./; q'`
30880       test -d "$as_dir" && break
30881     done
30882     test -z "$as_dirs" || eval "mkdir $as_dirs"
30883   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
30884 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
30885    { (exit 1); exit 1; }; }; }
30886   ac_builddir=.
30887
30888 case "$ac_dir" in
30889 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30890 *)
30891   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30892   # A ".." for each directory in $ac_dir_suffix.
30893   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30894   case $ac_top_builddir_sub in
30895   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30896   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30897   esac ;;
30898 esac
30899 ac_abs_top_builddir=$ac_pwd
30900 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30901 # for backward compatibility:
30902 ac_top_builddir=$ac_top_build_prefix
30903
30904 case $srcdir in
30905   .)  # We are building in place.
30906     ac_srcdir=.
30907     ac_top_srcdir=$ac_top_builddir_sub
30908     ac_abs_top_srcdir=$ac_pwd ;;
30909   [\\/]* | ?:[\\/]* )  # Absolute name.
30910     ac_srcdir=$srcdir$ac_dir_suffix;
30911     ac_top_srcdir=$srcdir
30912     ac_abs_top_srcdir=$srcdir ;;
30913   *) # Relative name.
30914     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30915     ac_top_srcdir=$ac_top_build_prefix$srcdir
30916     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30917 esac
30918 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30919
30920
30921   case $ac_mode in
30922   :F)
30923   #
30924   # CONFIG_FILE
30925   #
30926
30927   case $INSTALL in
30928   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30929   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30930   esac
30931   ac_MKDIR_P=$MKDIR_P
30932   case $MKDIR_P in
30933   [\\/$]* | ?:[\\/]* ) ;;
30934   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30935   esac
30936 _ACEOF
30937
30938 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30939 # If the template does not know about datarootdir, expand it.
30940 # FIXME: This hack should be removed a few years after 2.60.
30941 ac_datarootdir_hack=; ac_datarootdir_seen=
30942
30943 ac_sed_dataroot='
30944 /datarootdir/ {
30945   p
30946   q
30947 }
30948 /@datadir@/p
30949 /@docdir@/p
30950 /@infodir@/p
30951 /@localedir@/p
30952 /@mandir@/p
30953 '
30954 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30955 *datarootdir*) ac_datarootdir_seen=yes;;
30956 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30957   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30958 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30959 _ACEOF
30960 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30961   ac_datarootdir_hack='
30962   s&@datadir@&$datadir&g
30963   s&@docdir@&$docdir&g
30964   s&@infodir@&$infodir&g
30965   s&@localedir@&$localedir&g
30966   s&@mandir@&$mandir&g
30967     s&\\\${datarootdir}&$datarootdir&g' ;;
30968 esac
30969 _ACEOF
30970
30971 # Neutralize VPATH when `$srcdir' = `.'.
30972 # Shell code in configure.ac might set extrasub.
30973 # FIXME: do we really want to maintain this feature?
30974 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30975 ac_sed_extra="$ac_vpsub
30976 $extrasub
30977 _ACEOF
30978 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30979 :t
30980 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30981 s|@configure_input@|$ac_sed_conf_input|;t t
30982 s&@top_builddir@&$ac_top_builddir_sub&;t t
30983 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30984 s&@srcdir@&$ac_srcdir&;t t
30985 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30986 s&@top_srcdir@&$ac_top_srcdir&;t t
30987 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30988 s&@builddir@&$ac_builddir&;t t
30989 s&@abs_builddir@&$ac_abs_builddir&;t t
30990 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30991 s&@INSTALL@&$ac_INSTALL&;t t
30992 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30993 $ac_datarootdir_hack
30994 "
30995 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
30996   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30997 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30998    { (exit 1); exit 1; }; }
30999
31000 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
31001   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
31002   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
31003   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
31004 which seems to be undefined.  Please make sure it is defined." >&5
31005 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
31006 which seems to be undefined.  Please make sure it is defined." >&2;}
31007
31008   rm -f "$tmp/stdin"
31009   case $ac_file in
31010   -) cat "$tmp/out" && rm -f "$tmp/out";;
31011   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
31012   esac \
31013   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31014 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31015    { (exit 1); exit 1; }; }
31016  ;;
31017   :H)
31018   #
31019   # CONFIG_HEADER
31020   #
31021   if test x"$ac_file" != x-; then
31022     {
31023       $as_echo "/* $configure_input  */" \
31024       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
31025     } >"$tmp/config.h" \
31026       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31027 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31028    { (exit 1); exit 1; }; }
31029     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
31030       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
31031 $as_echo "$as_me: $ac_file is unchanged" >&6;}
31032     else
31033       rm -f "$ac_file"
31034       mv "$tmp/config.h" "$ac_file" \
31035         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
31036 $as_echo "$as_me: error: could not create $ac_file" >&2;}
31037    { (exit 1); exit 1; }; }
31038     fi
31039   else
31040     $as_echo "/* $configure_input  */" \
31041       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
31042       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
31043 $as_echo "$as_me: error: could not create -" >&2;}
31044    { (exit 1); exit 1; }; }
31045   fi
31046  ;;
31047   :L)
31048   #
31049   # CONFIG_LINK
31050   #
31051
31052   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
31053     :
31054   else
31055     # Prefer the file from the source tree if names are identical.
31056     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
31057       ac_source=$srcdir/$ac_source
31058     fi
31059
31060     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
31061 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
31062
31063     if test ! -r "$ac_source"; then
31064       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
31065 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
31066    { (exit 1); exit 1; }; }
31067     fi
31068     rm -f "$ac_file"
31069
31070     # Try a relative symlink, then a hard link, then a copy.
31071     case $srcdir in
31072     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
31073         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
31074     esac
31075     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
31076       ln "$ac_source" "$ac_file" 2>/dev/null ||
31077       cp -p "$ac_source" "$ac_file" ||
31078       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
31079 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
31080    { (exit 1); exit 1; }; }
31081   fi
31082  ;;
31083   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
31084 $as_echo "$as_me: executing $ac_file commands" >&6;}
31085  ;;
31086   esac
31087
31088
31089   case $ac_file$ac_mode in
31090     "check_win32_symlinks":C)
31091 # Links sometimes fail undetected on Mingw -
31092 # so here we detect it and warn the user
31093 for FILE in $CONFIG_LINKS
31094  do
31095         # test -e works for symlinks in the MinGW console
31096         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
31097 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
31098  done
31099  ;;
31100     "src/include/pg_config.h":H)
31101 # Update timestamp for pg_config.h (see Makefile.global)
31102 echo >src/include/stamp-h
31103  ;;
31104     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
31105
31106   esac
31107 done # for ac_tag
31108
31109
31110 { (exit 0); exit 0; }
31111 _ACEOF
31112 chmod +x $CONFIG_STATUS
31113 ac_clean_files=$ac_clean_files_save
31114
31115 test $ac_write_fail = 0 ||
31116   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
31117 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
31118    { (exit 1); exit 1; }; }
31119
31120
31121 # configure is writing to config.log, and then calls config.status.
31122 # config.status does its own redirection, appending to config.log.
31123 # Unfortunately, on DOS this fails, as config.log is still kept open
31124 # by configure, so config.status won't be able to write to it; its
31125 # output is simply discarded.  So we exec the FD to /dev/null,
31126 # effectively closing config.log, so it can be properly (re)opened and
31127 # appended to by config.status.  When coming back to configure, we
31128 # need to make the FD available again.
31129 if test "$no_create" != yes; then
31130   ac_cs_success=:
31131   ac_config_status_args=
31132   test "$silent" = yes &&
31133     ac_config_status_args="$ac_config_status_args --quiet"
31134   exec 5>/dev/null
31135   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
31136   exec 5>>config.log
31137   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
31138   # would make configure fail if this is the last instruction.
31139   $ac_cs_success || { (exit 1); exit 1; }
31140 fi
31141 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
31142   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
31143 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
31144 fi
31145