]> granicus.if.org Git - postgresql/blob - configure
Document that \t and \x are now settable.
[postgresql] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.61 for PostgreSQL 8.4devel.
4 #
5 # Report bugs to <pgsql-bugs@postgresql.org>.
6 #
7 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
8 # 2002, 2003, 2004, 2005, 2006 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-2008, 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   # Zsh 3.x and 4.x performs 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 # The user is always right.
45 if test "${PATH_SEPARATOR+set}" != set; then
46   echo "#! /bin/sh" >conf$$.sh
47   echo  "exit 0"   >>conf$$.sh
48   chmod +x conf$$.sh
49   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
50     PATH_SEPARATOR=';'
51   else
52     PATH_SEPARATOR=:
53   fi
54   rm -f conf$$.sh
55 fi
56
57 # Support unset when possible.
58 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
59   as_unset=unset
60 else
61   as_unset=false
62 fi
63
64
65 # IFS
66 # We need space, tab and new line, in precisely that order.  Quoting is
67 # there to prevent editors from complaining about space-tab.
68 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
69 # splitting by setting IFS to empty value.)
70 as_nl='
71 '
72 IFS=" ""        $as_nl"
73
74 # Find who we are.  Look in the path if we contain no directory separator.
75 case $0 in
76   *[\\/]* ) as_myself=$0 ;;
77   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
78 for as_dir in $PATH
79 do
80   IFS=$as_save_IFS
81   test -z "$as_dir" && as_dir=.
82   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
83 done
84 IFS=$as_save_IFS
85
86      ;;
87 esac
88 # We did not find ourselves, most probably we were run as `sh COMMAND'
89 # in which case we are not to be found in the path.
90 if test "x$as_myself" = x; then
91   as_myself=$0
92 fi
93 if test ! -f "$as_myself"; then
94   echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
95   { (exit 1); exit 1; }
96 fi
97
98 # Work around bugs in pre-3.0 UWIN ksh.
99 for as_var in ENV MAIL MAILPATH
100 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
101 done
102 PS1='$ '
103 PS2='> '
104 PS4='+ '
105
106 # NLS nuisances.
107 for as_var in \
108   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
109   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
110   LC_TELEPHONE LC_TIME
111 do
112   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
113     eval $as_var=C; export $as_var
114   else
115     ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
116   fi
117 done
118
119 # Required to use basename.
120 if expr a : '\(a\)' >/dev/null 2>&1 &&
121    test "X`expr 00001 : '.*\(...\)'`" = X001; then
122   as_expr=expr
123 else
124   as_expr=false
125 fi
126
127 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
128   as_basename=basename
129 else
130   as_basename=false
131 fi
132
133
134 # Name of the executable.
135 as_me=`$as_basename -- "$0" ||
136 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
137          X"$0" : 'X\(//\)$' \| \
138          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
139 echo X/"$0" |
140     sed '/^.*\/\([^/][^/]*\)\/*$/{
141             s//\1/
142             q
143           }
144           /^X\/\(\/\/\)$/{
145             s//\1/
146             q
147           }
148           /^X\/\(\/\).*/{
149             s//\1/
150             q
151           }
152           s/.*/./; q'`
153
154 # CDPATH.
155 $as_unset CDPATH
156
157
158 if test "x$CONFIG_SHELL" = x; then
159   if (eval ":") 2>/dev/null; then
160   as_have_required=yes
161 else
162   as_have_required=no
163 fi
164
165   if test $as_have_required = yes &&     (eval ":
166 (as_func_return () {
167   (exit \$1)
168 }
169 as_func_success () {
170   as_func_return 0
171 }
172 as_func_failure () {
173   as_func_return 1
174 }
175 as_func_ret_success () {
176   return 0
177 }
178 as_func_ret_failure () {
179   return 1
180 }
181
182 exitcode=0
183 if as_func_success; then
184   :
185 else
186   exitcode=1
187   echo as_func_success failed.
188 fi
189
190 if as_func_failure; then
191   exitcode=1
192   echo as_func_failure succeeded.
193 fi
194
195 if as_func_ret_success; then
196   :
197 else
198   exitcode=1
199   echo as_func_ret_success failed.
200 fi
201
202 if as_func_ret_failure; then
203   exitcode=1
204   echo as_func_ret_failure succeeded.
205 fi
206
207 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
208   :
209 else
210   exitcode=1
211   echo positional parameters were not saved.
212 fi
213
214 test \$exitcode = 0) || { (exit 1); exit 1; }
215
216 (
217   as_lineno_1=\$LINENO
218   as_lineno_2=\$LINENO
219   test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
220   test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
221 ") 2> /dev/null; then
222   :
223 else
224   as_candidate_shells=
225     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
226 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
227 do
228   IFS=$as_save_IFS
229   test -z "$as_dir" && as_dir=.
230   case $as_dir in
231          /*)
232            for as_base in sh bash ksh sh5; do
233              as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
234            done;;
235        esac
236 done
237 IFS=$as_save_IFS
238
239
240       for as_shell in $as_candidate_shells $SHELL; do
241          # Try only shells that exist, to save several forks.
242          if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
243                 { ("$as_shell") 2> /dev/null <<\_ASEOF
244 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
245   emulate sh
246   NULLCMD=:
247   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
248   # is contrary to our usage.  Disable this feature.
249   alias -g '${1+"$@"}'='"$@"'
250   setopt NO_GLOB_SUBST
251 else
252   case `(set -o) 2>/dev/null` in
253   *posix*) set -o posix ;;
254 esac
255
256 fi
257
258
259 :
260 _ASEOF
261 }; then
262   CONFIG_SHELL=$as_shell
263                as_have_required=yes
264                if { "$as_shell" 2> /dev/null <<\_ASEOF
265 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
266   emulate sh
267   NULLCMD=:
268   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
269   # is contrary to our usage.  Disable this feature.
270   alias -g '${1+"$@"}'='"$@"'
271   setopt NO_GLOB_SUBST
272 else
273   case `(set -o) 2>/dev/null` in
274   *posix*) set -o posix ;;
275 esac
276
277 fi
278
279
280 :
281 (as_func_return () {
282   (exit $1)
283 }
284 as_func_success () {
285   as_func_return 0
286 }
287 as_func_failure () {
288   as_func_return 1
289 }
290 as_func_ret_success () {
291   return 0
292 }
293 as_func_ret_failure () {
294   return 1
295 }
296
297 exitcode=0
298 if as_func_success; then
299   :
300 else
301   exitcode=1
302   echo as_func_success failed.
303 fi
304
305 if as_func_failure; then
306   exitcode=1
307   echo as_func_failure succeeded.
308 fi
309
310 if as_func_ret_success; then
311   :
312 else
313   exitcode=1
314   echo as_func_ret_success failed.
315 fi
316
317 if as_func_ret_failure; then
318   exitcode=1
319   echo as_func_ret_failure succeeded.
320 fi
321
322 if ( set x; as_func_ret_success y && test x = "$1" ); then
323   :
324 else
325   exitcode=1
326   echo positional parameters were not saved.
327 fi
328
329 test $exitcode = 0) || { (exit 1); exit 1; }
330
331 (
332   as_lineno_1=$LINENO
333   as_lineno_2=$LINENO
334   test "x$as_lineno_1" != "x$as_lineno_2" &&
335   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
336
337 _ASEOF
338 }; then
339   break
340 fi
341
342 fi
343
344       done
345
346       if test "x$CONFIG_SHELL" != x; then
347   for as_var in BASH_ENV ENV
348         do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
349         done
350         export CONFIG_SHELL
351         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
352 fi
353
354
355     if test $as_have_required = no; then
356   echo This script requires a shell more modern than all the
357       echo shells that I found on your system.  Please install a
358       echo modern shell, or manually run the script under such a
359       echo shell if you do have one.
360       { (exit 1); exit 1; }
361 fi
362
363
364 fi
365
366 fi
367
368
369
370 (eval "as_func_return () {
371   (exit \$1)
372 }
373 as_func_success () {
374   as_func_return 0
375 }
376 as_func_failure () {
377   as_func_return 1
378 }
379 as_func_ret_success () {
380   return 0
381 }
382 as_func_ret_failure () {
383   return 1
384 }
385
386 exitcode=0
387 if as_func_success; then
388   :
389 else
390   exitcode=1
391   echo as_func_success failed.
392 fi
393
394 if as_func_failure; then
395   exitcode=1
396   echo as_func_failure succeeded.
397 fi
398
399 if as_func_ret_success; then
400   :
401 else
402   exitcode=1
403   echo as_func_ret_success failed.
404 fi
405
406 if as_func_ret_failure; then
407   exitcode=1
408   echo as_func_ret_failure succeeded.
409 fi
410
411 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
412   :
413 else
414   exitcode=1
415   echo positional parameters were not saved.
416 fi
417
418 test \$exitcode = 0") || {
419   echo No shell found that supports shell functions.
420   echo Please tell autoconf@gnu.org about your system,
421   echo including any error possibly output before this
422   echo message
423 }
424
425
426
427   as_lineno_1=$LINENO
428   as_lineno_2=$LINENO
429   test "x$as_lineno_1" != "x$as_lineno_2" &&
430   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
431
432   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
433   # uniformly replaced by the line number.  The first 'sed' inserts a
434   # line-number line after each line using $LINENO; the second 'sed'
435   # does the real work.  The second script uses 'N' to pair each
436   # line-number line with the line containing $LINENO, and appends
437   # trailing '-' during substitution so that $LINENO is not a special
438   # case at line end.
439   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
440   # scripts with optimization help from Paolo Bonzini.  Blame Lee
441   # E. McMahon (1931-1989) for sed's syntax.  :-)
442   sed -n '
443     p
444     /[$]LINENO/=
445   ' <$as_myself |
446     sed '
447       s/[$]LINENO.*/&-/
448       t lineno
449       b
450       :lineno
451       N
452       :loop
453       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
454       t loop
455       s/-\n.*//
456     ' >$as_me.lineno &&
457   chmod +x "$as_me.lineno" ||
458     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
459    { (exit 1); exit 1; }; }
460
461   # Don't try to exec as it changes $[0], causing all sort of problems
462   # (the dirname of $[0] is not the place where we might find the
463   # original and so on.  Autoconf is especially sensitive to this).
464   . "./$as_me.lineno"
465   # Exit status is that of the last command.
466   exit
467 }
468
469
470 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
471   as_dirname=dirname
472 else
473   as_dirname=false
474 fi
475
476 ECHO_C= ECHO_N= ECHO_T=
477 case `echo -n x` in
478 -n*)
479   case `echo 'x\c'` in
480   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
481   *)   ECHO_C='\c';;
482   esac;;
483 *)
484   ECHO_N='-n';;
485 esac
486
487 if expr a : '\(a\)' >/dev/null 2>&1 &&
488    test "X`expr 00001 : '.*\(...\)'`" = X001; then
489   as_expr=expr
490 else
491   as_expr=false
492 fi
493
494 rm -f conf$$ conf$$.exe conf$$.file
495 if test -d conf$$.dir; then
496   rm -f conf$$.dir/conf$$.file
497 else
498   rm -f conf$$.dir
499   mkdir conf$$.dir
500 fi
501 echo >conf$$.file
502 if ln -s conf$$.file conf$$ 2>/dev/null; then
503   as_ln_s='ln -s'
504   # ... but there are two gotchas:
505   # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
506   # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
507   # In both cases, we have to default to `cp -p'.
508   ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
509     as_ln_s='cp -p'
510 elif ln conf$$.file conf$$ 2>/dev/null; then
511   as_ln_s=ln
512 else
513   as_ln_s='cp -p'
514 fi
515 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
516 rmdir conf$$.dir 2>/dev/null
517
518 if mkdir -p . 2>/dev/null; then
519   as_mkdir_p=:
520 else
521   test -d ./-p && rmdir ./-p
522   as_mkdir_p=false
523 fi
524
525 if test -x / >/dev/null 2>&1; then
526   as_test_x='test -x'
527 else
528   if ls -dL / >/dev/null 2>&1; then
529     as_ls_L_option=L
530   else
531     as_ls_L_option=
532   fi
533   as_test_x='
534     eval sh -c '\''
535       if test -d "$1"; then
536         test -d "$1/.";
537       else
538         case $1 in
539         -*)set "./$1";;
540         esac;
541         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
542         ???[sx]*):;;*)false;;esac;fi
543     '\'' sh
544   '
545 fi
546 as_executable_p=$as_test_x
547
548 # Sed expression to map a string onto a valid CPP name.
549 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
550
551 # Sed expression to map a string onto a valid variable name.
552 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
553
554
555
556 exec 7<&0 </dev/null 6>&1
557
558 # Name of the host.
559 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
560 # so uname gets run too.
561 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
562
563 #
564 # Initializations.
565 #
566 ac_default_prefix=/usr/local
567 ac_clean_files=
568 ac_config_libobj_dir=.
569 LIBOBJS=
570 cross_compiling=no
571 subdirs=
572 MFLAGS=
573 MAKEFLAGS=
574 SHELL=${CONFIG_SHELL-/bin/sh}
575
576 # Identity of this package.
577 PACKAGE_NAME='PostgreSQL'
578 PACKAGE_TARNAME='postgresql'
579 PACKAGE_VERSION='8.4devel'
580 PACKAGE_STRING='PostgreSQL 8.4devel'
581 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
582
583 ac_unique_file="src/backend/access/common/heaptuple.c"
584 ac_default_prefix=/usr/local/pgsql
585 # Factoring default headers for most tests.
586 ac_includes_default="\
587 #include <stdio.h>
588 #ifdef HAVE_SYS_TYPES_H
589 # include <sys/types.h>
590 #endif
591 #ifdef HAVE_SYS_STAT_H
592 # include <sys/stat.h>
593 #endif
594 #ifdef STDC_HEADERS
595 # include <stdlib.h>
596 # include <stddef.h>
597 #else
598 # ifdef HAVE_STDLIB_H
599 #  include <stdlib.h>
600 # endif
601 #endif
602 #ifdef HAVE_STRING_H
603 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
604 #  include <memory.h>
605 # endif
606 # include <string.h>
607 #endif
608 #ifdef HAVE_STRINGS_H
609 # include <strings.h>
610 #endif
611 #ifdef HAVE_INTTYPES_H
612 # include <inttypes.h>
613 #endif
614 #ifdef HAVE_STDINT_H
615 # include <stdint.h>
616 #endif
617 #ifdef HAVE_UNISTD_H
618 # include <unistd.h>
619 #endif"
620
621 ac_subst_vars='SHELL
622 PATH_SEPARATOR
623 PACKAGE_NAME
624 PACKAGE_TARNAME
625 PACKAGE_VERSION
626 PACKAGE_STRING
627 PACKAGE_BUGREPORT
628 exec_prefix
629 prefix
630 program_transform_name
631 bindir
632 sbindir
633 libexecdir
634 datarootdir
635 datadir
636 sysconfdir
637 sharedstatedir
638 localstatedir
639 includedir
640 oldincludedir
641 docdir
642 infodir
643 htmldir
644 dvidir
645 pdfdir
646 psdir
647 libdir
648 localedir
649 mandir
650 DEFS
651 ECHO_C
652 ECHO_N
653 ECHO_T
654 LIBS
655 build_alias
656 host_alias
657 target_alias
658 configure_args
659 build
660 build_cpu
661 build_vendor
662 build_os
663 host
664 host_cpu
665 host_vendor
666 host_os
667 PORTNAME
668 enable_nls
669 WANTED_LANGUAGES
670 default_port
671 enable_shared
672 enable_rpath
673 enable_debug
674 enable_profiling
675 DTRACE
676 DTRACEFLAGS
677 enable_dtrace
678 CC
679 CFLAGS
680 LDFLAGS
681 CPPFLAGS
682 ac_ct_CC
683 EXEEXT
684 OBJEXT
685 CPP
686 GCC
687 TAS
688 autodepend
689 INCLUDES
690 enable_thread_safety
691 with_tcl
692 with_perl
693 with_python
694 with_gssapi
695 with_krb5
696 krb_srvtab
697 with_pam
698 with_ldap
699 with_bonjour
700 with_openssl
701 with_ossp_uuid
702 XML2_CONFIG
703 with_libxml
704 with_libxslt
705 with_system_tzdata
706 with_zlib
707 GREP
708 EGREP
709 ELF_SYS
710 LDFLAGS_SL
711 LD
712 with_gnu_ld
713 ld_R_works
714 RANLIB
715 STRIP
716 STRIP_STATIC_LIB
717 STRIP_SHARED_LIB
718 TAR
719 LN_S
720 AWK
721 BISON
722 BISONFLAGS
723 FLEX
724 FLEXFLAGS
725 PERL
726 perl_archlibexp
727 perl_privlibexp
728 perl_useshrplib
729 perl_embed_ldflags
730 PYTHON
731 python_version
732 python_configdir
733 python_includespec
734 python_libdir
735 python_libspec
736 python_additional_libs
737 OSSP_UUID_LIBS
738 HAVE_IPV6
739 LIBOBJS
740 acx_pthread_config
741 PTHREAD_CC
742 PTHREAD_LIBS
743 PTHREAD_CFLAGS
744 LDAP_LIBS_FE
745 LDAP_LIBS_BE
746 HAVE_POSIX_SIGNALS
747 MSGFMT
748 MSGMERGE
749 XGETTEXT
750 TCLSH
751 TCL_CONFIG_SH
752 TCL_INCLUDE_SPEC
753 TCL_LIB_FILE
754 TCL_LIBS
755 TCL_LIB_SPEC
756 TCL_SHARED_BUILD
757 TCL_SHLIB_LD_LIBS
758 NSGMLS
759 JADE
760 have_docbook
761 DOCBOOKSTYLE
762 COLLATEINDEX
763 SGMLSPL
764 vpath_build
765 LTLIBOBJS'
766 ac_subst_files=''
767       ac_precious_vars='build_alias
768 host_alias
769 target_alias
770 CC
771 CFLAGS
772 LDFLAGS
773 LIBS
774 CPPFLAGS
775 CPP
776 LDFLAGS_SL
777 DOCBOOKSTYLE'
778
779
780 # Initialize some variables set by options.
781 ac_init_help=
782 ac_init_version=false
783 # The variables have the same names as the options, with
784 # dashes changed to underlines.
785 cache_file=/dev/null
786 exec_prefix=NONE
787 no_create=
788 no_recursion=
789 prefix=NONE
790 program_prefix=NONE
791 program_suffix=NONE
792 program_transform_name=s,x,x,
793 silent=
794 site=
795 srcdir=
796 verbose=
797 x_includes=NONE
798 x_libraries=NONE
799
800 # Installation directory options.
801 # These are left unexpanded so users can "make install exec_prefix=/foo"
802 # and all the variables that are supposed to be based on exec_prefix
803 # by default will actually change.
804 # Use braces instead of parens because sh, perl, etc. also accept them.
805 # (The list follows the same order as the GNU Coding Standards.)
806 bindir='${exec_prefix}/bin'
807 sbindir='${exec_prefix}/sbin'
808 libexecdir='${exec_prefix}/libexec'
809 datarootdir='${prefix}/share'
810 datadir='${datarootdir}'
811 sysconfdir='${prefix}/etc'
812 sharedstatedir='${prefix}/com'
813 localstatedir='${prefix}/var'
814 includedir='${prefix}/include'
815 oldincludedir='/usr/include'
816 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
817 infodir='${datarootdir}/info'
818 htmldir='${docdir}'
819 dvidir='${docdir}'
820 pdfdir='${docdir}'
821 psdir='${docdir}'
822 libdir='${exec_prefix}/lib'
823 localedir='${datarootdir}/locale'
824 mandir='${datarootdir}/man'
825
826 ac_prev=
827 ac_dashdash=
828 for ac_option
829 do
830   # If the previous option needs an argument, assign it.
831   if test -n "$ac_prev"; then
832     eval $ac_prev=\$ac_option
833     ac_prev=
834     continue
835   fi
836
837   case $ac_option in
838   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
839   *)    ac_optarg=yes ;;
840   esac
841
842   # Accept the important Cygnus configure options, so we can diagnose typos.
843
844   case $ac_dashdash$ac_option in
845   --)
846     ac_dashdash=yes ;;
847
848   -bindir | --bindir | --bindi | --bind | --bin | --bi)
849     ac_prev=bindir ;;
850   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
851     bindir=$ac_optarg ;;
852
853   -build | --build | --buil | --bui | --bu)
854     ac_prev=build_alias ;;
855   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
856     build_alias=$ac_optarg ;;
857
858   -cache-file | --cache-file | --cache-fil | --cache-fi \
859   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
860     ac_prev=cache_file ;;
861   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
862   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
863     cache_file=$ac_optarg ;;
864
865   --config-cache | -C)
866     cache_file=config.cache ;;
867
868   -datadir | --datadir | --datadi | --datad)
869     ac_prev=datadir ;;
870   -datadir=* | --datadir=* | --datadi=* | --datad=*)
871     datadir=$ac_optarg ;;
872
873   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
874   | --dataroo | --dataro | --datar)
875     ac_prev=datarootdir ;;
876   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
877   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
878     datarootdir=$ac_optarg ;;
879
880   -disable-* | --disable-*)
881     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
882     # Reject names that are not valid shell variable names.
883     expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
884       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
885    { (exit 1); exit 1; }; }
886     ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
887     eval enable_$ac_feature=no ;;
888
889   -docdir | --docdir | --docdi | --doc | --do)
890     ac_prev=docdir ;;
891   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
892     docdir=$ac_optarg ;;
893
894   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
895     ac_prev=dvidir ;;
896   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
897     dvidir=$ac_optarg ;;
898
899   -enable-* | --enable-*)
900     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
901     # Reject names that are not valid shell variable names.
902     expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
903       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
904    { (exit 1); exit 1; }; }
905     ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
906     eval enable_$ac_feature=\$ac_optarg ;;
907
908   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
909   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
910   | --exec | --exe | --ex)
911     ac_prev=exec_prefix ;;
912   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
913   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
914   | --exec=* | --exe=* | --ex=*)
915     exec_prefix=$ac_optarg ;;
916
917   -gas | --gas | --ga | --g)
918     # Obsolete; use --with-gas.
919     with_gas=yes ;;
920
921   -help | --help | --hel | --he | -h)
922     ac_init_help=long ;;
923   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
924     ac_init_help=recursive ;;
925   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
926     ac_init_help=short ;;
927
928   -host | --host | --hos | --ho)
929     ac_prev=host_alias ;;
930   -host=* | --host=* | --hos=* | --ho=*)
931     host_alias=$ac_optarg ;;
932
933   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
934     ac_prev=htmldir ;;
935   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
936   | --ht=*)
937     htmldir=$ac_optarg ;;
938
939   -includedir | --includedir | --includedi | --included | --include \
940   | --includ | --inclu | --incl | --inc)
941     ac_prev=includedir ;;
942   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
943   | --includ=* | --inclu=* | --incl=* | --inc=*)
944     includedir=$ac_optarg ;;
945
946   -infodir | --infodir | --infodi | --infod | --info | --inf)
947     ac_prev=infodir ;;
948   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
949     infodir=$ac_optarg ;;
950
951   -libdir | --libdir | --libdi | --libd)
952     ac_prev=libdir ;;
953   -libdir=* | --libdir=* | --libdi=* | --libd=*)
954     libdir=$ac_optarg ;;
955
956   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
957   | --libexe | --libex | --libe)
958     ac_prev=libexecdir ;;
959   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
960   | --libexe=* | --libex=* | --libe=*)
961     libexecdir=$ac_optarg ;;
962
963   -localedir | --localedir | --localedi | --localed | --locale)
964     ac_prev=localedir ;;
965   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
966     localedir=$ac_optarg ;;
967
968   -localstatedir | --localstatedir | --localstatedi | --localstated \
969   | --localstate | --localstat | --localsta | --localst | --locals)
970     ac_prev=localstatedir ;;
971   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
972   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
973     localstatedir=$ac_optarg ;;
974
975   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
976     ac_prev=mandir ;;
977   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
978     mandir=$ac_optarg ;;
979
980   -nfp | --nfp | --nf)
981     # Obsolete; use --without-fp.
982     with_fp=no ;;
983
984   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
985   | --no-cr | --no-c | -n)
986     no_create=yes ;;
987
988   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
989   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
990     no_recursion=yes ;;
991
992   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
993   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
994   | --oldin | --oldi | --old | --ol | --o)
995     ac_prev=oldincludedir ;;
996   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
997   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
998   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
999     oldincludedir=$ac_optarg ;;
1000
1001   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1002     ac_prev=prefix ;;
1003   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1004     prefix=$ac_optarg ;;
1005
1006   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1007   | --program-pre | --program-pr | --program-p)
1008     ac_prev=program_prefix ;;
1009   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1010   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1011     program_prefix=$ac_optarg ;;
1012
1013   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1014   | --program-suf | --program-su | --program-s)
1015     ac_prev=program_suffix ;;
1016   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1017   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1018     program_suffix=$ac_optarg ;;
1019
1020   -program-transform-name | --program-transform-name \
1021   | --program-transform-nam | --program-transform-na \
1022   | --program-transform-n | --program-transform- \
1023   | --program-transform | --program-transfor \
1024   | --program-transfo | --program-transf \
1025   | --program-trans | --program-tran \
1026   | --progr-tra | --program-tr | --program-t)
1027     ac_prev=program_transform_name ;;
1028   -program-transform-name=* | --program-transform-name=* \
1029   | --program-transform-nam=* | --program-transform-na=* \
1030   | --program-transform-n=* | --program-transform-=* \
1031   | --program-transform=* | --program-transfor=* \
1032   | --program-transfo=* | --program-transf=* \
1033   | --program-trans=* | --program-tran=* \
1034   | --progr-tra=* | --program-tr=* | --program-t=*)
1035     program_transform_name=$ac_optarg ;;
1036
1037   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1038     ac_prev=pdfdir ;;
1039   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1040     pdfdir=$ac_optarg ;;
1041
1042   -psdir | --psdir | --psdi | --psd | --ps)
1043     ac_prev=psdir ;;
1044   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1045     psdir=$ac_optarg ;;
1046
1047   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1048   | -silent | --silent | --silen | --sile | --sil)
1049     silent=yes ;;
1050
1051   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1052     ac_prev=sbindir ;;
1053   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1054   | --sbi=* | --sb=*)
1055     sbindir=$ac_optarg ;;
1056
1057   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1058   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1059   | --sharedst | --shareds | --shared | --share | --shar \
1060   | --sha | --sh)
1061     ac_prev=sharedstatedir ;;
1062   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1063   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1064   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1065   | --sha=* | --sh=*)
1066     sharedstatedir=$ac_optarg ;;
1067
1068   -site | --site | --sit)
1069     ac_prev=site ;;
1070   -site=* | --site=* | --sit=*)
1071     site=$ac_optarg ;;
1072
1073   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1074     ac_prev=srcdir ;;
1075   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1076     srcdir=$ac_optarg ;;
1077
1078   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1079   | --syscon | --sysco | --sysc | --sys | --sy)
1080     ac_prev=sysconfdir ;;
1081   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1082   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1083     sysconfdir=$ac_optarg ;;
1084
1085   -target | --target | --targe | --targ | --tar | --ta | --t)
1086     ac_prev=target_alias ;;
1087   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1088     target_alias=$ac_optarg ;;
1089
1090   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1091     verbose=yes ;;
1092
1093   -version | --version | --versio | --versi | --vers | -V)
1094     ac_init_version=: ;;
1095
1096   -with-* | --with-*)
1097     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1098     # Reject names that are not valid shell variable names.
1099     expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1100       { echo "$as_me: error: invalid package name: $ac_package" >&2
1101    { (exit 1); exit 1; }; }
1102     ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1103     eval with_$ac_package=\$ac_optarg ;;
1104
1105   -without-* | --without-*)
1106     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1107     # Reject names that are not valid shell variable names.
1108     expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1109       { echo "$as_me: error: invalid package name: $ac_package" >&2
1110    { (exit 1); exit 1; }; }
1111     ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1112     eval with_$ac_package=no ;;
1113
1114   --x)
1115     # Obsolete; use --with-x.
1116     with_x=yes ;;
1117
1118   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1119   | --x-incl | --x-inc | --x-in | --x-i)
1120     ac_prev=x_includes ;;
1121   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1122   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1123     x_includes=$ac_optarg ;;
1124
1125   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1126   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1127     ac_prev=x_libraries ;;
1128   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1129   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1130     x_libraries=$ac_optarg ;;
1131
1132   -*) { echo "$as_me: error: unrecognized option: $ac_option
1133 Try \`$0 --help' for more information." >&2
1134    { (exit 1); exit 1; }; }
1135     ;;
1136
1137   *=*)
1138     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1139     # Reject names that are not valid shell variable names.
1140     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1141       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1142    { (exit 1); exit 1; }; }
1143     eval $ac_envvar=\$ac_optarg
1144     export $ac_envvar ;;
1145
1146   *)
1147     # FIXME: should be removed in autoconf 3.0.
1148     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1149     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1150       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1151     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1152     ;;
1153
1154   esac
1155 done
1156
1157 if test -n "$ac_prev"; then
1158   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1159   { echo "$as_me: error: missing argument to $ac_option" >&2
1160    { (exit 1); exit 1; }; }
1161 fi
1162
1163 # Be sure to have absolute directory names.
1164 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1165                 datadir sysconfdir sharedstatedir localstatedir includedir \
1166                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1167                 libdir localedir mandir
1168 do
1169   eval ac_val=\$$ac_var
1170   case $ac_val in
1171     [\\/$]* | ?:[\\/]* )  continue;;
1172     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1173   esac
1174   { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1175    { (exit 1); exit 1; }; }
1176 done
1177
1178 # There might be people who depend on the old broken behavior: `$host'
1179 # used to hold the argument of --host etc.
1180 # FIXME: To remove some day.
1181 build=$build_alias
1182 host=$host_alias
1183 target=$target_alias
1184
1185 # FIXME: To remove some day.
1186 if test "x$host_alias" != x; then
1187   if test "x$build_alias" = x; then
1188     cross_compiling=maybe
1189     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1190     If a cross compiler is detected then cross compile mode will be used." >&2
1191   elif test "x$build_alias" != "x$host_alias"; then
1192     cross_compiling=yes
1193   fi
1194 fi
1195
1196 ac_tool_prefix=
1197 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1198
1199 test "$silent" = yes && exec 6>/dev/null
1200
1201
1202 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1203 ac_ls_di=`ls -di .` &&
1204 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1205   { echo "$as_me: error: Working directory cannot be determined" >&2
1206    { (exit 1); exit 1; }; }
1207 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1208   { echo "$as_me: error: pwd does not report name of working directory" >&2
1209    { (exit 1); exit 1; }; }
1210
1211
1212 # Find the source files, if location was not specified.
1213 if test -z "$srcdir"; then
1214   ac_srcdir_defaulted=yes
1215   # Try the directory containing this script, then the parent directory.
1216   ac_confdir=`$as_dirname -- "$0" ||
1217 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1218          X"$0" : 'X\(//\)[^/]' \| \
1219          X"$0" : 'X\(//\)$' \| \
1220          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
1221 echo X"$0" |
1222     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1223             s//\1/
1224             q
1225           }
1226           /^X\(\/\/\)[^/].*/{
1227             s//\1/
1228             q
1229           }
1230           /^X\(\/\/\)$/{
1231             s//\1/
1232             q
1233           }
1234           /^X\(\/\).*/{
1235             s//\1/
1236             q
1237           }
1238           s/.*/./; q'`
1239   srcdir=$ac_confdir
1240   if test ! -r "$srcdir/$ac_unique_file"; then
1241     srcdir=..
1242   fi
1243 else
1244   ac_srcdir_defaulted=no
1245 fi
1246 if test ! -r "$srcdir/$ac_unique_file"; then
1247   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1248   { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1249    { (exit 1); exit 1; }; }
1250 fi
1251 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1252 ac_abs_confdir=`(
1253         cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
1254    { (exit 1); exit 1; }; }
1255         pwd)`
1256 # When building in place, set srcdir=.
1257 if test "$ac_abs_confdir" = "$ac_pwd"; then
1258   srcdir=.
1259 fi
1260 # Remove unnecessary trailing slashes from srcdir.
1261 # Double slashes in file names in object file debugging info
1262 # mess up M-x gdb in Emacs.
1263 case $srcdir in
1264 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1265 esac
1266 for ac_var in $ac_precious_vars; do
1267   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1268   eval ac_env_${ac_var}_value=\$${ac_var}
1269   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1270   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1271 done
1272
1273 #
1274 # Report the --help message.
1275 #
1276 if test "$ac_init_help" = "long"; then
1277   # Omit some internal or obsolete options to make the list less imposing.
1278   # This message is too long to be a string in the A/UX 3.1 sh.
1279   cat <<_ACEOF
1280 \`configure' configures PostgreSQL 8.4devel to adapt to many kinds of systems.
1281
1282 Usage: $0 [OPTION]... [VAR=VALUE]...
1283
1284 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1285 VAR=VALUE.  See below for descriptions of some of the useful variables.
1286
1287 Defaults for the options are specified in brackets.
1288
1289 Configuration:
1290   -h, --help              display this help and exit
1291       --help=short        display options specific to this package
1292       --help=recursive    display the short help of all the included packages
1293   -V, --version           display version information and exit
1294   -q, --quiet, --silent   do not print \`checking...' messages
1295       --cache-file=FILE   cache test results in FILE [disabled]
1296   -C, --config-cache      alias for \`--cache-file=config.cache'
1297   -n, --no-create         do not create output files
1298       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1299
1300 Installation directories:
1301   --prefix=PREFIX         install architecture-independent files in PREFIX
1302                           [$ac_default_prefix]
1303   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1304                           [PREFIX]
1305
1306 By default, \`make install' will install all the files in
1307 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1308 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1309 for instance \`--prefix=\$HOME'.
1310
1311 For better control, use the options below.
1312
1313 Fine tuning of the installation directories:
1314   --bindir=DIR           user executables [EPREFIX/bin]
1315   --sbindir=DIR          system admin executables [EPREFIX/sbin]
1316   --libexecdir=DIR       program executables [EPREFIX/libexec]
1317   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
1318   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
1319   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
1320   --libdir=DIR           object code libraries [EPREFIX/lib]
1321   --includedir=DIR       C header files [PREFIX/include]
1322   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
1323   --datarootdir=DIR      read-only arch.-independent data root [PREFIX/share]
1324   --datadir=DIR          read-only architecture-independent data [DATAROOTDIR]
1325   --infodir=DIR          info documentation [DATAROOTDIR/info]
1326   --localedir=DIR        locale-dependent data [DATAROOTDIR/locale]
1327   --mandir=DIR           man documentation [DATAROOTDIR/man]
1328   --docdir=DIR           documentation root [DATAROOTDIR/doc/postgresql]
1329   --htmldir=DIR          html documentation [DOCDIR]
1330   --dvidir=DIR           dvi documentation [DOCDIR]
1331   --pdfdir=DIR           pdf documentation [DOCDIR]
1332   --psdir=DIR            ps documentation [DOCDIR]
1333 _ACEOF
1334
1335   cat <<\_ACEOF
1336
1337 System types:
1338   --build=BUILD     configure for building on BUILD [guessed]
1339   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1340 _ACEOF
1341 fi
1342
1343 if test -n "$ac_init_help"; then
1344   case $ac_init_help in
1345      short | recursive ) echo "Configuration of PostgreSQL 8.4devel:";;
1346    esac
1347   cat <<\_ACEOF
1348
1349 Optional Features:
1350   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1351   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1352   --disable-integer-datetimes  disable 64-bit integer date/time support
1353   --enable-nls[=LANGUAGES]  enable Native Language Support
1354   --disable-shared        do not build shared libraries
1355   --disable-rpath         do not embed shared library search path in executables
1356   --disable-spinlocks     do not use spinlocks
1357   --enable-debug          build with debugging symbols (-g)
1358   --enable-profiling      build with profiling enabled
1359   --enable-dtrace         build with DTrace support
1360   --enable-depend         turn on automatic dependency tracking
1361   --enable-cassert        enable assertion checks (for debugging)
1362   --enable-thread-safety  make client libraries thread-safe
1363   --enable-thread-safety-force  force thread-safety despite thread test failure
1364   --disable-float4-byval  disable float4 passed by value
1365   --disable-float8-byval  disable float8 passed by value
1366   --disable-largefile     omit support for large files
1367
1368 Optional Packages:
1369   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1370   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1371
1372   --with-includes=DIRS    look for additional header files in DIRS
1373   --with-libraries=DIRS   look for additional libraries in DIRS
1374   --with-libs=DIRS        alternative spelling of --with-libraries
1375   --with-pgport=PORTNUM   set default port number [5432]
1376   --with-blocksize=BLOCKSIZE  set table block size in kB [8]
1377   --with-segsize=SEGSIZE  set table segment size in GB [1]
1378   --with-wal-blocksize=BLOCKSIZE  set WAL block size in kB [8]
1379   --with-wal-segsize=SEGSIZE  set WAL segment size in MB [16]
1380   --with-tcl              build Tcl modules (PL/Tcl)
1381   --with-tclconfig=DIR    tclConfig.sh is in DIR
1382   --with-perl             build Perl modules (PL/Perl)
1383   --with-python           build Python modules (PL/Python)
1384   --with-gssapi           build with GSSAPI support
1385   --with-krb5             build with Kerberos 5 support
1386   --with-krb-srvnam=NAME  default service principal name in Kerberos [postgres]
1387   --with-pam              build with PAM support
1388   --with-ldap             build with LDAP support
1389   --with-bonjour          build with Bonjour support
1390   --with-openssl          build with OpenSSL support
1391   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1392   --with-libedit-preferred  prefer BSD Libedit over GNU Readline
1393   --with-ossp-uuid        use OSSP UUID library when building contrib/uuid-ossp
1394   --with-libxml           build with XML support
1395   --with-libxslt          use XSLT support when building contrib/xml2
1396   --with-system-tzdata=DIR  use system time zone data in DIR
1397   --without-zlib          do not use Zlib
1398   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1399
1400 Some influential environment variables:
1401   CC          C compiler command
1402   CFLAGS      C compiler flags
1403   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1404               nonstandard directory <lib dir>
1405   LIBS        libraries to pass to the linker, e.g. -l<library>
1406   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1407               you have headers in a nonstandard directory <include dir>
1408   CPP         C preprocessor
1409   LDFLAGS_SL
1410   DOCBOOKSTYLE
1411               location of DocBook stylesheets
1412
1413 Use these variables to override the choices made by `configure' or to help
1414 it to find libraries and programs with nonstandard names/locations.
1415
1416 Report bugs to <pgsql-bugs@postgresql.org>.
1417 _ACEOF
1418 ac_status=$?
1419 fi
1420
1421 if test "$ac_init_help" = "recursive"; then
1422   # If there are subdirs, report their specific --help.
1423   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1424     test -d "$ac_dir" || continue
1425     ac_builddir=.
1426
1427 case "$ac_dir" in
1428 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1429 *)
1430   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1431   # A ".." for each directory in $ac_dir_suffix.
1432   ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
1433   case $ac_top_builddir_sub in
1434   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1435   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1436   esac ;;
1437 esac
1438 ac_abs_top_builddir=$ac_pwd
1439 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1440 # for backward compatibility:
1441 ac_top_builddir=$ac_top_build_prefix
1442
1443 case $srcdir in
1444   .)  # We are building in place.
1445     ac_srcdir=.
1446     ac_top_srcdir=$ac_top_builddir_sub
1447     ac_abs_top_srcdir=$ac_pwd ;;
1448   [\\/]* | ?:[\\/]* )  # Absolute name.
1449     ac_srcdir=$srcdir$ac_dir_suffix;
1450     ac_top_srcdir=$srcdir
1451     ac_abs_top_srcdir=$srcdir ;;
1452   *) # Relative name.
1453     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1454     ac_top_srcdir=$ac_top_build_prefix$srcdir
1455     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1456 esac
1457 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1458
1459     cd "$ac_dir" || { ac_status=$?; continue; }
1460     # Check for guested configure.
1461     if test -f "$ac_srcdir/configure.gnu"; then
1462       echo &&
1463       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1464     elif test -f "$ac_srcdir/configure"; then
1465       echo &&
1466       $SHELL "$ac_srcdir/configure" --help=recursive
1467     else
1468       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1469     fi || ac_status=$?
1470     cd "$ac_pwd" || { ac_status=$?; break; }
1471   done
1472 fi
1473
1474 test -n "$ac_init_help" && exit $ac_status
1475 if $ac_init_version; then
1476   cat <<\_ACEOF
1477 PostgreSQL configure 8.4devel
1478 generated by GNU Autoconf 2.61
1479
1480 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1481 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
1482 This configure script is free software; the Free Software Foundation
1483 gives unlimited permission to copy, distribute and modify it.
1484
1485 Copyright (c) 1996-2008, PostgreSQL Global Development Group
1486 _ACEOF
1487   exit
1488 fi
1489 cat >config.log <<_ACEOF
1490 This file contains any messages produced by compilers while
1491 running configure, to aid debugging if configure makes a mistake.
1492
1493 It was created by PostgreSQL $as_me 8.4devel, which was
1494 generated by GNU Autoconf 2.61.  Invocation command line was
1495
1496   $ $0 $@
1497
1498 _ACEOF
1499 exec 5>>config.log
1500 {
1501 cat <<_ASUNAME
1502 ## --------- ##
1503 ## Platform. ##
1504 ## --------- ##
1505
1506 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1507 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1508 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1509 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1510 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1511
1512 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1513 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1514
1515 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1516 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1517 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1518 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1519 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1520 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1521 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1522
1523 _ASUNAME
1524
1525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1526 for as_dir in $PATH
1527 do
1528   IFS=$as_save_IFS
1529   test -z "$as_dir" && as_dir=.
1530   echo "PATH: $as_dir"
1531 done
1532 IFS=$as_save_IFS
1533
1534 } >&5
1535
1536 cat >&5 <<_ACEOF
1537
1538
1539 ## ----------- ##
1540 ## Core tests. ##
1541 ## ----------- ##
1542
1543 _ACEOF
1544
1545
1546 # Keep a trace of the command line.
1547 # Strip out --no-create and --no-recursion so they do not pile up.
1548 # Strip out --silent because we don't want to record it for future runs.
1549 # Also quote any args containing shell meta-characters.
1550 # Make two passes to allow for proper duplicate-argument suppression.
1551 ac_configure_args=
1552 ac_configure_args0=
1553 ac_configure_args1=
1554 ac_must_keep_next=false
1555 for ac_pass in 1 2
1556 do
1557   for ac_arg
1558   do
1559     case $ac_arg in
1560     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1561     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1562     | -silent | --silent | --silen | --sile | --sil)
1563       continue ;;
1564     *\'*)
1565       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1566     esac
1567     case $ac_pass in
1568     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1569     2)
1570       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1571       if test $ac_must_keep_next = true; then
1572         ac_must_keep_next=false # Got value, back to normal.
1573       else
1574         case $ac_arg in
1575           *=* | --config-cache | -C | -disable-* | --disable-* \
1576           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1577           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1578           | -with-* | --with-* | -without-* | --without-* | --x)
1579             case "$ac_configure_args0 " in
1580               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1581             esac
1582             ;;
1583           -* ) ac_must_keep_next=true ;;
1584         esac
1585       fi
1586       ac_configure_args="$ac_configure_args '$ac_arg'"
1587       ;;
1588     esac
1589   done
1590 done
1591 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1592 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1593
1594 # When interrupted or exit'd, cleanup temporary files, and complete
1595 # config.log.  We remove comments because anyway the quotes in there
1596 # would cause problems or look ugly.
1597 # WARNING: Use '\'' to represent an apostrophe within the trap.
1598 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1599 trap 'exit_status=$?
1600   # Save into config.log some information that might help in debugging.
1601   {
1602     echo
1603
1604     cat <<\_ASBOX
1605 ## ---------------- ##
1606 ## Cache variables. ##
1607 ## ---------------- ##
1608 _ASBOX
1609     echo
1610     # The following way of writing the cache mishandles newlines in values,
1611 (
1612   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1613     eval ac_val=\$$ac_var
1614     case $ac_val in #(
1615     *${as_nl}*)
1616       case $ac_var in #(
1617       *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
1618 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
1619       esac
1620       case $ac_var in #(
1621       _ | IFS | as_nl) ;; #(
1622       *) $as_unset $ac_var ;;
1623       esac ;;
1624     esac
1625   done
1626   (set) 2>&1 |
1627     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1628     *${as_nl}ac_space=\ *)
1629       sed -n \
1630         "s/'\''/'\''\\\\'\'''\''/g;
1631           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1632       ;; #(
1633     *)
1634       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1635       ;;
1636     esac |
1637     sort
1638 )
1639     echo
1640
1641     cat <<\_ASBOX
1642 ## ----------------- ##
1643 ## Output variables. ##
1644 ## ----------------- ##
1645 _ASBOX
1646     echo
1647     for ac_var in $ac_subst_vars
1648     do
1649       eval ac_val=\$$ac_var
1650       case $ac_val in
1651       *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1652       esac
1653       echo "$ac_var='\''$ac_val'\''"
1654     done | sort
1655     echo
1656
1657     if test -n "$ac_subst_files"; then
1658       cat <<\_ASBOX
1659 ## ------------------- ##
1660 ## File substitutions. ##
1661 ## ------------------- ##
1662 _ASBOX
1663       echo
1664       for ac_var in $ac_subst_files
1665       do
1666         eval ac_val=\$$ac_var
1667         case $ac_val in
1668         *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1669         esac
1670         echo "$ac_var='\''$ac_val'\''"
1671       done | sort
1672       echo
1673     fi
1674
1675     if test -s confdefs.h; then
1676       cat <<\_ASBOX
1677 ## ----------- ##
1678 ## confdefs.h. ##
1679 ## ----------- ##
1680 _ASBOX
1681       echo
1682       cat confdefs.h
1683       echo
1684     fi
1685     test "$ac_signal" != 0 &&
1686       echo "$as_me: caught signal $ac_signal"
1687     echo "$as_me: exit $exit_status"
1688   } >&5
1689   rm -f core *.core core.conftest.* &&
1690     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1691     exit $exit_status
1692 ' 0
1693 for ac_signal in 1 2 13 15; do
1694   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1695 done
1696 ac_signal=0
1697
1698 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1699 rm -f -r conftest* confdefs.h
1700
1701 # Predefined preprocessor variables.
1702
1703 cat >>confdefs.h <<_ACEOF
1704 #define PACKAGE_NAME "$PACKAGE_NAME"
1705 _ACEOF
1706
1707
1708 cat >>confdefs.h <<_ACEOF
1709 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1710 _ACEOF
1711
1712
1713 cat >>confdefs.h <<_ACEOF
1714 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1715 _ACEOF
1716
1717
1718 cat >>confdefs.h <<_ACEOF
1719 #define PACKAGE_STRING "$PACKAGE_STRING"
1720 _ACEOF
1721
1722
1723 cat >>confdefs.h <<_ACEOF
1724 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1725 _ACEOF
1726
1727
1728 # Let the site file select an alternate cache file if it wants to.
1729 # Prefer explicitly selected file to automatically selected ones.
1730 if test -n "$CONFIG_SITE"; then
1731   set x "$CONFIG_SITE"
1732 elif test "x$prefix" != xNONE; then
1733   set x "$prefix/share/config.site" "$prefix/etc/config.site"
1734 else
1735   set x "$ac_default_prefix/share/config.site" \
1736         "$ac_default_prefix/etc/config.site"
1737 fi
1738 shift
1739 for ac_site_file
1740 do
1741   if test -r "$ac_site_file"; then
1742     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1743 echo "$as_me: loading site script $ac_site_file" >&6;}
1744     sed 's/^/| /' "$ac_site_file" >&5
1745     . "$ac_site_file"
1746   fi
1747 done
1748
1749 if test -r "$cache_file"; then
1750   # Some versions of bash will fail to source /dev/null (special
1751   # files actually), so we avoid doing that.
1752   if test -f "$cache_file"; then
1753     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1754 echo "$as_me: loading cache $cache_file" >&6;}
1755     case $cache_file in
1756       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1757       *)                      . "./$cache_file";;
1758     esac
1759   fi
1760 else
1761   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1762 echo "$as_me: creating cache $cache_file" >&6;}
1763   >$cache_file
1764 fi
1765
1766 # Check that the precious variables saved in the cache have kept the same
1767 # value.
1768 ac_cache_corrupted=false
1769 for ac_var in $ac_precious_vars; do
1770   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1771   eval ac_new_set=\$ac_env_${ac_var}_set
1772   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1773   eval ac_new_val=\$ac_env_${ac_var}_value
1774   case $ac_old_set,$ac_new_set in
1775     set,)
1776       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1777 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1778       ac_cache_corrupted=: ;;
1779     ,set)
1780       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1781 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1782       ac_cache_corrupted=: ;;
1783     ,);;
1784     *)
1785       if test "x$ac_old_val" != "x$ac_new_val"; then
1786         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1787 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1788         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1789 echo "$as_me:   former value:  $ac_old_val" >&2;}
1790         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1791 echo "$as_me:   current value: $ac_new_val" >&2;}
1792         ac_cache_corrupted=:
1793       fi;;
1794   esac
1795   # Pass precious variables to config.status.
1796   if test "$ac_new_set" = set; then
1797     case $ac_new_val in
1798     *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1799     *) ac_arg=$ac_var=$ac_new_val ;;
1800     esac
1801     case " $ac_configure_args " in
1802       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1803       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1804     esac
1805   fi
1806 done
1807 if $ac_cache_corrupted; then
1808   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1809 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1810   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1811 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1812    { (exit 1); exit 1; }; }
1813 fi
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839 ac_ext=c
1840 ac_cpp='$CPP $CPPFLAGS'
1841 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1842 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1843 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1844
1845
1846
1847
1848
1849
1850 ac_aux_dir=
1851 for ac_dir in config "$srcdir"/config; do
1852   if test -f "$ac_dir/install-sh"; then
1853     ac_aux_dir=$ac_dir
1854     ac_install_sh="$ac_aux_dir/install-sh -c"
1855     break
1856   elif test -f "$ac_dir/install.sh"; then
1857     ac_aux_dir=$ac_dir
1858     ac_install_sh="$ac_aux_dir/install.sh -c"
1859     break
1860   elif test -f "$ac_dir/shtool"; then
1861     ac_aux_dir=$ac_dir
1862     ac_install_sh="$ac_aux_dir/shtool install -c"
1863     break
1864   fi
1865 done
1866 if test -z "$ac_aux_dir"; then
1867   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
1868 echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
1869    { (exit 1); exit 1; }; }
1870 fi
1871
1872 # These three variables are undocumented and unsupported,
1873 # and are intended to be withdrawn in a future Autoconf release.
1874 # They can cause serious problems if a builder's source tree is in a directory
1875 # whose full name contains unusual characters.
1876 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
1877 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
1878 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
1879
1880
1881
1882 configure_args=$ac_configure_args
1883
1884
1885
1886 cat >>confdefs.h <<_ACEOF
1887 #define PG_VERSION "$PACKAGE_VERSION"
1888 _ACEOF
1889
1890
1891 # Make sure we can run config.sub.
1892 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
1893   { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
1894 echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
1895    { (exit 1); exit 1; }; }
1896
1897 { echo "$as_me:$LINENO: checking build system type" >&5
1898 echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
1899 if test "${ac_cv_build+set}" = set; then
1900   echo $ECHO_N "(cached) $ECHO_C" >&6
1901 else
1902   ac_build_alias=$build_alias
1903 test "x$ac_build_alias" = x &&
1904   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
1905 test "x$ac_build_alias" = x &&
1906   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1907 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1908    { (exit 1); exit 1; }; }
1909 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
1910   { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
1911 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
1912    { (exit 1); exit 1; }; }
1913
1914 fi
1915 { echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1916 echo "${ECHO_T}$ac_cv_build" >&6; }
1917 case $ac_cv_build in
1918 *-*-*) ;;
1919 *) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
1920 echo "$as_me: error: invalid value of canonical build" >&2;}
1921    { (exit 1); exit 1; }; };;
1922 esac
1923 build=$ac_cv_build
1924 ac_save_IFS=$IFS; IFS='-'
1925 set x $ac_cv_build
1926 shift
1927 build_cpu=$1
1928 build_vendor=$2
1929 shift; shift
1930 # Remember, the first character of IFS is used to create $*,
1931 # except with old shells:
1932 build_os=$*
1933 IFS=$ac_save_IFS
1934 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
1935
1936
1937 { echo "$as_me:$LINENO: checking host system type" >&5
1938 echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
1939 if test "${ac_cv_host+set}" = set; then
1940   echo $ECHO_N "(cached) $ECHO_C" >&6
1941 else
1942   if test "x$host_alias" = x; then
1943   ac_cv_host=$ac_cv_build
1944 else
1945   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
1946     { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
1947 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
1948    { (exit 1); exit 1; }; }
1949 fi
1950
1951 fi
1952 { echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1953 echo "${ECHO_T}$ac_cv_host" >&6; }
1954 case $ac_cv_host in
1955 *-*-*) ;;
1956 *) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
1957 echo "$as_me: error: invalid value of canonical host" >&2;}
1958    { (exit 1); exit 1; }; };;
1959 esac
1960 host=$ac_cv_host
1961 ac_save_IFS=$IFS; IFS='-'
1962 set x $ac_cv_host
1963 shift
1964 host_cpu=$1
1965 host_vendor=$2
1966 shift; shift
1967 # Remember, the first character of IFS is used to create $*,
1968 # except with old shells:
1969 host_os=$*
1970 IFS=$ac_save_IFS
1971 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
1972
1973
1974
1975 template=
1976 { echo "$as_me:$LINENO: checking which template to use" >&5
1977 echo $ECHO_N "checking which template to use... $ECHO_C" >&6; }
1978
1979
1980 pgac_args="$pgac_args with_template"
1981
1982
1983 # Check whether --with-template was given.
1984 if test "${with_template+set}" = set; then
1985   withval=$with_template;
1986   case $withval in
1987     yes)
1988       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1989 echo "$as_me: error: argument required for --with-template option" >&2;}
1990    { (exit 1); exit 1; }; }
1991       ;;
1992     no)
1993       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1994 echo "$as_me: error: argument required for --with-template option" >&2;}
1995    { (exit 1); exit 1; }; }
1996       ;;
1997     *)
1998
1999   case $withval in
2000     list)   echo; ls "$srcdir/src/template"; exit;;
2001     *)      if test -f "$srcdir/src/template/$with_template" ; then
2002               template=$withval
2003             else
2004               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2005 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2006    { (exit 1); exit 1; }; }
2007             fi;;
2008   esac
2009
2010       ;;
2011   esac
2012
2013 else
2014
2015 # --with-template not given
2016
2017 case $host_os in
2018      aix*) template=aix ;;
2019     bsdi*) template=bsdi ;;
2020   cygwin*) template=cygwin ;;
2021   darwin*) template=darwin ;;
2022     dgux*) template=dgux ;;
2023  freebsd*) template=freebsd ;;
2024     hpux*) template=hpux ;;
2025     irix*) template=irix ;;
2026  linux*|gnu*|k*bsd*-gnu)
2027            template=linux ;;
2028    mingw*) template=win32 ;;
2029   netbsd*) template=netbsd ;;
2030 nextstep*) template=nextstep ;;
2031  openbsd*) template=openbsd ;;
2032      osf*) template=osf ;;
2033      sco*) template=sco ;;
2034  solaris*) template=solaris ;;
2035    sunos*) template=sunos4 ;;
2036  sysv4.2*)
2037         case $host_vendor in
2038           univel) template=univel ;;
2039         esac ;;
2040    sysv4*) template=svr4 ;;
2041    sysv5*) template=unixware ;;
2042   ultrix*) template=ultrix4 ;;
2043 esac
2044
2045   if test x"$template" = x"" ; then
2046     { { echo "$as_me:$LINENO: error:
2047 *******************************************************************
2048 PostgreSQL has apparently not been ported to your platform yet.
2049 To try a manual configuration, look into the src/template directory
2050 for a similar platform and use the '--with-template=' option.
2051
2052 Please also contact <pgsql-ports@postgresql.org> to see about
2053 rectifying this.  Include the above 'checking host system type...'
2054 line.
2055 *******************************************************************
2056 " >&5
2057 echo "$as_me: error:
2058 *******************************************************************
2059 PostgreSQL has apparently not been ported to your platform yet.
2060 To try a manual configuration, look into the src/template directory
2061 for a similar platform and use the '--with-template=' option.
2062
2063 Please also contact <pgsql-ports@postgresql.org> to see about
2064 rectifying this.  Include the above 'checking host system type...'
2065 line.
2066 *******************************************************************
2067 " >&2;}
2068    { (exit 1); exit 1; }; }
2069   fi
2070
2071
2072 fi
2073
2074
2075
2076 { echo "$as_me:$LINENO: result: $template" >&5
2077 echo "${ECHO_T}$template" >&6; }
2078
2079 PORTNAME=$template
2080
2081
2082 # Initialize default assumption that we do not need separate assembly code
2083 # for TAS (test-and-set).  This can be overridden by the template file
2084 # when it's executed.
2085 need_tas=no
2086 tas_file=dummy.s
2087
2088
2089
2090 ##
2091 ## Command line options
2092 ##
2093
2094 #
2095 # Add non-standard directories to the include path
2096 #
2097
2098 pgac_args="$pgac_args with_includes"
2099
2100
2101 # Check whether --with-includes was given.
2102 if test "${with_includes+set}" = set; then
2103   withval=$with_includes;
2104   case $withval in
2105     yes)
2106       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2107 echo "$as_me: error: argument required for --with-includes option" >&2;}
2108    { (exit 1); exit 1; }; }
2109       ;;
2110     no)
2111       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2112 echo "$as_me: error: argument required for --with-includes option" >&2;}
2113    { (exit 1); exit 1; }; }
2114       ;;
2115     *)
2116
2117       ;;
2118   esac
2119
2120 fi
2121
2122
2123
2124
2125 #
2126 # Add non-standard directories to the library search path
2127 #
2128
2129 pgac_args="$pgac_args with_libraries"
2130
2131
2132 # Check whether --with-libraries was given.
2133 if test "${with_libraries+set}" = set; then
2134   withval=$with_libraries;
2135   case $withval in
2136     yes)
2137       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2138 echo "$as_me: error: argument required for --with-libraries option" >&2;}
2139    { (exit 1); exit 1; }; }
2140       ;;
2141     no)
2142       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2143 echo "$as_me: error: argument required for --with-libraries option" >&2;}
2144    { (exit 1); exit 1; }; }
2145       ;;
2146     *)
2147       LIBRARY_DIRS=$withval
2148       ;;
2149   esac
2150
2151 fi
2152
2153
2154
2155
2156 pgac_args="$pgac_args with_libs"
2157
2158
2159 # Check whether --with-libs was given.
2160 if test "${with_libs+set}" = set; then
2161   withval=$with_libs;
2162   case $withval in
2163     yes)
2164       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2165 echo "$as_me: error: argument required for --with-libs option" >&2;}
2166    { (exit 1); exit 1; }; }
2167       ;;
2168     no)
2169       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2170 echo "$as_me: error: argument required for --with-libs option" >&2;}
2171    { (exit 1); exit 1; }; }
2172       ;;
2173     *)
2174       LIBRARY_DIRS=$withval
2175       ;;
2176   esac
2177
2178 fi
2179
2180
2181
2182
2183 #
2184 # 64-bit integer date/time storage: enabled by default.
2185 #
2186 { echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2187 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6; }
2188
2189 pgac_args="$pgac_args enable_integer_datetimes"
2190
2191 # Check whether --enable-integer-datetimes was given.
2192 if test "${enable_integer_datetimes+set}" = set; then
2193   enableval=$enable_integer_datetimes;
2194   case $enableval in
2195     yes)
2196
2197 cat >>confdefs.h <<\_ACEOF
2198 #define USE_INTEGER_DATETIMES 1
2199 _ACEOF
2200
2201       ;;
2202     no)
2203       :
2204       ;;
2205     *)
2206       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2207 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2208    { (exit 1); exit 1; }; }
2209       ;;
2210   esac
2211
2212 else
2213   enable_integer_datetimes=yes
2214
2215 cat >>confdefs.h <<\_ACEOF
2216 #define USE_INTEGER_DATETIMES 1
2217 _ACEOF
2218
2219 fi
2220
2221
2222 { echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2223 echo "${ECHO_T}$enable_integer_datetimes" >&6; }
2224
2225
2226 #
2227 # NLS
2228 #
2229 { echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2230 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6; }
2231
2232 pgac_args="$pgac_args enable_nls"
2233
2234 # Check whether --enable-nls was given.
2235 if test "${enable_nls+set}" = set; then
2236   enableval=$enable_nls;
2237   case $enableval in
2238     yes)
2239       :
2240       ;;
2241     no)
2242       :
2243       ;;
2244     *)
2245       enable_nls=yes
2246 WANTED_LANGUAGES=$enableval
2247       ;;
2248   esac
2249
2250 else
2251   enable_nls=no
2252 fi
2253
2254
2255
2256 if test "$enable_nls" = yes; then
2257
2258 cat >>confdefs.h <<\_ACEOF
2259 #define ENABLE_NLS 1
2260 _ACEOF
2261
2262 fi
2263
2264 { echo "$as_me:$LINENO: result: $enable_nls" >&5
2265 echo "${ECHO_T}$enable_nls" >&6; }
2266
2267
2268
2269 #
2270 # Default port number (--with-pgport), default 5432
2271 #
2272 { echo "$as_me:$LINENO: checking for default port number" >&5
2273 echo $ECHO_N "checking for default port number... $ECHO_C" >&6; }
2274
2275 pgac_args="$pgac_args with_pgport"
2276
2277
2278 # Check whether --with-pgport was given.
2279 if test "${with_pgport+set}" = set; then
2280   withval=$with_pgport;
2281   case $withval in
2282     yes)
2283       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2284 echo "$as_me: error: argument required for --with-pgport option" >&2;}
2285    { (exit 1); exit 1; }; }
2286       ;;
2287     no)
2288       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2289 echo "$as_me: error: argument required for --with-pgport option" >&2;}
2290    { (exit 1); exit 1; }; }
2291       ;;
2292     *)
2293       default_port=$withval
2294       ;;
2295   esac
2296
2297 else
2298   default_port=5432
2299 fi
2300
2301
2302 { echo "$as_me:$LINENO: result: $default_port" >&5
2303 echo "${ECHO_T}$default_port" >&6; }
2304 # Need both of these because some places want an integer and some a string
2305
2306 cat >>confdefs.h <<_ACEOF
2307 #define DEF_PGPORT ${default_port}
2308 _ACEOF
2309
2310
2311 cat >>confdefs.h <<_ACEOF
2312 #define DEF_PGPORT_STR "${default_port}"
2313 _ACEOF
2314
2315
2316
2317 #
2318 # Option to disable shared libraries
2319 #
2320
2321 pgac_args="$pgac_args enable_shared"
2322
2323 # Check whether --enable-shared was given.
2324 if test "${enable_shared+set}" = set; then
2325   enableval=$enable_shared;
2326   case $enableval in
2327     yes)
2328       :
2329       ;;
2330     no)
2331       :
2332       ;;
2333     *)
2334       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2335 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2336    { (exit 1); exit 1; }; }
2337       ;;
2338   esac
2339
2340 else
2341   enable_shared=yes
2342
2343 fi
2344
2345
2346
2347
2348 #
2349 # '-rpath'-like feature can be disabled
2350 #
2351
2352 pgac_args="$pgac_args enable_rpath"
2353
2354 # Check whether --enable-rpath was given.
2355 if test "${enable_rpath+set}" = set; then
2356   enableval=$enable_rpath;
2357   case $enableval in
2358     yes)
2359       :
2360       ;;
2361     no)
2362       :
2363       ;;
2364     *)
2365       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2366 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2367    { (exit 1); exit 1; }; }
2368       ;;
2369   esac
2370
2371 else
2372   enable_rpath=yes
2373
2374 fi
2375
2376
2377
2378
2379 #
2380 # Spinlocks
2381 #
2382
2383 pgac_args="$pgac_args enable_spinlocks"
2384
2385 # Check whether --enable-spinlocks was given.
2386 if test "${enable_spinlocks+set}" = set; then
2387   enableval=$enable_spinlocks;
2388   case $enableval in
2389     yes)
2390       :
2391       ;;
2392     no)
2393       :
2394       ;;
2395     *)
2396       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2397 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2398    { (exit 1); exit 1; }; }
2399       ;;
2400   esac
2401
2402 else
2403   enable_spinlocks=yes
2404
2405 fi
2406
2407
2408
2409 #
2410 # --enable-debug adds -g to compiler flags
2411 #
2412
2413 pgac_args="$pgac_args enable_debug"
2414
2415 # Check whether --enable-debug was given.
2416 if test "${enable_debug+set}" = set; then
2417   enableval=$enable_debug;
2418   case $enableval in
2419     yes)
2420       :
2421       ;;
2422     no)
2423       :
2424       ;;
2425     *)
2426       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2427 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2428    { (exit 1); exit 1; }; }
2429       ;;
2430   esac
2431
2432 else
2433   enable_debug=no
2434
2435 fi
2436
2437
2438
2439
2440 #
2441 # --enable-profiling enables gcc profiling
2442 #
2443
2444 pgac_args="$pgac_args enable_profiling"
2445
2446 # Check whether --enable-profiling was given.
2447 if test "${enable_profiling+set}" = set; then
2448   enableval=$enable_profiling;
2449   case $enableval in
2450     yes)
2451       :
2452       ;;
2453     no)
2454       :
2455       ;;
2456     *)
2457       { { echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2458 echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2459    { (exit 1); exit 1; }; }
2460       ;;
2461   esac
2462
2463 else
2464   enable_profiling=no
2465
2466 fi
2467
2468
2469
2470
2471 #
2472 # DTrace
2473 #
2474
2475 pgac_args="$pgac_args enable_dtrace"
2476
2477 # Check whether --enable-dtrace was given.
2478 if test "${enable_dtrace+set}" = set; then
2479   enableval=$enable_dtrace;
2480   case $enableval in
2481     yes)
2482
2483 cat >>confdefs.h <<\_ACEOF
2484 #define ENABLE_DTRACE 1
2485 _ACEOF
2486
2487 for ac_prog in dtrace
2488 do
2489   # Extract the first word of "$ac_prog", so it can be a program name with args.
2490 set dummy $ac_prog; ac_word=$2
2491 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2492 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2493 if test "${ac_cv_prog_DTRACE+set}" = set; then
2494   echo $ECHO_N "(cached) $ECHO_C" >&6
2495 else
2496   if test -n "$DTRACE"; then
2497   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2498 else
2499 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2500 for as_dir in $PATH
2501 do
2502   IFS=$as_save_IFS
2503   test -z "$as_dir" && as_dir=.
2504   for ac_exec_ext in '' $ac_executable_extensions; do
2505   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2506     ac_cv_prog_DTRACE="$ac_prog"
2507     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2508     break 2
2509   fi
2510 done
2511 done
2512 IFS=$as_save_IFS
2513
2514 fi
2515 fi
2516 DTRACE=$ac_cv_prog_DTRACE
2517 if test -n "$DTRACE"; then
2518   { echo "$as_me:$LINENO: result: $DTRACE" >&5
2519 echo "${ECHO_T}$DTRACE" >&6; }
2520 else
2521   { echo "$as_me:$LINENO: result: no" >&5
2522 echo "${ECHO_T}no" >&6; }
2523 fi
2524
2525
2526   test -n "$DTRACE" && break
2527 done
2528
2529 if test -z "$DTRACE"; then
2530   { { echo "$as_me:$LINENO: error: dtrace not found" >&5
2531 echo "$as_me: error: dtrace not found" >&2;}
2532    { (exit 1); exit 1; }; }
2533 fi
2534
2535       ;;
2536     no)
2537       :
2538       ;;
2539     *)
2540       { { echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2541 echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2542    { (exit 1); exit 1; }; }
2543       ;;
2544   esac
2545
2546 else
2547   enable_dtrace=no
2548
2549 fi
2550
2551
2552
2553
2554 #
2555 # Block size
2556 #
2557 { echo "$as_me:$LINENO: checking for block size" >&5
2558 echo $ECHO_N "checking for block size... $ECHO_C" >&6; }
2559
2560 pgac_args="$pgac_args with_blocksize"
2561
2562
2563 # Check whether --with-blocksize was given.
2564 if test "${with_blocksize+set}" = set; then
2565   withval=$with_blocksize;
2566   case $withval in
2567     yes)
2568       { { echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2569 echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2570    { (exit 1); exit 1; }; }
2571       ;;
2572     no)
2573       { { echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2574 echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2575    { (exit 1); exit 1; }; }
2576       ;;
2577     *)
2578       blocksize=$withval
2579       ;;
2580   esac
2581
2582 else
2583   blocksize=8
2584 fi
2585
2586
2587 case ${blocksize} in
2588   1) BLCKSZ=1024;;
2589   2) BLCKSZ=2048;;
2590   4) BLCKSZ=4096;;
2591   8) BLCKSZ=8192;;
2592  16) BLCKSZ=16384;;
2593  32) BLCKSZ=32768;;
2594   *) { { echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2595 echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2596    { (exit 1); exit 1; }; }
2597 esac
2598 { echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2599 echo "${ECHO_T}${blocksize}kB" >&6; }
2600
2601
2602 cat >>confdefs.h <<_ACEOF
2603 #define BLCKSZ ${BLCKSZ}
2604 _ACEOF
2605
2606
2607 #
2608 # Relation segment size
2609 #
2610 { echo "$as_me:$LINENO: checking for segment size" >&5
2611 echo $ECHO_N "checking for segment size... $ECHO_C" >&6; }
2612
2613 pgac_args="$pgac_args with_segsize"
2614
2615
2616 # Check whether --with-segsize was given.
2617 if test "${with_segsize+set}" = set; then
2618   withval=$with_segsize;
2619   case $withval in
2620     yes)
2621       { { echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2622 echo "$as_me: error: argument required for --with-segsize option" >&2;}
2623    { (exit 1); exit 1; }; }
2624       ;;
2625     no)
2626       { { echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2627 echo "$as_me: error: argument required for --with-segsize option" >&2;}
2628    { (exit 1); exit 1; }; }
2629       ;;
2630     *)
2631       segsize=$withval
2632       ;;
2633   esac
2634
2635 else
2636   segsize=1
2637 fi
2638
2639
2640 # this expression is set up to avoid unnecessary integer overflow
2641 # blocksize is already guaranteed to be a factor of 1024
2642 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2643 test $? -eq 0 || exit 1
2644 { echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2645 echo "${ECHO_T}${segsize}GB" >&6; }
2646
2647
2648 cat >>confdefs.h <<_ACEOF
2649 #define RELSEG_SIZE ${RELSEG_SIZE}
2650 _ACEOF
2651
2652
2653 #
2654 # WAL block size
2655 #
2656 { echo "$as_me:$LINENO: checking for WAL block size" >&5
2657 echo $ECHO_N "checking for WAL block size... $ECHO_C" >&6; }
2658
2659 pgac_args="$pgac_args with_wal_blocksize"
2660
2661
2662 # Check whether --with-wal-blocksize was given.
2663 if test "${with_wal_blocksize+set}" = set; then
2664   withval=$with_wal_blocksize;
2665   case $withval in
2666     yes)
2667       { { echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2668 echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2669    { (exit 1); exit 1; }; }
2670       ;;
2671     no)
2672       { { echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2673 echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2674    { (exit 1); exit 1; }; }
2675       ;;
2676     *)
2677       wal_blocksize=$withval
2678       ;;
2679   esac
2680
2681 else
2682   wal_blocksize=8
2683 fi
2684
2685
2686 case ${wal_blocksize} in
2687   1) XLOG_BLCKSZ=1024;;
2688   2) XLOG_BLCKSZ=2048;;
2689   4) XLOG_BLCKSZ=4096;;
2690   8) XLOG_BLCKSZ=8192;;
2691  16) XLOG_BLCKSZ=16384;;
2692  32) XLOG_BLCKSZ=32768;;
2693  64) XLOG_BLCKSZ=65536;;
2694   *) { { echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
2695 echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
2696    { (exit 1); exit 1; }; }
2697 esac
2698 { echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
2699 echo "${ECHO_T}${wal_blocksize}kB" >&6; }
2700
2701
2702 cat >>confdefs.h <<_ACEOF
2703 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
2704 _ACEOF
2705
2706
2707 #
2708 # WAL segment size
2709 #
2710 { echo "$as_me:$LINENO: checking for WAL segment size" >&5
2711 echo $ECHO_N "checking for WAL segment size... $ECHO_C" >&6; }
2712
2713 pgac_args="$pgac_args with_wal_segsize"
2714
2715
2716 # Check whether --with-wal-segsize was given.
2717 if test "${with_wal_segsize+set}" = set; then
2718   withval=$with_wal_segsize;
2719   case $withval in
2720     yes)
2721       { { echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
2722 echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
2723    { (exit 1); exit 1; }; }
2724       ;;
2725     no)
2726       { { echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
2727 echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
2728    { (exit 1); exit 1; }; }
2729       ;;
2730     *)
2731       wal_segsize=$withval
2732       ;;
2733   esac
2734
2735 else
2736   wal_segsize=16
2737 fi
2738
2739
2740 case ${wal_segsize} in
2741   1) ;;
2742   2) ;;
2743   4) ;;
2744   8) ;;
2745  16) ;;
2746  32) ;;
2747  64) ;;
2748   *) { { echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
2749 echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
2750    { (exit 1); exit 1; }; }
2751 esac
2752 { echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
2753 echo "${ECHO_T}${wal_segsize}MB" >&6; }
2754
2755
2756 cat >>confdefs.h <<_ACEOF
2757 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
2758 _ACEOF
2759
2760
2761 #
2762 # C compiler
2763 #
2764
2765 # For historical reasons you can also use --with-CC to specify the C compiler
2766 # to use, although the standard way to do this is to set the CC environment
2767 # variable.
2768
2769 pgac_args="$pgac_args with_CC"
2770
2771
2772 # Check whether --with-CC was given.
2773 if test "${with_CC+set}" = set; then
2774   withval=$with_CC;
2775   case $withval in
2776     yes)
2777       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
2778 echo "$as_me: error: argument required for --with-CC option" >&2;}
2779    { (exit 1); exit 1; }; }
2780       ;;
2781     no)
2782       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
2783 echo "$as_me: error: argument required for --with-CC option" >&2;}
2784    { (exit 1); exit 1; }; }
2785       ;;
2786     *)
2787       CC=$with_CC
2788       ;;
2789   esac
2790
2791 fi
2792
2793
2794
2795 case $template in
2796   aix) pgac_cc_list="gcc xlc";;
2797  irix) pgac_cc_list="cc";; # no gcc
2798     *) pgac_cc_list="gcc cc";;
2799 esac
2800
2801 ac_ext=c
2802 ac_cpp='$CPP $CPPFLAGS'
2803 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2804 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2805 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2806 if test -n "$ac_tool_prefix"; then
2807   for ac_prog in $pgac_cc_list
2808   do
2809     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2810 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2811 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2812 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2813 if test "${ac_cv_prog_CC+set}" = set; then
2814   echo $ECHO_N "(cached) $ECHO_C" >&6
2815 else
2816   if test -n "$CC"; then
2817   ac_cv_prog_CC="$CC" # Let the user override the test.
2818 else
2819 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2820 for as_dir in $PATH
2821 do
2822   IFS=$as_save_IFS
2823   test -z "$as_dir" && as_dir=.
2824   for ac_exec_ext in '' $ac_executable_extensions; do
2825   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2826     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2827     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2828     break 2
2829   fi
2830 done
2831 done
2832 IFS=$as_save_IFS
2833
2834 fi
2835 fi
2836 CC=$ac_cv_prog_CC
2837 if test -n "$CC"; then
2838   { echo "$as_me:$LINENO: result: $CC" >&5
2839 echo "${ECHO_T}$CC" >&6; }
2840 else
2841   { echo "$as_me:$LINENO: result: no" >&5
2842 echo "${ECHO_T}no" >&6; }
2843 fi
2844
2845
2846     test -n "$CC" && break
2847   done
2848 fi
2849 if test -z "$CC"; then
2850   ac_ct_CC=$CC
2851   for ac_prog in $pgac_cc_list
2852 do
2853   # Extract the first word of "$ac_prog", so it can be a program name with args.
2854 set dummy $ac_prog; ac_word=$2
2855 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2856 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2857 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2858   echo $ECHO_N "(cached) $ECHO_C" >&6
2859 else
2860   if test -n "$ac_ct_CC"; then
2861   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2862 else
2863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2864 for as_dir in $PATH
2865 do
2866   IFS=$as_save_IFS
2867   test -z "$as_dir" && as_dir=.
2868   for ac_exec_ext in '' $ac_executable_extensions; do
2869   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2870     ac_cv_prog_ac_ct_CC="$ac_prog"
2871     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2872     break 2
2873   fi
2874 done
2875 done
2876 IFS=$as_save_IFS
2877
2878 fi
2879 fi
2880 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2881 if test -n "$ac_ct_CC"; then
2882   { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2883 echo "${ECHO_T}$ac_ct_CC" >&6; }
2884 else
2885   { echo "$as_me:$LINENO: result: no" >&5
2886 echo "${ECHO_T}no" >&6; }
2887 fi
2888
2889
2890   test -n "$ac_ct_CC" && break
2891 done
2892
2893   if test "x$ac_ct_CC" = x; then
2894     CC=""
2895   else
2896     case $cross_compiling:$ac_tool_warned in
2897 yes:)
2898 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
2899 whose name does not start with the host triplet.  If you think this
2900 configuration is useful to you, please write to autoconf@gnu.org." >&5
2901 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
2902 whose name does not start with the host triplet.  If you think this
2903 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
2904 ac_tool_warned=yes ;;
2905 esac
2906     CC=$ac_ct_CC
2907   fi
2908 fi
2909
2910
2911 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2912 See \`config.log' for more details." >&5
2913 echo "$as_me: error: no acceptable C compiler found in \$PATH
2914 See \`config.log' for more details." >&2;}
2915    { (exit 1); exit 1; }; }
2916
2917 # Provide some information about the compiler.
2918 echo "$as_me:$LINENO: checking for C compiler version" >&5
2919 ac_compiler=`set X $ac_compile; echo $2`
2920 { (ac_try="$ac_compiler --version >&5"
2921 case "(($ac_try" in
2922   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2923   *) ac_try_echo=$ac_try;;
2924 esac
2925 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2926   (eval "$ac_compiler --version >&5") 2>&5
2927   ac_status=$?
2928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2929   (exit $ac_status); }
2930 { (ac_try="$ac_compiler -v >&5"
2931 case "(($ac_try" in
2932   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2933   *) ac_try_echo=$ac_try;;
2934 esac
2935 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2936   (eval "$ac_compiler -v >&5") 2>&5
2937   ac_status=$?
2938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2939   (exit $ac_status); }
2940 { (ac_try="$ac_compiler -V >&5"
2941 case "(($ac_try" in
2942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2943   *) ac_try_echo=$ac_try;;
2944 esac
2945 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2946   (eval "$ac_compiler -V >&5") 2>&5
2947   ac_status=$?
2948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2949   (exit $ac_status); }
2950
2951 cat >conftest.$ac_ext <<_ACEOF
2952 /* confdefs.h.  */
2953 _ACEOF
2954 cat confdefs.h >>conftest.$ac_ext
2955 cat >>conftest.$ac_ext <<_ACEOF
2956 /* end confdefs.h.  */
2957
2958 int
2959 main ()
2960 {
2961
2962   ;
2963   return 0;
2964 }
2965 _ACEOF
2966 ac_clean_files_save=$ac_clean_files
2967 ac_clean_files="$ac_clean_files a.out a.exe b.out"
2968 # Try to create an executable without -o first, disregard a.out.
2969 # It will help us diagnose broken compilers, and finding out an intuition
2970 # of exeext.
2971 { echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2972 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
2973 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2974 #
2975 # List of possible output files, starting from the most likely.
2976 # The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
2977 # only as a last resort.  b.out is created by i960 compilers.
2978 ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
2979 #
2980 # The IRIX 6 linker writes into existing files which may not be
2981 # executable, retaining their permissions.  Remove them first so a
2982 # subsequent execution test works.
2983 ac_rmfiles=
2984 for ac_file in $ac_files
2985 do
2986   case $ac_file in
2987     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
2988     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2989   esac
2990 done
2991 rm -f $ac_rmfiles
2992
2993 if { (ac_try="$ac_link_default"
2994 case "(($ac_try" in
2995   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2996   *) ac_try_echo=$ac_try;;
2997 esac
2998 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2999   (eval "$ac_link_default") 2>&5
3000   ac_status=$?
3001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3002   (exit $ac_status); }; then
3003   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3004 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3005 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3006 # so that the user can short-circuit this test for compilers unknown to
3007 # Autoconf.
3008 for ac_file in $ac_files ''
3009 do
3010   test -f "$ac_file" || continue
3011   case $ac_file in
3012     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
3013         ;;
3014     [ab].out )
3015         # We found the default executable, but exeext='' is most
3016         # certainly right.
3017         break;;
3018     *.* )
3019         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3020         then :; else
3021            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3022         fi
3023         # We set ac_cv_exeext here because the later test for it is not
3024         # safe: cross compilers may not add the suffix if given an `-o'
3025         # argument, so we may need to know it at that point already.
3026         # Even if this section looks crufty: it has the advantage of
3027         # actually working.
3028         break;;
3029     * )
3030         break;;
3031   esac
3032 done
3033 test "$ac_cv_exeext" = no && ac_cv_exeext=
3034
3035 else
3036   ac_file=''
3037 fi
3038
3039 { echo "$as_me:$LINENO: result: $ac_file" >&5
3040 echo "${ECHO_T}$ac_file" >&6; }
3041 if test -z "$ac_file"; then
3042   echo "$as_me: failed program was:" >&5
3043 sed 's/^/| /' conftest.$ac_ext >&5
3044
3045 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
3046 See \`config.log' for more details." >&5
3047 echo "$as_me: error: C compiler cannot create executables
3048 See \`config.log' for more details." >&2;}
3049    { (exit 77); exit 77; }; }
3050 fi
3051
3052 ac_exeext=$ac_cv_exeext
3053
3054 # Check that the compiler produces executables we can run.  If not, either
3055 # the compiler is broken, or we cross compile.
3056 { echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3057 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
3058 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3059 # If not cross compiling, check that we can run a simple program.
3060 if test "$cross_compiling" != yes; then
3061   if { ac_try='./$ac_file'
3062   { (case "(($ac_try" in
3063   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3064   *) ac_try_echo=$ac_try;;
3065 esac
3066 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3067   (eval "$ac_try") 2>&5
3068   ac_status=$?
3069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3070   (exit $ac_status); }; }; then
3071     cross_compiling=no
3072   else
3073     if test "$cross_compiling" = maybe; then
3074         cross_compiling=yes
3075     else
3076         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
3077 If you meant to cross compile, use \`--host'.
3078 See \`config.log' for more details." >&5
3079 echo "$as_me: error: cannot run C compiled programs.
3080 If you meant to cross compile, use \`--host'.
3081 See \`config.log' for more details." >&2;}
3082    { (exit 1); exit 1; }; }
3083     fi
3084   fi
3085 fi
3086 { echo "$as_me:$LINENO: result: yes" >&5
3087 echo "${ECHO_T}yes" >&6; }
3088
3089 rm -f a.out a.exe conftest$ac_cv_exeext b.out
3090 ac_clean_files=$ac_clean_files_save
3091 # Check that the compiler produces executables we can run.  If not, either
3092 # the compiler is broken, or we cross compile.
3093 { echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3094 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
3095 { echo "$as_me:$LINENO: result: $cross_compiling" >&5
3096 echo "${ECHO_T}$cross_compiling" >&6; }
3097
3098 { echo "$as_me:$LINENO: checking for suffix of executables" >&5
3099 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
3100 if { (ac_try="$ac_link"
3101 case "(($ac_try" in
3102   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3103   *) ac_try_echo=$ac_try;;
3104 esac
3105 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3106   (eval "$ac_link") 2>&5
3107   ac_status=$?
3108   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3109   (exit $ac_status); }; then
3110   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3111 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3112 # work properly (i.e., refer to `conftest.exe'), while it won't with
3113 # `rm'.
3114 for ac_file in conftest.exe conftest conftest.*; do
3115   test -f "$ac_file" || continue
3116   case $ac_file in
3117     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
3118     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3119           break;;
3120     * ) break;;
3121   esac
3122 done
3123 else
3124   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3125 See \`config.log' for more details." >&5
3126 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3127 See \`config.log' for more details." >&2;}
3128    { (exit 1); exit 1; }; }
3129 fi
3130
3131 rm -f conftest$ac_cv_exeext
3132 { echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3133 echo "${ECHO_T}$ac_cv_exeext" >&6; }
3134
3135 rm -f conftest.$ac_ext
3136 EXEEXT=$ac_cv_exeext
3137 ac_exeext=$EXEEXT
3138 { echo "$as_me:$LINENO: checking for suffix of object files" >&5
3139 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
3140 if test "${ac_cv_objext+set}" = set; then
3141   echo $ECHO_N "(cached) $ECHO_C" >&6
3142 else
3143   cat >conftest.$ac_ext <<_ACEOF
3144 /* confdefs.h.  */
3145 _ACEOF
3146 cat confdefs.h >>conftest.$ac_ext
3147 cat >>conftest.$ac_ext <<_ACEOF
3148 /* end confdefs.h.  */
3149
3150 int
3151 main ()
3152 {
3153
3154   ;
3155   return 0;
3156 }
3157 _ACEOF
3158 rm -f conftest.o conftest.obj
3159 if { (ac_try="$ac_compile"
3160 case "(($ac_try" in
3161   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3162   *) ac_try_echo=$ac_try;;
3163 esac
3164 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3165   (eval "$ac_compile") 2>&5
3166   ac_status=$?
3167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3168   (exit $ac_status); }; then
3169   for ac_file in conftest.o conftest.obj conftest.*; do
3170   test -f "$ac_file" || continue;
3171   case $ac_file in
3172     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
3173     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3174        break;;
3175   esac
3176 done
3177 else
3178   echo "$as_me: failed program was:" >&5
3179 sed 's/^/| /' conftest.$ac_ext >&5
3180
3181 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3182 See \`config.log' for more details." >&5
3183 echo "$as_me: error: cannot compute suffix of object files: cannot compile
3184 See \`config.log' for more details." >&2;}
3185    { (exit 1); exit 1; }; }
3186 fi
3187
3188 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3189 fi
3190 { echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3191 echo "${ECHO_T}$ac_cv_objext" >&6; }
3192 OBJEXT=$ac_cv_objext
3193 ac_objext=$OBJEXT
3194 { echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3195 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
3196 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3197   echo $ECHO_N "(cached) $ECHO_C" >&6
3198 else
3199   cat >conftest.$ac_ext <<_ACEOF
3200 /* confdefs.h.  */
3201 _ACEOF
3202 cat confdefs.h >>conftest.$ac_ext
3203 cat >>conftest.$ac_ext <<_ACEOF
3204 /* end confdefs.h.  */
3205
3206 int
3207 main ()
3208 {
3209 #ifndef __GNUC__
3210        choke me
3211 #endif
3212
3213   ;
3214   return 0;
3215 }
3216 _ACEOF
3217 rm -f conftest.$ac_objext
3218 if { (ac_try="$ac_compile"
3219 case "(($ac_try" in
3220   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3221   *) ac_try_echo=$ac_try;;
3222 esac
3223 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3224   (eval "$ac_compile") 2>conftest.er1
3225   ac_status=$?
3226   grep -v '^ *+' conftest.er1 >conftest.err
3227   rm -f conftest.er1
3228   cat conftest.err >&5
3229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3230   (exit $ac_status); } && {
3231          test -z "$ac_c_werror_flag" ||
3232          test ! -s conftest.err
3233        } && test -s conftest.$ac_objext; then
3234   ac_compiler_gnu=yes
3235 else
3236   echo "$as_me: failed program was:" >&5
3237 sed 's/^/| /' conftest.$ac_ext >&5
3238
3239         ac_compiler_gnu=no
3240 fi
3241
3242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3243 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3244
3245 fi
3246 { echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3247 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
3248 GCC=`test $ac_compiler_gnu = yes && echo yes`
3249 ac_test_CFLAGS=${CFLAGS+set}
3250 ac_save_CFLAGS=$CFLAGS
3251 { echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3252 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
3253 if test "${ac_cv_prog_cc_g+set}" = set; then
3254   echo $ECHO_N "(cached) $ECHO_C" >&6
3255 else
3256   ac_save_c_werror_flag=$ac_c_werror_flag
3257    ac_c_werror_flag=yes
3258    ac_cv_prog_cc_g=no
3259    CFLAGS="-g"
3260    cat >conftest.$ac_ext <<_ACEOF
3261 /* confdefs.h.  */
3262 _ACEOF
3263 cat confdefs.h >>conftest.$ac_ext
3264 cat >>conftest.$ac_ext <<_ACEOF
3265 /* end confdefs.h.  */
3266
3267 int
3268 main ()
3269 {
3270
3271   ;
3272   return 0;
3273 }
3274 _ACEOF
3275 rm -f conftest.$ac_objext
3276 if { (ac_try="$ac_compile"
3277 case "(($ac_try" in
3278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3279   *) ac_try_echo=$ac_try;;
3280 esac
3281 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3282   (eval "$ac_compile") 2>conftest.er1
3283   ac_status=$?
3284   grep -v '^ *+' conftest.er1 >conftest.err
3285   rm -f conftest.er1
3286   cat conftest.err >&5
3287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3288   (exit $ac_status); } && {
3289          test -z "$ac_c_werror_flag" ||
3290          test ! -s conftest.err
3291        } && test -s conftest.$ac_objext; then
3292   ac_cv_prog_cc_g=yes
3293 else
3294   echo "$as_me: failed program was:" >&5
3295 sed 's/^/| /' conftest.$ac_ext >&5
3296
3297         CFLAGS=""
3298       cat >conftest.$ac_ext <<_ACEOF
3299 /* confdefs.h.  */
3300 _ACEOF
3301 cat confdefs.h >>conftest.$ac_ext
3302 cat >>conftest.$ac_ext <<_ACEOF
3303 /* end confdefs.h.  */
3304
3305 int
3306 main ()
3307 {
3308
3309   ;
3310   return 0;
3311 }
3312 _ACEOF
3313 rm -f conftest.$ac_objext
3314 if { (ac_try="$ac_compile"
3315 case "(($ac_try" in
3316   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3317   *) ac_try_echo=$ac_try;;
3318 esac
3319 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3320   (eval "$ac_compile") 2>conftest.er1
3321   ac_status=$?
3322   grep -v '^ *+' conftest.er1 >conftest.err
3323   rm -f conftest.er1
3324   cat conftest.err >&5
3325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3326   (exit $ac_status); } && {
3327          test -z "$ac_c_werror_flag" ||
3328          test ! -s conftest.err
3329        } && test -s conftest.$ac_objext; then
3330   :
3331 else
3332   echo "$as_me: failed program was:" >&5
3333 sed 's/^/| /' conftest.$ac_ext >&5
3334
3335         ac_c_werror_flag=$ac_save_c_werror_flag
3336          CFLAGS="-g"
3337          cat >conftest.$ac_ext <<_ACEOF
3338 /* confdefs.h.  */
3339 _ACEOF
3340 cat confdefs.h >>conftest.$ac_ext
3341 cat >>conftest.$ac_ext <<_ACEOF
3342 /* end confdefs.h.  */
3343
3344 int
3345 main ()
3346 {
3347
3348   ;
3349   return 0;
3350 }
3351 _ACEOF
3352 rm -f conftest.$ac_objext
3353 if { (ac_try="$ac_compile"
3354 case "(($ac_try" in
3355   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3356   *) ac_try_echo=$ac_try;;
3357 esac
3358 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3359   (eval "$ac_compile") 2>conftest.er1
3360   ac_status=$?
3361   grep -v '^ *+' conftest.er1 >conftest.err
3362   rm -f conftest.er1
3363   cat conftest.err >&5
3364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3365   (exit $ac_status); } && {
3366          test -z "$ac_c_werror_flag" ||
3367          test ! -s conftest.err
3368        } && test -s conftest.$ac_objext; then
3369   ac_cv_prog_cc_g=yes
3370 else
3371   echo "$as_me: failed program was:" >&5
3372 sed 's/^/| /' conftest.$ac_ext >&5
3373
3374
3375 fi
3376
3377 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3378 fi
3379
3380 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3381 fi
3382
3383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3384    ac_c_werror_flag=$ac_save_c_werror_flag
3385 fi
3386 { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3387 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
3388 if test "$ac_test_CFLAGS" = set; then
3389   CFLAGS=$ac_save_CFLAGS
3390 elif test $ac_cv_prog_cc_g = yes; then
3391   if test "$GCC" = yes; then
3392     CFLAGS="-g -O2"
3393   else
3394     CFLAGS="-g"
3395   fi
3396 else
3397   if test "$GCC" = yes; then
3398     CFLAGS="-O2"
3399   else
3400     CFLAGS=
3401   fi
3402 fi
3403 { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3404 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
3405 if test "${ac_cv_prog_cc_c89+set}" = set; then
3406   echo $ECHO_N "(cached) $ECHO_C" >&6
3407 else
3408   ac_cv_prog_cc_c89=no
3409 ac_save_CC=$CC
3410 cat >conftest.$ac_ext <<_ACEOF
3411 /* confdefs.h.  */
3412 _ACEOF
3413 cat confdefs.h >>conftest.$ac_ext
3414 cat >>conftest.$ac_ext <<_ACEOF
3415 /* end confdefs.h.  */
3416 #include <stdarg.h>
3417 #include <stdio.h>
3418 #include <sys/types.h>
3419 #include <sys/stat.h>
3420 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3421 struct buf { int x; };
3422 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3423 static char *e (p, i)
3424      char **p;
3425      int i;
3426 {
3427   return p[i];
3428 }
3429 static char *f (char * (*g) (char **, int), char **p, ...)
3430 {
3431   char *s;
3432   va_list v;
3433   va_start (v,p);
3434   s = g (p, va_arg (v,int));
3435   va_end (v);
3436   return s;
3437 }
3438
3439 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3440    function prototypes and stuff, but not '\xHH' hex character constants.
3441    These don't provoke an error unfortunately, instead are silently treated
3442    as 'x'.  The following induces an error, until -std is added to get
3443    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3444    array size at least.  It's necessary to write '\x00'==0 to get something
3445    that's true only with -std.  */
3446 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3447
3448 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3449    inside strings and character constants.  */
3450 #define FOO(x) 'x'
3451 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3452
3453 int test (int i, double x);
3454 struct s1 {int (*f) (int a);};
3455 struct s2 {int (*f) (double a);};
3456 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3457 int argc;
3458 char **argv;
3459 int
3460 main ()
3461 {
3462 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3463   ;
3464   return 0;
3465 }
3466 _ACEOF
3467 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3468         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3469 do
3470   CC="$ac_save_CC $ac_arg"
3471   rm -f conftest.$ac_objext
3472 if { (ac_try="$ac_compile"
3473 case "(($ac_try" in
3474   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3475   *) ac_try_echo=$ac_try;;
3476 esac
3477 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3478   (eval "$ac_compile") 2>conftest.er1
3479   ac_status=$?
3480   grep -v '^ *+' conftest.er1 >conftest.err
3481   rm -f conftest.er1
3482   cat conftest.err >&5
3483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3484   (exit $ac_status); } && {
3485          test -z "$ac_c_werror_flag" ||
3486          test ! -s conftest.err
3487        } && test -s conftest.$ac_objext; then
3488   ac_cv_prog_cc_c89=$ac_arg
3489 else
3490   echo "$as_me: failed program was:" >&5
3491 sed 's/^/| /' conftest.$ac_ext >&5
3492
3493
3494 fi
3495
3496 rm -f core conftest.err conftest.$ac_objext
3497   test "x$ac_cv_prog_cc_c89" != "xno" && break
3498 done
3499 rm -f conftest.$ac_ext
3500 CC=$ac_save_CC
3501
3502 fi
3503 # AC_CACHE_VAL
3504 case "x$ac_cv_prog_cc_c89" in
3505   x)
3506     { echo "$as_me:$LINENO: result: none needed" >&5
3507 echo "${ECHO_T}none needed" >&6; } ;;
3508   xno)
3509     { echo "$as_me:$LINENO: result: unsupported" >&5
3510 echo "${ECHO_T}unsupported" >&6; } ;;
3511   *)
3512     CC="$CC $ac_cv_prog_cc_c89"
3513     { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3514 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
3515 esac
3516
3517
3518 ac_ext=c
3519 ac_cpp='$CPP $CPPFLAGS'
3520 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3521 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3522 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3523
3524
3525 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3526 # but has idiosyncrasies of its own.  We assume icc will define
3527 # __INTEL_COMPILER regardless of CFLAGS.
3528
3529 cat >conftest.$ac_ext <<_ACEOF
3530 /* confdefs.h.  */
3531 _ACEOF
3532 cat confdefs.h >>conftest.$ac_ext
3533 cat >>conftest.$ac_ext <<_ACEOF
3534 /* end confdefs.h.  */
3535
3536 int
3537 main ()
3538 {
3539 #ifndef __INTEL_COMPILER
3540 choke me
3541 #endif
3542   ;
3543   return 0;
3544 }
3545 _ACEOF
3546 rm -f conftest.$ac_objext
3547 if { (ac_try="$ac_compile"
3548 case "(($ac_try" in
3549   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3550   *) ac_try_echo=$ac_try;;
3551 esac
3552 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3553   (eval "$ac_compile") 2>conftest.er1
3554   ac_status=$?
3555   grep -v '^ *+' conftest.er1 >conftest.err
3556   rm -f conftest.er1
3557   cat conftest.err >&5
3558   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3559   (exit $ac_status); } && {
3560          test -z "$ac_c_werror_flag" ||
3561          test ! -s conftest.err
3562        } && test -s conftest.$ac_objext; then
3563   ICC=yes
3564 else
3565   echo "$as_me: failed program was:" >&5
3566 sed 's/^/| /' conftest.$ac_ext >&5
3567
3568         ICC=no
3569 fi
3570
3571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3572
3573 unset CFLAGS
3574
3575 #
3576 # Read the template
3577 #
3578 . "$srcdir/src/template/$template" || exit
3579
3580 # CFLAGS are selected so:
3581 # If the user specifies something in the environment, that is used.
3582 # else:  If the template file set something, that is used.
3583 # else:  If the compiler is GCC, then we use -O2.
3584 # else:  If the compiler is something else, then we use -0.
3585
3586 if test "$ac_env_CFLAGS_set" = set; then
3587   CFLAGS=$ac_env_CFLAGS_value
3588 elif test "${CFLAGS+set}" = set; then
3589   : # (keep what template set)
3590 elif test "$GCC" = yes; then
3591   CFLAGS="-O2"
3592 else
3593   # if the user selected debug mode, don't use -O
3594   if test "$enable_debug" != yes; then
3595     CFLAGS="-O"
3596   fi
3597 fi
3598
3599 # Some versions of GCC support some additional useful warning flags.
3600 # Check whether they are supported, and add them to CFLAGS if so.
3601 # ICC pretends to be GCC but it's lying; it doesn't support these options.
3602
3603 if test "$GCC" = yes -a "$ICC" = no; then
3604   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
3605   # These work in some but not all gcc versions
3606   { echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
3607 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6; }
3608 pgac_save_CFLAGS=$CFLAGS
3609 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
3610 cat >conftest.$ac_ext <<_ACEOF
3611 /* confdefs.h.  */
3612 _ACEOF
3613 cat confdefs.h >>conftest.$ac_ext
3614 cat >>conftest.$ac_ext <<_ACEOF
3615 /* end confdefs.h.  */
3616
3617 int
3618 main ()
3619 {
3620
3621   ;
3622   return 0;
3623 }
3624 _ACEOF
3625 rm -f conftest.$ac_objext
3626 if { (ac_try="$ac_compile"
3627 case "(($ac_try" in
3628   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3629   *) ac_try_echo=$ac_try;;
3630 esac
3631 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3632   (eval "$ac_compile") 2>conftest.er1
3633   ac_status=$?
3634   grep -v '^ *+' conftest.er1 >conftest.err
3635   rm -f conftest.er1
3636   cat conftest.err >&5
3637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3638   (exit $ac_status); } && {
3639          test -z "$ac_c_werror_flag" ||
3640          test ! -s conftest.err
3641        } && test -s conftest.$ac_objext; then
3642   { echo "$as_me:$LINENO: result: yes" >&5
3643 echo "${ECHO_T}yes" >&6; }
3644 else
3645   echo "$as_me: failed program was:" >&5
3646 sed 's/^/| /' conftest.$ac_ext >&5
3647
3648         CFLAGS="$pgac_save_CFLAGS"
3649                     { echo "$as_me:$LINENO: result: no" >&5
3650 echo "${ECHO_T}no" >&6; }
3651 fi
3652
3653 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3654
3655   { echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
3656 echo $ECHO_N "checking if $CC supports -Wendif-labels... $ECHO_C" >&6; }
3657 pgac_save_CFLAGS=$CFLAGS
3658 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
3659 cat >conftest.$ac_ext <<_ACEOF
3660 /* confdefs.h.  */
3661 _ACEOF
3662 cat confdefs.h >>conftest.$ac_ext
3663 cat >>conftest.$ac_ext <<_ACEOF
3664 /* end confdefs.h.  */
3665
3666 int
3667 main ()
3668 {
3669
3670   ;
3671   return 0;
3672 }
3673 _ACEOF
3674 rm -f conftest.$ac_objext
3675 if { (ac_try="$ac_compile"
3676 case "(($ac_try" in
3677   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3678   *) ac_try_echo=$ac_try;;
3679 esac
3680 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3681   (eval "$ac_compile") 2>conftest.er1
3682   ac_status=$?
3683   grep -v '^ *+' conftest.er1 >conftest.err
3684   rm -f conftest.er1
3685   cat conftest.err >&5
3686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3687   (exit $ac_status); } && {
3688          test -z "$ac_c_werror_flag" ||
3689          test ! -s conftest.err
3690        } && test -s conftest.$ac_objext; then
3691   { echo "$as_me:$LINENO: result: yes" >&5
3692 echo "${ECHO_T}yes" >&6; }
3693 else
3694   echo "$as_me: failed program was:" >&5
3695 sed 's/^/| /' conftest.$ac_ext >&5
3696
3697         CFLAGS="$pgac_save_CFLAGS"
3698                     { echo "$as_me:$LINENO: result: no" >&5
3699 echo "${ECHO_T}no" >&6; }
3700 fi
3701
3702 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3703
3704   # Disable strict-aliasing rules; needed for gcc 3.3+
3705   { echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
3706 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6; }
3707 pgac_save_CFLAGS=$CFLAGS
3708 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
3709 cat >conftest.$ac_ext <<_ACEOF
3710 /* confdefs.h.  */
3711 _ACEOF
3712 cat confdefs.h >>conftest.$ac_ext
3713 cat >>conftest.$ac_ext <<_ACEOF
3714 /* end confdefs.h.  */
3715
3716 int
3717 main ()
3718 {
3719
3720   ;
3721   return 0;
3722 }
3723 _ACEOF
3724 rm -f conftest.$ac_objext
3725 if { (ac_try="$ac_compile"
3726 case "(($ac_try" in
3727   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3728   *) ac_try_echo=$ac_try;;
3729 esac
3730 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3731   (eval "$ac_compile") 2>conftest.er1
3732   ac_status=$?
3733   grep -v '^ *+' conftest.er1 >conftest.err
3734   rm -f conftest.er1
3735   cat conftest.err >&5
3736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3737   (exit $ac_status); } && {
3738          test -z "$ac_c_werror_flag" ||
3739          test ! -s conftest.err
3740        } && test -s conftest.$ac_objext; then
3741   { echo "$as_me:$LINENO: result: yes" >&5
3742 echo "${ECHO_T}yes" >&6; }
3743 else
3744   echo "$as_me: failed program was:" >&5
3745 sed 's/^/| /' conftest.$ac_ext >&5
3746
3747         CFLAGS="$pgac_save_CFLAGS"
3748                     { echo "$as_me:$LINENO: result: no" >&5
3749 echo "${ECHO_T}no" >&6; }
3750 fi
3751
3752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3753
3754   # Disable optimizations that assume no overflow; needed for gcc 4.3+
3755   { echo "$as_me:$LINENO: checking if $CC supports -fwrapv" >&5
3756 echo $ECHO_N "checking if $CC supports -fwrapv... $ECHO_C" >&6; }
3757 pgac_save_CFLAGS=$CFLAGS
3758 CFLAGS="$pgac_save_CFLAGS -fwrapv"
3759 cat >conftest.$ac_ext <<_ACEOF
3760 /* confdefs.h.  */
3761 _ACEOF
3762 cat confdefs.h >>conftest.$ac_ext
3763 cat >>conftest.$ac_ext <<_ACEOF
3764 /* end confdefs.h.  */
3765
3766 int
3767 main ()
3768 {
3769
3770   ;
3771   return 0;
3772 }
3773 _ACEOF
3774 rm -f conftest.$ac_objext
3775 if { (ac_try="$ac_compile"
3776 case "(($ac_try" in
3777   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3778   *) ac_try_echo=$ac_try;;
3779 esac
3780 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3781   (eval "$ac_compile") 2>conftest.er1
3782   ac_status=$?
3783   grep -v '^ *+' conftest.er1 >conftest.err
3784   rm -f conftest.er1
3785   cat conftest.err >&5
3786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3787   (exit $ac_status); } && {
3788          test -z "$ac_c_werror_flag" ||
3789          test ! -s conftest.err
3790        } && test -s conftest.$ac_objext; then
3791   { echo "$as_me:$LINENO: result: yes" >&5
3792 echo "${ECHO_T}yes" >&6; }
3793 else
3794   echo "$as_me: failed program was:" >&5
3795 sed 's/^/| /' conftest.$ac_ext >&5
3796
3797         CFLAGS="$pgac_save_CFLAGS"
3798                     { echo "$as_me:$LINENO: result: no" >&5
3799 echo "${ECHO_T}no" >&6; }
3800 fi
3801
3802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3803
3804 elif test "$ICC" = yes; then
3805   # Intel's compiler has a bug/misoptimization in checking for
3806   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
3807   { echo "$as_me:$LINENO: checking if $CC supports -mp1" >&5
3808 echo $ECHO_N "checking if $CC supports -mp1... $ECHO_C" >&6; }
3809 pgac_save_CFLAGS=$CFLAGS
3810 CFLAGS="$pgac_save_CFLAGS -mp1"
3811 cat >conftest.$ac_ext <<_ACEOF
3812 /* confdefs.h.  */
3813 _ACEOF
3814 cat confdefs.h >>conftest.$ac_ext
3815 cat >>conftest.$ac_ext <<_ACEOF
3816 /* end confdefs.h.  */
3817
3818 int
3819 main ()
3820 {
3821
3822   ;
3823   return 0;
3824 }
3825 _ACEOF
3826 rm -f conftest.$ac_objext
3827 if { (ac_try="$ac_compile"
3828 case "(($ac_try" in
3829   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3830   *) ac_try_echo=$ac_try;;
3831 esac
3832 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3833   (eval "$ac_compile") 2>conftest.er1
3834   ac_status=$?
3835   grep -v '^ *+' conftest.er1 >conftest.err
3836   rm -f conftest.er1
3837   cat conftest.err >&5
3838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3839   (exit $ac_status); } && {
3840          test -z "$ac_c_werror_flag" ||
3841          test ! -s conftest.err
3842        } && test -s conftest.$ac_objext; then
3843   { echo "$as_me:$LINENO: result: yes" >&5
3844 echo "${ECHO_T}yes" >&6; }
3845 else
3846   echo "$as_me: failed program was:" >&5
3847 sed 's/^/| /' conftest.$ac_ext >&5
3848
3849         CFLAGS="$pgac_save_CFLAGS"
3850                     { echo "$as_me:$LINENO: result: no" >&5
3851 echo "${ECHO_T}no" >&6; }
3852 fi
3853
3854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3855
3856   # Make sure strict aliasing is off (though this is said to be the default)
3857   { echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
3858 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6; }
3859 pgac_save_CFLAGS=$CFLAGS
3860 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
3861 cat >conftest.$ac_ext <<_ACEOF
3862 /* confdefs.h.  */
3863 _ACEOF
3864 cat confdefs.h >>conftest.$ac_ext
3865 cat >>conftest.$ac_ext <<_ACEOF
3866 /* end confdefs.h.  */
3867
3868 int
3869 main ()
3870 {
3871
3872   ;
3873   return 0;
3874 }
3875 _ACEOF
3876 rm -f conftest.$ac_objext
3877 if { (ac_try="$ac_compile"
3878 case "(($ac_try" in
3879   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3880   *) ac_try_echo=$ac_try;;
3881 esac
3882 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3883   (eval "$ac_compile") 2>conftest.er1
3884   ac_status=$?
3885   grep -v '^ *+' conftest.er1 >conftest.err
3886   rm -f conftest.er1
3887   cat conftest.err >&5
3888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3889   (exit $ac_status); } && {
3890          test -z "$ac_c_werror_flag" ||
3891          test ! -s conftest.err
3892        } && test -s conftest.$ac_objext; then
3893   { echo "$as_me:$LINENO: result: yes" >&5
3894 echo "${ECHO_T}yes" >&6; }
3895 else
3896   echo "$as_me: failed program was:" >&5
3897 sed 's/^/| /' conftest.$ac_ext >&5
3898
3899         CFLAGS="$pgac_save_CFLAGS"
3900                     { echo "$as_me:$LINENO: result: no" >&5
3901 echo "${ECHO_T}no" >&6; }
3902 fi
3903
3904 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3905
3906 elif test x"${CC}" = x"xlc"; then
3907   # AIX xlc has to have strict aliasing turned off too
3908   { echo "$as_me:$LINENO: checking if $CC supports -qnoansialias" >&5
3909 echo $ECHO_N "checking if $CC supports -qnoansialias... $ECHO_C" >&6; }
3910 pgac_save_CFLAGS=$CFLAGS
3911 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
3912 cat >conftest.$ac_ext <<_ACEOF
3913 /* confdefs.h.  */
3914 _ACEOF
3915 cat confdefs.h >>conftest.$ac_ext
3916 cat >>conftest.$ac_ext <<_ACEOF
3917 /* end confdefs.h.  */
3918
3919 int
3920 main ()
3921 {
3922
3923   ;
3924   return 0;
3925 }
3926 _ACEOF
3927 rm -f conftest.$ac_objext
3928 if { (ac_try="$ac_compile"
3929 case "(($ac_try" in
3930   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3931   *) ac_try_echo=$ac_try;;
3932 esac
3933 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3934   (eval "$ac_compile") 2>conftest.er1
3935   ac_status=$?
3936   grep -v '^ *+' conftest.er1 >conftest.err
3937   rm -f conftest.er1
3938   cat conftest.err >&5
3939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3940   (exit $ac_status); } && {
3941          test -z "$ac_c_werror_flag" ||
3942          test ! -s conftest.err
3943        } && test -s conftest.$ac_objext; then
3944   { echo "$as_me:$LINENO: result: yes" >&5
3945 echo "${ECHO_T}yes" >&6; }
3946 else
3947   echo "$as_me: failed program was:" >&5
3948 sed 's/^/| /' conftest.$ac_ext >&5
3949
3950         CFLAGS="$pgac_save_CFLAGS"
3951                     { echo "$as_me:$LINENO: result: no" >&5
3952 echo "${ECHO_T}no" >&6; }
3953 fi
3954
3955 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3956
3957 fi
3958
3959 # supply -g if --enable-debug
3960 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
3961   CFLAGS="$CFLAGS -g"
3962 fi
3963
3964 # enable profiling if --enable-profiling
3965 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
3966   if test "$GCC" = yes; then
3967
3968 cat >>confdefs.h <<\_ACEOF
3969 #define PROFILE_PID_DIR 1
3970 _ACEOF
3971
3972     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
3973   else
3974     { { echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
3975 echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
3976    { (exit 1); exit 1; }; }
3977   fi
3978 fi
3979
3980 # We already have this in Makefile.win32, but configure needs it too
3981 if test "$PORTNAME" = "win32"; then
3982   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
3983 fi
3984
3985 # Check if the compiler still works with the template settings
3986 { echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
3987 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6; }
3988 cat >conftest.$ac_ext <<_ACEOF
3989 /* confdefs.h.  */
3990 _ACEOF
3991 cat confdefs.h >>conftest.$ac_ext
3992 cat >>conftest.$ac_ext <<_ACEOF
3993 /* end confdefs.h.  */
3994
3995 int
3996 main ()
3997 {
3998 return 0;
3999   ;
4000   return 0;
4001 }
4002 _ACEOF
4003 rm -f conftest.$ac_objext conftest$ac_exeext
4004 if { (ac_try="$ac_link"
4005 case "(($ac_try" in
4006   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4007   *) ac_try_echo=$ac_try;;
4008 esac
4009 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4010   (eval "$ac_link") 2>conftest.er1
4011   ac_status=$?
4012   grep -v '^ *+' conftest.er1 >conftest.err
4013   rm -f conftest.er1
4014   cat conftest.err >&5
4015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4016   (exit $ac_status); } && {
4017          test -z "$ac_c_werror_flag" ||
4018          test ! -s conftest.err
4019        } && test -s conftest$ac_exeext &&
4020        $as_test_x conftest$ac_exeext; then
4021   { echo "$as_me:$LINENO: result: yes" >&5
4022 echo "${ECHO_T}yes" >&6; }
4023 else
4024   echo "$as_me: failed program was:" >&5
4025 sed 's/^/| /' conftest.$ac_ext >&5
4026
4027         { echo "$as_me:$LINENO: result: no" >&5
4028 echo "${ECHO_T}no" >&6; }
4029    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
4030 echo "$as_me: error: cannot proceed" >&2;}
4031    { (exit 1); exit 1; }; }
4032 fi
4033
4034 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4035       conftest$ac_exeext conftest.$ac_ext
4036
4037 # Defend against gcc -ffast-math
4038 if test "$GCC" = yes; then
4039 cat >conftest.$ac_ext <<_ACEOF
4040 /* confdefs.h.  */
4041 _ACEOF
4042 cat confdefs.h >>conftest.$ac_ext
4043 cat >>conftest.$ac_ext <<_ACEOF
4044 /* end confdefs.h.  */
4045
4046 int
4047 main ()
4048 {
4049 #ifdef __FAST_MATH__
4050 choke me
4051 #endif
4052   ;
4053   return 0;
4054 }
4055 _ACEOF
4056 rm -f conftest.$ac_objext
4057 if { (ac_try="$ac_compile"
4058 case "(($ac_try" in
4059   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4060   *) ac_try_echo=$ac_try;;
4061 esac
4062 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4063   (eval "$ac_compile") 2>conftest.er1
4064   ac_status=$?
4065   grep -v '^ *+' conftest.er1 >conftest.err
4066   rm -f conftest.er1
4067   cat conftest.err >&5
4068   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4069   (exit $ac_status); } && {
4070          test -z "$ac_c_werror_flag" ||
4071          test ! -s conftest.err
4072        } && test -s conftest.$ac_objext; then
4073   :
4074 else
4075   echo "$as_me: failed program was:" >&5
4076 sed 's/^/| /' conftest.$ac_ext >&5
4077
4078         { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4079 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4080    { (exit 1); exit 1; }; }
4081 fi
4082
4083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4084 fi
4085
4086 ac_ext=c
4087 ac_cpp='$CPP $CPPFLAGS'
4088 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4089 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4090 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4091 { echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4092 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
4093 # On Suns, sometimes $CPP names a directory.
4094 if test -n "$CPP" && test -d "$CPP"; then
4095   CPP=
4096 fi
4097 if test -z "$CPP"; then
4098   if test "${ac_cv_prog_CPP+set}" = set; then
4099   echo $ECHO_N "(cached) $ECHO_C" >&6
4100 else
4101       # Double quotes because CPP needs to be expanded
4102     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4103     do
4104       ac_preproc_ok=false
4105 for ac_c_preproc_warn_flag in '' yes
4106 do
4107   # Use a header file that comes with gcc, so configuring glibc
4108   # with a fresh cross-compiler works.
4109   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4110   # <limits.h> exists even on freestanding compilers.
4111   # On the NeXT, cc -E runs the code through the compiler's parser,
4112   # not just through cpp. "Syntax error" is here to catch this case.
4113   cat >conftest.$ac_ext <<_ACEOF
4114 /* confdefs.h.  */
4115 _ACEOF
4116 cat confdefs.h >>conftest.$ac_ext
4117 cat >>conftest.$ac_ext <<_ACEOF
4118 /* end confdefs.h.  */
4119 #ifdef __STDC__
4120 # include <limits.h>
4121 #else
4122 # include <assert.h>
4123 #endif
4124                      Syntax error
4125 _ACEOF
4126 if { (ac_try="$ac_cpp conftest.$ac_ext"
4127 case "(($ac_try" in
4128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4129   *) ac_try_echo=$ac_try;;
4130 esac
4131 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4132   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4133   ac_status=$?
4134   grep -v '^ *+' conftest.er1 >conftest.err
4135   rm -f conftest.er1
4136   cat conftest.err >&5
4137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4138   (exit $ac_status); } >/dev/null && {
4139          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4140          test ! -s conftest.err
4141        }; then
4142   :
4143 else
4144   echo "$as_me: failed program was:" >&5
4145 sed 's/^/| /' conftest.$ac_ext >&5
4146
4147   # Broken: fails on valid input.
4148 continue
4149 fi
4150
4151 rm -f conftest.err conftest.$ac_ext
4152
4153   # OK, works on sane cases.  Now check whether nonexistent headers
4154   # can be detected and how.
4155   cat >conftest.$ac_ext <<_ACEOF
4156 /* confdefs.h.  */
4157 _ACEOF
4158 cat confdefs.h >>conftest.$ac_ext
4159 cat >>conftest.$ac_ext <<_ACEOF
4160 /* end confdefs.h.  */
4161 #include <ac_nonexistent.h>
4162 _ACEOF
4163 if { (ac_try="$ac_cpp conftest.$ac_ext"
4164 case "(($ac_try" in
4165   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4166   *) ac_try_echo=$ac_try;;
4167 esac
4168 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4169   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4170   ac_status=$?
4171   grep -v '^ *+' conftest.er1 >conftest.err
4172   rm -f conftest.er1
4173   cat conftest.err >&5
4174   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4175   (exit $ac_status); } >/dev/null && {
4176          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4177          test ! -s conftest.err
4178        }; then
4179   # Broken: success on invalid input.
4180 continue
4181 else
4182   echo "$as_me: failed program was:" >&5
4183 sed 's/^/| /' conftest.$ac_ext >&5
4184
4185   # Passes both tests.
4186 ac_preproc_ok=:
4187 break
4188 fi
4189
4190 rm -f conftest.err conftest.$ac_ext
4191
4192 done
4193 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4194 rm -f conftest.err conftest.$ac_ext
4195 if $ac_preproc_ok; then
4196   break
4197 fi
4198
4199     done
4200     ac_cv_prog_CPP=$CPP
4201
4202 fi
4203   CPP=$ac_cv_prog_CPP
4204 else
4205   ac_cv_prog_CPP=$CPP
4206 fi
4207 { echo "$as_me:$LINENO: result: $CPP" >&5
4208 echo "${ECHO_T}$CPP" >&6; }
4209 ac_preproc_ok=false
4210 for ac_c_preproc_warn_flag in '' yes
4211 do
4212   # Use a header file that comes with gcc, so configuring glibc
4213   # with a fresh cross-compiler works.
4214   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4215   # <limits.h> exists even on freestanding compilers.
4216   # On the NeXT, cc -E runs the code through the compiler's parser,
4217   # not just through cpp. "Syntax error" is here to catch this case.
4218   cat >conftest.$ac_ext <<_ACEOF
4219 /* confdefs.h.  */
4220 _ACEOF
4221 cat confdefs.h >>conftest.$ac_ext
4222 cat >>conftest.$ac_ext <<_ACEOF
4223 /* end confdefs.h.  */
4224 #ifdef __STDC__
4225 # include <limits.h>
4226 #else
4227 # include <assert.h>
4228 #endif
4229                      Syntax error
4230 _ACEOF
4231 if { (ac_try="$ac_cpp conftest.$ac_ext"
4232 case "(($ac_try" in
4233   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4234   *) ac_try_echo=$ac_try;;
4235 esac
4236 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4237   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4238   ac_status=$?
4239   grep -v '^ *+' conftest.er1 >conftest.err
4240   rm -f conftest.er1
4241   cat conftest.err >&5
4242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4243   (exit $ac_status); } >/dev/null && {
4244          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4245          test ! -s conftest.err
4246        }; then
4247   :
4248 else
4249   echo "$as_me: failed program was:" >&5
4250 sed 's/^/| /' conftest.$ac_ext >&5
4251
4252   # Broken: fails on valid input.
4253 continue
4254 fi
4255
4256 rm -f conftest.err conftest.$ac_ext
4257
4258   # OK, works on sane cases.  Now check whether nonexistent headers
4259   # can be detected and how.
4260   cat >conftest.$ac_ext <<_ACEOF
4261 /* confdefs.h.  */
4262 _ACEOF
4263 cat confdefs.h >>conftest.$ac_ext
4264 cat >>conftest.$ac_ext <<_ACEOF
4265 /* end confdefs.h.  */
4266 #include <ac_nonexistent.h>
4267 _ACEOF
4268 if { (ac_try="$ac_cpp conftest.$ac_ext"
4269 case "(($ac_try" in
4270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4271   *) ac_try_echo=$ac_try;;
4272 esac
4273 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4274   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4275   ac_status=$?
4276   grep -v '^ *+' conftest.er1 >conftest.err
4277   rm -f conftest.er1
4278   cat conftest.err >&5
4279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4280   (exit $ac_status); } >/dev/null && {
4281          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4282          test ! -s conftest.err
4283        }; then
4284   # Broken: success on invalid input.
4285 continue
4286 else
4287   echo "$as_me: failed program was:" >&5
4288 sed 's/^/| /' conftest.$ac_ext >&5
4289
4290   # Passes both tests.
4291 ac_preproc_ok=:
4292 break
4293 fi
4294
4295 rm -f conftest.err conftest.$ac_ext
4296
4297 done
4298 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4299 rm -f conftest.err conftest.$ac_ext
4300 if $ac_preproc_ok; then
4301   :
4302 else
4303   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4304 See \`config.log' for more details." >&5
4305 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4306 See \`config.log' for more details." >&2;}
4307    { (exit 1); exit 1; }; }
4308 fi
4309
4310 ac_ext=c
4311 ac_cpp='$CPP $CPPFLAGS'
4312 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4313 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4314 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4315
4316
4317
4318 # Create compiler version string
4319 if test x"$GCC" = x"yes" ; then
4320   cc_string="GCC `${CC} --version | sed q`"
4321 else
4322   cc_string=$CC
4323 fi
4324
4325 cat >>confdefs.h <<_ACEOF
4326 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
4327 _ACEOF
4328
4329
4330
4331 #
4332 # Set up TAS assembly code if needed; the template file has now had its
4333 # chance to request this.
4334 #
4335 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4336
4337
4338 if test "$need_tas" = yes ; then
4339   TAS=tas.o
4340 else
4341   TAS=""
4342 fi
4343
4344
4345
4346 #
4347 # Automatic dependency tracking
4348 #
4349
4350 pgac_args="$pgac_args enable_depend"
4351
4352 # Check whether --enable-depend was given.
4353 if test "${enable_depend+set}" = set; then
4354   enableval=$enable_depend;
4355   case $enableval in
4356     yes)
4357       autodepend=yes
4358       ;;
4359     no)
4360       :
4361       ;;
4362     *)
4363       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4364 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4365    { (exit 1); exit 1; }; }
4366       ;;
4367   esac
4368
4369 else
4370   enable_depend=no
4371
4372 fi
4373
4374
4375
4376
4377
4378 #
4379 # Enable assert checks
4380 #
4381
4382 pgac_args="$pgac_args enable_cassert"
4383
4384 # Check whether --enable-cassert was given.
4385 if test "${enable_cassert+set}" = set; then
4386   enableval=$enable_cassert;
4387   case $enableval in
4388     yes)
4389
4390 cat >>confdefs.h <<\_ACEOF
4391 #define USE_ASSERT_CHECKING 1
4392 _ACEOF
4393
4394       ;;
4395     no)
4396       :
4397       ;;
4398     *)
4399       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4400 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4401    { (exit 1); exit 1; }; }
4402       ;;
4403   esac
4404
4405 else
4406   enable_cassert=no
4407
4408 fi
4409
4410
4411
4412
4413 #
4414 # Include directories
4415 #
4416 ac_save_IFS=$IFS
4417 IFS="${IFS}${PATH_SEPARATOR}"
4418 # SRCH_INC comes from the template file
4419 for dir in $with_includes $SRCH_INC; do
4420   if test -d "$dir"; then
4421     INCLUDES="$INCLUDES -I$dir"
4422   else
4423     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4424 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4425   fi
4426 done
4427 IFS=$ac_save_IFS
4428
4429
4430
4431 #
4432 # Library directories
4433 #
4434 ac_save_IFS=$IFS
4435 IFS="${IFS}${PATH_SEPARATOR}"
4436 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4437 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4438   if test -d "$dir"; then
4439     LIBDIRS="$LIBDIRS -L$dir"
4440   else
4441     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4442 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4443   fi
4444 done
4445 IFS=$ac_save_IFS
4446
4447 #
4448 # Enable thread-safe client libraries
4449 #
4450 { echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4451 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6; }
4452 if test "$PORTNAME" != "win32"; then
4453
4454 pgac_args="$pgac_args enable_thread_safety"
4455
4456 # Check whether --enable-thread-safety was given.
4457 if test "${enable_thread_safety+set}" = set; then
4458   enableval=$enable_thread_safety;
4459   case $enableval in
4460     yes)
4461       :
4462       ;;
4463     no)
4464       :
4465       ;;
4466     *)
4467       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4468 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4469    { (exit 1); exit 1; }; }
4470       ;;
4471   esac
4472
4473 else
4474   enable_thread_safety=no
4475
4476 fi
4477
4478
4479 else
4480 # Win32 should always use threads
4481
4482 pgac_args="$pgac_args enable_thread_safety"
4483
4484 # Check whether --enable-thread-safety was given.
4485 if test "${enable_thread_safety+set}" = set; then
4486   enableval=$enable_thread_safety;
4487   case $enableval in
4488     yes)
4489       :
4490       ;;
4491     no)
4492       :
4493       ;;
4494     *)
4495       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4496 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4497    { (exit 1); exit 1; }; }
4498       ;;
4499   esac
4500
4501 else
4502   enable_thread_safety=yes
4503
4504 fi
4505
4506
4507 fi
4508
4509
4510 pgac_args="$pgac_args enable_thread_safety_force"
4511
4512 # Check whether --enable-thread-safety-force was given.
4513 if test "${enable_thread_safety_force+set}" = set; then
4514   enableval=$enable_thread_safety_force;
4515   case $enableval in
4516     yes)
4517       :
4518       ;;
4519     no)
4520       :
4521       ;;
4522     *)
4523       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety-force option" >&5
4524 echo "$as_me: error: no argument expected for --enable-thread-safety-force option" >&2;}
4525    { (exit 1); exit 1; }; }
4526       ;;
4527   esac
4528
4529 else
4530   enable_thread_safety_force=no
4531
4532 fi
4533
4534
4535 if test "$enable_thread_safety" = yes -o \
4536         "$enable_thread_safety_force" = yes; then
4537   enable_thread_safety="yes"    # for 'force'
4538
4539 cat >>confdefs.h <<\_ACEOF
4540 #define ENABLE_THREAD_SAFETY 1
4541 _ACEOF
4542
4543 fi
4544 { echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
4545 echo "${ECHO_T}$enable_thread_safety" >&6; }
4546
4547
4548 #
4549 # Optionally build Tcl modules (PL/Tcl)
4550 #
4551 { echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
4552 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6; }
4553
4554 pgac_args="$pgac_args with_tcl"
4555
4556
4557 # Check whether --with-tcl was given.
4558 if test "${with_tcl+set}" = set; then
4559   withval=$with_tcl;
4560   case $withval in
4561     yes)
4562       :
4563       ;;
4564     no)
4565       :
4566       ;;
4567     *)
4568       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
4569 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
4570    { (exit 1); exit 1; }; }
4571       ;;
4572   esac
4573
4574 else
4575   with_tcl=no
4576
4577 fi
4578
4579
4580 { echo "$as_me:$LINENO: result: $with_tcl" >&5
4581 echo "${ECHO_T}$with_tcl" >&6; }
4582
4583
4584 # We see if the path to the Tcl/Tk configuration scripts is specified.
4585 # This will override the use of tclsh to find the paths to search.
4586
4587
4588 pgac_args="$pgac_args with_tclconfig"
4589
4590
4591 # Check whether --with-tclconfig was given.
4592 if test "${with_tclconfig+set}" = set; then
4593   withval=$with_tclconfig;
4594   case $withval in
4595     yes)
4596       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4597 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4598    { (exit 1); exit 1; }; }
4599       ;;
4600     no)
4601       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4602 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4603    { (exit 1); exit 1; }; }
4604       ;;
4605     *)
4606
4607       ;;
4608   esac
4609
4610 fi
4611
4612
4613
4614 #
4615 # Optionally build Perl modules (PL/Perl)
4616 #
4617 { echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
4618 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6; }
4619
4620 pgac_args="$pgac_args with_perl"
4621
4622
4623 # Check whether --with-perl was given.
4624 if test "${with_perl+set}" = set; then
4625   withval=$with_perl;
4626   case $withval in
4627     yes)
4628       :
4629       ;;
4630     no)
4631       :
4632       ;;
4633     *)
4634       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
4635 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
4636    { (exit 1); exit 1; }; }
4637       ;;
4638   esac
4639
4640 else
4641   with_perl=no
4642
4643 fi
4644
4645
4646 { echo "$as_me:$LINENO: result: $with_perl" >&5
4647 echo "${ECHO_T}$with_perl" >&6; }
4648
4649
4650 #
4651 # Optionally build Python modules (PL/Python)
4652 #
4653 { echo "$as_me:$LINENO: checking whether to build Python modules" >&5
4654 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6; }
4655
4656 pgac_args="$pgac_args with_python"
4657
4658
4659 # Check whether --with-python was given.
4660 if test "${with_python+set}" = set; then
4661   withval=$with_python;
4662   case $withval in
4663     yes)
4664       :
4665       ;;
4666     no)
4667       :
4668       ;;
4669     *)
4670       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
4671 echo "$as_me: error: no argument expected for --with-python option" >&2;}
4672    { (exit 1); exit 1; }; }
4673       ;;
4674   esac
4675
4676 else
4677   with_python=no
4678
4679 fi
4680
4681
4682 { echo "$as_me:$LINENO: result: $with_python" >&5
4683 echo "${ECHO_T}$with_python" >&6; }
4684
4685
4686 #
4687 # GSSAPI
4688 #
4689 { echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
4690 echo $ECHO_N "checking whether to build with GSSAPI support... $ECHO_C" >&6; }
4691
4692 pgac_args="$pgac_args with_gssapi"
4693
4694
4695 # Check whether --with-gssapi was given.
4696 if test "${with_gssapi+set}" = set; then
4697   withval=$with_gssapi;
4698   case $withval in
4699     yes)
4700
4701
4702 cat >>confdefs.h <<\_ACEOF
4703 #define ENABLE_GSS 1
4704 _ACEOF
4705
4706   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
4707
4708       ;;
4709     no)
4710       :
4711       ;;
4712     *)
4713       { { echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
4714 echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
4715    { (exit 1); exit 1; }; }
4716       ;;
4717   esac
4718
4719 else
4720   with_gssapi=no
4721
4722 fi
4723
4724
4725 { echo "$as_me:$LINENO: result: $with_gssapi" >&5
4726 echo "${ECHO_T}$with_gssapi" >&6; }
4727
4728
4729 #
4730 # Kerberos 5
4731 #
4732 { echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
4733 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6; }
4734
4735 pgac_args="$pgac_args with_krb5"
4736
4737
4738 # Check whether --with-krb5 was given.
4739 if test "${with_krb5+set}" = set; then
4740   withval=$with_krb5;
4741   case $withval in
4742     yes)
4743
4744
4745 cat >>confdefs.h <<\_ACEOF
4746 #define KRB5 1
4747 _ACEOF
4748
4749   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
4750
4751       ;;
4752     no)
4753       :
4754       ;;
4755     *)
4756       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
4757 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
4758    { (exit 1); exit 1; }; }
4759       ;;
4760   esac
4761
4762 else
4763   with_krb5=no
4764
4765 fi
4766
4767
4768 { echo "$as_me:$LINENO: result: $with_krb5" >&5
4769 echo "${ECHO_T}$with_krb5" >&6; }
4770
4771
4772
4773
4774
4775
4776 #
4777 # Kerberos configuration parameters
4778 #
4779
4780 pgac_args="$pgac_args with_krb_srvnam"
4781
4782
4783 # Check whether --with-krb-srvnam was given.
4784 if test "${with_krb_srvnam+set}" = set; then
4785   withval=$with_krb_srvnam;
4786   case $withval in
4787     yes)
4788       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
4789 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
4790    { (exit 1); exit 1; }; }
4791       ;;
4792     no)
4793       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
4794 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
4795    { (exit 1); exit 1; }; }
4796       ;;
4797     *)
4798
4799       ;;
4800   esac
4801
4802 else
4803   with_krb_srvnam="postgres"
4804 fi
4805
4806
4807
4808 cat >>confdefs.h <<_ACEOF
4809 #define PG_KRB_SRVNAM "$with_krb_srvnam"
4810 _ACEOF
4811
4812
4813
4814 #
4815 # PAM
4816 #
4817 { echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
4818 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6; }
4819
4820 pgac_args="$pgac_args with_pam"
4821
4822
4823 # Check whether --with-pam was given.
4824 if test "${with_pam+set}" = set; then
4825   withval=$with_pam;
4826   case $withval in
4827     yes)
4828
4829 cat >>confdefs.h <<\_ACEOF
4830 #define USE_PAM 1
4831 _ACEOF
4832
4833       ;;
4834     no)
4835       :
4836       ;;
4837     *)
4838       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
4839 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
4840    { (exit 1); exit 1; }; }
4841       ;;
4842   esac
4843
4844 else
4845   with_pam=no
4846
4847 fi
4848
4849
4850 { echo "$as_me:$LINENO: result: $with_pam" >&5
4851 echo "${ECHO_T}$with_pam" >&6; }
4852
4853
4854
4855 #
4856 # LDAP
4857 #
4858 { echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
4859 echo $ECHO_N "checking whether to build with LDAP support... $ECHO_C" >&6; }
4860
4861 pgac_args="$pgac_args with_ldap"
4862
4863
4864 # Check whether --with-ldap was given.
4865 if test "${with_ldap+set}" = set; then
4866   withval=$with_ldap;
4867   case $withval in
4868     yes)
4869
4870 cat >>confdefs.h <<\_ACEOF
4871 #define USE_LDAP 1
4872 _ACEOF
4873
4874       ;;
4875     no)
4876       :
4877       ;;
4878     *)
4879       { { echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
4880 echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
4881    { (exit 1); exit 1; }; }
4882       ;;
4883   esac
4884
4885 else
4886   with_ldap=no
4887
4888 fi
4889
4890
4891 { echo "$as_me:$LINENO: result: $with_ldap" >&5
4892 echo "${ECHO_T}$with_ldap" >&6; }
4893
4894
4895
4896 #
4897 # Bonjour
4898 #
4899 { echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
4900 echo $ECHO_N "checking whether to build with Bonjour support... $ECHO_C" >&6; }
4901
4902 pgac_args="$pgac_args with_bonjour"
4903
4904
4905 # Check whether --with-bonjour was given.
4906 if test "${with_bonjour+set}" = set; then
4907   withval=$with_bonjour;
4908   case $withval in
4909     yes)
4910
4911 cat >>confdefs.h <<\_ACEOF
4912 #define USE_BONJOUR 1
4913 _ACEOF
4914
4915       ;;
4916     no)
4917       :
4918       ;;
4919     *)
4920       { { echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
4921 echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
4922    { (exit 1); exit 1; }; }
4923       ;;
4924   esac
4925
4926 else
4927   with_bonjour=no
4928
4929 fi
4930
4931
4932 { echo "$as_me:$LINENO: result: $with_bonjour" >&5
4933 echo "${ECHO_T}$with_bonjour" >&6; }
4934
4935
4936
4937 #
4938 # OpenSSL
4939 #
4940 { echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
4941 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6; }
4942
4943 pgac_args="$pgac_args with_openssl"
4944
4945
4946 # Check whether --with-openssl was given.
4947 if test "${with_openssl+set}" = set; then
4948   withval=$with_openssl;
4949   case $withval in
4950     yes)
4951
4952 cat >>confdefs.h <<\_ACEOF
4953 #define USE_SSL 1
4954 _ACEOF
4955
4956       ;;
4957     no)
4958       :
4959       ;;
4960     *)
4961       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
4962 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
4963    { (exit 1); exit 1; }; }
4964       ;;
4965   esac
4966
4967 else
4968   with_openssl=no
4969
4970 fi
4971
4972
4973 { echo "$as_me:$LINENO: result: $with_openssl" >&5
4974 echo "${ECHO_T}$with_openssl" >&6; }
4975
4976
4977
4978 #
4979 # Readline
4980 #
4981
4982 pgac_args="$pgac_args with_readline"
4983
4984
4985 # Check whether --with-readline was given.
4986 if test "${with_readline+set}" = set; then
4987   withval=$with_readline;
4988   case $withval in
4989     yes)
4990       :
4991       ;;
4992     no)
4993       :
4994       ;;
4995     *)
4996       { { echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
4997 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
4998    { (exit 1); exit 1; }; }
4999       ;;
5000   esac
5001
5002 else
5003   with_readline=yes
5004
5005 fi
5006
5007
5008 # readline on MinGW has problems with backslashes in psql and other bugs.
5009 # This is particularly a problem with non-US code pages.
5010 # Therefore disable its use until we understand the cause. 2004-07-20
5011 if test "$PORTNAME" = "win32"; then
5012   if test "$with_readline" = yes; then
5013     { echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5014 echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5015     with_readline=no
5016   fi
5017 fi
5018
5019
5020 #
5021 # Prefer libedit
5022 #
5023
5024 pgac_args="$pgac_args with_libedit_preferred"
5025
5026
5027 # Check whether --with-libedit-preferred was given.
5028 if test "${with_libedit_preferred+set}" = set; then
5029   withval=$with_libedit_preferred;
5030   case $withval in
5031     yes)
5032       :
5033       ;;
5034     no)
5035       :
5036       ;;
5037     *)
5038       { { echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5039 echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5040    { (exit 1); exit 1; }; }
5041       ;;
5042   esac
5043
5044 else
5045   with_libedit_preferred=no
5046
5047 fi
5048
5049
5050
5051
5052 #
5053 # OSSP UUID library
5054 #
5055
5056 pgac_args="$pgac_args with_ossp_uuid"
5057
5058
5059 # Check whether --with-ossp-uuid was given.
5060 if test "${with_ossp_uuid+set}" = set; then
5061   withval=$with_ossp_uuid;
5062   case $withval in
5063     yes)
5064       :
5065       ;;
5066     no)
5067       :
5068       ;;
5069     *)
5070       { { echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5071 echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5072    { (exit 1); exit 1; }; }
5073       ;;
5074   esac
5075
5076 else
5077   with_ossp_uuid=no
5078
5079 fi
5080
5081
5082
5083
5084
5085 #
5086 # XML
5087 #
5088
5089 pgac_args="$pgac_args with_libxml"
5090
5091
5092 # Check whether --with-libxml was given.
5093 if test "${with_libxml+set}" = set; then
5094   withval=$with_libxml;
5095   case $withval in
5096     yes)
5097
5098 cat >>confdefs.h <<\_ACEOF
5099 #define USE_LIBXML 1
5100 _ACEOF
5101
5102       ;;
5103     no)
5104       :
5105       ;;
5106     *)
5107       { { echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5108 echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5109    { (exit 1); exit 1; }; }
5110       ;;
5111   esac
5112
5113 else
5114   with_libxml=no
5115
5116 fi
5117
5118
5119
5120 if test "$with_libxml" = yes ; then
5121   for ac_prog in xml2-config
5122 do
5123   # Extract the first word of "$ac_prog", so it can be a program name with args.
5124 set dummy $ac_prog; ac_word=$2
5125 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5126 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5127 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5128   echo $ECHO_N "(cached) $ECHO_C" >&6
5129 else
5130   if test -n "$XML2_CONFIG"; then
5131   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5132 else
5133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5134 for as_dir in $PATH
5135 do
5136   IFS=$as_save_IFS
5137   test -z "$as_dir" && as_dir=.
5138   for ac_exec_ext in '' $ac_executable_extensions; do
5139   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5140     ac_cv_prog_XML2_CONFIG="$ac_prog"
5141     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5142     break 2
5143   fi
5144 done
5145 done
5146 IFS=$as_save_IFS
5147
5148 fi
5149 fi
5150 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5151 if test -n "$XML2_CONFIG"; then
5152   { echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5153 echo "${ECHO_T}$XML2_CONFIG" >&6; }
5154 else
5155   { echo "$as_me:$LINENO: result: no" >&5
5156 echo "${ECHO_T}no" >&6; }
5157 fi
5158
5159
5160   test -n "$XML2_CONFIG" && break
5161 done
5162
5163   if test -n "$XML2_CONFIG"; then
5164     for pgac_option in `$XML2_CONFIG --cflags`; do
5165       case $pgac_option in
5166         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5167       esac
5168     done
5169     for pgac_option in `$XML2_CONFIG --libs`; do
5170       case $pgac_option in
5171         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5172       esac
5173     done
5174   fi
5175 fi
5176
5177
5178
5179 #
5180 # XSLT
5181 #
5182
5183 pgac_args="$pgac_args with_libxslt"
5184
5185
5186 # Check whether --with-libxslt was given.
5187 if test "${with_libxslt+set}" = set; then
5188   withval=$with_libxslt;
5189   case $withval in
5190     yes)
5191
5192 cat >>confdefs.h <<\_ACEOF
5193 #define USE_LIBXSLT 1
5194 _ACEOF
5195
5196       ;;
5197     no)
5198       :
5199       ;;
5200     *)
5201       { { echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5202 echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5203    { (exit 1); exit 1; }; }
5204       ;;
5205   esac
5206
5207 else
5208   with_libxslt=no
5209
5210 fi
5211
5212
5213
5214
5215
5216
5217 #
5218 # tzdata
5219 #
5220
5221 pgac_args="$pgac_args with_system_tzdata"
5222
5223
5224 # Check whether --with-system-tzdata was given.
5225 if test "${with_system_tzdata+set}" = set; then
5226   withval=$with_system_tzdata;
5227   case $withval in
5228     yes)
5229       { { echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5230 echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5231    { (exit 1); exit 1; }; }
5232       ;;
5233     no)
5234       { { echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5235 echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5236    { (exit 1); exit 1; }; }
5237       ;;
5238     *)
5239
5240       ;;
5241   esac
5242
5243 fi
5244
5245
5246
5247
5248 #
5249 # Zlib
5250 #
5251
5252 pgac_args="$pgac_args with_zlib"
5253
5254
5255 # Check whether --with-zlib was given.
5256 if test "${with_zlib+set}" = set; then
5257   withval=$with_zlib;
5258   case $withval in
5259     yes)
5260       :
5261       ;;
5262     no)
5263       :
5264       ;;
5265     *)
5266       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5267 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5268    { (exit 1); exit 1; }; }
5269       ;;
5270   esac
5271
5272 else
5273   with_zlib=yes
5274
5275 fi
5276
5277
5278
5279
5280 #
5281 # Elf
5282 #
5283
5284 # Assume system is ELF if it predefines __ELF__ as 1,
5285 # otherwise believe host_os based default.
5286 case $host_os in
5287     freebsd1*|freebsd2*) elf=no;;
5288     freebsd3*|freebsd4*) elf=yes;;
5289 esac
5290
5291
5292 { echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5293 echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
5294 if test "${ac_cv_path_GREP+set}" = set; then
5295   echo $ECHO_N "(cached) $ECHO_C" >&6
5296 else
5297   # Extract the first word of "grep ggrep" to use in msg output
5298 if test -z "$GREP"; then
5299 set dummy grep ggrep; ac_prog_name=$2
5300 if test "${ac_cv_path_GREP+set}" = set; then
5301   echo $ECHO_N "(cached) $ECHO_C" >&6
5302 else
5303   ac_path_GREP_found=false
5304 # Loop through the user's path and test for each of PROGNAME-LIST
5305 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5306 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5307 do
5308   IFS=$as_save_IFS
5309   test -z "$as_dir" && as_dir=.
5310   for ac_prog in grep ggrep; do
5311   for ac_exec_ext in '' $ac_executable_extensions; do
5312     ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5313     { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5314     # Check for GNU ac_path_GREP and select it if it is found.
5315   # Check for GNU $ac_path_GREP
5316 case `"$ac_path_GREP" --version 2>&1` in
5317 *GNU*)
5318   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5319 *)
5320   ac_count=0
5321   echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
5322   while :
5323   do
5324     cat "conftest.in" "conftest.in" >"conftest.tmp"
5325     mv "conftest.tmp" "conftest.in"
5326     cp "conftest.in" "conftest.nl"
5327     echo 'GREP' >> "conftest.nl"
5328     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5329     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5330     ac_count=`expr $ac_count + 1`
5331     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5332       # Best one so far, save it but keep looking for a better one
5333       ac_cv_path_GREP="$ac_path_GREP"
5334       ac_path_GREP_max=$ac_count
5335     fi
5336     # 10*(2^10) chars as input seems more than enough
5337     test $ac_count -gt 10 && break
5338   done
5339   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5340 esac
5341
5342
5343     $ac_path_GREP_found && break 3
5344   done
5345 done
5346
5347 done
5348 IFS=$as_save_IFS
5349
5350
5351 fi
5352
5353 GREP="$ac_cv_path_GREP"
5354 if test -z "$GREP"; then
5355   { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5356 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5357    { (exit 1); exit 1; }; }
5358 fi
5359
5360 else
5361   ac_cv_path_GREP=$GREP
5362 fi
5363
5364
5365 fi
5366 { echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5367 echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
5368  GREP="$ac_cv_path_GREP"
5369
5370
5371 { echo "$as_me:$LINENO: checking for egrep" >&5
5372 echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
5373 if test "${ac_cv_path_EGREP+set}" = set; then
5374   echo $ECHO_N "(cached) $ECHO_C" >&6
5375 else
5376   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5377    then ac_cv_path_EGREP="$GREP -E"
5378    else
5379      # Extract the first word of "egrep" to use in msg output
5380 if test -z "$EGREP"; then
5381 set dummy egrep; ac_prog_name=$2
5382 if test "${ac_cv_path_EGREP+set}" = set; then
5383   echo $ECHO_N "(cached) $ECHO_C" >&6
5384 else
5385   ac_path_EGREP_found=false
5386 # Loop through the user's path and test for each of PROGNAME-LIST
5387 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5388 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5389 do
5390   IFS=$as_save_IFS
5391   test -z "$as_dir" && as_dir=.
5392   for ac_prog in egrep; do
5393   for ac_exec_ext in '' $ac_executable_extensions; do
5394     ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5395     { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5396     # Check for GNU ac_path_EGREP and select it if it is found.
5397   # Check for GNU $ac_path_EGREP
5398 case `"$ac_path_EGREP" --version 2>&1` in
5399 *GNU*)
5400   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5401 *)
5402   ac_count=0
5403   echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
5404   while :
5405   do
5406     cat "conftest.in" "conftest.in" >"conftest.tmp"
5407     mv "conftest.tmp" "conftest.in"
5408     cp "conftest.in" "conftest.nl"
5409     echo 'EGREP' >> "conftest.nl"
5410     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5411     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5412     ac_count=`expr $ac_count + 1`
5413     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5414       # Best one so far, save it but keep looking for a better one
5415       ac_cv_path_EGREP="$ac_path_EGREP"
5416       ac_path_EGREP_max=$ac_count
5417     fi
5418     # 10*(2^10) chars as input seems more than enough
5419     test $ac_count -gt 10 && break
5420   done
5421   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5422 esac
5423
5424
5425     $ac_path_EGREP_found && break 3
5426   done
5427 done
5428
5429 done
5430 IFS=$as_save_IFS
5431
5432
5433 fi
5434
5435 EGREP="$ac_cv_path_EGREP"
5436 if test -z "$EGREP"; then
5437   { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5438 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5439    { (exit 1); exit 1; }; }
5440 fi
5441
5442 else
5443   ac_cv_path_EGREP=$EGREP
5444 fi
5445
5446
5447    fi
5448 fi
5449 { echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5450 echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
5451  EGREP="$ac_cv_path_EGREP"
5452
5453
5454 cat >conftest.$ac_ext <<_ACEOF
5455 /* confdefs.h.  */
5456 _ACEOF
5457 cat confdefs.h >>conftest.$ac_ext
5458 cat >>conftest.$ac_ext <<_ACEOF
5459 /* end confdefs.h.  */
5460 #if __ELF__
5461   yes
5462 #endif
5463
5464 _ACEOF
5465 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5466   $EGREP "yes" >/dev/null 2>&1; then
5467   ELF_SYS=true
5468 else
5469   if test "X$elf" = "Xyes" ; then
5470   ELF_SYS=true
5471 else
5472   ELF_SYS=
5473 fi
5474 fi
5475 rm -f conftest*
5476
5477
5478
5479 #
5480 # Assignments
5481 #
5482
5483 CPPFLAGS="$CPPFLAGS $INCLUDES"
5484 LDFLAGS="$LDFLAGS $LIBDIRS"
5485
5486
5487
5488
5489 # Check whether --with-gnu-ld was given.
5490 if test "${with_gnu_ld+set}" = set; then
5491   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5492 else
5493   with_gnu_ld=no
5494 fi
5495
5496 ac_prog=ld
5497 if test "$GCC" = yes; then
5498   # Check if gcc -print-prog-name=ld gives a path.
5499   { echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5500 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6; }
5501   case $host in
5502   *-*-mingw*)
5503     # gcc leaves a trailing carriage return which upsets mingw
5504     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5505   *)
5506     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5507   esac
5508   case "$ac_prog" in
5509     # Accept absolute paths.
5510     [\\/]* | [A-Za-z]:[\\/]*)
5511       re_direlt='/[^/][^/]*/\.\./'
5512       # Canonicalize the path of ld
5513       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5514       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5515         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5516       done
5517       test -z "$LD" && LD="$ac_prog"
5518       ;;
5519   "")
5520     # If it fails, then pretend we aren't using GCC.
5521     ac_prog=ld
5522     ;;
5523   *)
5524     # If it is relative, then search for the first ld in PATH.
5525     with_gnu_ld=unknown
5526     ;;
5527   esac
5528 elif test "$with_gnu_ld" = yes; then
5529   { echo "$as_me:$LINENO: checking for GNU ld" >&5
5530 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
5531 else
5532   { echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5533 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; }
5534 fi
5535 if test "${ac_cv_path_LD+set}" = set; then
5536   echo $ECHO_N "(cached) $ECHO_C" >&6
5537 else
5538   if test -z "$LD"; then
5539   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5540   for ac_dir in $PATH; do
5541     test -z "$ac_dir" && ac_dir=.
5542     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5543       ac_cv_path_LD="$ac_dir/$ac_prog"
5544       # Check to see if the program is GNU ld.  I'd rather use --version,
5545       # but apparently some GNU ld's only accept -v.
5546       # Break only if it was the GNU/non-GNU ld that we prefer.
5547       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
5548         test "$with_gnu_ld" != no && break
5549       else
5550         test "$with_gnu_ld" != yes && break
5551       fi
5552     fi
5553   done
5554   IFS="$ac_save_ifs"
5555 else
5556   ac_cv_path_LD="$LD" # Let the user override the test with a path.
5557 fi
5558 fi
5559
5560 LD="$ac_cv_path_LD"
5561 if test -n "$LD"; then
5562   { echo "$as_me:$LINENO: result: $LD" >&5
5563 echo "${ECHO_T}$LD" >&6; }
5564 else
5565   { echo "$as_me:$LINENO: result: no" >&5
5566 echo "${ECHO_T}no" >&6; }
5567 fi
5568 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5569 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5570    { (exit 1); exit 1; }; }
5571 { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5572 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; }
5573 if test "${ac_cv_prog_gnu_ld+set}" = set; then
5574   echo $ECHO_N "(cached) $ECHO_C" >&6
5575 else
5576   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
5577 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
5578   ac_cv_prog_gnu_ld=yes
5579 else
5580   ac_cv_prog_gnu_ld=no
5581 fi
5582 fi
5583 { echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
5584 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6; }
5585 with_gnu_ld=$ac_cv_prog_gnu_ld
5586
5587
5588
5589
5590 case $host_os in sysv5*)
5591   { echo "$as_me:$LINENO: checking whether ld -R works" >&5
5592 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6; }
5593 if test "${pgac_cv_prog_ld_R+set}" = set; then
5594   echo $ECHO_N "(cached) $ECHO_C" >&6
5595 else
5596
5597     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
5598     cat >conftest.$ac_ext <<_ACEOF
5599 /* confdefs.h.  */
5600 _ACEOF
5601 cat confdefs.h >>conftest.$ac_ext
5602 cat >>conftest.$ac_ext <<_ACEOF
5603 /* end confdefs.h.  */
5604
5605 int
5606 main ()
5607 {
5608
5609   ;
5610   return 0;
5611 }
5612 _ACEOF
5613 rm -f conftest.$ac_objext conftest$ac_exeext
5614 if { (ac_try="$ac_link"
5615 case "(($ac_try" in
5616   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5617   *) ac_try_echo=$ac_try;;
5618 esac
5619 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5620   (eval "$ac_link") 2>conftest.er1
5621   ac_status=$?
5622   grep -v '^ *+' conftest.er1 >conftest.err
5623   rm -f conftest.er1
5624   cat conftest.err >&5
5625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5626   (exit $ac_status); } && {
5627          test -z "$ac_c_werror_flag" ||
5628          test ! -s conftest.err
5629        } && test -s conftest$ac_exeext &&
5630        $as_test_x conftest$ac_exeext; then
5631   pgac_cv_prog_ld_R=yes
5632 else
5633   echo "$as_me: failed program was:" >&5
5634 sed 's/^/| /' conftest.$ac_ext >&5
5635
5636         pgac_cv_prog_ld_R=no
5637 fi
5638
5639 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5640       conftest$ac_exeext conftest.$ac_ext
5641     LDFLAGS=$pgac_save_LDFLAGS
5642
5643 fi
5644 { echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
5645 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6; }
5646   ld_R_works=$pgac_cv_prog_ld_R
5647
5648 esac
5649 if test -n "$ac_tool_prefix"; then
5650   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5651 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5652 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5653 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5654 if test "${ac_cv_prog_RANLIB+set}" = set; then
5655   echo $ECHO_N "(cached) $ECHO_C" >&6
5656 else
5657   if test -n "$RANLIB"; then
5658   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5659 else
5660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5661 for as_dir in $PATH
5662 do
5663   IFS=$as_save_IFS
5664   test -z "$as_dir" && as_dir=.
5665   for ac_exec_ext in '' $ac_executable_extensions; do
5666   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5667     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5668     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5669     break 2
5670   fi
5671 done
5672 done
5673 IFS=$as_save_IFS
5674
5675 fi
5676 fi
5677 RANLIB=$ac_cv_prog_RANLIB
5678 if test -n "$RANLIB"; then
5679   { echo "$as_me:$LINENO: result: $RANLIB" >&5
5680 echo "${ECHO_T}$RANLIB" >&6; }
5681 else
5682   { echo "$as_me:$LINENO: result: no" >&5
5683 echo "${ECHO_T}no" >&6; }
5684 fi
5685
5686
5687 fi
5688 if test -z "$ac_cv_prog_RANLIB"; then
5689   ac_ct_RANLIB=$RANLIB
5690   # Extract the first word of "ranlib", so it can be a program name with args.
5691 set dummy ranlib; ac_word=$2
5692 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5693 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5694 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
5695   echo $ECHO_N "(cached) $ECHO_C" >&6
5696 else
5697   if test -n "$ac_ct_RANLIB"; then
5698   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5699 else
5700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5701 for as_dir in $PATH
5702 do
5703   IFS=$as_save_IFS
5704   test -z "$as_dir" && as_dir=.
5705   for ac_exec_ext in '' $ac_executable_extensions; do
5706   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5707     ac_cv_prog_ac_ct_RANLIB="ranlib"
5708     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5709     break 2
5710   fi
5711 done
5712 done
5713 IFS=$as_save_IFS
5714
5715 fi
5716 fi
5717 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5718 if test -n "$ac_ct_RANLIB"; then
5719   { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
5720 echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
5721 else
5722   { echo "$as_me:$LINENO: result: no" >&5
5723 echo "${ECHO_T}no" >&6; }
5724 fi
5725
5726   if test "x$ac_ct_RANLIB" = x; then
5727     RANLIB=":"
5728   else
5729     case $cross_compiling:$ac_tool_warned in
5730 yes:)
5731 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
5732 whose name does not start with the host triplet.  If you think this
5733 configuration is useful to you, please write to autoconf@gnu.org." >&5
5734 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
5735 whose name does not start with the host triplet.  If you think this
5736 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
5737 ac_tool_warned=yes ;;
5738 esac
5739     RANLIB=$ac_ct_RANLIB
5740   fi
5741 else
5742   RANLIB="$ac_cv_prog_RANLIB"
5743 fi
5744
5745
5746   if test -n "$ac_tool_prefix"; then
5747   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5748 set dummy ${ac_tool_prefix}strip; ac_word=$2
5749 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5750 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5751 if test "${ac_cv_prog_STRIP+set}" = set; then
5752   echo $ECHO_N "(cached) $ECHO_C" >&6
5753 else
5754   if test -n "$STRIP"; then
5755   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5756 else
5757 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5758 for as_dir in $PATH
5759 do
5760   IFS=$as_save_IFS
5761   test -z "$as_dir" && as_dir=.
5762   for ac_exec_ext in '' $ac_executable_extensions; do
5763   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5764     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5765     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5766     break 2
5767   fi
5768 done
5769 done
5770 IFS=$as_save_IFS
5771
5772 fi
5773 fi
5774 STRIP=$ac_cv_prog_STRIP
5775 if test -n "$STRIP"; then
5776   { echo "$as_me:$LINENO: result: $STRIP" >&5
5777 echo "${ECHO_T}$STRIP" >&6; }
5778 else
5779   { echo "$as_me:$LINENO: result: no" >&5
5780 echo "${ECHO_T}no" >&6; }
5781 fi
5782
5783
5784 fi
5785 if test -z "$ac_cv_prog_STRIP"; then
5786   ac_ct_STRIP=$STRIP
5787   # Extract the first word of "strip", so it can be a program name with args.
5788 set dummy strip; ac_word=$2
5789 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5790 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5791 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
5792   echo $ECHO_N "(cached) $ECHO_C" >&6
5793 else
5794   if test -n "$ac_ct_STRIP"; then
5795   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5796 else
5797 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5798 for as_dir in $PATH
5799 do
5800   IFS=$as_save_IFS
5801   test -z "$as_dir" && as_dir=.
5802   for ac_exec_ext in '' $ac_executable_extensions; do
5803   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5804     ac_cv_prog_ac_ct_STRIP="strip"
5805     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5806     break 2
5807   fi
5808 done
5809 done
5810 IFS=$as_save_IFS
5811
5812 fi
5813 fi
5814 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5815 if test -n "$ac_ct_STRIP"; then
5816   { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
5817 echo "${ECHO_T}$ac_ct_STRIP" >&6; }
5818 else
5819   { echo "$as_me:$LINENO: result: no" >&5
5820 echo "${ECHO_T}no" >&6; }
5821 fi
5822
5823   if test "x$ac_ct_STRIP" = x; then
5824     STRIP=":"
5825   else
5826     case $cross_compiling:$ac_tool_warned in
5827 yes:)
5828 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
5829 whose name does not start with the host triplet.  If you think this
5830 configuration is useful to you, please write to autoconf@gnu.org." >&5
5831 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
5832 whose name does not start with the host triplet.  If you think this
5833 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
5834 ac_tool_warned=yes ;;
5835 esac
5836     STRIP=$ac_ct_STRIP
5837   fi
5838 else
5839   STRIP="$ac_cv_prog_STRIP"
5840 fi
5841
5842
5843   { echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
5844 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6; }
5845   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
5846     STRIP_STATIC_LIB="$STRIP -x"
5847     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
5848     { echo "$as_me:$LINENO: result: yes" >&5
5849 echo "${ECHO_T}yes" >&6; }
5850   else
5851     STRIP_STATIC_LIB=:
5852     STRIP_SHARED_LIB=:
5853     { echo "$as_me:$LINENO: result: no" >&5
5854 echo "${ECHO_T}no" >&6; }
5855   fi
5856
5857
5858
5859
5860 # Extract the first word of "tar", so it can be a program name with args.
5861 set dummy tar; ac_word=$2
5862 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5863 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5864 if test "${ac_cv_path_TAR+set}" = set; then
5865   echo $ECHO_N "(cached) $ECHO_C" >&6
5866 else
5867   case $TAR in
5868   [\\/]* | ?:[\\/]*)
5869   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
5870   ;;
5871   *)
5872   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5873 for as_dir in $PATH
5874 do
5875   IFS=$as_save_IFS
5876   test -z "$as_dir" && as_dir=.
5877   for ac_exec_ext in '' $ac_executable_extensions; do
5878   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5879     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
5880     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5881     break 2
5882   fi
5883 done
5884 done
5885 IFS=$as_save_IFS
5886
5887   ;;
5888 esac
5889 fi
5890 TAR=$ac_cv_path_TAR
5891 if test -n "$TAR"; then
5892   { echo "$as_me:$LINENO: result: $TAR" >&5
5893 echo "${ECHO_T}$TAR" >&6; }
5894 else
5895   { echo "$as_me:$LINENO: result: no" >&5
5896 echo "${ECHO_T}no" >&6; }
5897 fi
5898
5899
5900 { echo "$as_me:$LINENO: checking whether ln -s works" >&5
5901 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
5902 LN_S=$as_ln_s
5903 if test "$LN_S" = "ln -s"; then
5904   { echo "$as_me:$LINENO: result: yes" >&5
5905 echo "${ECHO_T}yes" >&6; }
5906 else
5907   { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
5908 echo "${ECHO_T}no, using $LN_S" >&6; }
5909 fi
5910
5911 for ac_prog in gawk mawk nawk awk
5912 do
5913   # Extract the first word of "$ac_prog", so it can be a program name with args.
5914 set dummy $ac_prog; ac_word=$2
5915 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5916 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5917 if test "${ac_cv_prog_AWK+set}" = set; then
5918   echo $ECHO_N "(cached) $ECHO_C" >&6
5919 else
5920   if test -n "$AWK"; then
5921   ac_cv_prog_AWK="$AWK" # Let the user override the test.
5922 else
5923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5924 for as_dir in $PATH
5925 do
5926   IFS=$as_save_IFS
5927   test -z "$as_dir" && as_dir=.
5928   for ac_exec_ext in '' $ac_executable_extensions; do
5929   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5930     ac_cv_prog_AWK="$ac_prog"
5931     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5932     break 2
5933   fi
5934 done
5935 done
5936 IFS=$as_save_IFS
5937
5938 fi
5939 fi
5940 AWK=$ac_cv_prog_AWK
5941 if test -n "$AWK"; then
5942   { echo "$as_me:$LINENO: result: $AWK" >&5
5943 echo "${ECHO_T}$AWK" >&6; }
5944 else
5945   { echo "$as_me:$LINENO: result: no" >&5
5946 echo "${ECHO_T}no" >&6; }
5947 fi
5948
5949
5950   test -n "$AWK" && break
5951 done
5952
5953
5954 # Let the user override the search
5955 if test -z "$BISON"; then
5956   for ac_prog in bison
5957 do
5958   # Extract the first word of "$ac_prog", so it can be a program name with args.
5959 set dummy $ac_prog; ac_word=$2
5960 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5961 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5962 if test "${ac_cv_prog_BISON+set}" = set; then
5963   echo $ECHO_N "(cached) $ECHO_C" >&6
5964 else
5965   if test -n "$BISON"; then
5966   ac_cv_prog_BISON="$BISON" # Let the user override the test.
5967 else
5968 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5969 for as_dir in $PATH
5970 do
5971   IFS=$as_save_IFS
5972   test -z "$as_dir" && as_dir=.
5973   for ac_exec_ext in '' $ac_executable_extensions; do
5974   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5975     ac_cv_prog_BISON="$ac_prog"
5976     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5977     break 2
5978   fi
5979 done
5980 done
5981 IFS=$as_save_IFS
5982
5983 fi
5984 fi
5985 BISON=$ac_cv_prog_BISON
5986 if test -n "$BISON"; then
5987   { echo "$as_me:$LINENO: result: $BISON" >&5
5988 echo "${ECHO_T}$BISON" >&6; }
5989 else
5990   { echo "$as_me:$LINENO: result: no" >&5
5991 echo "${ECHO_T}no" >&6; }
5992 fi
5993
5994
5995   test -n "$BISON" && break
5996 done
5997
5998 fi
5999
6000 if test "$BISON"; then
6001   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
6002   { echo "$as_me:$LINENO: using $pgac_bison_version" >&5
6003 echo "$as_me: using $pgac_bison_version" >&6;}
6004   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
6005   then
6006     { echo "$as_me:$LINENO: WARNING:
6007 *** The installed version of Bison is too old to use with PostgreSQL.
6008 *** Bison version 1.875 or later is required." >&5
6009 echo "$as_me: WARNING:
6010 *** The installed version of Bison is too old to use with PostgreSQL.
6011 *** Bison version 1.875 or later is required." >&2;}
6012     BISON=""
6013   fi
6014 fi
6015
6016 if test -z "$BISON"; then
6017   { echo "$as_me:$LINENO: WARNING:
6018 *** Without Bison you will not be able to build PostgreSQL from CVS nor
6019 *** change any of the parser definition files.  You can obtain Bison from
6020 *** a GNU mirror site.  (If you are using the official distribution of
6021 *** PostgreSQL then you do not need to worry about this, because the Bison
6022 *** output is pre-generated.)" >&5
6023 echo "$as_me: WARNING:
6024 *** Without Bison you will not be able to build PostgreSQL from CVS nor
6025 *** change any of the parser definition files.  You can obtain Bison from
6026 *** a GNU mirror site.  (If you are using the official distribution of
6027 *** PostgreSQL then you do not need to worry about this, because the Bison
6028 *** output is pre-generated.)" >&2;}
6029 fi
6030 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
6031
6032
6033 { echo "$as_me:$LINENO: checking for flex" >&5
6034 echo $ECHO_N "checking for flex... $ECHO_C" >&6; }
6035 if test "${pgac_cv_path_flex+set}" = set; then
6036   echo $ECHO_N "(cached) $ECHO_C" >&6
6037 else
6038   # Let the user override the test
6039 if test -n "$FLEX"; then
6040   pgac_cv_path_flex=$FLEX
6041 else
6042   pgac_save_IFS=$IFS
6043   IFS=$PATH_SEPARATOR
6044   for pgac_dir in $PATH; do
6045     IFS=$pgac_save_IFS
6046     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
6047       pgac_dir=`pwd`
6048     fi
6049     for pgac_prog in flex lex; do
6050       pgac_candidate="$pgac_dir/$pgac_prog"
6051       if test -f "$pgac_candidate" \
6052         && $pgac_candidate --version </dev/null >/dev/null 2>&1
6053       then
6054         echo '%%'  > conftest.l
6055         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
6056           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
6057             pgac_broken_flex=$pgac_candidate
6058             continue
6059           fi
6060
6061           pgac_cv_path_flex=$pgac_candidate
6062           break 2
6063         fi
6064       fi
6065     done
6066   done
6067   rm -f conftest.l lex.yy.c
6068   : ${pgac_cv_path_flex=no}
6069 fi
6070
6071 fi
6072 { echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
6073 echo "${ECHO_T}$pgac_cv_path_flex" >&6; }
6074 if test x"$pgac_cv_path_flex" = x"no"; then
6075   if test -n "$pgac_broken_flex"; then
6076     { echo "$as_me:$LINENO: WARNING:
6077 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
6078 *** should get version 2.5.4 or later." >&5
6079 echo "$as_me: WARNING:
6080 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
6081 *** should get version 2.5.4 or later." >&2;}
6082   fi
6083
6084   { echo "$as_me:$LINENO: WARNING:
6085 *** Without Flex you will not be able to build PostgreSQL from CVS or
6086 *** change any of the scanner definition files.  You can obtain Flex from
6087 *** a GNU mirror site.  (If you are using the official distribution of
6088 *** PostgreSQL then you do not need to worry about this because the Flex
6089 *** output is pre-generated.)" >&5
6090 echo "$as_me: WARNING:
6091 *** Without Flex you will not be able to build PostgreSQL from CVS or
6092 *** change any of the scanner definition files.  You can obtain Flex from
6093 *** a GNU mirror site.  (If you are using the official distribution of
6094 *** PostgreSQL then you do not need to worry about this because the Flex
6095 *** output is pre-generated.)" >&2;}
6096
6097   FLEX=
6098 else
6099   FLEX=$pgac_cv_path_flex
6100   pgac_flex_version=`$FLEX -V 2>/dev/null`
6101   { echo "$as_me:$LINENO: using $pgac_flex_version" >&5
6102 echo "$as_me: using $pgac_flex_version" >&6;}
6103 fi
6104
6105
6106
6107
6108
6109 # Extract the first word of "perl", so it can be a program name with args.
6110 set dummy perl; ac_word=$2
6111 { echo "$as_me:$LINENO: checking for $ac_word" >&5
6112 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
6113 if test "${ac_cv_path_PERL+set}" = set; then
6114   echo $ECHO_N "(cached) $ECHO_C" >&6
6115 else
6116   case $PERL in
6117   [\\/]* | ?:[\\/]*)
6118   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
6119   ;;
6120   *)
6121   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6122 for as_dir in $PATH
6123 do
6124   IFS=$as_save_IFS
6125   test -z "$as_dir" && as_dir=.
6126   for ac_exec_ext in '' $ac_executable_extensions; do
6127   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6128     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
6129     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6130     break 2
6131   fi
6132 done
6133 done
6134 IFS=$as_save_IFS
6135
6136   ;;
6137 esac
6138 fi
6139 PERL=$ac_cv_path_PERL
6140 if test -n "$PERL"; then
6141   { echo "$as_me:$LINENO: result: $PERL" >&5
6142 echo "${ECHO_T}$PERL" >&6; }
6143 else
6144   { echo "$as_me:$LINENO: result: no" >&5
6145 echo "${ECHO_T}no" >&6; }
6146 fi
6147
6148
6149 if test "$with_perl" = yes; then
6150
6151 { echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
6152 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6; }
6153 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
6154 { echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
6155 echo "${ECHO_T}$perl_archlibexp" >&6; }
6156 { echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
6157 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6; }
6158 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
6159 { echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
6160 echo "${ECHO_T}$perl_privlibexp" >&6; }
6161 { echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
6162 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6; }
6163 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
6164 { echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
6165 echo "${ECHO_T}$perl_useshrplib" >&6; }
6166
6167 { echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
6168 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6; }
6169 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
6170 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
6171 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
6172 { echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
6173 echo "${ECHO_T}$perl_embed_ldflags" >&6; }
6174 fi
6175
6176 if test "$with_python" = yes; then
6177   # Extract the first word of "python", so it can be a program name with args.
6178 set dummy python; ac_word=$2
6179 { echo "$as_me:$LINENO: checking for $ac_word" >&5
6180 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
6181 if test "${ac_cv_path_PYTHON+set}" = set; then
6182   echo $ECHO_N "(cached) $ECHO_C" >&6
6183 else
6184   case $PYTHON in
6185   [\\/]* | ?:[\\/]*)
6186   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
6187   ;;
6188   *)
6189   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6190 for as_dir in $PATH
6191 do
6192   IFS=$as_save_IFS
6193   test -z "$as_dir" && as_dir=.
6194   for ac_exec_ext in '' $ac_executable_extensions; do
6195   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6196     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
6197     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6198     break 2
6199   fi
6200 done
6201 done
6202 IFS=$as_save_IFS
6203
6204   ;;
6205 esac
6206 fi
6207 PYTHON=$ac_cv_path_PYTHON
6208 if test -n "$PYTHON"; then
6209   { echo "$as_me:$LINENO: result: $PYTHON" >&5
6210 echo "${ECHO_T}$PYTHON" >&6; }
6211 else
6212   { echo "$as_me:$LINENO: result: no" >&5
6213 echo "${ECHO_T}no" >&6; }
6214 fi
6215
6216
6217 if test x"$PYTHON" = x""; then
6218   { { echo "$as_me:$LINENO: error: Python not found" >&5
6219 echo "$as_me: error: Python not found" >&2;}
6220    { (exit 1); exit 1; }; }
6221 fi
6222
6223
6224 { echo "$as_me:$LINENO: checking for Python distutils module" >&5
6225 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6; }
6226 if "${PYTHON}" 2>&- -c 'import distutils'
6227 then
6228     { echo "$as_me:$LINENO: result: yes" >&5
6229 echo "${ECHO_T}yes" >&6; }
6230 else
6231     { echo "$as_me:$LINENO: result: no" >&5
6232 echo "${ECHO_T}no" >&6; }
6233     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
6234 echo "$as_me: error: distutils module not found" >&2;}
6235    { (exit 1); exit 1; }; }
6236 fi
6237 { echo "$as_me:$LINENO: checking Python configuration directory" >&5
6238 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6; }
6239 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
6240 python_configdir=`${PYTHON} -c "from distutils.sysconfig import get_python_lib as f; import os; print os.path.join(f(plat_specific=1,standard_lib=1),'config')"`
6241 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
6242
6243 # This should be enough of a message.
6244 { echo "$as_me:$LINENO: result: $python_configdir" >&5
6245 echo "${ECHO_T}$python_configdir" >&6; }
6246
6247
6248 { echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
6249 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6; }
6250
6251 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
6252 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
6253 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
6254 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
6255
6256 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
6257 then
6258         # New way: use the official shared library
6259         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
6260         python_libspec="-L${python_libdir} -l${ldlibrary}"
6261 else
6262         # Old way: use libpython from python_configdir
6263         python_libdir="${python_configdir}"
6264         python_libspec="-L${python_libdir} -lpython${python_version}"
6265 fi
6266
6267 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
6268
6269 { echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
6270 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6; }
6271
6272
6273 # threaded python is not supported on bsd's
6274 { echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
6275 echo $ECHO_N "checking whether Python is compiled with thread support... $ECHO_C" >&6; }
6276 pythreads=`${PYTHON} -c "import sys; print int('thread' in sys.builtin_module_names)"`
6277 if test "$pythreads" = "1"; then
6278   { echo "$as_me:$LINENO: result: yes" >&5
6279 echo "${ECHO_T}yes" >&6; }
6280   case $host_os in
6281   openbsd*|freebsd*)
6282     { { echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
6283 echo "$as_me: error: threaded Python not supported on this platform" >&2;}
6284    { (exit 1); exit 1; }; }
6285     ;;
6286   esac
6287 else
6288   { echo "$as_me:$LINENO: result: no" >&5
6289 echo "${ECHO_T}no" >&6; }
6290 fi
6291
6292
6293 fi
6294
6295 # Supply a numeric version string for use by 3rd party add-ons
6296 # awk -F is a regex on some platforms, and not on others, so make "." a tab
6297 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
6298 tr '.' '        ' |
6299 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
6300
6301 cat >>confdefs.h <<_ACEOF
6302 #define PG_VERSION_NUM $PG_VERSION_NUM
6303 _ACEOF
6304
6305
6306 ##
6307 ## Libraries
6308 ##
6309 ## Most libraries are included only if they demonstrably provide a function
6310 ## we need, but libm is an exception: always include it, because there are
6311 ## too many compilers that play cute optimization games that will break
6312 ## probes for standard functions such as pow().
6313 ##
6314
6315
6316 { echo "$as_me:$LINENO: checking for main in -lm" >&5
6317 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6; }
6318 if test "${ac_cv_lib_m_main+set}" = set; then
6319   echo $ECHO_N "(cached) $ECHO_C" >&6
6320 else
6321   ac_check_lib_save_LIBS=$LIBS
6322 LIBS="-lm  $LIBS"
6323 cat >conftest.$ac_ext <<_ACEOF
6324 /* confdefs.h.  */
6325 _ACEOF
6326 cat confdefs.h >>conftest.$ac_ext
6327 cat >>conftest.$ac_ext <<_ACEOF
6328 /* end confdefs.h.  */
6329
6330
6331 int
6332 main ()
6333 {
6334 return main ();
6335   ;
6336   return 0;
6337 }
6338 _ACEOF
6339 rm -f conftest.$ac_objext conftest$ac_exeext
6340 if { (ac_try="$ac_link"
6341 case "(($ac_try" in
6342   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6343   *) ac_try_echo=$ac_try;;
6344 esac
6345 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6346   (eval "$ac_link") 2>conftest.er1
6347   ac_status=$?
6348   grep -v '^ *+' conftest.er1 >conftest.err
6349   rm -f conftest.er1
6350   cat conftest.err >&5
6351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6352   (exit $ac_status); } && {
6353          test -z "$ac_c_werror_flag" ||
6354          test ! -s conftest.err
6355        } && test -s conftest$ac_exeext &&
6356        $as_test_x conftest$ac_exeext; then
6357   ac_cv_lib_m_main=yes
6358 else
6359   echo "$as_me: failed program was:" >&5
6360 sed 's/^/| /' conftest.$ac_ext >&5
6361
6362         ac_cv_lib_m_main=no
6363 fi
6364
6365 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6366       conftest$ac_exeext conftest.$ac_ext
6367 LIBS=$ac_check_lib_save_LIBS
6368 fi
6369 { echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
6370 echo "${ECHO_T}$ac_cv_lib_m_main" >&6; }
6371 if test $ac_cv_lib_m_main = yes; then
6372   cat >>confdefs.h <<_ACEOF
6373 #define HAVE_LIBM 1
6374 _ACEOF
6375
6376   LIBS="-lm $LIBS"
6377
6378 fi
6379
6380 { echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
6381 echo $ECHO_N "checking for library containing setproctitle... $ECHO_C" >&6; }
6382 if test "${ac_cv_search_setproctitle+set}" = set; then
6383   echo $ECHO_N "(cached) $ECHO_C" >&6
6384 else
6385   ac_func_search_save_LIBS=$LIBS
6386 cat >conftest.$ac_ext <<_ACEOF
6387 /* confdefs.h.  */
6388 _ACEOF
6389 cat confdefs.h >>conftest.$ac_ext
6390 cat >>conftest.$ac_ext <<_ACEOF
6391 /* end confdefs.h.  */
6392
6393 /* Override any GCC internal prototype to avoid an error.
6394    Use char because int might match the return type of a GCC
6395    builtin and then its argument prototype would still apply.  */
6396 #ifdef __cplusplus
6397 extern "C"
6398 #endif
6399 char setproctitle ();
6400 int
6401 main ()
6402 {
6403 return setproctitle ();
6404   ;
6405   return 0;
6406 }
6407 _ACEOF
6408 for ac_lib in '' util; do
6409   if test -z "$ac_lib"; then
6410     ac_res="none required"
6411   else
6412     ac_res=-l$ac_lib
6413     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6414   fi
6415   rm -f conftest.$ac_objext conftest$ac_exeext
6416 if { (ac_try="$ac_link"
6417 case "(($ac_try" in
6418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6419   *) ac_try_echo=$ac_try;;
6420 esac
6421 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6422   (eval "$ac_link") 2>conftest.er1
6423   ac_status=$?
6424   grep -v '^ *+' conftest.er1 >conftest.err
6425   rm -f conftest.er1
6426   cat conftest.err >&5
6427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6428   (exit $ac_status); } && {
6429          test -z "$ac_c_werror_flag" ||
6430          test ! -s conftest.err
6431        } && test -s conftest$ac_exeext &&
6432        $as_test_x conftest$ac_exeext; then
6433   ac_cv_search_setproctitle=$ac_res
6434 else
6435   echo "$as_me: failed program was:" >&5
6436 sed 's/^/| /' conftest.$ac_ext >&5
6437
6438
6439 fi
6440
6441 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6442       conftest$ac_exeext
6443   if test "${ac_cv_search_setproctitle+set}" = set; then
6444   break
6445 fi
6446 done
6447 if test "${ac_cv_search_setproctitle+set}" = set; then
6448   :
6449 else
6450   ac_cv_search_setproctitle=no
6451 fi
6452 rm conftest.$ac_ext
6453 LIBS=$ac_func_search_save_LIBS
6454 fi
6455 { echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
6456 echo "${ECHO_T}$ac_cv_search_setproctitle" >&6; }
6457 ac_res=$ac_cv_search_setproctitle
6458 if test "$ac_res" != no; then
6459   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6460
6461 fi
6462
6463 { echo "$as_me:$LINENO: checking for library containing dlopen" >&5
6464 echo $ECHO_N "checking for library containing dlopen... $ECHO_C" >&6; }
6465 if test "${ac_cv_search_dlopen+set}" = set; then
6466   echo $ECHO_N "(cached) $ECHO_C" >&6
6467 else
6468   ac_func_search_save_LIBS=$LIBS
6469 cat >conftest.$ac_ext <<_ACEOF
6470 /* confdefs.h.  */
6471 _ACEOF
6472 cat confdefs.h >>conftest.$ac_ext
6473 cat >>conftest.$ac_ext <<_ACEOF
6474 /* end confdefs.h.  */
6475
6476 /* Override any GCC internal prototype to avoid an error.
6477    Use char because int might match the return type of a GCC
6478    builtin and then its argument prototype would still apply.  */
6479 #ifdef __cplusplus
6480 extern "C"
6481 #endif
6482 char dlopen ();
6483 int
6484 main ()
6485 {
6486 return dlopen ();
6487   ;
6488   return 0;
6489 }
6490 _ACEOF
6491 for ac_lib in '' dl; do
6492   if test -z "$ac_lib"; then
6493     ac_res="none required"
6494   else
6495     ac_res=-l$ac_lib
6496     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6497   fi
6498   rm -f conftest.$ac_objext conftest$ac_exeext
6499 if { (ac_try="$ac_link"
6500 case "(($ac_try" in
6501   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6502   *) ac_try_echo=$ac_try;;
6503 esac
6504 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6505   (eval "$ac_link") 2>conftest.er1
6506   ac_status=$?
6507   grep -v '^ *+' conftest.er1 >conftest.err
6508   rm -f conftest.er1
6509   cat conftest.err >&5
6510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6511   (exit $ac_status); } && {
6512          test -z "$ac_c_werror_flag" ||
6513          test ! -s conftest.err
6514        } && test -s conftest$ac_exeext &&
6515        $as_test_x conftest$ac_exeext; then
6516   ac_cv_search_dlopen=$ac_res
6517 else
6518   echo "$as_me: failed program was:" >&5
6519 sed 's/^/| /' conftest.$ac_ext >&5
6520
6521
6522 fi
6523
6524 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6525       conftest$ac_exeext
6526   if test "${ac_cv_search_dlopen+set}" = set; then
6527   break
6528 fi
6529 done
6530 if test "${ac_cv_search_dlopen+set}" = set; then
6531   :
6532 else
6533   ac_cv_search_dlopen=no
6534 fi
6535 rm conftest.$ac_ext
6536 LIBS=$ac_func_search_save_LIBS
6537 fi
6538 { echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
6539 echo "${ECHO_T}$ac_cv_search_dlopen" >&6; }
6540 ac_res=$ac_cv_search_dlopen
6541 if test "$ac_res" != no; then
6542   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6543
6544 fi
6545
6546 { echo "$as_me:$LINENO: checking for library containing socket" >&5
6547 echo $ECHO_N "checking for library containing socket... $ECHO_C" >&6; }
6548 if test "${ac_cv_search_socket+set}" = set; then
6549   echo $ECHO_N "(cached) $ECHO_C" >&6
6550 else
6551   ac_func_search_save_LIBS=$LIBS
6552 cat >conftest.$ac_ext <<_ACEOF
6553 /* confdefs.h.  */
6554 _ACEOF
6555 cat confdefs.h >>conftest.$ac_ext
6556 cat >>conftest.$ac_ext <<_ACEOF
6557 /* end confdefs.h.  */
6558
6559 /* Override any GCC internal prototype to avoid an error.
6560    Use char because int might match the return type of a GCC
6561    builtin and then its argument prototype would still apply.  */
6562 #ifdef __cplusplus
6563 extern "C"
6564 #endif
6565 char socket ();
6566 int
6567 main ()
6568 {
6569 return socket ();
6570   ;
6571   return 0;
6572 }
6573 _ACEOF
6574 for ac_lib in '' socket wsock32; do
6575   if test -z "$ac_lib"; then
6576     ac_res="none required"
6577   else
6578     ac_res=-l$ac_lib
6579     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6580   fi
6581   rm -f conftest.$ac_objext conftest$ac_exeext
6582 if { (ac_try="$ac_link"
6583 case "(($ac_try" in
6584   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6585   *) ac_try_echo=$ac_try;;
6586 esac
6587 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6588   (eval "$ac_link") 2>conftest.er1
6589   ac_status=$?
6590   grep -v '^ *+' conftest.er1 >conftest.err
6591   rm -f conftest.er1
6592   cat conftest.err >&5
6593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6594   (exit $ac_status); } && {
6595          test -z "$ac_c_werror_flag" ||
6596          test ! -s conftest.err
6597        } && test -s conftest$ac_exeext &&
6598        $as_test_x conftest$ac_exeext; then
6599   ac_cv_search_socket=$ac_res
6600 else
6601   echo "$as_me: failed program was:" >&5
6602 sed 's/^/| /' conftest.$ac_ext >&5
6603
6604
6605 fi
6606
6607 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6608       conftest$ac_exeext
6609   if test "${ac_cv_search_socket+set}" = set; then
6610   break
6611 fi
6612 done
6613 if test "${ac_cv_search_socket+set}" = set; then
6614   :
6615 else
6616   ac_cv_search_socket=no
6617 fi
6618 rm conftest.$ac_ext
6619 LIBS=$ac_func_search_save_LIBS
6620 fi
6621 { echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
6622 echo "${ECHO_T}$ac_cv_search_socket" >&6; }
6623 ac_res=$ac_cv_search_socket
6624 if test "$ac_res" != no; then
6625   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6626
6627 fi
6628
6629 { echo "$as_me:$LINENO: checking for library containing shl_load" >&5
6630 echo $ECHO_N "checking for library containing shl_load... $ECHO_C" >&6; }
6631 if test "${ac_cv_search_shl_load+set}" = set; then
6632   echo $ECHO_N "(cached) $ECHO_C" >&6
6633 else
6634   ac_func_search_save_LIBS=$LIBS
6635 cat >conftest.$ac_ext <<_ACEOF
6636 /* confdefs.h.  */
6637 _ACEOF
6638 cat confdefs.h >>conftest.$ac_ext
6639 cat >>conftest.$ac_ext <<_ACEOF
6640 /* end confdefs.h.  */
6641
6642 /* Override any GCC internal prototype to avoid an error.
6643    Use char because int might match the return type of a GCC
6644    builtin and then its argument prototype would still apply.  */
6645 #ifdef __cplusplus
6646 extern "C"
6647 #endif
6648 char shl_load ();
6649 int
6650 main ()
6651 {
6652 return shl_load ();
6653   ;
6654   return 0;
6655 }
6656 _ACEOF
6657 for ac_lib in '' dld; do
6658   if test -z "$ac_lib"; then
6659     ac_res="none required"
6660   else
6661     ac_res=-l$ac_lib
6662     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6663   fi
6664   rm -f conftest.$ac_objext conftest$ac_exeext
6665 if { (ac_try="$ac_link"
6666 case "(($ac_try" in
6667   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6668   *) ac_try_echo=$ac_try;;
6669 esac
6670 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6671   (eval "$ac_link") 2>conftest.er1
6672   ac_status=$?
6673   grep -v '^ *+' conftest.er1 >conftest.err
6674   rm -f conftest.er1
6675   cat conftest.err >&5
6676   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6677   (exit $ac_status); } && {
6678          test -z "$ac_c_werror_flag" ||
6679          test ! -s conftest.err
6680        } && test -s conftest$ac_exeext &&
6681        $as_test_x conftest$ac_exeext; then
6682   ac_cv_search_shl_load=$ac_res
6683 else
6684   echo "$as_me: failed program was:" >&5
6685 sed 's/^/| /' conftest.$ac_ext >&5
6686
6687
6688 fi
6689
6690 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6691       conftest$ac_exeext
6692   if test "${ac_cv_search_shl_load+set}" = set; then
6693   break
6694 fi
6695 done
6696 if test "${ac_cv_search_shl_load+set}" = set; then
6697   :
6698 else
6699   ac_cv_search_shl_load=no
6700 fi
6701 rm conftest.$ac_ext
6702 LIBS=$ac_func_search_save_LIBS
6703 fi
6704 { echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
6705 echo "${ECHO_T}$ac_cv_search_shl_load" >&6; }
6706 ac_res=$ac_cv_search_shl_load
6707 if test "$ac_res" != no; then
6708   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6709
6710 fi
6711
6712 # We only use libld in port/dynloader/aix.c
6713 case $host_os in
6714      aix*)
6715         { echo "$as_me:$LINENO: checking for library containing ldopen" >&5
6716 echo $ECHO_N "checking for library containing ldopen... $ECHO_C" >&6; }
6717 if test "${ac_cv_search_ldopen+set}" = set; then
6718   echo $ECHO_N "(cached) $ECHO_C" >&6
6719 else
6720   ac_func_search_save_LIBS=$LIBS
6721 cat >conftest.$ac_ext <<_ACEOF
6722 /* confdefs.h.  */
6723 _ACEOF
6724 cat confdefs.h >>conftest.$ac_ext
6725 cat >>conftest.$ac_ext <<_ACEOF
6726 /* end confdefs.h.  */
6727
6728 /* Override any GCC internal prototype to avoid an error.
6729    Use char because int might match the return type of a GCC
6730    builtin and then its argument prototype would still apply.  */
6731 #ifdef __cplusplus
6732 extern "C"
6733 #endif
6734 char ldopen ();
6735 int
6736 main ()
6737 {
6738 return ldopen ();
6739   ;
6740   return 0;
6741 }
6742 _ACEOF
6743 for ac_lib in '' ld; do
6744   if test -z "$ac_lib"; then
6745     ac_res="none required"
6746   else
6747     ac_res=-l$ac_lib
6748     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6749   fi
6750   rm -f conftest.$ac_objext conftest$ac_exeext
6751 if { (ac_try="$ac_link"
6752 case "(($ac_try" in
6753   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6754   *) ac_try_echo=$ac_try;;
6755 esac
6756 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6757   (eval "$ac_link") 2>conftest.er1
6758   ac_status=$?
6759   grep -v '^ *+' conftest.er1 >conftest.err
6760   rm -f conftest.er1
6761   cat conftest.err >&5
6762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6763   (exit $ac_status); } && {
6764          test -z "$ac_c_werror_flag" ||
6765          test ! -s conftest.err
6766        } && test -s conftest$ac_exeext &&
6767        $as_test_x conftest$ac_exeext; then
6768   ac_cv_search_ldopen=$ac_res
6769 else
6770   echo "$as_me: failed program was:" >&5
6771 sed 's/^/| /' conftest.$ac_ext >&5
6772
6773
6774 fi
6775
6776 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6777       conftest$ac_exeext
6778   if test "${ac_cv_search_ldopen+set}" = set; then
6779   break
6780 fi
6781 done
6782 if test "${ac_cv_search_ldopen+set}" = set; then
6783   :
6784 else
6785   ac_cv_search_ldopen=no
6786 fi
6787 rm conftest.$ac_ext
6788 LIBS=$ac_func_search_save_LIBS
6789 fi
6790 { echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
6791 echo "${ECHO_T}$ac_cv_search_ldopen" >&6; }
6792 ac_res=$ac_cv_search_ldopen
6793 if test "$ac_res" != no; then
6794   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6795
6796 fi
6797
6798         ;;
6799 esac
6800 { echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
6801 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6; }
6802 if test "${ac_cv_search_getopt_long+set}" = set; then
6803   echo $ECHO_N "(cached) $ECHO_C" >&6
6804 else
6805   ac_func_search_save_LIBS=$LIBS
6806 cat >conftest.$ac_ext <<_ACEOF
6807 /* confdefs.h.  */
6808 _ACEOF
6809 cat confdefs.h >>conftest.$ac_ext
6810 cat >>conftest.$ac_ext <<_ACEOF
6811 /* end confdefs.h.  */
6812
6813 /* Override any GCC internal prototype to avoid an error.
6814    Use char because int might match the return type of a GCC
6815    builtin and then its argument prototype would still apply.  */
6816 #ifdef __cplusplus
6817 extern "C"
6818 #endif
6819 char getopt_long ();
6820 int
6821 main ()
6822 {
6823 return getopt_long ();
6824   ;
6825   return 0;
6826 }
6827 _ACEOF
6828 for ac_lib in '' getopt gnugetopt; do
6829   if test -z "$ac_lib"; then
6830     ac_res="none required"
6831   else
6832     ac_res=-l$ac_lib
6833     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6834   fi
6835   rm -f conftest.$ac_objext conftest$ac_exeext
6836 if { (ac_try="$ac_link"
6837 case "(($ac_try" in
6838   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6839   *) ac_try_echo=$ac_try;;
6840 esac
6841 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6842   (eval "$ac_link") 2>conftest.er1
6843   ac_status=$?
6844   grep -v '^ *+' conftest.er1 >conftest.err
6845   rm -f conftest.er1
6846   cat conftest.err >&5
6847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6848   (exit $ac_status); } && {
6849          test -z "$ac_c_werror_flag" ||
6850          test ! -s conftest.err
6851        } && test -s conftest$ac_exeext &&
6852        $as_test_x conftest$ac_exeext; then
6853   ac_cv_search_getopt_long=$ac_res
6854 else
6855   echo "$as_me: failed program was:" >&5
6856 sed 's/^/| /' conftest.$ac_ext >&5
6857
6858
6859 fi
6860
6861 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6862       conftest$ac_exeext
6863   if test "${ac_cv_search_getopt_long+set}" = set; then
6864   break
6865 fi
6866 done
6867 if test "${ac_cv_search_getopt_long+set}" = set; then
6868   :
6869 else
6870   ac_cv_search_getopt_long=no
6871 fi
6872 rm conftest.$ac_ext
6873 LIBS=$ac_func_search_save_LIBS
6874 fi
6875 { echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
6876 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6; }
6877 ac_res=$ac_cv_search_getopt_long
6878 if test "$ac_res" != no; then
6879   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6880
6881 fi
6882
6883 { echo "$as_me:$LINENO: checking for library containing crypt" >&5
6884 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6; }
6885 if test "${ac_cv_search_crypt+set}" = set; then
6886   echo $ECHO_N "(cached) $ECHO_C" >&6
6887 else
6888   ac_func_search_save_LIBS=$LIBS
6889 cat >conftest.$ac_ext <<_ACEOF
6890 /* confdefs.h.  */
6891 _ACEOF
6892 cat confdefs.h >>conftest.$ac_ext
6893 cat >>conftest.$ac_ext <<_ACEOF
6894 /* end confdefs.h.  */
6895
6896 /* Override any GCC internal prototype to avoid an error.
6897    Use char because int might match the return type of a GCC
6898    builtin and then its argument prototype would still apply.  */
6899 #ifdef __cplusplus
6900 extern "C"
6901 #endif
6902 char crypt ();
6903 int
6904 main ()
6905 {
6906 return crypt ();
6907   ;
6908   return 0;
6909 }
6910 _ACEOF
6911 for ac_lib in '' crypt; do
6912   if test -z "$ac_lib"; then
6913     ac_res="none required"
6914   else
6915     ac_res=-l$ac_lib
6916     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6917   fi
6918   rm -f conftest.$ac_objext conftest$ac_exeext
6919 if { (ac_try="$ac_link"
6920 case "(($ac_try" in
6921   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6922   *) ac_try_echo=$ac_try;;
6923 esac
6924 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6925   (eval "$ac_link") 2>conftest.er1
6926   ac_status=$?
6927   grep -v '^ *+' conftest.er1 >conftest.err
6928   rm -f conftest.er1
6929   cat conftest.err >&5
6930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6931   (exit $ac_status); } && {
6932          test -z "$ac_c_werror_flag" ||
6933          test ! -s conftest.err
6934        } && test -s conftest$ac_exeext &&
6935        $as_test_x conftest$ac_exeext; then
6936   ac_cv_search_crypt=$ac_res
6937 else
6938   echo "$as_me: failed program was:" >&5
6939 sed 's/^/| /' conftest.$ac_ext >&5
6940
6941
6942 fi
6943
6944 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6945       conftest$ac_exeext
6946   if test "${ac_cv_search_crypt+set}" = set; then
6947   break
6948 fi
6949 done
6950 if test "${ac_cv_search_crypt+set}" = set; then
6951   :
6952 else
6953   ac_cv_search_crypt=no
6954 fi
6955 rm conftest.$ac_ext
6956 LIBS=$ac_func_search_save_LIBS
6957 fi
6958 { echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
6959 echo "${ECHO_T}$ac_cv_search_crypt" >&6; }
6960 ac_res=$ac_cv_search_crypt
6961 if test "$ac_res" != no; then
6962   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6963
6964 fi
6965
6966 # Solaris:
6967 { echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
6968 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6; }
6969 if test "${ac_cv_search_fdatasync+set}" = set; then
6970   echo $ECHO_N "(cached) $ECHO_C" >&6
6971 else
6972   ac_func_search_save_LIBS=$LIBS
6973 cat >conftest.$ac_ext <<_ACEOF
6974 /* confdefs.h.  */
6975 _ACEOF
6976 cat confdefs.h >>conftest.$ac_ext
6977 cat >>conftest.$ac_ext <<_ACEOF
6978 /* end confdefs.h.  */
6979
6980 /* Override any GCC internal prototype to avoid an error.
6981    Use char because int might match the return type of a GCC
6982    builtin and then its argument prototype would still apply.  */
6983 #ifdef __cplusplus
6984 extern "C"
6985 #endif
6986 char fdatasync ();
6987 int
6988 main ()
6989 {
6990 return fdatasync ();
6991   ;
6992   return 0;
6993 }
6994 _ACEOF
6995 for ac_lib in '' rt posix4; do
6996   if test -z "$ac_lib"; then
6997     ac_res="none required"
6998   else
6999     ac_res=-l$ac_lib
7000     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7001   fi
7002   rm -f conftest.$ac_objext conftest$ac_exeext
7003 if { (ac_try="$ac_link"
7004 case "(($ac_try" in
7005   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7006   *) ac_try_echo=$ac_try;;
7007 esac
7008 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7009   (eval "$ac_link") 2>conftest.er1
7010   ac_status=$?
7011   grep -v '^ *+' conftest.er1 >conftest.err
7012   rm -f conftest.er1
7013   cat conftest.err >&5
7014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7015   (exit $ac_status); } && {
7016          test -z "$ac_c_werror_flag" ||
7017          test ! -s conftest.err
7018        } && test -s conftest$ac_exeext &&
7019        $as_test_x conftest$ac_exeext; then
7020   ac_cv_search_fdatasync=$ac_res
7021 else
7022   echo "$as_me: failed program was:" >&5
7023 sed 's/^/| /' conftest.$ac_ext >&5
7024
7025
7026 fi
7027
7028 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7029       conftest$ac_exeext
7030   if test "${ac_cv_search_fdatasync+set}" = set; then
7031   break
7032 fi
7033 done
7034 if test "${ac_cv_search_fdatasync+set}" = set; then
7035   :
7036 else
7037   ac_cv_search_fdatasync=no
7038 fi
7039 rm conftest.$ac_ext
7040 LIBS=$ac_func_search_save_LIBS
7041 fi
7042 { echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
7043 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6; }
7044 ac_res=$ac_cv_search_fdatasync
7045 if test "$ac_res" != no; then
7046   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7047
7048 fi
7049
7050 # Cygwin:
7051 { echo "$as_me:$LINENO: checking for library containing shmget" >&5
7052 echo $ECHO_N "checking for library containing shmget... $ECHO_C" >&6; }
7053 if test "${ac_cv_search_shmget+set}" = set; then
7054   echo $ECHO_N "(cached) $ECHO_C" >&6
7055 else
7056   ac_func_search_save_LIBS=$LIBS
7057 cat >conftest.$ac_ext <<_ACEOF
7058 /* confdefs.h.  */
7059 _ACEOF
7060 cat confdefs.h >>conftest.$ac_ext
7061 cat >>conftest.$ac_ext <<_ACEOF
7062 /* end confdefs.h.  */
7063
7064 /* Override any GCC internal prototype to avoid an error.
7065    Use char because int might match the return type of a GCC
7066    builtin and then its argument prototype would still apply.  */
7067 #ifdef __cplusplus
7068 extern "C"
7069 #endif
7070 char shmget ();
7071 int
7072 main ()
7073 {
7074 return shmget ();
7075   ;
7076   return 0;
7077 }
7078 _ACEOF
7079 for ac_lib in '' cygipc; do
7080   if test -z "$ac_lib"; then
7081     ac_res="none required"
7082   else
7083     ac_res=-l$ac_lib
7084     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7085   fi
7086   rm -f conftest.$ac_objext conftest$ac_exeext
7087 if { (ac_try="$ac_link"
7088 case "(($ac_try" in
7089   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7090   *) ac_try_echo=$ac_try;;
7091 esac
7092 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7093   (eval "$ac_link") 2>conftest.er1
7094   ac_status=$?
7095   grep -v '^ *+' conftest.er1 >conftest.err
7096   rm -f conftest.er1
7097   cat conftest.err >&5
7098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7099   (exit $ac_status); } && {
7100          test -z "$ac_c_werror_flag" ||
7101          test ! -s conftest.err
7102        } && test -s conftest$ac_exeext &&
7103        $as_test_x conftest$ac_exeext; then
7104   ac_cv_search_shmget=$ac_res
7105 else
7106   echo "$as_me: failed program was:" >&5
7107 sed 's/^/| /' conftest.$ac_ext >&5
7108
7109
7110 fi
7111
7112 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7113       conftest$ac_exeext
7114   if test "${ac_cv_search_shmget+set}" = set; then
7115   break
7116 fi
7117 done
7118 if test "${ac_cv_search_shmget+set}" = set; then
7119   :
7120 else
7121   ac_cv_search_shmget=no
7122 fi
7123 rm conftest.$ac_ext
7124 LIBS=$ac_func_search_save_LIBS
7125 fi
7126 { echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
7127 echo "${ECHO_T}$ac_cv_search_shmget" >&6; }
7128 ac_res=$ac_cv_search_shmget
7129 if test "$ac_res" != no; then
7130   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7131
7132 fi
7133
7134
7135 if test "$with_readline" = yes; then
7136
7137
7138 if test "${pgac_cv_check_readline+set}" = set; then
7139   echo $ECHO_N "(cached) $ECHO_C" >&6
7140 else
7141   pgac_cv_check_readline=no
7142 pgac_save_LIBS=$LIBS
7143 if test x"$with_libedit_preferred" != x"yes"
7144 then    READLINE_ORDER="-lreadline -ledit"
7145 else    READLINE_ORDER="-ledit -lreadline"
7146 fi
7147 for pgac_rllib in $READLINE_ORDER ; do
7148   { echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
7149 echo $ECHO_N "checking for ${pgac_rllib}... $ECHO_C" >&6; }
7150   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
7151     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
7152     cat >conftest.$ac_ext <<_ACEOF
7153 /* confdefs.h.  */
7154 _ACEOF
7155 cat confdefs.h >>conftest.$ac_ext
7156 cat >>conftest.$ac_ext <<_ACEOF
7157 /* end confdefs.h.  */
7158
7159 /* Override any GCC internal prototype to avoid an error.
7160    Use char because int might match the return type of a GCC
7161    builtin and then its argument prototype would still apply.  */
7162 #ifdef __cplusplus
7163 extern "C"
7164 #endif
7165 char readline ();
7166 int
7167 main ()
7168 {
7169 return readline ();
7170   ;
7171   return 0;
7172 }
7173 _ACEOF
7174 rm -f conftest.$ac_objext conftest$ac_exeext
7175 if { (ac_try="$ac_link"
7176 case "(($ac_try" in
7177   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7178   *) ac_try_echo=$ac_try;;
7179 esac
7180 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7181   (eval "$ac_link") 2>conftest.er1
7182   ac_status=$?
7183   grep -v '^ *+' conftest.er1 >conftest.err
7184   rm -f conftest.er1
7185   cat conftest.err >&5
7186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7187   (exit $ac_status); } && {
7188          test -z "$ac_c_werror_flag" ||
7189          test ! -s conftest.err
7190        } && test -s conftest$ac_exeext &&
7191        $as_test_x conftest$ac_exeext; then
7192
7193       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
7194       # recognize dependent libraries; assume curses is needed if we didn't
7195       # find any dependency.
7196       case $host_os in
7197         netbsd* | openbsd* | irix*)
7198           if test x"$pgac_lib" = x"" ; then
7199             pgac_lib=" -lcurses"
7200           fi ;;
7201       esac
7202
7203       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
7204       break
7205
7206 else
7207   echo "$as_me: failed program was:" >&5
7208 sed 's/^/| /' conftest.$ac_ext >&5
7209
7210
7211 fi
7212
7213 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7214       conftest$ac_exeext conftest.$ac_ext
7215   done
7216   if test "$pgac_cv_check_readline" != no ; then
7217     { echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
7218 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6; }
7219     break
7220   else
7221     { echo "$as_me:$LINENO: result: no" >&5
7222 echo "${ECHO_T}no" >&6; }
7223   fi
7224 done
7225 LIBS=$pgac_save_LIBS
7226
7227 fi
7228
7229 if test "$pgac_cv_check_readline" != no ; then
7230   LIBS="$pgac_cv_check_readline $LIBS"
7231
7232 cat >>confdefs.h <<\_ACEOF
7233 #define HAVE_LIBREADLINE 1
7234 _ACEOF
7235
7236 fi
7237
7238
7239   if test x"$pgac_cv_check_readline" = x"no"; then
7240     { { echo "$as_me:$LINENO: error: readline library not found
7241 If you have readline already installed, see config.log for details on the
7242 failure.  It is possible the compiler isn't looking in the proper directory.
7243 Use --without-readline to disable readline support." >&5
7244 echo "$as_me: error: readline library not found
7245 If you have readline already installed, see config.log for details on the
7246 failure.  It is possible the compiler isn't looking in the proper directory.
7247 Use --without-readline to disable readline support." >&2;}
7248    { (exit 1); exit 1; }; }
7249   fi
7250 fi
7251
7252 if test "$with_zlib" = yes; then
7253
7254 { echo "$as_me:$LINENO: checking for inflate in -lz" >&5
7255 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6; }
7256 if test "${ac_cv_lib_z_inflate+set}" = set; then
7257   echo $ECHO_N "(cached) $ECHO_C" >&6
7258 else
7259   ac_check_lib_save_LIBS=$LIBS
7260 LIBS="-lz  $LIBS"
7261 cat >conftest.$ac_ext <<_ACEOF
7262 /* confdefs.h.  */
7263 _ACEOF
7264 cat confdefs.h >>conftest.$ac_ext
7265 cat >>conftest.$ac_ext <<_ACEOF
7266 /* end confdefs.h.  */
7267
7268 /* Override any GCC internal prototype to avoid an error.
7269    Use char because int might match the return type of a GCC
7270    builtin and then its argument prototype would still apply.  */
7271 #ifdef __cplusplus
7272 extern "C"
7273 #endif
7274 char inflate ();
7275 int
7276 main ()
7277 {
7278 return inflate ();
7279   ;
7280   return 0;
7281 }
7282 _ACEOF
7283 rm -f conftest.$ac_objext conftest$ac_exeext
7284 if { (ac_try="$ac_link"
7285 case "(($ac_try" in
7286   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7287   *) ac_try_echo=$ac_try;;
7288 esac
7289 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7290   (eval "$ac_link") 2>conftest.er1
7291   ac_status=$?
7292   grep -v '^ *+' conftest.er1 >conftest.err
7293   rm -f conftest.er1
7294   cat conftest.err >&5
7295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7296   (exit $ac_status); } && {
7297          test -z "$ac_c_werror_flag" ||
7298          test ! -s conftest.err
7299        } && test -s conftest$ac_exeext &&
7300        $as_test_x conftest$ac_exeext; then
7301   ac_cv_lib_z_inflate=yes
7302 else
7303   echo "$as_me: failed program was:" >&5
7304 sed 's/^/| /' conftest.$ac_ext >&5
7305
7306         ac_cv_lib_z_inflate=no
7307 fi
7308
7309 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7310       conftest$ac_exeext conftest.$ac_ext
7311 LIBS=$ac_check_lib_save_LIBS
7312 fi
7313 { echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
7314 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6; }
7315 if test $ac_cv_lib_z_inflate = yes; then
7316   cat >>confdefs.h <<_ACEOF
7317 #define HAVE_LIBZ 1
7318 _ACEOF
7319
7320   LIBS="-lz $LIBS"
7321
7322 else
7323   { { echo "$as_me:$LINENO: error: zlib library not found
7324 If you have zlib already installed, see config.log for details on the
7325 failure.  It is possible the compiler isn't looking in the proper directory.
7326 Use --without-zlib to disable zlib support." >&5
7327 echo "$as_me: error: zlib library not found
7328 If you have zlib already installed, see config.log for details on the
7329 failure.  It is possible the compiler isn't looking in the proper directory.
7330 Use --without-zlib to disable zlib support." >&2;}
7331    { (exit 1); exit 1; }; }
7332 fi
7333
7334 fi
7335
7336 if test "$enable_spinlocks" = yes; then
7337
7338 cat >>confdefs.h <<\_ACEOF
7339 #define HAVE_SPINLOCKS 1
7340 _ACEOF
7341
7342 else
7343   { echo "$as_me:$LINENO: WARNING:
7344 *** Not using spinlocks will cause poor performance." >&5
7345 echo "$as_me: WARNING:
7346 *** Not using spinlocks will cause poor performance." >&2;}
7347 fi
7348
7349 if test "$with_gssapi" = yes ; then
7350   if test "$PORTNAME" != "win32"; then
7351     { echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
7352 echo $ECHO_N "checking for library containing gss_init_sec_context... $ECHO_C" >&6; }
7353 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
7354   echo $ECHO_N "(cached) $ECHO_C" >&6
7355 else
7356   ac_func_search_save_LIBS=$LIBS
7357 cat >conftest.$ac_ext <<_ACEOF
7358 /* confdefs.h.  */
7359 _ACEOF
7360 cat confdefs.h >>conftest.$ac_ext
7361 cat >>conftest.$ac_ext <<_ACEOF
7362 /* end confdefs.h.  */
7363
7364 /* Override any GCC internal prototype to avoid an error.
7365    Use char because int might match the return type of a GCC
7366    builtin and then its argument prototype would still apply.  */
7367 #ifdef __cplusplus
7368 extern "C"
7369 #endif
7370 char gss_init_sec_context ();
7371 int
7372 main ()
7373 {
7374 return gss_init_sec_context ();
7375   ;
7376   return 0;
7377 }
7378 _ACEOF
7379 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
7380   if test -z "$ac_lib"; then
7381     ac_res="none required"
7382   else
7383     ac_res=-l$ac_lib
7384     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7385   fi
7386   rm -f conftest.$ac_objext conftest$ac_exeext
7387 if { (ac_try="$ac_link"
7388 case "(($ac_try" in
7389   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7390   *) ac_try_echo=$ac_try;;
7391 esac
7392 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7393   (eval "$ac_link") 2>conftest.er1
7394   ac_status=$?
7395   grep -v '^ *+' conftest.er1 >conftest.err
7396   rm -f conftest.er1
7397   cat conftest.err >&5
7398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7399   (exit $ac_status); } && {
7400          test -z "$ac_c_werror_flag" ||
7401          test ! -s conftest.err
7402        } && test -s conftest$ac_exeext &&
7403        $as_test_x conftest$ac_exeext; then
7404   ac_cv_search_gss_init_sec_context=$ac_res
7405 else
7406   echo "$as_me: failed program was:" >&5
7407 sed 's/^/| /' conftest.$ac_ext >&5
7408
7409
7410 fi
7411
7412 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7413       conftest$ac_exeext
7414   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
7415   break
7416 fi
7417 done
7418 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
7419   :
7420 else
7421   ac_cv_search_gss_init_sec_context=no
7422 fi
7423 rm conftest.$ac_ext
7424 LIBS=$ac_func_search_save_LIBS
7425 fi
7426 { echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
7427 echo "${ECHO_T}$ac_cv_search_gss_init_sec_context" >&6; }
7428 ac_res=$ac_cv_search_gss_init_sec_context
7429 if test "$ac_res" != no; then
7430   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7431
7432 else
7433   { { echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
7434 echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
7435    { (exit 1); exit 1; }; }
7436 fi
7437
7438   else
7439     LIBS="$LIBS -lgssapi32"
7440   fi
7441 fi
7442
7443 if test "$with_krb5" = yes ; then
7444   if test "$PORTNAME" != "win32"; then
7445      { echo "$as_me:$LINENO: checking for library containing com_err" >&5
7446 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6; }
7447 if test "${ac_cv_search_com_err+set}" = set; then
7448   echo $ECHO_N "(cached) $ECHO_C" >&6
7449 else
7450   ac_func_search_save_LIBS=$LIBS
7451 cat >conftest.$ac_ext <<_ACEOF
7452 /* confdefs.h.  */
7453 _ACEOF
7454 cat confdefs.h >>conftest.$ac_ext
7455 cat >>conftest.$ac_ext <<_ACEOF
7456 /* end confdefs.h.  */
7457
7458 /* Override any GCC internal prototype to avoid an error.
7459    Use char because int might match the return type of a GCC
7460    builtin and then its argument prototype would still apply.  */
7461 #ifdef __cplusplus
7462 extern "C"
7463 #endif
7464 char com_err ();
7465 int
7466 main ()
7467 {
7468 return com_err ();
7469   ;
7470   return 0;
7471 }
7472 _ACEOF
7473 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err; do
7474   if test -z "$ac_lib"; then
7475     ac_res="none required"
7476   else
7477     ac_res=-l$ac_lib
7478     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7479   fi
7480   rm -f conftest.$ac_objext conftest$ac_exeext
7481 if { (ac_try="$ac_link"
7482 case "(($ac_try" in
7483   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7484   *) ac_try_echo=$ac_try;;
7485 esac
7486 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7487   (eval "$ac_link") 2>conftest.er1
7488   ac_status=$?
7489   grep -v '^ *+' conftest.er1 >conftest.err
7490   rm -f conftest.er1
7491   cat conftest.err >&5
7492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7493   (exit $ac_status); } && {
7494          test -z "$ac_c_werror_flag" ||
7495          test ! -s conftest.err
7496        } && test -s conftest$ac_exeext &&
7497        $as_test_x conftest$ac_exeext; then
7498   ac_cv_search_com_err=$ac_res
7499 else
7500   echo "$as_me: failed program was:" >&5
7501 sed 's/^/| /' conftest.$ac_ext >&5
7502
7503
7504 fi
7505
7506 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7507       conftest$ac_exeext
7508   if test "${ac_cv_search_com_err+set}" = set; then
7509   break
7510 fi
7511 done
7512 if test "${ac_cv_search_com_err+set}" = set; then
7513   :
7514 else
7515   ac_cv_search_com_err=no
7516 fi
7517 rm conftest.$ac_ext
7518 LIBS=$ac_func_search_save_LIBS
7519 fi
7520 { echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
7521 echo "${ECHO_T}$ac_cv_search_com_err" >&6; }
7522 ac_res=$ac_cv_search_com_err
7523 if test "$ac_res" != no; then
7524   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7525
7526 else
7527   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
7528 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
7529    { (exit 1); exit 1; }; }
7530 fi
7531
7532      { echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
7533 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6; }
7534 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
7535   echo $ECHO_N "(cached) $ECHO_C" >&6
7536 else
7537   ac_func_search_save_LIBS=$LIBS
7538 cat >conftest.$ac_ext <<_ACEOF
7539 /* confdefs.h.  */
7540 _ACEOF
7541 cat confdefs.h >>conftest.$ac_ext
7542 cat >>conftest.$ac_ext <<_ACEOF
7543 /* end confdefs.h.  */
7544
7545 /* Override any GCC internal prototype to avoid an error.
7546    Use char because int might match the return type of a GCC
7547    builtin and then its argument prototype would still apply.  */
7548 #ifdef __cplusplus
7549 extern "C"
7550 #endif
7551 char krb5_sendauth ();
7552 int
7553 main ()
7554 {
7555 return krb5_sendauth ();
7556   ;
7557   return 0;
7558 }
7559 _ACEOF
7560 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
7561   if test -z "$ac_lib"; then
7562     ac_res="none required"
7563   else
7564     ac_res=-l$ac_lib
7565     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7566   fi
7567   rm -f conftest.$ac_objext conftest$ac_exeext
7568 if { (ac_try="$ac_link"
7569 case "(($ac_try" in
7570   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7571   *) ac_try_echo=$ac_try;;
7572 esac
7573 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7574   (eval "$ac_link") 2>conftest.er1
7575   ac_status=$?
7576   grep -v '^ *+' conftest.er1 >conftest.err
7577   rm -f conftest.er1
7578   cat conftest.err >&5
7579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7580   (exit $ac_status); } && {
7581          test -z "$ac_c_werror_flag" ||
7582          test ! -s conftest.err
7583        } && test -s conftest$ac_exeext &&
7584        $as_test_x conftest$ac_exeext; then
7585   ac_cv_search_krb5_sendauth=$ac_res
7586 else
7587   echo "$as_me: failed program was:" >&5
7588 sed 's/^/| /' conftest.$ac_ext >&5
7589
7590
7591 fi
7592
7593 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7594       conftest$ac_exeext
7595   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
7596   break
7597 fi
7598 done
7599 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
7600   :
7601 else
7602   ac_cv_search_krb5_sendauth=no
7603 fi
7604 rm conftest.$ac_ext
7605 LIBS=$ac_func_search_save_LIBS
7606 fi
7607 { echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
7608 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6; }
7609 ac_res=$ac_cv_search_krb5_sendauth
7610 if test "$ac_res" != no; then
7611   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7612
7613 else
7614   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
7615 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
7616    { (exit 1); exit 1; }; }
7617 fi
7618
7619   else
7620      { echo "$as_me:$LINENO: checking for library containing com_err" >&5
7621 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6; }
7622 if test "${ac_cv_search_com_err+set}" = set; then
7623   echo $ECHO_N "(cached) $ECHO_C" >&6
7624 else
7625   ac_func_search_save_LIBS=$LIBS
7626 cat >conftest.$ac_ext <<_ACEOF
7627 /* confdefs.h.  */
7628 _ACEOF
7629 cat confdefs.h >>conftest.$ac_ext
7630 cat >>conftest.$ac_ext <<_ACEOF
7631 /* end confdefs.h.  */
7632
7633 /* Override any GCC internal prototype to avoid an error.
7634    Use char because int might match the return type of a GCC
7635    builtin and then its argument prototype would still apply.  */
7636 #ifdef __cplusplus
7637 extern "C"
7638 #endif
7639 char com_err ();
7640 int
7641 main ()
7642 {
7643 return com_err ();
7644   ;
7645   return 0;
7646 }
7647 _ACEOF
7648 for ac_lib in '' 'comerr32 -lkrb5_32'; do
7649   if test -z "$ac_lib"; then
7650     ac_res="none required"
7651   else
7652     ac_res=-l$ac_lib
7653     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7654   fi
7655   rm -f conftest.$ac_objext conftest$ac_exeext
7656 if { (ac_try="$ac_link"
7657 case "(($ac_try" in
7658   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7659   *) ac_try_echo=$ac_try;;
7660 esac
7661 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7662   (eval "$ac_link") 2>conftest.er1
7663   ac_status=$?
7664   grep -v '^ *+' conftest.er1 >conftest.err
7665   rm -f conftest.er1
7666   cat conftest.err >&5
7667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7668   (exit $ac_status); } && {
7669          test -z "$ac_c_werror_flag" ||
7670          test ! -s conftest.err
7671        } && test -s conftest$ac_exeext &&
7672        $as_test_x conftest$ac_exeext; then
7673   ac_cv_search_com_err=$ac_res
7674 else
7675   echo "$as_me: failed program was:" >&5
7676 sed 's/^/| /' conftest.$ac_ext >&5
7677
7678
7679 fi
7680
7681 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7682       conftest$ac_exeext
7683   if test "${ac_cv_search_com_err+set}" = set; then
7684   break
7685 fi
7686 done
7687 if test "${ac_cv_search_com_err+set}" = set; then
7688   :
7689 else
7690   ac_cv_search_com_err=no
7691 fi
7692 rm conftest.$ac_ext
7693 LIBS=$ac_func_search_save_LIBS
7694 fi
7695 { echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
7696 echo "${ECHO_T}$ac_cv_search_com_err" >&6; }
7697 ac_res=$ac_cv_search_com_err
7698 if test "$ac_res" != no; then
7699   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7700
7701 else
7702   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
7703 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
7704    { (exit 1); exit 1; }; }
7705 fi
7706
7707   fi
7708 fi
7709
7710 if test "$with_openssl" = yes ; then
7711     if test "$PORTNAME" != "win32"; then
7712
7713 { echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
7714 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6; }
7715 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
7716   echo $ECHO_N "(cached) $ECHO_C" >&6
7717 else
7718   ac_check_lib_save_LIBS=$LIBS
7719 LIBS="-lcrypto  $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 CRYPTO_new_ex_data ();
7734 int
7735 main ()
7736 {
7737 return CRYPTO_new_ex_data ();
7738   ;
7739   return 0;
7740 }
7741 _ACEOF
7742 rm -f conftest.$ac_objext conftest$ac_exeext
7743 if { (ac_try="$ac_link"
7744 case "(($ac_try" in
7745   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7746   *) ac_try_echo=$ac_try;;
7747 esac
7748 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7749   (eval "$ac_link") 2>conftest.er1
7750   ac_status=$?
7751   grep -v '^ *+' conftest.er1 >conftest.err
7752   rm -f conftest.er1
7753   cat conftest.err >&5
7754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7755   (exit $ac_status); } && {
7756          test -z "$ac_c_werror_flag" ||
7757          test ! -s conftest.err
7758        } && test -s conftest$ac_exeext &&
7759        $as_test_x conftest$ac_exeext; then
7760   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
7761 else
7762   echo "$as_me: failed program was:" >&5
7763 sed 's/^/| /' conftest.$ac_ext >&5
7764
7765         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
7766 fi
7767
7768 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7769       conftest$ac_exeext conftest.$ac_ext
7770 LIBS=$ac_check_lib_save_LIBS
7771 fi
7772 { echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
7773 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
7774 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
7775   cat >>confdefs.h <<_ACEOF
7776 #define HAVE_LIBCRYPTO 1
7777 _ACEOF
7778
7779   LIBS="-lcrypto $LIBS"
7780
7781 else
7782   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
7783 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
7784    { (exit 1); exit 1; }; }
7785 fi
7786
7787
7788 { echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
7789 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6; }
7790 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
7791   echo $ECHO_N "(cached) $ECHO_C" >&6
7792 else
7793   ac_check_lib_save_LIBS=$LIBS
7794 LIBS="-lssl  $LIBS"
7795 cat >conftest.$ac_ext <<_ACEOF
7796 /* confdefs.h.  */
7797 _ACEOF
7798 cat confdefs.h >>conftest.$ac_ext
7799 cat >>conftest.$ac_ext <<_ACEOF
7800 /* end confdefs.h.  */
7801
7802 /* Override any GCC internal prototype to avoid an error.
7803    Use char because int might match the return type of a GCC
7804    builtin and then its argument prototype would still apply.  */
7805 #ifdef __cplusplus
7806 extern "C"
7807 #endif
7808 char SSL_library_init ();
7809 int
7810 main ()
7811 {
7812 return SSL_library_init ();
7813   ;
7814   return 0;
7815 }
7816 _ACEOF
7817 rm -f conftest.$ac_objext conftest$ac_exeext
7818 if { (ac_try="$ac_link"
7819 case "(($ac_try" in
7820   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7821   *) ac_try_echo=$ac_try;;
7822 esac
7823 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7824   (eval "$ac_link") 2>conftest.er1
7825   ac_status=$?
7826   grep -v '^ *+' conftest.er1 >conftest.err
7827   rm -f conftest.er1
7828   cat conftest.err >&5
7829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7830   (exit $ac_status); } && {
7831          test -z "$ac_c_werror_flag" ||
7832          test ! -s conftest.err
7833        } && test -s conftest$ac_exeext &&
7834        $as_test_x conftest$ac_exeext; then
7835   ac_cv_lib_ssl_SSL_library_init=yes
7836 else
7837   echo "$as_me: failed program was:" >&5
7838 sed 's/^/| /' conftest.$ac_ext >&5
7839
7840         ac_cv_lib_ssl_SSL_library_init=no
7841 fi
7842
7843 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7844       conftest$ac_exeext conftest.$ac_ext
7845 LIBS=$ac_check_lib_save_LIBS
7846 fi
7847 { echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
7848 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6; }
7849 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
7850   cat >>confdefs.h <<_ACEOF
7851 #define HAVE_LIBSSL 1
7852 _ACEOF
7853
7854   LIBS="-lssl $LIBS"
7855
7856 else
7857   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
7858 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
7859    { (exit 1); exit 1; }; }
7860 fi
7861
7862   else
7863
7864 { echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
7865 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6; }
7866 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
7867   echo $ECHO_N "(cached) $ECHO_C" >&6
7868 else
7869   ac_check_lib_save_LIBS=$LIBS
7870 LIBS="-leay32  $LIBS"
7871 cat >conftest.$ac_ext <<_ACEOF
7872 /* confdefs.h.  */
7873 _ACEOF
7874 cat confdefs.h >>conftest.$ac_ext
7875 cat >>conftest.$ac_ext <<_ACEOF
7876 /* end confdefs.h.  */
7877
7878 /* Override any GCC internal prototype to avoid an error.
7879    Use char because int might match the return type of a GCC
7880    builtin and then its argument prototype would still apply.  */
7881 #ifdef __cplusplus
7882 extern "C"
7883 #endif
7884 char CRYPTO_new_ex_data ();
7885 int
7886 main ()
7887 {
7888 return CRYPTO_new_ex_data ();
7889   ;
7890   return 0;
7891 }
7892 _ACEOF
7893 rm -f conftest.$ac_objext conftest$ac_exeext
7894 if { (ac_try="$ac_link"
7895 case "(($ac_try" in
7896   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7897   *) ac_try_echo=$ac_try;;
7898 esac
7899 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7900   (eval "$ac_link") 2>conftest.er1
7901   ac_status=$?
7902   grep -v '^ *+' conftest.er1 >conftest.err
7903   rm -f conftest.er1
7904   cat conftest.err >&5
7905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7906   (exit $ac_status); } && {
7907          test -z "$ac_c_werror_flag" ||
7908          test ! -s conftest.err
7909        } && test -s conftest$ac_exeext &&
7910        $as_test_x conftest$ac_exeext; then
7911   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
7912 else
7913   echo "$as_me: failed program was:" >&5
7914 sed 's/^/| /' conftest.$ac_ext >&5
7915
7916         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
7917 fi
7918
7919 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7920       conftest$ac_exeext conftest.$ac_ext
7921 LIBS=$ac_check_lib_save_LIBS
7922 fi
7923 { echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
7924 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
7925 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
7926   cat >>confdefs.h <<_ACEOF
7927 #define HAVE_LIBEAY32 1
7928 _ACEOF
7929
7930   LIBS="-leay32 $LIBS"
7931
7932 else
7933   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
7934 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
7935    { (exit 1); exit 1; }; }
7936 fi
7937
7938
7939 { echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
7940 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6; }
7941 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
7942   echo $ECHO_N "(cached) $ECHO_C" >&6
7943 else
7944   ac_check_lib_save_LIBS=$LIBS
7945 LIBS="-lssleay32  $LIBS"
7946 cat >conftest.$ac_ext <<_ACEOF
7947 /* confdefs.h.  */
7948 _ACEOF
7949 cat confdefs.h >>conftest.$ac_ext
7950 cat >>conftest.$ac_ext <<_ACEOF
7951 /* end confdefs.h.  */
7952
7953 /* Override any GCC internal prototype to avoid an error.
7954    Use char because int might match the return type of a GCC
7955    builtin and then its argument prototype would still apply.  */
7956 #ifdef __cplusplus
7957 extern "C"
7958 #endif
7959 char SSL_library_init ();
7960 int
7961 main ()
7962 {
7963 return SSL_library_init ();
7964   ;
7965   return 0;
7966 }
7967 _ACEOF
7968 rm -f conftest.$ac_objext conftest$ac_exeext
7969 if { (ac_try="$ac_link"
7970 case "(($ac_try" in
7971   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7972   *) ac_try_echo=$ac_try;;
7973 esac
7974 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7975   (eval "$ac_link") 2>conftest.er1
7976   ac_status=$?
7977   grep -v '^ *+' conftest.er1 >conftest.err
7978   rm -f conftest.er1
7979   cat conftest.err >&5
7980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7981   (exit $ac_status); } && {
7982          test -z "$ac_c_werror_flag" ||
7983          test ! -s conftest.err
7984        } && test -s conftest$ac_exeext &&
7985        $as_test_x conftest$ac_exeext; then
7986   ac_cv_lib_ssleay32_SSL_library_init=yes
7987 else
7988   echo "$as_me: failed program was:" >&5
7989 sed 's/^/| /' conftest.$ac_ext >&5
7990
7991         ac_cv_lib_ssleay32_SSL_library_init=no
7992 fi
7993
7994 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7995       conftest$ac_exeext conftest.$ac_ext
7996 LIBS=$ac_check_lib_save_LIBS
7997 fi
7998 { echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7999 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
8000 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
8001   cat >>confdefs.h <<_ACEOF
8002 #define HAVE_LIBSSLEAY32 1
8003 _ACEOF
8004
8005   LIBS="-lssleay32 $LIBS"
8006
8007 else
8008   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
8009 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
8010    { (exit 1); exit 1; }; }
8011 fi
8012
8013   fi
8014 fi
8015
8016 if test "$with_pam" = yes ; then
8017
8018 { echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
8019 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6; }
8020 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
8021   echo $ECHO_N "(cached) $ECHO_C" >&6
8022 else
8023   ac_check_lib_save_LIBS=$LIBS
8024 LIBS="-lpam  $LIBS"
8025 cat >conftest.$ac_ext <<_ACEOF
8026 /* confdefs.h.  */
8027 _ACEOF
8028 cat confdefs.h >>conftest.$ac_ext
8029 cat >>conftest.$ac_ext <<_ACEOF
8030 /* end confdefs.h.  */
8031
8032 /* Override any GCC internal prototype to avoid an error.
8033    Use char because int might match the return type of a GCC
8034    builtin and then its argument prototype would still apply.  */
8035 #ifdef __cplusplus
8036 extern "C"
8037 #endif
8038 char pam_start ();
8039 int
8040 main ()
8041 {
8042 return pam_start ();
8043   ;
8044   return 0;
8045 }
8046 _ACEOF
8047 rm -f conftest.$ac_objext conftest$ac_exeext
8048 if { (ac_try="$ac_link"
8049 case "(($ac_try" in
8050   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8051   *) ac_try_echo=$ac_try;;
8052 esac
8053 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8054   (eval "$ac_link") 2>conftest.er1
8055   ac_status=$?
8056   grep -v '^ *+' conftest.er1 >conftest.err
8057   rm -f conftest.er1
8058   cat conftest.err >&5
8059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8060   (exit $ac_status); } && {
8061          test -z "$ac_c_werror_flag" ||
8062          test ! -s conftest.err
8063        } && test -s conftest$ac_exeext &&
8064        $as_test_x conftest$ac_exeext; then
8065   ac_cv_lib_pam_pam_start=yes
8066 else
8067   echo "$as_me: failed program was:" >&5
8068 sed 's/^/| /' conftest.$ac_ext >&5
8069
8070         ac_cv_lib_pam_pam_start=no
8071 fi
8072
8073 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8074       conftest$ac_exeext conftest.$ac_ext
8075 LIBS=$ac_check_lib_save_LIBS
8076 fi
8077 { echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
8078 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6; }
8079 if test $ac_cv_lib_pam_pam_start = yes; then
8080   cat >>confdefs.h <<_ACEOF
8081 #define HAVE_LIBPAM 1
8082 _ACEOF
8083
8084   LIBS="-lpam $LIBS"
8085
8086 else
8087   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
8088 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
8089    { (exit 1); exit 1; }; }
8090 fi
8091
8092 fi
8093
8094 if test "$with_libxml" = yes ; then
8095
8096 { echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
8097 echo $ECHO_N "checking for xmlSaveToBuffer in -lxml2... $ECHO_C" >&6; }
8098 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
8099   echo $ECHO_N "(cached) $ECHO_C" >&6
8100 else
8101   ac_check_lib_save_LIBS=$LIBS
8102 LIBS="-lxml2  $LIBS"
8103 cat >conftest.$ac_ext <<_ACEOF
8104 /* confdefs.h.  */
8105 _ACEOF
8106 cat confdefs.h >>conftest.$ac_ext
8107 cat >>conftest.$ac_ext <<_ACEOF
8108 /* end confdefs.h.  */
8109
8110 /* Override any GCC internal prototype to avoid an error.
8111    Use char because int might match the return type of a GCC
8112    builtin and then its argument prototype would still apply.  */
8113 #ifdef __cplusplus
8114 extern "C"
8115 #endif
8116 char xmlSaveToBuffer ();
8117 int
8118 main ()
8119 {
8120 return xmlSaveToBuffer ();
8121   ;
8122   return 0;
8123 }
8124 _ACEOF
8125 rm -f conftest.$ac_objext conftest$ac_exeext
8126 if { (ac_try="$ac_link"
8127 case "(($ac_try" in
8128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8129   *) ac_try_echo=$ac_try;;
8130 esac
8131 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8132   (eval "$ac_link") 2>conftest.er1
8133   ac_status=$?
8134   grep -v '^ *+' conftest.er1 >conftest.err
8135   rm -f conftest.er1
8136   cat conftest.err >&5
8137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8138   (exit $ac_status); } && {
8139          test -z "$ac_c_werror_flag" ||
8140          test ! -s conftest.err
8141        } && test -s conftest$ac_exeext &&
8142        $as_test_x conftest$ac_exeext; then
8143   ac_cv_lib_xml2_xmlSaveToBuffer=yes
8144 else
8145   echo "$as_me: failed program was:" >&5
8146 sed 's/^/| /' conftest.$ac_ext >&5
8147
8148         ac_cv_lib_xml2_xmlSaveToBuffer=no
8149 fi
8150
8151 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8152       conftest$ac_exeext conftest.$ac_ext
8153 LIBS=$ac_check_lib_save_LIBS
8154 fi
8155 { echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
8156 echo "${ECHO_T}$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
8157 if test $ac_cv_lib_xml2_xmlSaveToBuffer = yes; then
8158   cat >>confdefs.h <<_ACEOF
8159 #define HAVE_LIBXML2 1
8160 _ACEOF
8161
8162   LIBS="-lxml2 $LIBS"
8163
8164 else
8165   { { echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
8166 echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
8167    { (exit 1); exit 1; }; }
8168 fi
8169
8170 fi
8171
8172 if test "$with_libxslt" = yes ; then
8173
8174 { echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
8175 echo $ECHO_N "checking for xsltCleanupGlobals in -lxslt... $ECHO_C" >&6; }
8176 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
8177   echo $ECHO_N "(cached) $ECHO_C" >&6
8178 else
8179   ac_check_lib_save_LIBS=$LIBS
8180 LIBS="-lxslt  $LIBS"
8181 cat >conftest.$ac_ext <<_ACEOF
8182 /* confdefs.h.  */
8183 _ACEOF
8184 cat confdefs.h >>conftest.$ac_ext
8185 cat >>conftest.$ac_ext <<_ACEOF
8186 /* end confdefs.h.  */
8187
8188 /* Override any GCC internal prototype to avoid an error.
8189    Use char because int might match the return type of a GCC
8190    builtin and then its argument prototype would still apply.  */
8191 #ifdef __cplusplus
8192 extern "C"
8193 #endif
8194 char xsltCleanupGlobals ();
8195 int
8196 main ()
8197 {
8198 return xsltCleanupGlobals ();
8199   ;
8200   return 0;
8201 }
8202 _ACEOF
8203 rm -f conftest.$ac_objext conftest$ac_exeext
8204 if { (ac_try="$ac_link"
8205 case "(($ac_try" in
8206   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8207   *) ac_try_echo=$ac_try;;
8208 esac
8209 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8210   (eval "$ac_link") 2>conftest.er1
8211   ac_status=$?
8212   grep -v '^ *+' conftest.er1 >conftest.err
8213   rm -f conftest.er1
8214   cat conftest.err >&5
8215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8216   (exit $ac_status); } && {
8217          test -z "$ac_c_werror_flag" ||
8218          test ! -s conftest.err
8219        } && test -s conftest$ac_exeext &&
8220        $as_test_x conftest$ac_exeext; then
8221   ac_cv_lib_xslt_xsltCleanupGlobals=yes
8222 else
8223   echo "$as_me: failed program was:" >&5
8224 sed 's/^/| /' conftest.$ac_ext >&5
8225
8226         ac_cv_lib_xslt_xsltCleanupGlobals=no
8227 fi
8228
8229 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8230       conftest$ac_exeext conftest.$ac_ext
8231 LIBS=$ac_check_lib_save_LIBS
8232 fi
8233 { echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
8234 echo "${ECHO_T}$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
8235 if test $ac_cv_lib_xslt_xsltCleanupGlobals = yes; then
8236   cat >>confdefs.h <<_ACEOF
8237 #define HAVE_LIBXSLT 1
8238 _ACEOF
8239
8240   LIBS="-lxslt $LIBS"
8241
8242 else
8243   { { echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
8244 echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
8245    { (exit 1); exit 1; }; }
8246 fi
8247
8248 fi
8249
8250 # for contrib/uuid-ossp
8251 if test "$with_ossp_uuid" = yes ; then
8252   { echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
8253 echo $ECHO_N "checking for uuid_export in -lossp-uuid... $ECHO_C" >&6; }
8254 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
8255   echo $ECHO_N "(cached) $ECHO_C" >&6
8256 else
8257   ac_check_lib_save_LIBS=$LIBS
8258 LIBS="-lossp-uuid  $LIBS"
8259 cat >conftest.$ac_ext <<_ACEOF
8260 /* confdefs.h.  */
8261 _ACEOF
8262 cat confdefs.h >>conftest.$ac_ext
8263 cat >>conftest.$ac_ext <<_ACEOF
8264 /* end confdefs.h.  */
8265
8266 /* Override any GCC internal prototype to avoid an error.
8267    Use char because int might match the return type of a GCC
8268    builtin and then its argument prototype would still apply.  */
8269 #ifdef __cplusplus
8270 extern "C"
8271 #endif
8272 char uuid_export ();
8273 int
8274 main ()
8275 {
8276 return uuid_export ();
8277   ;
8278   return 0;
8279 }
8280 _ACEOF
8281 rm -f conftest.$ac_objext conftest$ac_exeext
8282 if { (ac_try="$ac_link"
8283 case "(($ac_try" in
8284   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8285   *) ac_try_echo=$ac_try;;
8286 esac
8287 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8288   (eval "$ac_link") 2>conftest.er1
8289   ac_status=$?
8290   grep -v '^ *+' conftest.er1 >conftest.err
8291   rm -f conftest.er1
8292   cat conftest.err >&5
8293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8294   (exit $ac_status); } && {
8295          test -z "$ac_c_werror_flag" ||
8296          test ! -s conftest.err
8297        } && test -s conftest$ac_exeext &&
8298        $as_test_x conftest$ac_exeext; then
8299   ac_cv_lib_ossp_uuid_uuid_export=yes
8300 else
8301   echo "$as_me: failed program was:" >&5
8302 sed 's/^/| /' conftest.$ac_ext >&5
8303
8304         ac_cv_lib_ossp_uuid_uuid_export=no
8305 fi
8306
8307 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8308       conftest$ac_exeext conftest.$ac_ext
8309 LIBS=$ac_check_lib_save_LIBS
8310 fi
8311 { echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
8312 echo "${ECHO_T}$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
8313 if test $ac_cv_lib_ossp_uuid_uuid_export = yes; then
8314   OSSP_UUID_LIBS="-lossp-uuid"
8315 else
8316   { echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
8317 echo $ECHO_N "checking for uuid_export in -luuid... $ECHO_C" >&6; }
8318 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
8319   echo $ECHO_N "(cached) $ECHO_C" >&6
8320 else
8321   ac_check_lib_save_LIBS=$LIBS
8322 LIBS="-luuid  $LIBS"
8323 cat >conftest.$ac_ext <<_ACEOF
8324 /* confdefs.h.  */
8325 _ACEOF
8326 cat confdefs.h >>conftest.$ac_ext
8327 cat >>conftest.$ac_ext <<_ACEOF
8328 /* end confdefs.h.  */
8329
8330 /* Override any GCC internal prototype to avoid an error.
8331    Use char because int might match the return type of a GCC
8332    builtin and then its argument prototype would still apply.  */
8333 #ifdef __cplusplus
8334 extern "C"
8335 #endif
8336 char uuid_export ();
8337 int
8338 main ()
8339 {
8340 return uuid_export ();
8341   ;
8342   return 0;
8343 }
8344 _ACEOF
8345 rm -f conftest.$ac_objext conftest$ac_exeext
8346 if { (ac_try="$ac_link"
8347 case "(($ac_try" in
8348   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8349   *) ac_try_echo=$ac_try;;
8350 esac
8351 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8352   (eval "$ac_link") 2>conftest.er1
8353   ac_status=$?
8354   grep -v '^ *+' conftest.er1 >conftest.err
8355   rm -f conftest.er1
8356   cat conftest.err >&5
8357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8358   (exit $ac_status); } && {
8359          test -z "$ac_c_werror_flag" ||
8360          test ! -s conftest.err
8361        } && test -s conftest$ac_exeext &&
8362        $as_test_x conftest$ac_exeext; then
8363   ac_cv_lib_uuid_uuid_export=yes
8364 else
8365   echo "$as_me: failed program was:" >&5
8366 sed 's/^/| /' conftest.$ac_ext >&5
8367
8368         ac_cv_lib_uuid_uuid_export=no
8369 fi
8370
8371 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8372       conftest$ac_exeext conftest.$ac_ext
8373 LIBS=$ac_check_lib_save_LIBS
8374 fi
8375 { echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
8376 echo "${ECHO_T}$ac_cv_lib_uuid_uuid_export" >&6; }
8377 if test $ac_cv_lib_uuid_uuid_export = yes; then
8378   OSSP_UUID_LIBS="-luuid"
8379 else
8380   { { echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
8381 echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
8382    { (exit 1); exit 1; }; }
8383 fi
8384
8385 fi
8386
8387 fi
8388
8389
8390
8391 ##
8392 ## Header files
8393 ##
8394
8395 { echo "$as_me:$LINENO: checking for ANSI C header files" >&5
8396 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
8397 if test "${ac_cv_header_stdc+set}" = set; then
8398   echo $ECHO_N "(cached) $ECHO_C" >&6
8399 else
8400   cat >conftest.$ac_ext <<_ACEOF
8401 /* confdefs.h.  */
8402 _ACEOF
8403 cat confdefs.h >>conftest.$ac_ext
8404 cat >>conftest.$ac_ext <<_ACEOF
8405 /* end confdefs.h.  */
8406 #include <stdlib.h>
8407 #include <stdarg.h>
8408 #include <string.h>
8409 #include <float.h>
8410
8411 int
8412 main ()
8413 {
8414
8415   ;
8416   return 0;
8417 }
8418 _ACEOF
8419 rm -f conftest.$ac_objext
8420 if { (ac_try="$ac_compile"
8421 case "(($ac_try" in
8422   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8423   *) ac_try_echo=$ac_try;;
8424 esac
8425 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8426   (eval "$ac_compile") 2>conftest.er1
8427   ac_status=$?
8428   grep -v '^ *+' conftest.er1 >conftest.err
8429   rm -f conftest.er1
8430   cat conftest.err >&5
8431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8432   (exit $ac_status); } && {
8433          test -z "$ac_c_werror_flag" ||
8434          test ! -s conftest.err
8435        } && test -s conftest.$ac_objext; then
8436   ac_cv_header_stdc=yes
8437 else
8438   echo "$as_me: failed program was:" >&5
8439 sed 's/^/| /' conftest.$ac_ext >&5
8440
8441         ac_cv_header_stdc=no
8442 fi
8443
8444 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8445
8446 if test $ac_cv_header_stdc = yes; then
8447   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
8448   cat >conftest.$ac_ext <<_ACEOF
8449 /* confdefs.h.  */
8450 _ACEOF
8451 cat confdefs.h >>conftest.$ac_ext
8452 cat >>conftest.$ac_ext <<_ACEOF
8453 /* end confdefs.h.  */
8454 #include <string.h>
8455
8456 _ACEOF
8457 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8458   $EGREP "memchr" >/dev/null 2>&1; then
8459   :
8460 else
8461   ac_cv_header_stdc=no
8462 fi
8463 rm -f conftest*
8464
8465 fi
8466
8467 if test $ac_cv_header_stdc = yes; then
8468   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
8469   cat >conftest.$ac_ext <<_ACEOF
8470 /* confdefs.h.  */
8471 _ACEOF
8472 cat confdefs.h >>conftest.$ac_ext
8473 cat >>conftest.$ac_ext <<_ACEOF
8474 /* end confdefs.h.  */
8475 #include <stdlib.h>
8476
8477 _ACEOF
8478 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8479   $EGREP "free" >/dev/null 2>&1; then
8480   :
8481 else
8482   ac_cv_header_stdc=no
8483 fi
8484 rm -f conftest*
8485
8486 fi
8487
8488 if test $ac_cv_header_stdc = yes; then
8489   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
8490   if test "$cross_compiling" = yes; then
8491   :
8492 else
8493   cat >conftest.$ac_ext <<_ACEOF
8494 /* confdefs.h.  */
8495 _ACEOF
8496 cat confdefs.h >>conftest.$ac_ext
8497 cat >>conftest.$ac_ext <<_ACEOF
8498 /* end confdefs.h.  */
8499 #include <ctype.h>
8500 #include <stdlib.h>
8501 #if ((' ' & 0x0FF) == 0x020)
8502 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8503 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8504 #else
8505 # define ISLOWER(c) \
8506                    (('a' <= (c) && (c) <= 'i') \
8507                      || ('j' <= (c) && (c) <= 'r') \
8508                      || ('s' <= (c) && (c) <= 'z'))
8509 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8510 #endif
8511
8512 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8513 int
8514 main ()
8515 {
8516   int i;
8517   for (i = 0; i < 256; i++)
8518     if (XOR (islower (i), ISLOWER (i))
8519         || toupper (i) != TOUPPER (i))
8520       return 2;
8521   return 0;
8522 }
8523 _ACEOF
8524 rm -f conftest$ac_exeext
8525 if { (ac_try="$ac_link"
8526 case "(($ac_try" in
8527   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8528   *) ac_try_echo=$ac_try;;
8529 esac
8530 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8531   (eval "$ac_link") 2>&5
8532   ac_status=$?
8533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8534   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8535   { (case "(($ac_try" in
8536   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8537   *) ac_try_echo=$ac_try;;
8538 esac
8539 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8540   (eval "$ac_try") 2>&5
8541   ac_status=$?
8542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8543   (exit $ac_status); }; }; then
8544   :
8545 else
8546   echo "$as_me: program exited with status $ac_status" >&5
8547 echo "$as_me: failed program was:" >&5
8548 sed 's/^/| /' conftest.$ac_ext >&5
8549
8550 ( exit $ac_status )
8551 ac_cv_header_stdc=no
8552 fi
8553 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8554 fi
8555
8556
8557 fi
8558 fi
8559 { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
8560 echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
8561 if test $ac_cv_header_stdc = yes; then
8562
8563 cat >>confdefs.h <<\_ACEOF
8564 #define STDC_HEADERS 1
8565 _ACEOF
8566
8567 fi
8568
8569 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
8570
8571
8572
8573
8574
8575
8576
8577
8578
8579 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
8580                   inttypes.h stdint.h unistd.h
8581 do
8582 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8583 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8584 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8585 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8586   echo $ECHO_N "(cached) $ECHO_C" >&6
8587 else
8588   cat >conftest.$ac_ext <<_ACEOF
8589 /* confdefs.h.  */
8590 _ACEOF
8591 cat confdefs.h >>conftest.$ac_ext
8592 cat >>conftest.$ac_ext <<_ACEOF
8593 /* end confdefs.h.  */
8594 $ac_includes_default
8595
8596 #include <$ac_header>
8597 _ACEOF
8598 rm -f conftest.$ac_objext
8599 if { (ac_try="$ac_compile"
8600 case "(($ac_try" in
8601   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8602   *) ac_try_echo=$ac_try;;
8603 esac
8604 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8605   (eval "$ac_compile") 2>conftest.er1
8606   ac_status=$?
8607   grep -v '^ *+' conftest.er1 >conftest.err
8608   rm -f conftest.er1
8609   cat conftest.err >&5
8610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8611   (exit $ac_status); } && {
8612          test -z "$ac_c_werror_flag" ||
8613          test ! -s conftest.err
8614        } && test -s conftest.$ac_objext; then
8615   eval "$as_ac_Header=yes"
8616 else
8617   echo "$as_me: failed program was:" >&5
8618 sed 's/^/| /' conftest.$ac_ext >&5
8619
8620         eval "$as_ac_Header=no"
8621 fi
8622
8623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8624 fi
8625 ac_res=`eval echo '${'$as_ac_Header'}'`
8626                { echo "$as_me:$LINENO: result: $ac_res" >&5
8627 echo "${ECHO_T}$ac_res" >&6; }
8628 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8629   cat >>confdefs.h <<_ACEOF
8630 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8631 _ACEOF
8632
8633 fi
8634
8635 done
8636
8637
8638
8639
8640
8641
8642
8643
8644
8645
8646
8647
8648
8649
8650
8651
8652
8653
8654
8655
8656
8657
8658
8659
8660
8661
8662
8663
8664 for ac_header in crypt.h dld.h fp_class.h getopt.h ieeefp.h langinfo.h poll.h pwd.h sys/ipc.h sys/poll.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/socket.h sys/shm.h sys/tas.h sys/time.h sys/un.h termios.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h
8665 do
8666 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8667 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8668   { echo "$as_me:$LINENO: checking for $ac_header" >&5
8669 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8670 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8671   echo $ECHO_N "(cached) $ECHO_C" >&6
8672 fi
8673 ac_res=`eval echo '${'$as_ac_Header'}'`
8674                { echo "$as_me:$LINENO: result: $ac_res" >&5
8675 echo "${ECHO_T}$ac_res" >&6; }
8676 else
8677   # Is the header compilable?
8678 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
8679 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
8680 cat >conftest.$ac_ext <<_ACEOF
8681 /* confdefs.h.  */
8682 _ACEOF
8683 cat confdefs.h >>conftest.$ac_ext
8684 cat >>conftest.$ac_ext <<_ACEOF
8685 /* end confdefs.h.  */
8686 $ac_includes_default
8687 #include <$ac_header>
8688 _ACEOF
8689 rm -f conftest.$ac_objext
8690 if { (ac_try="$ac_compile"
8691 case "(($ac_try" in
8692   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8693   *) ac_try_echo=$ac_try;;
8694 esac
8695 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8696   (eval "$ac_compile") 2>conftest.er1
8697   ac_status=$?
8698   grep -v '^ *+' conftest.er1 >conftest.err
8699   rm -f conftest.er1
8700   cat conftest.err >&5
8701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8702   (exit $ac_status); } && {
8703          test -z "$ac_c_werror_flag" ||
8704          test ! -s conftest.err
8705        } && test -s conftest.$ac_objext; then
8706   ac_header_compiler=yes
8707 else
8708   echo "$as_me: failed program was:" >&5
8709 sed 's/^/| /' conftest.$ac_ext >&5
8710
8711         ac_header_compiler=no
8712 fi
8713
8714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8715 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8716 echo "${ECHO_T}$ac_header_compiler" >&6; }
8717
8718 # Is the header present?
8719 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
8720 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
8721 cat >conftest.$ac_ext <<_ACEOF
8722 /* confdefs.h.  */
8723 _ACEOF
8724 cat confdefs.h >>conftest.$ac_ext
8725 cat >>conftest.$ac_ext <<_ACEOF
8726 /* end confdefs.h.  */
8727 #include <$ac_header>
8728 _ACEOF
8729 if { (ac_try="$ac_cpp conftest.$ac_ext"
8730 case "(($ac_try" in
8731   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8732   *) ac_try_echo=$ac_try;;
8733 esac
8734 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8735   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8736   ac_status=$?
8737   grep -v '^ *+' conftest.er1 >conftest.err
8738   rm -f conftest.er1
8739   cat conftest.err >&5
8740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8741   (exit $ac_status); } >/dev/null && {
8742          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8743          test ! -s conftest.err
8744        }; then
8745   ac_header_preproc=yes
8746 else
8747   echo "$as_me: failed program was:" >&5
8748 sed 's/^/| /' conftest.$ac_ext >&5
8749
8750   ac_header_preproc=no
8751 fi
8752
8753 rm -f conftest.err conftest.$ac_ext
8754 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8755 echo "${ECHO_T}$ac_header_preproc" >&6; }
8756
8757 # So?  What about this header?
8758 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8759   yes:no: )
8760     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8761 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8762     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8763 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8764     ac_header_preproc=yes
8765     ;;
8766   no:yes:* )
8767     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8768 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8769     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8770 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8771     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8772 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8773     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8774 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8775     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8776 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8777     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8778 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8779     ( cat <<\_ASBOX
8780 ## ---------------------------------------- ##
8781 ## Report this to pgsql-bugs@postgresql.org ##
8782 ## ---------------------------------------- ##
8783 _ASBOX
8784      ) | sed "s/^/$as_me: WARNING:     /" >&2
8785     ;;
8786 esac
8787 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8788 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8789 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8790   echo $ECHO_N "(cached) $ECHO_C" >&6
8791 else
8792   eval "$as_ac_Header=\$ac_header_preproc"
8793 fi
8794 ac_res=`eval echo '${'$as_ac_Header'}'`
8795                { echo "$as_me:$LINENO: result: $ac_res" >&5
8796 echo "${ECHO_T}$ac_res" >&6; }
8797
8798 fi
8799 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8800   cat >>confdefs.h <<_ACEOF
8801 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8802 _ACEOF
8803
8804 fi
8805
8806 done
8807
8808
8809 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
8810 # netinet/in.h is included first.
8811
8812 for ac_header in netinet/in.h
8813 do
8814 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8815 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8816   { echo "$as_me:$LINENO: checking for $ac_header" >&5
8817 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8818 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8819   echo $ECHO_N "(cached) $ECHO_C" >&6
8820 fi
8821 ac_res=`eval echo '${'$as_ac_Header'}'`
8822                { echo "$as_me:$LINENO: result: $ac_res" >&5
8823 echo "${ECHO_T}$ac_res" >&6; }
8824 else
8825   # Is the header compilable?
8826 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
8827 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
8828 cat >conftest.$ac_ext <<_ACEOF
8829 /* confdefs.h.  */
8830 _ACEOF
8831 cat confdefs.h >>conftest.$ac_ext
8832 cat >>conftest.$ac_ext <<_ACEOF
8833 /* end confdefs.h.  */
8834 $ac_includes_default
8835 #include <$ac_header>
8836 _ACEOF
8837 rm -f conftest.$ac_objext
8838 if { (ac_try="$ac_compile"
8839 case "(($ac_try" in
8840   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8841   *) ac_try_echo=$ac_try;;
8842 esac
8843 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8844   (eval "$ac_compile") 2>conftest.er1
8845   ac_status=$?
8846   grep -v '^ *+' conftest.er1 >conftest.err
8847   rm -f conftest.er1
8848   cat conftest.err >&5
8849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8850   (exit $ac_status); } && {
8851          test -z "$ac_c_werror_flag" ||
8852          test ! -s conftest.err
8853        } && test -s conftest.$ac_objext; then
8854   ac_header_compiler=yes
8855 else
8856   echo "$as_me: failed program was:" >&5
8857 sed 's/^/| /' conftest.$ac_ext >&5
8858
8859         ac_header_compiler=no
8860 fi
8861
8862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8863 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8864 echo "${ECHO_T}$ac_header_compiler" >&6; }
8865
8866 # Is the header present?
8867 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
8868 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
8869 cat >conftest.$ac_ext <<_ACEOF
8870 /* confdefs.h.  */
8871 _ACEOF
8872 cat confdefs.h >>conftest.$ac_ext
8873 cat >>conftest.$ac_ext <<_ACEOF
8874 /* end confdefs.h.  */
8875 #include <$ac_header>
8876 _ACEOF
8877 if { (ac_try="$ac_cpp conftest.$ac_ext"
8878 case "(($ac_try" in
8879   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8880   *) ac_try_echo=$ac_try;;
8881 esac
8882 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8883   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8884   ac_status=$?
8885   grep -v '^ *+' conftest.er1 >conftest.err
8886   rm -f conftest.er1
8887   cat conftest.err >&5
8888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8889   (exit $ac_status); } >/dev/null && {
8890          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8891          test ! -s conftest.err
8892        }; then
8893   ac_header_preproc=yes
8894 else
8895   echo "$as_me: failed program was:" >&5
8896 sed 's/^/| /' conftest.$ac_ext >&5
8897
8898   ac_header_preproc=no
8899 fi
8900
8901 rm -f conftest.err conftest.$ac_ext
8902 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8903 echo "${ECHO_T}$ac_header_preproc" >&6; }
8904
8905 # So?  What about this header?
8906 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8907   yes:no: )
8908     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8909 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8910     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8911 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8912     ac_header_preproc=yes
8913     ;;
8914   no:yes:* )
8915     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8916 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8917     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8918 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8919     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8920 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8921     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8922 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8923     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8924 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8925     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8926 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8927     ( cat <<\_ASBOX
8928 ## ---------------------------------------- ##
8929 ## Report this to pgsql-bugs@postgresql.org ##
8930 ## ---------------------------------------- ##
8931 _ASBOX
8932      ) | sed "s/^/$as_me: WARNING:     /" >&2
8933     ;;
8934 esac
8935 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8936 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8937 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8938   echo $ECHO_N "(cached) $ECHO_C" >&6
8939 else
8940   eval "$as_ac_Header=\$ac_header_preproc"
8941 fi
8942 ac_res=`eval echo '${'$as_ac_Header'}'`
8943                { echo "$as_me:$LINENO: result: $ac_res" >&5
8944 echo "${ECHO_T}$ac_res" >&6; }
8945
8946 fi
8947 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8948   cat >>confdefs.h <<_ACEOF
8949 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8950 _ACEOF
8951
8952 fi
8953
8954 done
8955
8956
8957 for ac_header in netinet/tcp.h
8958 do
8959 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8960 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8961 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8962 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8963   echo $ECHO_N "(cached) $ECHO_C" >&6
8964 else
8965   cat >conftest.$ac_ext <<_ACEOF
8966 /* confdefs.h.  */
8967 _ACEOF
8968 cat confdefs.h >>conftest.$ac_ext
8969 cat >>conftest.$ac_ext <<_ACEOF
8970 /* end confdefs.h.  */
8971 $ac_includes_default
8972 #ifdef HAVE_NETINET_IN_H
8973 #include <netinet/in.h>
8974 #endif
8975
8976
8977 #include <$ac_header>
8978 _ACEOF
8979 rm -f conftest.$ac_objext
8980 if { (ac_try="$ac_compile"
8981 case "(($ac_try" in
8982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8983   *) ac_try_echo=$ac_try;;
8984 esac
8985 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8986   (eval "$ac_compile") 2>conftest.er1
8987   ac_status=$?
8988   grep -v '^ *+' conftest.er1 >conftest.err
8989   rm -f conftest.er1
8990   cat conftest.err >&5
8991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8992   (exit $ac_status); } && {
8993          test -z "$ac_c_werror_flag" ||
8994          test ! -s conftest.err
8995        } && test -s conftest.$ac_objext; then
8996   eval "$as_ac_Header=yes"
8997 else
8998   echo "$as_me: failed program was:" >&5
8999 sed 's/^/| /' conftest.$ac_ext >&5
9000
9001         eval "$as_ac_Header=no"
9002 fi
9003
9004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9005 fi
9006 ac_res=`eval echo '${'$as_ac_Header'}'`
9007                { echo "$as_me:$LINENO: result: $ac_res" >&5
9008 echo "${ECHO_T}$ac_res" >&6; }
9009 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9010   cat >>confdefs.h <<_ACEOF
9011 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9012 _ACEOF
9013
9014 fi
9015
9016 done
9017
9018
9019 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
9020
9021 for ac_header in readline/readline.h
9022 do
9023 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9024 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9025   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9026 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9027 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9028   echo $ECHO_N "(cached) $ECHO_C" >&6
9029 fi
9030 ac_res=`eval echo '${'$as_ac_Header'}'`
9031                { echo "$as_me:$LINENO: result: $ac_res" >&5
9032 echo "${ECHO_T}$ac_res" >&6; }
9033 else
9034   # Is the header compilable?
9035 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9036 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9037 cat >conftest.$ac_ext <<_ACEOF
9038 /* confdefs.h.  */
9039 _ACEOF
9040 cat confdefs.h >>conftest.$ac_ext
9041 cat >>conftest.$ac_ext <<_ACEOF
9042 /* end confdefs.h.  */
9043 $ac_includes_default
9044 #include <$ac_header>
9045 _ACEOF
9046 rm -f conftest.$ac_objext
9047 if { (ac_try="$ac_compile"
9048 case "(($ac_try" in
9049   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9050   *) ac_try_echo=$ac_try;;
9051 esac
9052 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9053   (eval "$ac_compile") 2>conftest.er1
9054   ac_status=$?
9055   grep -v '^ *+' conftest.er1 >conftest.err
9056   rm -f conftest.er1
9057   cat conftest.err >&5
9058   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9059   (exit $ac_status); } && {
9060          test -z "$ac_c_werror_flag" ||
9061          test ! -s conftest.err
9062        } && test -s conftest.$ac_objext; then
9063   ac_header_compiler=yes
9064 else
9065   echo "$as_me: failed program was:" >&5
9066 sed 's/^/| /' conftest.$ac_ext >&5
9067
9068         ac_header_compiler=no
9069 fi
9070
9071 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9072 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9073 echo "${ECHO_T}$ac_header_compiler" >&6; }
9074
9075 # Is the header present?
9076 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9077 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9078 cat >conftest.$ac_ext <<_ACEOF
9079 /* confdefs.h.  */
9080 _ACEOF
9081 cat confdefs.h >>conftest.$ac_ext
9082 cat >>conftest.$ac_ext <<_ACEOF
9083 /* end confdefs.h.  */
9084 #include <$ac_header>
9085 _ACEOF
9086 if { (ac_try="$ac_cpp conftest.$ac_ext"
9087 case "(($ac_try" in
9088   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9089   *) ac_try_echo=$ac_try;;
9090 esac
9091 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9092   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9093   ac_status=$?
9094   grep -v '^ *+' conftest.er1 >conftest.err
9095   rm -f conftest.er1
9096   cat conftest.err >&5
9097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9098   (exit $ac_status); } >/dev/null && {
9099          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9100          test ! -s conftest.err
9101        }; then
9102   ac_header_preproc=yes
9103 else
9104   echo "$as_me: failed program was:" >&5
9105 sed 's/^/| /' conftest.$ac_ext >&5
9106
9107   ac_header_preproc=no
9108 fi
9109
9110 rm -f conftest.err conftest.$ac_ext
9111 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9112 echo "${ECHO_T}$ac_header_preproc" >&6; }
9113
9114 # So?  What about this header?
9115 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9116   yes:no: )
9117     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9118 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9119     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9120 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9121     ac_header_preproc=yes
9122     ;;
9123   no:yes:* )
9124     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9125 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9126     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9127 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9128     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9129 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9130     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9131 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9132     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9133 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9134     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9135 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9136     ( cat <<\_ASBOX
9137 ## ---------------------------------------- ##
9138 ## Report this to pgsql-bugs@postgresql.org ##
9139 ## ---------------------------------------- ##
9140 _ASBOX
9141      ) | sed "s/^/$as_me: WARNING:     /" >&2
9142     ;;
9143 esac
9144 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9145 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9146 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9147   echo $ECHO_N "(cached) $ECHO_C" >&6
9148 else
9149   eval "$as_ac_Header=\$ac_header_preproc"
9150 fi
9151 ac_res=`eval echo '${'$as_ac_Header'}'`
9152                { echo "$as_me:$LINENO: result: $ac_res" >&5
9153 echo "${ECHO_T}$ac_res" >&6; }
9154
9155 fi
9156 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9157   cat >>confdefs.h <<_ACEOF
9158 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9159 _ACEOF
9160
9161 else
9162
9163 for ac_header in readline.h
9164 do
9165 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9166 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9167   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9168 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9169 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9170   echo $ECHO_N "(cached) $ECHO_C" >&6
9171 fi
9172 ac_res=`eval echo '${'$as_ac_Header'}'`
9173                { echo "$as_me:$LINENO: result: $ac_res" >&5
9174 echo "${ECHO_T}$ac_res" >&6; }
9175 else
9176   # Is the header compilable?
9177 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9178 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9179 cat >conftest.$ac_ext <<_ACEOF
9180 /* confdefs.h.  */
9181 _ACEOF
9182 cat confdefs.h >>conftest.$ac_ext
9183 cat >>conftest.$ac_ext <<_ACEOF
9184 /* end confdefs.h.  */
9185 $ac_includes_default
9186 #include <$ac_header>
9187 _ACEOF
9188 rm -f conftest.$ac_objext
9189 if { (ac_try="$ac_compile"
9190 case "(($ac_try" in
9191   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9192   *) ac_try_echo=$ac_try;;
9193 esac
9194 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9195   (eval "$ac_compile") 2>conftest.er1
9196   ac_status=$?
9197   grep -v '^ *+' conftest.er1 >conftest.err
9198   rm -f conftest.er1
9199   cat conftest.err >&5
9200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9201   (exit $ac_status); } && {
9202          test -z "$ac_c_werror_flag" ||
9203          test ! -s conftest.err
9204        } && test -s conftest.$ac_objext; then
9205   ac_header_compiler=yes
9206 else
9207   echo "$as_me: failed program was:" >&5
9208 sed 's/^/| /' conftest.$ac_ext >&5
9209
9210         ac_header_compiler=no
9211 fi
9212
9213 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9214 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9215 echo "${ECHO_T}$ac_header_compiler" >&6; }
9216
9217 # Is the header present?
9218 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9219 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9220 cat >conftest.$ac_ext <<_ACEOF
9221 /* confdefs.h.  */
9222 _ACEOF
9223 cat confdefs.h >>conftest.$ac_ext
9224 cat >>conftest.$ac_ext <<_ACEOF
9225 /* end confdefs.h.  */
9226 #include <$ac_header>
9227 _ACEOF
9228 if { (ac_try="$ac_cpp conftest.$ac_ext"
9229 case "(($ac_try" in
9230   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9231   *) ac_try_echo=$ac_try;;
9232 esac
9233 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9234   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9235   ac_status=$?
9236   grep -v '^ *+' conftest.er1 >conftest.err
9237   rm -f conftest.er1
9238   cat conftest.err >&5
9239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9240   (exit $ac_status); } >/dev/null && {
9241          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9242          test ! -s conftest.err
9243        }; then
9244   ac_header_preproc=yes
9245 else
9246   echo "$as_me: failed program was:" >&5
9247 sed 's/^/| /' conftest.$ac_ext >&5
9248
9249   ac_header_preproc=no
9250 fi
9251
9252 rm -f conftest.err conftest.$ac_ext
9253 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9254 echo "${ECHO_T}$ac_header_preproc" >&6; }
9255
9256 # So?  What about this header?
9257 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9258   yes:no: )
9259     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9260 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9261     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9262 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9263     ac_header_preproc=yes
9264     ;;
9265   no:yes:* )
9266     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9267 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9268     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9269 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9270     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9271 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9272     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9273 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9274     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9275 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9276     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9277 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9278     ( cat <<\_ASBOX
9279 ## ---------------------------------------- ##
9280 ## Report this to pgsql-bugs@postgresql.org ##
9281 ## ---------------------------------------- ##
9282 _ASBOX
9283      ) | sed "s/^/$as_me: WARNING:     /" >&2
9284     ;;
9285 esac
9286 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9287 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9288 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9289   echo $ECHO_N "(cached) $ECHO_C" >&6
9290 else
9291   eval "$as_ac_Header=\$ac_header_preproc"
9292 fi
9293 ac_res=`eval echo '${'$as_ac_Header'}'`
9294                { echo "$as_me:$LINENO: result: $ac_res" >&5
9295 echo "${ECHO_T}$ac_res" >&6; }
9296
9297 fi
9298 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9299   cat >>confdefs.h <<_ACEOF
9300 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9301 _ACEOF
9302
9303 else
9304   { { echo "$as_me:$LINENO: error: readline header not found
9305 If you have readline already installed, see config.log for details on the
9306 failure.  It is possible the compiler isn't looking in the proper directory.
9307 Use --without-readline to disable readline support." >&5
9308 echo "$as_me: error: readline header not found
9309 If you have readline already installed, see config.log for details on the
9310 failure.  It is possible the compiler isn't looking in the proper directory.
9311 Use --without-readline to disable readline support." >&2;}
9312    { (exit 1); exit 1; }; }
9313 fi
9314
9315 done
9316
9317 fi
9318
9319 done
9320
9321
9322 for ac_header in readline/history.h
9323 do
9324 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9325 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9326   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9327 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9328 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9329   echo $ECHO_N "(cached) $ECHO_C" >&6
9330 fi
9331 ac_res=`eval echo '${'$as_ac_Header'}'`
9332                { echo "$as_me:$LINENO: result: $ac_res" >&5
9333 echo "${ECHO_T}$ac_res" >&6; }
9334 else
9335   # Is the header compilable?
9336 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9337 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9338 cat >conftest.$ac_ext <<_ACEOF
9339 /* confdefs.h.  */
9340 _ACEOF
9341 cat confdefs.h >>conftest.$ac_ext
9342 cat >>conftest.$ac_ext <<_ACEOF
9343 /* end confdefs.h.  */
9344 $ac_includes_default
9345 #include <$ac_header>
9346 _ACEOF
9347 rm -f conftest.$ac_objext
9348 if { (ac_try="$ac_compile"
9349 case "(($ac_try" in
9350   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9351   *) ac_try_echo=$ac_try;;
9352 esac
9353 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9354   (eval "$ac_compile") 2>conftest.er1
9355   ac_status=$?
9356   grep -v '^ *+' conftest.er1 >conftest.err
9357   rm -f conftest.er1
9358   cat conftest.err >&5
9359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9360   (exit $ac_status); } && {
9361          test -z "$ac_c_werror_flag" ||
9362          test ! -s conftest.err
9363        } && test -s conftest.$ac_objext; then
9364   ac_header_compiler=yes
9365 else
9366   echo "$as_me: failed program was:" >&5
9367 sed 's/^/| /' conftest.$ac_ext >&5
9368
9369         ac_header_compiler=no
9370 fi
9371
9372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9373 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9374 echo "${ECHO_T}$ac_header_compiler" >&6; }
9375
9376 # Is the header present?
9377 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9378 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9379 cat >conftest.$ac_ext <<_ACEOF
9380 /* confdefs.h.  */
9381 _ACEOF
9382 cat confdefs.h >>conftest.$ac_ext
9383 cat >>conftest.$ac_ext <<_ACEOF
9384 /* end confdefs.h.  */
9385 #include <$ac_header>
9386 _ACEOF
9387 if { (ac_try="$ac_cpp conftest.$ac_ext"
9388 case "(($ac_try" in
9389   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9390   *) ac_try_echo=$ac_try;;
9391 esac
9392 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9393   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9394   ac_status=$?
9395   grep -v '^ *+' conftest.er1 >conftest.err
9396   rm -f conftest.er1
9397   cat conftest.err >&5
9398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9399   (exit $ac_status); } >/dev/null && {
9400          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9401          test ! -s conftest.err
9402        }; then
9403   ac_header_preproc=yes
9404 else
9405   echo "$as_me: failed program was:" >&5
9406 sed 's/^/| /' conftest.$ac_ext >&5
9407
9408   ac_header_preproc=no
9409 fi
9410
9411 rm -f conftest.err conftest.$ac_ext
9412 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9413 echo "${ECHO_T}$ac_header_preproc" >&6; }
9414
9415 # So?  What about this header?
9416 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9417   yes:no: )
9418     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9419 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9420     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9421 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9422     ac_header_preproc=yes
9423     ;;
9424   no:yes:* )
9425     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9426 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9427     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9428 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9429     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9430 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9431     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9432 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9433     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9434 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9435     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9436 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9437     ( cat <<\_ASBOX
9438 ## ---------------------------------------- ##
9439 ## Report this to pgsql-bugs@postgresql.org ##
9440 ## ---------------------------------------- ##
9441 _ASBOX
9442      ) | sed "s/^/$as_me: WARNING:     /" >&2
9443     ;;
9444 esac
9445 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9446 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9447 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9448   echo $ECHO_N "(cached) $ECHO_C" >&6
9449 else
9450   eval "$as_ac_Header=\$ac_header_preproc"
9451 fi
9452 ac_res=`eval echo '${'$as_ac_Header'}'`
9453                { echo "$as_me:$LINENO: result: $ac_res" >&5
9454 echo "${ECHO_T}$ac_res" >&6; }
9455
9456 fi
9457 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9458   cat >>confdefs.h <<_ACEOF
9459 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9460 _ACEOF
9461
9462 else
9463
9464 for ac_header in history.h
9465 do
9466 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9467 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9468   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9469 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9470 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9471   echo $ECHO_N "(cached) $ECHO_C" >&6
9472 fi
9473 ac_res=`eval echo '${'$as_ac_Header'}'`
9474                { echo "$as_me:$LINENO: result: $ac_res" >&5
9475 echo "${ECHO_T}$ac_res" >&6; }
9476 else
9477   # Is the header compilable?
9478 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9479 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9480 cat >conftest.$ac_ext <<_ACEOF
9481 /* confdefs.h.  */
9482 _ACEOF
9483 cat confdefs.h >>conftest.$ac_ext
9484 cat >>conftest.$ac_ext <<_ACEOF
9485 /* end confdefs.h.  */
9486 $ac_includes_default
9487 #include <$ac_header>
9488 _ACEOF
9489 rm -f conftest.$ac_objext
9490 if { (ac_try="$ac_compile"
9491 case "(($ac_try" in
9492   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9493   *) ac_try_echo=$ac_try;;
9494 esac
9495 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9496   (eval "$ac_compile") 2>conftest.er1
9497   ac_status=$?
9498   grep -v '^ *+' conftest.er1 >conftest.err
9499   rm -f conftest.er1
9500   cat conftest.err >&5
9501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9502   (exit $ac_status); } && {
9503          test -z "$ac_c_werror_flag" ||
9504          test ! -s conftest.err
9505        } && test -s conftest.$ac_objext; then
9506   ac_header_compiler=yes
9507 else
9508   echo "$as_me: failed program was:" >&5
9509 sed 's/^/| /' conftest.$ac_ext >&5
9510
9511         ac_header_compiler=no
9512 fi
9513
9514 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9515 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9516 echo "${ECHO_T}$ac_header_compiler" >&6; }
9517
9518 # Is the header present?
9519 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9520 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9521 cat >conftest.$ac_ext <<_ACEOF
9522 /* confdefs.h.  */
9523 _ACEOF
9524 cat confdefs.h >>conftest.$ac_ext
9525 cat >>conftest.$ac_ext <<_ACEOF
9526 /* end confdefs.h.  */
9527 #include <$ac_header>
9528 _ACEOF
9529 if { (ac_try="$ac_cpp conftest.$ac_ext"
9530 case "(($ac_try" in
9531   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9532   *) ac_try_echo=$ac_try;;
9533 esac
9534 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9535   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9536   ac_status=$?
9537   grep -v '^ *+' conftest.er1 >conftest.err
9538   rm -f conftest.er1
9539   cat conftest.err >&5
9540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9541   (exit $ac_status); } >/dev/null && {
9542          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9543          test ! -s conftest.err
9544        }; then
9545   ac_header_preproc=yes
9546 else
9547   echo "$as_me: failed program was:" >&5
9548 sed 's/^/| /' conftest.$ac_ext >&5
9549
9550   ac_header_preproc=no
9551 fi
9552
9553 rm -f conftest.err conftest.$ac_ext
9554 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9555 echo "${ECHO_T}$ac_header_preproc" >&6; }
9556
9557 # So?  What about this header?
9558 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9559   yes:no: )
9560     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9561 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9562     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9563 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9564     ac_header_preproc=yes
9565     ;;
9566   no:yes:* )
9567     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9568 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9569     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9570 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9571     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9572 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9573     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9574 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9575     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9576 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9577     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9578 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9579     ( cat <<\_ASBOX
9580 ## ---------------------------------------- ##
9581 ## Report this to pgsql-bugs@postgresql.org ##
9582 ## ---------------------------------------- ##
9583 _ASBOX
9584      ) | sed "s/^/$as_me: WARNING:     /" >&2
9585     ;;
9586 esac
9587 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9588 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9589 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9590   echo $ECHO_N "(cached) $ECHO_C" >&6
9591 else
9592   eval "$as_ac_Header=\$ac_header_preproc"
9593 fi
9594 ac_res=`eval echo '${'$as_ac_Header'}'`
9595                { echo "$as_me:$LINENO: result: $ac_res" >&5
9596 echo "${ECHO_T}$ac_res" >&6; }
9597
9598 fi
9599 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9600   cat >>confdefs.h <<_ACEOF
9601 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9602 _ACEOF
9603
9604 else
9605   { { echo "$as_me:$LINENO: error: history header not found
9606 If you have readline already installed, see config.log for details on the
9607 failure.  It is possible the compiler isn't looking in the proper directory.
9608 Use --without-readline to disable readline support." >&5
9609 echo "$as_me: error: history header not found
9610 If you have readline already installed, see config.log for details on the
9611 failure.  It is possible the compiler isn't looking in the proper directory.
9612 Use --without-readline to disable readline support." >&2;}
9613    { (exit 1); exit 1; }; }
9614 fi
9615
9616 done
9617
9618 fi
9619
9620 done
9621
9622 fi
9623
9624 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
9625 # Some installations of libedit usurp /usr/include/readline/, which seems
9626 # bad practice, since in combined installations readline will have its headers
9627 # there.  We might have to resort to AC_EGREP checks to make sure we found
9628 # the proper header...
9629
9630 for ac_header in editline/readline.h
9631 do
9632 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9633 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9634   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9635 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9636 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9637   echo $ECHO_N "(cached) $ECHO_C" >&6
9638 fi
9639 ac_res=`eval echo '${'$as_ac_Header'}'`
9640                { echo "$as_me:$LINENO: result: $ac_res" >&5
9641 echo "${ECHO_T}$ac_res" >&6; }
9642 else
9643   # Is the header compilable?
9644 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9645 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9646 cat >conftest.$ac_ext <<_ACEOF
9647 /* confdefs.h.  */
9648 _ACEOF
9649 cat confdefs.h >>conftest.$ac_ext
9650 cat >>conftest.$ac_ext <<_ACEOF
9651 /* end confdefs.h.  */
9652 $ac_includes_default
9653 #include <$ac_header>
9654 _ACEOF
9655 rm -f conftest.$ac_objext
9656 if { (ac_try="$ac_compile"
9657 case "(($ac_try" in
9658   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9659   *) ac_try_echo=$ac_try;;
9660 esac
9661 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9662   (eval "$ac_compile") 2>conftest.er1
9663   ac_status=$?
9664   grep -v '^ *+' conftest.er1 >conftest.err
9665   rm -f conftest.er1
9666   cat conftest.err >&5
9667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9668   (exit $ac_status); } && {
9669          test -z "$ac_c_werror_flag" ||
9670          test ! -s conftest.err
9671        } && test -s conftest.$ac_objext; then
9672   ac_header_compiler=yes
9673 else
9674   echo "$as_me: failed program was:" >&5
9675 sed 's/^/| /' conftest.$ac_ext >&5
9676
9677         ac_header_compiler=no
9678 fi
9679
9680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9681 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9682 echo "${ECHO_T}$ac_header_compiler" >&6; }
9683
9684 # Is the header present?
9685 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9686 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9687 cat >conftest.$ac_ext <<_ACEOF
9688 /* confdefs.h.  */
9689 _ACEOF
9690 cat confdefs.h >>conftest.$ac_ext
9691 cat >>conftest.$ac_ext <<_ACEOF
9692 /* end confdefs.h.  */
9693 #include <$ac_header>
9694 _ACEOF
9695 if { (ac_try="$ac_cpp conftest.$ac_ext"
9696 case "(($ac_try" in
9697   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9698   *) ac_try_echo=$ac_try;;
9699 esac
9700 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9701   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9702   ac_status=$?
9703   grep -v '^ *+' conftest.er1 >conftest.err
9704   rm -f conftest.er1
9705   cat conftest.err >&5
9706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9707   (exit $ac_status); } >/dev/null && {
9708          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9709          test ! -s conftest.err
9710        }; then
9711   ac_header_preproc=yes
9712 else
9713   echo "$as_me: failed program was:" >&5
9714 sed 's/^/| /' conftest.$ac_ext >&5
9715
9716   ac_header_preproc=no
9717 fi
9718
9719 rm -f conftest.err conftest.$ac_ext
9720 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9721 echo "${ECHO_T}$ac_header_preproc" >&6; }
9722
9723 # So?  What about this header?
9724 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9725   yes:no: )
9726     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9727 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9728     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9729 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9730     ac_header_preproc=yes
9731     ;;
9732   no:yes:* )
9733     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9734 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9735     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9736 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9737     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9738 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9739     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9740 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9741     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9742 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9743     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9744 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9745     ( cat <<\_ASBOX
9746 ## ---------------------------------------- ##
9747 ## Report this to pgsql-bugs@postgresql.org ##
9748 ## ---------------------------------------- ##
9749 _ASBOX
9750      ) | sed "s/^/$as_me: WARNING:     /" >&2
9751     ;;
9752 esac
9753 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9754 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9755 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9756   echo $ECHO_N "(cached) $ECHO_C" >&6
9757 else
9758   eval "$as_ac_Header=\$ac_header_preproc"
9759 fi
9760 ac_res=`eval echo '${'$as_ac_Header'}'`
9761                { echo "$as_me:$LINENO: result: $ac_res" >&5
9762 echo "${ECHO_T}$ac_res" >&6; }
9763
9764 fi
9765 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9766   cat >>confdefs.h <<_ACEOF
9767 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9768 _ACEOF
9769
9770 else
9771
9772 for ac_header in readline.h
9773 do
9774 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9775 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9776   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9777 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9778 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9779   echo $ECHO_N "(cached) $ECHO_C" >&6
9780 fi
9781 ac_res=`eval echo '${'$as_ac_Header'}'`
9782                { echo "$as_me:$LINENO: result: $ac_res" >&5
9783 echo "${ECHO_T}$ac_res" >&6; }
9784 else
9785   # Is the header compilable?
9786 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9787 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9788 cat >conftest.$ac_ext <<_ACEOF
9789 /* confdefs.h.  */
9790 _ACEOF
9791 cat confdefs.h >>conftest.$ac_ext
9792 cat >>conftest.$ac_ext <<_ACEOF
9793 /* end confdefs.h.  */
9794 $ac_includes_default
9795 #include <$ac_header>
9796 _ACEOF
9797 rm -f conftest.$ac_objext
9798 if { (ac_try="$ac_compile"
9799 case "(($ac_try" in
9800   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9801   *) ac_try_echo=$ac_try;;
9802 esac
9803 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9804   (eval "$ac_compile") 2>conftest.er1
9805   ac_status=$?
9806   grep -v '^ *+' conftest.er1 >conftest.err
9807   rm -f conftest.er1
9808   cat conftest.err >&5
9809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9810   (exit $ac_status); } && {
9811          test -z "$ac_c_werror_flag" ||
9812          test ! -s conftest.err
9813        } && test -s conftest.$ac_objext; then
9814   ac_header_compiler=yes
9815 else
9816   echo "$as_me: failed program was:" >&5
9817 sed 's/^/| /' conftest.$ac_ext >&5
9818
9819         ac_header_compiler=no
9820 fi
9821
9822 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9823 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9824 echo "${ECHO_T}$ac_header_compiler" >&6; }
9825
9826 # Is the header present?
9827 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9828 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9829 cat >conftest.$ac_ext <<_ACEOF
9830 /* confdefs.h.  */
9831 _ACEOF
9832 cat confdefs.h >>conftest.$ac_ext
9833 cat >>conftest.$ac_ext <<_ACEOF
9834 /* end confdefs.h.  */
9835 #include <$ac_header>
9836 _ACEOF
9837 if { (ac_try="$ac_cpp conftest.$ac_ext"
9838 case "(($ac_try" in
9839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9840   *) ac_try_echo=$ac_try;;
9841 esac
9842 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9843   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9844   ac_status=$?
9845   grep -v '^ *+' conftest.er1 >conftest.err
9846   rm -f conftest.er1
9847   cat conftest.err >&5
9848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9849   (exit $ac_status); } >/dev/null && {
9850          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9851          test ! -s conftest.err
9852        }; then
9853   ac_header_preproc=yes
9854 else
9855   echo "$as_me: failed program was:" >&5
9856 sed 's/^/| /' conftest.$ac_ext >&5
9857
9858   ac_header_preproc=no
9859 fi
9860
9861 rm -f conftest.err conftest.$ac_ext
9862 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9863 echo "${ECHO_T}$ac_header_preproc" >&6; }
9864
9865 # So?  What about this header?
9866 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9867   yes:no: )
9868     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9869 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9870     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9871 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9872     ac_header_preproc=yes
9873     ;;
9874   no:yes:* )
9875     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9876 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9877     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9878 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9879     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9880 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9881     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9882 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9883     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9884 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9885     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9886 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9887     ( cat <<\_ASBOX
9888 ## ---------------------------------------- ##
9889 ## Report this to pgsql-bugs@postgresql.org ##
9890 ## ---------------------------------------- ##
9891 _ASBOX
9892      ) | sed "s/^/$as_me: WARNING:     /" >&2
9893     ;;
9894 esac
9895 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9896 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9897 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9898   echo $ECHO_N "(cached) $ECHO_C" >&6
9899 else
9900   eval "$as_ac_Header=\$ac_header_preproc"
9901 fi
9902 ac_res=`eval echo '${'$as_ac_Header'}'`
9903                { echo "$as_me:$LINENO: result: $ac_res" >&5
9904 echo "${ECHO_T}$ac_res" >&6; }
9905
9906 fi
9907 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9908   cat >>confdefs.h <<_ACEOF
9909 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9910 _ACEOF
9911
9912 else
9913
9914 for ac_header in readline/readline.h
9915 do
9916 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9917 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9918   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9919 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9920 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9921   echo $ECHO_N "(cached) $ECHO_C" >&6
9922 fi
9923 ac_res=`eval echo '${'$as_ac_Header'}'`
9924                { echo "$as_me:$LINENO: result: $ac_res" >&5
9925 echo "${ECHO_T}$ac_res" >&6; }
9926 else
9927   # Is the header compilable?
9928 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9929 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9930 cat >conftest.$ac_ext <<_ACEOF
9931 /* confdefs.h.  */
9932 _ACEOF
9933 cat confdefs.h >>conftest.$ac_ext
9934 cat >>conftest.$ac_ext <<_ACEOF
9935 /* end confdefs.h.  */
9936 $ac_includes_default
9937 #include <$ac_header>
9938 _ACEOF
9939 rm -f conftest.$ac_objext
9940 if { (ac_try="$ac_compile"
9941 case "(($ac_try" in
9942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9943   *) ac_try_echo=$ac_try;;
9944 esac
9945 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9946   (eval "$ac_compile") 2>conftest.er1
9947   ac_status=$?
9948   grep -v '^ *+' conftest.er1 >conftest.err
9949   rm -f conftest.er1
9950   cat conftest.err >&5
9951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9952   (exit $ac_status); } && {
9953          test -z "$ac_c_werror_flag" ||
9954          test ! -s conftest.err
9955        } && test -s conftest.$ac_objext; then
9956   ac_header_compiler=yes
9957 else
9958   echo "$as_me: failed program was:" >&5
9959 sed 's/^/| /' conftest.$ac_ext >&5
9960
9961         ac_header_compiler=no
9962 fi
9963
9964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9965 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9966 echo "${ECHO_T}$ac_header_compiler" >&6; }
9967
9968 # Is the header present?
9969 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9970 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9971 cat >conftest.$ac_ext <<_ACEOF
9972 /* confdefs.h.  */
9973 _ACEOF
9974 cat confdefs.h >>conftest.$ac_ext
9975 cat >>conftest.$ac_ext <<_ACEOF
9976 /* end confdefs.h.  */
9977 #include <$ac_header>
9978 _ACEOF
9979 if { (ac_try="$ac_cpp conftest.$ac_ext"
9980 case "(($ac_try" in
9981   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9982   *) ac_try_echo=$ac_try;;
9983 esac
9984 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9985   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9986   ac_status=$?
9987   grep -v '^ *+' conftest.er1 >conftest.err
9988   rm -f conftest.er1
9989   cat conftest.err >&5
9990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9991   (exit $ac_status); } >/dev/null && {
9992          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9993          test ! -s conftest.err
9994        }; then
9995   ac_header_preproc=yes
9996 else
9997   echo "$as_me: failed program was:" >&5
9998 sed 's/^/| /' conftest.$ac_ext >&5
9999
10000   ac_header_preproc=no
10001 fi
10002
10003 rm -f conftest.err conftest.$ac_ext
10004 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10005 echo "${ECHO_T}$ac_header_preproc" >&6; }
10006
10007 # So?  What about this header?
10008 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10009   yes:no: )
10010     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10011 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10012     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10013 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10014     ac_header_preproc=yes
10015     ;;
10016   no:yes:* )
10017     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10018 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10019     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10020 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10021     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10022 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10023     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10024 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10025     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10026 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10027     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10028 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10029     ( cat <<\_ASBOX
10030 ## ---------------------------------------- ##
10031 ## Report this to pgsql-bugs@postgresql.org ##
10032 ## ---------------------------------------- ##
10033 _ASBOX
10034      ) | sed "s/^/$as_me: WARNING:     /" >&2
10035     ;;
10036 esac
10037 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10038 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10039 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10040   echo $ECHO_N "(cached) $ECHO_C" >&6
10041 else
10042   eval "$as_ac_Header=\$ac_header_preproc"
10043 fi
10044 ac_res=`eval echo '${'$as_ac_Header'}'`
10045                { echo "$as_me:$LINENO: result: $ac_res" >&5
10046 echo "${ECHO_T}$ac_res" >&6; }
10047
10048 fi
10049 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10050   cat >>confdefs.h <<_ACEOF
10051 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10052 _ACEOF
10053
10054 else
10055   { { echo "$as_me:$LINENO: error: readline header not found
10056 If you have libedit already installed, see config.log for details on the
10057 failure.  It is possible the compiler isn't looking in the proper directory.
10058 Use --without-readline to disable libedit support." >&5
10059 echo "$as_me: error: readline header not found
10060 If you have libedit already installed, see config.log for details on the
10061 failure.  It is possible the compiler isn't looking in the proper directory.
10062 Use --without-readline to disable libedit support." >&2;}
10063    { (exit 1); exit 1; }; }
10064 fi
10065
10066 done
10067
10068 fi
10069
10070 done
10071
10072 fi
10073
10074 done
10075
10076 # Note: in a libedit installation, history.h is sometimes a dummy, and may
10077 # not be there at all.  Hence, don't complain if not found.  We must check
10078 # though, since in yet other versions it is an independent header.
10079
10080 for ac_header in editline/history.h
10081 do
10082 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10083 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10084   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10085 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10086 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10087   echo $ECHO_N "(cached) $ECHO_C" >&6
10088 fi
10089 ac_res=`eval echo '${'$as_ac_Header'}'`
10090                { echo "$as_me:$LINENO: result: $ac_res" >&5
10091 echo "${ECHO_T}$ac_res" >&6; }
10092 else
10093   # Is the header compilable?
10094 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10095 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10096 cat >conftest.$ac_ext <<_ACEOF
10097 /* confdefs.h.  */
10098 _ACEOF
10099 cat confdefs.h >>conftest.$ac_ext
10100 cat >>conftest.$ac_ext <<_ACEOF
10101 /* end confdefs.h.  */
10102 $ac_includes_default
10103 #include <$ac_header>
10104 _ACEOF
10105 rm -f conftest.$ac_objext
10106 if { (ac_try="$ac_compile"
10107 case "(($ac_try" in
10108   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10109   *) ac_try_echo=$ac_try;;
10110 esac
10111 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10112   (eval "$ac_compile") 2>conftest.er1
10113   ac_status=$?
10114   grep -v '^ *+' conftest.er1 >conftest.err
10115   rm -f conftest.er1
10116   cat conftest.err >&5
10117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10118   (exit $ac_status); } && {
10119          test -z "$ac_c_werror_flag" ||
10120          test ! -s conftest.err
10121        } && test -s conftest.$ac_objext; then
10122   ac_header_compiler=yes
10123 else
10124   echo "$as_me: failed program was:" >&5
10125 sed 's/^/| /' conftest.$ac_ext >&5
10126
10127         ac_header_compiler=no
10128 fi
10129
10130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10131 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10132 echo "${ECHO_T}$ac_header_compiler" >&6; }
10133
10134 # Is the header present?
10135 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10136 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10137 cat >conftest.$ac_ext <<_ACEOF
10138 /* confdefs.h.  */
10139 _ACEOF
10140 cat confdefs.h >>conftest.$ac_ext
10141 cat >>conftest.$ac_ext <<_ACEOF
10142 /* end confdefs.h.  */
10143 #include <$ac_header>
10144 _ACEOF
10145 if { (ac_try="$ac_cpp conftest.$ac_ext"
10146 case "(($ac_try" in
10147   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10148   *) ac_try_echo=$ac_try;;
10149 esac
10150 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10151   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10152   ac_status=$?
10153   grep -v '^ *+' conftest.er1 >conftest.err
10154   rm -f conftest.er1
10155   cat conftest.err >&5
10156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10157   (exit $ac_status); } >/dev/null && {
10158          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10159          test ! -s conftest.err
10160        }; then
10161   ac_header_preproc=yes
10162 else
10163   echo "$as_me: failed program was:" >&5
10164 sed 's/^/| /' conftest.$ac_ext >&5
10165
10166   ac_header_preproc=no
10167 fi
10168
10169 rm -f conftest.err conftest.$ac_ext
10170 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10171 echo "${ECHO_T}$ac_header_preproc" >&6; }
10172
10173 # So?  What about this header?
10174 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10175   yes:no: )
10176     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10177 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10178     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10179 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10180     ac_header_preproc=yes
10181     ;;
10182   no:yes:* )
10183     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10184 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10185     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10186 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10187     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10188 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10189     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10190 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10191     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10192 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10193     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10194 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10195     ( cat <<\_ASBOX
10196 ## ---------------------------------------- ##
10197 ## Report this to pgsql-bugs@postgresql.org ##
10198 ## ---------------------------------------- ##
10199 _ASBOX
10200      ) | sed "s/^/$as_me: WARNING:     /" >&2
10201     ;;
10202 esac
10203 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10204 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10205 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10206   echo $ECHO_N "(cached) $ECHO_C" >&6
10207 else
10208   eval "$as_ac_Header=\$ac_header_preproc"
10209 fi
10210 ac_res=`eval echo '${'$as_ac_Header'}'`
10211                { echo "$as_me:$LINENO: result: $ac_res" >&5
10212 echo "${ECHO_T}$ac_res" >&6; }
10213
10214 fi
10215 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10216   cat >>confdefs.h <<_ACEOF
10217 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10218 _ACEOF
10219
10220 else
10221
10222 for ac_header in history.h
10223 do
10224 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10225 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10226   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10227 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10228 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10229   echo $ECHO_N "(cached) $ECHO_C" >&6
10230 fi
10231 ac_res=`eval echo '${'$as_ac_Header'}'`
10232                { echo "$as_me:$LINENO: result: $ac_res" >&5
10233 echo "${ECHO_T}$ac_res" >&6; }
10234 else
10235   # Is the header compilable?
10236 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10237 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10238 cat >conftest.$ac_ext <<_ACEOF
10239 /* confdefs.h.  */
10240 _ACEOF
10241 cat confdefs.h >>conftest.$ac_ext
10242 cat >>conftest.$ac_ext <<_ACEOF
10243 /* end confdefs.h.  */
10244 $ac_includes_default
10245 #include <$ac_header>
10246 _ACEOF
10247 rm -f conftest.$ac_objext
10248 if { (ac_try="$ac_compile"
10249 case "(($ac_try" in
10250   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10251   *) ac_try_echo=$ac_try;;
10252 esac
10253 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10254   (eval "$ac_compile") 2>conftest.er1
10255   ac_status=$?
10256   grep -v '^ *+' conftest.er1 >conftest.err
10257   rm -f conftest.er1
10258   cat conftest.err >&5
10259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10260   (exit $ac_status); } && {
10261          test -z "$ac_c_werror_flag" ||
10262          test ! -s conftest.err
10263        } && test -s conftest.$ac_objext; then
10264   ac_header_compiler=yes
10265 else
10266   echo "$as_me: failed program was:" >&5
10267 sed 's/^/| /' conftest.$ac_ext >&5
10268
10269         ac_header_compiler=no
10270 fi
10271
10272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10273 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10274 echo "${ECHO_T}$ac_header_compiler" >&6; }
10275
10276 # Is the header present?
10277 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10278 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10279 cat >conftest.$ac_ext <<_ACEOF
10280 /* confdefs.h.  */
10281 _ACEOF
10282 cat confdefs.h >>conftest.$ac_ext
10283 cat >>conftest.$ac_ext <<_ACEOF
10284 /* end confdefs.h.  */
10285 #include <$ac_header>
10286 _ACEOF
10287 if { (ac_try="$ac_cpp conftest.$ac_ext"
10288 case "(($ac_try" in
10289   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10290   *) ac_try_echo=$ac_try;;
10291 esac
10292 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10293   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10294   ac_status=$?
10295   grep -v '^ *+' conftest.er1 >conftest.err
10296   rm -f conftest.er1
10297   cat conftest.err >&5
10298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10299   (exit $ac_status); } >/dev/null && {
10300          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10301          test ! -s conftest.err
10302        }; then
10303   ac_header_preproc=yes
10304 else
10305   echo "$as_me: failed program was:" >&5
10306 sed 's/^/| /' conftest.$ac_ext >&5
10307
10308   ac_header_preproc=no
10309 fi
10310
10311 rm -f conftest.err conftest.$ac_ext
10312 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10313 echo "${ECHO_T}$ac_header_preproc" >&6; }
10314
10315 # So?  What about this header?
10316 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10317   yes:no: )
10318     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10319 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10320     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10321 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10322     ac_header_preproc=yes
10323     ;;
10324   no:yes:* )
10325     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10326 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10327     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10328 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10329     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10330 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10331     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10332 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10333     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10334 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10335     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10336 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10337     ( cat <<\_ASBOX
10338 ## ---------------------------------------- ##
10339 ## Report this to pgsql-bugs@postgresql.org ##
10340 ## ---------------------------------------- ##
10341 _ASBOX
10342      ) | sed "s/^/$as_me: WARNING:     /" >&2
10343     ;;
10344 esac
10345 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10346 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10347 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10348   echo $ECHO_N "(cached) $ECHO_C" >&6
10349 else
10350   eval "$as_ac_Header=\$ac_header_preproc"
10351 fi
10352 ac_res=`eval echo '${'$as_ac_Header'}'`
10353                { echo "$as_me:$LINENO: result: $ac_res" >&5
10354 echo "${ECHO_T}$ac_res" >&6; }
10355
10356 fi
10357 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10358   cat >>confdefs.h <<_ACEOF
10359 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10360 _ACEOF
10361
10362 else
10363
10364 for ac_header in readline/history.h
10365 do
10366 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10367 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10368   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10369 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10370 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10371   echo $ECHO_N "(cached) $ECHO_C" >&6
10372 fi
10373 ac_res=`eval echo '${'$as_ac_Header'}'`
10374                { echo "$as_me:$LINENO: result: $ac_res" >&5
10375 echo "${ECHO_T}$ac_res" >&6; }
10376 else
10377   # Is the header compilable?
10378 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10379 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10380 cat >conftest.$ac_ext <<_ACEOF
10381 /* confdefs.h.  */
10382 _ACEOF
10383 cat confdefs.h >>conftest.$ac_ext
10384 cat >>conftest.$ac_ext <<_ACEOF
10385 /* end confdefs.h.  */
10386 $ac_includes_default
10387 #include <$ac_header>
10388 _ACEOF
10389 rm -f conftest.$ac_objext
10390 if { (ac_try="$ac_compile"
10391 case "(($ac_try" in
10392   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10393   *) ac_try_echo=$ac_try;;
10394 esac
10395 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10396   (eval "$ac_compile") 2>conftest.er1
10397   ac_status=$?
10398   grep -v '^ *+' conftest.er1 >conftest.err
10399   rm -f conftest.er1
10400   cat conftest.err >&5
10401   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10402   (exit $ac_status); } && {
10403          test -z "$ac_c_werror_flag" ||
10404          test ! -s conftest.err
10405        } && test -s conftest.$ac_objext; then
10406   ac_header_compiler=yes
10407 else
10408   echo "$as_me: failed program was:" >&5
10409 sed 's/^/| /' conftest.$ac_ext >&5
10410
10411         ac_header_compiler=no
10412 fi
10413
10414 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10415 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10416 echo "${ECHO_T}$ac_header_compiler" >&6; }
10417
10418 # Is the header present?
10419 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10420 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10421 cat >conftest.$ac_ext <<_ACEOF
10422 /* confdefs.h.  */
10423 _ACEOF
10424 cat confdefs.h >>conftest.$ac_ext
10425 cat >>conftest.$ac_ext <<_ACEOF
10426 /* end confdefs.h.  */
10427 #include <$ac_header>
10428 _ACEOF
10429 if { (ac_try="$ac_cpp conftest.$ac_ext"
10430 case "(($ac_try" in
10431   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10432   *) ac_try_echo=$ac_try;;
10433 esac
10434 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10435   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10436   ac_status=$?
10437   grep -v '^ *+' conftest.er1 >conftest.err
10438   rm -f conftest.er1
10439   cat conftest.err >&5
10440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10441   (exit $ac_status); } >/dev/null && {
10442          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10443          test ! -s conftest.err
10444        }; then
10445   ac_header_preproc=yes
10446 else
10447   echo "$as_me: failed program was:" >&5
10448 sed 's/^/| /' conftest.$ac_ext >&5
10449
10450   ac_header_preproc=no
10451 fi
10452
10453 rm -f conftest.err conftest.$ac_ext
10454 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10455 echo "${ECHO_T}$ac_header_preproc" >&6; }
10456
10457 # So?  What about this header?
10458 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10459   yes:no: )
10460     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10461 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10462     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10463 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10464     ac_header_preproc=yes
10465     ;;
10466   no:yes:* )
10467     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10468 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10469     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10470 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10471     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10472 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10473     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10474 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10475     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10476 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10477     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10478 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10479     ( cat <<\_ASBOX
10480 ## ---------------------------------------- ##
10481 ## Report this to pgsql-bugs@postgresql.org ##
10482 ## ---------------------------------------- ##
10483 _ASBOX
10484      ) | sed "s/^/$as_me: WARNING:     /" >&2
10485     ;;
10486 esac
10487 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10488 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10489 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10490   echo $ECHO_N "(cached) $ECHO_C" >&6
10491 else
10492   eval "$as_ac_Header=\$ac_header_preproc"
10493 fi
10494 ac_res=`eval echo '${'$as_ac_Header'}'`
10495                { echo "$as_me:$LINENO: result: $ac_res" >&5
10496 echo "${ECHO_T}$ac_res" >&6; }
10497
10498 fi
10499 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10500   cat >>confdefs.h <<_ACEOF
10501 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10502 _ACEOF
10503
10504 fi
10505
10506 done
10507
10508 fi
10509
10510 done
10511
10512 fi
10513
10514 done
10515
10516 fi
10517
10518 if test "$with_zlib" = yes; then
10519   if test "${ac_cv_header_zlib_h+set}" = set; then
10520   { echo "$as_me:$LINENO: checking for zlib.h" >&5
10521 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6; }
10522 if test "${ac_cv_header_zlib_h+set}" = set; then
10523   echo $ECHO_N "(cached) $ECHO_C" >&6
10524 fi
10525 { echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
10526 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6; }
10527 else
10528   # Is the header compilable?
10529 { echo "$as_me:$LINENO: checking zlib.h usability" >&5
10530 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6; }
10531 cat >conftest.$ac_ext <<_ACEOF
10532 /* confdefs.h.  */
10533 _ACEOF
10534 cat confdefs.h >>conftest.$ac_ext
10535 cat >>conftest.$ac_ext <<_ACEOF
10536 /* end confdefs.h.  */
10537 $ac_includes_default
10538 #include <zlib.h>
10539 _ACEOF
10540 rm -f conftest.$ac_objext
10541 if { (ac_try="$ac_compile"
10542 case "(($ac_try" in
10543   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10544   *) ac_try_echo=$ac_try;;
10545 esac
10546 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10547   (eval "$ac_compile") 2>conftest.er1
10548   ac_status=$?
10549   grep -v '^ *+' conftest.er1 >conftest.err
10550   rm -f conftest.er1
10551   cat conftest.err >&5
10552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10553   (exit $ac_status); } && {
10554          test -z "$ac_c_werror_flag" ||
10555          test ! -s conftest.err
10556        } && test -s conftest.$ac_objext; then
10557   ac_header_compiler=yes
10558 else
10559   echo "$as_me: failed program was:" >&5
10560 sed 's/^/| /' conftest.$ac_ext >&5
10561
10562         ac_header_compiler=no
10563 fi
10564
10565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10566 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10567 echo "${ECHO_T}$ac_header_compiler" >&6; }
10568
10569 # Is the header present?
10570 { echo "$as_me:$LINENO: checking zlib.h presence" >&5
10571 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6; }
10572 cat >conftest.$ac_ext <<_ACEOF
10573 /* confdefs.h.  */
10574 _ACEOF
10575 cat confdefs.h >>conftest.$ac_ext
10576 cat >>conftest.$ac_ext <<_ACEOF
10577 /* end confdefs.h.  */
10578 #include <zlib.h>
10579 _ACEOF
10580 if { (ac_try="$ac_cpp conftest.$ac_ext"
10581 case "(($ac_try" in
10582   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10583   *) ac_try_echo=$ac_try;;
10584 esac
10585 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10586   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10587   ac_status=$?
10588   grep -v '^ *+' conftest.er1 >conftest.err
10589   rm -f conftest.er1
10590   cat conftest.err >&5
10591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10592   (exit $ac_status); } >/dev/null && {
10593          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10594          test ! -s conftest.err
10595        }; then
10596   ac_header_preproc=yes
10597 else
10598   echo "$as_me: failed program was:" >&5
10599 sed 's/^/| /' conftest.$ac_ext >&5
10600
10601   ac_header_preproc=no
10602 fi
10603
10604 rm -f conftest.err conftest.$ac_ext
10605 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10606 echo "${ECHO_T}$ac_header_preproc" >&6; }
10607
10608 # So?  What about this header?
10609 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10610   yes:no: )
10611     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
10612 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10613     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
10614 echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
10615     ac_header_preproc=yes
10616     ;;
10617   no:yes:* )
10618     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
10619 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
10620     { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
10621 echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
10622     { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
10623 echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
10624     { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
10625 echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10626     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
10627 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
10628     { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
10629 echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
10630     ( cat <<\_ASBOX
10631 ## ---------------------------------------- ##
10632 ## Report this to pgsql-bugs@postgresql.org ##
10633 ## ---------------------------------------- ##
10634 _ASBOX
10635      ) | sed "s/^/$as_me: WARNING:     /" >&2
10636     ;;
10637 esac
10638 { echo "$as_me:$LINENO: checking for zlib.h" >&5
10639 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6; }
10640 if test "${ac_cv_header_zlib_h+set}" = set; then
10641   echo $ECHO_N "(cached) $ECHO_C" >&6
10642 else
10643   ac_cv_header_zlib_h=$ac_header_preproc
10644 fi
10645 { echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
10646 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6; }
10647
10648 fi
10649 if test $ac_cv_header_zlib_h = yes; then
10650   :
10651 else
10652   { { echo "$as_me:$LINENO: error: zlib header not found
10653 If you have zlib already installed, see config.log for details on the
10654 failure.  It is possible the compiler isn't looking in the proper directory.
10655 Use --without-zlib to disable zlib support." >&5
10656 echo "$as_me: error: zlib header not found
10657 If you have zlib already installed, see config.log for details on the
10658 failure.  It is possible the compiler isn't looking in the proper directory.
10659 Use --without-zlib to disable zlib support." >&2;}
10660    { (exit 1); exit 1; }; }
10661 fi
10662
10663
10664 fi
10665
10666 if test "$with_gssapi" = yes ; then
10667
10668 for ac_header in gssapi/gssapi.h
10669 do
10670 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10671 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10672   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10673 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10674 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10675   echo $ECHO_N "(cached) $ECHO_C" >&6
10676 fi
10677 ac_res=`eval echo '${'$as_ac_Header'}'`
10678                { echo "$as_me:$LINENO: result: $ac_res" >&5
10679 echo "${ECHO_T}$ac_res" >&6; }
10680 else
10681   # Is the header compilable?
10682 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10683 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10684 cat >conftest.$ac_ext <<_ACEOF
10685 /* confdefs.h.  */
10686 _ACEOF
10687 cat confdefs.h >>conftest.$ac_ext
10688 cat >>conftest.$ac_ext <<_ACEOF
10689 /* end confdefs.h.  */
10690 $ac_includes_default
10691 #include <$ac_header>
10692 _ACEOF
10693 rm -f conftest.$ac_objext
10694 if { (ac_try="$ac_compile"
10695 case "(($ac_try" in
10696   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10697   *) ac_try_echo=$ac_try;;
10698 esac
10699 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10700   (eval "$ac_compile") 2>conftest.er1
10701   ac_status=$?
10702   grep -v '^ *+' conftest.er1 >conftest.err
10703   rm -f conftest.er1
10704   cat conftest.err >&5
10705   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10706   (exit $ac_status); } && {
10707          test -z "$ac_c_werror_flag" ||
10708          test ! -s conftest.err
10709        } && test -s conftest.$ac_objext; then
10710   ac_header_compiler=yes
10711 else
10712   echo "$as_me: failed program was:" >&5
10713 sed 's/^/| /' conftest.$ac_ext >&5
10714
10715         ac_header_compiler=no
10716 fi
10717
10718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10719 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10720 echo "${ECHO_T}$ac_header_compiler" >&6; }
10721
10722 # Is the header present?
10723 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10724 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10725 cat >conftest.$ac_ext <<_ACEOF
10726 /* confdefs.h.  */
10727 _ACEOF
10728 cat confdefs.h >>conftest.$ac_ext
10729 cat >>conftest.$ac_ext <<_ACEOF
10730 /* end confdefs.h.  */
10731 #include <$ac_header>
10732 _ACEOF
10733 if { (ac_try="$ac_cpp conftest.$ac_ext"
10734 case "(($ac_try" in
10735   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10736   *) ac_try_echo=$ac_try;;
10737 esac
10738 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10739   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10740   ac_status=$?
10741   grep -v '^ *+' conftest.er1 >conftest.err
10742   rm -f conftest.er1
10743   cat conftest.err >&5
10744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10745   (exit $ac_status); } >/dev/null && {
10746          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10747          test ! -s conftest.err
10748        }; then
10749   ac_header_preproc=yes
10750 else
10751   echo "$as_me: failed program was:" >&5
10752 sed 's/^/| /' conftest.$ac_ext >&5
10753
10754   ac_header_preproc=no
10755 fi
10756
10757 rm -f conftest.err conftest.$ac_ext
10758 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10759 echo "${ECHO_T}$ac_header_preproc" >&6; }
10760
10761 # So?  What about this header?
10762 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10763   yes:no: )
10764     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10765 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10766     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10767 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10768     ac_header_preproc=yes
10769     ;;
10770   no:yes:* )
10771     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10772 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10773     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10774 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10775     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10776 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10777     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10778 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10779     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10780 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10781     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10782 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10783     ( cat <<\_ASBOX
10784 ## ---------------------------------------- ##
10785 ## Report this to pgsql-bugs@postgresql.org ##
10786 ## ---------------------------------------- ##
10787 _ASBOX
10788      ) | sed "s/^/$as_me: WARNING:     /" >&2
10789     ;;
10790 esac
10791 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10792 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10793 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10794   echo $ECHO_N "(cached) $ECHO_C" >&6
10795 else
10796   eval "$as_ac_Header=\$ac_header_preproc"
10797 fi
10798 ac_res=`eval echo '${'$as_ac_Header'}'`
10799                { echo "$as_me:$LINENO: result: $ac_res" >&5
10800 echo "${ECHO_T}$ac_res" >&6; }
10801
10802 fi
10803 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10804   cat >>confdefs.h <<_ACEOF
10805 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10806 _ACEOF
10807
10808 else
10809
10810 for ac_header in gssapi.h
10811 do
10812 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10813 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10814   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10815 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10816 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10817   echo $ECHO_N "(cached) $ECHO_C" >&6
10818 fi
10819 ac_res=`eval echo '${'$as_ac_Header'}'`
10820                { echo "$as_me:$LINENO: result: $ac_res" >&5
10821 echo "${ECHO_T}$ac_res" >&6; }
10822 else
10823   # Is the header compilable?
10824 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10825 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10826 cat >conftest.$ac_ext <<_ACEOF
10827 /* confdefs.h.  */
10828 _ACEOF
10829 cat confdefs.h >>conftest.$ac_ext
10830 cat >>conftest.$ac_ext <<_ACEOF
10831 /* end confdefs.h.  */
10832 $ac_includes_default
10833 #include <$ac_header>
10834 _ACEOF
10835 rm -f conftest.$ac_objext
10836 if { (ac_try="$ac_compile"
10837 case "(($ac_try" in
10838   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10839   *) ac_try_echo=$ac_try;;
10840 esac
10841 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10842   (eval "$ac_compile") 2>conftest.er1
10843   ac_status=$?
10844   grep -v '^ *+' conftest.er1 >conftest.err
10845   rm -f conftest.er1
10846   cat conftest.err >&5
10847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10848   (exit $ac_status); } && {
10849          test -z "$ac_c_werror_flag" ||
10850          test ! -s conftest.err
10851        } && test -s conftest.$ac_objext; then
10852   ac_header_compiler=yes
10853 else
10854   echo "$as_me: failed program was:" >&5
10855 sed 's/^/| /' conftest.$ac_ext >&5
10856
10857         ac_header_compiler=no
10858 fi
10859
10860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10861 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10862 echo "${ECHO_T}$ac_header_compiler" >&6; }
10863
10864 # Is the header present?
10865 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10866 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10867 cat >conftest.$ac_ext <<_ACEOF
10868 /* confdefs.h.  */
10869 _ACEOF
10870 cat confdefs.h >>conftest.$ac_ext
10871 cat >>conftest.$ac_ext <<_ACEOF
10872 /* end confdefs.h.  */
10873 #include <$ac_header>
10874 _ACEOF
10875 if { (ac_try="$ac_cpp conftest.$ac_ext"
10876 case "(($ac_try" in
10877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10878   *) ac_try_echo=$ac_try;;
10879 esac
10880 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10881   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10882   ac_status=$?
10883   grep -v '^ *+' conftest.er1 >conftest.err
10884   rm -f conftest.er1
10885   cat conftest.err >&5
10886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10887   (exit $ac_status); } >/dev/null && {
10888          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10889          test ! -s conftest.err
10890        }; then
10891   ac_header_preproc=yes
10892 else
10893   echo "$as_me: failed program was:" >&5
10894 sed 's/^/| /' conftest.$ac_ext >&5
10895
10896   ac_header_preproc=no
10897 fi
10898
10899 rm -f conftest.err conftest.$ac_ext
10900 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10901 echo "${ECHO_T}$ac_header_preproc" >&6; }
10902
10903 # So?  What about this header?
10904 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10905   yes:no: )
10906     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10907 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10908     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10909 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10910     ac_header_preproc=yes
10911     ;;
10912   no:yes:* )
10913     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10914 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10915     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10916 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10917     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10918 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10919     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10920 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10921     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10922 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10923     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10924 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10925     ( cat <<\_ASBOX
10926 ## ---------------------------------------- ##
10927 ## Report this to pgsql-bugs@postgresql.org ##
10928 ## ---------------------------------------- ##
10929 _ASBOX
10930      ) | sed "s/^/$as_me: WARNING:     /" >&2
10931     ;;
10932 esac
10933 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10934 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10935 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10936   echo $ECHO_N "(cached) $ECHO_C" >&6
10937 else
10938   eval "$as_ac_Header=\$ac_header_preproc"
10939 fi
10940 ac_res=`eval echo '${'$as_ac_Header'}'`
10941                { echo "$as_me:$LINENO: result: $ac_res" >&5
10942 echo "${ECHO_T}$ac_res" >&6; }
10943
10944 fi
10945 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10946   cat >>confdefs.h <<_ACEOF
10947 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10948 _ACEOF
10949
10950 else
10951   { { echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
10952 echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
10953    { (exit 1); exit 1; }; }
10954 fi
10955
10956 done
10957
10958 fi
10959
10960 done
10961
10962 fi
10963
10964 if test "$with_krb5" = yes ; then
10965   if test "${ac_cv_header_krb5_h+set}" = set; then
10966   { echo "$as_me:$LINENO: checking for krb5.h" >&5
10967 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6; }
10968 if test "${ac_cv_header_krb5_h+set}" = set; then
10969   echo $ECHO_N "(cached) $ECHO_C" >&6
10970 fi
10971 { echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
10972 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6; }
10973 else
10974   # Is the header compilable?
10975 { echo "$as_me:$LINENO: checking krb5.h usability" >&5
10976 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6; }
10977 cat >conftest.$ac_ext <<_ACEOF
10978 /* confdefs.h.  */
10979 _ACEOF
10980 cat confdefs.h >>conftest.$ac_ext
10981 cat >>conftest.$ac_ext <<_ACEOF
10982 /* end confdefs.h.  */
10983 $ac_includes_default
10984 #include <krb5.h>
10985 _ACEOF
10986 rm -f conftest.$ac_objext
10987 if { (ac_try="$ac_compile"
10988 case "(($ac_try" in
10989   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10990   *) ac_try_echo=$ac_try;;
10991 esac
10992 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10993   (eval "$ac_compile") 2>conftest.er1
10994   ac_status=$?
10995   grep -v '^ *+' conftest.er1 >conftest.err
10996   rm -f conftest.er1
10997   cat conftest.err >&5
10998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10999   (exit $ac_status); } && {
11000          test -z "$ac_c_werror_flag" ||
11001          test ! -s conftest.err
11002        } && test -s conftest.$ac_objext; then
11003   ac_header_compiler=yes
11004 else
11005   echo "$as_me: failed program was:" >&5
11006 sed 's/^/| /' conftest.$ac_ext >&5
11007
11008         ac_header_compiler=no
11009 fi
11010
11011 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11012 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11013 echo "${ECHO_T}$ac_header_compiler" >&6; }
11014
11015 # Is the header present?
11016 { echo "$as_me:$LINENO: checking krb5.h presence" >&5
11017 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6; }
11018 cat >conftest.$ac_ext <<_ACEOF
11019 /* confdefs.h.  */
11020 _ACEOF
11021 cat confdefs.h >>conftest.$ac_ext
11022 cat >>conftest.$ac_ext <<_ACEOF
11023 /* end confdefs.h.  */
11024 #include <krb5.h>
11025 _ACEOF
11026 if { (ac_try="$ac_cpp conftest.$ac_ext"
11027 case "(($ac_try" in
11028   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11029   *) ac_try_echo=$ac_try;;
11030 esac
11031 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11032   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11033   ac_status=$?
11034   grep -v '^ *+' conftest.er1 >conftest.err
11035   rm -f conftest.er1
11036   cat conftest.err >&5
11037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11038   (exit $ac_status); } >/dev/null && {
11039          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11040          test ! -s conftest.err
11041        }; then
11042   ac_header_preproc=yes
11043 else
11044   echo "$as_me: failed program was:" >&5
11045 sed 's/^/| /' conftest.$ac_ext >&5
11046
11047   ac_header_preproc=no
11048 fi
11049
11050 rm -f conftest.err conftest.$ac_ext
11051 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11052 echo "${ECHO_T}$ac_header_preproc" >&6; }
11053
11054 # So?  What about this header?
11055 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11056   yes:no: )
11057     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
11058 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11059     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
11060 echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
11061     ac_header_preproc=yes
11062     ;;
11063   no:yes:* )
11064     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
11065 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
11066     { echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
11067 echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
11068     { echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
11069 echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
11070     { echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
11071 echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11072     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
11073 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
11074     { echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
11075 echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
11076     ( cat <<\_ASBOX
11077 ## ---------------------------------------- ##
11078 ## Report this to pgsql-bugs@postgresql.org ##
11079 ## ---------------------------------------- ##
11080 _ASBOX
11081      ) | sed "s/^/$as_me: WARNING:     /" >&2
11082     ;;
11083 esac
11084 { echo "$as_me:$LINENO: checking for krb5.h" >&5
11085 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6; }
11086 if test "${ac_cv_header_krb5_h+set}" = set; then
11087   echo $ECHO_N "(cached) $ECHO_C" >&6
11088 else
11089   ac_cv_header_krb5_h=$ac_header_preproc
11090 fi
11091 { echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
11092 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6; }
11093
11094 fi
11095 if test $ac_cv_header_krb5_h = yes; then
11096   :
11097 else
11098   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
11099 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
11100    { (exit 1); exit 1; }; }
11101 fi
11102
11103
11104 fi
11105
11106 if test "$with_openssl" = yes ; then
11107   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
11108   { echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
11109 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6; }
11110 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
11111   echo $ECHO_N "(cached) $ECHO_C" >&6
11112 fi
11113 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
11114 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6; }
11115 else
11116   # Is the header compilable?
11117 { echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
11118 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6; }
11119 cat >conftest.$ac_ext <<_ACEOF
11120 /* confdefs.h.  */
11121 _ACEOF
11122 cat confdefs.h >>conftest.$ac_ext
11123 cat >>conftest.$ac_ext <<_ACEOF
11124 /* end confdefs.h.  */
11125 $ac_includes_default
11126 #include <openssl/ssl.h>
11127 _ACEOF
11128 rm -f conftest.$ac_objext
11129 if { (ac_try="$ac_compile"
11130 case "(($ac_try" in
11131   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11132   *) ac_try_echo=$ac_try;;
11133 esac
11134 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11135   (eval "$ac_compile") 2>conftest.er1
11136   ac_status=$?
11137   grep -v '^ *+' conftest.er1 >conftest.err
11138   rm -f conftest.er1
11139   cat conftest.err >&5
11140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11141   (exit $ac_status); } && {
11142          test -z "$ac_c_werror_flag" ||
11143          test ! -s conftest.err
11144        } && test -s conftest.$ac_objext; then
11145   ac_header_compiler=yes
11146 else
11147   echo "$as_me: failed program was:" >&5
11148 sed 's/^/| /' conftest.$ac_ext >&5
11149
11150         ac_header_compiler=no
11151 fi
11152
11153 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11154 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11155 echo "${ECHO_T}$ac_header_compiler" >&6; }
11156
11157 # Is the header present?
11158 { echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
11159 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6; }
11160 cat >conftest.$ac_ext <<_ACEOF
11161 /* confdefs.h.  */
11162 _ACEOF
11163 cat confdefs.h >>conftest.$ac_ext
11164 cat >>conftest.$ac_ext <<_ACEOF
11165 /* end confdefs.h.  */
11166 #include <openssl/ssl.h>
11167 _ACEOF
11168 if { (ac_try="$ac_cpp conftest.$ac_ext"
11169 case "(($ac_try" in
11170   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11171   *) ac_try_echo=$ac_try;;
11172 esac
11173 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11174   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11175   ac_status=$?
11176   grep -v '^ *+' conftest.er1 >conftest.err
11177   rm -f conftest.er1
11178   cat conftest.err >&5
11179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11180   (exit $ac_status); } >/dev/null && {
11181          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11182          test ! -s conftest.err
11183        }; then
11184   ac_header_preproc=yes
11185 else
11186   echo "$as_me: failed program was:" >&5
11187 sed 's/^/| /' conftest.$ac_ext >&5
11188
11189   ac_header_preproc=no
11190 fi
11191
11192 rm -f conftest.err conftest.$ac_ext
11193 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11194 echo "${ECHO_T}$ac_header_preproc" >&6; }
11195
11196 # So?  What about this header?
11197 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11198   yes:no: )
11199     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
11200 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11201     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
11202 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
11203     ac_header_preproc=yes
11204     ;;
11205   no:yes:* )
11206     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
11207 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
11208     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
11209 echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
11210     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
11211 echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
11212     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
11213 echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11214     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
11215 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
11216     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
11217 echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
11218     ( cat <<\_ASBOX
11219 ## ---------------------------------------- ##
11220 ## Report this to pgsql-bugs@postgresql.org ##
11221 ## ---------------------------------------- ##
11222 _ASBOX
11223      ) | sed "s/^/$as_me: WARNING:     /" >&2
11224     ;;
11225 esac
11226 { echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
11227 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6; }
11228 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
11229   echo $ECHO_N "(cached) $ECHO_C" >&6
11230 else
11231   ac_cv_header_openssl_ssl_h=$ac_header_preproc
11232 fi
11233 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
11234 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6; }
11235
11236 fi
11237 if test $ac_cv_header_openssl_ssl_h = yes; then
11238   :
11239 else
11240   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
11241 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
11242    { (exit 1); exit 1; }; }
11243 fi
11244
11245
11246   if test "${ac_cv_header_openssl_err_h+set}" = set; then
11247   { echo "$as_me:$LINENO: checking for openssl/err.h" >&5
11248 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6; }
11249 if test "${ac_cv_header_openssl_err_h+set}" = set; then
11250   echo $ECHO_N "(cached) $ECHO_C" >&6
11251 fi
11252 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
11253 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6; }
11254 else
11255   # Is the header compilable?
11256 { echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
11257 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6; }
11258 cat >conftest.$ac_ext <<_ACEOF
11259 /* confdefs.h.  */
11260 _ACEOF
11261 cat confdefs.h >>conftest.$ac_ext
11262 cat >>conftest.$ac_ext <<_ACEOF
11263 /* end confdefs.h.  */
11264 $ac_includes_default
11265 #include <openssl/err.h>
11266 _ACEOF
11267 rm -f conftest.$ac_objext
11268 if { (ac_try="$ac_compile"
11269 case "(($ac_try" in
11270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11271   *) ac_try_echo=$ac_try;;
11272 esac
11273 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11274   (eval "$ac_compile") 2>conftest.er1
11275   ac_status=$?
11276   grep -v '^ *+' conftest.er1 >conftest.err
11277   rm -f conftest.er1
11278   cat conftest.err >&5
11279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11280   (exit $ac_status); } && {
11281          test -z "$ac_c_werror_flag" ||
11282          test ! -s conftest.err
11283        } && test -s conftest.$ac_objext; then
11284   ac_header_compiler=yes
11285 else
11286   echo "$as_me: failed program was:" >&5
11287 sed 's/^/| /' conftest.$ac_ext >&5
11288
11289         ac_header_compiler=no
11290 fi
11291
11292 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11293 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11294 echo "${ECHO_T}$ac_header_compiler" >&6; }
11295
11296 # Is the header present?
11297 { echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
11298 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6; }
11299 cat >conftest.$ac_ext <<_ACEOF
11300 /* confdefs.h.  */
11301 _ACEOF
11302 cat confdefs.h >>conftest.$ac_ext
11303 cat >>conftest.$ac_ext <<_ACEOF
11304 /* end confdefs.h.  */
11305 #include <openssl/err.h>
11306 _ACEOF
11307 if { (ac_try="$ac_cpp conftest.$ac_ext"
11308 case "(($ac_try" in
11309   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11310   *) ac_try_echo=$ac_try;;
11311 esac
11312 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11313   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11314   ac_status=$?
11315   grep -v '^ *+' conftest.er1 >conftest.err
11316   rm -f conftest.er1
11317   cat conftest.err >&5
11318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11319   (exit $ac_status); } >/dev/null && {
11320          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11321          test ! -s conftest.err
11322        }; then
11323   ac_header_preproc=yes
11324 else
11325   echo "$as_me: failed program was:" >&5
11326 sed 's/^/| /' conftest.$ac_ext >&5
11327
11328   ac_header_preproc=no
11329 fi
11330
11331 rm -f conftest.err conftest.$ac_ext
11332 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11333 echo "${ECHO_T}$ac_header_preproc" >&6; }
11334
11335 # So?  What about this header?
11336 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11337   yes:no: )
11338     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
11339 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11340     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
11341 echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
11342     ac_header_preproc=yes
11343     ;;
11344   no:yes:* )
11345     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
11346 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
11347     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
11348 echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
11349     { echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
11350 echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
11351     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
11352 echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11353     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
11354 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
11355     { echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
11356 echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
11357     ( cat <<\_ASBOX
11358 ## ---------------------------------------- ##
11359 ## Report this to pgsql-bugs@postgresql.org ##
11360 ## ---------------------------------------- ##
11361 _ASBOX
11362      ) | sed "s/^/$as_me: WARNING:     /" >&2
11363     ;;
11364 esac
11365 { echo "$as_me:$LINENO: checking for openssl/err.h" >&5
11366 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6; }
11367 if test "${ac_cv_header_openssl_err_h+set}" = set; then
11368   echo $ECHO_N "(cached) $ECHO_C" >&6
11369 else
11370   ac_cv_header_openssl_err_h=$ac_header_preproc
11371 fi
11372 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
11373 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6; }
11374
11375 fi
11376 if test $ac_cv_header_openssl_err_h = yes; then
11377   :
11378 else
11379   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
11380 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
11381    { (exit 1); exit 1; }; }
11382 fi
11383
11384
11385
11386 for ac_func in ERR_set_mark
11387 do
11388 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11389 { echo "$as_me:$LINENO: checking for $ac_func" >&5
11390 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11391 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11392   echo $ECHO_N "(cached) $ECHO_C" >&6
11393 else
11394   cat >conftest.$ac_ext <<_ACEOF
11395 /* confdefs.h.  */
11396 _ACEOF
11397 cat confdefs.h >>conftest.$ac_ext
11398 cat >>conftest.$ac_ext <<_ACEOF
11399 /* end confdefs.h.  */
11400 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11401    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11402 #define $ac_func innocuous_$ac_func
11403
11404 /* System header to define __stub macros and hopefully few prototypes,
11405     which can conflict with char $ac_func (); below.
11406     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11407     <limits.h> exists even on freestanding compilers.  */
11408
11409 #ifdef __STDC__
11410 # include <limits.h>
11411 #else
11412 # include <assert.h>
11413 #endif
11414
11415 #undef $ac_func
11416
11417 /* Override any GCC internal prototype to avoid an error.
11418    Use char because int might match the return type of a GCC
11419    builtin and then its argument prototype would still apply.  */
11420 #ifdef __cplusplus
11421 extern "C"
11422 #endif
11423 char $ac_func ();
11424 /* The GNU C library defines this for functions which it implements
11425     to always fail with ENOSYS.  Some functions are actually named
11426     something starting with __ and the normal name is an alias.  */
11427 #if defined __stub_$ac_func || defined __stub___$ac_func
11428 choke me
11429 #endif
11430
11431 int
11432 main ()
11433 {
11434 return $ac_func ();
11435   ;
11436   return 0;
11437 }
11438 _ACEOF
11439 rm -f conftest.$ac_objext conftest$ac_exeext
11440 if { (ac_try="$ac_link"
11441 case "(($ac_try" in
11442   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11443   *) ac_try_echo=$ac_try;;
11444 esac
11445 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11446   (eval "$ac_link") 2>conftest.er1
11447   ac_status=$?
11448   grep -v '^ *+' conftest.er1 >conftest.err
11449   rm -f conftest.er1
11450   cat conftest.err >&5
11451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11452   (exit $ac_status); } && {
11453          test -z "$ac_c_werror_flag" ||
11454          test ! -s conftest.err
11455        } && test -s conftest$ac_exeext &&
11456        $as_test_x conftest$ac_exeext; then
11457   eval "$as_ac_var=yes"
11458 else
11459   echo "$as_me: failed program was:" >&5
11460 sed 's/^/| /' conftest.$ac_ext >&5
11461
11462         eval "$as_ac_var=no"
11463 fi
11464
11465 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11466       conftest$ac_exeext conftest.$ac_ext
11467 fi
11468 ac_res=`eval echo '${'$as_ac_var'}'`
11469                { echo "$as_me:$LINENO: result: $ac_res" >&5
11470 echo "${ECHO_T}$ac_res" >&6; }
11471 if test `eval echo '${'$as_ac_var'}'` = yes; then
11472   cat >>confdefs.h <<_ACEOF
11473 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11474 _ACEOF
11475
11476 fi
11477 done
11478
11479 fi
11480
11481 if test "$with_pam" = yes ; then
11482
11483 for ac_header in security/pam_appl.h
11484 do
11485 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11486 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11487   { echo "$as_me:$LINENO: checking for $ac_header" >&5
11488 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11489 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11490   echo $ECHO_N "(cached) $ECHO_C" >&6
11491 fi
11492 ac_res=`eval echo '${'$as_ac_Header'}'`
11493                { echo "$as_me:$LINENO: result: $ac_res" >&5
11494 echo "${ECHO_T}$ac_res" >&6; }
11495 else
11496   # Is the header compilable?
11497 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
11498 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11499 cat >conftest.$ac_ext <<_ACEOF
11500 /* confdefs.h.  */
11501 _ACEOF
11502 cat confdefs.h >>conftest.$ac_ext
11503 cat >>conftest.$ac_ext <<_ACEOF
11504 /* end confdefs.h.  */
11505 $ac_includes_default
11506 #include <$ac_header>
11507 _ACEOF
11508 rm -f conftest.$ac_objext
11509 if { (ac_try="$ac_compile"
11510 case "(($ac_try" in
11511   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11512   *) ac_try_echo=$ac_try;;
11513 esac
11514 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11515   (eval "$ac_compile") 2>conftest.er1
11516   ac_status=$?
11517   grep -v '^ *+' conftest.er1 >conftest.err
11518   rm -f conftest.er1
11519   cat conftest.err >&5
11520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11521   (exit $ac_status); } && {
11522          test -z "$ac_c_werror_flag" ||
11523          test ! -s conftest.err
11524        } && test -s conftest.$ac_objext; then
11525   ac_header_compiler=yes
11526 else
11527   echo "$as_me: failed program was:" >&5
11528 sed 's/^/| /' conftest.$ac_ext >&5
11529
11530         ac_header_compiler=no
11531 fi
11532
11533 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11534 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11535 echo "${ECHO_T}$ac_header_compiler" >&6; }
11536
11537 # Is the header present?
11538 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
11539 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11540 cat >conftest.$ac_ext <<_ACEOF
11541 /* confdefs.h.  */
11542 _ACEOF
11543 cat confdefs.h >>conftest.$ac_ext
11544 cat >>conftest.$ac_ext <<_ACEOF
11545 /* end confdefs.h.  */
11546 #include <$ac_header>
11547 _ACEOF
11548 if { (ac_try="$ac_cpp conftest.$ac_ext"
11549 case "(($ac_try" in
11550   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11551   *) ac_try_echo=$ac_try;;
11552 esac
11553 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11554   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11555   ac_status=$?
11556   grep -v '^ *+' conftest.er1 >conftest.err
11557   rm -f conftest.er1
11558   cat conftest.err >&5
11559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11560   (exit $ac_status); } >/dev/null && {
11561          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11562          test ! -s conftest.err
11563        }; then
11564   ac_header_preproc=yes
11565 else
11566   echo "$as_me: failed program was:" >&5
11567 sed 's/^/| /' conftest.$ac_ext >&5
11568
11569   ac_header_preproc=no
11570 fi
11571
11572 rm -f conftest.err conftest.$ac_ext
11573 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11574 echo "${ECHO_T}$ac_header_preproc" >&6; }
11575
11576 # So?  What about this header?
11577 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11578   yes:no: )
11579     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11580 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11581     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11582 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11583     ac_header_preproc=yes
11584     ;;
11585   no:yes:* )
11586     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11587 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11588     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11589 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11590     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11591 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11592     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11593 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11594     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11595 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11596     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11597 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11598     ( cat <<\_ASBOX
11599 ## ---------------------------------------- ##
11600 ## Report this to pgsql-bugs@postgresql.org ##
11601 ## ---------------------------------------- ##
11602 _ASBOX
11603      ) | sed "s/^/$as_me: WARNING:     /" >&2
11604     ;;
11605 esac
11606 { echo "$as_me:$LINENO: checking for $ac_header" >&5
11607 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11608 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11609   echo $ECHO_N "(cached) $ECHO_C" >&6
11610 else
11611   eval "$as_ac_Header=\$ac_header_preproc"
11612 fi
11613 ac_res=`eval echo '${'$as_ac_Header'}'`
11614                { echo "$as_me:$LINENO: result: $ac_res" >&5
11615 echo "${ECHO_T}$ac_res" >&6; }
11616
11617 fi
11618 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11619   cat >>confdefs.h <<_ACEOF
11620 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11621 _ACEOF
11622
11623 else
11624
11625 for ac_header in pam/pam_appl.h
11626 do
11627 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11628 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11629   { echo "$as_me:$LINENO: checking for $ac_header" >&5
11630 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11631 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11632   echo $ECHO_N "(cached) $ECHO_C" >&6
11633 fi
11634 ac_res=`eval echo '${'$as_ac_Header'}'`
11635                { echo "$as_me:$LINENO: result: $ac_res" >&5
11636 echo "${ECHO_T}$ac_res" >&6; }
11637 else
11638   # Is the header compilable?
11639 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
11640 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11641 cat >conftest.$ac_ext <<_ACEOF
11642 /* confdefs.h.  */
11643 _ACEOF
11644 cat confdefs.h >>conftest.$ac_ext
11645 cat >>conftest.$ac_ext <<_ACEOF
11646 /* end confdefs.h.  */
11647 $ac_includes_default
11648 #include <$ac_header>
11649 _ACEOF
11650 rm -f conftest.$ac_objext
11651 if { (ac_try="$ac_compile"
11652 case "(($ac_try" in
11653   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11654   *) ac_try_echo=$ac_try;;
11655 esac
11656 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11657   (eval "$ac_compile") 2>conftest.er1
11658   ac_status=$?
11659   grep -v '^ *+' conftest.er1 >conftest.err
11660   rm -f conftest.er1
11661   cat conftest.err >&5
11662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11663   (exit $ac_status); } && {
11664          test -z "$ac_c_werror_flag" ||
11665          test ! -s conftest.err
11666        } && test -s conftest.$ac_objext; then
11667   ac_header_compiler=yes
11668 else
11669   echo "$as_me: failed program was:" >&5
11670 sed 's/^/| /' conftest.$ac_ext >&5
11671
11672         ac_header_compiler=no
11673 fi
11674
11675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11676 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11677 echo "${ECHO_T}$ac_header_compiler" >&6; }
11678
11679 # Is the header present?
11680 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
11681 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11682 cat >conftest.$ac_ext <<_ACEOF
11683 /* confdefs.h.  */
11684 _ACEOF
11685 cat confdefs.h >>conftest.$ac_ext
11686 cat >>conftest.$ac_ext <<_ACEOF
11687 /* end confdefs.h.  */
11688 #include <$ac_header>
11689 _ACEOF
11690 if { (ac_try="$ac_cpp conftest.$ac_ext"
11691 case "(($ac_try" in
11692   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11693   *) ac_try_echo=$ac_try;;
11694 esac
11695 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11696   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11697   ac_status=$?
11698   grep -v '^ *+' conftest.er1 >conftest.err
11699   rm -f conftest.er1
11700   cat conftest.err >&5
11701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11702   (exit $ac_status); } >/dev/null && {
11703          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11704          test ! -s conftest.err
11705        }; then
11706   ac_header_preproc=yes
11707 else
11708   echo "$as_me: failed program was:" >&5
11709 sed 's/^/| /' conftest.$ac_ext >&5
11710
11711   ac_header_preproc=no
11712 fi
11713
11714 rm -f conftest.err conftest.$ac_ext
11715 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11716 echo "${ECHO_T}$ac_header_preproc" >&6; }
11717
11718 # So?  What about this header?
11719 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11720   yes:no: )
11721     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11722 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11723     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11724 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11725     ac_header_preproc=yes
11726     ;;
11727   no:yes:* )
11728     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11729 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11730     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11731 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11732     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11733 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11734     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11735 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11736     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11737 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11738     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11739 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11740     ( cat <<\_ASBOX
11741 ## ---------------------------------------- ##
11742 ## Report this to pgsql-bugs@postgresql.org ##
11743 ## ---------------------------------------- ##
11744 _ASBOX
11745      ) | sed "s/^/$as_me: WARNING:     /" >&2
11746     ;;
11747 esac
11748 { echo "$as_me:$LINENO: checking for $ac_header" >&5
11749 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11750 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11751   echo $ECHO_N "(cached) $ECHO_C" >&6
11752 else
11753   eval "$as_ac_Header=\$ac_header_preproc"
11754 fi
11755 ac_res=`eval echo '${'$as_ac_Header'}'`
11756                { echo "$as_me:$LINENO: result: $ac_res" >&5
11757 echo "${ECHO_T}$ac_res" >&6; }
11758
11759 fi
11760 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11761   cat >>confdefs.h <<_ACEOF
11762 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11763 _ACEOF
11764
11765 else
11766   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
11767 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
11768    { (exit 1); exit 1; }; }
11769 fi
11770
11771 done
11772
11773 fi
11774
11775 done
11776
11777 fi
11778
11779 if test "$with_libxml" = yes ; then
11780   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
11781   { echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
11782 echo $ECHO_N "checking for libxml/parser.h... $ECHO_C" >&6; }
11783 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
11784   echo $ECHO_N "(cached) $ECHO_C" >&6
11785 fi
11786 { echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
11787 echo "${ECHO_T}$ac_cv_header_libxml_parser_h" >&6; }
11788 else
11789   # Is the header compilable?
11790 { echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
11791 echo $ECHO_N "checking libxml/parser.h usability... $ECHO_C" >&6; }
11792 cat >conftest.$ac_ext <<_ACEOF
11793 /* confdefs.h.  */
11794 _ACEOF
11795 cat confdefs.h >>conftest.$ac_ext
11796 cat >>conftest.$ac_ext <<_ACEOF
11797 /* end confdefs.h.  */
11798 $ac_includes_default
11799 #include <libxml/parser.h>
11800 _ACEOF
11801 rm -f conftest.$ac_objext
11802 if { (ac_try="$ac_compile"
11803 case "(($ac_try" in
11804   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11805   *) ac_try_echo=$ac_try;;
11806 esac
11807 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11808   (eval "$ac_compile") 2>conftest.er1
11809   ac_status=$?
11810   grep -v '^ *+' conftest.er1 >conftest.err
11811   rm -f conftest.er1
11812   cat conftest.err >&5
11813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11814   (exit $ac_status); } && {
11815          test -z "$ac_c_werror_flag" ||
11816          test ! -s conftest.err
11817        } && test -s conftest.$ac_objext; then
11818   ac_header_compiler=yes
11819 else
11820   echo "$as_me: failed program was:" >&5
11821 sed 's/^/| /' conftest.$ac_ext >&5
11822
11823         ac_header_compiler=no
11824 fi
11825
11826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11827 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11828 echo "${ECHO_T}$ac_header_compiler" >&6; }
11829
11830 # Is the header present?
11831 { echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
11832 echo $ECHO_N "checking libxml/parser.h presence... $ECHO_C" >&6; }
11833 cat >conftest.$ac_ext <<_ACEOF
11834 /* confdefs.h.  */
11835 _ACEOF
11836 cat confdefs.h >>conftest.$ac_ext
11837 cat >>conftest.$ac_ext <<_ACEOF
11838 /* end confdefs.h.  */
11839 #include <libxml/parser.h>
11840 _ACEOF
11841 if { (ac_try="$ac_cpp conftest.$ac_ext"
11842 case "(($ac_try" in
11843   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11844   *) ac_try_echo=$ac_try;;
11845 esac
11846 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11847   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11848   ac_status=$?
11849   grep -v '^ *+' conftest.er1 >conftest.err
11850   rm -f conftest.er1
11851   cat conftest.err >&5
11852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11853   (exit $ac_status); } >/dev/null && {
11854          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11855          test ! -s conftest.err
11856        }; then
11857   ac_header_preproc=yes
11858 else
11859   echo "$as_me: failed program was:" >&5
11860 sed 's/^/| /' conftest.$ac_ext >&5
11861
11862   ac_header_preproc=no
11863 fi
11864
11865 rm -f conftest.err conftest.$ac_ext
11866 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11867 echo "${ECHO_T}$ac_header_preproc" >&6; }
11868
11869 # So?  What about this header?
11870 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11871   yes:no: )
11872     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
11873 echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11874     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
11875 echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
11876     ac_header_preproc=yes
11877     ;;
11878   no:yes:* )
11879     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
11880 echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
11881     { echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
11882 echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
11883     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
11884 echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
11885     { echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
11886 echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11887     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
11888 echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
11889     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
11890 echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
11891     ( cat <<\_ASBOX
11892 ## ---------------------------------------- ##
11893 ## Report this to pgsql-bugs@postgresql.org ##
11894 ## ---------------------------------------- ##
11895 _ASBOX
11896      ) | sed "s/^/$as_me: WARNING:     /" >&2
11897     ;;
11898 esac
11899 { echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
11900 echo $ECHO_N "checking for libxml/parser.h... $ECHO_C" >&6; }
11901 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
11902   echo $ECHO_N "(cached) $ECHO_C" >&6
11903 else
11904   ac_cv_header_libxml_parser_h=$ac_header_preproc
11905 fi
11906 { echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
11907 echo "${ECHO_T}$ac_cv_header_libxml_parser_h" >&6; }
11908
11909 fi
11910 if test $ac_cv_header_libxml_parser_h = yes; then
11911   :
11912 else
11913   { { echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
11914 echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
11915    { (exit 1); exit 1; }; }
11916 fi
11917
11918
11919 fi
11920
11921 if test "$with_libxslt" = yes ; then
11922   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
11923   { echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
11924 echo $ECHO_N "checking for libxslt/xslt.h... $ECHO_C" >&6; }
11925 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
11926   echo $ECHO_N "(cached) $ECHO_C" >&6
11927 fi
11928 { echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
11929 echo "${ECHO_T}$ac_cv_header_libxslt_xslt_h" >&6; }
11930 else
11931   # Is the header compilable?
11932 { echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
11933 echo $ECHO_N "checking libxslt/xslt.h usability... $ECHO_C" >&6; }
11934 cat >conftest.$ac_ext <<_ACEOF
11935 /* confdefs.h.  */
11936 _ACEOF
11937 cat confdefs.h >>conftest.$ac_ext
11938 cat >>conftest.$ac_ext <<_ACEOF
11939 /* end confdefs.h.  */
11940 $ac_includes_default
11941 #include <libxslt/xslt.h>
11942 _ACEOF
11943 rm -f conftest.$ac_objext
11944 if { (ac_try="$ac_compile"
11945 case "(($ac_try" in
11946   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11947   *) ac_try_echo=$ac_try;;
11948 esac
11949 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11950   (eval "$ac_compile") 2>conftest.er1
11951   ac_status=$?
11952   grep -v '^ *+' conftest.er1 >conftest.err
11953   rm -f conftest.er1
11954   cat conftest.err >&5
11955   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11956   (exit $ac_status); } && {
11957          test -z "$ac_c_werror_flag" ||
11958          test ! -s conftest.err
11959        } && test -s conftest.$ac_objext; then
11960   ac_header_compiler=yes
11961 else
11962   echo "$as_me: failed program was:" >&5
11963 sed 's/^/| /' conftest.$ac_ext >&5
11964
11965         ac_header_compiler=no
11966 fi
11967
11968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11969 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11970 echo "${ECHO_T}$ac_header_compiler" >&6; }
11971
11972 # Is the header present?
11973 { echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
11974 echo $ECHO_N "checking libxslt/xslt.h presence... $ECHO_C" >&6; }
11975 cat >conftest.$ac_ext <<_ACEOF
11976 /* confdefs.h.  */
11977 _ACEOF
11978 cat confdefs.h >>conftest.$ac_ext
11979 cat >>conftest.$ac_ext <<_ACEOF
11980 /* end confdefs.h.  */
11981 #include <libxslt/xslt.h>
11982 _ACEOF
11983 if { (ac_try="$ac_cpp conftest.$ac_ext"
11984 case "(($ac_try" in
11985   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11986   *) ac_try_echo=$ac_try;;
11987 esac
11988 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11989   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11990   ac_status=$?
11991   grep -v '^ *+' conftest.er1 >conftest.err
11992   rm -f conftest.er1
11993   cat conftest.err >&5
11994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11995   (exit $ac_status); } >/dev/null && {
11996          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11997          test ! -s conftest.err
11998        }; then
11999   ac_header_preproc=yes
12000 else
12001   echo "$as_me: failed program was:" >&5
12002 sed 's/^/| /' conftest.$ac_ext >&5
12003
12004   ac_header_preproc=no
12005 fi
12006
12007 rm -f conftest.err conftest.$ac_ext
12008 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12009 echo "${ECHO_T}$ac_header_preproc" >&6; }
12010
12011 # So?  What about this header?
12012 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12013   yes:no: )
12014     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
12015 echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12016     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
12017 echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
12018     ac_header_preproc=yes
12019     ;;
12020   no:yes:* )
12021     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
12022 echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
12023     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
12024 echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
12025     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
12026 echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
12027     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
12028 echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12029     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
12030 echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
12031     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
12032 echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
12033     ( cat <<\_ASBOX
12034 ## ---------------------------------------- ##
12035 ## Report this to pgsql-bugs@postgresql.org ##
12036 ## ---------------------------------------- ##
12037 _ASBOX
12038      ) | sed "s/^/$as_me: WARNING:     /" >&2
12039     ;;
12040 esac
12041 { echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
12042 echo $ECHO_N "checking for libxslt/xslt.h... $ECHO_C" >&6; }
12043 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
12044   echo $ECHO_N "(cached) $ECHO_C" >&6
12045 else
12046   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
12047 fi
12048 { echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
12049 echo "${ECHO_T}$ac_cv_header_libxslt_xslt_h" >&6; }
12050
12051 fi
12052 if test $ac_cv_header_libxslt_xslt_h = yes; then
12053   :
12054 else
12055   { { echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
12056 echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
12057    { (exit 1); exit 1; }; }
12058 fi
12059
12060
12061 fi
12062
12063 if test "$with_ldap" = yes ; then
12064   if test "$PORTNAME" != "win32"; then
12065
12066 for ac_header in ldap.h
12067 do
12068 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12069 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12070   { echo "$as_me:$LINENO: checking for $ac_header" >&5
12071 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12072 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12073   echo $ECHO_N "(cached) $ECHO_C" >&6
12074 fi
12075 ac_res=`eval echo '${'$as_ac_Header'}'`
12076                { echo "$as_me:$LINENO: result: $ac_res" >&5
12077 echo "${ECHO_T}$ac_res" >&6; }
12078 else
12079   # Is the header compilable?
12080 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
12081 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12082 cat >conftest.$ac_ext <<_ACEOF
12083 /* confdefs.h.  */
12084 _ACEOF
12085 cat confdefs.h >>conftest.$ac_ext
12086 cat >>conftest.$ac_ext <<_ACEOF
12087 /* end confdefs.h.  */
12088 $ac_includes_default
12089 #include <$ac_header>
12090 _ACEOF
12091 rm -f conftest.$ac_objext
12092 if { (ac_try="$ac_compile"
12093 case "(($ac_try" in
12094   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12095   *) ac_try_echo=$ac_try;;
12096 esac
12097 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12098   (eval "$ac_compile") 2>conftest.er1
12099   ac_status=$?
12100   grep -v '^ *+' conftest.er1 >conftest.err
12101   rm -f conftest.er1
12102   cat conftest.err >&5
12103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12104   (exit $ac_status); } && {
12105          test -z "$ac_c_werror_flag" ||
12106          test ! -s conftest.err
12107        } && test -s conftest.$ac_objext; then
12108   ac_header_compiler=yes
12109 else
12110   echo "$as_me: failed program was:" >&5
12111 sed 's/^/| /' conftest.$ac_ext >&5
12112
12113         ac_header_compiler=no
12114 fi
12115
12116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12117 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12118 echo "${ECHO_T}$ac_header_compiler" >&6; }
12119
12120 # Is the header present?
12121 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
12122 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12123 cat >conftest.$ac_ext <<_ACEOF
12124 /* confdefs.h.  */
12125 _ACEOF
12126 cat confdefs.h >>conftest.$ac_ext
12127 cat >>conftest.$ac_ext <<_ACEOF
12128 /* end confdefs.h.  */
12129 #include <$ac_header>
12130 _ACEOF
12131 if { (ac_try="$ac_cpp conftest.$ac_ext"
12132 case "(($ac_try" in
12133   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12134   *) ac_try_echo=$ac_try;;
12135 esac
12136 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12137   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12138   ac_status=$?
12139   grep -v '^ *+' conftest.er1 >conftest.err
12140   rm -f conftest.er1
12141   cat conftest.err >&5
12142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12143   (exit $ac_status); } >/dev/null && {
12144          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12145          test ! -s conftest.err
12146        }; then
12147   ac_header_preproc=yes
12148 else
12149   echo "$as_me: failed program was:" >&5
12150 sed 's/^/| /' conftest.$ac_ext >&5
12151
12152   ac_header_preproc=no
12153 fi
12154
12155 rm -f conftest.err conftest.$ac_ext
12156 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12157 echo "${ECHO_T}$ac_header_preproc" >&6; }
12158
12159 # So?  What about this header?
12160 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12161   yes:no: )
12162     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12163 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12164     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12165 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12166     ac_header_preproc=yes
12167     ;;
12168   no:yes:* )
12169     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12170 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12171     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12172 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12173     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12174 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12175     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12176 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12177     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12178 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12179     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12180 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12181     ( cat <<\_ASBOX
12182 ## ---------------------------------------- ##
12183 ## Report this to pgsql-bugs@postgresql.org ##
12184 ## ---------------------------------------- ##
12185 _ASBOX
12186      ) | sed "s/^/$as_me: WARNING:     /" >&2
12187     ;;
12188 esac
12189 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12190 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12191 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12192   echo $ECHO_N "(cached) $ECHO_C" >&6
12193 else
12194   eval "$as_ac_Header=\$ac_header_preproc"
12195 fi
12196 ac_res=`eval echo '${'$as_ac_Header'}'`
12197                { echo "$as_me:$LINENO: result: $ac_res" >&5
12198 echo "${ECHO_T}$ac_res" >&6; }
12199
12200 fi
12201 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12202   cat >>confdefs.h <<_ACEOF
12203 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12204 _ACEOF
12205
12206 else
12207   { { echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
12208 echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
12209    { (exit 1); exit 1; }; }
12210 fi
12211
12212 done
12213
12214   else
12215
12216 for ac_header in winldap.h
12217 do
12218 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12219 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12220 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12221 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12222   echo $ECHO_N "(cached) $ECHO_C" >&6
12223 else
12224   cat >conftest.$ac_ext <<_ACEOF
12225 /* confdefs.h.  */
12226 _ACEOF
12227 cat confdefs.h >>conftest.$ac_ext
12228 cat >>conftest.$ac_ext <<_ACEOF
12229 /* end confdefs.h.  */
12230 $ac_includes_default
12231 #include <windows.h>
12232
12233
12234 #include <$ac_header>
12235 _ACEOF
12236 rm -f conftest.$ac_objext
12237 if { (ac_try="$ac_compile"
12238 case "(($ac_try" in
12239   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12240   *) ac_try_echo=$ac_try;;
12241 esac
12242 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12243   (eval "$ac_compile") 2>conftest.er1
12244   ac_status=$?
12245   grep -v '^ *+' conftest.er1 >conftest.err
12246   rm -f conftest.er1
12247   cat conftest.err >&5
12248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12249   (exit $ac_status); } && {
12250          test -z "$ac_c_werror_flag" ||
12251          test ! -s conftest.err
12252        } && test -s conftest.$ac_objext; then
12253   eval "$as_ac_Header=yes"
12254 else
12255   echo "$as_me: failed program was:" >&5
12256 sed 's/^/| /' conftest.$ac_ext >&5
12257
12258         eval "$as_ac_Header=no"
12259 fi
12260
12261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12262 fi
12263 ac_res=`eval echo '${'$as_ac_Header'}'`
12264                { echo "$as_me:$LINENO: result: $ac_res" >&5
12265 echo "${ECHO_T}$ac_res" >&6; }
12266 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12267   cat >>confdefs.h <<_ACEOF
12268 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12269 _ACEOF
12270
12271 else
12272   { { echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
12273 echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
12274    { (exit 1); exit 1; }; }
12275 fi
12276
12277 done
12278
12279   fi
12280 fi
12281
12282 if test "$with_bonjour" = yes ; then
12283   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
12284   { echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
12285 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6; }
12286 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
12287   echo $ECHO_N "(cached) $ECHO_C" >&6
12288 fi
12289 { echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
12290 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6; }
12291 else
12292   # Is the header compilable?
12293 { echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
12294 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6; }
12295 cat >conftest.$ac_ext <<_ACEOF
12296 /* confdefs.h.  */
12297 _ACEOF
12298 cat confdefs.h >>conftest.$ac_ext
12299 cat >>conftest.$ac_ext <<_ACEOF
12300 /* end confdefs.h.  */
12301 $ac_includes_default
12302 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
12303 _ACEOF
12304 rm -f conftest.$ac_objext
12305 if { (ac_try="$ac_compile"
12306 case "(($ac_try" in
12307   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12308   *) ac_try_echo=$ac_try;;
12309 esac
12310 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12311   (eval "$ac_compile") 2>conftest.er1
12312   ac_status=$?
12313   grep -v '^ *+' conftest.er1 >conftest.err
12314   rm -f conftest.er1
12315   cat conftest.err >&5
12316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12317   (exit $ac_status); } && {
12318          test -z "$ac_c_werror_flag" ||
12319          test ! -s conftest.err
12320        } && test -s conftest.$ac_objext; then
12321   ac_header_compiler=yes
12322 else
12323   echo "$as_me: failed program was:" >&5
12324 sed 's/^/| /' conftest.$ac_ext >&5
12325
12326         ac_header_compiler=no
12327 fi
12328
12329 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12330 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12331 echo "${ECHO_T}$ac_header_compiler" >&6; }
12332
12333 # Is the header present?
12334 { echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
12335 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6; }
12336 cat >conftest.$ac_ext <<_ACEOF
12337 /* confdefs.h.  */
12338 _ACEOF
12339 cat confdefs.h >>conftest.$ac_ext
12340 cat >>conftest.$ac_ext <<_ACEOF
12341 /* end confdefs.h.  */
12342 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
12343 _ACEOF
12344 if { (ac_try="$ac_cpp conftest.$ac_ext"
12345 case "(($ac_try" in
12346   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12347   *) ac_try_echo=$ac_try;;
12348 esac
12349 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12350   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12351   ac_status=$?
12352   grep -v '^ *+' conftest.er1 >conftest.err
12353   rm -f conftest.er1
12354   cat conftest.err >&5
12355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12356   (exit $ac_status); } >/dev/null && {
12357          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12358          test ! -s conftest.err
12359        }; then
12360   ac_header_preproc=yes
12361 else
12362   echo "$as_me: failed program was:" >&5
12363 sed 's/^/| /' conftest.$ac_ext >&5
12364
12365   ac_header_preproc=no
12366 fi
12367
12368 rm -f conftest.err conftest.$ac_ext
12369 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12370 echo "${ECHO_T}$ac_header_preproc" >&6; }
12371
12372 # So?  What about this header?
12373 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12374   yes:no: )
12375     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
12376 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12377     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&5
12378 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&2;}
12379     ac_header_preproc=yes
12380     ;;
12381   no:yes:* )
12382     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
12383 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
12384     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&5
12385 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&2;}
12386     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&5
12387 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&2;}
12388     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&5
12389 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12390     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
12391 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;}
12392     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&5
12393 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&2;}
12394     ( cat <<\_ASBOX
12395 ## ---------------------------------------- ##
12396 ## Report this to pgsql-bugs@postgresql.org ##
12397 ## ---------------------------------------- ##
12398 _ASBOX
12399      ) | sed "s/^/$as_me: WARNING:     /" >&2
12400     ;;
12401 esac
12402 { echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
12403 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6; }
12404 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
12405   echo $ECHO_N "(cached) $ECHO_C" >&6
12406 else
12407   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
12408 fi
12409 { echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
12410 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6; }
12411
12412 fi
12413 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
12414   :
12415 else
12416   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&5
12417 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&2;}
12418    { (exit 1); exit 1; }; }
12419 fi
12420
12421
12422 fi
12423
12424 # for contrib/uuid-ossp
12425 if test "$with_ossp_uuid" = yes ; then
12426
12427 for ac_header in ossp/uuid.h
12428 do
12429 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12430 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12431   { echo "$as_me:$LINENO: checking for $ac_header" >&5
12432 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12433 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12434   echo $ECHO_N "(cached) $ECHO_C" >&6
12435 fi
12436 ac_res=`eval echo '${'$as_ac_Header'}'`
12437                { echo "$as_me:$LINENO: result: $ac_res" >&5
12438 echo "${ECHO_T}$ac_res" >&6; }
12439 else
12440   # Is the header compilable?
12441 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
12442 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12443 cat >conftest.$ac_ext <<_ACEOF
12444 /* confdefs.h.  */
12445 _ACEOF
12446 cat confdefs.h >>conftest.$ac_ext
12447 cat >>conftest.$ac_ext <<_ACEOF
12448 /* end confdefs.h.  */
12449 $ac_includes_default
12450 #include <$ac_header>
12451 _ACEOF
12452 rm -f conftest.$ac_objext
12453 if { (ac_try="$ac_compile"
12454 case "(($ac_try" in
12455   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12456   *) ac_try_echo=$ac_try;;
12457 esac
12458 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12459   (eval "$ac_compile") 2>conftest.er1
12460   ac_status=$?
12461   grep -v '^ *+' conftest.er1 >conftest.err
12462   rm -f conftest.er1
12463   cat conftest.err >&5
12464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12465   (exit $ac_status); } && {
12466          test -z "$ac_c_werror_flag" ||
12467          test ! -s conftest.err
12468        } && test -s conftest.$ac_objext; then
12469   ac_header_compiler=yes
12470 else
12471   echo "$as_me: failed program was:" >&5
12472 sed 's/^/| /' conftest.$ac_ext >&5
12473
12474         ac_header_compiler=no
12475 fi
12476
12477 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12478 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12479 echo "${ECHO_T}$ac_header_compiler" >&6; }
12480
12481 # Is the header present?
12482 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
12483 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12484 cat >conftest.$ac_ext <<_ACEOF
12485 /* confdefs.h.  */
12486 _ACEOF
12487 cat confdefs.h >>conftest.$ac_ext
12488 cat >>conftest.$ac_ext <<_ACEOF
12489 /* end confdefs.h.  */
12490 #include <$ac_header>
12491 _ACEOF
12492 if { (ac_try="$ac_cpp conftest.$ac_ext"
12493 case "(($ac_try" in
12494   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12495   *) ac_try_echo=$ac_try;;
12496 esac
12497 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12498   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12499   ac_status=$?
12500   grep -v '^ *+' conftest.er1 >conftest.err
12501   rm -f conftest.er1
12502   cat conftest.err >&5
12503   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12504   (exit $ac_status); } >/dev/null && {
12505          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12506          test ! -s conftest.err
12507        }; then
12508   ac_header_preproc=yes
12509 else
12510   echo "$as_me: failed program was:" >&5
12511 sed 's/^/| /' conftest.$ac_ext >&5
12512
12513   ac_header_preproc=no
12514 fi
12515
12516 rm -f conftest.err conftest.$ac_ext
12517 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12518 echo "${ECHO_T}$ac_header_preproc" >&6; }
12519
12520 # So?  What about this header?
12521 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12522   yes:no: )
12523     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12524 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12525     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12526 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12527     ac_header_preproc=yes
12528     ;;
12529   no:yes:* )
12530     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12531 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12532     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12533 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12534     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12535 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12536     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12537 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12538     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12539 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12540     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12541 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12542     ( cat <<\_ASBOX
12543 ## ---------------------------------------- ##
12544 ## Report this to pgsql-bugs@postgresql.org ##
12545 ## ---------------------------------------- ##
12546 _ASBOX
12547      ) | sed "s/^/$as_me: WARNING:     /" >&2
12548     ;;
12549 esac
12550 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12551 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12552 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12553   echo $ECHO_N "(cached) $ECHO_C" >&6
12554 else
12555   eval "$as_ac_Header=\$ac_header_preproc"
12556 fi
12557 ac_res=`eval echo '${'$as_ac_Header'}'`
12558                { echo "$as_me:$LINENO: result: $ac_res" >&5
12559 echo "${ECHO_T}$ac_res" >&6; }
12560
12561 fi
12562 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12563   cat >>confdefs.h <<_ACEOF
12564 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12565 _ACEOF
12566
12567 else
12568
12569
12570 for ac_header in uuid.h
12571 do
12572 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12573 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12574   { echo "$as_me:$LINENO: checking for $ac_header" >&5
12575 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12576 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12577   echo $ECHO_N "(cached) $ECHO_C" >&6
12578 fi
12579 ac_res=`eval echo '${'$as_ac_Header'}'`
12580                { echo "$as_me:$LINENO: result: $ac_res" >&5
12581 echo "${ECHO_T}$ac_res" >&6; }
12582 else
12583   # Is the header compilable?
12584 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
12585 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12586 cat >conftest.$ac_ext <<_ACEOF
12587 /* confdefs.h.  */
12588 _ACEOF
12589 cat confdefs.h >>conftest.$ac_ext
12590 cat >>conftest.$ac_ext <<_ACEOF
12591 /* end confdefs.h.  */
12592 $ac_includes_default
12593 #include <$ac_header>
12594 _ACEOF
12595 rm -f conftest.$ac_objext
12596 if { (ac_try="$ac_compile"
12597 case "(($ac_try" in
12598   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12599   *) ac_try_echo=$ac_try;;
12600 esac
12601 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12602   (eval "$ac_compile") 2>conftest.er1
12603   ac_status=$?
12604   grep -v '^ *+' conftest.er1 >conftest.err
12605   rm -f conftest.er1
12606   cat conftest.err >&5
12607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12608   (exit $ac_status); } && {
12609          test -z "$ac_c_werror_flag" ||
12610          test ! -s conftest.err
12611        } && test -s conftest.$ac_objext; then
12612   ac_header_compiler=yes
12613 else
12614   echo "$as_me: failed program was:" >&5
12615 sed 's/^/| /' conftest.$ac_ext >&5
12616
12617         ac_header_compiler=no
12618 fi
12619
12620 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12621 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12622 echo "${ECHO_T}$ac_header_compiler" >&6; }
12623
12624 # Is the header present?
12625 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
12626 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12627 cat >conftest.$ac_ext <<_ACEOF
12628 /* confdefs.h.  */
12629 _ACEOF
12630 cat confdefs.h >>conftest.$ac_ext
12631 cat >>conftest.$ac_ext <<_ACEOF
12632 /* end confdefs.h.  */
12633 #include <$ac_header>
12634 _ACEOF
12635 if { (ac_try="$ac_cpp conftest.$ac_ext"
12636 case "(($ac_try" in
12637   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12638   *) ac_try_echo=$ac_try;;
12639 esac
12640 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12641   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12642   ac_status=$?
12643   grep -v '^ *+' conftest.er1 >conftest.err
12644   rm -f conftest.er1
12645   cat conftest.err >&5
12646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12647   (exit $ac_status); } >/dev/null && {
12648          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12649          test ! -s conftest.err
12650        }; then
12651   ac_header_preproc=yes
12652 else
12653   echo "$as_me: failed program was:" >&5
12654 sed 's/^/| /' conftest.$ac_ext >&5
12655
12656   ac_header_preproc=no
12657 fi
12658
12659 rm -f conftest.err conftest.$ac_ext
12660 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12661 echo "${ECHO_T}$ac_header_preproc" >&6; }
12662
12663 # So?  What about this header?
12664 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12665   yes:no: )
12666     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12667 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12668     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12669 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12670     ac_header_preproc=yes
12671     ;;
12672   no:yes:* )
12673     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12674 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12675     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12676 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12677     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12678 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12679     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12680 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12681     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12682 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12683     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12684 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12685     ( cat <<\_ASBOX
12686 ## ---------------------------------------- ##
12687 ## Report this to pgsql-bugs@postgresql.org ##
12688 ## ---------------------------------------- ##
12689 _ASBOX
12690      ) | sed "s/^/$as_me: WARNING:     /" >&2
12691     ;;
12692 esac
12693 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12694 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12695 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12696   echo $ECHO_N "(cached) $ECHO_C" >&6
12697 else
12698   eval "$as_ac_Header=\$ac_header_preproc"
12699 fi
12700 ac_res=`eval echo '${'$as_ac_Header'}'`
12701                { echo "$as_me:$LINENO: result: $ac_res" >&5
12702 echo "${ECHO_T}$ac_res" >&6; }
12703
12704 fi
12705 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12706   cat >>confdefs.h <<_ACEOF
12707 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12708 _ACEOF
12709
12710 else
12711   { { echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
12712 echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
12713    { (exit 1); exit 1; }; }
12714 fi
12715
12716 done
12717
12718 fi
12719
12720 done
12721
12722 fi
12723
12724
12725 ##
12726 ## Types, structures, compiler characteristics
12727 ##
12728
12729  { echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
12730 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
12731 if test "${ac_cv_c_bigendian+set}" = set; then
12732   echo $ECHO_N "(cached) $ECHO_C" >&6
12733 else
12734   # See if sys/param.h defines the BYTE_ORDER macro.
12735 cat >conftest.$ac_ext <<_ACEOF
12736 /* confdefs.h.  */
12737 _ACEOF
12738 cat confdefs.h >>conftest.$ac_ext
12739 cat >>conftest.$ac_ext <<_ACEOF
12740 /* end confdefs.h.  */
12741 #include <sys/types.h>
12742 #include <sys/param.h>
12743
12744 int
12745 main ()
12746 {
12747 #if  ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
12748         && BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
12749  bogus endian macros
12750 #endif
12751
12752   ;
12753   return 0;
12754 }
12755 _ACEOF
12756 rm -f conftest.$ac_objext
12757 if { (ac_try="$ac_compile"
12758 case "(($ac_try" in
12759   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12760   *) ac_try_echo=$ac_try;;
12761 esac
12762 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12763   (eval "$ac_compile") 2>conftest.er1
12764   ac_status=$?
12765   grep -v '^ *+' conftest.er1 >conftest.err
12766   rm -f conftest.er1
12767   cat conftest.err >&5
12768   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12769   (exit $ac_status); } && {
12770          test -z "$ac_c_werror_flag" ||
12771          test ! -s conftest.err
12772        } && test -s conftest.$ac_objext; then
12773   # It does; now see whether it defined to BIG_ENDIAN or not.
12774 cat >conftest.$ac_ext <<_ACEOF
12775 /* confdefs.h.  */
12776 _ACEOF
12777 cat confdefs.h >>conftest.$ac_ext
12778 cat >>conftest.$ac_ext <<_ACEOF
12779 /* end confdefs.h.  */
12780 #include <sys/types.h>
12781 #include <sys/param.h>
12782
12783 int
12784 main ()
12785 {
12786 #if BYTE_ORDER != BIG_ENDIAN
12787  not big endian
12788 #endif
12789
12790   ;
12791   return 0;
12792 }
12793 _ACEOF
12794 rm -f conftest.$ac_objext
12795 if { (ac_try="$ac_compile"
12796 case "(($ac_try" in
12797   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12798   *) ac_try_echo=$ac_try;;
12799 esac
12800 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12801   (eval "$ac_compile") 2>conftest.er1
12802   ac_status=$?
12803   grep -v '^ *+' conftest.er1 >conftest.err
12804   rm -f conftest.er1
12805   cat conftest.err >&5
12806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12807   (exit $ac_status); } && {
12808          test -z "$ac_c_werror_flag" ||
12809          test ! -s conftest.err
12810        } && test -s conftest.$ac_objext; then
12811   ac_cv_c_bigendian=yes
12812 else
12813   echo "$as_me: failed program was:" >&5
12814 sed 's/^/| /' conftest.$ac_ext >&5
12815
12816         ac_cv_c_bigendian=no
12817 fi
12818
12819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12820 else
12821   echo "$as_me: failed program was:" >&5
12822 sed 's/^/| /' conftest.$ac_ext >&5
12823
12824         # It does not; compile a test program.
12825 if test "$cross_compiling" = yes; then
12826   # try to guess the endianness by grepping values into an object file
12827   ac_cv_c_bigendian=unknown
12828   cat >conftest.$ac_ext <<_ACEOF
12829 /* confdefs.h.  */
12830 _ACEOF
12831 cat confdefs.h >>conftest.$ac_ext
12832 cat >>conftest.$ac_ext <<_ACEOF
12833 /* end confdefs.h.  */
12834 short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
12835 short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
12836 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
12837 short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
12838 short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
12839 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
12840 int
12841 main ()
12842 {
12843  _ascii (); _ebcdic ();
12844   ;
12845   return 0;
12846 }
12847 _ACEOF
12848 rm -f conftest.$ac_objext
12849 if { (ac_try="$ac_compile"
12850 case "(($ac_try" in
12851   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12852   *) ac_try_echo=$ac_try;;
12853 esac
12854 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12855   (eval "$ac_compile") 2>conftest.er1
12856   ac_status=$?
12857   grep -v '^ *+' conftest.er1 >conftest.err
12858   rm -f conftest.er1
12859   cat conftest.err >&5
12860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12861   (exit $ac_status); } && {
12862          test -z "$ac_c_werror_flag" ||
12863          test ! -s conftest.err
12864        } && test -s conftest.$ac_objext; then
12865   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
12866   ac_cv_c_bigendian=yes
12867 fi
12868 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
12869   if test "$ac_cv_c_bigendian" = unknown; then
12870     ac_cv_c_bigendian=no
12871   else
12872     # finding both strings is unlikely to happen, but who knows?
12873     ac_cv_c_bigendian=unknown
12874   fi
12875 fi
12876 else
12877   echo "$as_me: failed program was:" >&5
12878 sed 's/^/| /' conftest.$ac_ext >&5
12879
12880
12881 fi
12882
12883 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12884 else
12885   cat >conftest.$ac_ext <<_ACEOF
12886 /* confdefs.h.  */
12887 _ACEOF
12888 cat confdefs.h >>conftest.$ac_ext
12889 cat >>conftest.$ac_ext <<_ACEOF
12890 /* end confdefs.h.  */
12891 $ac_includes_default
12892 int
12893 main ()
12894 {
12895
12896   /* Are we little or big endian?  From Harbison&Steele.  */
12897   union
12898   {
12899     long int l;
12900     char c[sizeof (long int)];
12901   } u;
12902   u.l = 1;
12903   return u.c[sizeof (long int) - 1] == 1;
12904
12905   ;
12906   return 0;
12907 }
12908 _ACEOF
12909 rm -f conftest$ac_exeext
12910 if { (ac_try="$ac_link"
12911 case "(($ac_try" in
12912   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12913   *) ac_try_echo=$ac_try;;
12914 esac
12915 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12916   (eval "$ac_link") 2>&5
12917   ac_status=$?
12918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12919   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12920   { (case "(($ac_try" in
12921   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12922   *) ac_try_echo=$ac_try;;
12923 esac
12924 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12925   (eval "$ac_try") 2>&5
12926   ac_status=$?
12927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12928   (exit $ac_status); }; }; then
12929   ac_cv_c_bigendian=no
12930 else
12931   echo "$as_me: program exited with status $ac_status" >&5
12932 echo "$as_me: failed program was:" >&5
12933 sed 's/^/| /' conftest.$ac_ext >&5
12934
12935 ( exit $ac_status )
12936 ac_cv_c_bigendian=yes
12937 fi
12938 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12939 fi
12940
12941
12942 fi
12943
12944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12945 fi
12946 { echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
12947 echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
12948 case $ac_cv_c_bigendian in
12949   yes)
12950
12951 cat >>confdefs.h <<\_ACEOF
12952 #define WORDS_BIGENDIAN 1
12953 _ACEOF
12954  ;;
12955   no)
12956      ;;
12957   *)
12958     { { echo "$as_me:$LINENO: error: unknown endianness
12959 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
12960 echo "$as_me: error: unknown endianness
12961 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
12962    { (exit 1); exit 1; }; } ;;
12963 esac
12964
12965 { echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
12966 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; }
12967 if test "${ac_cv_c_const+set}" = set; then
12968   echo $ECHO_N "(cached) $ECHO_C" >&6
12969 else
12970   cat >conftest.$ac_ext <<_ACEOF
12971 /* confdefs.h.  */
12972 _ACEOF
12973 cat confdefs.h >>conftest.$ac_ext
12974 cat >>conftest.$ac_ext <<_ACEOF
12975 /* end confdefs.h.  */
12976
12977 int
12978 main ()
12979 {
12980 /* FIXME: Include the comments suggested by Paul. */
12981 #ifndef __cplusplus
12982   /* Ultrix mips cc rejects this.  */
12983   typedef int charset[2];
12984   const charset cs;
12985   /* SunOS 4.1.1 cc rejects this.  */
12986   char const *const *pcpcc;
12987   char **ppc;
12988   /* NEC SVR4.0.2 mips cc rejects this.  */
12989   struct point {int x, y;};
12990   static struct point const zero = {0,0};
12991   /* AIX XL C 1.02.0.0 rejects this.
12992      It does not let you subtract one const X* pointer from another in
12993      an arm of an if-expression whose if-part is not a constant
12994      expression */
12995   const char *g = "string";
12996   pcpcc = &g + (g ? g-g : 0);
12997   /* HPUX 7.0 cc rejects these. */
12998   ++pcpcc;
12999   ppc = (char**) pcpcc;
13000   pcpcc = (char const *const *) ppc;
13001   { /* SCO 3.2v4 cc rejects this.  */
13002     char *t;
13003     char const *s = 0 ? (char *) 0 : (char const *) 0;
13004
13005     *t++ = 0;
13006     if (s) return 0;
13007   }
13008   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
13009     int x[] = {25, 17};
13010     const int *foo = &x[0];
13011     ++foo;
13012   }
13013   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
13014     typedef const int *iptr;
13015     iptr p = 0;
13016     ++p;
13017   }
13018   { /* AIX XL C 1.02.0.0 rejects this saying
13019        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
13020     struct s { int j; const int *ap[3]; };
13021     struct s *b; b->j = 5;
13022   }
13023   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
13024     const int foo = 10;
13025     if (!foo) return 0;
13026   }
13027   return !cs[0] && !zero.x;
13028 #endif
13029
13030   ;
13031   return 0;
13032 }
13033 _ACEOF
13034 rm -f conftest.$ac_objext
13035 if { (ac_try="$ac_compile"
13036 case "(($ac_try" in
13037   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13038   *) ac_try_echo=$ac_try;;
13039 esac
13040 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13041   (eval "$ac_compile") 2>conftest.er1
13042   ac_status=$?
13043   grep -v '^ *+' conftest.er1 >conftest.err
13044   rm -f conftest.er1
13045   cat conftest.err >&5
13046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13047   (exit $ac_status); } && {
13048          test -z "$ac_c_werror_flag" ||
13049          test ! -s conftest.err
13050        } && test -s conftest.$ac_objext; then
13051   ac_cv_c_const=yes
13052 else
13053   echo "$as_me: failed program was:" >&5
13054 sed 's/^/| /' conftest.$ac_ext >&5
13055
13056         ac_cv_c_const=no
13057 fi
13058
13059 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13060 fi
13061 { echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
13062 echo "${ECHO_T}$ac_cv_c_const" >&6; }
13063 if test $ac_cv_c_const = no; then
13064
13065 cat >>confdefs.h <<\_ACEOF
13066 #define const
13067 _ACEOF
13068
13069 fi
13070
13071 { echo "$as_me:$LINENO: checking for inline" >&5
13072 echo $ECHO_N "checking for inline... $ECHO_C" >&6; }
13073 if test "${ac_cv_c_inline+set}" = set; then
13074   echo $ECHO_N "(cached) $ECHO_C" >&6
13075 else
13076   ac_cv_c_inline=no
13077 for ac_kw in inline __inline__ __inline; do
13078   cat >conftest.$ac_ext <<_ACEOF
13079 /* confdefs.h.  */
13080 _ACEOF
13081 cat confdefs.h >>conftest.$ac_ext
13082 cat >>conftest.$ac_ext <<_ACEOF
13083 /* end confdefs.h.  */
13084 #ifndef __cplusplus
13085 typedef int foo_t;
13086 static $ac_kw foo_t static_foo () {return 0; }
13087 $ac_kw foo_t foo () {return 0; }
13088 #endif
13089
13090 _ACEOF
13091 rm -f conftest.$ac_objext
13092 if { (ac_try="$ac_compile"
13093 case "(($ac_try" in
13094   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13095   *) ac_try_echo=$ac_try;;
13096 esac
13097 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13098   (eval "$ac_compile") 2>conftest.er1
13099   ac_status=$?
13100   grep -v '^ *+' conftest.er1 >conftest.err
13101   rm -f conftest.er1
13102   cat conftest.err >&5
13103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13104   (exit $ac_status); } && {
13105          test -z "$ac_c_werror_flag" ||
13106          test ! -s conftest.err
13107        } && test -s conftest.$ac_objext; then
13108   ac_cv_c_inline=$ac_kw
13109 else
13110   echo "$as_me: failed program was:" >&5
13111 sed 's/^/| /' conftest.$ac_ext >&5
13112
13113
13114 fi
13115
13116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13117   test "$ac_cv_c_inline" != no && break
13118 done
13119
13120 fi
13121 { echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
13122 echo "${ECHO_T}$ac_cv_c_inline" >&6; }
13123
13124
13125 case $ac_cv_c_inline in
13126   inline | yes) ;;
13127   *)
13128     case $ac_cv_c_inline in
13129       no) ac_val=;;
13130       *) ac_val=$ac_cv_c_inline;;
13131     esac
13132     cat >>confdefs.h <<_ACEOF
13133 #ifndef __cplusplus
13134 #define inline $ac_val
13135 #endif
13136 _ACEOF
13137     ;;
13138 esac
13139
13140 { echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
13141 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6; }
13142 if test "${ac_cv_c_stringize+set}" = set; then
13143   echo $ECHO_N "(cached) $ECHO_C" >&6
13144 else
13145   cat >conftest.$ac_ext <<_ACEOF
13146 /* confdefs.h.  */
13147 _ACEOF
13148 cat confdefs.h >>conftest.$ac_ext
13149 cat >>conftest.$ac_ext <<_ACEOF
13150 /* end confdefs.h.  */
13151 #define x(y) #y
13152
13153 char *s = x(teststring);
13154 _ACEOF
13155 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13156   $EGREP "#teststring" >/dev/null 2>&1; then
13157   ac_cv_c_stringize=no
13158 else
13159   ac_cv_c_stringize=yes
13160 fi
13161 rm -f conftest*
13162
13163 fi
13164 { echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
13165 echo "${ECHO_T}$ac_cv_c_stringize" >&6; }
13166 if test $ac_cv_c_stringize = yes; then
13167
13168 cat >>confdefs.h <<\_ACEOF
13169 #define HAVE_STRINGIZE 1
13170 _ACEOF
13171
13172 fi
13173
13174 { echo "$as_me:$LINENO: checking for signed types" >&5
13175 echo $ECHO_N "checking for signed types... $ECHO_C" >&6; }
13176 if test "${pgac_cv_c_signed+set}" = set; then
13177   echo $ECHO_N "(cached) $ECHO_C" >&6
13178 else
13179   cat >conftest.$ac_ext <<_ACEOF
13180 /* confdefs.h.  */
13181 _ACEOF
13182 cat confdefs.h >>conftest.$ac_ext
13183 cat >>conftest.$ac_ext <<_ACEOF
13184 /* end confdefs.h.  */
13185
13186 int
13187 main ()
13188 {
13189 signed char c; signed short s; signed int i;
13190   ;
13191   return 0;
13192 }
13193 _ACEOF
13194 rm -f conftest.$ac_objext
13195 if { (ac_try="$ac_compile"
13196 case "(($ac_try" in
13197   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13198   *) ac_try_echo=$ac_try;;
13199 esac
13200 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13201   (eval "$ac_compile") 2>conftest.er1
13202   ac_status=$?
13203   grep -v '^ *+' conftest.er1 >conftest.err
13204   rm -f conftest.er1
13205   cat conftest.err >&5
13206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13207   (exit $ac_status); } && {
13208          test -z "$ac_c_werror_flag" ||
13209          test ! -s conftest.err
13210        } && test -s conftest.$ac_objext; then
13211   pgac_cv_c_signed=yes
13212 else
13213   echo "$as_me: failed program was:" >&5
13214 sed 's/^/| /' conftest.$ac_ext >&5
13215
13216         pgac_cv_c_signed=no
13217 fi
13218
13219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13220 fi
13221 { echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
13222 echo "${ECHO_T}$pgac_cv_c_signed" >&6; }
13223 if test x"$pgac_cv_c_signed" = xno ; then
13224
13225 cat >>confdefs.h <<\_ACEOF
13226 #define signed
13227 _ACEOF
13228
13229 fi
13230 { echo "$as_me:$LINENO: checking for working volatile" >&5
13231 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6; }
13232 if test "${ac_cv_c_volatile+set}" = set; then
13233   echo $ECHO_N "(cached) $ECHO_C" >&6
13234 else
13235   cat >conftest.$ac_ext <<_ACEOF
13236 /* confdefs.h.  */
13237 _ACEOF
13238 cat confdefs.h >>conftest.$ac_ext
13239 cat >>conftest.$ac_ext <<_ACEOF
13240 /* end confdefs.h.  */
13241
13242 int
13243 main ()
13244 {
13245
13246 volatile int x;
13247 int * volatile y = (int *) 0;
13248 return !x && !y;
13249   ;
13250   return 0;
13251 }
13252 _ACEOF
13253 rm -f conftest.$ac_objext
13254 if { (ac_try="$ac_compile"
13255 case "(($ac_try" in
13256   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13257   *) ac_try_echo=$ac_try;;
13258 esac
13259 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13260   (eval "$ac_compile") 2>conftest.er1
13261   ac_status=$?
13262   grep -v '^ *+' conftest.er1 >conftest.err
13263   rm -f conftest.er1
13264   cat conftest.err >&5
13265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13266   (exit $ac_status); } && {
13267          test -z "$ac_c_werror_flag" ||
13268          test ! -s conftest.err
13269        } && test -s conftest.$ac_objext; then
13270   ac_cv_c_volatile=yes
13271 else
13272   echo "$as_me: failed program was:" >&5
13273 sed 's/^/| /' conftest.$ac_ext >&5
13274
13275         ac_cv_c_volatile=no
13276 fi
13277
13278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13279 fi
13280 { echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
13281 echo "${ECHO_T}$ac_cv_c_volatile" >&6; }
13282 if test $ac_cv_c_volatile = no; then
13283
13284 cat >>confdefs.h <<\_ACEOF
13285 #define volatile
13286 _ACEOF
13287
13288 fi
13289
13290 { echo "$as_me:$LINENO: checking for __func__" >&5
13291 echo $ECHO_N "checking for __func__... $ECHO_C" >&6; }
13292 if test "${pgac_cv_funcname_func_support+set}" = set; then
13293   echo $ECHO_N "(cached) $ECHO_C" >&6
13294 else
13295   cat >conftest.$ac_ext <<_ACEOF
13296 /* confdefs.h.  */
13297 _ACEOF
13298 cat confdefs.h >>conftest.$ac_ext
13299 cat >>conftest.$ac_ext <<_ACEOF
13300 /* end confdefs.h.  */
13301 #include <stdio.h>
13302 int
13303 main ()
13304 {
13305 printf("%s\n", __func__);
13306   ;
13307   return 0;
13308 }
13309 _ACEOF
13310 rm -f conftest.$ac_objext
13311 if { (ac_try="$ac_compile"
13312 case "(($ac_try" in
13313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13314   *) ac_try_echo=$ac_try;;
13315 esac
13316 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13317   (eval "$ac_compile") 2>conftest.er1
13318   ac_status=$?
13319   grep -v '^ *+' conftest.er1 >conftest.err
13320   rm -f conftest.er1
13321   cat conftest.err >&5
13322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13323   (exit $ac_status); } && {
13324          test -z "$ac_c_werror_flag" ||
13325          test ! -s conftest.err
13326        } && test -s conftest.$ac_objext; then
13327   pgac_cv_funcname_func_support=yes
13328 else
13329   echo "$as_me: failed program was:" >&5
13330 sed 's/^/| /' conftest.$ac_ext >&5
13331
13332         pgac_cv_funcname_func_support=no
13333 fi
13334
13335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13336 fi
13337 { echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
13338 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6; }
13339 if test x"$pgac_cv_funcname_func_support" = xyes ; then
13340
13341 cat >>confdefs.h <<\_ACEOF
13342 #define HAVE_FUNCNAME__FUNC 1
13343 _ACEOF
13344
13345 else
13346 { echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
13347 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6; }
13348 if test "${pgac_cv_funcname_function_support+set}" = set; then
13349   echo $ECHO_N "(cached) $ECHO_C" >&6
13350 else
13351   cat >conftest.$ac_ext <<_ACEOF
13352 /* confdefs.h.  */
13353 _ACEOF
13354 cat confdefs.h >>conftest.$ac_ext
13355 cat >>conftest.$ac_ext <<_ACEOF
13356 /* end confdefs.h.  */
13357 #include <stdio.h>
13358 int
13359 main ()
13360 {
13361 printf("%s\n", __FUNCTION__);
13362   ;
13363   return 0;
13364 }
13365 _ACEOF
13366 rm -f conftest.$ac_objext
13367 if { (ac_try="$ac_compile"
13368 case "(($ac_try" in
13369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13370   *) ac_try_echo=$ac_try;;
13371 esac
13372 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13373   (eval "$ac_compile") 2>conftest.er1
13374   ac_status=$?
13375   grep -v '^ *+' conftest.er1 >conftest.err
13376   rm -f conftest.er1
13377   cat conftest.err >&5
13378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13379   (exit $ac_status); } && {
13380          test -z "$ac_c_werror_flag" ||
13381          test ! -s conftest.err
13382        } && test -s conftest.$ac_objext; then
13383   pgac_cv_funcname_function_support=yes
13384 else
13385   echo "$as_me: failed program was:" >&5
13386 sed 's/^/| /' conftest.$ac_ext >&5
13387
13388         pgac_cv_funcname_function_support=no
13389 fi
13390
13391 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13392 fi
13393 { echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
13394 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6; }
13395 if test x"$pgac_cv_funcname_function_support" = xyes ; then
13396
13397 cat >>confdefs.h <<\_ACEOF
13398 #define HAVE_FUNCNAME__FUNCTION 1
13399 _ACEOF
13400
13401 fi
13402 fi
13403 { echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
13404 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; }
13405 if test "${ac_cv_struct_tm+set}" = set; then
13406   echo $ECHO_N "(cached) $ECHO_C" >&6
13407 else
13408   cat >conftest.$ac_ext <<_ACEOF
13409 /* confdefs.h.  */
13410 _ACEOF
13411 cat confdefs.h >>conftest.$ac_ext
13412 cat >>conftest.$ac_ext <<_ACEOF
13413 /* end confdefs.h.  */
13414 #include <sys/types.h>
13415 #include <time.h>
13416
13417 int
13418 main ()
13419 {
13420 struct tm tm;
13421                                      int *p = &tm.tm_sec;
13422                                      return !p;
13423   ;
13424   return 0;
13425 }
13426 _ACEOF
13427 rm -f conftest.$ac_objext
13428 if { (ac_try="$ac_compile"
13429 case "(($ac_try" in
13430   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13431   *) ac_try_echo=$ac_try;;
13432 esac
13433 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13434   (eval "$ac_compile") 2>conftest.er1
13435   ac_status=$?
13436   grep -v '^ *+' conftest.er1 >conftest.err
13437   rm -f conftest.er1
13438   cat conftest.err >&5
13439   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13440   (exit $ac_status); } && {
13441          test -z "$ac_c_werror_flag" ||
13442          test ! -s conftest.err
13443        } && test -s conftest.$ac_objext; then
13444   ac_cv_struct_tm=time.h
13445 else
13446   echo "$as_me: failed program was:" >&5
13447 sed 's/^/| /' conftest.$ac_ext >&5
13448
13449         ac_cv_struct_tm=sys/time.h
13450 fi
13451
13452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13453 fi
13454 { echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
13455 echo "${ECHO_T}$ac_cv_struct_tm" >&6; }
13456 if test $ac_cv_struct_tm = sys/time.h; then
13457
13458 cat >>confdefs.h <<\_ACEOF
13459 #define TM_IN_SYS_TIME 1
13460 _ACEOF
13461
13462 fi
13463
13464 { echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
13465 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6; }
13466 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
13467   echo $ECHO_N "(cached) $ECHO_C" >&6
13468 else
13469   cat >conftest.$ac_ext <<_ACEOF
13470 /* confdefs.h.  */
13471 _ACEOF
13472 cat confdefs.h >>conftest.$ac_ext
13473 cat >>conftest.$ac_ext <<_ACEOF
13474 /* end confdefs.h.  */
13475 #include <sys/types.h>
13476 #include <$ac_cv_struct_tm>
13477
13478
13479 int
13480 main ()
13481 {
13482 static struct tm ac_aggr;
13483 if (ac_aggr.tm_zone)
13484 return 0;
13485   ;
13486   return 0;
13487 }
13488 _ACEOF
13489 rm -f conftest.$ac_objext
13490 if { (ac_try="$ac_compile"
13491 case "(($ac_try" in
13492   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13493   *) ac_try_echo=$ac_try;;
13494 esac
13495 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13496   (eval "$ac_compile") 2>conftest.er1
13497   ac_status=$?
13498   grep -v '^ *+' conftest.er1 >conftest.err
13499   rm -f conftest.er1
13500   cat conftest.err >&5
13501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13502   (exit $ac_status); } && {
13503          test -z "$ac_c_werror_flag" ||
13504          test ! -s conftest.err
13505        } && test -s conftest.$ac_objext; then
13506   ac_cv_member_struct_tm_tm_zone=yes
13507 else
13508   echo "$as_me: failed program was:" >&5
13509 sed 's/^/| /' conftest.$ac_ext >&5
13510
13511         cat >conftest.$ac_ext <<_ACEOF
13512 /* confdefs.h.  */
13513 _ACEOF
13514 cat confdefs.h >>conftest.$ac_ext
13515 cat >>conftest.$ac_ext <<_ACEOF
13516 /* end confdefs.h.  */
13517 #include <sys/types.h>
13518 #include <$ac_cv_struct_tm>
13519
13520
13521 int
13522 main ()
13523 {
13524 static struct tm ac_aggr;
13525 if (sizeof ac_aggr.tm_zone)
13526 return 0;
13527   ;
13528   return 0;
13529 }
13530 _ACEOF
13531 rm -f conftest.$ac_objext
13532 if { (ac_try="$ac_compile"
13533 case "(($ac_try" in
13534   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13535   *) ac_try_echo=$ac_try;;
13536 esac
13537 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13538   (eval "$ac_compile") 2>conftest.er1
13539   ac_status=$?
13540   grep -v '^ *+' conftest.er1 >conftest.err
13541   rm -f conftest.er1
13542   cat conftest.err >&5
13543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13544   (exit $ac_status); } && {
13545          test -z "$ac_c_werror_flag" ||
13546          test ! -s conftest.err
13547        } && test -s conftest.$ac_objext; then
13548   ac_cv_member_struct_tm_tm_zone=yes
13549 else
13550   echo "$as_me: failed program was:" >&5
13551 sed 's/^/| /' conftest.$ac_ext >&5
13552
13553         ac_cv_member_struct_tm_tm_zone=no
13554 fi
13555
13556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13557 fi
13558
13559 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13560 fi
13561 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
13562 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6; }
13563 if test $ac_cv_member_struct_tm_tm_zone = yes; then
13564
13565 cat >>confdefs.h <<_ACEOF
13566 #define HAVE_STRUCT_TM_TM_ZONE 1
13567 _ACEOF
13568
13569
13570 fi
13571
13572 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13573
13574 cat >>confdefs.h <<\_ACEOF
13575 #define HAVE_TM_ZONE 1
13576 _ACEOF
13577
13578 fi
13579 { echo "$as_me:$LINENO: checking for tzname" >&5
13580 echo $ECHO_N "checking for tzname... $ECHO_C" >&6; }
13581 if test "${ac_cv_var_tzname+set}" = set; then
13582   echo $ECHO_N "(cached) $ECHO_C" >&6
13583 else
13584   cat >conftest.$ac_ext <<_ACEOF
13585 /* confdefs.h.  */
13586 _ACEOF
13587 cat confdefs.h >>conftest.$ac_ext
13588 cat >>conftest.$ac_ext <<_ACEOF
13589 /* end confdefs.h.  */
13590 #include <time.h>
13591 #ifndef tzname /* For SGI.  */
13592 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
13593 #endif
13594
13595 int
13596 main ()
13597 {
13598 atoi(*tzname);
13599   ;
13600   return 0;
13601 }
13602 _ACEOF
13603 rm -f conftest.$ac_objext conftest$ac_exeext
13604 if { (ac_try="$ac_link"
13605 case "(($ac_try" in
13606   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13607   *) ac_try_echo=$ac_try;;
13608 esac
13609 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13610   (eval "$ac_link") 2>conftest.er1
13611   ac_status=$?
13612   grep -v '^ *+' conftest.er1 >conftest.err
13613   rm -f conftest.er1
13614   cat conftest.err >&5
13615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13616   (exit $ac_status); } && {
13617          test -z "$ac_c_werror_flag" ||
13618          test ! -s conftest.err
13619        } && test -s conftest$ac_exeext &&
13620        $as_test_x conftest$ac_exeext; then
13621   ac_cv_var_tzname=yes
13622 else
13623   echo "$as_me: failed program was:" >&5
13624 sed 's/^/| /' conftest.$ac_ext >&5
13625
13626         ac_cv_var_tzname=no
13627 fi
13628
13629 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13630       conftest$ac_exeext conftest.$ac_ext
13631 fi
13632 { echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
13633 echo "${ECHO_T}$ac_cv_var_tzname" >&6; }
13634 if test $ac_cv_var_tzname = yes; then
13635
13636 cat >>confdefs.h <<\_ACEOF
13637 #define HAVE_TZNAME 1
13638 _ACEOF
13639
13640 fi
13641
13642 { echo "$as_me:$LINENO: checking for union semun" >&5
13643 echo $ECHO_N "checking for union semun... $ECHO_C" >&6; }
13644 if test "${ac_cv_type_union_semun+set}" = set; then
13645   echo $ECHO_N "(cached) $ECHO_C" >&6
13646 else
13647   cat >conftest.$ac_ext <<_ACEOF
13648 /* confdefs.h.  */
13649 _ACEOF
13650 cat confdefs.h >>conftest.$ac_ext
13651 cat >>conftest.$ac_ext <<_ACEOF
13652 /* end confdefs.h.  */
13653 #include <sys/types.h>
13654 #include <sys/ipc.h>
13655 #include <sys/sem.h>
13656
13657 typedef union semun ac__type_new_;
13658 int
13659 main ()
13660 {
13661 if ((ac__type_new_ *) 0)
13662   return 0;
13663 if (sizeof (ac__type_new_))
13664   return 0;
13665   ;
13666   return 0;
13667 }
13668 _ACEOF
13669 rm -f conftest.$ac_objext
13670 if { (ac_try="$ac_compile"
13671 case "(($ac_try" in
13672   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13673   *) ac_try_echo=$ac_try;;
13674 esac
13675 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13676   (eval "$ac_compile") 2>conftest.er1
13677   ac_status=$?
13678   grep -v '^ *+' conftest.er1 >conftest.err
13679   rm -f conftest.er1
13680   cat conftest.err >&5
13681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13682   (exit $ac_status); } && {
13683          test -z "$ac_c_werror_flag" ||
13684          test ! -s conftest.err
13685        } && test -s conftest.$ac_objext; then
13686   ac_cv_type_union_semun=yes
13687 else
13688   echo "$as_me: failed program was:" >&5
13689 sed 's/^/| /' conftest.$ac_ext >&5
13690
13691         ac_cv_type_union_semun=no
13692 fi
13693
13694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13695 fi
13696 { echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
13697 echo "${ECHO_T}$ac_cv_type_union_semun" >&6; }
13698 if test $ac_cv_type_union_semun = yes; then
13699
13700 cat >>confdefs.h <<_ACEOF
13701 #define HAVE_UNION_SEMUN 1
13702 _ACEOF
13703
13704
13705 fi
13706
13707 { echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
13708 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6; }
13709 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
13710   echo $ECHO_N "(cached) $ECHO_C" >&6
13711 else
13712   cat >conftest.$ac_ext <<_ACEOF
13713 /* confdefs.h.  */
13714 _ACEOF
13715 cat confdefs.h >>conftest.$ac_ext
13716 cat >>conftest.$ac_ext <<_ACEOF
13717 /* end confdefs.h.  */
13718 #include <sys/types.h>
13719 #ifdef HAVE_SYS_UN_H
13720 #include <sys/un.h>
13721 #endif
13722
13723
13724 typedef struct sockaddr_un ac__type_new_;
13725 int
13726 main ()
13727 {
13728 if ((ac__type_new_ *) 0)
13729   return 0;
13730 if (sizeof (ac__type_new_))
13731   return 0;
13732   ;
13733   return 0;
13734 }
13735 _ACEOF
13736 rm -f conftest.$ac_objext
13737 if { (ac_try="$ac_compile"
13738 case "(($ac_try" in
13739   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13740   *) ac_try_echo=$ac_try;;
13741 esac
13742 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13743   (eval "$ac_compile") 2>conftest.er1
13744   ac_status=$?
13745   grep -v '^ *+' conftest.er1 >conftest.err
13746   rm -f conftest.er1
13747   cat conftest.err >&5
13748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13749   (exit $ac_status); } && {
13750          test -z "$ac_c_werror_flag" ||
13751          test ! -s conftest.err
13752        } && test -s conftest.$ac_objext; then
13753   ac_cv_type_struct_sockaddr_un=yes
13754 else
13755   echo "$as_me: failed program was:" >&5
13756 sed 's/^/| /' conftest.$ac_ext >&5
13757
13758         ac_cv_type_struct_sockaddr_un=no
13759 fi
13760
13761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13762 fi
13763 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
13764 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6; }
13765 if test $ac_cv_type_struct_sockaddr_un = yes; then
13766
13767 cat >>confdefs.h <<_ACEOF
13768 #define HAVE_STRUCT_SOCKADDR_UN 1
13769 _ACEOF
13770
13771
13772 cat >>confdefs.h <<\_ACEOF
13773 #define HAVE_UNIX_SOCKETS 1
13774 _ACEOF
13775
13776 fi
13777
13778 { echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
13779 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6; }
13780 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
13781   echo $ECHO_N "(cached) $ECHO_C" >&6
13782 else
13783   cat >conftest.$ac_ext <<_ACEOF
13784 /* confdefs.h.  */
13785 _ACEOF
13786 cat confdefs.h >>conftest.$ac_ext
13787 cat >>conftest.$ac_ext <<_ACEOF
13788 /* end confdefs.h.  */
13789 #include <sys/types.h>
13790 #ifdef HAVE_SYS_SOCKET_H
13791 #include <sys/socket.h>
13792 #endif
13793
13794
13795 typedef struct sockaddr_storage ac__type_new_;
13796 int
13797 main ()
13798 {
13799 if ((ac__type_new_ *) 0)
13800   return 0;
13801 if (sizeof (ac__type_new_))
13802   return 0;
13803   ;
13804   return 0;
13805 }
13806 _ACEOF
13807 rm -f conftest.$ac_objext
13808 if { (ac_try="$ac_compile"
13809 case "(($ac_try" in
13810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13811   *) ac_try_echo=$ac_try;;
13812 esac
13813 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13814   (eval "$ac_compile") 2>conftest.er1
13815   ac_status=$?
13816   grep -v '^ *+' conftest.er1 >conftest.err
13817   rm -f conftest.er1
13818   cat conftest.err >&5
13819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13820   (exit $ac_status); } && {
13821          test -z "$ac_c_werror_flag" ||
13822          test ! -s conftest.err
13823        } && test -s conftest.$ac_objext; then
13824   ac_cv_type_struct_sockaddr_storage=yes
13825 else
13826   echo "$as_me: failed program was:" >&5
13827 sed 's/^/| /' conftest.$ac_ext >&5
13828
13829         ac_cv_type_struct_sockaddr_storage=no
13830 fi
13831
13832 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13833 fi
13834 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
13835 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6; }
13836 if test $ac_cv_type_struct_sockaddr_storage = yes; then
13837
13838 cat >>confdefs.h <<_ACEOF
13839 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
13840 _ACEOF
13841
13842
13843 fi
13844
13845 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
13846 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6; }
13847 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
13848   echo $ECHO_N "(cached) $ECHO_C" >&6
13849 else
13850   cat >conftest.$ac_ext <<_ACEOF
13851 /* confdefs.h.  */
13852 _ACEOF
13853 cat confdefs.h >>conftest.$ac_ext
13854 cat >>conftest.$ac_ext <<_ACEOF
13855 /* end confdefs.h.  */
13856 #include <sys/types.h>
13857 #ifdef HAVE_SYS_SOCKET_H
13858 #include <sys/socket.h>
13859 #endif
13860
13861
13862 int
13863 main ()
13864 {
13865 static struct sockaddr_storage ac_aggr;
13866 if (ac_aggr.ss_family)
13867 return 0;
13868   ;
13869   return 0;
13870 }
13871 _ACEOF
13872 rm -f conftest.$ac_objext
13873 if { (ac_try="$ac_compile"
13874 case "(($ac_try" in
13875   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13876   *) ac_try_echo=$ac_try;;
13877 esac
13878 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13879   (eval "$ac_compile") 2>conftest.er1
13880   ac_status=$?
13881   grep -v '^ *+' conftest.er1 >conftest.err
13882   rm -f conftest.er1
13883   cat conftest.err >&5
13884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13885   (exit $ac_status); } && {
13886          test -z "$ac_c_werror_flag" ||
13887          test ! -s conftest.err
13888        } && test -s conftest.$ac_objext; then
13889   ac_cv_member_struct_sockaddr_storage_ss_family=yes
13890 else
13891   echo "$as_me: failed program was:" >&5
13892 sed 's/^/| /' conftest.$ac_ext >&5
13893
13894         cat >conftest.$ac_ext <<_ACEOF
13895 /* confdefs.h.  */
13896 _ACEOF
13897 cat confdefs.h >>conftest.$ac_ext
13898 cat >>conftest.$ac_ext <<_ACEOF
13899 /* end confdefs.h.  */
13900 #include <sys/types.h>
13901 #ifdef HAVE_SYS_SOCKET_H
13902 #include <sys/socket.h>
13903 #endif
13904
13905
13906 int
13907 main ()
13908 {
13909 static struct sockaddr_storage ac_aggr;
13910 if (sizeof ac_aggr.ss_family)
13911 return 0;
13912   ;
13913   return 0;
13914 }
13915 _ACEOF
13916 rm -f conftest.$ac_objext
13917 if { (ac_try="$ac_compile"
13918 case "(($ac_try" in
13919   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13920   *) ac_try_echo=$ac_try;;
13921 esac
13922 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13923   (eval "$ac_compile") 2>conftest.er1
13924   ac_status=$?
13925   grep -v '^ *+' conftest.er1 >conftest.err
13926   rm -f conftest.er1
13927   cat conftest.err >&5
13928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13929   (exit $ac_status); } && {
13930          test -z "$ac_c_werror_flag" ||
13931          test ! -s conftest.err
13932        } && test -s conftest.$ac_objext; then
13933   ac_cv_member_struct_sockaddr_storage_ss_family=yes
13934 else
13935   echo "$as_me: failed program was:" >&5
13936 sed 's/^/| /' conftest.$ac_ext >&5
13937
13938         ac_cv_member_struct_sockaddr_storage_ss_family=no
13939 fi
13940
13941 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13942 fi
13943
13944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13945 fi
13946 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
13947 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
13948 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
13949
13950 cat >>confdefs.h <<_ACEOF
13951 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
13952 _ACEOF
13953
13954
13955 fi
13956 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
13957 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6; }
13958 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
13959   echo $ECHO_N "(cached) $ECHO_C" >&6
13960 else
13961   cat >conftest.$ac_ext <<_ACEOF
13962 /* confdefs.h.  */
13963 _ACEOF
13964 cat confdefs.h >>conftest.$ac_ext
13965 cat >>conftest.$ac_ext <<_ACEOF
13966 /* end confdefs.h.  */
13967 #include <sys/types.h>
13968 #ifdef HAVE_SYS_SOCKET_H
13969 #include <sys/socket.h>
13970 #endif
13971
13972
13973 int
13974 main ()
13975 {
13976 static struct sockaddr_storage ac_aggr;
13977 if (ac_aggr.__ss_family)
13978 return 0;
13979   ;
13980   return 0;
13981 }
13982 _ACEOF
13983 rm -f conftest.$ac_objext
13984 if { (ac_try="$ac_compile"
13985 case "(($ac_try" in
13986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13987   *) ac_try_echo=$ac_try;;
13988 esac
13989 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13990   (eval "$ac_compile") 2>conftest.er1
13991   ac_status=$?
13992   grep -v '^ *+' conftest.er1 >conftest.err
13993   rm -f conftest.er1
13994   cat conftest.err >&5
13995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13996   (exit $ac_status); } && {
13997          test -z "$ac_c_werror_flag" ||
13998          test ! -s conftest.err
13999        } && test -s conftest.$ac_objext; then
14000   ac_cv_member_struct_sockaddr_storage___ss_family=yes
14001 else
14002   echo "$as_me: failed program was:" >&5
14003 sed 's/^/| /' conftest.$ac_ext >&5
14004
14005         cat >conftest.$ac_ext <<_ACEOF
14006 /* confdefs.h.  */
14007 _ACEOF
14008 cat confdefs.h >>conftest.$ac_ext
14009 cat >>conftest.$ac_ext <<_ACEOF
14010 /* end confdefs.h.  */
14011 #include <sys/types.h>
14012 #ifdef HAVE_SYS_SOCKET_H
14013 #include <sys/socket.h>
14014 #endif
14015
14016
14017 int
14018 main ()
14019 {
14020 static struct sockaddr_storage ac_aggr;
14021 if (sizeof ac_aggr.__ss_family)
14022 return 0;
14023   ;
14024   return 0;
14025 }
14026 _ACEOF
14027 rm -f conftest.$ac_objext
14028 if { (ac_try="$ac_compile"
14029 case "(($ac_try" in
14030   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14031   *) ac_try_echo=$ac_try;;
14032 esac
14033 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14034   (eval "$ac_compile") 2>conftest.er1
14035   ac_status=$?
14036   grep -v '^ *+' conftest.er1 >conftest.err
14037   rm -f conftest.er1
14038   cat conftest.err >&5
14039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14040   (exit $ac_status); } && {
14041          test -z "$ac_c_werror_flag" ||
14042          test ! -s conftest.err
14043        } && test -s conftest.$ac_objext; then
14044   ac_cv_member_struct_sockaddr_storage___ss_family=yes
14045 else
14046   echo "$as_me: failed program was:" >&5
14047 sed 's/^/| /' conftest.$ac_ext >&5
14048
14049         ac_cv_member_struct_sockaddr_storage___ss_family=no
14050 fi
14051
14052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14053 fi
14054
14055 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14056 fi
14057 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
14058 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
14059 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
14060
14061 cat >>confdefs.h <<_ACEOF
14062 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
14063 _ACEOF
14064
14065
14066 fi
14067 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
14068 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6; }
14069 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
14070   echo $ECHO_N "(cached) $ECHO_C" >&6
14071 else
14072   cat >conftest.$ac_ext <<_ACEOF
14073 /* confdefs.h.  */
14074 _ACEOF
14075 cat confdefs.h >>conftest.$ac_ext
14076 cat >>conftest.$ac_ext <<_ACEOF
14077 /* end confdefs.h.  */
14078 #include <sys/types.h>
14079 #ifdef HAVE_SYS_SOCKET_H
14080 #include <sys/socket.h>
14081 #endif
14082
14083
14084 int
14085 main ()
14086 {
14087 static struct sockaddr_storage ac_aggr;
14088 if (ac_aggr.ss_len)
14089 return 0;
14090   ;
14091   return 0;
14092 }
14093 _ACEOF
14094 rm -f conftest.$ac_objext
14095 if { (ac_try="$ac_compile"
14096 case "(($ac_try" in
14097   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14098   *) ac_try_echo=$ac_try;;
14099 esac
14100 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14101   (eval "$ac_compile") 2>conftest.er1
14102   ac_status=$?
14103   grep -v '^ *+' conftest.er1 >conftest.err
14104   rm -f conftest.er1
14105   cat conftest.err >&5
14106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14107   (exit $ac_status); } && {
14108          test -z "$ac_c_werror_flag" ||
14109          test ! -s conftest.err
14110        } && test -s conftest.$ac_objext; then
14111   ac_cv_member_struct_sockaddr_storage_ss_len=yes
14112 else
14113   echo "$as_me: failed program was:" >&5
14114 sed 's/^/| /' conftest.$ac_ext >&5
14115
14116         cat >conftest.$ac_ext <<_ACEOF
14117 /* confdefs.h.  */
14118 _ACEOF
14119 cat confdefs.h >>conftest.$ac_ext
14120 cat >>conftest.$ac_ext <<_ACEOF
14121 /* end confdefs.h.  */
14122 #include <sys/types.h>
14123 #ifdef HAVE_SYS_SOCKET_H
14124 #include <sys/socket.h>
14125 #endif
14126
14127
14128 int
14129 main ()
14130 {
14131 static struct sockaddr_storage ac_aggr;
14132 if (sizeof ac_aggr.ss_len)
14133 return 0;
14134   ;
14135   return 0;
14136 }
14137 _ACEOF
14138 rm -f conftest.$ac_objext
14139 if { (ac_try="$ac_compile"
14140 case "(($ac_try" in
14141   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14142   *) ac_try_echo=$ac_try;;
14143 esac
14144 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14145   (eval "$ac_compile") 2>conftest.er1
14146   ac_status=$?
14147   grep -v '^ *+' conftest.er1 >conftest.err
14148   rm -f conftest.er1
14149   cat conftest.err >&5
14150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14151   (exit $ac_status); } && {
14152          test -z "$ac_c_werror_flag" ||
14153          test ! -s conftest.err
14154        } && test -s conftest.$ac_objext; then
14155   ac_cv_member_struct_sockaddr_storage_ss_len=yes
14156 else
14157   echo "$as_me: failed program was:" >&5
14158 sed 's/^/| /' conftest.$ac_ext >&5
14159
14160         ac_cv_member_struct_sockaddr_storage_ss_len=no
14161 fi
14162
14163 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14164 fi
14165
14166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14167 fi
14168 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
14169 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
14170 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
14171
14172 cat >>confdefs.h <<_ACEOF
14173 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
14174 _ACEOF
14175
14176
14177 fi
14178 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
14179 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6; }
14180 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
14181   echo $ECHO_N "(cached) $ECHO_C" >&6
14182 else
14183   cat >conftest.$ac_ext <<_ACEOF
14184 /* confdefs.h.  */
14185 _ACEOF
14186 cat confdefs.h >>conftest.$ac_ext
14187 cat >>conftest.$ac_ext <<_ACEOF
14188 /* end confdefs.h.  */
14189 #include <sys/types.h>
14190 #ifdef HAVE_SYS_SOCKET_H
14191 #include <sys/socket.h>
14192 #endif
14193
14194
14195 int
14196 main ()
14197 {
14198 static struct sockaddr_storage ac_aggr;
14199 if (ac_aggr.__ss_len)
14200 return 0;
14201   ;
14202   return 0;
14203 }
14204 _ACEOF
14205 rm -f conftest.$ac_objext
14206 if { (ac_try="$ac_compile"
14207 case "(($ac_try" in
14208   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14209   *) ac_try_echo=$ac_try;;
14210 esac
14211 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14212   (eval "$ac_compile") 2>conftest.er1
14213   ac_status=$?
14214   grep -v '^ *+' conftest.er1 >conftest.err
14215   rm -f conftest.er1
14216   cat conftest.err >&5
14217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14218   (exit $ac_status); } && {
14219          test -z "$ac_c_werror_flag" ||
14220          test ! -s conftest.err
14221        } && test -s conftest.$ac_objext; then
14222   ac_cv_member_struct_sockaddr_storage___ss_len=yes
14223 else
14224   echo "$as_me: failed program was:" >&5
14225 sed 's/^/| /' conftest.$ac_ext >&5
14226
14227         cat >conftest.$ac_ext <<_ACEOF
14228 /* confdefs.h.  */
14229 _ACEOF
14230 cat confdefs.h >>conftest.$ac_ext
14231 cat >>conftest.$ac_ext <<_ACEOF
14232 /* end confdefs.h.  */
14233 #include <sys/types.h>
14234 #ifdef HAVE_SYS_SOCKET_H
14235 #include <sys/socket.h>
14236 #endif
14237
14238
14239 int
14240 main ()
14241 {
14242 static struct sockaddr_storage ac_aggr;
14243 if (sizeof ac_aggr.__ss_len)
14244 return 0;
14245   ;
14246   return 0;
14247 }
14248 _ACEOF
14249 rm -f conftest.$ac_objext
14250 if { (ac_try="$ac_compile"
14251 case "(($ac_try" in
14252   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14253   *) ac_try_echo=$ac_try;;
14254 esac
14255 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14256   (eval "$ac_compile") 2>conftest.er1
14257   ac_status=$?
14258   grep -v '^ *+' conftest.er1 >conftest.err
14259   rm -f conftest.er1
14260   cat conftest.err >&5
14261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14262   (exit $ac_status); } && {
14263          test -z "$ac_c_werror_flag" ||
14264          test ! -s conftest.err
14265        } && test -s conftest.$ac_objext; then
14266   ac_cv_member_struct_sockaddr_storage___ss_len=yes
14267 else
14268   echo "$as_me: failed program was:" >&5
14269 sed 's/^/| /' conftest.$ac_ext >&5
14270
14271         ac_cv_member_struct_sockaddr_storage___ss_len=no
14272 fi
14273
14274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14275 fi
14276
14277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14278 fi
14279 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
14280 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
14281 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
14282
14283 cat >>confdefs.h <<_ACEOF
14284 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
14285 _ACEOF
14286
14287
14288 fi
14289 { echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
14290 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6; }
14291 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
14292   echo $ECHO_N "(cached) $ECHO_C" >&6
14293 else
14294   cat >conftest.$ac_ext <<_ACEOF
14295 /* confdefs.h.  */
14296 _ACEOF
14297 cat confdefs.h >>conftest.$ac_ext
14298 cat >>conftest.$ac_ext <<_ACEOF
14299 /* end confdefs.h.  */
14300 #include <sys/types.h>
14301 #ifdef HAVE_SYS_SOCKET_H
14302 #include <sys/socket.h>
14303 #endif
14304
14305
14306 int
14307 main ()
14308 {
14309 static struct sockaddr ac_aggr;
14310 if (ac_aggr.sa_len)
14311 return 0;
14312   ;
14313   return 0;
14314 }
14315 _ACEOF
14316 rm -f conftest.$ac_objext
14317 if { (ac_try="$ac_compile"
14318 case "(($ac_try" in
14319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14320   *) ac_try_echo=$ac_try;;
14321 esac
14322 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14323   (eval "$ac_compile") 2>conftest.er1
14324   ac_status=$?
14325   grep -v '^ *+' conftest.er1 >conftest.err
14326   rm -f conftest.er1
14327   cat conftest.err >&5
14328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14329   (exit $ac_status); } && {
14330          test -z "$ac_c_werror_flag" ||
14331          test ! -s conftest.err
14332        } && test -s conftest.$ac_objext; then
14333   ac_cv_member_struct_sockaddr_sa_len=yes
14334 else
14335   echo "$as_me: failed program was:" >&5
14336 sed 's/^/| /' conftest.$ac_ext >&5
14337
14338         cat >conftest.$ac_ext <<_ACEOF
14339 /* confdefs.h.  */
14340 _ACEOF
14341 cat confdefs.h >>conftest.$ac_ext
14342 cat >>conftest.$ac_ext <<_ACEOF
14343 /* end confdefs.h.  */
14344 #include <sys/types.h>
14345 #ifdef HAVE_SYS_SOCKET_H
14346 #include <sys/socket.h>
14347 #endif
14348
14349
14350 int
14351 main ()
14352 {
14353 static struct sockaddr ac_aggr;
14354 if (sizeof ac_aggr.sa_len)
14355 return 0;
14356   ;
14357   return 0;
14358 }
14359 _ACEOF
14360 rm -f conftest.$ac_objext
14361 if { (ac_try="$ac_compile"
14362 case "(($ac_try" in
14363   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14364   *) ac_try_echo=$ac_try;;
14365 esac
14366 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14367   (eval "$ac_compile") 2>conftest.er1
14368   ac_status=$?
14369   grep -v '^ *+' conftest.er1 >conftest.err
14370   rm -f conftest.er1
14371   cat conftest.err >&5
14372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14373   (exit $ac_status); } && {
14374          test -z "$ac_c_werror_flag" ||
14375          test ! -s conftest.err
14376        } && test -s conftest.$ac_objext; then
14377   ac_cv_member_struct_sockaddr_sa_len=yes
14378 else
14379   echo "$as_me: failed program was:" >&5
14380 sed 's/^/| /' conftest.$ac_ext >&5
14381
14382         ac_cv_member_struct_sockaddr_sa_len=no
14383 fi
14384
14385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14386 fi
14387
14388 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14389 fi
14390 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
14391 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6; }
14392 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
14393
14394 cat >>confdefs.h <<_ACEOF
14395 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
14396 _ACEOF
14397
14398
14399 fi
14400
14401 { echo "$as_me:$LINENO: checking for struct addrinfo" >&5
14402 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6; }
14403 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
14404   echo $ECHO_N "(cached) $ECHO_C" >&6
14405 else
14406   cat >conftest.$ac_ext <<_ACEOF
14407 /* confdefs.h.  */
14408 _ACEOF
14409 cat confdefs.h >>conftest.$ac_ext
14410 cat >>conftest.$ac_ext <<_ACEOF
14411 /* end confdefs.h.  */
14412 #include <sys/types.h>
14413 #include <sys/socket.h>
14414 #include <netdb.h>
14415
14416
14417 typedef struct addrinfo ac__type_new_;
14418 int
14419 main ()
14420 {
14421 if ((ac__type_new_ *) 0)
14422   return 0;
14423 if (sizeof (ac__type_new_))
14424   return 0;
14425   ;
14426   return 0;
14427 }
14428 _ACEOF
14429 rm -f conftest.$ac_objext
14430 if { (ac_try="$ac_compile"
14431 case "(($ac_try" in
14432   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14433   *) ac_try_echo=$ac_try;;
14434 esac
14435 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14436   (eval "$ac_compile") 2>conftest.er1
14437   ac_status=$?
14438   grep -v '^ *+' conftest.er1 >conftest.err
14439   rm -f conftest.er1
14440   cat conftest.err >&5
14441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14442   (exit $ac_status); } && {
14443          test -z "$ac_c_werror_flag" ||
14444          test ! -s conftest.err
14445        } && test -s conftest.$ac_objext; then
14446   ac_cv_type_struct_addrinfo=yes
14447 else
14448   echo "$as_me: failed program was:" >&5
14449 sed 's/^/| /' conftest.$ac_ext >&5
14450
14451         ac_cv_type_struct_addrinfo=no
14452 fi
14453
14454 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14455 fi
14456 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
14457 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6; }
14458 if test $ac_cv_type_struct_addrinfo = yes; then
14459
14460 cat >>confdefs.h <<_ACEOF
14461 #define HAVE_STRUCT_ADDRINFO 1
14462 _ACEOF
14463
14464
14465 fi
14466
14467
14468 { echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
14469 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6; }
14470 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
14471   echo $ECHO_N "(cached) $ECHO_C" >&6
14472 else
14473   cat >conftest.$ac_ext <<_ACEOF
14474 /* confdefs.h.  */
14475 _ACEOF
14476 cat confdefs.h >>conftest.$ac_ext
14477 cat >>conftest.$ac_ext <<_ACEOF
14478 /* end confdefs.h.  */
14479 #include <sys/param.h>
14480 #include <sys/types.h>
14481 #include <sys/socket.h>
14482 #include <sys/ucred.h>
14483
14484 typedef struct cmsgcred ac__type_new_;
14485 int
14486 main ()
14487 {
14488 if ((ac__type_new_ *) 0)
14489   return 0;
14490 if (sizeof (ac__type_new_))
14491   return 0;
14492   ;
14493   return 0;
14494 }
14495 _ACEOF
14496 rm -f conftest.$ac_objext
14497 if { (ac_try="$ac_compile"
14498 case "(($ac_try" in
14499   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14500   *) ac_try_echo=$ac_try;;
14501 esac
14502 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14503   (eval "$ac_compile") 2>conftest.er1
14504   ac_status=$?
14505   grep -v '^ *+' conftest.er1 >conftest.err
14506   rm -f conftest.er1
14507   cat conftest.err >&5
14508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14509   (exit $ac_status); } && {
14510          test -z "$ac_c_werror_flag" ||
14511          test ! -s conftest.err
14512        } && test -s conftest.$ac_objext; then
14513   ac_cv_type_struct_cmsgcred=yes
14514 else
14515   echo "$as_me: failed program was:" >&5
14516 sed 's/^/| /' conftest.$ac_ext >&5
14517
14518         ac_cv_type_struct_cmsgcred=no
14519 fi
14520
14521 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14522 fi
14523 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
14524 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6; }
14525 if test $ac_cv_type_struct_cmsgcred = yes; then
14526
14527 cat >>confdefs.h <<_ACEOF
14528 #define HAVE_STRUCT_CMSGCRED 1
14529 _ACEOF
14530
14531
14532 fi
14533 { echo "$as_me:$LINENO: checking for struct fcred" >&5
14534 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6; }
14535 if test "${ac_cv_type_struct_fcred+set}" = set; then
14536   echo $ECHO_N "(cached) $ECHO_C" >&6
14537 else
14538   cat >conftest.$ac_ext <<_ACEOF
14539 /* confdefs.h.  */
14540 _ACEOF
14541 cat confdefs.h >>conftest.$ac_ext
14542 cat >>conftest.$ac_ext <<_ACEOF
14543 /* end confdefs.h.  */
14544 #include <sys/param.h>
14545 #include <sys/types.h>
14546 #include <sys/socket.h>
14547 #include <sys/ucred.h>
14548
14549 typedef struct fcred ac__type_new_;
14550 int
14551 main ()
14552 {
14553 if ((ac__type_new_ *) 0)
14554   return 0;
14555 if (sizeof (ac__type_new_))
14556   return 0;
14557   ;
14558   return 0;
14559 }
14560 _ACEOF
14561 rm -f conftest.$ac_objext
14562 if { (ac_try="$ac_compile"
14563 case "(($ac_try" in
14564   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14565   *) ac_try_echo=$ac_try;;
14566 esac
14567 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14568   (eval "$ac_compile") 2>conftest.er1
14569   ac_status=$?
14570   grep -v '^ *+' conftest.er1 >conftest.err
14571   rm -f conftest.er1
14572   cat conftest.err >&5
14573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14574   (exit $ac_status); } && {
14575          test -z "$ac_c_werror_flag" ||
14576          test ! -s conftest.err
14577        } && test -s conftest.$ac_objext; then
14578   ac_cv_type_struct_fcred=yes
14579 else
14580   echo "$as_me: failed program was:" >&5
14581 sed 's/^/| /' conftest.$ac_ext >&5
14582
14583         ac_cv_type_struct_fcred=no
14584 fi
14585
14586 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14587 fi
14588 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
14589 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6; }
14590 if test $ac_cv_type_struct_fcred = yes; then
14591
14592 cat >>confdefs.h <<_ACEOF
14593 #define HAVE_STRUCT_FCRED 1
14594 _ACEOF
14595
14596
14597 fi
14598 { echo "$as_me:$LINENO: checking for struct sockcred" >&5
14599 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6; }
14600 if test "${ac_cv_type_struct_sockcred+set}" = set; then
14601   echo $ECHO_N "(cached) $ECHO_C" >&6
14602 else
14603   cat >conftest.$ac_ext <<_ACEOF
14604 /* confdefs.h.  */
14605 _ACEOF
14606 cat confdefs.h >>conftest.$ac_ext
14607 cat >>conftest.$ac_ext <<_ACEOF
14608 /* end confdefs.h.  */
14609 #include <sys/param.h>
14610 #include <sys/types.h>
14611 #include <sys/socket.h>
14612 #include <sys/ucred.h>
14613
14614 typedef struct sockcred ac__type_new_;
14615 int
14616 main ()
14617 {
14618 if ((ac__type_new_ *) 0)
14619   return 0;
14620 if (sizeof (ac__type_new_))
14621   return 0;
14622   ;
14623   return 0;
14624 }
14625 _ACEOF
14626 rm -f conftest.$ac_objext
14627 if { (ac_try="$ac_compile"
14628 case "(($ac_try" in
14629   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14630   *) ac_try_echo=$ac_try;;
14631 esac
14632 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14633   (eval "$ac_compile") 2>conftest.er1
14634   ac_status=$?
14635   grep -v '^ *+' conftest.er1 >conftest.err
14636   rm -f conftest.er1
14637   cat conftest.err >&5
14638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14639   (exit $ac_status); } && {
14640          test -z "$ac_c_werror_flag" ||
14641          test ! -s conftest.err
14642        } && test -s conftest.$ac_objext; then
14643   ac_cv_type_struct_sockcred=yes
14644 else
14645   echo "$as_me: failed program was:" >&5
14646 sed 's/^/| /' conftest.$ac_ext >&5
14647
14648         ac_cv_type_struct_sockcred=no
14649 fi
14650
14651 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14652 fi
14653 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
14654 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6; }
14655 if test $ac_cv_type_struct_sockcred = yes; then
14656
14657 cat >>confdefs.h <<_ACEOF
14658 #define HAVE_STRUCT_SOCKCRED 1
14659 _ACEOF
14660
14661
14662 fi
14663
14664
14665 { echo "$as_me:$LINENO: checking for struct option" >&5
14666 echo $ECHO_N "checking for struct option... $ECHO_C" >&6; }
14667 if test "${ac_cv_type_struct_option+set}" = set; then
14668   echo $ECHO_N "(cached) $ECHO_C" >&6
14669 else
14670   cat >conftest.$ac_ext <<_ACEOF
14671 /* confdefs.h.  */
14672 _ACEOF
14673 cat confdefs.h >>conftest.$ac_ext
14674 cat >>conftest.$ac_ext <<_ACEOF
14675 /* end confdefs.h.  */
14676 #ifdef HAVE_GETOPT_H
14677 #include <getopt.h>
14678 #endif
14679
14680 typedef struct option ac__type_new_;
14681 int
14682 main ()
14683 {
14684 if ((ac__type_new_ *) 0)
14685   return 0;
14686 if (sizeof (ac__type_new_))
14687   return 0;
14688   ;
14689   return 0;
14690 }
14691 _ACEOF
14692 rm -f conftest.$ac_objext
14693 if { (ac_try="$ac_compile"
14694 case "(($ac_try" in
14695   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14696   *) ac_try_echo=$ac_try;;
14697 esac
14698 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14699   (eval "$ac_compile") 2>conftest.er1
14700   ac_status=$?
14701   grep -v '^ *+' conftest.er1 >conftest.err
14702   rm -f conftest.er1
14703   cat conftest.err >&5
14704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14705   (exit $ac_status); } && {
14706          test -z "$ac_c_werror_flag" ||
14707          test ! -s conftest.err
14708        } && test -s conftest.$ac_objext; then
14709   ac_cv_type_struct_option=yes
14710 else
14711   echo "$as_me: failed program was:" >&5
14712 sed 's/^/| /' conftest.$ac_ext >&5
14713
14714         ac_cv_type_struct_option=no
14715 fi
14716
14717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14718 fi
14719 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
14720 echo "${ECHO_T}$ac_cv_type_struct_option" >&6; }
14721 if test $ac_cv_type_struct_option = yes; then
14722
14723 cat >>confdefs.h <<_ACEOF
14724 #define HAVE_STRUCT_OPTION 1
14725 _ACEOF
14726
14727
14728 fi
14729
14730
14731 if test "$with_zlib" = yes; then
14732   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
14733   # did not).  While we could work around the lack of z_streamp, it
14734   # seems unwise to encourage people to use such old zlib versions...
14735   { echo "$as_me:$LINENO: checking for z_streamp" >&5
14736 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6; }
14737 if test "${ac_cv_type_z_streamp+set}" = set; then
14738   echo $ECHO_N "(cached) $ECHO_C" >&6
14739 else
14740   cat >conftest.$ac_ext <<_ACEOF
14741 /* confdefs.h.  */
14742 _ACEOF
14743 cat confdefs.h >>conftest.$ac_ext
14744 cat >>conftest.$ac_ext <<_ACEOF
14745 /* end confdefs.h.  */
14746 #include <zlib.h>
14747
14748 typedef z_streamp ac__type_new_;
14749 int
14750 main ()
14751 {
14752 if ((ac__type_new_ *) 0)
14753   return 0;
14754 if (sizeof (ac__type_new_))
14755   return 0;
14756   ;
14757   return 0;
14758 }
14759 _ACEOF
14760 rm -f conftest.$ac_objext
14761 if { (ac_try="$ac_compile"
14762 case "(($ac_try" in
14763   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14764   *) ac_try_echo=$ac_try;;
14765 esac
14766 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14767   (eval "$ac_compile") 2>conftest.er1
14768   ac_status=$?
14769   grep -v '^ *+' conftest.er1 >conftest.err
14770   rm -f conftest.er1
14771   cat conftest.err >&5
14772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14773   (exit $ac_status); } && {
14774          test -z "$ac_c_werror_flag" ||
14775          test ! -s conftest.err
14776        } && test -s conftest.$ac_objext; then
14777   ac_cv_type_z_streamp=yes
14778 else
14779   echo "$as_me: failed program was:" >&5
14780 sed 's/^/| /' conftest.$ac_ext >&5
14781
14782         ac_cv_type_z_streamp=no
14783 fi
14784
14785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14786 fi
14787 { echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
14788 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6; }
14789 if test $ac_cv_type_z_streamp = yes; then
14790   :
14791 else
14792   { { echo "$as_me:$LINENO: error: zlib version is too old
14793 Use --without-zlib to disable zlib support." >&5
14794 echo "$as_me: error: zlib version is too old
14795 Use --without-zlib to disable zlib support." >&2;}
14796    { (exit 1); exit 1; }; }
14797 fi
14798
14799 fi
14800
14801 if test "$with_krb5" = yes; then
14802 # Check for differences between MIT and Heimdal (KTH) releases
14803   { echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
14804 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6; }
14805 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
14806   echo $ECHO_N "(cached) $ECHO_C" >&6
14807 else
14808   cat >conftest.$ac_ext <<_ACEOF
14809 /* confdefs.h.  */
14810 _ACEOF
14811 cat confdefs.h >>conftest.$ac_ext
14812 cat >>conftest.$ac_ext <<_ACEOF
14813 /* end confdefs.h.  */
14814 #include <krb5.h>
14815
14816 int
14817 main ()
14818 {
14819 static krb5_ticket ac_aggr;
14820 if (ac_aggr.enc_part2)
14821 return 0;
14822   ;
14823   return 0;
14824 }
14825 _ACEOF
14826 rm -f conftest.$ac_objext
14827 if { (ac_try="$ac_compile"
14828 case "(($ac_try" in
14829   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14830   *) ac_try_echo=$ac_try;;
14831 esac
14832 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14833   (eval "$ac_compile") 2>conftest.er1
14834   ac_status=$?
14835   grep -v '^ *+' conftest.er1 >conftest.err
14836   rm -f conftest.er1
14837   cat conftest.err >&5
14838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14839   (exit $ac_status); } && {
14840          test -z "$ac_c_werror_flag" ||
14841          test ! -s conftest.err
14842        } && test -s conftest.$ac_objext; then
14843   ac_cv_member_krb5_ticket_enc_part2=yes
14844 else
14845   echo "$as_me: failed program was:" >&5
14846 sed 's/^/| /' conftest.$ac_ext >&5
14847
14848         cat >conftest.$ac_ext <<_ACEOF
14849 /* confdefs.h.  */
14850 _ACEOF
14851 cat confdefs.h >>conftest.$ac_ext
14852 cat >>conftest.$ac_ext <<_ACEOF
14853 /* end confdefs.h.  */
14854 #include <krb5.h>
14855
14856 int
14857 main ()
14858 {
14859 static krb5_ticket ac_aggr;
14860 if (sizeof ac_aggr.enc_part2)
14861 return 0;
14862   ;
14863   return 0;
14864 }
14865 _ACEOF
14866 rm -f conftest.$ac_objext
14867 if { (ac_try="$ac_compile"
14868 case "(($ac_try" in
14869   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14870   *) ac_try_echo=$ac_try;;
14871 esac
14872 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14873   (eval "$ac_compile") 2>conftest.er1
14874   ac_status=$?
14875   grep -v '^ *+' conftest.er1 >conftest.err
14876   rm -f conftest.er1
14877   cat conftest.err >&5
14878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14879   (exit $ac_status); } && {
14880          test -z "$ac_c_werror_flag" ||
14881          test ! -s conftest.err
14882        } && test -s conftest.$ac_objext; then
14883   ac_cv_member_krb5_ticket_enc_part2=yes
14884 else
14885   echo "$as_me: failed program was:" >&5
14886 sed 's/^/| /' conftest.$ac_ext >&5
14887
14888         ac_cv_member_krb5_ticket_enc_part2=no
14889 fi
14890
14891 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14892 fi
14893
14894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14895 fi
14896 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
14897 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6; }
14898 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
14899
14900 cat >>confdefs.h <<_ACEOF
14901 #define HAVE_KRB5_TICKET_ENC_PART2 1
14902 _ACEOF
14903
14904
14905 else
14906   { echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
14907 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6; }
14908 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
14909   echo $ECHO_N "(cached) $ECHO_C" >&6
14910 else
14911   cat >conftest.$ac_ext <<_ACEOF
14912 /* confdefs.h.  */
14913 _ACEOF
14914 cat confdefs.h >>conftest.$ac_ext
14915 cat >>conftest.$ac_ext <<_ACEOF
14916 /* end confdefs.h.  */
14917 #include <krb5.h>
14918
14919 int
14920 main ()
14921 {
14922 static krb5_ticket ac_aggr;
14923 if (ac_aggr.client)
14924 return 0;
14925   ;
14926   return 0;
14927 }
14928 _ACEOF
14929 rm -f conftest.$ac_objext
14930 if { (ac_try="$ac_compile"
14931 case "(($ac_try" in
14932   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14933   *) ac_try_echo=$ac_try;;
14934 esac
14935 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14936   (eval "$ac_compile") 2>conftest.er1
14937   ac_status=$?
14938   grep -v '^ *+' conftest.er1 >conftest.err
14939   rm -f conftest.er1
14940   cat conftest.err >&5
14941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14942   (exit $ac_status); } && {
14943          test -z "$ac_c_werror_flag" ||
14944          test ! -s conftest.err
14945        } && test -s conftest.$ac_objext; then
14946   ac_cv_member_krb5_ticket_client=yes
14947 else
14948   echo "$as_me: failed program was:" >&5
14949 sed 's/^/| /' conftest.$ac_ext >&5
14950
14951         cat >conftest.$ac_ext <<_ACEOF
14952 /* confdefs.h.  */
14953 _ACEOF
14954 cat confdefs.h >>conftest.$ac_ext
14955 cat >>conftest.$ac_ext <<_ACEOF
14956 /* end confdefs.h.  */
14957 #include <krb5.h>
14958
14959 int
14960 main ()
14961 {
14962 static krb5_ticket ac_aggr;
14963 if (sizeof ac_aggr.client)
14964 return 0;
14965   ;
14966   return 0;
14967 }
14968 _ACEOF
14969 rm -f conftest.$ac_objext
14970 if { (ac_try="$ac_compile"
14971 case "(($ac_try" in
14972   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14973   *) ac_try_echo=$ac_try;;
14974 esac
14975 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14976   (eval "$ac_compile") 2>conftest.er1
14977   ac_status=$?
14978   grep -v '^ *+' conftest.er1 >conftest.err
14979   rm -f conftest.er1
14980   cat conftest.err >&5
14981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14982   (exit $ac_status); } && {
14983          test -z "$ac_c_werror_flag" ||
14984          test ! -s conftest.err
14985        } && test -s conftest.$ac_objext; then
14986   ac_cv_member_krb5_ticket_client=yes
14987 else
14988   echo "$as_me: failed program was:" >&5
14989 sed 's/^/| /' conftest.$ac_ext >&5
14990
14991         ac_cv_member_krb5_ticket_client=no
14992 fi
14993
14994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14995 fi
14996
14997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14998 fi
14999 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
15000 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6; }
15001 if test $ac_cv_member_krb5_ticket_client = yes; then
15002
15003 cat >>confdefs.h <<_ACEOF
15004 #define HAVE_KRB5_TICKET_CLIENT 1
15005 _ACEOF
15006
15007
15008 else
15009   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
15010 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
15011    { (exit 1); exit 1; }; }
15012 fi
15013
15014 fi
15015
15016   { echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
15017 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6; }
15018 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
15019   echo $ECHO_N "(cached) $ECHO_C" >&6
15020 else
15021   cat >conftest.$ac_ext <<_ACEOF
15022 /* confdefs.h.  */
15023 _ACEOF
15024 cat confdefs.h >>conftest.$ac_ext
15025 cat >>conftest.$ac_ext <<_ACEOF
15026 /* end confdefs.h.  */
15027 #include <krb5.h>
15028
15029 int
15030 main ()
15031 {
15032 static krb5_error ac_aggr;
15033 if (ac_aggr.text.data)
15034 return 0;
15035   ;
15036   return 0;
15037 }
15038 _ACEOF
15039 rm -f conftest.$ac_objext
15040 if { (ac_try="$ac_compile"
15041 case "(($ac_try" in
15042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15043   *) ac_try_echo=$ac_try;;
15044 esac
15045 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15046   (eval "$ac_compile") 2>conftest.er1
15047   ac_status=$?
15048   grep -v '^ *+' conftest.er1 >conftest.err
15049   rm -f conftest.er1
15050   cat conftest.err >&5
15051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15052   (exit $ac_status); } && {
15053          test -z "$ac_c_werror_flag" ||
15054          test ! -s conftest.err
15055        } && test -s conftest.$ac_objext; then
15056   ac_cv_member_krb5_error_text_data=yes
15057 else
15058   echo "$as_me: failed program was:" >&5
15059 sed 's/^/| /' conftest.$ac_ext >&5
15060
15061         cat >conftest.$ac_ext <<_ACEOF
15062 /* confdefs.h.  */
15063 _ACEOF
15064 cat confdefs.h >>conftest.$ac_ext
15065 cat >>conftest.$ac_ext <<_ACEOF
15066 /* end confdefs.h.  */
15067 #include <krb5.h>
15068
15069 int
15070 main ()
15071 {
15072 static krb5_error ac_aggr;
15073 if (sizeof ac_aggr.text.data)
15074 return 0;
15075   ;
15076   return 0;
15077 }
15078 _ACEOF
15079 rm -f conftest.$ac_objext
15080 if { (ac_try="$ac_compile"
15081 case "(($ac_try" in
15082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15083   *) ac_try_echo=$ac_try;;
15084 esac
15085 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15086   (eval "$ac_compile") 2>conftest.er1
15087   ac_status=$?
15088   grep -v '^ *+' conftest.er1 >conftest.err
15089   rm -f conftest.er1
15090   cat conftest.err >&5
15091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15092   (exit $ac_status); } && {
15093          test -z "$ac_c_werror_flag" ||
15094          test ! -s conftest.err
15095        } && test -s conftest.$ac_objext; then
15096   ac_cv_member_krb5_error_text_data=yes
15097 else
15098   echo "$as_me: failed program was:" >&5
15099 sed 's/^/| /' conftest.$ac_ext >&5
15100
15101         ac_cv_member_krb5_error_text_data=no
15102 fi
15103
15104 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15105 fi
15106
15107 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15108 fi
15109 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
15110 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6; }
15111 if test $ac_cv_member_krb5_error_text_data = yes; then
15112
15113 cat >>confdefs.h <<_ACEOF
15114 #define HAVE_KRB5_ERROR_TEXT_DATA 1
15115 _ACEOF
15116
15117
15118 else
15119   { echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
15120 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6; }
15121 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
15122   echo $ECHO_N "(cached) $ECHO_C" >&6
15123 else
15124   cat >conftest.$ac_ext <<_ACEOF
15125 /* confdefs.h.  */
15126 _ACEOF
15127 cat confdefs.h >>conftest.$ac_ext
15128 cat >>conftest.$ac_ext <<_ACEOF
15129 /* end confdefs.h.  */
15130 #include <krb5.h>
15131
15132 int
15133 main ()
15134 {
15135 static krb5_error ac_aggr;
15136 if (ac_aggr.e_data)
15137 return 0;
15138   ;
15139   return 0;
15140 }
15141 _ACEOF
15142 rm -f conftest.$ac_objext
15143 if { (ac_try="$ac_compile"
15144 case "(($ac_try" in
15145   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15146   *) ac_try_echo=$ac_try;;
15147 esac
15148 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15149   (eval "$ac_compile") 2>conftest.er1
15150   ac_status=$?
15151   grep -v '^ *+' conftest.er1 >conftest.err
15152   rm -f conftest.er1
15153   cat conftest.err >&5
15154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15155   (exit $ac_status); } && {
15156          test -z "$ac_c_werror_flag" ||
15157          test ! -s conftest.err
15158        } && test -s conftest.$ac_objext; then
15159   ac_cv_member_krb5_error_e_data=yes
15160 else
15161   echo "$as_me: failed program was:" >&5
15162 sed 's/^/| /' conftest.$ac_ext >&5
15163
15164         cat >conftest.$ac_ext <<_ACEOF
15165 /* confdefs.h.  */
15166 _ACEOF
15167 cat confdefs.h >>conftest.$ac_ext
15168 cat >>conftest.$ac_ext <<_ACEOF
15169 /* end confdefs.h.  */
15170 #include <krb5.h>
15171
15172 int
15173 main ()
15174 {
15175 static krb5_error ac_aggr;
15176 if (sizeof ac_aggr.e_data)
15177 return 0;
15178   ;
15179   return 0;
15180 }
15181 _ACEOF
15182 rm -f conftest.$ac_objext
15183 if { (ac_try="$ac_compile"
15184 case "(($ac_try" in
15185   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15186   *) ac_try_echo=$ac_try;;
15187 esac
15188 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15189   (eval "$ac_compile") 2>conftest.er1
15190   ac_status=$?
15191   grep -v '^ *+' conftest.er1 >conftest.err
15192   rm -f conftest.er1
15193   cat conftest.err >&5
15194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15195   (exit $ac_status); } && {
15196          test -z "$ac_c_werror_flag" ||
15197          test ! -s conftest.err
15198        } && test -s conftest.$ac_objext; then
15199   ac_cv_member_krb5_error_e_data=yes
15200 else
15201   echo "$as_me: failed program was:" >&5
15202 sed 's/^/| /' conftest.$ac_ext >&5
15203
15204         ac_cv_member_krb5_error_e_data=no
15205 fi
15206
15207 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15208 fi
15209
15210 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15211 fi
15212 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
15213 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6; }
15214 if test $ac_cv_member_krb5_error_e_data = yes; then
15215
15216 cat >>confdefs.h <<_ACEOF
15217 #define HAVE_KRB5_ERROR_E_DATA 1
15218 _ACEOF
15219
15220
15221 else
15222   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
15223 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
15224    { (exit 1); exit 1; }; }
15225 fi
15226
15227 fi
15228
15229
15230 # Win32 requires headers to be loaded for __stdcall, so can't use
15231 # AC_CHECK_FUNCS here.
15232   { echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
15233 echo $ECHO_N "checking for krb5_free_unparsed_name... $ECHO_C" >&6; }
15234   cat >conftest.$ac_ext <<_ACEOF
15235 /* confdefs.h.  */
15236 _ACEOF
15237 cat confdefs.h >>conftest.$ac_ext
15238 cat >>conftest.$ac_ext <<_ACEOF
15239 /* end confdefs.h.  */
15240 #include <krb5.h>
15241 int
15242 main ()
15243 {
15244 krb5_free_unparsed_name(NULL,NULL);
15245   ;
15246   return 0;
15247 }
15248 _ACEOF
15249 rm -f conftest.$ac_objext conftest$ac_exeext
15250 if { (ac_try="$ac_link"
15251 case "(($ac_try" in
15252   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15253   *) ac_try_echo=$ac_try;;
15254 esac
15255 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15256   (eval "$ac_link") 2>conftest.er1
15257   ac_status=$?
15258   grep -v '^ *+' conftest.er1 >conftest.err
15259   rm -f conftest.er1
15260   cat conftest.err >&5
15261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15262   (exit $ac_status); } && {
15263          test -z "$ac_c_werror_flag" ||
15264          test ! -s conftest.err
15265        } && test -s conftest$ac_exeext &&
15266        $as_test_x conftest$ac_exeext; then
15267
15268 cat >>confdefs.h <<\_ACEOF
15269 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
15270 _ACEOF
15271
15272 { echo "$as_me:$LINENO: result: yes" >&5
15273 echo "${ECHO_T}yes" >&6; }
15274 else
15275   echo "$as_me: failed program was:" >&5
15276 sed 's/^/| /' conftest.$ac_ext >&5
15277
15278         { echo "$as_me:$LINENO: result: no" >&5
15279 echo "${ECHO_T}no" >&6; }
15280 fi
15281
15282 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15283       conftest$ac_exeext conftest.$ac_ext
15284 fi
15285
15286
15287 ##
15288 ## Functions, global variables
15289 ##
15290
15291 { echo "$as_me:$LINENO: checking for int timezone" >&5
15292 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6; }
15293 if test "${pgac_cv_var_int_timezone+set}" = set; then
15294   echo $ECHO_N "(cached) $ECHO_C" >&6
15295 else
15296   cat >conftest.$ac_ext <<_ACEOF
15297 /* confdefs.h.  */
15298 _ACEOF
15299 cat confdefs.h >>conftest.$ac_ext
15300 cat >>conftest.$ac_ext <<_ACEOF
15301 /* end confdefs.h.  */
15302 #include <time.h>
15303 int res;
15304 int
15305 main ()
15306 {
15307 #ifndef __CYGWIN__
15308 res = timezone / 60;
15309 #else
15310 res = _timezone / 60;
15311 #endif
15312   ;
15313   return 0;
15314 }
15315 _ACEOF
15316 rm -f conftest.$ac_objext conftest$ac_exeext
15317 if { (ac_try="$ac_link"
15318 case "(($ac_try" in
15319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15320   *) ac_try_echo=$ac_try;;
15321 esac
15322 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15323   (eval "$ac_link") 2>conftest.er1
15324   ac_status=$?
15325   grep -v '^ *+' conftest.er1 >conftest.err
15326   rm -f conftest.er1
15327   cat conftest.err >&5
15328   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_exeext &&
15333        $as_test_x conftest$ac_exeext; then
15334   pgac_cv_var_int_timezone=yes
15335 else
15336   echo "$as_me: failed program was:" >&5
15337 sed 's/^/| /' conftest.$ac_ext >&5
15338
15339         pgac_cv_var_int_timezone=no
15340 fi
15341
15342 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15343       conftest$ac_exeext conftest.$ac_ext
15344 fi
15345 { echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
15346 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6; }
15347 if test x"$pgac_cv_var_int_timezone" = xyes ; then
15348
15349 cat >>confdefs.h <<\_ACEOF
15350 #define HAVE_INT_TIMEZONE
15351 _ACEOF
15352
15353 fi
15354 { echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
15355 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6; }
15356  if test "${ac_cv_func_accept_return+set}" = set; then
15357   echo $ECHO_N "(cached) $ECHO_C" >&6
15358 else
15359    if test "${ac_cv_func_accept_arg1+set}" = set; then
15360   echo $ECHO_N "(cached) $ECHO_C" >&6
15361 else
15362     if test "${ac_cv_func_accept_arg2+set}" = set; then
15363   echo $ECHO_N "(cached) $ECHO_C" >&6
15364 else
15365      if test "${ac_cv_func_accept_arg3+set}" = set; then
15366   echo $ECHO_N "(cached) $ECHO_C" >&6
15367 else
15368       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
15369       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
15370        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
15371         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
15372          cat >conftest.$ac_ext <<_ACEOF
15373 /* confdefs.h.  */
15374 _ACEOF
15375 cat confdefs.h >>conftest.$ac_ext
15376 cat >>conftest.$ac_ext <<_ACEOF
15377 /* end confdefs.h.  */
15378 #ifdef HAVE_SYS_TYPES_H
15379 #include <sys/types.h>
15380 #endif
15381 #ifdef HAVE_SYS_SOCKET_H
15382 #include <sys/socket.h>
15383 #endif
15384 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
15385 int
15386 main ()
15387 {
15388
15389   ;
15390   return 0;
15391 }
15392 _ACEOF
15393 rm -f conftest.$ac_objext
15394 if { (ac_try="$ac_compile"
15395 case "(($ac_try" in
15396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15397   *) ac_try_echo=$ac_try;;
15398 esac
15399 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15400   (eval "$ac_compile") 2>conftest.er1
15401   ac_status=$?
15402   grep -v '^ *+' conftest.er1 >conftest.err
15403   rm -f conftest.er1
15404   cat conftest.err >&5
15405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15406   (exit $ac_status); } && {
15407          test -z "$ac_c_werror_flag" ||
15408          test ! -s conftest.err
15409        } && test -s conftest.$ac_objext; then
15410   ac_not_found=no; break 4
15411 else
15412   echo "$as_me: failed program was:" >&5
15413 sed 's/^/| /' conftest.$ac_ext >&5
15414
15415         ac_not_found=yes
15416 fi
15417
15418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15419        done
15420       done
15421      done
15422     done
15423     if test "$ac_not_found" = yes; then
15424       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
15425 echo "$as_me: error: could not determine argument types" >&2;}
15426    { (exit 1); exit 1; }; }
15427     fi
15428     if test "$ac_cv_func_accept_arg3" = "void"; then
15429       ac_cv_func_accept_arg3=int
15430     fi
15431
15432 fi
15433
15434 fi
15435
15436 fi
15437
15438 fi
15439  { 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
15440 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
15441
15442 cat >>confdefs.h <<_ACEOF
15443 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
15444 _ACEOF
15445
15446
15447 cat >>confdefs.h <<_ACEOF
15448 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
15449 _ACEOF
15450
15451
15452 cat >>confdefs.h <<_ACEOF
15453 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
15454 _ACEOF
15455
15456
15457 cat >>confdefs.h <<_ACEOF
15458 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
15459 _ACEOF
15460
15461
15462 { echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
15463 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6; }
15464 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
15465   echo $ECHO_N "(cached) $ECHO_C" >&6
15466 else
15467   cat >conftest.$ac_ext <<_ACEOF
15468 /* confdefs.h.  */
15469 _ACEOF
15470 cat confdefs.h >>conftest.$ac_ext
15471 cat >>conftest.$ac_ext <<_ACEOF
15472 /* end confdefs.h.  */
15473 #include <sys/time.h>
15474 int
15475 main ()
15476 {
15477 struct timeval *tp;
15478 struct timezone *tzp;
15479 gettimeofday(tp,tzp);
15480   ;
15481   return 0;
15482 }
15483 _ACEOF
15484 rm -f conftest.$ac_objext
15485 if { (ac_try="$ac_compile"
15486 case "(($ac_try" in
15487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15488   *) ac_try_echo=$ac_try;;
15489 esac
15490 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15491   (eval "$ac_compile") 2>conftest.er1
15492   ac_status=$?
15493   grep -v '^ *+' conftest.er1 >conftest.err
15494   rm -f conftest.er1
15495   cat conftest.err >&5
15496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15497   (exit $ac_status); } && {
15498          test -z "$ac_c_werror_flag" ||
15499          test ! -s conftest.err
15500        } && test -s conftest.$ac_objext; then
15501   pgac_cv_func_gettimeofday_1arg=no
15502 else
15503   echo "$as_me: failed program was:" >&5
15504 sed 's/^/| /' conftest.$ac_ext >&5
15505
15506         pgac_cv_func_gettimeofday_1arg=yes
15507 fi
15508
15509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15510 fi
15511 { echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
15512 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6; }
15513 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
15514
15515 cat >>confdefs.h <<\_ACEOF
15516 #define GETTIMEOFDAY_1ARG
15517 _ACEOF
15518
15519 fi
15520
15521
15522
15523
15524
15525
15526
15527
15528
15529
15530
15531
15532
15533
15534
15535
15536
15537
15538
15539
15540
15541
15542
15543 for ac_func in cbrt dlopen fcvt fdatasync getpeereid getrlimit memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
15544 do
15545 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15546 { echo "$as_me:$LINENO: checking for $ac_func" >&5
15547 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15548 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15549   echo $ECHO_N "(cached) $ECHO_C" >&6
15550 else
15551   cat >conftest.$ac_ext <<_ACEOF
15552 /* confdefs.h.  */
15553 _ACEOF
15554 cat confdefs.h >>conftest.$ac_ext
15555 cat >>conftest.$ac_ext <<_ACEOF
15556 /* end confdefs.h.  */
15557 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15558    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15559 #define $ac_func innocuous_$ac_func
15560
15561 /* System header to define __stub macros and hopefully few prototypes,
15562     which can conflict with char $ac_func (); below.
15563     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15564     <limits.h> exists even on freestanding compilers.  */
15565
15566 #ifdef __STDC__
15567 # include <limits.h>
15568 #else
15569 # include <assert.h>
15570 #endif
15571
15572 #undef $ac_func
15573
15574 /* Override any GCC internal prototype to avoid an error.
15575    Use char because int might match the return type of a GCC
15576    builtin and then its argument prototype would still apply.  */
15577 #ifdef __cplusplus
15578 extern "C"
15579 #endif
15580 char $ac_func ();
15581 /* The GNU C library defines this for functions which it implements
15582     to always fail with ENOSYS.  Some functions are actually named
15583     something starting with __ and the normal name is an alias.  */
15584 #if defined __stub_$ac_func || defined __stub___$ac_func
15585 choke me
15586 #endif
15587
15588 int
15589 main ()
15590 {
15591 return $ac_func ();
15592   ;
15593   return 0;
15594 }
15595 _ACEOF
15596 rm -f conftest.$ac_objext conftest$ac_exeext
15597 if { (ac_try="$ac_link"
15598 case "(($ac_try" in
15599   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15600   *) ac_try_echo=$ac_try;;
15601 esac
15602 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15603   (eval "$ac_link") 2>conftest.er1
15604   ac_status=$?
15605   grep -v '^ *+' conftest.er1 >conftest.err
15606   rm -f conftest.er1
15607   cat conftest.err >&5
15608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15609   (exit $ac_status); } && {
15610          test -z "$ac_c_werror_flag" ||
15611          test ! -s conftest.err
15612        } && test -s conftest$ac_exeext &&
15613        $as_test_x conftest$ac_exeext; then
15614   eval "$as_ac_var=yes"
15615 else
15616   echo "$as_me: failed program was:" >&5
15617 sed 's/^/| /' conftest.$ac_ext >&5
15618
15619         eval "$as_ac_var=no"
15620 fi
15621
15622 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15623       conftest$ac_exeext conftest.$ac_ext
15624 fi
15625 ac_res=`eval echo '${'$as_ac_var'}'`
15626                { echo "$as_me:$LINENO: result: $ac_res" >&5
15627 echo "${ECHO_T}$ac_res" >&6; }
15628 if test `eval echo '${'$as_ac_var'}'` = yes; then
15629   cat >>confdefs.h <<_ACEOF
15630 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15631 _ACEOF
15632
15633 fi
15634 done
15635
15636
15637 { echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
15638 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6; }
15639 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
15640   echo $ECHO_N "(cached) $ECHO_C" >&6
15641 else
15642   cat >conftest.$ac_ext <<_ACEOF
15643 /* confdefs.h.  */
15644 _ACEOF
15645 cat confdefs.h >>conftest.$ac_ext
15646 cat >>conftest.$ac_ext <<_ACEOF
15647 /* end confdefs.h.  */
15648 #include <unistd.h>
15649
15650 int
15651 main ()
15652 {
15653 #ifndef fdatasync
15654   (void) fdatasync;
15655 #endif
15656
15657   ;
15658   return 0;
15659 }
15660 _ACEOF
15661 rm -f conftest.$ac_objext
15662 if { (ac_try="$ac_compile"
15663 case "(($ac_try" in
15664   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15665   *) ac_try_echo=$ac_try;;
15666 esac
15667 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15668   (eval "$ac_compile") 2>conftest.er1
15669   ac_status=$?
15670   grep -v '^ *+' conftest.er1 >conftest.err
15671   rm -f conftest.er1
15672   cat conftest.err >&5
15673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15674   (exit $ac_status); } && {
15675          test -z "$ac_c_werror_flag" ||
15676          test ! -s conftest.err
15677        } && test -s conftest.$ac_objext; then
15678   ac_cv_have_decl_fdatasync=yes
15679 else
15680   echo "$as_me: failed program was:" >&5
15681 sed 's/^/| /' conftest.$ac_ext >&5
15682
15683         ac_cv_have_decl_fdatasync=no
15684 fi
15685
15686 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15687 fi
15688 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
15689 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6; }
15690 if test $ac_cv_have_decl_fdatasync = yes; then
15691
15692 cat >>confdefs.h <<_ACEOF
15693 #define HAVE_DECL_FDATASYNC 1
15694 _ACEOF
15695
15696
15697 else
15698   cat >>confdefs.h <<_ACEOF
15699 #define HAVE_DECL_FDATASYNC 0
15700 _ACEOF
15701
15702
15703 fi
15704
15705
15706 { echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
15707 echo $ECHO_N "checking whether posix_fadvise is declared... $ECHO_C" >&6; }
15708 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
15709   echo $ECHO_N "(cached) $ECHO_C" >&6
15710 else
15711   cat >conftest.$ac_ext <<_ACEOF
15712 /* confdefs.h.  */
15713 _ACEOF
15714 cat confdefs.h >>conftest.$ac_ext
15715 cat >>conftest.$ac_ext <<_ACEOF
15716 /* end confdefs.h.  */
15717 #include <fcntl.h>
15718
15719 int
15720 main ()
15721 {
15722 #ifndef posix_fadvise
15723   (void) posix_fadvise;
15724 #endif
15725
15726   ;
15727   return 0;
15728 }
15729 _ACEOF
15730 rm -f conftest.$ac_objext
15731 if { (ac_try="$ac_compile"
15732 case "(($ac_try" in
15733   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15734   *) ac_try_echo=$ac_try;;
15735 esac
15736 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15737   (eval "$ac_compile") 2>conftest.er1
15738   ac_status=$?
15739   grep -v '^ *+' conftest.er1 >conftest.err
15740   rm -f conftest.er1
15741   cat conftest.err >&5
15742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15743   (exit $ac_status); } && {
15744          test -z "$ac_c_werror_flag" ||
15745          test ! -s conftest.err
15746        } && test -s conftest.$ac_objext; then
15747   ac_cv_have_decl_posix_fadvise=yes
15748 else
15749   echo "$as_me: failed program was:" >&5
15750 sed 's/^/| /' conftest.$ac_ext >&5
15751
15752         ac_cv_have_decl_posix_fadvise=no
15753 fi
15754
15755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15756 fi
15757 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
15758 echo "${ECHO_T}$ac_cv_have_decl_posix_fadvise" >&6; }
15759 if test $ac_cv_have_decl_posix_fadvise = yes; then
15760
15761 cat >>confdefs.h <<_ACEOF
15762 #define HAVE_DECL_POSIX_FADVISE 1
15763 _ACEOF
15764
15765
15766 else
15767   cat >>confdefs.h <<_ACEOF
15768 #define HAVE_DECL_POSIX_FADVISE 0
15769 _ACEOF
15770
15771
15772 fi
15773
15774
15775 { echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
15776 echo $ECHO_N "checking whether strlcat is declared... $ECHO_C" >&6; }
15777 if test "${ac_cv_have_decl_strlcat+set}" = set; then
15778   echo $ECHO_N "(cached) $ECHO_C" >&6
15779 else
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 $ac_includes_default
15787 int
15788 main ()
15789 {
15790 #ifndef strlcat
15791   (void) strlcat;
15792 #endif
15793
15794   ;
15795   return 0;
15796 }
15797 _ACEOF
15798 rm -f conftest.$ac_objext
15799 if { (ac_try="$ac_compile"
15800 case "(($ac_try" in
15801   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15802   *) ac_try_echo=$ac_try;;
15803 esac
15804 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15805   (eval "$ac_compile") 2>conftest.er1
15806   ac_status=$?
15807   grep -v '^ *+' conftest.er1 >conftest.err
15808   rm -f conftest.er1
15809   cat conftest.err >&5
15810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15811   (exit $ac_status); } && {
15812          test -z "$ac_c_werror_flag" ||
15813          test ! -s conftest.err
15814        } && test -s conftest.$ac_objext; then
15815   ac_cv_have_decl_strlcat=yes
15816 else
15817   echo "$as_me: failed program was:" >&5
15818 sed 's/^/| /' conftest.$ac_ext >&5
15819
15820         ac_cv_have_decl_strlcat=no
15821 fi
15822
15823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15824 fi
15825 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
15826 echo "${ECHO_T}$ac_cv_have_decl_strlcat" >&6; }
15827 if test $ac_cv_have_decl_strlcat = yes; then
15828
15829 cat >>confdefs.h <<_ACEOF
15830 #define HAVE_DECL_STRLCAT 1
15831 _ACEOF
15832
15833
15834 else
15835   cat >>confdefs.h <<_ACEOF
15836 #define HAVE_DECL_STRLCAT 0
15837 _ACEOF
15838
15839
15840 fi
15841 { echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
15842 echo $ECHO_N "checking whether strlcpy is declared... $ECHO_C" >&6; }
15843 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
15844   echo $ECHO_N "(cached) $ECHO_C" >&6
15845 else
15846   cat >conftest.$ac_ext <<_ACEOF
15847 /* confdefs.h.  */
15848 _ACEOF
15849 cat confdefs.h >>conftest.$ac_ext
15850 cat >>conftest.$ac_ext <<_ACEOF
15851 /* end confdefs.h.  */
15852 $ac_includes_default
15853 int
15854 main ()
15855 {
15856 #ifndef strlcpy
15857   (void) strlcpy;
15858 #endif
15859
15860   ;
15861   return 0;
15862 }
15863 _ACEOF
15864 rm -f conftest.$ac_objext
15865 if { (ac_try="$ac_compile"
15866 case "(($ac_try" in
15867   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15868   *) ac_try_echo=$ac_try;;
15869 esac
15870 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15871   (eval "$ac_compile") 2>conftest.er1
15872   ac_status=$?
15873   grep -v '^ *+' conftest.er1 >conftest.err
15874   rm -f conftest.er1
15875   cat conftest.err >&5
15876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15877   (exit $ac_status); } && {
15878          test -z "$ac_c_werror_flag" ||
15879          test ! -s conftest.err
15880        } && test -s conftest.$ac_objext; then
15881   ac_cv_have_decl_strlcpy=yes
15882 else
15883   echo "$as_me: failed program was:" >&5
15884 sed 's/^/| /' conftest.$ac_ext >&5
15885
15886         ac_cv_have_decl_strlcpy=no
15887 fi
15888
15889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15890 fi
15891 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
15892 echo "${ECHO_T}$ac_cv_have_decl_strlcpy" >&6; }
15893 if test $ac_cv_have_decl_strlcpy = yes; then
15894
15895 cat >>confdefs.h <<_ACEOF
15896 #define HAVE_DECL_STRLCPY 1
15897 _ACEOF
15898
15899
15900 else
15901   cat >>confdefs.h <<_ACEOF
15902 #define HAVE_DECL_STRLCPY 0
15903 _ACEOF
15904
15905
15906 fi
15907
15908
15909 # This is probably only present on Darwin, but may as well check always
15910 { echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
15911 echo $ECHO_N "checking whether F_FULLFSYNC is declared... $ECHO_C" >&6; }
15912 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
15913   echo $ECHO_N "(cached) $ECHO_C" >&6
15914 else
15915   cat >conftest.$ac_ext <<_ACEOF
15916 /* confdefs.h.  */
15917 _ACEOF
15918 cat confdefs.h >>conftest.$ac_ext
15919 cat >>conftest.$ac_ext <<_ACEOF
15920 /* end confdefs.h.  */
15921 #include <fcntl.h>
15922
15923 int
15924 main ()
15925 {
15926 #ifndef F_FULLFSYNC
15927   (void) F_FULLFSYNC;
15928 #endif
15929
15930   ;
15931   return 0;
15932 }
15933 _ACEOF
15934 rm -f conftest.$ac_objext
15935 if { (ac_try="$ac_compile"
15936 case "(($ac_try" in
15937   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15938   *) ac_try_echo=$ac_try;;
15939 esac
15940 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15941   (eval "$ac_compile") 2>conftest.er1
15942   ac_status=$?
15943   grep -v '^ *+' conftest.er1 >conftest.err
15944   rm -f conftest.er1
15945   cat conftest.err >&5
15946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15947   (exit $ac_status); } && {
15948          test -z "$ac_c_werror_flag" ||
15949          test ! -s conftest.err
15950        } && test -s conftest.$ac_objext; then
15951   ac_cv_have_decl_F_FULLFSYNC=yes
15952 else
15953   echo "$as_me: failed program was:" >&5
15954 sed 's/^/| /' conftest.$ac_ext >&5
15955
15956         ac_cv_have_decl_F_FULLFSYNC=no
15957 fi
15958
15959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15960 fi
15961 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
15962 echo "${ECHO_T}$ac_cv_have_decl_F_FULLFSYNC" >&6; }
15963 if test $ac_cv_have_decl_F_FULLFSYNC = yes; then
15964
15965 cat >>confdefs.h <<_ACEOF
15966 #define HAVE_DECL_F_FULLFSYNC 1
15967 _ACEOF
15968
15969
15970 else
15971   cat >>confdefs.h <<_ACEOF
15972 #define HAVE_DECL_F_FULLFSYNC 0
15973 _ACEOF
15974
15975
15976 fi
15977
15978
15979
15980 HAVE_IPV6=no
15981 { echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
15982 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6; }
15983 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
15984   echo $ECHO_N "(cached) $ECHO_C" >&6
15985 else
15986   cat >conftest.$ac_ext <<_ACEOF
15987 /* confdefs.h.  */
15988 _ACEOF
15989 cat confdefs.h >>conftest.$ac_ext
15990 cat >>conftest.$ac_ext <<_ACEOF
15991 /* end confdefs.h.  */
15992 $ac_includes_default
15993 #include <netinet/in.h>
15994
15995 typedef struct sockaddr_in6 ac__type_new_;
15996 int
15997 main ()
15998 {
15999 if ((ac__type_new_ *) 0)
16000   return 0;
16001 if (sizeof (ac__type_new_))
16002   return 0;
16003   ;
16004   return 0;
16005 }
16006 _ACEOF
16007 rm -f conftest.$ac_objext
16008 if { (ac_try="$ac_compile"
16009 case "(($ac_try" in
16010   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16011   *) ac_try_echo=$ac_try;;
16012 esac
16013 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16014   (eval "$ac_compile") 2>conftest.er1
16015   ac_status=$?
16016   grep -v '^ *+' conftest.er1 >conftest.err
16017   rm -f conftest.er1
16018   cat conftest.err >&5
16019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16020   (exit $ac_status); } && {
16021          test -z "$ac_c_werror_flag" ||
16022          test ! -s conftest.err
16023        } && test -s conftest.$ac_objext; then
16024   ac_cv_type_struct_sockaddr_in6=yes
16025 else
16026   echo "$as_me: failed program was:" >&5
16027 sed 's/^/| /' conftest.$ac_ext >&5
16028
16029         ac_cv_type_struct_sockaddr_in6=no
16030 fi
16031
16032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16033 fi
16034 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
16035 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6; }
16036 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
16037
16038 cat >>confdefs.h <<\_ACEOF
16039 #define HAVE_IPV6 1
16040 _ACEOF
16041
16042          HAVE_IPV6=yes
16043 fi
16044
16045
16046
16047 { echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
16048 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6; }
16049 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
16050   echo $ECHO_N "(cached) $ECHO_C" >&6
16051 else
16052   cat >conftest.$ac_ext <<_ACEOF
16053 /* confdefs.h.  */
16054 _ACEOF
16055 cat confdefs.h >>conftest.$ac_ext
16056 cat >>conftest.$ac_ext <<_ACEOF
16057 /* end confdefs.h.  */
16058 #include <machine/vmparam.h>
16059 #include <sys/exec.h>
16060
16061 int
16062 main ()
16063 {
16064 PS_STRINGS->ps_nargvstr = 1;
16065 PS_STRINGS->ps_argvstr = "foo";
16066   ;
16067   return 0;
16068 }
16069 _ACEOF
16070 rm -f conftest.$ac_objext conftest$ac_exeext
16071 if { (ac_try="$ac_link"
16072 case "(($ac_try" in
16073   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16074   *) ac_try_echo=$ac_try;;
16075 esac
16076 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16077   (eval "$ac_link") 2>conftest.er1
16078   ac_status=$?
16079   grep -v '^ *+' conftest.er1 >conftest.err
16080   rm -f conftest.er1
16081   cat conftest.err >&5
16082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16083   (exit $ac_status); } && {
16084          test -z "$ac_c_werror_flag" ||
16085          test ! -s conftest.err
16086        } && test -s conftest$ac_exeext &&
16087        $as_test_x conftest$ac_exeext; then
16088   pgac_cv_var_PS_STRINGS=yes
16089 else
16090   echo "$as_me: failed program was:" >&5
16091 sed 's/^/| /' conftest.$ac_ext >&5
16092
16093         pgac_cv_var_PS_STRINGS=no
16094 fi
16095
16096 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16097       conftest$ac_exeext conftest.$ac_ext
16098 fi
16099 { echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
16100 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6; }
16101 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
16102
16103 cat >>confdefs.h <<\_ACEOF
16104 #define HAVE_PS_STRINGS
16105 _ACEOF
16106
16107 fi
16108
16109
16110 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
16111 # is missing.  Yes, there are machines that have only one.  We may
16112 # also decide to use snprintf.c if snprintf() is present but does not
16113 # have all the features we need --- see below.
16114
16115 if test "$PORTNAME" = "win32"; then
16116   # Win32 gets snprintf.c built unconditionally.
16117   #
16118   # To properly translate all NLS languages strings, we must support the
16119   # *printf() %$ format, which allows *printf() arguments to be selected
16120   # by position in the translated string.
16121   #
16122   # libintl versions < 0.13 use the native *printf() functions, and Win32
16123   # *printf() doesn't understand %$, so we must use our /port versions,
16124   # which do understand %$. libintl versions >= 0.13 include their own
16125   # *printf versions on Win32.  The libintl 0.13 release note text is:
16126   #
16127   #   C format strings with positions, as they arise when a translator
16128   #   needs to reorder a sentence, are now supported on all platforms.
16129   #   On those few platforms (NetBSD and Woe32) for which the native
16130   #   printf()/fprintf()/... functions don't support such format
16131   #   strings, replacements are provided through <libintl.h>.
16132   #
16133   # We could use libintl >= 0.13's *printf() if we were sure that we had
16134   # a litint >= 0.13 at runtime, but seeing that there is no clean way
16135   # to guarantee that, it is best to just use our own, so we are sure to
16136   # get %$ support. In include/port.h we disable the *printf() macros
16137   # that might have been defined by libintl.
16138   #
16139   # We do this unconditionally whether NLS is used or not so we are sure
16140   # that all Win32 libraries and binaries behave the same.
16141   pgac_need_repl_snprintf=yes
16142 else
16143   pgac_need_repl_snprintf=no
16144
16145 for ac_func in snprintf
16146 do
16147 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16148 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16149 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16150 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16151   echo $ECHO_N "(cached) $ECHO_C" >&6
16152 else
16153   cat >conftest.$ac_ext <<_ACEOF
16154 /* confdefs.h.  */
16155 _ACEOF
16156 cat confdefs.h >>conftest.$ac_ext
16157 cat >>conftest.$ac_ext <<_ACEOF
16158 /* end confdefs.h.  */
16159 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16160    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16161 #define $ac_func innocuous_$ac_func
16162
16163 /* System header to define __stub macros and hopefully few prototypes,
16164     which can conflict with char $ac_func (); below.
16165     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16166     <limits.h> exists even on freestanding compilers.  */
16167
16168 #ifdef __STDC__
16169 # include <limits.h>
16170 #else
16171 # include <assert.h>
16172 #endif
16173
16174 #undef $ac_func
16175
16176 /* Override any GCC internal prototype to avoid an error.
16177    Use char because int might match the return type of a GCC
16178    builtin and then its argument prototype would still apply.  */
16179 #ifdef __cplusplus
16180 extern "C"
16181 #endif
16182 char $ac_func ();
16183 /* The GNU C library defines this for functions which it implements
16184     to always fail with ENOSYS.  Some functions are actually named
16185     something starting with __ and the normal name is an alias.  */
16186 #if defined __stub_$ac_func || defined __stub___$ac_func
16187 choke me
16188 #endif
16189
16190 int
16191 main ()
16192 {
16193 return $ac_func ();
16194   ;
16195   return 0;
16196 }
16197 _ACEOF
16198 rm -f conftest.$ac_objext conftest$ac_exeext
16199 if { (ac_try="$ac_link"
16200 case "(($ac_try" in
16201   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16202   *) ac_try_echo=$ac_try;;
16203 esac
16204 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16205   (eval "$ac_link") 2>conftest.er1
16206   ac_status=$?
16207   grep -v '^ *+' conftest.er1 >conftest.err
16208   rm -f conftest.er1
16209   cat conftest.err >&5
16210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16211   (exit $ac_status); } && {
16212          test -z "$ac_c_werror_flag" ||
16213          test ! -s conftest.err
16214        } && test -s conftest$ac_exeext &&
16215        $as_test_x conftest$ac_exeext; then
16216   eval "$as_ac_var=yes"
16217 else
16218   echo "$as_me: failed program was:" >&5
16219 sed 's/^/| /' conftest.$ac_ext >&5
16220
16221         eval "$as_ac_var=no"
16222 fi
16223
16224 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16225       conftest$ac_exeext conftest.$ac_ext
16226 fi
16227 ac_res=`eval echo '${'$as_ac_var'}'`
16228                { echo "$as_me:$LINENO: result: $ac_res" >&5
16229 echo "${ECHO_T}$ac_res" >&6; }
16230 if test `eval echo '${'$as_ac_var'}'` = yes; then
16231   cat >>confdefs.h <<_ACEOF
16232 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16233 _ACEOF
16234
16235 else
16236   pgac_need_repl_snprintf=yes
16237 fi
16238 done
16239
16240
16241 for ac_func in vsnprintf
16242 do
16243 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16244 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16245 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16246 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16247   echo $ECHO_N "(cached) $ECHO_C" >&6
16248 else
16249   cat >conftest.$ac_ext <<_ACEOF
16250 /* confdefs.h.  */
16251 _ACEOF
16252 cat confdefs.h >>conftest.$ac_ext
16253 cat >>conftest.$ac_ext <<_ACEOF
16254 /* end confdefs.h.  */
16255 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16256    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16257 #define $ac_func innocuous_$ac_func
16258
16259 /* System header to define __stub macros and hopefully few prototypes,
16260     which can conflict with char $ac_func (); below.
16261     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16262     <limits.h> exists even on freestanding compilers.  */
16263
16264 #ifdef __STDC__
16265 # include <limits.h>
16266 #else
16267 # include <assert.h>
16268 #endif
16269
16270 #undef $ac_func
16271
16272 /* Override any GCC internal prototype to avoid an error.
16273    Use char because int might match the return type of a GCC
16274    builtin and then its argument prototype would still apply.  */
16275 #ifdef __cplusplus
16276 extern "C"
16277 #endif
16278 char $ac_func ();
16279 /* The GNU C library defines this for functions which it implements
16280     to always fail with ENOSYS.  Some functions are actually named
16281     something starting with __ and the normal name is an alias.  */
16282 #if defined __stub_$ac_func || defined __stub___$ac_func
16283 choke me
16284 #endif
16285
16286 int
16287 main ()
16288 {
16289 return $ac_func ();
16290   ;
16291   return 0;
16292 }
16293 _ACEOF
16294 rm -f conftest.$ac_objext conftest$ac_exeext
16295 if { (ac_try="$ac_link"
16296 case "(($ac_try" in
16297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16298   *) ac_try_echo=$ac_try;;
16299 esac
16300 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16301   (eval "$ac_link") 2>conftest.er1
16302   ac_status=$?
16303   grep -v '^ *+' conftest.er1 >conftest.err
16304   rm -f conftest.er1
16305   cat conftest.err >&5
16306   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_exeext &&
16311        $as_test_x conftest$ac_exeext; then
16312   eval "$as_ac_var=yes"
16313 else
16314   echo "$as_me: failed program was:" >&5
16315 sed 's/^/| /' conftest.$ac_ext >&5
16316
16317         eval "$as_ac_var=no"
16318 fi
16319
16320 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16321       conftest$ac_exeext conftest.$ac_ext
16322 fi
16323 ac_res=`eval echo '${'$as_ac_var'}'`
16324                { echo "$as_me:$LINENO: result: $ac_res" >&5
16325 echo "${ECHO_T}$ac_res" >&6; }
16326 if test `eval echo '${'$as_ac_var'}'` = yes; then
16327   cat >>confdefs.h <<_ACEOF
16328 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16329 _ACEOF
16330
16331 else
16332   pgac_need_repl_snprintf=yes
16333 fi
16334 done
16335
16336 fi
16337
16338
16339 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
16340 # include/c.h will provide declarations.  Note this is a separate test
16341 # from whether the functions exist in the C library --- there are
16342 # systems that have the functions but don't bother to declare them :-(
16343
16344 { echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
16345 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6; }
16346 if test "${ac_cv_have_decl_snprintf+set}" = set; then
16347   echo $ECHO_N "(cached) $ECHO_C" >&6
16348 else
16349   cat >conftest.$ac_ext <<_ACEOF
16350 /* confdefs.h.  */
16351 _ACEOF
16352 cat confdefs.h >>conftest.$ac_ext
16353 cat >>conftest.$ac_ext <<_ACEOF
16354 /* end confdefs.h.  */
16355 $ac_includes_default
16356 int
16357 main ()
16358 {
16359 #ifndef snprintf
16360   (void) snprintf;
16361 #endif
16362
16363   ;
16364   return 0;
16365 }
16366 _ACEOF
16367 rm -f conftest.$ac_objext
16368 if { (ac_try="$ac_compile"
16369 case "(($ac_try" in
16370   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16371   *) ac_try_echo=$ac_try;;
16372 esac
16373 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16374   (eval "$ac_compile") 2>conftest.er1
16375   ac_status=$?
16376   grep -v '^ *+' conftest.er1 >conftest.err
16377   rm -f conftest.er1
16378   cat conftest.err >&5
16379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16380   (exit $ac_status); } && {
16381          test -z "$ac_c_werror_flag" ||
16382          test ! -s conftest.err
16383        } && test -s conftest.$ac_objext; then
16384   ac_cv_have_decl_snprintf=yes
16385 else
16386   echo "$as_me: failed program was:" >&5
16387 sed 's/^/| /' conftest.$ac_ext >&5
16388
16389         ac_cv_have_decl_snprintf=no
16390 fi
16391
16392 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16393 fi
16394 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
16395 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6; }
16396 if test $ac_cv_have_decl_snprintf = yes; then
16397
16398 cat >>confdefs.h <<_ACEOF
16399 #define HAVE_DECL_SNPRINTF 1
16400 _ACEOF
16401
16402
16403 else
16404   cat >>confdefs.h <<_ACEOF
16405 #define HAVE_DECL_SNPRINTF 0
16406 _ACEOF
16407
16408
16409 fi
16410 { echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
16411 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6; }
16412 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
16413   echo $ECHO_N "(cached) $ECHO_C" >&6
16414 else
16415   cat >conftest.$ac_ext <<_ACEOF
16416 /* confdefs.h.  */
16417 _ACEOF
16418 cat confdefs.h >>conftest.$ac_ext
16419 cat >>conftest.$ac_ext <<_ACEOF
16420 /* end confdefs.h.  */
16421 $ac_includes_default
16422 int
16423 main ()
16424 {
16425 #ifndef vsnprintf
16426   (void) vsnprintf;
16427 #endif
16428
16429   ;
16430   return 0;
16431 }
16432 _ACEOF
16433 rm -f conftest.$ac_objext
16434 if { (ac_try="$ac_compile"
16435 case "(($ac_try" in
16436   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16437   *) ac_try_echo=$ac_try;;
16438 esac
16439 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16440   (eval "$ac_compile") 2>conftest.er1
16441   ac_status=$?
16442   grep -v '^ *+' conftest.er1 >conftest.err
16443   rm -f conftest.er1
16444   cat conftest.err >&5
16445   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16446   (exit $ac_status); } && {
16447          test -z "$ac_c_werror_flag" ||
16448          test ! -s conftest.err
16449        } && test -s conftest.$ac_objext; then
16450   ac_cv_have_decl_vsnprintf=yes
16451 else
16452   echo "$as_me: failed program was:" >&5
16453 sed 's/^/| /' conftest.$ac_ext >&5
16454
16455         ac_cv_have_decl_vsnprintf=no
16456 fi
16457
16458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16459 fi
16460 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
16461 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6; }
16462 if test $ac_cv_have_decl_vsnprintf = yes; then
16463
16464 cat >>confdefs.h <<_ACEOF
16465 #define HAVE_DECL_VSNPRINTF 1
16466 _ACEOF
16467
16468
16469 else
16470   cat >>confdefs.h <<_ACEOF
16471 #define HAVE_DECL_VSNPRINTF 0
16472 _ACEOF
16473
16474
16475 fi
16476
16477
16478
16479
16480 { echo "$as_me:$LINENO: checking for isinf" >&5
16481 echo $ECHO_N "checking for isinf... $ECHO_C" >&6; }
16482 if test "${ac_cv_func_isinf+set}" = set; then
16483   echo $ECHO_N "(cached) $ECHO_C" >&6
16484 else
16485   cat >conftest.$ac_ext <<_ACEOF
16486 /* confdefs.h.  */
16487 _ACEOF
16488 cat confdefs.h >>conftest.$ac_ext
16489 cat >>conftest.$ac_ext <<_ACEOF
16490 /* end confdefs.h.  */
16491
16492 #include <math.h>
16493 double glob_double;
16494
16495 int
16496 main ()
16497 {
16498 return isinf(glob_double) ? 0 : 1;
16499   ;
16500   return 0;
16501 }
16502 _ACEOF
16503 rm -f conftest.$ac_objext conftest$ac_exeext
16504 if { (ac_try="$ac_link"
16505 case "(($ac_try" in
16506   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16507   *) ac_try_echo=$ac_try;;
16508 esac
16509 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16510   (eval "$ac_link") 2>conftest.er1
16511   ac_status=$?
16512   grep -v '^ *+' conftest.er1 >conftest.err
16513   rm -f conftest.er1
16514   cat conftest.err >&5
16515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16516   (exit $ac_status); } && {
16517          test -z "$ac_c_werror_flag" ||
16518          test ! -s conftest.err
16519        } && test -s conftest$ac_exeext &&
16520        $as_test_x conftest$ac_exeext; then
16521   ac_cv_func_isinf=yes
16522 else
16523   echo "$as_me: failed program was:" >&5
16524 sed 's/^/| /' conftest.$ac_ext >&5
16525
16526         ac_cv_func_isinf=no
16527 fi
16528
16529 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16530       conftest$ac_exeext conftest.$ac_ext
16531 fi
16532 { echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
16533 echo "${ECHO_T}$ac_cv_func_isinf" >&6; }
16534
16535 if test $ac_cv_func_isinf = yes ; then
16536
16537 cat >>confdefs.h <<\_ACEOF
16538 #define HAVE_ISINF 1
16539 _ACEOF
16540
16541 else
16542   case " $LIBOBJS " in
16543   *" isinf.$ac_objext "* ) ;;
16544   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
16545  ;;
16546 esac
16547
16548   # Look for a way to implement a substitute for isinf()
16549
16550
16551
16552
16553 for ac_func in fpclass fp_class fp_class_d class
16554 do
16555 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16556 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16557 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16558 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16559   echo $ECHO_N "(cached) $ECHO_C" >&6
16560 else
16561   cat >conftest.$ac_ext <<_ACEOF
16562 /* confdefs.h.  */
16563 _ACEOF
16564 cat confdefs.h >>conftest.$ac_ext
16565 cat >>conftest.$ac_ext <<_ACEOF
16566 /* end confdefs.h.  */
16567 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16568    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16569 #define $ac_func innocuous_$ac_func
16570
16571 /* System header to define __stub macros and hopefully few prototypes,
16572     which can conflict with char $ac_func (); below.
16573     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16574     <limits.h> exists even on freestanding compilers.  */
16575
16576 #ifdef __STDC__
16577 # include <limits.h>
16578 #else
16579 # include <assert.h>
16580 #endif
16581
16582 #undef $ac_func
16583
16584 /* Override any GCC internal prototype to avoid an error.
16585    Use char because int might match the return type of a GCC
16586    builtin and then its argument prototype would still apply.  */
16587 #ifdef __cplusplus
16588 extern "C"
16589 #endif
16590 char $ac_func ();
16591 /* The GNU C library defines this for functions which it implements
16592     to always fail with ENOSYS.  Some functions are actually named
16593     something starting with __ and the normal name is an alias.  */
16594 #if defined __stub_$ac_func || defined __stub___$ac_func
16595 choke me
16596 #endif
16597
16598 int
16599 main ()
16600 {
16601 return $ac_func ();
16602   ;
16603   return 0;
16604 }
16605 _ACEOF
16606 rm -f conftest.$ac_objext conftest$ac_exeext
16607 if { (ac_try="$ac_link"
16608 case "(($ac_try" in
16609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16610   *) ac_try_echo=$ac_try;;
16611 esac
16612 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16613   (eval "$ac_link") 2>conftest.er1
16614   ac_status=$?
16615   grep -v '^ *+' conftest.er1 >conftest.err
16616   rm -f conftest.er1
16617   cat conftest.err >&5
16618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16619   (exit $ac_status); } && {
16620          test -z "$ac_c_werror_flag" ||
16621          test ! -s conftest.err
16622        } && test -s conftest$ac_exeext &&
16623        $as_test_x conftest$ac_exeext; then
16624   eval "$as_ac_var=yes"
16625 else
16626   echo "$as_me: failed program was:" >&5
16627 sed 's/^/| /' conftest.$ac_ext >&5
16628
16629         eval "$as_ac_var=no"
16630 fi
16631
16632 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16633       conftest$ac_exeext conftest.$ac_ext
16634 fi
16635 ac_res=`eval echo '${'$as_ac_var'}'`
16636                { echo "$as_me:$LINENO: result: $ac_res" >&5
16637 echo "${ECHO_T}$ac_res" >&6; }
16638 if test `eval echo '${'$as_ac_var'}'` = yes; then
16639   cat >>confdefs.h <<_ACEOF
16640 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16641 _ACEOF
16642  break
16643 fi
16644 done
16645
16646 fi
16647
16648 # Some versions of libedit contain strlcpy(); so disregard that library while
16649 # checking for these standard libc functions.
16650 pgac_save_LIBS="$LIBS"
16651 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
16652
16653
16654
16655
16656
16657
16658
16659
16660
16661
16662
16663
16664
16665
16666
16667 for ac_func in crypt getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul unsetenv
16668 do
16669 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16670 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16671 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16672 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16673   echo $ECHO_N "(cached) $ECHO_C" >&6
16674 else
16675   cat >conftest.$ac_ext <<_ACEOF
16676 /* confdefs.h.  */
16677 _ACEOF
16678 cat confdefs.h >>conftest.$ac_ext
16679 cat >>conftest.$ac_ext <<_ACEOF
16680 /* end confdefs.h.  */
16681 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16682    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16683 #define $ac_func innocuous_$ac_func
16684
16685 /* System header to define __stub macros and hopefully few prototypes,
16686     which can conflict with char $ac_func (); below.
16687     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16688     <limits.h> exists even on freestanding compilers.  */
16689
16690 #ifdef __STDC__
16691 # include <limits.h>
16692 #else
16693 # include <assert.h>
16694 #endif
16695
16696 #undef $ac_func
16697
16698 /* Override any GCC internal prototype to avoid an error.
16699    Use char because int might match the return type of a GCC
16700    builtin and then its argument prototype would still apply.  */
16701 #ifdef __cplusplus
16702 extern "C"
16703 #endif
16704 char $ac_func ();
16705 /* The GNU C library defines this for functions which it implements
16706     to always fail with ENOSYS.  Some functions are actually named
16707     something starting with __ and the normal name is an alias.  */
16708 #if defined __stub_$ac_func || defined __stub___$ac_func
16709 choke me
16710 #endif
16711
16712 int
16713 main ()
16714 {
16715 return $ac_func ();
16716   ;
16717   return 0;
16718 }
16719 _ACEOF
16720 rm -f conftest.$ac_objext conftest$ac_exeext
16721 if { (ac_try="$ac_link"
16722 case "(($ac_try" in
16723   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16724   *) ac_try_echo=$ac_try;;
16725 esac
16726 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16727   (eval "$ac_link") 2>conftest.er1
16728   ac_status=$?
16729   grep -v '^ *+' conftest.er1 >conftest.err
16730   rm -f conftest.er1
16731   cat conftest.err >&5
16732   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16733   (exit $ac_status); } && {
16734          test -z "$ac_c_werror_flag" ||
16735          test ! -s conftest.err
16736        } && test -s conftest$ac_exeext &&
16737        $as_test_x conftest$ac_exeext; then
16738   eval "$as_ac_var=yes"
16739 else
16740   echo "$as_me: failed program was:" >&5
16741 sed 's/^/| /' conftest.$ac_ext >&5
16742
16743         eval "$as_ac_var=no"
16744 fi
16745
16746 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16747       conftest$ac_exeext conftest.$ac_ext
16748 fi
16749 ac_res=`eval echo '${'$as_ac_var'}'`
16750                { echo "$as_me:$LINENO: result: $ac_res" >&5
16751 echo "${ECHO_T}$ac_res" >&6; }
16752 if test `eval echo '${'$as_ac_var'}'` = yes; then
16753   cat >>confdefs.h <<_ACEOF
16754 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16755 _ACEOF
16756
16757 else
16758   case " $LIBOBJS " in
16759   *" $ac_func.$ac_objext "* ) ;;
16760   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
16761  ;;
16762 esac
16763
16764 fi
16765 done
16766
16767
16768
16769 LIBS="$pgac_save_LIBS"
16770
16771 # System's version of getaddrinfo(), if any, may be used only if we found
16772 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
16773 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
16774 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
16775 # because we want to use our own getaddrinfo.c on Windows anyway.)
16776 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
16777
16778 for ac_func in getaddrinfo
16779 do
16780 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16781 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16782 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16783 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16784   echo $ECHO_N "(cached) $ECHO_C" >&6
16785 else
16786   cat >conftest.$ac_ext <<_ACEOF
16787 /* confdefs.h.  */
16788 _ACEOF
16789 cat confdefs.h >>conftest.$ac_ext
16790 cat >>conftest.$ac_ext <<_ACEOF
16791 /* end confdefs.h.  */
16792 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16793    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16794 #define $ac_func innocuous_$ac_func
16795
16796 /* System header to define __stub macros and hopefully few prototypes,
16797     which can conflict with char $ac_func (); below.
16798     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16799     <limits.h> exists even on freestanding compilers.  */
16800
16801 #ifdef __STDC__
16802 # include <limits.h>
16803 #else
16804 # include <assert.h>
16805 #endif
16806
16807 #undef $ac_func
16808
16809 /* Override any GCC internal prototype to avoid an error.
16810    Use char because int might match the return type of a GCC
16811    builtin and then its argument prototype would still apply.  */
16812 #ifdef __cplusplus
16813 extern "C"
16814 #endif
16815 char $ac_func ();
16816 /* The GNU C library defines this for functions which it implements
16817     to always fail with ENOSYS.  Some functions are actually named
16818     something starting with __ and the normal name is an alias.  */
16819 #if defined __stub_$ac_func || defined __stub___$ac_func
16820 choke me
16821 #endif
16822
16823 int
16824 main ()
16825 {
16826 return $ac_func ();
16827   ;
16828   return 0;
16829 }
16830 _ACEOF
16831 rm -f conftest.$ac_objext conftest$ac_exeext
16832 if { (ac_try="$ac_link"
16833 case "(($ac_try" in
16834   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16835   *) ac_try_echo=$ac_try;;
16836 esac
16837 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16838   (eval "$ac_link") 2>conftest.er1
16839   ac_status=$?
16840   grep -v '^ *+' conftest.er1 >conftest.err
16841   rm -f conftest.er1
16842   cat conftest.err >&5
16843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16844   (exit $ac_status); } && {
16845          test -z "$ac_c_werror_flag" ||
16846          test ! -s conftest.err
16847        } && test -s conftest$ac_exeext &&
16848        $as_test_x conftest$ac_exeext; then
16849   eval "$as_ac_var=yes"
16850 else
16851   echo "$as_me: failed program was:" >&5
16852 sed 's/^/| /' conftest.$ac_ext >&5
16853
16854         eval "$as_ac_var=no"
16855 fi
16856
16857 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16858       conftest$ac_exeext conftest.$ac_ext
16859 fi
16860 ac_res=`eval echo '${'$as_ac_var'}'`
16861                { echo "$as_me:$LINENO: result: $ac_res" >&5
16862 echo "${ECHO_T}$ac_res" >&6; }
16863 if test `eval echo '${'$as_ac_var'}'` = yes; then
16864   cat >>confdefs.h <<_ACEOF
16865 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16866 _ACEOF
16867
16868 else
16869   case " $LIBOBJS " in
16870   *" $ac_func.$ac_objext "* ) ;;
16871   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
16872  ;;
16873 esac
16874
16875 fi
16876 done
16877
16878
16879 else
16880   case " $LIBOBJS " in
16881   *" getaddrinfo.$ac_objext "* ) ;;
16882   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
16883  ;;
16884 esac
16885
16886 fi
16887
16888 # Similarly, use system's getopt_long() only if system provides struct option.
16889 # Solaris' getopt() doesn't do what we want for long options, so always use
16890 # our versions on that platform.
16891 if test "$PORTNAME" = "solaris"; then
16892   case " $LIBOBJS " in
16893   *" getopt.$ac_objext "* ) ;;
16894   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
16895  ;;
16896 esac
16897
16898   case " $LIBOBJS " in
16899   *" getopt_long.$ac_objext "* ) ;;
16900   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
16901  ;;
16902 esac
16903
16904 elif test x"$ac_cv_type_struct_option" = xyes ; then
16905
16906 for ac_func in getopt_long
16907 do
16908 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16909 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16910 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16911 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16912   echo $ECHO_N "(cached) $ECHO_C" >&6
16913 else
16914   cat >conftest.$ac_ext <<_ACEOF
16915 /* confdefs.h.  */
16916 _ACEOF
16917 cat confdefs.h >>conftest.$ac_ext
16918 cat >>conftest.$ac_ext <<_ACEOF
16919 /* end confdefs.h.  */
16920 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16921    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16922 #define $ac_func innocuous_$ac_func
16923
16924 /* System header to define __stub macros and hopefully few prototypes,
16925     which can conflict with char $ac_func (); below.
16926     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16927     <limits.h> exists even on freestanding compilers.  */
16928
16929 #ifdef __STDC__
16930 # include <limits.h>
16931 #else
16932 # include <assert.h>
16933 #endif
16934
16935 #undef $ac_func
16936
16937 /* Override any GCC internal prototype to avoid an error.
16938    Use char because int might match the return type of a GCC
16939    builtin and then its argument prototype would still apply.  */
16940 #ifdef __cplusplus
16941 extern "C"
16942 #endif
16943 char $ac_func ();
16944 /* The GNU C library defines this for functions which it implements
16945     to always fail with ENOSYS.  Some functions are actually named
16946     something starting with __ and the normal name is an alias.  */
16947 #if defined __stub_$ac_func || defined __stub___$ac_func
16948 choke me
16949 #endif
16950
16951 int
16952 main ()
16953 {
16954 return $ac_func ();
16955   ;
16956   return 0;
16957 }
16958 _ACEOF
16959 rm -f conftest.$ac_objext conftest$ac_exeext
16960 if { (ac_try="$ac_link"
16961 case "(($ac_try" in
16962   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16963   *) ac_try_echo=$ac_try;;
16964 esac
16965 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16966   (eval "$ac_link") 2>conftest.er1
16967   ac_status=$?
16968   grep -v '^ *+' conftest.er1 >conftest.err
16969   rm -f conftest.er1
16970   cat conftest.err >&5
16971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16972   (exit $ac_status); } && {
16973          test -z "$ac_c_werror_flag" ||
16974          test ! -s conftest.err
16975        } && test -s conftest$ac_exeext &&
16976        $as_test_x conftest$ac_exeext; then
16977   eval "$as_ac_var=yes"
16978 else
16979   echo "$as_me: failed program was:" >&5
16980 sed 's/^/| /' conftest.$ac_ext >&5
16981
16982         eval "$as_ac_var=no"
16983 fi
16984
16985 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16986       conftest$ac_exeext conftest.$ac_ext
16987 fi
16988 ac_res=`eval echo '${'$as_ac_var'}'`
16989                { echo "$as_me:$LINENO: result: $ac_res" >&5
16990 echo "${ECHO_T}$ac_res" >&6; }
16991 if test `eval echo '${'$as_ac_var'}'` = yes; then
16992   cat >>confdefs.h <<_ACEOF
16993 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16994 _ACEOF
16995
16996 else
16997   case " $LIBOBJS " in
16998   *" $ac_func.$ac_objext "* ) ;;
16999   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
17000  ;;
17001 esac
17002
17003 fi
17004 done
17005
17006
17007 else
17008   case " $LIBOBJS " in
17009   *" getopt_long.$ac_objext "* ) ;;
17010   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
17011  ;;
17012 esac
17013
17014 fi
17015
17016 # Win32 support
17017 if test "$PORTNAME" = "win32"; then
17018
17019 for ac_func in gettimeofday
17020 do
17021 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17022 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17023 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17024 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17025   echo $ECHO_N "(cached) $ECHO_C" >&6
17026 else
17027   cat >conftest.$ac_ext <<_ACEOF
17028 /* confdefs.h.  */
17029 _ACEOF
17030 cat confdefs.h >>conftest.$ac_ext
17031 cat >>conftest.$ac_ext <<_ACEOF
17032 /* end confdefs.h.  */
17033 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17034    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17035 #define $ac_func innocuous_$ac_func
17036
17037 /* System header to define __stub macros and hopefully few prototypes,
17038     which can conflict with char $ac_func (); below.
17039     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17040     <limits.h> exists even on freestanding compilers.  */
17041
17042 #ifdef __STDC__
17043 # include <limits.h>
17044 #else
17045 # include <assert.h>
17046 #endif
17047
17048 #undef $ac_func
17049
17050 /* Override any GCC internal prototype to avoid an error.
17051    Use char because int might match the return type of a GCC
17052    builtin and then its argument prototype would still apply.  */
17053 #ifdef __cplusplus
17054 extern "C"
17055 #endif
17056 char $ac_func ();
17057 /* The GNU C library defines this for functions which it implements
17058     to always fail with ENOSYS.  Some functions are actually named
17059     something starting with __ and the normal name is an alias.  */
17060 #if defined __stub_$ac_func || defined __stub___$ac_func
17061 choke me
17062 #endif
17063
17064 int
17065 main ()
17066 {
17067 return $ac_func ();
17068   ;
17069   return 0;
17070 }
17071 _ACEOF
17072 rm -f conftest.$ac_objext conftest$ac_exeext
17073 if { (ac_try="$ac_link"
17074 case "(($ac_try" in
17075   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17076   *) ac_try_echo=$ac_try;;
17077 esac
17078 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17079   (eval "$ac_link") 2>conftest.er1
17080   ac_status=$?
17081   grep -v '^ *+' conftest.er1 >conftest.err
17082   rm -f conftest.er1
17083   cat conftest.err >&5
17084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17085   (exit $ac_status); } && {
17086          test -z "$ac_c_werror_flag" ||
17087          test ! -s conftest.err
17088        } && test -s conftest$ac_exeext &&
17089        $as_test_x conftest$ac_exeext; then
17090   eval "$as_ac_var=yes"
17091 else
17092   echo "$as_me: failed program was:" >&5
17093 sed 's/^/| /' conftest.$ac_ext >&5
17094
17095         eval "$as_ac_var=no"
17096 fi
17097
17098 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17099       conftest$ac_exeext conftest.$ac_ext
17100 fi
17101 ac_res=`eval echo '${'$as_ac_var'}'`
17102                { echo "$as_me:$LINENO: result: $ac_res" >&5
17103 echo "${ECHO_T}$ac_res" >&6; }
17104 if test `eval echo '${'$as_ac_var'}'` = yes; then
17105   cat >>confdefs.h <<_ACEOF
17106 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17107 _ACEOF
17108
17109 else
17110   case " $LIBOBJS " in
17111   *" $ac_func.$ac_objext "* ) ;;
17112   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
17113  ;;
17114 esac
17115
17116 fi
17117 done
17118
17119
17120 case " $LIBOBJS " in
17121   *" kill.$ac_objext "* ) ;;
17122   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
17123  ;;
17124 esac
17125
17126 case " $LIBOBJS " in
17127   *" open.$ac_objext "* ) ;;
17128   *) LIBOBJS="$LIBOBJS open.$ac_objext"
17129  ;;
17130 esac
17131
17132 case " $LIBOBJS " in
17133   *" rand.$ac_objext "* ) ;;
17134   *) LIBOBJS="$LIBOBJS rand.$ac_objext"
17135  ;;
17136 esac
17137
17138 case " $LIBOBJS " in
17139   *" win32error.$ac_objext "* ) ;;
17140   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
17141  ;;
17142 esac
17143
17144
17145 cat >>confdefs.h <<\_ACEOF
17146 #define HAVE_SYMLINK 1
17147 _ACEOF
17148
17149 fi
17150
17151 if test "$with_readline" = yes; then
17152   { echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
17153 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6; }
17154 cat >conftest.$ac_ext <<_ACEOF
17155 /* confdefs.h.  */
17156 _ACEOF
17157 cat confdefs.h >>conftest.$ac_ext
17158 cat >>conftest.$ac_ext <<_ACEOF
17159 /* end confdefs.h.  */
17160 #include <stdio.h>
17161 #ifdef HAVE_READLINE_READLINE_H
17162 # include <readline/readline.h>
17163 #elif defined(HAVE_READLINE_H)
17164 # include <readline.h>
17165 #endif
17166
17167 int
17168 main ()
17169 {
17170 rl_completion_append_character = 'x';
17171   ;
17172   return 0;
17173 }
17174 _ACEOF
17175 rm -f conftest.$ac_objext conftest$ac_exeext
17176 if { (ac_try="$ac_link"
17177 case "(($ac_try" in
17178   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17179   *) ac_try_echo=$ac_try;;
17180 esac
17181 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17182   (eval "$ac_link") 2>conftest.er1
17183   ac_status=$?
17184   grep -v '^ *+' conftest.er1 >conftest.err
17185   rm -f conftest.er1
17186   cat conftest.err >&5
17187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17188   (exit $ac_status); } && {
17189          test -z "$ac_c_werror_flag" ||
17190          test ! -s conftest.err
17191        } && test -s conftest$ac_exeext &&
17192        $as_test_x conftest$ac_exeext; then
17193   { echo "$as_me:$LINENO: result: yes" >&5
17194 echo "${ECHO_T}yes" >&6; }
17195
17196 cat >>confdefs.h <<\_ACEOF
17197 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
17198 _ACEOF
17199
17200 else
17201   echo "$as_me: failed program was:" >&5
17202 sed 's/^/| /' conftest.$ac_ext >&5
17203
17204         { echo "$as_me:$LINENO: result: no" >&5
17205 echo "${ECHO_T}no" >&6; }
17206 fi
17207
17208 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17209       conftest$ac_exeext conftest.$ac_ext
17210
17211
17212 for ac_func in rl_completion_matches rl_filename_completion_function
17213 do
17214 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17215 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17216 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17217 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17218   echo $ECHO_N "(cached) $ECHO_C" >&6
17219 else
17220   cat >conftest.$ac_ext <<_ACEOF
17221 /* confdefs.h.  */
17222 _ACEOF
17223 cat confdefs.h >>conftest.$ac_ext
17224 cat >>conftest.$ac_ext <<_ACEOF
17225 /* end confdefs.h.  */
17226 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17227    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17228 #define $ac_func innocuous_$ac_func
17229
17230 /* System header to define __stub macros and hopefully few prototypes,
17231     which can conflict with char $ac_func (); below.
17232     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17233     <limits.h> exists even on freestanding compilers.  */
17234
17235 #ifdef __STDC__
17236 # include <limits.h>
17237 #else
17238 # include <assert.h>
17239 #endif
17240
17241 #undef $ac_func
17242
17243 /* Override any GCC internal prototype to avoid an error.
17244    Use char because int might match the return type of a GCC
17245    builtin and then its argument prototype would still apply.  */
17246 #ifdef __cplusplus
17247 extern "C"
17248 #endif
17249 char $ac_func ();
17250 /* The GNU C library defines this for functions which it implements
17251     to always fail with ENOSYS.  Some functions are actually named
17252     something starting with __ and the normal name is an alias.  */
17253 #if defined __stub_$ac_func || defined __stub___$ac_func
17254 choke me
17255 #endif
17256
17257 int
17258 main ()
17259 {
17260 return $ac_func ();
17261   ;
17262   return 0;
17263 }
17264 _ACEOF
17265 rm -f conftest.$ac_objext conftest$ac_exeext
17266 if { (ac_try="$ac_link"
17267 case "(($ac_try" in
17268   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17269   *) ac_try_echo=$ac_try;;
17270 esac
17271 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17272   (eval "$ac_link") 2>conftest.er1
17273   ac_status=$?
17274   grep -v '^ *+' conftest.er1 >conftest.err
17275   rm -f conftest.er1
17276   cat conftest.err >&5
17277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17278   (exit $ac_status); } && {
17279          test -z "$ac_c_werror_flag" ||
17280          test ! -s conftest.err
17281        } && test -s conftest$ac_exeext &&
17282        $as_test_x conftest$ac_exeext; then
17283   eval "$as_ac_var=yes"
17284 else
17285   echo "$as_me: failed program was:" >&5
17286 sed 's/^/| /' conftest.$ac_ext >&5
17287
17288         eval "$as_ac_var=no"
17289 fi
17290
17291 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17292       conftest$ac_exeext conftest.$ac_ext
17293 fi
17294 ac_res=`eval echo '${'$as_ac_var'}'`
17295                { echo "$as_me:$LINENO: result: $ac_res" >&5
17296 echo "${ECHO_T}$ac_res" >&6; }
17297 if test `eval echo '${'$as_ac_var'}'` = yes; then
17298   cat >>confdefs.h <<_ACEOF
17299 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17300 _ACEOF
17301
17302 fi
17303 done
17304
17305
17306 for ac_func in replace_history_entry
17307 do
17308 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17309 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17310 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17311 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17312   echo $ECHO_N "(cached) $ECHO_C" >&6
17313 else
17314   cat >conftest.$ac_ext <<_ACEOF
17315 /* confdefs.h.  */
17316 _ACEOF
17317 cat confdefs.h >>conftest.$ac_ext
17318 cat >>conftest.$ac_ext <<_ACEOF
17319 /* end confdefs.h.  */
17320 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17321    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17322 #define $ac_func innocuous_$ac_func
17323
17324 /* System header to define __stub macros and hopefully few prototypes,
17325     which can conflict with char $ac_func (); below.
17326     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17327     <limits.h> exists even on freestanding compilers.  */
17328
17329 #ifdef __STDC__
17330 # include <limits.h>
17331 #else
17332 # include <assert.h>
17333 #endif
17334
17335 #undef $ac_func
17336
17337 /* Override any GCC internal prototype to avoid an error.
17338    Use char because int might match the return type of a GCC
17339    builtin and then its argument prototype would still apply.  */
17340 #ifdef __cplusplus
17341 extern "C"
17342 #endif
17343 char $ac_func ();
17344 /* The GNU C library defines this for functions which it implements
17345     to always fail with ENOSYS.  Some functions are actually named
17346     something starting with __ and the normal name is an alias.  */
17347 #if defined __stub_$ac_func || defined __stub___$ac_func
17348 choke me
17349 #endif
17350
17351 int
17352 main ()
17353 {
17354 return $ac_func ();
17355   ;
17356   return 0;
17357 }
17358 _ACEOF
17359 rm -f conftest.$ac_objext conftest$ac_exeext
17360 if { (ac_try="$ac_link"
17361 case "(($ac_try" in
17362   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17363   *) ac_try_echo=$ac_try;;
17364 esac
17365 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17366   (eval "$ac_link") 2>conftest.er1
17367   ac_status=$?
17368   grep -v '^ *+' conftest.er1 >conftest.err
17369   rm -f conftest.er1
17370   cat conftest.err >&5
17371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17372   (exit $ac_status); } && {
17373          test -z "$ac_c_werror_flag" ||
17374          test ! -s conftest.err
17375        } && test -s conftest$ac_exeext &&
17376        $as_test_x conftest$ac_exeext; then
17377   eval "$as_ac_var=yes"
17378 else
17379   echo "$as_me: failed program was:" >&5
17380 sed 's/^/| /' conftest.$ac_ext >&5
17381
17382         eval "$as_ac_var=no"
17383 fi
17384
17385 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17386       conftest$ac_exeext conftest.$ac_ext
17387 fi
17388 ac_res=`eval echo '${'$as_ac_var'}'`
17389                { echo "$as_me:$LINENO: result: $ac_res" >&5
17390 echo "${ECHO_T}$ac_res" >&6; }
17391 if test `eval echo '${'$as_ac_var'}'` = yes; then
17392   cat >>confdefs.h <<_ACEOF
17393 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17394 _ACEOF
17395
17396 fi
17397 done
17398
17399 fi
17400
17401
17402 { echo "$as_me:$LINENO: checking for sigsetjmp" >&5
17403 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6; }
17404 cat >conftest.$ac_ext <<_ACEOF
17405 /* confdefs.h.  */
17406 _ACEOF
17407 cat confdefs.h >>conftest.$ac_ext
17408 cat >>conftest.$ac_ext <<_ACEOF
17409 /* end confdefs.h.  */
17410 #include <setjmp.h>
17411 int
17412 main ()
17413 {
17414 sigjmp_buf x; sigsetjmp(x, 1);
17415   ;
17416   return 0;
17417 }
17418 _ACEOF
17419 rm -f conftest.$ac_objext conftest$ac_exeext
17420 if { (ac_try="$ac_link"
17421 case "(($ac_try" in
17422   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17423   *) ac_try_echo=$ac_try;;
17424 esac
17425 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17426   (eval "$ac_link") 2>conftest.er1
17427   ac_status=$?
17428   grep -v '^ *+' conftest.er1 >conftest.err
17429   rm -f conftest.er1
17430   cat conftest.err >&5
17431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17432   (exit $ac_status); } && {
17433          test -z "$ac_c_werror_flag" ||
17434          test ! -s conftest.err
17435        } && test -s conftest$ac_exeext &&
17436        $as_test_x conftest$ac_exeext; then
17437
17438 cat >>confdefs.h <<\_ACEOF
17439 #define HAVE_SIGSETJMP 1
17440 _ACEOF
17441
17442 { echo "$as_me:$LINENO: result: yes" >&5
17443 echo "${ECHO_T}yes" >&6; }
17444 else
17445   echo "$as_me: failed program was:" >&5
17446 sed 's/^/| /' conftest.$ac_ext >&5
17447
17448         { echo "$as_me:$LINENO: result: no" >&5
17449 echo "${ECHO_T}no" >&6; }
17450 fi
17451
17452 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17453       conftest$ac_exeext conftest.$ac_ext
17454
17455 { echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
17456 echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6; }
17457 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
17458   echo $ECHO_N "(cached) $ECHO_C" >&6
17459 else
17460   cat >conftest.$ac_ext <<_ACEOF
17461 /* confdefs.h.  */
17462 _ACEOF
17463 cat confdefs.h >>conftest.$ac_ext
17464 cat >>conftest.$ac_ext <<_ACEOF
17465 /* end confdefs.h.  */
17466 #include <signal.h>
17467 /* NetBSD declares sys_siglist in unistd.h.  */
17468 #ifdef HAVE_UNISTD_H
17469 # include <unistd.h>
17470 #endif
17471
17472
17473 int
17474 main ()
17475 {
17476 #ifndef sys_siglist
17477   (void) sys_siglist;
17478 #endif
17479
17480   ;
17481   return 0;
17482 }
17483 _ACEOF
17484 rm -f conftest.$ac_objext
17485 if { (ac_try="$ac_compile"
17486 case "(($ac_try" in
17487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17488   *) ac_try_echo=$ac_try;;
17489 esac
17490 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17491   (eval "$ac_compile") 2>conftest.er1
17492   ac_status=$?
17493   grep -v '^ *+' conftest.er1 >conftest.err
17494   rm -f conftest.er1
17495   cat conftest.err >&5
17496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17497   (exit $ac_status); } && {
17498          test -z "$ac_c_werror_flag" ||
17499          test ! -s conftest.err
17500        } && test -s conftest.$ac_objext; then
17501   ac_cv_have_decl_sys_siglist=yes
17502 else
17503   echo "$as_me: failed program was:" >&5
17504 sed 's/^/| /' conftest.$ac_ext >&5
17505
17506         ac_cv_have_decl_sys_siglist=no
17507 fi
17508
17509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17510 fi
17511 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
17512 echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6; }
17513 if test $ac_cv_have_decl_sys_siglist = yes; then
17514
17515 cat >>confdefs.h <<_ACEOF
17516 #define HAVE_DECL_SYS_SIGLIST 1
17517 _ACEOF
17518
17519
17520 else
17521   cat >>confdefs.h <<_ACEOF
17522 #define HAVE_DECL_SYS_SIGLIST 0
17523 _ACEOF
17524
17525
17526 fi
17527
17528
17529
17530
17531 { echo "$as_me:$LINENO: checking for syslog" >&5
17532 echo $ECHO_N "checking for syslog... $ECHO_C" >&6; }
17533 if test "${ac_cv_func_syslog+set}" = set; then
17534   echo $ECHO_N "(cached) $ECHO_C" >&6
17535 else
17536   cat >conftest.$ac_ext <<_ACEOF
17537 /* confdefs.h.  */
17538 _ACEOF
17539 cat confdefs.h >>conftest.$ac_ext
17540 cat >>conftest.$ac_ext <<_ACEOF
17541 /* end confdefs.h.  */
17542 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
17543    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17544 #define syslog innocuous_syslog
17545
17546 /* System header to define __stub macros and hopefully few prototypes,
17547     which can conflict with char syslog (); below.
17548     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17549     <limits.h> exists even on freestanding compilers.  */
17550
17551 #ifdef __STDC__
17552 # include <limits.h>
17553 #else
17554 # include <assert.h>
17555 #endif
17556
17557 #undef syslog
17558
17559 /* Override any GCC internal prototype to avoid an error.
17560    Use char because int might match the return type of a GCC
17561    builtin and then its argument prototype would still apply.  */
17562 #ifdef __cplusplus
17563 extern "C"
17564 #endif
17565 char syslog ();
17566 /* The GNU C library defines this for functions which it implements
17567     to always fail with ENOSYS.  Some functions are actually named
17568     something starting with __ and the normal name is an alias.  */
17569 #if defined __stub_syslog || defined __stub___syslog
17570 choke me
17571 #endif
17572
17573 int
17574 main ()
17575 {
17576 return syslog ();
17577   ;
17578   return 0;
17579 }
17580 _ACEOF
17581 rm -f conftest.$ac_objext conftest$ac_exeext
17582 if { (ac_try="$ac_link"
17583 case "(($ac_try" in
17584   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17585   *) ac_try_echo=$ac_try;;
17586 esac
17587 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17588   (eval "$ac_link") 2>conftest.er1
17589   ac_status=$?
17590   grep -v '^ *+' conftest.er1 >conftest.err
17591   rm -f conftest.er1
17592   cat conftest.err >&5
17593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17594   (exit $ac_status); } && {
17595          test -z "$ac_c_werror_flag" ||
17596          test ! -s conftest.err
17597        } && test -s conftest$ac_exeext &&
17598        $as_test_x conftest$ac_exeext; then
17599   ac_cv_func_syslog=yes
17600 else
17601   echo "$as_me: failed program was:" >&5
17602 sed 's/^/| /' conftest.$ac_ext >&5
17603
17604         ac_cv_func_syslog=no
17605 fi
17606
17607 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17608       conftest$ac_exeext conftest.$ac_ext
17609 fi
17610 { echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
17611 echo "${ECHO_T}$ac_cv_func_syslog" >&6; }
17612 if test $ac_cv_func_syslog = yes; then
17613   if test "${ac_cv_header_syslog_h+set}" = set; then
17614   { echo "$as_me:$LINENO: checking for syslog.h" >&5
17615 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6; }
17616 if test "${ac_cv_header_syslog_h+set}" = set; then
17617   echo $ECHO_N "(cached) $ECHO_C" >&6
17618 fi
17619 { echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
17620 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6; }
17621 else
17622   # Is the header compilable?
17623 { echo "$as_me:$LINENO: checking syslog.h usability" >&5
17624 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6; }
17625 cat >conftest.$ac_ext <<_ACEOF
17626 /* confdefs.h.  */
17627 _ACEOF
17628 cat confdefs.h >>conftest.$ac_ext
17629 cat >>conftest.$ac_ext <<_ACEOF
17630 /* end confdefs.h.  */
17631 $ac_includes_default
17632 #include <syslog.h>
17633 _ACEOF
17634 rm -f conftest.$ac_objext
17635 if { (ac_try="$ac_compile"
17636 case "(($ac_try" in
17637   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17638   *) ac_try_echo=$ac_try;;
17639 esac
17640 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17641   (eval "$ac_compile") 2>conftest.er1
17642   ac_status=$?
17643   grep -v '^ *+' conftest.er1 >conftest.err
17644   rm -f conftest.er1
17645   cat conftest.err >&5
17646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17647   (exit $ac_status); } && {
17648          test -z "$ac_c_werror_flag" ||
17649          test ! -s conftest.err
17650        } && test -s conftest.$ac_objext; then
17651   ac_header_compiler=yes
17652 else
17653   echo "$as_me: failed program was:" >&5
17654 sed 's/^/| /' conftest.$ac_ext >&5
17655
17656         ac_header_compiler=no
17657 fi
17658
17659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17660 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17661 echo "${ECHO_T}$ac_header_compiler" >&6; }
17662
17663 # Is the header present?
17664 { echo "$as_me:$LINENO: checking syslog.h presence" >&5
17665 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6; }
17666 cat >conftest.$ac_ext <<_ACEOF
17667 /* confdefs.h.  */
17668 _ACEOF
17669 cat confdefs.h >>conftest.$ac_ext
17670 cat >>conftest.$ac_ext <<_ACEOF
17671 /* end confdefs.h.  */
17672 #include <syslog.h>
17673 _ACEOF
17674 if { (ac_try="$ac_cpp conftest.$ac_ext"
17675 case "(($ac_try" in
17676   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17677   *) ac_try_echo=$ac_try;;
17678 esac
17679 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17680   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
17681   ac_status=$?
17682   grep -v '^ *+' conftest.er1 >conftest.err
17683   rm -f conftest.er1
17684   cat conftest.err >&5
17685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17686   (exit $ac_status); } >/dev/null && {
17687          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
17688          test ! -s conftest.err
17689        }; then
17690   ac_header_preproc=yes
17691 else
17692   echo "$as_me: failed program was:" >&5
17693 sed 's/^/| /' conftest.$ac_ext >&5
17694
17695   ac_header_preproc=no
17696 fi
17697
17698 rm -f conftest.err conftest.$ac_ext
17699 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17700 echo "${ECHO_T}$ac_header_preproc" >&6; }
17701
17702 # So?  What about this header?
17703 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17704   yes:no: )
17705     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
17706 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17707     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
17708 echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
17709     ac_header_preproc=yes
17710     ;;
17711   no:yes:* )
17712     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
17713 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
17714     { echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
17715 echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
17716     { echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
17717 echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
17718     { echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
17719 echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
17720     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
17721 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
17722     { echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
17723 echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
17724     ( cat <<\_ASBOX
17725 ## ---------------------------------------- ##
17726 ## Report this to pgsql-bugs@postgresql.org ##
17727 ## ---------------------------------------- ##
17728 _ASBOX
17729      ) | sed "s/^/$as_me: WARNING:     /" >&2
17730     ;;
17731 esac
17732 { echo "$as_me:$LINENO: checking for syslog.h" >&5
17733 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6; }
17734 if test "${ac_cv_header_syslog_h+set}" = set; then
17735   echo $ECHO_N "(cached) $ECHO_C" >&6
17736 else
17737   ac_cv_header_syslog_h=$ac_header_preproc
17738 fi
17739 { echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
17740 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6; }
17741
17742 fi
17743 if test $ac_cv_header_syslog_h = yes; then
17744
17745 cat >>confdefs.h <<\_ACEOF
17746 #define HAVE_SYSLOG 1
17747 _ACEOF
17748
17749 fi
17750
17751
17752 fi
17753
17754
17755 { echo "$as_me:$LINENO: checking for optreset" >&5
17756 echo $ECHO_N "checking for optreset... $ECHO_C" >&6; }
17757 if test "${pgac_cv_var_int_optreset+set}" = set; then
17758   echo $ECHO_N "(cached) $ECHO_C" >&6
17759 else
17760   cat >conftest.$ac_ext <<_ACEOF
17761 /* confdefs.h.  */
17762 _ACEOF
17763 cat confdefs.h >>conftest.$ac_ext
17764 cat >>conftest.$ac_ext <<_ACEOF
17765 /* end confdefs.h.  */
17766 #include <unistd.h>
17767 int
17768 main ()
17769 {
17770 extern int optreset; optreset = 1;
17771   ;
17772   return 0;
17773 }
17774 _ACEOF
17775 rm -f conftest.$ac_objext conftest$ac_exeext
17776 if { (ac_try="$ac_link"
17777 case "(($ac_try" in
17778   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17779   *) ac_try_echo=$ac_try;;
17780 esac
17781 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17782   (eval "$ac_link") 2>conftest.er1
17783   ac_status=$?
17784   grep -v '^ *+' conftest.er1 >conftest.err
17785   rm -f conftest.er1
17786   cat conftest.err >&5
17787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17788   (exit $ac_status); } && {
17789          test -z "$ac_c_werror_flag" ||
17790          test ! -s conftest.err
17791        } && test -s conftest$ac_exeext &&
17792        $as_test_x conftest$ac_exeext; then
17793   pgac_cv_var_int_optreset=yes
17794 else
17795   echo "$as_me: failed program was:" >&5
17796 sed 's/^/| /' conftest.$ac_ext >&5
17797
17798         pgac_cv_var_int_optreset=no
17799 fi
17800
17801 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17802       conftest$ac_exeext conftest.$ac_ext
17803 fi
17804 { echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
17805 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6; }
17806 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
17807
17808 cat >>confdefs.h <<\_ACEOF
17809 #define HAVE_INT_OPTRESET 1
17810 _ACEOF
17811
17812 fi
17813
17814
17815
17816 for ac_func in strtoll strtoq
17817 do
17818 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17819 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17820 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17821 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17822   echo $ECHO_N "(cached) $ECHO_C" >&6
17823 else
17824   cat >conftest.$ac_ext <<_ACEOF
17825 /* confdefs.h.  */
17826 _ACEOF
17827 cat confdefs.h >>conftest.$ac_ext
17828 cat >>conftest.$ac_ext <<_ACEOF
17829 /* end confdefs.h.  */
17830 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17831    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17832 #define $ac_func innocuous_$ac_func
17833
17834 /* System header to define __stub macros and hopefully few prototypes,
17835     which can conflict with char $ac_func (); below.
17836     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17837     <limits.h> exists even on freestanding compilers.  */
17838
17839 #ifdef __STDC__
17840 # include <limits.h>
17841 #else
17842 # include <assert.h>
17843 #endif
17844
17845 #undef $ac_func
17846
17847 /* Override any GCC internal prototype to avoid an error.
17848    Use char because int might match the return type of a GCC
17849    builtin and then its argument prototype would still apply.  */
17850 #ifdef __cplusplus
17851 extern "C"
17852 #endif
17853 char $ac_func ();
17854 /* The GNU C library defines this for functions which it implements
17855     to always fail with ENOSYS.  Some functions are actually named
17856     something starting with __ and the normal name is an alias.  */
17857 #if defined __stub_$ac_func || defined __stub___$ac_func
17858 choke me
17859 #endif
17860
17861 int
17862 main ()
17863 {
17864 return $ac_func ();
17865   ;
17866   return 0;
17867 }
17868 _ACEOF
17869 rm -f conftest.$ac_objext conftest$ac_exeext
17870 if { (ac_try="$ac_link"
17871 case "(($ac_try" in
17872   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17873   *) ac_try_echo=$ac_try;;
17874 esac
17875 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17876   (eval "$ac_link") 2>conftest.er1
17877   ac_status=$?
17878   grep -v '^ *+' conftest.er1 >conftest.err
17879   rm -f conftest.er1
17880   cat conftest.err >&5
17881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17882   (exit $ac_status); } && {
17883          test -z "$ac_c_werror_flag" ||
17884          test ! -s conftest.err
17885        } && test -s conftest$ac_exeext &&
17886        $as_test_x conftest$ac_exeext; then
17887   eval "$as_ac_var=yes"
17888 else
17889   echo "$as_me: failed program was:" >&5
17890 sed 's/^/| /' conftest.$ac_ext >&5
17891
17892         eval "$as_ac_var=no"
17893 fi
17894
17895 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17896       conftest$ac_exeext conftest.$ac_ext
17897 fi
17898 ac_res=`eval echo '${'$as_ac_var'}'`
17899                { echo "$as_me:$LINENO: result: $ac_res" >&5
17900 echo "${ECHO_T}$ac_res" >&6; }
17901 if test `eval echo '${'$as_ac_var'}'` = yes; then
17902   cat >>confdefs.h <<_ACEOF
17903 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17904 _ACEOF
17905  break
17906 fi
17907 done
17908
17909
17910
17911 for ac_func in strtoull strtouq
17912 do
17913 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17914 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17915 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17916 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17917   echo $ECHO_N "(cached) $ECHO_C" >&6
17918 else
17919   cat >conftest.$ac_ext <<_ACEOF
17920 /* confdefs.h.  */
17921 _ACEOF
17922 cat confdefs.h >>conftest.$ac_ext
17923 cat >>conftest.$ac_ext <<_ACEOF
17924 /* end confdefs.h.  */
17925 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17926    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17927 #define $ac_func innocuous_$ac_func
17928
17929 /* System header to define __stub macros and hopefully few prototypes,
17930     which can conflict with char $ac_func (); below.
17931     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17932     <limits.h> exists even on freestanding compilers.  */
17933
17934 #ifdef __STDC__
17935 # include <limits.h>
17936 #else
17937 # include <assert.h>
17938 #endif
17939
17940 #undef $ac_func
17941
17942 /* Override any GCC internal prototype to avoid an error.
17943    Use char because int might match the return type of a GCC
17944    builtin and then its argument prototype would still apply.  */
17945 #ifdef __cplusplus
17946 extern "C"
17947 #endif
17948 char $ac_func ();
17949 /* The GNU C library defines this for functions which it implements
17950     to always fail with ENOSYS.  Some functions are actually named
17951     something starting with __ and the normal name is an alias.  */
17952 #if defined __stub_$ac_func || defined __stub___$ac_func
17953 choke me
17954 #endif
17955
17956 int
17957 main ()
17958 {
17959 return $ac_func ();
17960   ;
17961   return 0;
17962 }
17963 _ACEOF
17964 rm -f conftest.$ac_objext conftest$ac_exeext
17965 if { (ac_try="$ac_link"
17966 case "(($ac_try" in
17967   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17968   *) ac_try_echo=$ac_try;;
17969 esac
17970 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17971   (eval "$ac_link") 2>conftest.er1
17972   ac_status=$?
17973   grep -v '^ *+' conftest.er1 >conftest.err
17974   rm -f conftest.er1
17975   cat conftest.err >&5
17976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17977   (exit $ac_status); } && {
17978          test -z "$ac_c_werror_flag" ||
17979          test ! -s conftest.err
17980        } && test -s conftest$ac_exeext &&
17981        $as_test_x conftest$ac_exeext; then
17982   eval "$as_ac_var=yes"
17983 else
17984   echo "$as_me: failed program was:" >&5
17985 sed 's/^/| /' conftest.$ac_ext >&5
17986
17987         eval "$as_ac_var=no"
17988 fi
17989
17990 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17991       conftest$ac_exeext conftest.$ac_ext
17992 fi
17993 ac_res=`eval echo '${'$as_ac_var'}'`
17994                { echo "$as_me:$LINENO: result: $ac_res" >&5
17995 echo "${ECHO_T}$ac_res" >&6; }
17996 if test `eval echo '${'$as_ac_var'}'` = yes; then
17997   cat >>confdefs.h <<_ACEOF
17998 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17999 _ACEOF
18000  break
18001 fi
18002 done
18003
18004
18005 # Check for one of atexit() or on_exit()
18006
18007 for ac_func in atexit
18008 do
18009 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18010 { echo "$as_me:$LINENO: checking for $ac_func" >&5
18011 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18012 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18013   echo $ECHO_N "(cached) $ECHO_C" >&6
18014 else
18015   cat >conftest.$ac_ext <<_ACEOF
18016 /* confdefs.h.  */
18017 _ACEOF
18018 cat confdefs.h >>conftest.$ac_ext
18019 cat >>conftest.$ac_ext <<_ACEOF
18020 /* end confdefs.h.  */
18021 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18022    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18023 #define $ac_func innocuous_$ac_func
18024
18025 /* System header to define __stub macros and hopefully few prototypes,
18026     which can conflict with char $ac_func (); below.
18027     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18028     <limits.h> exists even on freestanding compilers.  */
18029
18030 #ifdef __STDC__
18031 # include <limits.h>
18032 #else
18033 # include <assert.h>
18034 #endif
18035
18036 #undef $ac_func
18037
18038 /* Override any GCC internal prototype to avoid an error.
18039    Use char because int might match the return type of a GCC
18040    builtin and then its argument prototype would still apply.  */
18041 #ifdef __cplusplus
18042 extern "C"
18043 #endif
18044 char $ac_func ();
18045 /* The GNU C library defines this for functions which it implements
18046     to always fail with ENOSYS.  Some functions are actually named
18047     something starting with __ and the normal name is an alias.  */
18048 #if defined __stub_$ac_func || defined __stub___$ac_func
18049 choke me
18050 #endif
18051
18052 int
18053 main ()
18054 {
18055 return $ac_func ();
18056   ;
18057   return 0;
18058 }
18059 _ACEOF
18060 rm -f conftest.$ac_objext conftest$ac_exeext
18061 if { (ac_try="$ac_link"
18062 case "(($ac_try" in
18063   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18064   *) ac_try_echo=$ac_try;;
18065 esac
18066 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18067   (eval "$ac_link") 2>conftest.er1
18068   ac_status=$?
18069   grep -v '^ *+' conftest.er1 >conftest.err
18070   rm -f conftest.er1
18071   cat conftest.err >&5
18072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18073   (exit $ac_status); } && {
18074          test -z "$ac_c_werror_flag" ||
18075          test ! -s conftest.err
18076        } && test -s conftest$ac_exeext &&
18077        $as_test_x conftest$ac_exeext; then
18078   eval "$as_ac_var=yes"
18079 else
18080   echo "$as_me: failed program was:" >&5
18081 sed 's/^/| /' conftest.$ac_ext >&5
18082
18083         eval "$as_ac_var=no"
18084 fi
18085
18086 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18087       conftest$ac_exeext conftest.$ac_ext
18088 fi
18089 ac_res=`eval echo '${'$as_ac_var'}'`
18090                { echo "$as_me:$LINENO: result: $ac_res" >&5
18091 echo "${ECHO_T}$ac_res" >&6; }
18092 if test `eval echo '${'$as_ac_var'}'` = yes; then
18093   cat >>confdefs.h <<_ACEOF
18094 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18095 _ACEOF
18096
18097 else
18098
18099 for ac_func in on_exit
18100 do
18101 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18102 { echo "$as_me:$LINENO: checking for $ac_func" >&5
18103 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18104 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18105   echo $ECHO_N "(cached) $ECHO_C" >&6
18106 else
18107   cat >conftest.$ac_ext <<_ACEOF
18108 /* confdefs.h.  */
18109 _ACEOF
18110 cat confdefs.h >>conftest.$ac_ext
18111 cat >>conftest.$ac_ext <<_ACEOF
18112 /* end confdefs.h.  */
18113 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18114    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18115 #define $ac_func innocuous_$ac_func
18116
18117 /* System header to define __stub macros and hopefully few prototypes,
18118     which can conflict with char $ac_func (); below.
18119     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18120     <limits.h> exists even on freestanding compilers.  */
18121
18122 #ifdef __STDC__
18123 # include <limits.h>
18124 #else
18125 # include <assert.h>
18126 #endif
18127
18128 #undef $ac_func
18129
18130 /* Override any GCC internal prototype to avoid an error.
18131    Use char because int might match the return type of a GCC
18132    builtin and then its argument prototype would still apply.  */
18133 #ifdef __cplusplus
18134 extern "C"
18135 #endif
18136 char $ac_func ();
18137 /* The GNU C library defines this for functions which it implements
18138     to always fail with ENOSYS.  Some functions are actually named
18139     something starting with __ and the normal name is an alias.  */
18140 #if defined __stub_$ac_func || defined __stub___$ac_func
18141 choke me
18142 #endif
18143
18144 int
18145 main ()
18146 {
18147 return $ac_func ();
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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18159   (eval "$ac_link") 2>conftest.er1
18160   ac_status=$?
18161   grep -v '^ *+' conftest.er1 >conftest.err
18162   rm -f conftest.er1
18163   cat conftest.err >&5
18164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18165   (exit $ac_status); } && {
18166          test -z "$ac_c_werror_flag" ||
18167          test ! -s conftest.err
18168        } && test -s conftest$ac_exeext &&
18169        $as_test_x conftest$ac_exeext; then
18170   eval "$as_ac_var=yes"
18171 else
18172   echo "$as_me: failed program was:" >&5
18173 sed 's/^/| /' conftest.$ac_ext >&5
18174
18175         eval "$as_ac_var=no"
18176 fi
18177
18178 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18179       conftest$ac_exeext conftest.$ac_ext
18180 fi
18181 ac_res=`eval echo '${'$as_ac_var'}'`
18182                { echo "$as_me:$LINENO: result: $ac_res" >&5
18183 echo "${ECHO_T}$ac_res" >&6; }
18184 if test `eval echo '${'$as_ac_var'}'` = yes; then
18185   cat >>confdefs.h <<_ACEOF
18186 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18187 _ACEOF
18188
18189 else
18190   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
18191 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
18192    { (exit 1); exit 1; }; }
18193 fi
18194 done
18195
18196 fi
18197 done
18198
18199
18200
18201 for ac_func in fseeko
18202 do
18203 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18204 { echo "$as_me:$LINENO: checking for $ac_func" >&5
18205 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18206 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18207   echo $ECHO_N "(cached) $ECHO_C" >&6
18208 else
18209   cat >conftest.$ac_ext <<_ACEOF
18210 /* confdefs.h.  */
18211 _ACEOF
18212 cat confdefs.h >>conftest.$ac_ext
18213 cat >>conftest.$ac_ext <<_ACEOF
18214 /* end confdefs.h.  */
18215 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18216    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18217 #define $ac_func innocuous_$ac_func
18218
18219 /* System header to define __stub macros and hopefully few prototypes,
18220     which can conflict with char $ac_func (); below.
18221     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18222     <limits.h> exists even on freestanding compilers.  */
18223
18224 #ifdef __STDC__
18225 # include <limits.h>
18226 #else
18227 # include <assert.h>
18228 #endif
18229
18230 #undef $ac_func
18231
18232 /* Override any GCC internal prototype to avoid an error.
18233    Use char because int might match the return type of a GCC
18234    builtin and then its argument prototype would still apply.  */
18235 #ifdef __cplusplus
18236 extern "C"
18237 #endif
18238 char $ac_func ();
18239 /* The GNU C library defines this for functions which it implements
18240     to always fail with ENOSYS.  Some functions are actually named
18241     something starting with __ and the normal name is an alias.  */
18242 #if defined __stub_$ac_func || defined __stub___$ac_func
18243 choke me
18244 #endif
18245
18246 int
18247 main ()
18248 {
18249 return $ac_func ();
18250   ;
18251   return 0;
18252 }
18253 _ACEOF
18254 rm -f conftest.$ac_objext conftest$ac_exeext
18255 if { (ac_try="$ac_link"
18256 case "(($ac_try" in
18257   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18258   *) ac_try_echo=$ac_try;;
18259 esac
18260 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18261   (eval "$ac_link") 2>conftest.er1
18262   ac_status=$?
18263   grep -v '^ *+' conftest.er1 >conftest.err
18264   rm -f conftest.er1
18265   cat conftest.err >&5
18266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18267   (exit $ac_status); } && {
18268          test -z "$ac_c_werror_flag" ||
18269          test ! -s conftest.err
18270        } && test -s conftest$ac_exeext &&
18271        $as_test_x conftest$ac_exeext; then
18272   eval "$as_ac_var=yes"
18273 else
18274   echo "$as_me: failed program was:" >&5
18275 sed 's/^/| /' conftest.$ac_ext >&5
18276
18277         eval "$as_ac_var=no"
18278 fi
18279
18280 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18281       conftest$ac_exeext conftest.$ac_ext
18282 fi
18283 ac_res=`eval echo '${'$as_ac_var'}'`
18284                { echo "$as_me:$LINENO: result: $ac_res" >&5
18285 echo "${ECHO_T}$ac_res" >&6; }
18286 if test `eval echo '${'$as_ac_var'}'` = yes; then
18287   cat >>confdefs.h <<_ACEOF
18288 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18289 _ACEOF
18290
18291 else
18292   case " $LIBOBJS " in
18293   *" $ac_func.$ac_objext "* ) ;;
18294   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18295  ;;
18296 esac
18297
18298 fi
18299 done
18300
18301
18302 case $host_os in
18303         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
18304         bsdi*|netbsd*)
18305
18306 cat >>confdefs.h <<\_ACEOF
18307 #define HAVE_FSEEKO 1
18308 _ACEOF
18309
18310                 ac_cv_func_fseeko=yes;;
18311         *)
18312                 { echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
18313 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6; }
18314 if test "${ac_cv_sys_largefile_source+set}" = set; then
18315   echo $ECHO_N "(cached) $ECHO_C" >&6
18316 else
18317   while :; do
18318   cat >conftest.$ac_ext <<_ACEOF
18319 /* confdefs.h.  */
18320 _ACEOF
18321 cat confdefs.h >>conftest.$ac_ext
18322 cat >>conftest.$ac_ext <<_ACEOF
18323 /* end confdefs.h.  */
18324 #include <sys/types.h> /* for off_t */
18325      #include <stdio.h>
18326 int
18327 main ()
18328 {
18329 int (*fp) (FILE *, off_t, int) = fseeko;
18330      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18331   ;
18332   return 0;
18333 }
18334 _ACEOF
18335 rm -f conftest.$ac_objext conftest$ac_exeext
18336 if { (ac_try="$ac_link"
18337 case "(($ac_try" in
18338   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18339   *) ac_try_echo=$ac_try;;
18340 esac
18341 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18342   (eval "$ac_link") 2>conftest.er1
18343   ac_status=$?
18344   grep -v '^ *+' conftest.er1 >conftest.err
18345   rm -f conftest.er1
18346   cat conftest.err >&5
18347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18348   (exit $ac_status); } && {
18349          test -z "$ac_c_werror_flag" ||
18350          test ! -s conftest.err
18351        } && test -s conftest$ac_exeext &&
18352        $as_test_x conftest$ac_exeext; then
18353   ac_cv_sys_largefile_source=no; break
18354 else
18355   echo "$as_me: failed program was:" >&5
18356 sed 's/^/| /' conftest.$ac_ext >&5
18357
18358
18359 fi
18360
18361 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18362       conftest$ac_exeext conftest.$ac_ext
18363   cat >conftest.$ac_ext <<_ACEOF
18364 /* confdefs.h.  */
18365 _ACEOF
18366 cat confdefs.h >>conftest.$ac_ext
18367 cat >>conftest.$ac_ext <<_ACEOF
18368 /* end confdefs.h.  */
18369 #define _LARGEFILE_SOURCE 1
18370 #include <sys/types.h> /* for off_t */
18371      #include <stdio.h>
18372 int
18373 main ()
18374 {
18375 int (*fp) (FILE *, off_t, int) = fseeko;
18376      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18377   ;
18378   return 0;
18379 }
18380 _ACEOF
18381 rm -f conftest.$ac_objext conftest$ac_exeext
18382 if { (ac_try="$ac_link"
18383 case "(($ac_try" in
18384   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18385   *) ac_try_echo=$ac_try;;
18386 esac
18387 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18388   (eval "$ac_link") 2>conftest.er1
18389   ac_status=$?
18390   grep -v '^ *+' conftest.er1 >conftest.err
18391   rm -f conftest.er1
18392   cat conftest.err >&5
18393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18394   (exit $ac_status); } && {
18395          test -z "$ac_c_werror_flag" ||
18396          test ! -s conftest.err
18397        } && test -s conftest$ac_exeext &&
18398        $as_test_x conftest$ac_exeext; then
18399   ac_cv_sys_largefile_source=1; break
18400 else
18401   echo "$as_me: failed program was:" >&5
18402 sed 's/^/| /' conftest.$ac_ext >&5
18403
18404
18405 fi
18406
18407 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18408       conftest$ac_exeext conftest.$ac_ext
18409   ac_cv_sys_largefile_source=unknown
18410   break
18411 done
18412 fi
18413 { echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
18414 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6; }
18415 case $ac_cv_sys_largefile_source in #(
18416   no | unknown) ;;
18417   *)
18418 cat >>confdefs.h <<_ACEOF
18419 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
18420 _ACEOF
18421 ;;
18422 esac
18423 rm -f conftest*
18424
18425 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
18426 # in glibc 2.1.3, but that breaks too many other things.
18427 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
18428 if test $ac_cv_sys_largefile_source != unknown; then
18429
18430 cat >>confdefs.h <<\_ACEOF
18431 #define HAVE_FSEEKO 1
18432 _ACEOF
18433
18434 fi
18435 ;;
18436 esac
18437
18438
18439 #
18440 # Pthreads
18441 #
18442 # For each platform, we need to know about any special compile and link
18443 # libraries, and whether the normal C function names are thread-safe.
18444 # See the comment at the top of src/port/thread.c for more information.
18445 # WIN32 doesn't need the pthread tests;  it always uses threads
18446 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
18447
18448
18449
18450 ac_ext=c
18451 ac_cpp='$CPP $CPPFLAGS'
18452 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18453 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18454 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18455
18456 acx_pthread_ok=no
18457
18458 # We used to check for pthread.h first, but this fails if pthread.h
18459 # requires special compiler flags (e.g. on True64 or Sequent).
18460 # It gets checked for in the link test anyway.
18461
18462 # First of all, check if the user has set any of the PTHREAD_LIBS,
18463 # etcetera environment variables, and if threads linking works using
18464 # them:
18465 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
18466         save_CFLAGS="$CFLAGS"
18467         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
18468         save_LIBS="$LIBS"
18469         LIBS="$PTHREAD_LIBS $LIBS"
18470         { echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
18471 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6; }
18472         cat >conftest.$ac_ext <<_ACEOF
18473 /* confdefs.h.  */
18474 _ACEOF
18475 cat confdefs.h >>conftest.$ac_ext
18476 cat >>conftest.$ac_ext <<_ACEOF
18477 /* end confdefs.h.  */
18478
18479 /* Override any GCC internal prototype to avoid an error.
18480    Use char because int might match the return type of a GCC
18481    builtin and then its argument prototype would still apply.  */
18482 #ifdef __cplusplus
18483 extern "C"
18484 #endif
18485 char pthread_join ();
18486 int
18487 main ()
18488 {
18489 return pthread_join ();
18490   ;
18491   return 0;
18492 }
18493 _ACEOF
18494 rm -f conftest.$ac_objext conftest$ac_exeext
18495 if { (ac_try="$ac_link"
18496 case "(($ac_try" in
18497   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18498   *) ac_try_echo=$ac_try;;
18499 esac
18500 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18501   (eval "$ac_link") 2>conftest.er1
18502   ac_status=$?
18503   grep -v '^ *+' conftest.er1 >conftest.err
18504   rm -f conftest.er1
18505   cat conftest.err >&5
18506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18507   (exit $ac_status); } && {
18508          test -z "$ac_c_werror_flag" ||
18509          test ! -s conftest.err
18510        } && test -s conftest$ac_exeext &&
18511        $as_test_x conftest$ac_exeext; then
18512   acx_pthread_ok=yes
18513 else
18514   echo "$as_me: failed program was:" >&5
18515 sed 's/^/| /' conftest.$ac_ext >&5
18516
18517
18518 fi
18519
18520 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18521       conftest$ac_exeext conftest.$ac_ext
18522         { echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
18523 echo "${ECHO_T}$acx_pthread_ok" >&6; }
18524         if test x"$acx_pthread_ok" = xno; then
18525                 PTHREAD_LIBS=""
18526                 PTHREAD_CFLAGS=""
18527         fi
18528         LIBS="$save_LIBS"
18529         CFLAGS="$save_CFLAGS"
18530 fi
18531
18532 # We must check for the threads library under a number of different
18533 # names; the ordering is very important because some systems
18534 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
18535 # libraries is broken (non-POSIX).
18536
18537 # Create a list of thread flags to try.  Items starting with a "-" are
18538 # C compiler flags, and other items are library names, except for "none"
18539 # which indicates that we try without any flags at all, and "pthread-config"
18540 # which is a program returning the flags for the Pth emulation library.
18541
18542 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
18543
18544 # The ordering *is* (sometimes) important.  Some notes on the
18545 # individual items follow:
18546
18547 # pthreads: AIX (must check this before -lpthread)
18548 # none: in case threads are in libc; should be tried before -Kthread and
18549 #       other compiler flags to prevent continual compiler warnings
18550 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
18551 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
18552 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
18553 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
18554 # -pthreads: Solaris/gcc
18555 # -mthreads: Mingw32/gcc, Lynx/gcc
18556 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
18557 #      doesn't hurt to check since this sometimes defines pthreads too;
18558 #      also defines -D_REENTRANT)
18559 # pthread: Linux, etcetera
18560 # --thread-safe: KAI C++
18561 # pthread-config: use pthread-config program (for GNU Pth library)
18562
18563 case "${host_cpu}-${host_os}" in
18564         *solaris*)
18565
18566         # On Solaris (at least, for some versions), libc contains stubbed
18567         # (non-functional) versions of the pthreads routines, so link-based
18568         # tests will erroneously succeed.  (We need to link with -pthread or
18569         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
18570         # a function called by this macro, so we could check for that, but
18571         # who knows whether they'll stub that too in a future libc.)  So,
18572         # we'll just look for -pthreads and -lpthread first:
18573
18574         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
18575         ;;
18576 esac
18577
18578 if test x"$acx_pthread_ok" = xno; then
18579 for flag in $acx_pthread_flags; do
18580
18581         tryPTHREAD_CFLAGS=""
18582         tryPTHREAD_LIBS=""
18583         case $flag in
18584                 none)
18585                 { echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
18586 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6; }
18587                 ;;
18588
18589                 -*)
18590                 { echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
18591 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6; }
18592                 tryPTHREAD_CFLAGS="$flag"
18593                 ;;
18594
18595                 pthread-config)
18596                 # skip this if we already have flags defined, for PostgreSQL
18597                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
18598                 # Extract the first word of "pthread-config", so it can be a program name with args.
18599 set dummy pthread-config; ac_word=$2
18600 { echo "$as_me:$LINENO: checking for $ac_word" >&5
18601 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
18602 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
18603   echo $ECHO_N "(cached) $ECHO_C" >&6
18604 else
18605   if test -n "$acx_pthread_config"; then
18606   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
18607 else
18608 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18609 for as_dir in $PATH
18610 do
18611   IFS=$as_save_IFS
18612   test -z "$as_dir" && as_dir=.
18613   for ac_exec_ext in '' $ac_executable_extensions; do
18614   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18615     ac_cv_prog_acx_pthread_config="yes"
18616     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18617     break 2
18618   fi
18619 done
18620 done
18621 IFS=$as_save_IFS
18622
18623   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
18624 fi
18625 fi
18626 acx_pthread_config=$ac_cv_prog_acx_pthread_config
18627 if test -n "$acx_pthread_config"; then
18628   { echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
18629 echo "${ECHO_T}$acx_pthread_config" >&6; }
18630 else
18631   { echo "$as_me:$LINENO: result: no" >&5
18632 echo "${ECHO_T}no" >&6; }
18633 fi
18634
18635
18636                 if test x"$acx_pthread_config" = xno; then continue; fi
18637                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
18638                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
18639                 ;;
18640
18641                 *)
18642                 { echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
18643 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6; }
18644                 tryPTHREAD_LIBS="-l$flag"
18645                 ;;
18646         esac
18647
18648         save_LIBS="$LIBS"
18649         save_CFLAGS="$CFLAGS"
18650         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
18651         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
18652
18653         # Check for various functions.  We must include pthread.h,
18654         # since some functions may be macros.  (On the Sequent, we
18655         # need a special flag -Kthread to make this header compile.)
18656         # We check for pthread_join because it is in -lpthread on IRIX
18657         # while pthread_create is in libc.  We check for pthread_attr_init
18658         # due to DEC craziness with -lpthreads.  We check for
18659         # pthread_cleanup_push because it is one of the few pthread
18660         # functions on Solaris that doesn't have a non-functional libc stub.
18661         # We try pthread_create on general principles.
18662         cat >conftest.$ac_ext <<_ACEOF
18663 /* confdefs.h.  */
18664 _ACEOF
18665 cat confdefs.h >>conftest.$ac_ext
18666 cat >>conftest.$ac_ext <<_ACEOF
18667 /* end confdefs.h.  */
18668 #include <pthread.h>
18669 int
18670 main ()
18671 {
18672 pthread_t th; pthread_join(th, 0);
18673                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
18674                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
18675   ;
18676   return 0;
18677 }
18678 _ACEOF
18679 rm -f conftest.$ac_objext conftest$ac_exeext
18680 if { (ac_try="$ac_link"
18681 case "(($ac_try" in
18682   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18683   *) ac_try_echo=$ac_try;;
18684 esac
18685 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18686   (eval "$ac_link") 2>conftest.er1
18687   ac_status=$?
18688   grep -v '^ *+' conftest.er1 >conftest.err
18689   rm -f conftest.er1
18690   cat conftest.err >&5
18691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18692   (exit $ac_status); } && {
18693          test -z "$ac_c_werror_flag" ||
18694          test ! -s conftest.err
18695        } && test -s conftest$ac_exeext &&
18696        $as_test_x conftest$ac_exeext; then
18697   acx_pthread_ok=yes
18698 else
18699   echo "$as_me: failed program was:" >&5
18700 sed 's/^/| /' conftest.$ac_ext >&5
18701
18702         acx_pthread_ok=no
18703 fi
18704
18705 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18706       conftest$ac_exeext conftest.$ac_ext
18707
18708         if test "x$acx_pthread_ok" = xyes; then
18709             # Don't use options that are ignored by the compiler.
18710             # We find them by checking stderror.
18711             cat >conftest.$ac_ext <<_ACEOF
18712 int
18713 main (int argc, char **argv)
18714 {
18715   (void) argc;
18716   (void) argv;
18717   return 0;
18718 }
18719 _ACEOF
18720             rm -f conftest.$ac_objext conftest$ac_exeext
18721             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
18722                 # we continue with more flags because Linux needs -lpthread
18723                 # for libpq builds on PostgreSQL.  The test above only
18724                 # tests for building binaries, not shared libraries.
18725                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
18726                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
18727             else   acx_pthread_ok=no
18728             fi
18729         fi
18730
18731         LIBS="$save_LIBS"
18732         CFLAGS="$save_CFLAGS"
18733
18734         { echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
18735 echo "${ECHO_T}$acx_pthread_ok" >&6; }
18736 done
18737 fi
18738
18739 # Various other checks:
18740 if test "x$acx_pthread_ok" = xyes; then
18741         save_LIBS="$LIBS"
18742         LIBS="$PTHREAD_LIBS $LIBS"
18743         save_CFLAGS="$CFLAGS"
18744         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
18745
18746         # Detect AIX lossage: threads are created detached by default
18747         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
18748         { echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
18749 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6; }
18750         cat >conftest.$ac_ext <<_ACEOF
18751 /* confdefs.h.  */
18752 _ACEOF
18753 cat confdefs.h >>conftest.$ac_ext
18754 cat >>conftest.$ac_ext <<_ACEOF
18755 /* end confdefs.h.  */
18756 #include <pthread.h>
18757 int
18758 main ()
18759 {
18760 int attr=PTHREAD_CREATE_JOINABLE;
18761   ;
18762   return 0;
18763 }
18764 _ACEOF
18765 rm -f conftest.$ac_objext conftest$ac_exeext
18766 if { (ac_try="$ac_link"
18767 case "(($ac_try" in
18768   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18769   *) ac_try_echo=$ac_try;;
18770 esac
18771 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18772   (eval "$ac_link") 2>conftest.er1
18773   ac_status=$?
18774   grep -v '^ *+' conftest.er1 >conftest.err
18775   rm -f conftest.er1
18776   cat conftest.err >&5
18777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18778   (exit $ac_status); } && {
18779          test -z "$ac_c_werror_flag" ||
18780          test ! -s conftest.err
18781        } && test -s conftest$ac_exeext &&
18782        $as_test_x conftest$ac_exeext; then
18783   ok=PTHREAD_CREATE_JOINABLE
18784 else
18785   echo "$as_me: failed program was:" >&5
18786 sed 's/^/| /' conftest.$ac_ext >&5
18787
18788         ok=unknown
18789 fi
18790
18791 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18792       conftest$ac_exeext conftest.$ac_ext
18793         if test x"$ok" = xunknown; then
18794                 cat >conftest.$ac_ext <<_ACEOF
18795 /* confdefs.h.  */
18796 _ACEOF
18797 cat confdefs.h >>conftest.$ac_ext
18798 cat >>conftest.$ac_ext <<_ACEOF
18799 /* end confdefs.h.  */
18800 #include <pthread.h>
18801 int
18802 main ()
18803 {
18804 int attr=PTHREAD_CREATE_UNDETACHED;
18805   ;
18806   return 0;
18807 }
18808 _ACEOF
18809 rm -f conftest.$ac_objext conftest$ac_exeext
18810 if { (ac_try="$ac_link"
18811 case "(($ac_try" in
18812   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18813   *) ac_try_echo=$ac_try;;
18814 esac
18815 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18816   (eval "$ac_link") 2>conftest.er1
18817   ac_status=$?
18818   grep -v '^ *+' conftest.er1 >conftest.err
18819   rm -f conftest.er1
18820   cat conftest.err >&5
18821   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18822   (exit $ac_status); } && {
18823          test -z "$ac_c_werror_flag" ||
18824          test ! -s conftest.err
18825        } && test -s conftest$ac_exeext &&
18826        $as_test_x conftest$ac_exeext; then
18827   ok=PTHREAD_CREATE_UNDETACHED
18828 else
18829   echo "$as_me: failed program was:" >&5
18830 sed 's/^/| /' conftest.$ac_ext >&5
18831
18832         ok=unknown
18833 fi
18834
18835 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18836       conftest$ac_exeext conftest.$ac_ext
18837         fi
18838         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
18839
18840 cat >>confdefs.h <<\_ACEOF
18841 #define PTHREAD_CREATE_JOINABLE $ok
18842 _ACEOF
18843
18844         fi
18845         { echo "$as_me:$LINENO: result: ${ok}" >&5
18846 echo "${ECHO_T}${ok}" >&6; }
18847         if test x"$ok" = xunknown; then
18848                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
18849 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
18850         fi
18851
18852         { echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
18853 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6; }
18854         flag=no
18855 # We always add these in PostgreSQL
18856 #       case "${host_cpu}-${host_os}" in
18857 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
18858 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
18859 #       esac
18860         { echo "$as_me:$LINENO: result: ${flag}" >&5
18861 echo "${ECHO_T}${flag}" >&6; }
18862         if test "x$flag" != xno; then
18863                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
18864         fi
18865
18866         LIBS="$save_LIBS"
18867         CFLAGS="$save_CFLAGS"
18868
18869 # Supporting cc_r would require a special CC in all places that
18870 # use libpq, and that is ugly, so we don't do it.  Users can still
18871 # define their compiler as cc_r to do thread builds of everything.
18872         # More AIX lossage: must compile with cc_r
18873         # Extract the first word of "cc_r", so it can be a program name with args.
18874 set dummy cc_r; ac_word=$2
18875 { echo "$as_me:$LINENO: checking for $ac_word" >&5
18876 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
18877 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
18878   echo $ECHO_N "(cached) $ECHO_C" >&6
18879 else
18880   if test -n "$PTHREAD_CC"; then
18881   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
18882 else
18883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18884 for as_dir in $PATH
18885 do
18886   IFS=$as_save_IFS
18887   test -z "$as_dir" && as_dir=.
18888   for ac_exec_ext in '' $ac_executable_extensions; do
18889   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18890     ac_cv_prog_PTHREAD_CC="cc_r"
18891     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18892     break 2
18893   fi
18894 done
18895 done
18896 IFS=$as_save_IFS
18897
18898   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
18899 fi
18900 fi
18901 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
18902 if test -n "$PTHREAD_CC"; then
18903   { echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
18904 echo "${ECHO_T}$PTHREAD_CC" >&6; }
18905 else
18906   { echo "$as_me:$LINENO: result: no" >&5
18907 echo "${ECHO_T}no" >&6; }
18908 fi
18909
18910
18911 else
18912         PTHREAD_CC="$CC"
18913 fi
18914
18915
18916
18917
18918
18919 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
18920 if test x"$acx_pthread_ok" = xyes; then
18921
18922 cat >>confdefs.h <<\_ACEOF
18923 #define HAVE_PTHREAD 1
18924 _ACEOF
18925
18926         :
18927 else
18928         acx_pthread_ok=no
18929
18930 fi
18931 ac_ext=c
18932 ac_cpp='$CPP $CPPFLAGS'
18933 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18934 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18935 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18936
18937         # set thread flags
18938
18939 # Some platforms use these, so just defineed them.  They can't hurt if they
18940 # are not supported.
18941 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
18942
18943
18944 # At this point, we don't want to muck with the compiler name for threading.
18945 # Let's see who fails, perhaps AIX.  2004-04-23
18946 if test "$PTHREAD_CC" != "$CC"; then
18947 { { echo "$as_me:$LINENO: error:
18948 PostgreSQL does not support platforms that require a special compiler
18949 for thread safety." >&5
18950 echo "$as_me: error:
18951 PostgreSQL does not support platforms that require a special compiler
18952 for thread safety." >&2;}
18953    { (exit 1); exit 1; }; }
18954 fi
18955
18956 if test "$THREAD_SUPPORT" = no; then
18957 { { echo "$as_me:$LINENO: error: cannot enable threads on this platform
18958 This platform is known to not support thread-safe programs.  For details,
18959 compile and run src/bin/pg_thread_test." >&5
18960 echo "$as_me: error: cannot enable threads on this platform
18961 This platform is known to not support thread-safe programs.  For details,
18962 compile and run src/bin/pg_thread_test." >&2;}
18963    { (exit 1); exit 1; }; }
18964 fi
18965
18966 # Check for *_r functions
18967 _CFLAGS="$CFLAGS"
18968 _LIBS="$LIBS"
18969 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
18970 LIBS="$LIBS $PTHREAD_LIBS"
18971
18972 if test "$PORTNAME" != "win32"; then
18973 if test "${ac_cv_header_pthread_h+set}" = set; then
18974   { echo "$as_me:$LINENO: checking for pthread.h" >&5
18975 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6; }
18976 if test "${ac_cv_header_pthread_h+set}" = set; then
18977   echo $ECHO_N "(cached) $ECHO_C" >&6
18978 fi
18979 { echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
18980 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6; }
18981 else
18982   # Is the header compilable?
18983 { echo "$as_me:$LINENO: checking pthread.h usability" >&5
18984 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6; }
18985 cat >conftest.$ac_ext <<_ACEOF
18986 /* confdefs.h.  */
18987 _ACEOF
18988 cat confdefs.h >>conftest.$ac_ext
18989 cat >>conftest.$ac_ext <<_ACEOF
18990 /* end confdefs.h.  */
18991 $ac_includes_default
18992 #include <pthread.h>
18993 _ACEOF
18994 rm -f conftest.$ac_objext
18995 if { (ac_try="$ac_compile"
18996 case "(($ac_try" in
18997   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18998   *) ac_try_echo=$ac_try;;
18999 esac
19000 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19001   (eval "$ac_compile") 2>conftest.er1
19002   ac_status=$?
19003   grep -v '^ *+' conftest.er1 >conftest.err
19004   rm -f conftest.er1
19005   cat conftest.err >&5
19006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19007   (exit $ac_status); } && {
19008          test -z "$ac_c_werror_flag" ||
19009          test ! -s conftest.err
19010        } && test -s conftest.$ac_objext; then
19011   ac_header_compiler=yes
19012 else
19013   echo "$as_me: failed program was:" >&5
19014 sed 's/^/| /' conftest.$ac_ext >&5
19015
19016         ac_header_compiler=no
19017 fi
19018
19019 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19020 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19021 echo "${ECHO_T}$ac_header_compiler" >&6; }
19022
19023 # Is the header present?
19024 { echo "$as_me:$LINENO: checking pthread.h presence" >&5
19025 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6; }
19026 cat >conftest.$ac_ext <<_ACEOF
19027 /* confdefs.h.  */
19028 _ACEOF
19029 cat confdefs.h >>conftest.$ac_ext
19030 cat >>conftest.$ac_ext <<_ACEOF
19031 /* end confdefs.h.  */
19032 #include <pthread.h>
19033 _ACEOF
19034 if { (ac_try="$ac_cpp conftest.$ac_ext"
19035 case "(($ac_try" in
19036   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19037   *) ac_try_echo=$ac_try;;
19038 esac
19039 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19040   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
19041   ac_status=$?
19042   grep -v '^ *+' conftest.er1 >conftest.err
19043   rm -f conftest.er1
19044   cat conftest.err >&5
19045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19046   (exit $ac_status); } >/dev/null && {
19047          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
19048          test ! -s conftest.err
19049        }; then
19050   ac_header_preproc=yes
19051 else
19052   echo "$as_me: failed program was:" >&5
19053 sed 's/^/| /' conftest.$ac_ext >&5
19054
19055   ac_header_preproc=no
19056 fi
19057
19058 rm -f conftest.err conftest.$ac_ext
19059 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19060 echo "${ECHO_T}$ac_header_preproc" >&6; }
19061
19062 # So?  What about this header?
19063 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19064   yes:no: )
19065     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
19066 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
19067     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
19068 echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
19069     ac_header_preproc=yes
19070     ;;
19071   no:yes:* )
19072     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
19073 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
19074     { echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
19075 echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
19076     { echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
19077 echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
19078     { echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
19079 echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
19080     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
19081 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
19082     { echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
19083 echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
19084     ( cat <<\_ASBOX
19085 ## ---------------------------------------- ##
19086 ## Report this to pgsql-bugs@postgresql.org ##
19087 ## ---------------------------------------- ##
19088 _ASBOX
19089      ) | sed "s/^/$as_me: WARNING:     /" >&2
19090     ;;
19091 esac
19092 { echo "$as_me:$LINENO: checking for pthread.h" >&5
19093 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6; }
19094 if test "${ac_cv_header_pthread_h+set}" = set; then
19095   echo $ECHO_N "(cached) $ECHO_C" >&6
19096 else
19097   ac_cv_header_pthread_h=$ac_header_preproc
19098 fi
19099 { echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
19100 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6; }
19101
19102 fi
19103 if test $ac_cv_header_pthread_h = yes; then
19104   :
19105 else
19106   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
19107 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
19108    { (exit 1); exit 1; }; }
19109 fi
19110
19111
19112 fi
19113
19114
19115
19116
19117 for ac_func in strerror_r getpwuid_r gethostbyname_r
19118 do
19119 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19120 { echo "$as_me:$LINENO: checking for $ac_func" >&5
19121 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
19122 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19123   echo $ECHO_N "(cached) $ECHO_C" >&6
19124 else
19125   cat >conftest.$ac_ext <<_ACEOF
19126 /* confdefs.h.  */
19127 _ACEOF
19128 cat confdefs.h >>conftest.$ac_ext
19129 cat >>conftest.$ac_ext <<_ACEOF
19130 /* end confdefs.h.  */
19131 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19132    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19133 #define $ac_func innocuous_$ac_func
19134
19135 /* System header to define __stub macros and hopefully few prototypes,
19136     which can conflict with char $ac_func (); below.
19137     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19138     <limits.h> exists even on freestanding compilers.  */
19139
19140 #ifdef __STDC__
19141 # include <limits.h>
19142 #else
19143 # include <assert.h>
19144 #endif
19145
19146 #undef $ac_func
19147
19148 /* Override any GCC internal prototype to avoid an error.
19149    Use char because int might match the return type of a GCC
19150    builtin and then its argument prototype would still apply.  */
19151 #ifdef __cplusplus
19152 extern "C"
19153 #endif
19154 char $ac_func ();
19155 /* The GNU C library defines this for functions which it implements
19156     to always fail with ENOSYS.  Some functions are actually named
19157     something starting with __ and the normal name is an alias.  */
19158 #if defined __stub_$ac_func || defined __stub___$ac_func
19159 choke me
19160 #endif
19161
19162 int
19163 main ()
19164 {
19165 return $ac_func ();
19166   ;
19167   return 0;
19168 }
19169 _ACEOF
19170 rm -f conftest.$ac_objext conftest$ac_exeext
19171 if { (ac_try="$ac_link"
19172 case "(($ac_try" in
19173   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19174   *) ac_try_echo=$ac_try;;
19175 esac
19176 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19177   (eval "$ac_link") 2>conftest.er1
19178   ac_status=$?
19179   grep -v '^ *+' conftest.er1 >conftest.err
19180   rm -f conftest.er1
19181   cat conftest.err >&5
19182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19183   (exit $ac_status); } && {
19184          test -z "$ac_c_werror_flag" ||
19185          test ! -s conftest.err
19186        } && test -s conftest$ac_exeext &&
19187        $as_test_x conftest$ac_exeext; then
19188   eval "$as_ac_var=yes"
19189 else
19190   echo "$as_me: failed program was:" >&5
19191 sed 's/^/| /' conftest.$ac_ext >&5
19192
19193         eval "$as_ac_var=no"
19194 fi
19195
19196 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19197       conftest$ac_exeext conftest.$ac_ext
19198 fi
19199 ac_res=`eval echo '${'$as_ac_var'}'`
19200                { echo "$as_me:$LINENO: result: $ac_res" >&5
19201 echo "${ECHO_T}$ac_res" >&6; }
19202 if test `eval echo '${'$as_ac_var'}'` = yes; then
19203   cat >>confdefs.h <<_ACEOF
19204 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19205 _ACEOF
19206
19207 fi
19208 done
19209
19210
19211 # Do test here with the proper thread flags
19212 { echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
19213 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6; }
19214 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
19215   echo $ECHO_N "(cached) $ECHO_C" >&6
19216 else
19217   cat >conftest.$ac_ext <<_ACEOF
19218 /* confdefs.h.  */
19219 _ACEOF
19220 cat confdefs.h >>conftest.$ac_ext
19221 cat >>conftest.$ac_ext <<_ACEOF
19222 /* end confdefs.h.  */
19223 #include <sys/types.h>
19224 #include <pwd.h>
19225 int
19226 main ()
19227 {
19228 uid_t uid;
19229 struct passwd *space;
19230 char *buf;
19231 size_t bufsize;
19232 struct passwd **result;
19233 getpwuid_r(uid, space, buf, bufsize, result);
19234   ;
19235   return 0;
19236 }
19237 _ACEOF
19238 rm -f conftest.$ac_objext
19239 if { (ac_try="$ac_compile"
19240 case "(($ac_try" in
19241   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19242   *) ac_try_echo=$ac_try;;
19243 esac
19244 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19245   (eval "$ac_compile") 2>conftest.er1
19246   ac_status=$?
19247   grep -v '^ *+' conftest.er1 >conftest.err
19248   rm -f conftest.er1
19249   cat conftest.err >&5
19250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19251   (exit $ac_status); } && {
19252          test -z "$ac_c_werror_flag" ||
19253          test ! -s conftest.err
19254        } && test -s conftest.$ac_objext; then
19255   pgac_cv_func_getpwuid_r_5arg=yes
19256 else
19257   echo "$as_me: failed program was:" >&5
19258 sed 's/^/| /' conftest.$ac_ext >&5
19259
19260         pgac_cv_func_getpwuid_r_5arg=no
19261 fi
19262
19263 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19264 fi
19265 { echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
19266 echo "${ECHO_T}$pgac_cv_func_getpwuid_r_5arg" >&6; }
19267 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
19268
19269 cat >>confdefs.h <<\_ACEOF
19270 #define GETPWUID_R_5ARG
19271 _ACEOF
19272
19273 fi
19274
19275 { echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
19276 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6; }
19277 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
19278   echo $ECHO_N "(cached) $ECHO_C" >&6
19279 else
19280   cat >conftest.$ac_ext <<_ACEOF
19281 /* confdefs.h.  */
19282 _ACEOF
19283 cat confdefs.h >>conftest.$ac_ext
19284 cat >>conftest.$ac_ext <<_ACEOF
19285 /* end confdefs.h.  */
19286 #include <string.h>
19287 int
19288 main ()
19289 {
19290 #ifndef _AIX
19291 int strerror_r(int, char *, size_t);
19292 #else
19293 /* Older AIX has 'int' for the third argument so we don't test the args. */
19294 int strerror_r();
19295 #endif
19296   ;
19297   return 0;
19298 }
19299 _ACEOF
19300 rm -f conftest.$ac_objext
19301 if { (ac_try="$ac_compile"
19302 case "(($ac_try" in
19303   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19304   *) ac_try_echo=$ac_try;;
19305 esac
19306 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19307   (eval "$ac_compile") 2>conftest.er1
19308   ac_status=$?
19309   grep -v '^ *+' conftest.er1 >conftest.err
19310   rm -f conftest.er1
19311   cat conftest.err >&5
19312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19313   (exit $ac_status); } && {
19314          test -z "$ac_c_werror_flag" ||
19315          test ! -s conftest.err
19316        } && test -s conftest.$ac_objext; then
19317   pgac_cv_func_strerror_r_int=yes
19318 else
19319   echo "$as_me: failed program was:" >&5
19320 sed 's/^/| /' conftest.$ac_ext >&5
19321
19322         pgac_cv_func_strerror_r_int=no
19323 fi
19324
19325 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19326 fi
19327 { echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
19328 echo "${ECHO_T}$pgac_cv_func_strerror_r_int" >&6; }
19329 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
19330
19331 cat >>confdefs.h <<\_ACEOF
19332 #define STRERROR_R_INT
19333 _ACEOF
19334
19335 fi
19336
19337
19338 CFLAGS="$_CFLAGS"
19339 LIBS="$_LIBS"
19340
19341 else
19342 # do not use values from template file
19343 PTHREAD_CFLAGS=
19344 PTHREAD_LIBS=
19345 fi
19346
19347
19348
19349
19350
19351 # We can test for libldap_r only after we know PTHREAD_LIBS
19352 if test "$with_ldap" = yes ; then
19353   _LIBS="$LIBS"
19354   if test "$PORTNAME" != "win32"; then
19355
19356 { echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
19357 echo $ECHO_N "checking for ldap_bind in -lldap... $ECHO_C" >&6; }
19358 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
19359   echo $ECHO_N "(cached) $ECHO_C" >&6
19360 else
19361   ac_check_lib_save_LIBS=$LIBS
19362 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
19363 cat >conftest.$ac_ext <<_ACEOF
19364 /* confdefs.h.  */
19365 _ACEOF
19366 cat confdefs.h >>conftest.$ac_ext
19367 cat >>conftest.$ac_ext <<_ACEOF
19368 /* end confdefs.h.  */
19369
19370 /* Override any GCC internal prototype to avoid an error.
19371    Use char because int might match the return type of a GCC
19372    builtin and then its argument prototype would still apply.  */
19373 #ifdef __cplusplus
19374 extern "C"
19375 #endif
19376 char ldap_bind ();
19377 int
19378 main ()
19379 {
19380 return ldap_bind ();
19381   ;
19382   return 0;
19383 }
19384 _ACEOF
19385 rm -f conftest.$ac_objext conftest$ac_exeext
19386 if { (ac_try="$ac_link"
19387 case "(($ac_try" in
19388   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19389   *) ac_try_echo=$ac_try;;
19390 esac
19391 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19392   (eval "$ac_link") 2>conftest.er1
19393   ac_status=$?
19394   grep -v '^ *+' conftest.er1 >conftest.err
19395   rm -f conftest.er1
19396   cat conftest.err >&5
19397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19398   (exit $ac_status); } && {
19399          test -z "$ac_c_werror_flag" ||
19400          test ! -s conftest.err
19401        } && test -s conftest$ac_exeext &&
19402        $as_test_x conftest$ac_exeext; then
19403   ac_cv_lib_ldap_ldap_bind=yes
19404 else
19405   echo "$as_me: failed program was:" >&5
19406 sed 's/^/| /' conftest.$ac_ext >&5
19407
19408         ac_cv_lib_ldap_ldap_bind=no
19409 fi
19410
19411 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19412       conftest$ac_exeext conftest.$ac_ext
19413 LIBS=$ac_check_lib_save_LIBS
19414 fi
19415 { echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
19416 echo "${ECHO_T}$ac_cv_lib_ldap_ldap_bind" >&6; }
19417 if test $ac_cv_lib_ldap_ldap_bind = yes; then
19418   cat >>confdefs.h <<_ACEOF
19419 #define HAVE_LIBLDAP 1
19420 _ACEOF
19421
19422   LIBS="-lldap $LIBS"
19423
19424 else
19425   { { echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
19426 echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
19427    { (exit 1); exit 1; }; }
19428 fi
19429
19430     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
19431     if test "$enable_thread_safety" = yes; then
19432       # on some platforms ldap_r fails to link without PTHREAD_LIBS
19433
19434 { echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
19435 echo $ECHO_N "checking for ldap_simple_bind in -lldap_r... $ECHO_C" >&6; }
19436 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
19437   echo $ECHO_N "(cached) $ECHO_C" >&6
19438 else
19439   ac_check_lib_save_LIBS=$LIBS
19440 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
19441 cat >conftest.$ac_ext <<_ACEOF
19442 /* confdefs.h.  */
19443 _ACEOF
19444 cat confdefs.h >>conftest.$ac_ext
19445 cat >>conftest.$ac_ext <<_ACEOF
19446 /* end confdefs.h.  */
19447
19448 /* Override any GCC internal prototype to avoid an error.
19449    Use char because int might match the return type of a GCC
19450    builtin and then its argument prototype would still apply.  */
19451 #ifdef __cplusplus
19452 extern "C"
19453 #endif
19454 char ldap_simple_bind ();
19455 int
19456 main ()
19457 {
19458 return ldap_simple_bind ();
19459   ;
19460   return 0;
19461 }
19462 _ACEOF
19463 rm -f conftest.$ac_objext conftest$ac_exeext
19464 if { (ac_try="$ac_link"
19465 case "(($ac_try" in
19466   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19467   *) ac_try_echo=$ac_try;;
19468 esac
19469 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19470   (eval "$ac_link") 2>conftest.er1
19471   ac_status=$?
19472   grep -v '^ *+' conftest.er1 >conftest.err
19473   rm -f conftest.er1
19474   cat conftest.err >&5
19475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19476   (exit $ac_status); } && {
19477          test -z "$ac_c_werror_flag" ||
19478          test ! -s conftest.err
19479        } && test -s conftest$ac_exeext &&
19480        $as_test_x conftest$ac_exeext; then
19481   ac_cv_lib_ldap_r_ldap_simple_bind=yes
19482 else
19483   echo "$as_me: failed program was:" >&5
19484 sed 's/^/| /' conftest.$ac_ext >&5
19485
19486         ac_cv_lib_ldap_r_ldap_simple_bind=no
19487 fi
19488
19489 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19490       conftest$ac_exeext conftest.$ac_ext
19491 LIBS=$ac_check_lib_save_LIBS
19492 fi
19493 { echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
19494 echo "${ECHO_T}$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
19495 if test $ac_cv_lib_ldap_r_ldap_simple_bind = yes; then
19496   cat >>confdefs.h <<_ACEOF
19497 #define HAVE_LIBLDAP_R 1
19498 _ACEOF
19499
19500   LIBS="-lldap_r $LIBS"
19501
19502 else
19503   { { echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
19504 echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
19505    { (exit 1); exit 1; }; }
19506 fi
19507
19508       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
19509     else
19510       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
19511     fi
19512   else
19513
19514 { echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
19515 echo $ECHO_N "checking for ldap_bind in -lwldap32... $ECHO_C" >&6; }
19516 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
19517   echo $ECHO_N "(cached) $ECHO_C" >&6
19518 else
19519   ac_check_lib_save_LIBS=$LIBS
19520 LIBS="-lwldap32  $LIBS"
19521 cat >conftest.$ac_ext <<_ACEOF
19522 /* confdefs.h.  */
19523 _ACEOF
19524 cat confdefs.h >>conftest.$ac_ext
19525 cat >>conftest.$ac_ext <<_ACEOF
19526 /* end confdefs.h.  */
19527
19528 /* Override any GCC internal prototype to avoid an error.
19529    Use char because int might match the return type of a GCC
19530    builtin and then its argument prototype would still apply.  */
19531 #ifdef __cplusplus
19532 extern "C"
19533 #endif
19534 char ldap_bind ();
19535 int
19536 main ()
19537 {
19538 return ldap_bind ();
19539   ;
19540   return 0;
19541 }
19542 _ACEOF
19543 rm -f conftest.$ac_objext conftest$ac_exeext
19544 if { (ac_try="$ac_link"
19545 case "(($ac_try" in
19546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19547   *) ac_try_echo=$ac_try;;
19548 esac
19549 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19550   (eval "$ac_link") 2>conftest.er1
19551   ac_status=$?
19552   grep -v '^ *+' conftest.er1 >conftest.err
19553   rm -f conftest.er1
19554   cat conftest.err >&5
19555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19556   (exit $ac_status); } && {
19557          test -z "$ac_c_werror_flag" ||
19558          test ! -s conftest.err
19559        } && test -s conftest$ac_exeext &&
19560        $as_test_x conftest$ac_exeext; then
19561   ac_cv_lib_wldap32_ldap_bind=yes
19562 else
19563   echo "$as_me: failed program was:" >&5
19564 sed 's/^/| /' conftest.$ac_ext >&5
19565
19566         ac_cv_lib_wldap32_ldap_bind=no
19567 fi
19568
19569 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19570       conftest$ac_exeext conftest.$ac_ext
19571 LIBS=$ac_check_lib_save_LIBS
19572 fi
19573 { echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
19574 echo "${ECHO_T}$ac_cv_lib_wldap32_ldap_bind" >&6; }
19575 if test $ac_cv_lib_wldap32_ldap_bind = yes; then
19576   cat >>confdefs.h <<_ACEOF
19577 #define HAVE_LIBWLDAP32 1
19578 _ACEOF
19579
19580   LIBS="-lwldap32 $LIBS"
19581
19582 else
19583   { { echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
19584 echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
19585    { (exit 1); exit 1; }; }
19586 fi
19587
19588     LDAP_LIBS_FE="-lwldap32"
19589     LDAP_LIBS_BE="-lwldap32"
19590   fi
19591   LIBS="$_LIBS"
19592 fi
19593
19594
19595
19596
19597 # This test makes sure that run tests work at all.  Sometimes a shared
19598 # library is found by the linker, but the runtime linker can't find it.
19599 # This check should come after all modifications of compiler or linker
19600 # variables, and before any other run tests.
19601 { echo "$as_me:$LINENO: checking test program" >&5
19602 echo $ECHO_N "checking test program... $ECHO_C" >&6; }
19603 if test "$cross_compiling" = yes; then
19604   { echo "$as_me:$LINENO: result: cross-compiling" >&5
19605 echo "${ECHO_T}cross-compiling" >&6; }
19606 else
19607   cat >conftest.$ac_ext <<_ACEOF
19608 /* confdefs.h.  */
19609 _ACEOF
19610 cat confdefs.h >>conftest.$ac_ext
19611 cat >>conftest.$ac_ext <<_ACEOF
19612 /* end confdefs.h.  */
19613 int main() { return 0; }
19614 _ACEOF
19615 rm -f conftest$ac_exeext
19616 if { (ac_try="$ac_link"
19617 case "(($ac_try" in
19618   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19619   *) ac_try_echo=$ac_try;;
19620 esac
19621 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19622   (eval "$ac_link") 2>&5
19623   ac_status=$?
19624   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19625   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19626   { (case "(($ac_try" in
19627   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19628   *) ac_try_echo=$ac_try;;
19629 esac
19630 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19631   (eval "$ac_try") 2>&5
19632   ac_status=$?
19633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19634   (exit $ac_status); }; }; then
19635   { echo "$as_me:$LINENO: result: ok" >&5
19636 echo "${ECHO_T}ok" >&6; }
19637 else
19638   echo "$as_me: program exited with status $ac_status" >&5
19639 echo "$as_me: failed program was:" >&5
19640 sed 's/^/| /' conftest.$ac_ext >&5
19641
19642 ( exit $ac_status )
19643 { echo "$as_me:$LINENO: result: failed" >&5
19644 echo "${ECHO_T}failed" >&6; }
19645 { { echo "$as_me:$LINENO: error:
19646 Could not execute a simple test program.  This may be a problem
19647 related to locating shared libraries.  Check the file 'config.log'
19648 for the exact reason." >&5
19649 echo "$as_me: error:
19650 Could not execute a simple test program.  This may be a problem
19651 related to locating shared libraries.  Check the file 'config.log'
19652 for the exact reason." >&2;}
19653    { (exit 1); exit 1; }; }
19654 fi
19655 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19656 fi
19657
19658
19659
19660 # --------------------
19661 # Run tests below here
19662 # --------------------
19663
19664 # Force use of our snprintf if system's doesn't do arg control
19665 # See comment above at snprintf test for details.
19666 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
19667   { echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
19668 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6; }
19669 if test "${pgac_cv_printf_arg_control+set}" = set; then
19670   echo $ECHO_N "(cached) $ECHO_C" >&6
19671 else
19672   if test "$cross_compiling" = yes; then
19673   pgac_cv_printf_arg_control=cross
19674 else
19675   cat >conftest.$ac_ext <<_ACEOF
19676 /* confdefs.h.  */
19677 _ACEOF
19678 cat confdefs.h >>conftest.$ac_ext
19679 cat >>conftest.$ac_ext <<_ACEOF
19680 /* end confdefs.h.  */
19681 #include <stdio.h>
19682 #include <string.h>
19683
19684 int main()
19685 {
19686   char buf[100];
19687
19688   /* can it swap arguments? */
19689   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
19690   if (strcmp(buf, "4 3") != 0)
19691     return 1;
19692   return 0;
19693 }
19694 _ACEOF
19695 rm -f conftest$ac_exeext
19696 if { (ac_try="$ac_link"
19697 case "(($ac_try" in
19698   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19699   *) ac_try_echo=$ac_try;;
19700 esac
19701 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19702   (eval "$ac_link") 2>&5
19703   ac_status=$?
19704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19705   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19706   { (case "(($ac_try" in
19707   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19708   *) ac_try_echo=$ac_try;;
19709 esac
19710 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19711   (eval "$ac_try") 2>&5
19712   ac_status=$?
19713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19714   (exit $ac_status); }; }; then
19715   pgac_cv_printf_arg_control=yes
19716 else
19717   echo "$as_me: program exited with status $ac_status" >&5
19718 echo "$as_me: failed program was:" >&5
19719 sed 's/^/| /' conftest.$ac_ext >&5
19720
19721 ( exit $ac_status )
19722 pgac_cv_printf_arg_control=no
19723 fi
19724 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19725 fi
19726
19727
19728
19729 fi
19730 { echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
19731 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6; }
19732
19733   if test $pgac_cv_printf_arg_control != yes ; then
19734     pgac_need_repl_snprintf=yes
19735   fi
19736 fi
19737
19738
19739
19740 { echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
19741 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6; }
19742 if test "${pgac_cv_type_long_int_64+set}" = set; then
19743   echo $ECHO_N "(cached) $ECHO_C" >&6
19744 else
19745   if test "$cross_compiling" = yes; then
19746   # If cross-compiling, check the size reported by the compiler and
19747 # trust that the arithmetic works.
19748 cat >conftest.$ac_ext <<_ACEOF
19749 /* confdefs.h.  */
19750 _ACEOF
19751 cat confdefs.h >>conftest.$ac_ext
19752 cat >>conftest.$ac_ext <<_ACEOF
19753 /* end confdefs.h.  */
19754
19755 int
19756 main ()
19757 {
19758 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
19759 test_array [0] = 0
19760
19761   ;
19762   return 0;
19763 }
19764 _ACEOF
19765 rm -f conftest.$ac_objext
19766 if { (ac_try="$ac_compile"
19767 case "(($ac_try" in
19768   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19769   *) ac_try_echo=$ac_try;;
19770 esac
19771 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19772   (eval "$ac_compile") 2>conftest.er1
19773   ac_status=$?
19774   grep -v '^ *+' conftest.er1 >conftest.err
19775   rm -f conftest.er1
19776   cat conftest.err >&5
19777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19778   (exit $ac_status); } && {
19779          test -z "$ac_c_werror_flag" ||
19780          test ! -s conftest.err
19781        } && test -s conftest.$ac_objext; then
19782   pgac_cv_type_long_int_64=yes
19783 else
19784   echo "$as_me: failed program was:" >&5
19785 sed 's/^/| /' conftest.$ac_ext >&5
19786
19787         pgac_cv_type_long_int_64=no
19788 fi
19789
19790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19791 else
19792   cat >conftest.$ac_ext <<_ACEOF
19793 /* confdefs.h.  */
19794 _ACEOF
19795 cat confdefs.h >>conftest.$ac_ext
19796 cat >>conftest.$ac_ext <<_ACEOF
19797 /* end confdefs.h.  */
19798 typedef long int ac_int64;
19799
19800 /*
19801  * These are globals to discourage the compiler from folding all the
19802  * arithmetic tests down to compile-time constants.
19803  */
19804 ac_int64 a = 20000001;
19805 ac_int64 b = 40000005;
19806
19807 int does_int64_work()
19808 {
19809   ac_int64 c,d;
19810
19811   if (sizeof(ac_int64) != 8)
19812     return 0;                   /* definitely not the right size */
19813
19814   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
19815   c = a * b;
19816   d = (c + b) / b;
19817   if (d != a+1)
19818     return 0;
19819   return 1;
19820 }
19821 main() {
19822   exit(! does_int64_work());
19823 }
19824 _ACEOF
19825 rm -f conftest$ac_exeext
19826 if { (ac_try="$ac_link"
19827 case "(($ac_try" in
19828   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19829   *) ac_try_echo=$ac_try;;
19830 esac
19831 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19832   (eval "$ac_link") 2>&5
19833   ac_status=$?
19834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19835   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19836   { (case "(($ac_try" in
19837   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19838   *) ac_try_echo=$ac_try;;
19839 esac
19840 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19841   (eval "$ac_try") 2>&5
19842   ac_status=$?
19843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19844   (exit $ac_status); }; }; then
19845   pgac_cv_type_long_int_64=yes
19846 else
19847   echo "$as_me: program exited with status $ac_status" >&5
19848 echo "$as_me: failed program was:" >&5
19849 sed 's/^/| /' conftest.$ac_ext >&5
19850
19851 ( exit $ac_status )
19852 pgac_cv_type_long_int_64=no
19853 fi
19854 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19855 fi
19856
19857
19858 fi
19859 { echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
19860 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6; }
19861
19862 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
19863 if test x"$pgac_cv_type_long_int_64" = xyes ; then
19864
19865 cat >>confdefs.h <<\_ACEOF
19866 #define HAVE_LONG_INT_64 1
19867 _ACEOF
19868
19869 fi
19870
19871
19872 if test x"$HAVE_LONG_INT_64" = x"no" ; then
19873   { echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
19874 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6; }
19875 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
19876   echo $ECHO_N "(cached) $ECHO_C" >&6
19877 else
19878   if test "$cross_compiling" = yes; then
19879   # If cross-compiling, check the size reported by the compiler and
19880 # trust that the arithmetic works.
19881 cat >conftest.$ac_ext <<_ACEOF
19882 /* confdefs.h.  */
19883 _ACEOF
19884 cat confdefs.h >>conftest.$ac_ext
19885 cat >>conftest.$ac_ext <<_ACEOF
19886 /* end confdefs.h.  */
19887
19888 int
19889 main ()
19890 {
19891 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
19892 test_array [0] = 0
19893
19894   ;
19895   return 0;
19896 }
19897 _ACEOF
19898 rm -f conftest.$ac_objext
19899 if { (ac_try="$ac_compile"
19900 case "(($ac_try" in
19901   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19902   *) ac_try_echo=$ac_try;;
19903 esac
19904 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19905   (eval "$ac_compile") 2>conftest.er1
19906   ac_status=$?
19907   grep -v '^ *+' conftest.er1 >conftest.err
19908   rm -f conftest.er1
19909   cat conftest.err >&5
19910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19911   (exit $ac_status); } && {
19912          test -z "$ac_c_werror_flag" ||
19913          test ! -s conftest.err
19914        } && test -s conftest.$ac_objext; then
19915   pgac_cv_type_long_long_int_64=yes
19916 else
19917   echo "$as_me: failed program was:" >&5
19918 sed 's/^/| /' conftest.$ac_ext >&5
19919
19920         pgac_cv_type_long_long_int_64=no
19921 fi
19922
19923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19924 else
19925   cat >conftest.$ac_ext <<_ACEOF
19926 /* confdefs.h.  */
19927 _ACEOF
19928 cat confdefs.h >>conftest.$ac_ext
19929 cat >>conftest.$ac_ext <<_ACEOF
19930 /* end confdefs.h.  */
19931 typedef long long int ac_int64;
19932
19933 /*
19934  * These are globals to discourage the compiler from folding all the
19935  * arithmetic tests down to compile-time constants.
19936  */
19937 ac_int64 a = 20000001;
19938 ac_int64 b = 40000005;
19939
19940 int does_int64_work()
19941 {
19942   ac_int64 c,d;
19943
19944   if (sizeof(ac_int64) != 8)
19945     return 0;                   /* definitely not the right size */
19946
19947   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
19948   c = a * b;
19949   d = (c + b) / b;
19950   if (d != a+1)
19951     return 0;
19952   return 1;
19953 }
19954 main() {
19955   exit(! does_int64_work());
19956 }
19957 _ACEOF
19958 rm -f conftest$ac_exeext
19959 if { (ac_try="$ac_link"
19960 case "(($ac_try" in
19961   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19962   *) ac_try_echo=$ac_try;;
19963 esac
19964 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19965   (eval "$ac_link") 2>&5
19966   ac_status=$?
19967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19968   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19969   { (case "(($ac_try" in
19970   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19971   *) ac_try_echo=$ac_try;;
19972 esac
19973 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19974   (eval "$ac_try") 2>&5
19975   ac_status=$?
19976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19977   (exit $ac_status); }; }; then
19978   pgac_cv_type_long_long_int_64=yes
19979 else
19980   echo "$as_me: program exited with status $ac_status" >&5
19981 echo "$as_me: failed program was:" >&5
19982 sed 's/^/| /' conftest.$ac_ext >&5
19983
19984 ( exit $ac_status )
19985 pgac_cv_type_long_long_int_64=no
19986 fi
19987 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19988 fi
19989
19990
19991 fi
19992 { echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
19993 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6; }
19994
19995 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
19996 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
19997
19998 cat >>confdefs.h <<\_ACEOF
19999 #define HAVE_LONG_LONG_INT_64 1
20000 _ACEOF
20001
20002 fi
20003
20004 fi
20005
20006
20007
20008 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
20009   cat >conftest.$ac_ext <<_ACEOF
20010 /* confdefs.h.  */
20011 _ACEOF
20012 cat confdefs.h >>conftest.$ac_ext
20013 cat >>conftest.$ac_ext <<_ACEOF
20014 /* end confdefs.h.  */
20015
20016 #define INT64CONST(x)  x##LL
20017 long long int foo = INT64CONST(0x1234567890123456);
20018
20019 int
20020 main ()
20021 {
20022
20023   ;
20024   return 0;
20025 }
20026 _ACEOF
20027 rm -f conftest.$ac_objext
20028 if { (ac_try="$ac_compile"
20029 case "(($ac_try" in
20030   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20031   *) ac_try_echo=$ac_try;;
20032 esac
20033 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20034   (eval "$ac_compile") 2>conftest.er1
20035   ac_status=$?
20036   grep -v '^ *+' conftest.er1 >conftest.err
20037   rm -f conftest.er1
20038   cat conftest.err >&5
20039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20040   (exit $ac_status); } && {
20041          test -z "$ac_c_werror_flag" ||
20042          test ! -s conftest.err
20043        } && test -s conftest.$ac_objext; then
20044
20045 cat >>confdefs.h <<\_ACEOF
20046 #define HAVE_LL_CONSTANTS 1
20047 _ACEOF
20048
20049 else
20050   echo "$as_me: failed program was:" >&5
20051 sed 's/^/| /' conftest.$ac_ext >&5
20052
20053
20054 fi
20055
20056 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20057 fi
20058
20059
20060 # If we found "long int" is 64 bits, assume snprintf handles it.  If
20061 # we found we need to use "long long int", better check.  We cope with
20062 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
20063 # work, fall back to our own snprintf emulation (which we know uses %lld).
20064
20065 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
20066   if test $pgac_need_repl_snprintf = no; then
20067     { echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
20068 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6; }
20069 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
20070   echo $ECHO_N "(cached) $ECHO_C" >&6
20071 else
20072   for pgac_format in '%lld' '%qd' '%I64d'; do
20073 if test "$cross_compiling" = yes; then
20074   pgac_cv_snprintf_long_long_int_format=cross; break
20075 else
20076   cat >conftest.$ac_ext <<_ACEOF
20077 /* confdefs.h.  */
20078 _ACEOF
20079 cat confdefs.h >>conftest.$ac_ext
20080 cat >>conftest.$ac_ext <<_ACEOF
20081 /* end confdefs.h.  */
20082 #include <stdio.h>
20083 typedef long long int ac_int64;
20084 #define INT64_FORMAT "$pgac_format"
20085
20086 ac_int64 a = 20000001;
20087 ac_int64 b = 40000005;
20088
20089 int does_int64_snprintf_work()
20090 {
20091   ac_int64 c;
20092   char buf[100];
20093
20094   if (sizeof(ac_int64) != 8)
20095     return 0;                   /* doesn't look like the right size */
20096
20097   c = a * b;
20098   snprintf(buf, 100, INT64_FORMAT, c);
20099   if (strcmp(buf, "800000140000005") != 0)
20100     return 0;                   /* either multiply or snprintf is busted */
20101   return 1;
20102 }
20103 main() {
20104   exit(! does_int64_snprintf_work());
20105 }
20106 _ACEOF
20107 rm -f conftest$ac_exeext
20108 if { (ac_try="$ac_link"
20109 case "(($ac_try" in
20110   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20111   *) ac_try_echo=$ac_try;;
20112 esac
20113 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20114   (eval "$ac_link") 2>&5
20115   ac_status=$?
20116   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20117   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20118   { (case "(($ac_try" in
20119   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20120   *) ac_try_echo=$ac_try;;
20121 esac
20122 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20123   (eval "$ac_try") 2>&5
20124   ac_status=$?
20125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20126   (exit $ac_status); }; }; then
20127   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
20128 else
20129   echo "$as_me: program exited with status $ac_status" >&5
20130 echo "$as_me: failed program was:" >&5
20131 sed 's/^/| /' conftest.$ac_ext >&5
20132
20133 fi
20134 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20135 fi
20136
20137
20138 done
20139 fi
20140
20141 LONG_LONG_INT_FORMAT=''
20142
20143 case $pgac_cv_snprintf_long_long_int_format in
20144   cross) { echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
20145 echo "${ECHO_T}cannot test (not on host machine)" >&6; };;
20146   ?*)    { echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
20147 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6; }
20148          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
20149   *)     { echo "$as_me:$LINENO: result: none" >&5
20150 echo "${ECHO_T}none" >&6; };;
20151 esac
20152     if test "$LONG_LONG_INT_FORMAT" = ""; then
20153       # Force usage of our own snprintf, since system snprintf is broken
20154       pgac_need_repl_snprintf=yes
20155       LONG_LONG_INT_FORMAT='%lld'
20156     fi
20157   else
20158     # Here if we previously decided we needed to use our own snprintf
20159     LONG_LONG_INT_FORMAT='%lld'
20160   fi
20161   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
20162   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
20163   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
20164 else
20165   # Here if we are not using 'long long int' at all
20166   INT64_FORMAT='"%ld"'
20167   UINT64_FORMAT='"%lu"'
20168 fi
20169
20170
20171 cat >>confdefs.h <<_ACEOF
20172 #define INT64_FORMAT $INT64_FORMAT
20173 _ACEOF
20174
20175
20176
20177 cat >>confdefs.h <<_ACEOF
20178 #define UINT64_FORMAT $UINT64_FORMAT
20179 _ACEOF
20180
20181
20182 # Now we have checked all the reasons to replace snprintf
20183 if test $pgac_need_repl_snprintf = yes; then
20184
20185 cat >>confdefs.h <<\_ACEOF
20186 #define USE_REPL_SNPRINTF 1
20187 _ACEOF
20188
20189   case " $LIBOBJS " in
20190   *" snprintf.$ac_objext "* ) ;;
20191   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20192  ;;
20193 esac
20194
20195 fi
20196
20197 # Need a #define for the size of Datum (unsigned long)
20198 { echo "$as_me:$LINENO: checking for unsigned long" >&5
20199 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6; }
20200 if test "${ac_cv_type_unsigned_long+set}" = set; then
20201   echo $ECHO_N "(cached) $ECHO_C" >&6
20202 else
20203   cat >conftest.$ac_ext <<_ACEOF
20204 /* confdefs.h.  */
20205 _ACEOF
20206 cat confdefs.h >>conftest.$ac_ext
20207 cat >>conftest.$ac_ext <<_ACEOF
20208 /* end confdefs.h.  */
20209 $ac_includes_default
20210 typedef unsigned long ac__type_new_;
20211 int
20212 main ()
20213 {
20214 if ((ac__type_new_ *) 0)
20215   return 0;
20216 if (sizeof (ac__type_new_))
20217   return 0;
20218   ;
20219   return 0;
20220 }
20221 _ACEOF
20222 rm -f conftest.$ac_objext
20223 if { (ac_try="$ac_compile"
20224 case "(($ac_try" in
20225   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20226   *) ac_try_echo=$ac_try;;
20227 esac
20228 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20229   (eval "$ac_compile") 2>conftest.er1
20230   ac_status=$?
20231   grep -v '^ *+' conftest.er1 >conftest.err
20232   rm -f conftest.er1
20233   cat conftest.err >&5
20234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20235   (exit $ac_status); } && {
20236          test -z "$ac_c_werror_flag" ||
20237          test ! -s conftest.err
20238        } && test -s conftest.$ac_objext; then
20239   ac_cv_type_unsigned_long=yes
20240 else
20241   echo "$as_me: failed program was:" >&5
20242 sed 's/^/| /' conftest.$ac_ext >&5
20243
20244         ac_cv_type_unsigned_long=no
20245 fi
20246
20247 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20248 fi
20249 { echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
20250 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6; }
20251
20252 # The cast to long int works around a bug in the HP C Compiler
20253 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20254 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20255 # This bug is HP SR number 8606223364.
20256 { echo "$as_me:$LINENO: checking size of unsigned long" >&5
20257 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6; }
20258 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
20259   echo $ECHO_N "(cached) $ECHO_C" >&6
20260 else
20261   if test "$cross_compiling" = yes; then
20262   # Depending upon the size, compute the lo and hi bounds.
20263 cat >conftest.$ac_ext <<_ACEOF
20264 /* confdefs.h.  */
20265 _ACEOF
20266 cat confdefs.h >>conftest.$ac_ext
20267 cat >>conftest.$ac_ext <<_ACEOF
20268 /* end confdefs.h.  */
20269 $ac_includes_default
20270    typedef unsigned long ac__type_sizeof_;
20271 int
20272 main ()
20273 {
20274 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
20275 test_array [0] = 0
20276
20277   ;
20278   return 0;
20279 }
20280 _ACEOF
20281 rm -f conftest.$ac_objext
20282 if { (ac_try="$ac_compile"
20283 case "(($ac_try" in
20284   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20285   *) ac_try_echo=$ac_try;;
20286 esac
20287 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20288   (eval "$ac_compile") 2>conftest.er1
20289   ac_status=$?
20290   grep -v '^ *+' conftest.er1 >conftest.err
20291   rm -f conftest.er1
20292   cat conftest.err >&5
20293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20294   (exit $ac_status); } && {
20295          test -z "$ac_c_werror_flag" ||
20296          test ! -s conftest.err
20297        } && test -s conftest.$ac_objext; then
20298   ac_lo=0 ac_mid=0
20299   while :; do
20300     cat >conftest.$ac_ext <<_ACEOF
20301 /* confdefs.h.  */
20302 _ACEOF
20303 cat confdefs.h >>conftest.$ac_ext
20304 cat >>conftest.$ac_ext <<_ACEOF
20305 /* end confdefs.h.  */
20306 $ac_includes_default
20307    typedef unsigned long ac__type_sizeof_;
20308 int
20309 main ()
20310 {
20311 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20312 test_array [0] = 0
20313
20314   ;
20315   return 0;
20316 }
20317 _ACEOF
20318 rm -f conftest.$ac_objext
20319 if { (ac_try="$ac_compile"
20320 case "(($ac_try" in
20321   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20322   *) ac_try_echo=$ac_try;;
20323 esac
20324 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20325   (eval "$ac_compile") 2>conftest.er1
20326   ac_status=$?
20327   grep -v '^ *+' conftest.er1 >conftest.err
20328   rm -f conftest.er1
20329   cat conftest.err >&5
20330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20331   (exit $ac_status); } && {
20332          test -z "$ac_c_werror_flag" ||
20333          test ! -s conftest.err
20334        } && test -s conftest.$ac_objext; then
20335   ac_hi=$ac_mid; break
20336 else
20337   echo "$as_me: failed program was:" >&5
20338 sed 's/^/| /' conftest.$ac_ext >&5
20339
20340         ac_lo=`expr $ac_mid + 1`
20341                         if test $ac_lo -le $ac_mid; then
20342                           ac_lo= ac_hi=
20343                           break
20344                         fi
20345                         ac_mid=`expr 2 '*' $ac_mid + 1`
20346 fi
20347
20348 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20349   done
20350 else
20351   echo "$as_me: failed program was:" >&5
20352 sed 's/^/| /' conftest.$ac_ext >&5
20353
20354         cat >conftest.$ac_ext <<_ACEOF
20355 /* confdefs.h.  */
20356 _ACEOF
20357 cat confdefs.h >>conftest.$ac_ext
20358 cat >>conftest.$ac_ext <<_ACEOF
20359 /* end confdefs.h.  */
20360 $ac_includes_default
20361    typedef unsigned long ac__type_sizeof_;
20362 int
20363 main ()
20364 {
20365 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
20366 test_array [0] = 0
20367
20368   ;
20369   return 0;
20370 }
20371 _ACEOF
20372 rm -f conftest.$ac_objext
20373 if { (ac_try="$ac_compile"
20374 case "(($ac_try" in
20375   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20376   *) ac_try_echo=$ac_try;;
20377 esac
20378 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20379   (eval "$ac_compile") 2>conftest.er1
20380   ac_status=$?
20381   grep -v '^ *+' conftest.er1 >conftest.err
20382   rm -f conftest.er1
20383   cat conftest.err >&5
20384   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20385   (exit $ac_status); } && {
20386          test -z "$ac_c_werror_flag" ||
20387          test ! -s conftest.err
20388        } && test -s conftest.$ac_objext; then
20389   ac_hi=-1 ac_mid=-1
20390   while :; do
20391     cat >conftest.$ac_ext <<_ACEOF
20392 /* confdefs.h.  */
20393 _ACEOF
20394 cat confdefs.h >>conftest.$ac_ext
20395 cat >>conftest.$ac_ext <<_ACEOF
20396 /* end confdefs.h.  */
20397 $ac_includes_default
20398    typedef unsigned long ac__type_sizeof_;
20399 int
20400 main ()
20401 {
20402 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
20403 test_array [0] = 0
20404
20405   ;
20406   return 0;
20407 }
20408 _ACEOF
20409 rm -f conftest.$ac_objext
20410 if { (ac_try="$ac_compile"
20411 case "(($ac_try" in
20412   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20413   *) ac_try_echo=$ac_try;;
20414 esac
20415 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20416   (eval "$ac_compile") 2>conftest.er1
20417   ac_status=$?
20418   grep -v '^ *+' conftest.er1 >conftest.err
20419   rm -f conftest.er1
20420   cat conftest.err >&5
20421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20422   (exit $ac_status); } && {
20423          test -z "$ac_c_werror_flag" ||
20424          test ! -s conftest.err
20425        } && test -s conftest.$ac_objext; then
20426   ac_lo=$ac_mid; break
20427 else
20428   echo "$as_me: failed program was:" >&5
20429 sed 's/^/| /' conftest.$ac_ext >&5
20430
20431         ac_hi=`expr '(' $ac_mid ')' - 1`
20432                         if test $ac_mid -le $ac_hi; then
20433                           ac_lo= ac_hi=
20434                           break
20435                         fi
20436                         ac_mid=`expr 2 '*' $ac_mid`
20437 fi
20438
20439 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20440   done
20441 else
20442   echo "$as_me: failed program was:" >&5
20443 sed 's/^/| /' conftest.$ac_ext >&5
20444
20445         ac_lo= ac_hi=
20446 fi
20447
20448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20449 fi
20450
20451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20452 # Binary search between lo and hi bounds.
20453 while test "x$ac_lo" != "x$ac_hi"; do
20454   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20455   cat >conftest.$ac_ext <<_ACEOF
20456 /* confdefs.h.  */
20457 _ACEOF
20458 cat confdefs.h >>conftest.$ac_ext
20459 cat >>conftest.$ac_ext <<_ACEOF
20460 /* end confdefs.h.  */
20461 $ac_includes_default
20462    typedef unsigned long ac__type_sizeof_;
20463 int
20464 main ()
20465 {
20466 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20467 test_array [0] = 0
20468
20469   ;
20470   return 0;
20471 }
20472 _ACEOF
20473 rm -f conftest.$ac_objext
20474 if { (ac_try="$ac_compile"
20475 case "(($ac_try" in
20476   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20477   *) ac_try_echo=$ac_try;;
20478 esac
20479 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20480   (eval "$ac_compile") 2>conftest.er1
20481   ac_status=$?
20482   grep -v '^ *+' conftest.er1 >conftest.err
20483   rm -f conftest.er1
20484   cat conftest.err >&5
20485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20486   (exit $ac_status); } && {
20487          test -z "$ac_c_werror_flag" ||
20488          test ! -s conftest.err
20489        } && test -s conftest.$ac_objext; then
20490   ac_hi=$ac_mid
20491 else
20492   echo "$as_me: failed program was:" >&5
20493 sed 's/^/| /' conftest.$ac_ext >&5
20494
20495         ac_lo=`expr '(' $ac_mid ')' + 1`
20496 fi
20497
20498 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20499 done
20500 case $ac_lo in
20501 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
20502 '') if test "$ac_cv_type_unsigned_long" = yes; then
20503      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
20504 See \`config.log' for more details." >&5
20505 echo "$as_me: error: cannot compute sizeof (unsigned long)
20506 See \`config.log' for more details." >&2;}
20507    { (exit 77); exit 77; }; }
20508    else
20509      ac_cv_sizeof_unsigned_long=0
20510    fi ;;
20511 esac
20512 else
20513   cat >conftest.$ac_ext <<_ACEOF
20514 /* confdefs.h.  */
20515 _ACEOF
20516 cat confdefs.h >>conftest.$ac_ext
20517 cat >>conftest.$ac_ext <<_ACEOF
20518 /* end confdefs.h.  */
20519 $ac_includes_default
20520    typedef unsigned long ac__type_sizeof_;
20521 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
20522 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
20523 #include <stdio.h>
20524 #include <stdlib.h>
20525 int
20526 main ()
20527 {
20528
20529   FILE *f = fopen ("conftest.val", "w");
20530   if (! f)
20531     return 1;
20532   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
20533     {
20534       long int i = longval ();
20535       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20536         return 1;
20537       fprintf (f, "%ld\n", i);
20538     }
20539   else
20540     {
20541       unsigned long int i = ulongval ();
20542       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20543         return 1;
20544       fprintf (f, "%lu\n", i);
20545     }
20546   return ferror (f) || fclose (f) != 0;
20547
20548   ;
20549   return 0;
20550 }
20551 _ACEOF
20552 rm -f conftest$ac_exeext
20553 if { (ac_try="$ac_link"
20554 case "(($ac_try" in
20555   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20556   *) ac_try_echo=$ac_try;;
20557 esac
20558 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20559   (eval "$ac_link") 2>&5
20560   ac_status=$?
20561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20562   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20563   { (case "(($ac_try" in
20564   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20565   *) ac_try_echo=$ac_try;;
20566 esac
20567 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20568   (eval "$ac_try") 2>&5
20569   ac_status=$?
20570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20571   (exit $ac_status); }; }; then
20572   ac_cv_sizeof_unsigned_long=`cat conftest.val`
20573 else
20574   echo "$as_me: program exited with status $ac_status" >&5
20575 echo "$as_me: failed program was:" >&5
20576 sed 's/^/| /' conftest.$ac_ext >&5
20577
20578 ( exit $ac_status )
20579 if test "$ac_cv_type_unsigned_long" = yes; then
20580      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
20581 See \`config.log' for more details." >&5
20582 echo "$as_me: error: cannot compute sizeof (unsigned long)
20583 See \`config.log' for more details." >&2;}
20584    { (exit 77); exit 77; }; }
20585    else
20586      ac_cv_sizeof_unsigned_long=0
20587    fi
20588 fi
20589 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20590 fi
20591 rm -f conftest.val
20592 fi
20593 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
20594 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6; }
20595
20596
20597
20598 cat >>confdefs.h <<_ACEOF
20599 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
20600 _ACEOF
20601
20602
20603
20604 # And one for the size of size_t (enables tweaks for > 32bit address space)
20605 { echo "$as_me:$LINENO: checking for size_t" >&5
20606 echo $ECHO_N "checking for size_t... $ECHO_C" >&6; }
20607 if test "${ac_cv_type_size_t+set}" = set; then
20608   echo $ECHO_N "(cached) $ECHO_C" >&6
20609 else
20610   cat >conftest.$ac_ext <<_ACEOF
20611 /* confdefs.h.  */
20612 _ACEOF
20613 cat confdefs.h >>conftest.$ac_ext
20614 cat >>conftest.$ac_ext <<_ACEOF
20615 /* end confdefs.h.  */
20616 $ac_includes_default
20617 typedef size_t ac__type_new_;
20618 int
20619 main ()
20620 {
20621 if ((ac__type_new_ *) 0)
20622   return 0;
20623 if (sizeof (ac__type_new_))
20624   return 0;
20625   ;
20626   return 0;
20627 }
20628 _ACEOF
20629 rm -f conftest.$ac_objext
20630 if { (ac_try="$ac_compile"
20631 case "(($ac_try" in
20632   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20633   *) ac_try_echo=$ac_try;;
20634 esac
20635 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20636   (eval "$ac_compile") 2>conftest.er1
20637   ac_status=$?
20638   grep -v '^ *+' conftest.er1 >conftest.err
20639   rm -f conftest.er1
20640   cat conftest.err >&5
20641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20642   (exit $ac_status); } && {
20643          test -z "$ac_c_werror_flag" ||
20644          test ! -s conftest.err
20645        } && test -s conftest.$ac_objext; then
20646   ac_cv_type_size_t=yes
20647 else
20648   echo "$as_me: failed program was:" >&5
20649 sed 's/^/| /' conftest.$ac_ext >&5
20650
20651         ac_cv_type_size_t=no
20652 fi
20653
20654 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20655 fi
20656 { echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
20657 echo "${ECHO_T}$ac_cv_type_size_t" >&6; }
20658
20659 # The cast to long int works around a bug in the HP C Compiler
20660 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20661 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20662 # This bug is HP SR number 8606223364.
20663 { echo "$as_me:$LINENO: checking size of size_t" >&5
20664 echo $ECHO_N "checking size of size_t... $ECHO_C" >&6; }
20665 if test "${ac_cv_sizeof_size_t+set}" = set; then
20666   echo $ECHO_N "(cached) $ECHO_C" >&6
20667 else
20668   if test "$cross_compiling" = yes; then
20669   # Depending upon the size, compute the lo and hi bounds.
20670 cat >conftest.$ac_ext <<_ACEOF
20671 /* confdefs.h.  */
20672 _ACEOF
20673 cat confdefs.h >>conftest.$ac_ext
20674 cat >>conftest.$ac_ext <<_ACEOF
20675 /* end confdefs.h.  */
20676 $ac_includes_default
20677    typedef size_t ac__type_sizeof_;
20678 int
20679 main ()
20680 {
20681 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
20682 test_array [0] = 0
20683
20684   ;
20685   return 0;
20686 }
20687 _ACEOF
20688 rm -f conftest.$ac_objext
20689 if { (ac_try="$ac_compile"
20690 case "(($ac_try" in
20691   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20692   *) ac_try_echo=$ac_try;;
20693 esac
20694 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20695   (eval "$ac_compile") 2>conftest.er1
20696   ac_status=$?
20697   grep -v '^ *+' conftest.er1 >conftest.err
20698   rm -f conftest.er1
20699   cat conftest.err >&5
20700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20701   (exit $ac_status); } && {
20702          test -z "$ac_c_werror_flag" ||
20703          test ! -s conftest.err
20704        } && test -s conftest.$ac_objext; then
20705   ac_lo=0 ac_mid=0
20706   while :; do
20707     cat >conftest.$ac_ext <<_ACEOF
20708 /* confdefs.h.  */
20709 _ACEOF
20710 cat confdefs.h >>conftest.$ac_ext
20711 cat >>conftest.$ac_ext <<_ACEOF
20712 /* end confdefs.h.  */
20713 $ac_includes_default
20714    typedef size_t ac__type_sizeof_;
20715 int
20716 main ()
20717 {
20718 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20719 test_array [0] = 0
20720
20721   ;
20722   return 0;
20723 }
20724 _ACEOF
20725 rm -f conftest.$ac_objext
20726 if { (ac_try="$ac_compile"
20727 case "(($ac_try" in
20728   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20729   *) ac_try_echo=$ac_try;;
20730 esac
20731 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20732   (eval "$ac_compile") 2>conftest.er1
20733   ac_status=$?
20734   grep -v '^ *+' conftest.er1 >conftest.err
20735   rm -f conftest.er1
20736   cat conftest.err >&5
20737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20738   (exit $ac_status); } && {
20739          test -z "$ac_c_werror_flag" ||
20740          test ! -s conftest.err
20741        } && test -s conftest.$ac_objext; then
20742   ac_hi=$ac_mid; break
20743 else
20744   echo "$as_me: failed program was:" >&5
20745 sed 's/^/| /' conftest.$ac_ext >&5
20746
20747         ac_lo=`expr $ac_mid + 1`
20748                         if test $ac_lo -le $ac_mid; then
20749                           ac_lo= ac_hi=
20750                           break
20751                         fi
20752                         ac_mid=`expr 2 '*' $ac_mid + 1`
20753 fi
20754
20755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20756   done
20757 else
20758   echo "$as_me: failed program was:" >&5
20759 sed 's/^/| /' conftest.$ac_ext >&5
20760
20761         cat >conftest.$ac_ext <<_ACEOF
20762 /* confdefs.h.  */
20763 _ACEOF
20764 cat confdefs.h >>conftest.$ac_ext
20765 cat >>conftest.$ac_ext <<_ACEOF
20766 /* end confdefs.h.  */
20767 $ac_includes_default
20768    typedef size_t ac__type_sizeof_;
20769 int
20770 main ()
20771 {
20772 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
20773 test_array [0] = 0
20774
20775   ;
20776   return 0;
20777 }
20778 _ACEOF
20779 rm -f conftest.$ac_objext
20780 if { (ac_try="$ac_compile"
20781 case "(($ac_try" in
20782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20783   *) ac_try_echo=$ac_try;;
20784 esac
20785 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20786   (eval "$ac_compile") 2>conftest.er1
20787   ac_status=$?
20788   grep -v '^ *+' conftest.er1 >conftest.err
20789   rm -f conftest.er1
20790   cat conftest.err >&5
20791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20792   (exit $ac_status); } && {
20793          test -z "$ac_c_werror_flag" ||
20794          test ! -s conftest.err
20795        } && test -s conftest.$ac_objext; then
20796   ac_hi=-1 ac_mid=-1
20797   while :; do
20798     cat >conftest.$ac_ext <<_ACEOF
20799 /* confdefs.h.  */
20800 _ACEOF
20801 cat confdefs.h >>conftest.$ac_ext
20802 cat >>conftest.$ac_ext <<_ACEOF
20803 /* end confdefs.h.  */
20804 $ac_includes_default
20805    typedef size_t ac__type_sizeof_;
20806 int
20807 main ()
20808 {
20809 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
20810 test_array [0] = 0
20811
20812   ;
20813   return 0;
20814 }
20815 _ACEOF
20816 rm -f conftest.$ac_objext
20817 if { (ac_try="$ac_compile"
20818 case "(($ac_try" in
20819   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20820   *) ac_try_echo=$ac_try;;
20821 esac
20822 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20823   (eval "$ac_compile") 2>conftest.er1
20824   ac_status=$?
20825   grep -v '^ *+' conftest.er1 >conftest.err
20826   rm -f conftest.er1
20827   cat conftest.err >&5
20828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20829   (exit $ac_status); } && {
20830          test -z "$ac_c_werror_flag" ||
20831          test ! -s conftest.err
20832        } && test -s conftest.$ac_objext; then
20833   ac_lo=$ac_mid; break
20834 else
20835   echo "$as_me: failed program was:" >&5
20836 sed 's/^/| /' conftest.$ac_ext >&5
20837
20838         ac_hi=`expr '(' $ac_mid ')' - 1`
20839                         if test $ac_mid -le $ac_hi; then
20840                           ac_lo= ac_hi=
20841                           break
20842                         fi
20843                         ac_mid=`expr 2 '*' $ac_mid`
20844 fi
20845
20846 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20847   done
20848 else
20849   echo "$as_me: failed program was:" >&5
20850 sed 's/^/| /' conftest.$ac_ext >&5
20851
20852         ac_lo= ac_hi=
20853 fi
20854
20855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20856 fi
20857
20858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20859 # Binary search between lo and hi bounds.
20860 while test "x$ac_lo" != "x$ac_hi"; do
20861   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20862   cat >conftest.$ac_ext <<_ACEOF
20863 /* confdefs.h.  */
20864 _ACEOF
20865 cat confdefs.h >>conftest.$ac_ext
20866 cat >>conftest.$ac_ext <<_ACEOF
20867 /* end confdefs.h.  */
20868 $ac_includes_default
20869    typedef size_t ac__type_sizeof_;
20870 int
20871 main ()
20872 {
20873 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20874 test_array [0] = 0
20875
20876   ;
20877   return 0;
20878 }
20879 _ACEOF
20880 rm -f conftest.$ac_objext
20881 if { (ac_try="$ac_compile"
20882 case "(($ac_try" in
20883   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20884   *) ac_try_echo=$ac_try;;
20885 esac
20886 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20887   (eval "$ac_compile") 2>conftest.er1
20888   ac_status=$?
20889   grep -v '^ *+' conftest.er1 >conftest.err
20890   rm -f conftest.er1
20891   cat conftest.err >&5
20892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20893   (exit $ac_status); } && {
20894          test -z "$ac_c_werror_flag" ||
20895          test ! -s conftest.err
20896        } && test -s conftest.$ac_objext; then
20897   ac_hi=$ac_mid
20898 else
20899   echo "$as_me: failed program was:" >&5
20900 sed 's/^/| /' conftest.$ac_ext >&5
20901
20902         ac_lo=`expr '(' $ac_mid ')' + 1`
20903 fi
20904
20905 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20906 done
20907 case $ac_lo in
20908 ?*) ac_cv_sizeof_size_t=$ac_lo;;
20909 '') if test "$ac_cv_type_size_t" = yes; then
20910      { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
20911 See \`config.log' for more details." >&5
20912 echo "$as_me: error: cannot compute sizeof (size_t)
20913 See \`config.log' for more details." >&2;}
20914    { (exit 77); exit 77; }; }
20915    else
20916      ac_cv_sizeof_size_t=0
20917    fi ;;
20918 esac
20919 else
20920   cat >conftest.$ac_ext <<_ACEOF
20921 /* confdefs.h.  */
20922 _ACEOF
20923 cat confdefs.h >>conftest.$ac_ext
20924 cat >>conftest.$ac_ext <<_ACEOF
20925 /* end confdefs.h.  */
20926 $ac_includes_default
20927    typedef size_t ac__type_sizeof_;
20928 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
20929 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
20930 #include <stdio.h>
20931 #include <stdlib.h>
20932 int
20933 main ()
20934 {
20935
20936   FILE *f = fopen ("conftest.val", "w");
20937   if (! f)
20938     return 1;
20939   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
20940     {
20941       long int i = longval ();
20942       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20943         return 1;
20944       fprintf (f, "%ld\n", i);
20945     }
20946   else
20947     {
20948       unsigned long int i = ulongval ();
20949       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20950         return 1;
20951       fprintf (f, "%lu\n", i);
20952     }
20953   return ferror (f) || fclose (f) != 0;
20954
20955   ;
20956   return 0;
20957 }
20958 _ACEOF
20959 rm -f conftest$ac_exeext
20960 if { (ac_try="$ac_link"
20961 case "(($ac_try" in
20962   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20963   *) ac_try_echo=$ac_try;;
20964 esac
20965 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20966   (eval "$ac_link") 2>&5
20967   ac_status=$?
20968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20969   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20970   { (case "(($ac_try" in
20971   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20972   *) ac_try_echo=$ac_try;;
20973 esac
20974 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20975   (eval "$ac_try") 2>&5
20976   ac_status=$?
20977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20978   (exit $ac_status); }; }; then
20979   ac_cv_sizeof_size_t=`cat conftest.val`
20980 else
20981   echo "$as_me: program exited with status $ac_status" >&5
20982 echo "$as_me: failed program was:" >&5
20983 sed 's/^/| /' conftest.$ac_ext >&5
20984
20985 ( exit $ac_status )
20986 if test "$ac_cv_type_size_t" = yes; then
20987      { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
20988 See \`config.log' for more details." >&5
20989 echo "$as_me: error: cannot compute sizeof (size_t)
20990 See \`config.log' for more details." >&2;}
20991    { (exit 77); exit 77; }; }
20992    else
20993      ac_cv_sizeof_size_t=0
20994    fi
20995 fi
20996 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20997 fi
20998 rm -f conftest.val
20999 fi
21000 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
21001 echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6; }
21002
21003
21004
21005 cat >>confdefs.h <<_ACEOF
21006 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
21007 _ACEOF
21008
21009
21010
21011 # Decide whether float4 is passed by value: user-selectable, enabled by default
21012 { echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
21013 echo $ECHO_N "checking whether to build with float4 passed by value... $ECHO_C" >&6; }
21014
21015 pgac_args="$pgac_args enable_float4_byval"
21016
21017 # Check whether --enable-float4-byval was given.
21018 if test "${enable_float4_byval+set}" = set; then
21019   enableval=$enable_float4_byval;
21020   case $enableval in
21021     yes)
21022
21023 cat >>confdefs.h <<\_ACEOF
21024 #define USE_FLOAT4_BYVAL 1
21025 _ACEOF
21026
21027                float4passbyval=true
21028       ;;
21029     no)
21030       float4passbyval=false
21031       ;;
21032     *)
21033       { { echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
21034 echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
21035    { (exit 1); exit 1; }; }
21036       ;;
21037   esac
21038
21039 else
21040   enable_float4_byval=yes
21041
21042 cat >>confdefs.h <<\_ACEOF
21043 #define USE_FLOAT4_BYVAL 1
21044 _ACEOF
21045
21046                float4passbyval=true
21047 fi
21048
21049
21050 { echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
21051 echo "${ECHO_T}$enable_float4_byval" >&6; }
21052
21053 cat >>confdefs.h <<_ACEOF
21054 #define FLOAT4PASSBYVAL $float4passbyval
21055 _ACEOF
21056
21057
21058 # Decide whether float8 is passed by value.
21059 # Note: this setting also controls int8 and related types such as timestamp.
21060 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
21061 # If not, trying to select it is an error.
21062 { echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
21063 echo $ECHO_N "checking whether to build with float8 passed by value... $ECHO_C" >&6; }
21064 if test $ac_cv_sizeof_unsigned_long -ge 8 ; then
21065
21066 pgac_args="$pgac_args enable_float8_byval"
21067
21068 # Check whether --enable-float8-byval was given.
21069 if test "${enable_float8_byval+set}" = set; then
21070   enableval=$enable_float8_byval;
21071   case $enableval in
21072     yes)
21073       :
21074       ;;
21075     no)
21076       :
21077       ;;
21078     *)
21079       { { echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
21080 echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
21081    { (exit 1); exit 1; }; }
21082       ;;
21083   esac
21084
21085 else
21086   enable_float8_byval=yes
21087
21088 fi
21089
21090
21091 else
21092
21093 pgac_args="$pgac_args enable_float8_byval"
21094
21095 # Check whether --enable-float8-byval was given.
21096 if test "${enable_float8_byval+set}" = set; then
21097   enableval=$enable_float8_byval;
21098   case $enableval in
21099     yes)
21100       :
21101       ;;
21102     no)
21103       :
21104       ;;
21105     *)
21106       { { echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
21107 echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
21108    { (exit 1); exit 1; }; }
21109       ;;
21110   esac
21111
21112 else
21113   enable_float8_byval=no
21114
21115 fi
21116
21117
21118   if test "$enable_float8_byval" = yes ; then
21119     { { echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
21120 echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
21121    { (exit 1); exit 1; }; }
21122   fi
21123 fi
21124 if test "$enable_float8_byval" = yes ; then
21125
21126 cat >>confdefs.h <<\_ACEOF
21127 #define USE_FLOAT8_BYVAL 1
21128 _ACEOF
21129
21130   float8passbyval=true
21131 else
21132   float8passbyval=false
21133 fi
21134 { echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
21135 echo "${ECHO_T}$enable_float8_byval" >&6; }
21136
21137 cat >>confdefs.h <<_ACEOF
21138 #define FLOAT8PASSBYVAL $float8passbyval
21139 _ACEOF
21140
21141
21142 # Determine memory alignment requirements for the basic C data types.
21143
21144 { echo "$as_me:$LINENO: checking for short" >&5
21145 echo $ECHO_N "checking for short... $ECHO_C" >&6; }
21146 if test "${ac_cv_type_short+set}" = set; then
21147   echo $ECHO_N "(cached) $ECHO_C" >&6
21148 else
21149   cat >conftest.$ac_ext <<_ACEOF
21150 /* confdefs.h.  */
21151 _ACEOF
21152 cat confdefs.h >>conftest.$ac_ext
21153 cat >>conftest.$ac_ext <<_ACEOF
21154 /* end confdefs.h.  */
21155 $ac_includes_default
21156 typedef short ac__type_new_;
21157 int
21158 main ()
21159 {
21160 if ((ac__type_new_ *) 0)
21161   return 0;
21162 if (sizeof (ac__type_new_))
21163   return 0;
21164   ;
21165   return 0;
21166 }
21167 _ACEOF
21168 rm -f conftest.$ac_objext
21169 if { (ac_try="$ac_compile"
21170 case "(($ac_try" in
21171   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21172   *) ac_try_echo=$ac_try;;
21173 esac
21174 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21175   (eval "$ac_compile") 2>conftest.er1
21176   ac_status=$?
21177   grep -v '^ *+' conftest.er1 >conftest.err
21178   rm -f conftest.er1
21179   cat conftest.err >&5
21180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21181   (exit $ac_status); } && {
21182          test -z "$ac_c_werror_flag" ||
21183          test ! -s conftest.err
21184        } && test -s conftest.$ac_objext; then
21185   ac_cv_type_short=yes
21186 else
21187   echo "$as_me: failed program was:" >&5
21188 sed 's/^/| /' conftest.$ac_ext >&5
21189
21190         ac_cv_type_short=no
21191 fi
21192
21193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21194 fi
21195 { echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
21196 echo "${ECHO_T}$ac_cv_type_short" >&6; }
21197
21198 # The cast to long int works around a bug in the HP C Compiler,
21199 # see AC_CHECK_SIZEOF for more information.
21200 { echo "$as_me:$LINENO: checking alignment of short" >&5
21201 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6; }
21202 if test "${ac_cv_alignof_short+set}" = set; then
21203   echo $ECHO_N "(cached) $ECHO_C" >&6
21204 else
21205   if test "$cross_compiling" = yes; then
21206   # Depending upon the size, compute the lo and hi bounds.
21207 cat >conftest.$ac_ext <<_ACEOF
21208 /* confdefs.h.  */
21209 _ACEOF
21210 cat confdefs.h >>conftest.$ac_ext
21211 cat >>conftest.$ac_ext <<_ACEOF
21212 /* end confdefs.h.  */
21213 $ac_includes_default
21214 #ifndef offsetof
21215 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21216 #endif
21217 typedef struct { char x; short y; } ac__type_alignof_;
21218 int
21219 main ()
21220 {
21221 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
21222 test_array [0] = 0
21223
21224   ;
21225   return 0;
21226 }
21227 _ACEOF
21228 rm -f conftest.$ac_objext
21229 if { (ac_try="$ac_compile"
21230 case "(($ac_try" in
21231   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21232   *) ac_try_echo=$ac_try;;
21233 esac
21234 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21235   (eval "$ac_compile") 2>conftest.er1
21236   ac_status=$?
21237   grep -v '^ *+' conftest.er1 >conftest.err
21238   rm -f conftest.er1
21239   cat conftest.err >&5
21240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21241   (exit $ac_status); } && {
21242          test -z "$ac_c_werror_flag" ||
21243          test ! -s conftest.err
21244        } && test -s conftest.$ac_objext; then
21245   ac_lo=0 ac_mid=0
21246   while :; do
21247     cat >conftest.$ac_ext <<_ACEOF
21248 /* confdefs.h.  */
21249 _ACEOF
21250 cat confdefs.h >>conftest.$ac_ext
21251 cat >>conftest.$ac_ext <<_ACEOF
21252 /* end confdefs.h.  */
21253 $ac_includes_default
21254 #ifndef offsetof
21255 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21256 #endif
21257 typedef struct { char x; short y; } ac__type_alignof_;
21258 int
21259 main ()
21260 {
21261 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21262 test_array [0] = 0
21263
21264   ;
21265   return 0;
21266 }
21267 _ACEOF
21268 rm -f conftest.$ac_objext
21269 if { (ac_try="$ac_compile"
21270 case "(($ac_try" in
21271   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21272   *) ac_try_echo=$ac_try;;
21273 esac
21274 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21275   (eval "$ac_compile") 2>conftest.er1
21276   ac_status=$?
21277   grep -v '^ *+' conftest.er1 >conftest.err
21278   rm -f conftest.er1
21279   cat conftest.err >&5
21280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21281   (exit $ac_status); } && {
21282          test -z "$ac_c_werror_flag" ||
21283          test ! -s conftest.err
21284        } && test -s conftest.$ac_objext; then
21285   ac_hi=$ac_mid; break
21286 else
21287   echo "$as_me: failed program was:" >&5
21288 sed 's/^/| /' conftest.$ac_ext >&5
21289
21290         ac_lo=`expr $ac_mid + 1`
21291                         if test $ac_lo -le $ac_mid; then
21292                           ac_lo= ac_hi=
21293                           break
21294                         fi
21295                         ac_mid=`expr 2 '*' $ac_mid + 1`
21296 fi
21297
21298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21299   done
21300 else
21301   echo "$as_me: failed program was:" >&5
21302 sed 's/^/| /' conftest.$ac_ext >&5
21303
21304         cat >conftest.$ac_ext <<_ACEOF
21305 /* confdefs.h.  */
21306 _ACEOF
21307 cat confdefs.h >>conftest.$ac_ext
21308 cat >>conftest.$ac_ext <<_ACEOF
21309 /* end confdefs.h.  */
21310 $ac_includes_default
21311 #ifndef offsetof
21312 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21313 #endif
21314 typedef struct { char x; short y; } ac__type_alignof_;
21315 int
21316 main ()
21317 {
21318 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
21319 test_array [0] = 0
21320
21321   ;
21322   return 0;
21323 }
21324 _ACEOF
21325 rm -f conftest.$ac_objext
21326 if { (ac_try="$ac_compile"
21327 case "(($ac_try" in
21328   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21329   *) ac_try_echo=$ac_try;;
21330 esac
21331 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21332   (eval "$ac_compile") 2>conftest.er1
21333   ac_status=$?
21334   grep -v '^ *+' conftest.er1 >conftest.err
21335   rm -f conftest.er1
21336   cat conftest.err >&5
21337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21338   (exit $ac_status); } && {
21339          test -z "$ac_c_werror_flag" ||
21340          test ! -s conftest.err
21341        } && test -s conftest.$ac_objext; then
21342   ac_hi=-1 ac_mid=-1
21343   while :; do
21344     cat >conftest.$ac_ext <<_ACEOF
21345 /* confdefs.h.  */
21346 _ACEOF
21347 cat confdefs.h >>conftest.$ac_ext
21348 cat >>conftest.$ac_ext <<_ACEOF
21349 /* end confdefs.h.  */
21350 $ac_includes_default
21351 #ifndef offsetof
21352 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21353 #endif
21354 typedef struct { char x; short y; } ac__type_alignof_;
21355 int
21356 main ()
21357 {
21358 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
21359 test_array [0] = 0
21360
21361   ;
21362   return 0;
21363 }
21364 _ACEOF
21365 rm -f conftest.$ac_objext
21366 if { (ac_try="$ac_compile"
21367 case "(($ac_try" in
21368   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21369   *) ac_try_echo=$ac_try;;
21370 esac
21371 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21372   (eval "$ac_compile") 2>conftest.er1
21373   ac_status=$?
21374   grep -v '^ *+' conftest.er1 >conftest.err
21375   rm -f conftest.er1
21376   cat conftest.err >&5
21377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21378   (exit $ac_status); } && {
21379          test -z "$ac_c_werror_flag" ||
21380          test ! -s conftest.err
21381        } && test -s conftest.$ac_objext; then
21382   ac_lo=$ac_mid; break
21383 else
21384   echo "$as_me: failed program was:" >&5
21385 sed 's/^/| /' conftest.$ac_ext >&5
21386
21387         ac_hi=`expr '(' $ac_mid ')' - 1`
21388                         if test $ac_mid -le $ac_hi; then
21389                           ac_lo= ac_hi=
21390                           break
21391                         fi
21392                         ac_mid=`expr 2 '*' $ac_mid`
21393 fi
21394
21395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21396   done
21397 else
21398   echo "$as_me: failed program was:" >&5
21399 sed 's/^/| /' conftest.$ac_ext >&5
21400
21401         ac_lo= ac_hi=
21402 fi
21403
21404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21405 fi
21406
21407 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21408 # Binary search between lo and hi bounds.
21409 while test "x$ac_lo" != "x$ac_hi"; do
21410   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
21411   cat >conftest.$ac_ext <<_ACEOF
21412 /* confdefs.h.  */
21413 _ACEOF
21414 cat confdefs.h >>conftest.$ac_ext
21415 cat >>conftest.$ac_ext <<_ACEOF
21416 /* end confdefs.h.  */
21417 $ac_includes_default
21418 #ifndef offsetof
21419 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21420 #endif
21421 typedef struct { char x; short y; } ac__type_alignof_;
21422 int
21423 main ()
21424 {
21425 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21426 test_array [0] = 0
21427
21428   ;
21429   return 0;
21430 }
21431 _ACEOF
21432 rm -f conftest.$ac_objext
21433 if { (ac_try="$ac_compile"
21434 case "(($ac_try" in
21435   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21436   *) ac_try_echo=$ac_try;;
21437 esac
21438 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21439   (eval "$ac_compile") 2>conftest.er1
21440   ac_status=$?
21441   grep -v '^ *+' conftest.er1 >conftest.err
21442   rm -f conftest.er1
21443   cat conftest.err >&5
21444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21445   (exit $ac_status); } && {
21446          test -z "$ac_c_werror_flag" ||
21447          test ! -s conftest.err
21448        } && test -s conftest.$ac_objext; then
21449   ac_hi=$ac_mid
21450 else
21451   echo "$as_me: failed program was:" >&5
21452 sed 's/^/| /' conftest.$ac_ext >&5
21453
21454         ac_lo=`expr '(' $ac_mid ')' + 1`
21455 fi
21456
21457 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21458 done
21459 case $ac_lo in
21460 ?*) ac_cv_alignof_short=$ac_lo;;
21461 '') if test "$ac_cv_type_short" = yes; then
21462      { { echo "$as_me:$LINENO: error: cannot compute alignment of short
21463 See \`config.log' for more details." >&5
21464 echo "$as_me: error: cannot compute alignment of short
21465 See \`config.log' for more details." >&2;}
21466    { (exit 77); exit 77; }; }
21467    else
21468      ac_cv_alignof_short=0
21469    fi ;;
21470 esac
21471 else
21472   cat >conftest.$ac_ext <<_ACEOF
21473 /* confdefs.h.  */
21474 _ACEOF
21475 cat confdefs.h >>conftest.$ac_ext
21476 cat >>conftest.$ac_ext <<_ACEOF
21477 /* end confdefs.h.  */
21478 $ac_includes_default
21479 #ifndef offsetof
21480 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21481 #endif
21482 typedef struct { char x; short y; } ac__type_alignof_;
21483 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
21484 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
21485 #include <stdio.h>
21486 #include <stdlib.h>
21487 int
21488 main ()
21489 {
21490
21491   FILE *f = fopen ("conftest.val", "w");
21492   if (! f)
21493     return 1;
21494   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
21495     {
21496       long int i = longval ();
21497       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21498         return 1;
21499       fprintf (f, "%ld\n", i);
21500     }
21501   else
21502     {
21503       unsigned long int i = ulongval ();
21504       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21505         return 1;
21506       fprintf (f, "%lu\n", i);
21507     }
21508   return ferror (f) || fclose (f) != 0;
21509
21510   ;
21511   return 0;
21512 }
21513 _ACEOF
21514 rm -f conftest$ac_exeext
21515 if { (ac_try="$ac_link"
21516 case "(($ac_try" in
21517   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21518   *) ac_try_echo=$ac_try;;
21519 esac
21520 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21521   (eval "$ac_link") 2>&5
21522   ac_status=$?
21523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21524   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21525   { (case "(($ac_try" in
21526   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21527   *) ac_try_echo=$ac_try;;
21528 esac
21529 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21530   (eval "$ac_try") 2>&5
21531   ac_status=$?
21532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21533   (exit $ac_status); }; }; then
21534   ac_cv_alignof_short=`cat conftest.val`
21535 else
21536   echo "$as_me: program exited with status $ac_status" >&5
21537 echo "$as_me: failed program was:" >&5
21538 sed 's/^/| /' conftest.$ac_ext >&5
21539
21540 ( exit $ac_status )
21541 if test "$ac_cv_type_short" = yes; then
21542      { { echo "$as_me:$LINENO: error: cannot compute alignment of short
21543 See \`config.log' for more details." >&5
21544 echo "$as_me: error: cannot compute alignment of short
21545 See \`config.log' for more details." >&2;}
21546    { (exit 77); exit 77; }; }
21547    else
21548      ac_cv_alignof_short=0
21549    fi
21550 fi
21551 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21552 fi
21553 rm -f conftest.val
21554 fi
21555 { echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
21556 echo "${ECHO_T}$ac_cv_alignof_short" >&6; }
21557
21558
21559
21560 cat >>confdefs.h <<_ACEOF
21561 #define ALIGNOF_SHORT $ac_cv_alignof_short
21562 _ACEOF
21563
21564
21565 { echo "$as_me:$LINENO: checking for int" >&5
21566 echo $ECHO_N "checking for int... $ECHO_C" >&6; }
21567 if test "${ac_cv_type_int+set}" = set; then
21568   echo $ECHO_N "(cached) $ECHO_C" >&6
21569 else
21570   cat >conftest.$ac_ext <<_ACEOF
21571 /* confdefs.h.  */
21572 _ACEOF
21573 cat confdefs.h >>conftest.$ac_ext
21574 cat >>conftest.$ac_ext <<_ACEOF
21575 /* end confdefs.h.  */
21576 $ac_includes_default
21577 typedef int ac__type_new_;
21578 int
21579 main ()
21580 {
21581 if ((ac__type_new_ *) 0)
21582   return 0;
21583 if (sizeof (ac__type_new_))
21584   return 0;
21585   ;
21586   return 0;
21587 }
21588 _ACEOF
21589 rm -f conftest.$ac_objext
21590 if { (ac_try="$ac_compile"
21591 case "(($ac_try" in
21592   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21593   *) ac_try_echo=$ac_try;;
21594 esac
21595 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21596   (eval "$ac_compile") 2>conftest.er1
21597   ac_status=$?
21598   grep -v '^ *+' conftest.er1 >conftest.err
21599   rm -f conftest.er1
21600   cat conftest.err >&5
21601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21602   (exit $ac_status); } && {
21603          test -z "$ac_c_werror_flag" ||
21604          test ! -s conftest.err
21605        } && test -s conftest.$ac_objext; then
21606   ac_cv_type_int=yes
21607 else
21608   echo "$as_me: failed program was:" >&5
21609 sed 's/^/| /' conftest.$ac_ext >&5
21610
21611         ac_cv_type_int=no
21612 fi
21613
21614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21615 fi
21616 { echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
21617 echo "${ECHO_T}$ac_cv_type_int" >&6; }
21618
21619 # The cast to long int works around a bug in the HP C Compiler,
21620 # see AC_CHECK_SIZEOF for more information.
21621 { echo "$as_me:$LINENO: checking alignment of int" >&5
21622 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6; }
21623 if test "${ac_cv_alignof_int+set}" = set; then
21624   echo $ECHO_N "(cached) $ECHO_C" >&6
21625 else
21626   if test "$cross_compiling" = yes; then
21627   # Depending upon the size, compute the lo and hi bounds.
21628 cat >conftest.$ac_ext <<_ACEOF
21629 /* confdefs.h.  */
21630 _ACEOF
21631 cat confdefs.h >>conftest.$ac_ext
21632 cat >>conftest.$ac_ext <<_ACEOF
21633 /* end confdefs.h.  */
21634 $ac_includes_default
21635 #ifndef offsetof
21636 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21637 #endif
21638 typedef struct { char x; int y; } ac__type_alignof_;
21639 int
21640 main ()
21641 {
21642 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
21643 test_array [0] = 0
21644
21645   ;
21646   return 0;
21647 }
21648 _ACEOF
21649 rm -f conftest.$ac_objext
21650 if { (ac_try="$ac_compile"
21651 case "(($ac_try" in
21652   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21653   *) ac_try_echo=$ac_try;;
21654 esac
21655 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21656   (eval "$ac_compile") 2>conftest.er1
21657   ac_status=$?
21658   grep -v '^ *+' conftest.er1 >conftest.err
21659   rm -f conftest.er1
21660   cat conftest.err >&5
21661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21662   (exit $ac_status); } && {
21663          test -z "$ac_c_werror_flag" ||
21664          test ! -s conftest.err
21665        } && test -s conftest.$ac_objext; then
21666   ac_lo=0 ac_mid=0
21667   while :; do
21668     cat >conftest.$ac_ext <<_ACEOF
21669 /* confdefs.h.  */
21670 _ACEOF
21671 cat confdefs.h >>conftest.$ac_ext
21672 cat >>conftest.$ac_ext <<_ACEOF
21673 /* end confdefs.h.  */
21674 $ac_includes_default
21675 #ifndef offsetof
21676 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21677 #endif
21678 typedef struct { char x; int y; } ac__type_alignof_;
21679 int
21680 main ()
21681 {
21682 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21683 test_array [0] = 0
21684
21685   ;
21686   return 0;
21687 }
21688 _ACEOF
21689 rm -f conftest.$ac_objext
21690 if { (ac_try="$ac_compile"
21691 case "(($ac_try" in
21692   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21693   *) ac_try_echo=$ac_try;;
21694 esac
21695 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21696   (eval "$ac_compile") 2>conftest.er1
21697   ac_status=$?
21698   grep -v '^ *+' conftest.er1 >conftest.err
21699   rm -f conftest.er1
21700   cat conftest.err >&5
21701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21702   (exit $ac_status); } && {
21703          test -z "$ac_c_werror_flag" ||
21704          test ! -s conftest.err
21705        } && test -s conftest.$ac_objext; then
21706   ac_hi=$ac_mid; break
21707 else
21708   echo "$as_me: failed program was:" >&5
21709 sed 's/^/| /' conftest.$ac_ext >&5
21710
21711         ac_lo=`expr $ac_mid + 1`
21712                         if test $ac_lo -le $ac_mid; then
21713                           ac_lo= ac_hi=
21714                           break
21715                         fi
21716                         ac_mid=`expr 2 '*' $ac_mid + 1`
21717 fi
21718
21719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21720   done
21721 else
21722   echo "$as_me: failed program was:" >&5
21723 sed 's/^/| /' conftest.$ac_ext >&5
21724
21725         cat >conftest.$ac_ext <<_ACEOF
21726 /* confdefs.h.  */
21727 _ACEOF
21728 cat confdefs.h >>conftest.$ac_ext
21729 cat >>conftest.$ac_ext <<_ACEOF
21730 /* end confdefs.h.  */
21731 $ac_includes_default
21732 #ifndef offsetof
21733 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21734 #endif
21735 typedef struct { char x; int y; } ac__type_alignof_;
21736 int
21737 main ()
21738 {
21739 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
21740 test_array [0] = 0
21741
21742   ;
21743   return 0;
21744 }
21745 _ACEOF
21746 rm -f conftest.$ac_objext
21747 if { (ac_try="$ac_compile"
21748 case "(($ac_try" in
21749   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21750   *) ac_try_echo=$ac_try;;
21751 esac
21752 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21753   (eval "$ac_compile") 2>conftest.er1
21754   ac_status=$?
21755   grep -v '^ *+' conftest.er1 >conftest.err
21756   rm -f conftest.er1
21757   cat conftest.err >&5
21758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21759   (exit $ac_status); } && {
21760          test -z "$ac_c_werror_flag" ||
21761          test ! -s conftest.err
21762        } && test -s conftest.$ac_objext; then
21763   ac_hi=-1 ac_mid=-1
21764   while :; do
21765     cat >conftest.$ac_ext <<_ACEOF
21766 /* confdefs.h.  */
21767 _ACEOF
21768 cat confdefs.h >>conftest.$ac_ext
21769 cat >>conftest.$ac_ext <<_ACEOF
21770 /* end confdefs.h.  */
21771 $ac_includes_default
21772 #ifndef offsetof
21773 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21774 #endif
21775 typedef struct { char x; int y; } ac__type_alignof_;
21776 int
21777 main ()
21778 {
21779 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
21780 test_array [0] = 0
21781
21782   ;
21783   return 0;
21784 }
21785 _ACEOF
21786 rm -f conftest.$ac_objext
21787 if { (ac_try="$ac_compile"
21788 case "(($ac_try" in
21789   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21790   *) ac_try_echo=$ac_try;;
21791 esac
21792 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21793   (eval "$ac_compile") 2>conftest.er1
21794   ac_status=$?
21795   grep -v '^ *+' conftest.er1 >conftest.err
21796   rm -f conftest.er1
21797   cat conftest.err >&5
21798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21799   (exit $ac_status); } && {
21800          test -z "$ac_c_werror_flag" ||
21801          test ! -s conftest.err
21802        } && test -s conftest.$ac_objext; then
21803   ac_lo=$ac_mid; break
21804 else
21805   echo "$as_me: failed program was:" >&5
21806 sed 's/^/| /' conftest.$ac_ext >&5
21807
21808         ac_hi=`expr '(' $ac_mid ')' - 1`
21809                         if test $ac_mid -le $ac_hi; then
21810                           ac_lo= ac_hi=
21811                           break
21812                         fi
21813                         ac_mid=`expr 2 '*' $ac_mid`
21814 fi
21815
21816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21817   done
21818 else
21819   echo "$as_me: failed program was:" >&5
21820 sed 's/^/| /' conftest.$ac_ext >&5
21821
21822         ac_lo= ac_hi=
21823 fi
21824
21825 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21826 fi
21827
21828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21829 # Binary search between lo and hi bounds.
21830 while test "x$ac_lo" != "x$ac_hi"; do
21831   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
21832   cat >conftest.$ac_ext <<_ACEOF
21833 /* confdefs.h.  */
21834 _ACEOF
21835 cat confdefs.h >>conftest.$ac_ext
21836 cat >>conftest.$ac_ext <<_ACEOF
21837 /* end confdefs.h.  */
21838 $ac_includes_default
21839 #ifndef offsetof
21840 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21841 #endif
21842 typedef struct { char x; int y; } ac__type_alignof_;
21843 int
21844 main ()
21845 {
21846 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21847 test_array [0] = 0
21848
21849   ;
21850   return 0;
21851 }
21852 _ACEOF
21853 rm -f conftest.$ac_objext
21854 if { (ac_try="$ac_compile"
21855 case "(($ac_try" in
21856   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21857   *) ac_try_echo=$ac_try;;
21858 esac
21859 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21860   (eval "$ac_compile") 2>conftest.er1
21861   ac_status=$?
21862   grep -v '^ *+' conftest.er1 >conftest.err
21863   rm -f conftest.er1
21864   cat conftest.err >&5
21865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21866   (exit $ac_status); } && {
21867          test -z "$ac_c_werror_flag" ||
21868          test ! -s conftest.err
21869        } && test -s conftest.$ac_objext; then
21870   ac_hi=$ac_mid
21871 else
21872   echo "$as_me: failed program was:" >&5
21873 sed 's/^/| /' conftest.$ac_ext >&5
21874
21875         ac_lo=`expr '(' $ac_mid ')' + 1`
21876 fi
21877
21878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21879 done
21880 case $ac_lo in
21881 ?*) ac_cv_alignof_int=$ac_lo;;
21882 '') if test "$ac_cv_type_int" = yes; then
21883      { { echo "$as_me:$LINENO: error: cannot compute alignment of int
21884 See \`config.log' for more details." >&5
21885 echo "$as_me: error: cannot compute alignment of int
21886 See \`config.log' for more details." >&2;}
21887    { (exit 77); exit 77; }; }
21888    else
21889      ac_cv_alignof_int=0
21890    fi ;;
21891 esac
21892 else
21893   cat >conftest.$ac_ext <<_ACEOF
21894 /* confdefs.h.  */
21895 _ACEOF
21896 cat confdefs.h >>conftest.$ac_ext
21897 cat >>conftest.$ac_ext <<_ACEOF
21898 /* end confdefs.h.  */
21899 $ac_includes_default
21900 #ifndef offsetof
21901 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21902 #endif
21903 typedef struct { char x; int y; } ac__type_alignof_;
21904 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
21905 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
21906 #include <stdio.h>
21907 #include <stdlib.h>
21908 int
21909 main ()
21910 {
21911
21912   FILE *f = fopen ("conftest.val", "w");
21913   if (! f)
21914     return 1;
21915   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
21916     {
21917       long int i = longval ();
21918       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21919         return 1;
21920       fprintf (f, "%ld\n", i);
21921     }
21922   else
21923     {
21924       unsigned long int i = ulongval ();
21925       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21926         return 1;
21927       fprintf (f, "%lu\n", i);
21928     }
21929   return ferror (f) || fclose (f) != 0;
21930
21931   ;
21932   return 0;
21933 }
21934 _ACEOF
21935 rm -f conftest$ac_exeext
21936 if { (ac_try="$ac_link"
21937 case "(($ac_try" in
21938   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21939   *) ac_try_echo=$ac_try;;
21940 esac
21941 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21942   (eval "$ac_link") 2>&5
21943   ac_status=$?
21944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21945   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21946   { (case "(($ac_try" in
21947   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21948   *) ac_try_echo=$ac_try;;
21949 esac
21950 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21951   (eval "$ac_try") 2>&5
21952   ac_status=$?
21953   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21954   (exit $ac_status); }; }; then
21955   ac_cv_alignof_int=`cat conftest.val`
21956 else
21957   echo "$as_me: program exited with status $ac_status" >&5
21958 echo "$as_me: failed program was:" >&5
21959 sed 's/^/| /' conftest.$ac_ext >&5
21960
21961 ( exit $ac_status )
21962 if test "$ac_cv_type_int" = yes; then
21963      { { echo "$as_me:$LINENO: error: cannot compute alignment of int
21964 See \`config.log' for more details." >&5
21965 echo "$as_me: error: cannot compute alignment of int
21966 See \`config.log' for more details." >&2;}
21967    { (exit 77); exit 77; }; }
21968    else
21969      ac_cv_alignof_int=0
21970    fi
21971 fi
21972 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21973 fi
21974 rm -f conftest.val
21975 fi
21976 { echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
21977 echo "${ECHO_T}$ac_cv_alignof_int" >&6; }
21978
21979
21980
21981 cat >>confdefs.h <<_ACEOF
21982 #define ALIGNOF_INT $ac_cv_alignof_int
21983 _ACEOF
21984
21985
21986 { echo "$as_me:$LINENO: checking for long" >&5
21987 echo $ECHO_N "checking for long... $ECHO_C" >&6; }
21988 if test "${ac_cv_type_long+set}" = set; then
21989   echo $ECHO_N "(cached) $ECHO_C" >&6
21990 else
21991   cat >conftest.$ac_ext <<_ACEOF
21992 /* confdefs.h.  */
21993 _ACEOF
21994 cat confdefs.h >>conftest.$ac_ext
21995 cat >>conftest.$ac_ext <<_ACEOF
21996 /* end confdefs.h.  */
21997 $ac_includes_default
21998 typedef long ac__type_new_;
21999 int
22000 main ()
22001 {
22002 if ((ac__type_new_ *) 0)
22003   return 0;
22004 if (sizeof (ac__type_new_))
22005   return 0;
22006   ;
22007   return 0;
22008 }
22009 _ACEOF
22010 rm -f conftest.$ac_objext
22011 if { (ac_try="$ac_compile"
22012 case "(($ac_try" in
22013   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22014   *) ac_try_echo=$ac_try;;
22015 esac
22016 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22017   (eval "$ac_compile") 2>conftest.er1
22018   ac_status=$?
22019   grep -v '^ *+' conftest.er1 >conftest.err
22020   rm -f conftest.er1
22021   cat conftest.err >&5
22022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22023   (exit $ac_status); } && {
22024          test -z "$ac_c_werror_flag" ||
22025          test ! -s conftest.err
22026        } && test -s conftest.$ac_objext; then
22027   ac_cv_type_long=yes
22028 else
22029   echo "$as_me: failed program was:" >&5
22030 sed 's/^/| /' conftest.$ac_ext >&5
22031
22032         ac_cv_type_long=no
22033 fi
22034
22035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22036 fi
22037 { echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
22038 echo "${ECHO_T}$ac_cv_type_long" >&6; }
22039
22040 # The cast to long int works around a bug in the HP C Compiler,
22041 # see AC_CHECK_SIZEOF for more information.
22042 { echo "$as_me:$LINENO: checking alignment of long" >&5
22043 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6; }
22044 if test "${ac_cv_alignof_long+set}" = set; then
22045   echo $ECHO_N "(cached) $ECHO_C" >&6
22046 else
22047   if test "$cross_compiling" = yes; then
22048   # Depending upon the size, compute the lo and hi bounds.
22049 cat >conftest.$ac_ext <<_ACEOF
22050 /* confdefs.h.  */
22051 _ACEOF
22052 cat confdefs.h >>conftest.$ac_ext
22053 cat >>conftest.$ac_ext <<_ACEOF
22054 /* end confdefs.h.  */
22055 $ac_includes_default
22056 #ifndef offsetof
22057 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22058 #endif
22059 typedef struct { char x; long y; } ac__type_alignof_;
22060 int
22061 main ()
22062 {
22063 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
22064 test_array [0] = 0
22065
22066   ;
22067   return 0;
22068 }
22069 _ACEOF
22070 rm -f conftest.$ac_objext
22071 if { (ac_try="$ac_compile"
22072 case "(($ac_try" in
22073   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22074   *) ac_try_echo=$ac_try;;
22075 esac
22076 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22077   (eval "$ac_compile") 2>conftest.er1
22078   ac_status=$?
22079   grep -v '^ *+' conftest.er1 >conftest.err
22080   rm -f conftest.er1
22081   cat conftest.err >&5
22082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22083   (exit $ac_status); } && {
22084          test -z "$ac_c_werror_flag" ||
22085          test ! -s conftest.err
22086        } && test -s conftest.$ac_objext; then
22087   ac_lo=0 ac_mid=0
22088   while :; do
22089     cat >conftest.$ac_ext <<_ACEOF
22090 /* confdefs.h.  */
22091 _ACEOF
22092 cat confdefs.h >>conftest.$ac_ext
22093 cat >>conftest.$ac_ext <<_ACEOF
22094 /* end confdefs.h.  */
22095 $ac_includes_default
22096 #ifndef offsetof
22097 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22098 #endif
22099 typedef struct { char x; long y; } ac__type_alignof_;
22100 int
22101 main ()
22102 {
22103 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22104 test_array [0] = 0
22105
22106   ;
22107   return 0;
22108 }
22109 _ACEOF
22110 rm -f conftest.$ac_objext
22111 if { (ac_try="$ac_compile"
22112 case "(($ac_try" in
22113   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22114   *) ac_try_echo=$ac_try;;
22115 esac
22116 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22117   (eval "$ac_compile") 2>conftest.er1
22118   ac_status=$?
22119   grep -v '^ *+' conftest.er1 >conftest.err
22120   rm -f conftest.er1
22121   cat conftest.err >&5
22122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22123   (exit $ac_status); } && {
22124          test -z "$ac_c_werror_flag" ||
22125          test ! -s conftest.err
22126        } && test -s conftest.$ac_objext; then
22127   ac_hi=$ac_mid; break
22128 else
22129   echo "$as_me: failed program was:" >&5
22130 sed 's/^/| /' conftest.$ac_ext >&5
22131
22132         ac_lo=`expr $ac_mid + 1`
22133                         if test $ac_lo -le $ac_mid; then
22134                           ac_lo= ac_hi=
22135                           break
22136                         fi
22137                         ac_mid=`expr 2 '*' $ac_mid + 1`
22138 fi
22139
22140 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22141   done
22142 else
22143   echo "$as_me: failed program was:" >&5
22144 sed 's/^/| /' conftest.$ac_ext >&5
22145
22146         cat >conftest.$ac_ext <<_ACEOF
22147 /* confdefs.h.  */
22148 _ACEOF
22149 cat confdefs.h >>conftest.$ac_ext
22150 cat >>conftest.$ac_ext <<_ACEOF
22151 /* end confdefs.h.  */
22152 $ac_includes_default
22153 #ifndef offsetof
22154 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22155 #endif
22156 typedef struct { char x; long y; } ac__type_alignof_;
22157 int
22158 main ()
22159 {
22160 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
22161 test_array [0] = 0
22162
22163   ;
22164   return 0;
22165 }
22166 _ACEOF
22167 rm -f conftest.$ac_objext
22168 if { (ac_try="$ac_compile"
22169 case "(($ac_try" in
22170   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22171   *) ac_try_echo=$ac_try;;
22172 esac
22173 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22174   (eval "$ac_compile") 2>conftest.er1
22175   ac_status=$?
22176   grep -v '^ *+' conftest.er1 >conftest.err
22177   rm -f conftest.er1
22178   cat conftest.err >&5
22179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22180   (exit $ac_status); } && {
22181          test -z "$ac_c_werror_flag" ||
22182          test ! -s conftest.err
22183        } && test -s conftest.$ac_objext; then
22184   ac_hi=-1 ac_mid=-1
22185   while :; do
22186     cat >conftest.$ac_ext <<_ACEOF
22187 /* confdefs.h.  */
22188 _ACEOF
22189 cat confdefs.h >>conftest.$ac_ext
22190 cat >>conftest.$ac_ext <<_ACEOF
22191 /* end confdefs.h.  */
22192 $ac_includes_default
22193 #ifndef offsetof
22194 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22195 #endif
22196 typedef struct { char x; long y; } ac__type_alignof_;
22197 int
22198 main ()
22199 {
22200 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
22201 test_array [0] = 0
22202
22203   ;
22204   return 0;
22205 }
22206 _ACEOF
22207 rm -f conftest.$ac_objext
22208 if { (ac_try="$ac_compile"
22209 case "(($ac_try" in
22210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22211   *) ac_try_echo=$ac_try;;
22212 esac
22213 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22214   (eval "$ac_compile") 2>conftest.er1
22215   ac_status=$?
22216   grep -v '^ *+' conftest.er1 >conftest.err
22217   rm -f conftest.er1
22218   cat conftest.err >&5
22219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22220   (exit $ac_status); } && {
22221          test -z "$ac_c_werror_flag" ||
22222          test ! -s conftest.err
22223        } && test -s conftest.$ac_objext; then
22224   ac_lo=$ac_mid; break
22225 else
22226   echo "$as_me: failed program was:" >&5
22227 sed 's/^/| /' conftest.$ac_ext >&5
22228
22229         ac_hi=`expr '(' $ac_mid ')' - 1`
22230                         if test $ac_mid -le $ac_hi; then
22231                           ac_lo= ac_hi=
22232                           break
22233                         fi
22234                         ac_mid=`expr 2 '*' $ac_mid`
22235 fi
22236
22237 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22238   done
22239 else
22240   echo "$as_me: failed program was:" >&5
22241 sed 's/^/| /' conftest.$ac_ext >&5
22242
22243         ac_lo= ac_hi=
22244 fi
22245
22246 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22247 fi
22248
22249 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22250 # Binary search between lo and hi bounds.
22251 while test "x$ac_lo" != "x$ac_hi"; do
22252   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
22253   cat >conftest.$ac_ext <<_ACEOF
22254 /* confdefs.h.  */
22255 _ACEOF
22256 cat confdefs.h >>conftest.$ac_ext
22257 cat >>conftest.$ac_ext <<_ACEOF
22258 /* end confdefs.h.  */
22259 $ac_includes_default
22260 #ifndef offsetof
22261 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22262 #endif
22263 typedef struct { char x; long y; } ac__type_alignof_;
22264 int
22265 main ()
22266 {
22267 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22268 test_array [0] = 0
22269
22270   ;
22271   return 0;
22272 }
22273 _ACEOF
22274 rm -f conftest.$ac_objext
22275 if { (ac_try="$ac_compile"
22276 case "(($ac_try" in
22277   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22278   *) ac_try_echo=$ac_try;;
22279 esac
22280 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22281   (eval "$ac_compile") 2>conftest.er1
22282   ac_status=$?
22283   grep -v '^ *+' conftest.er1 >conftest.err
22284   rm -f conftest.er1
22285   cat conftest.err >&5
22286   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22287   (exit $ac_status); } && {
22288          test -z "$ac_c_werror_flag" ||
22289          test ! -s conftest.err
22290        } && test -s conftest.$ac_objext; then
22291   ac_hi=$ac_mid
22292 else
22293   echo "$as_me: failed program was:" >&5
22294 sed 's/^/| /' conftest.$ac_ext >&5
22295
22296         ac_lo=`expr '(' $ac_mid ')' + 1`
22297 fi
22298
22299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22300 done
22301 case $ac_lo in
22302 ?*) ac_cv_alignof_long=$ac_lo;;
22303 '') if test "$ac_cv_type_long" = yes; then
22304      { { echo "$as_me:$LINENO: error: cannot compute alignment of long
22305 See \`config.log' for more details." >&5
22306 echo "$as_me: error: cannot compute alignment of long
22307 See \`config.log' for more details." >&2;}
22308    { (exit 77); exit 77; }; }
22309    else
22310      ac_cv_alignof_long=0
22311    fi ;;
22312 esac
22313 else
22314   cat >conftest.$ac_ext <<_ACEOF
22315 /* confdefs.h.  */
22316 _ACEOF
22317 cat confdefs.h >>conftest.$ac_ext
22318 cat >>conftest.$ac_ext <<_ACEOF
22319 /* end confdefs.h.  */
22320 $ac_includes_default
22321 #ifndef offsetof
22322 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22323 #endif
22324 typedef struct { char x; long y; } ac__type_alignof_;
22325 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
22326 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
22327 #include <stdio.h>
22328 #include <stdlib.h>
22329 int
22330 main ()
22331 {
22332
22333   FILE *f = fopen ("conftest.val", "w");
22334   if (! f)
22335     return 1;
22336   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
22337     {
22338       long int i = longval ();
22339       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22340         return 1;
22341       fprintf (f, "%ld\n", i);
22342     }
22343   else
22344     {
22345       unsigned long int i = ulongval ();
22346       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22347         return 1;
22348       fprintf (f, "%lu\n", i);
22349     }
22350   return ferror (f) || fclose (f) != 0;
22351
22352   ;
22353   return 0;
22354 }
22355 _ACEOF
22356 rm -f conftest$ac_exeext
22357 if { (ac_try="$ac_link"
22358 case "(($ac_try" in
22359   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22360   *) ac_try_echo=$ac_try;;
22361 esac
22362 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22363   (eval "$ac_link") 2>&5
22364   ac_status=$?
22365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22366   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22367   { (case "(($ac_try" in
22368   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22369   *) ac_try_echo=$ac_try;;
22370 esac
22371 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22372   (eval "$ac_try") 2>&5
22373   ac_status=$?
22374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22375   (exit $ac_status); }; }; then
22376   ac_cv_alignof_long=`cat conftest.val`
22377 else
22378   echo "$as_me: program exited with status $ac_status" >&5
22379 echo "$as_me: failed program was:" >&5
22380 sed 's/^/| /' conftest.$ac_ext >&5
22381
22382 ( exit $ac_status )
22383 if test "$ac_cv_type_long" = yes; then
22384      { { echo "$as_me:$LINENO: error: cannot compute alignment of long
22385 See \`config.log' for more details." >&5
22386 echo "$as_me: error: cannot compute alignment of long
22387 See \`config.log' for more details." >&2;}
22388    { (exit 77); exit 77; }; }
22389    else
22390      ac_cv_alignof_long=0
22391    fi
22392 fi
22393 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22394 fi
22395 rm -f conftest.val
22396 fi
22397 { echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
22398 echo "${ECHO_T}$ac_cv_alignof_long" >&6; }
22399
22400
22401
22402 cat >>confdefs.h <<_ACEOF
22403 #define ALIGNOF_LONG $ac_cv_alignof_long
22404 _ACEOF
22405
22406
22407 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
22408   { echo "$as_me:$LINENO: checking for long long int" >&5
22409 echo $ECHO_N "checking for long long int... $ECHO_C" >&6; }
22410 if test "${ac_cv_type_long_long_int+set}" = set; then
22411   echo $ECHO_N "(cached) $ECHO_C" >&6
22412 else
22413   cat >conftest.$ac_ext <<_ACEOF
22414 /* confdefs.h.  */
22415 _ACEOF
22416 cat confdefs.h >>conftest.$ac_ext
22417 cat >>conftest.$ac_ext <<_ACEOF
22418 /* end confdefs.h.  */
22419 $ac_includes_default
22420 typedef long long int ac__type_new_;
22421 int
22422 main ()
22423 {
22424 if ((ac__type_new_ *) 0)
22425   return 0;
22426 if (sizeof (ac__type_new_))
22427   return 0;
22428   ;
22429   return 0;
22430 }
22431 _ACEOF
22432 rm -f conftest.$ac_objext
22433 if { (ac_try="$ac_compile"
22434 case "(($ac_try" in
22435   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22436   *) ac_try_echo=$ac_try;;
22437 esac
22438 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22439   (eval "$ac_compile") 2>conftest.er1
22440   ac_status=$?
22441   grep -v '^ *+' conftest.er1 >conftest.err
22442   rm -f conftest.er1
22443   cat conftest.err >&5
22444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22445   (exit $ac_status); } && {
22446          test -z "$ac_c_werror_flag" ||
22447          test ! -s conftest.err
22448        } && test -s conftest.$ac_objext; then
22449   ac_cv_type_long_long_int=yes
22450 else
22451   echo "$as_me: failed program was:" >&5
22452 sed 's/^/| /' conftest.$ac_ext >&5
22453
22454         ac_cv_type_long_long_int=no
22455 fi
22456
22457 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22458 fi
22459 { echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
22460 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6; }
22461
22462 # The cast to long int works around a bug in the HP C Compiler,
22463 # see AC_CHECK_SIZEOF for more information.
22464 { echo "$as_me:$LINENO: checking alignment of long long int" >&5
22465 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6; }
22466 if test "${ac_cv_alignof_long_long_int+set}" = set; then
22467   echo $ECHO_N "(cached) $ECHO_C" >&6
22468 else
22469   if test "$cross_compiling" = yes; then
22470   # Depending upon the size, compute the lo and hi bounds.
22471 cat >conftest.$ac_ext <<_ACEOF
22472 /* confdefs.h.  */
22473 _ACEOF
22474 cat confdefs.h >>conftest.$ac_ext
22475 cat >>conftest.$ac_ext <<_ACEOF
22476 /* end confdefs.h.  */
22477 $ac_includes_default
22478 #ifndef offsetof
22479 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22480 #endif
22481 typedef struct { char x; long long int y; } ac__type_alignof_;
22482 int
22483 main ()
22484 {
22485 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
22486 test_array [0] = 0
22487
22488   ;
22489   return 0;
22490 }
22491 _ACEOF
22492 rm -f conftest.$ac_objext
22493 if { (ac_try="$ac_compile"
22494 case "(($ac_try" in
22495   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22496   *) ac_try_echo=$ac_try;;
22497 esac
22498 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22499   (eval "$ac_compile") 2>conftest.er1
22500   ac_status=$?
22501   grep -v '^ *+' conftest.er1 >conftest.err
22502   rm -f conftest.er1
22503   cat conftest.err >&5
22504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22505   (exit $ac_status); } && {
22506          test -z "$ac_c_werror_flag" ||
22507          test ! -s conftest.err
22508        } && test -s conftest.$ac_objext; then
22509   ac_lo=0 ac_mid=0
22510   while :; do
22511     cat >conftest.$ac_ext <<_ACEOF
22512 /* confdefs.h.  */
22513 _ACEOF
22514 cat confdefs.h >>conftest.$ac_ext
22515 cat >>conftest.$ac_ext <<_ACEOF
22516 /* end confdefs.h.  */
22517 $ac_includes_default
22518 #ifndef offsetof
22519 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22520 #endif
22521 typedef struct { char x; long long int y; } ac__type_alignof_;
22522 int
22523 main ()
22524 {
22525 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22526 test_array [0] = 0
22527
22528   ;
22529   return 0;
22530 }
22531 _ACEOF
22532 rm -f conftest.$ac_objext
22533 if { (ac_try="$ac_compile"
22534 case "(($ac_try" in
22535   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22536   *) ac_try_echo=$ac_try;;
22537 esac
22538 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22539   (eval "$ac_compile") 2>conftest.er1
22540   ac_status=$?
22541   grep -v '^ *+' conftest.er1 >conftest.err
22542   rm -f conftest.er1
22543   cat conftest.err >&5
22544   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22545   (exit $ac_status); } && {
22546          test -z "$ac_c_werror_flag" ||
22547          test ! -s conftest.err
22548        } && test -s conftest.$ac_objext; then
22549   ac_hi=$ac_mid; break
22550 else
22551   echo "$as_me: failed program was:" >&5
22552 sed 's/^/| /' conftest.$ac_ext >&5
22553
22554         ac_lo=`expr $ac_mid + 1`
22555                         if test $ac_lo -le $ac_mid; then
22556                           ac_lo= ac_hi=
22557                           break
22558                         fi
22559                         ac_mid=`expr 2 '*' $ac_mid + 1`
22560 fi
22561
22562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22563   done
22564 else
22565   echo "$as_me: failed program was:" >&5
22566 sed 's/^/| /' conftest.$ac_ext >&5
22567
22568         cat >conftest.$ac_ext <<_ACEOF
22569 /* confdefs.h.  */
22570 _ACEOF
22571 cat confdefs.h >>conftest.$ac_ext
22572 cat >>conftest.$ac_ext <<_ACEOF
22573 /* end confdefs.h.  */
22574 $ac_includes_default
22575 #ifndef offsetof
22576 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22577 #endif
22578 typedef struct { char x; long long int y; } ac__type_alignof_;
22579 int
22580 main ()
22581 {
22582 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
22583 test_array [0] = 0
22584
22585   ;
22586   return 0;
22587 }
22588 _ACEOF
22589 rm -f conftest.$ac_objext
22590 if { (ac_try="$ac_compile"
22591 case "(($ac_try" in
22592   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22593   *) ac_try_echo=$ac_try;;
22594 esac
22595 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22596   (eval "$ac_compile") 2>conftest.er1
22597   ac_status=$?
22598   grep -v '^ *+' conftest.er1 >conftest.err
22599   rm -f conftest.er1
22600   cat conftest.err >&5
22601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22602   (exit $ac_status); } && {
22603          test -z "$ac_c_werror_flag" ||
22604          test ! -s conftest.err
22605        } && test -s conftest.$ac_objext; then
22606   ac_hi=-1 ac_mid=-1
22607   while :; do
22608     cat >conftest.$ac_ext <<_ACEOF
22609 /* confdefs.h.  */
22610 _ACEOF
22611 cat confdefs.h >>conftest.$ac_ext
22612 cat >>conftest.$ac_ext <<_ACEOF
22613 /* end confdefs.h.  */
22614 $ac_includes_default
22615 #ifndef offsetof
22616 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22617 #endif
22618 typedef struct { char x; long long int y; } ac__type_alignof_;
22619 int
22620 main ()
22621 {
22622 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
22623 test_array [0] = 0
22624
22625   ;
22626   return 0;
22627 }
22628 _ACEOF
22629 rm -f conftest.$ac_objext
22630 if { (ac_try="$ac_compile"
22631 case "(($ac_try" in
22632   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22633   *) ac_try_echo=$ac_try;;
22634 esac
22635 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22636   (eval "$ac_compile") 2>conftest.er1
22637   ac_status=$?
22638   grep -v '^ *+' conftest.er1 >conftest.err
22639   rm -f conftest.er1
22640   cat conftest.err >&5
22641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22642   (exit $ac_status); } && {
22643          test -z "$ac_c_werror_flag" ||
22644          test ! -s conftest.err
22645        } && test -s conftest.$ac_objext; then
22646   ac_lo=$ac_mid; break
22647 else
22648   echo "$as_me: failed program was:" >&5
22649 sed 's/^/| /' conftest.$ac_ext >&5
22650
22651         ac_hi=`expr '(' $ac_mid ')' - 1`
22652                         if test $ac_mid -le $ac_hi; then
22653                           ac_lo= ac_hi=
22654                           break
22655                         fi
22656                         ac_mid=`expr 2 '*' $ac_mid`
22657 fi
22658
22659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22660   done
22661 else
22662   echo "$as_me: failed program was:" >&5
22663 sed 's/^/| /' conftest.$ac_ext >&5
22664
22665         ac_lo= ac_hi=
22666 fi
22667
22668 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22669 fi
22670
22671 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22672 # Binary search between lo and hi bounds.
22673 while test "x$ac_lo" != "x$ac_hi"; do
22674   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
22675   cat >conftest.$ac_ext <<_ACEOF
22676 /* confdefs.h.  */
22677 _ACEOF
22678 cat confdefs.h >>conftest.$ac_ext
22679 cat >>conftest.$ac_ext <<_ACEOF
22680 /* end confdefs.h.  */
22681 $ac_includes_default
22682 #ifndef offsetof
22683 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22684 #endif
22685 typedef struct { char x; long long int y; } ac__type_alignof_;
22686 int
22687 main ()
22688 {
22689 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22690 test_array [0] = 0
22691
22692   ;
22693   return 0;
22694 }
22695 _ACEOF
22696 rm -f conftest.$ac_objext
22697 if { (ac_try="$ac_compile"
22698 case "(($ac_try" in
22699   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22700   *) ac_try_echo=$ac_try;;
22701 esac
22702 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22703   (eval "$ac_compile") 2>conftest.er1
22704   ac_status=$?
22705   grep -v '^ *+' conftest.er1 >conftest.err
22706   rm -f conftest.er1
22707   cat conftest.err >&5
22708   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22709   (exit $ac_status); } && {
22710          test -z "$ac_c_werror_flag" ||
22711          test ! -s conftest.err
22712        } && test -s conftest.$ac_objext; then
22713   ac_hi=$ac_mid
22714 else
22715   echo "$as_me: failed program was:" >&5
22716 sed 's/^/| /' conftest.$ac_ext >&5
22717
22718         ac_lo=`expr '(' $ac_mid ')' + 1`
22719 fi
22720
22721 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22722 done
22723 case $ac_lo in
22724 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
22725 '') if test "$ac_cv_type_long_long_int" = yes; then
22726      { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int
22727 See \`config.log' for more details." >&5
22728 echo "$as_me: error: cannot compute alignment of long long int
22729 See \`config.log' for more details." >&2;}
22730    { (exit 77); exit 77; }; }
22731    else
22732      ac_cv_alignof_long_long_int=0
22733    fi ;;
22734 esac
22735 else
22736   cat >conftest.$ac_ext <<_ACEOF
22737 /* confdefs.h.  */
22738 _ACEOF
22739 cat confdefs.h >>conftest.$ac_ext
22740 cat >>conftest.$ac_ext <<_ACEOF
22741 /* end confdefs.h.  */
22742 $ac_includes_default
22743 #ifndef offsetof
22744 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22745 #endif
22746 typedef struct { char x; long long int y; } ac__type_alignof_;
22747 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
22748 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
22749 #include <stdio.h>
22750 #include <stdlib.h>
22751 int
22752 main ()
22753 {
22754
22755   FILE *f = fopen ("conftest.val", "w");
22756   if (! f)
22757     return 1;
22758   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
22759     {
22760       long int i = longval ();
22761       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22762         return 1;
22763       fprintf (f, "%ld\n", i);
22764     }
22765   else
22766     {
22767       unsigned long int i = ulongval ();
22768       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22769         return 1;
22770       fprintf (f, "%lu\n", i);
22771     }
22772   return ferror (f) || fclose (f) != 0;
22773
22774   ;
22775   return 0;
22776 }
22777 _ACEOF
22778 rm -f conftest$ac_exeext
22779 if { (ac_try="$ac_link"
22780 case "(($ac_try" in
22781   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22782   *) ac_try_echo=$ac_try;;
22783 esac
22784 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22785   (eval "$ac_link") 2>&5
22786   ac_status=$?
22787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22788   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22789   { (case "(($ac_try" in
22790   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22791   *) ac_try_echo=$ac_try;;
22792 esac
22793 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22794   (eval "$ac_try") 2>&5
22795   ac_status=$?
22796   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22797   (exit $ac_status); }; }; then
22798   ac_cv_alignof_long_long_int=`cat conftest.val`
22799 else
22800   echo "$as_me: program exited with status $ac_status" >&5
22801 echo "$as_me: failed program was:" >&5
22802 sed 's/^/| /' conftest.$ac_ext >&5
22803
22804 ( exit $ac_status )
22805 if test "$ac_cv_type_long_long_int" = yes; then
22806      { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int
22807 See \`config.log' for more details." >&5
22808 echo "$as_me: error: cannot compute alignment of long long int
22809 See \`config.log' for more details." >&2;}
22810    { (exit 77); exit 77; }; }
22811    else
22812      ac_cv_alignof_long_long_int=0
22813    fi
22814 fi
22815 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22816 fi
22817 rm -f conftest.val
22818 fi
22819 { echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
22820 echo "${ECHO_T}$ac_cv_alignof_long_long_int" >&6; }
22821
22822
22823
22824 cat >>confdefs.h <<_ACEOF
22825 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
22826 _ACEOF
22827
22828
22829 fi
22830 { echo "$as_me:$LINENO: checking for double" >&5
22831 echo $ECHO_N "checking for double... $ECHO_C" >&6; }
22832 if test "${ac_cv_type_double+set}" = set; then
22833   echo $ECHO_N "(cached) $ECHO_C" >&6
22834 else
22835   cat >conftest.$ac_ext <<_ACEOF
22836 /* confdefs.h.  */
22837 _ACEOF
22838 cat confdefs.h >>conftest.$ac_ext
22839 cat >>conftest.$ac_ext <<_ACEOF
22840 /* end confdefs.h.  */
22841 $ac_includes_default
22842 typedef double ac__type_new_;
22843 int
22844 main ()
22845 {
22846 if ((ac__type_new_ *) 0)
22847   return 0;
22848 if (sizeof (ac__type_new_))
22849   return 0;
22850   ;
22851   return 0;
22852 }
22853 _ACEOF
22854 rm -f conftest.$ac_objext
22855 if { (ac_try="$ac_compile"
22856 case "(($ac_try" in
22857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22858   *) ac_try_echo=$ac_try;;
22859 esac
22860 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22861   (eval "$ac_compile") 2>conftest.er1
22862   ac_status=$?
22863   grep -v '^ *+' conftest.er1 >conftest.err
22864   rm -f conftest.er1
22865   cat conftest.err >&5
22866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22867   (exit $ac_status); } && {
22868          test -z "$ac_c_werror_flag" ||
22869          test ! -s conftest.err
22870        } && test -s conftest.$ac_objext; then
22871   ac_cv_type_double=yes
22872 else
22873   echo "$as_me: failed program was:" >&5
22874 sed 's/^/| /' conftest.$ac_ext >&5
22875
22876         ac_cv_type_double=no
22877 fi
22878
22879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22880 fi
22881 { echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
22882 echo "${ECHO_T}$ac_cv_type_double" >&6; }
22883
22884 # The cast to long int works around a bug in the HP C Compiler,
22885 # see AC_CHECK_SIZEOF for more information.
22886 { echo "$as_me:$LINENO: checking alignment of double" >&5
22887 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6; }
22888 if test "${ac_cv_alignof_double+set}" = set; then
22889   echo $ECHO_N "(cached) $ECHO_C" >&6
22890 else
22891   if test "$cross_compiling" = yes; then
22892   # Depending upon the size, compute the lo and hi bounds.
22893 cat >conftest.$ac_ext <<_ACEOF
22894 /* confdefs.h.  */
22895 _ACEOF
22896 cat confdefs.h >>conftest.$ac_ext
22897 cat >>conftest.$ac_ext <<_ACEOF
22898 /* end confdefs.h.  */
22899 $ac_includes_default
22900 #ifndef offsetof
22901 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22902 #endif
22903 typedef struct { char x; double y; } ac__type_alignof_;
22904 int
22905 main ()
22906 {
22907 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
22908 test_array [0] = 0
22909
22910   ;
22911   return 0;
22912 }
22913 _ACEOF
22914 rm -f conftest.$ac_objext
22915 if { (ac_try="$ac_compile"
22916 case "(($ac_try" in
22917   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22918   *) ac_try_echo=$ac_try;;
22919 esac
22920 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22921   (eval "$ac_compile") 2>conftest.er1
22922   ac_status=$?
22923   grep -v '^ *+' conftest.er1 >conftest.err
22924   rm -f conftest.er1
22925   cat conftest.err >&5
22926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22927   (exit $ac_status); } && {
22928          test -z "$ac_c_werror_flag" ||
22929          test ! -s conftest.err
22930        } && test -s conftest.$ac_objext; then
22931   ac_lo=0 ac_mid=0
22932   while :; do
22933     cat >conftest.$ac_ext <<_ACEOF
22934 /* confdefs.h.  */
22935 _ACEOF
22936 cat confdefs.h >>conftest.$ac_ext
22937 cat >>conftest.$ac_ext <<_ACEOF
22938 /* end confdefs.h.  */
22939 $ac_includes_default
22940 #ifndef offsetof
22941 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22942 #endif
22943 typedef struct { char x; double y; } ac__type_alignof_;
22944 int
22945 main ()
22946 {
22947 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22948 test_array [0] = 0
22949
22950   ;
22951   return 0;
22952 }
22953 _ACEOF
22954 rm -f conftest.$ac_objext
22955 if { (ac_try="$ac_compile"
22956 case "(($ac_try" in
22957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22958   *) ac_try_echo=$ac_try;;
22959 esac
22960 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22961   (eval "$ac_compile") 2>conftest.er1
22962   ac_status=$?
22963   grep -v '^ *+' conftest.er1 >conftest.err
22964   rm -f conftest.er1
22965   cat conftest.err >&5
22966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22967   (exit $ac_status); } && {
22968          test -z "$ac_c_werror_flag" ||
22969          test ! -s conftest.err
22970        } && test -s conftest.$ac_objext; then
22971   ac_hi=$ac_mid; break
22972 else
22973   echo "$as_me: failed program was:" >&5
22974 sed 's/^/| /' conftest.$ac_ext >&5
22975
22976         ac_lo=`expr $ac_mid + 1`
22977                         if test $ac_lo -le $ac_mid; then
22978                           ac_lo= ac_hi=
22979                           break
22980                         fi
22981                         ac_mid=`expr 2 '*' $ac_mid + 1`
22982 fi
22983
22984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22985   done
22986 else
22987   echo "$as_me: failed program was:" >&5
22988 sed 's/^/| /' conftest.$ac_ext >&5
22989
22990         cat >conftest.$ac_ext <<_ACEOF
22991 /* confdefs.h.  */
22992 _ACEOF
22993 cat confdefs.h >>conftest.$ac_ext
22994 cat >>conftest.$ac_ext <<_ACEOF
22995 /* end confdefs.h.  */
22996 $ac_includes_default
22997 #ifndef offsetof
22998 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22999 #endif
23000 typedef struct { char x; double y; } ac__type_alignof_;
23001 int
23002 main ()
23003 {
23004 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
23005 test_array [0] = 0
23006
23007   ;
23008   return 0;
23009 }
23010 _ACEOF
23011 rm -f conftest.$ac_objext
23012 if { (ac_try="$ac_compile"
23013 case "(($ac_try" in
23014   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23015   *) ac_try_echo=$ac_try;;
23016 esac
23017 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23018   (eval "$ac_compile") 2>conftest.er1
23019   ac_status=$?
23020   grep -v '^ *+' conftest.er1 >conftest.err
23021   rm -f conftest.er1
23022   cat conftest.err >&5
23023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23024   (exit $ac_status); } && {
23025          test -z "$ac_c_werror_flag" ||
23026          test ! -s conftest.err
23027        } && test -s conftest.$ac_objext; then
23028   ac_hi=-1 ac_mid=-1
23029   while :; do
23030     cat >conftest.$ac_ext <<_ACEOF
23031 /* confdefs.h.  */
23032 _ACEOF
23033 cat confdefs.h >>conftest.$ac_ext
23034 cat >>conftest.$ac_ext <<_ACEOF
23035 /* end confdefs.h.  */
23036 $ac_includes_default
23037 #ifndef offsetof
23038 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23039 #endif
23040 typedef struct { char x; double y; } ac__type_alignof_;
23041 int
23042 main ()
23043 {
23044 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
23045 test_array [0] = 0
23046
23047   ;
23048   return 0;
23049 }
23050 _ACEOF
23051 rm -f conftest.$ac_objext
23052 if { (ac_try="$ac_compile"
23053 case "(($ac_try" in
23054   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23055   *) ac_try_echo=$ac_try;;
23056 esac
23057 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23058   (eval "$ac_compile") 2>conftest.er1
23059   ac_status=$?
23060   grep -v '^ *+' conftest.er1 >conftest.err
23061   rm -f conftest.er1
23062   cat conftest.err >&5
23063   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23064   (exit $ac_status); } && {
23065          test -z "$ac_c_werror_flag" ||
23066          test ! -s conftest.err
23067        } && test -s conftest.$ac_objext; then
23068   ac_lo=$ac_mid; break
23069 else
23070   echo "$as_me: failed program was:" >&5
23071 sed 's/^/| /' conftest.$ac_ext >&5
23072
23073         ac_hi=`expr '(' $ac_mid ')' - 1`
23074                         if test $ac_mid -le $ac_hi; then
23075                           ac_lo= ac_hi=
23076                           break
23077                         fi
23078                         ac_mid=`expr 2 '*' $ac_mid`
23079 fi
23080
23081 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23082   done
23083 else
23084   echo "$as_me: failed program was:" >&5
23085 sed 's/^/| /' conftest.$ac_ext >&5
23086
23087         ac_lo= ac_hi=
23088 fi
23089
23090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23091 fi
23092
23093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23094 # Binary search between lo and hi bounds.
23095 while test "x$ac_lo" != "x$ac_hi"; do
23096   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
23097   cat >conftest.$ac_ext <<_ACEOF
23098 /* confdefs.h.  */
23099 _ACEOF
23100 cat confdefs.h >>conftest.$ac_ext
23101 cat >>conftest.$ac_ext <<_ACEOF
23102 /* end confdefs.h.  */
23103 $ac_includes_default
23104 #ifndef offsetof
23105 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23106 #endif
23107 typedef struct { char x; double y; } ac__type_alignof_;
23108 int
23109 main ()
23110 {
23111 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
23112 test_array [0] = 0
23113
23114   ;
23115   return 0;
23116 }
23117 _ACEOF
23118 rm -f conftest.$ac_objext
23119 if { (ac_try="$ac_compile"
23120 case "(($ac_try" in
23121   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23122   *) ac_try_echo=$ac_try;;
23123 esac
23124 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23125   (eval "$ac_compile") 2>conftest.er1
23126   ac_status=$?
23127   grep -v '^ *+' conftest.er1 >conftest.err
23128   rm -f conftest.er1
23129   cat conftest.err >&5
23130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23131   (exit $ac_status); } && {
23132          test -z "$ac_c_werror_flag" ||
23133          test ! -s conftest.err
23134        } && test -s conftest.$ac_objext; then
23135   ac_hi=$ac_mid
23136 else
23137   echo "$as_me: failed program was:" >&5
23138 sed 's/^/| /' conftest.$ac_ext >&5
23139
23140         ac_lo=`expr '(' $ac_mid ')' + 1`
23141 fi
23142
23143 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23144 done
23145 case $ac_lo in
23146 ?*) ac_cv_alignof_double=$ac_lo;;
23147 '') if test "$ac_cv_type_double" = yes; then
23148      { { echo "$as_me:$LINENO: error: cannot compute alignment of double
23149 See \`config.log' for more details." >&5
23150 echo "$as_me: error: cannot compute alignment of double
23151 See \`config.log' for more details." >&2;}
23152    { (exit 77); exit 77; }; }
23153    else
23154      ac_cv_alignof_double=0
23155    fi ;;
23156 esac
23157 else
23158   cat >conftest.$ac_ext <<_ACEOF
23159 /* confdefs.h.  */
23160 _ACEOF
23161 cat confdefs.h >>conftest.$ac_ext
23162 cat >>conftest.$ac_ext <<_ACEOF
23163 /* end confdefs.h.  */
23164 $ac_includes_default
23165 #ifndef offsetof
23166 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23167 #endif
23168 typedef struct { char x; double y; } ac__type_alignof_;
23169 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
23170 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
23171 #include <stdio.h>
23172 #include <stdlib.h>
23173 int
23174 main ()
23175 {
23176
23177   FILE *f = fopen ("conftest.val", "w");
23178   if (! f)
23179     return 1;
23180   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
23181     {
23182       long int i = longval ();
23183       if (i != ((long int) offsetof (ac__type_alignof_, y)))
23184         return 1;
23185       fprintf (f, "%ld\n", i);
23186     }
23187   else
23188     {
23189       unsigned long int i = ulongval ();
23190       if (i != ((long int) offsetof (ac__type_alignof_, y)))
23191         return 1;
23192       fprintf (f, "%lu\n", i);
23193     }
23194   return ferror (f) || fclose (f) != 0;
23195
23196   ;
23197   return 0;
23198 }
23199 _ACEOF
23200 rm -f conftest$ac_exeext
23201 if { (ac_try="$ac_link"
23202 case "(($ac_try" in
23203   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23204   *) ac_try_echo=$ac_try;;
23205 esac
23206 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23207   (eval "$ac_link") 2>&5
23208   ac_status=$?
23209   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23210   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23211   { (case "(($ac_try" in
23212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23213   *) ac_try_echo=$ac_try;;
23214 esac
23215 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23216   (eval "$ac_try") 2>&5
23217   ac_status=$?
23218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23219   (exit $ac_status); }; }; then
23220   ac_cv_alignof_double=`cat conftest.val`
23221 else
23222   echo "$as_me: program exited with status $ac_status" >&5
23223 echo "$as_me: failed program was:" >&5
23224 sed 's/^/| /' conftest.$ac_ext >&5
23225
23226 ( exit $ac_status )
23227 if test "$ac_cv_type_double" = yes; then
23228      { { echo "$as_me:$LINENO: error: cannot compute alignment of double
23229 See \`config.log' for more details." >&5
23230 echo "$as_me: error: cannot compute alignment of double
23231 See \`config.log' for more details." >&2;}
23232    { (exit 77); exit 77; }; }
23233    else
23234      ac_cv_alignof_double=0
23235    fi
23236 fi
23237 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23238 fi
23239 rm -f conftest.val
23240 fi
23241 { echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
23242 echo "${ECHO_T}$ac_cv_alignof_double" >&6; }
23243
23244
23245
23246 cat >>confdefs.h <<_ACEOF
23247 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
23248 _ACEOF
23249
23250
23251
23252 # Compute maximum alignment of any basic type.
23253 # We assume long's alignment is at least as strong as char, short, or int;
23254 # but we must check long long (if it exists) and double.
23255
23256 MAX_ALIGNOF=$ac_cv_alignof_long
23257 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
23258   MAX_ALIGNOF=$ac_cv_alignof_double
23259 fi
23260 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
23261   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
23262 fi
23263
23264 cat >>confdefs.h <<_ACEOF
23265 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
23266 _ACEOF
23267
23268
23269
23270 # Some platforms predefine the types int8, int16, etc.  Only check
23271 # a (hopefully) representative subset.
23272 { echo "$as_me:$LINENO: checking for int8" >&5
23273 echo $ECHO_N "checking for int8... $ECHO_C" >&6; }
23274 if test "${ac_cv_type_int8+set}" = set; then
23275   echo $ECHO_N "(cached) $ECHO_C" >&6
23276 else
23277   cat >conftest.$ac_ext <<_ACEOF
23278 /* confdefs.h.  */
23279 _ACEOF
23280 cat confdefs.h >>conftest.$ac_ext
23281 cat >>conftest.$ac_ext <<_ACEOF
23282 /* end confdefs.h.  */
23283 #include <stdio.h>
23284 #ifdef HAVE_SUPPORTDEFS_H
23285 #include <SupportDefs.h>
23286 #endif
23287
23288 typedef int8 ac__type_new_;
23289 int
23290 main ()
23291 {
23292 if ((ac__type_new_ *) 0)
23293   return 0;
23294 if (sizeof (ac__type_new_))
23295   return 0;
23296   ;
23297   return 0;
23298 }
23299 _ACEOF
23300 rm -f conftest.$ac_objext
23301 if { (ac_try="$ac_compile"
23302 case "(($ac_try" in
23303   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23304   *) ac_try_echo=$ac_try;;
23305 esac
23306 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23307   (eval "$ac_compile") 2>conftest.er1
23308   ac_status=$?
23309   grep -v '^ *+' conftest.er1 >conftest.err
23310   rm -f conftest.er1
23311   cat conftest.err >&5
23312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23313   (exit $ac_status); } && {
23314          test -z "$ac_c_werror_flag" ||
23315          test ! -s conftest.err
23316        } && test -s conftest.$ac_objext; then
23317   ac_cv_type_int8=yes
23318 else
23319   echo "$as_me: failed program was:" >&5
23320 sed 's/^/| /' conftest.$ac_ext >&5
23321
23322         ac_cv_type_int8=no
23323 fi
23324
23325 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23326 fi
23327 { echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
23328 echo "${ECHO_T}$ac_cv_type_int8" >&6; }
23329 if test $ac_cv_type_int8 = yes; then
23330
23331 cat >>confdefs.h <<_ACEOF
23332 #define HAVE_INT8 1
23333 _ACEOF
23334
23335
23336 fi
23337 { echo "$as_me:$LINENO: checking for uint8" >&5
23338 echo $ECHO_N "checking for uint8... $ECHO_C" >&6; }
23339 if test "${ac_cv_type_uint8+set}" = set; then
23340   echo $ECHO_N "(cached) $ECHO_C" >&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 #include <stdio.h>
23349 #ifdef HAVE_SUPPORTDEFS_H
23350 #include <SupportDefs.h>
23351 #endif
23352
23353 typedef uint8 ac__type_new_;
23354 int
23355 main ()
23356 {
23357 if ((ac__type_new_ *) 0)
23358   return 0;
23359 if (sizeof (ac__type_new_))
23360   return 0;
23361   ;
23362   return 0;
23363 }
23364 _ACEOF
23365 rm -f conftest.$ac_objext
23366 if { (ac_try="$ac_compile"
23367 case "(($ac_try" in
23368   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23369   *) ac_try_echo=$ac_try;;
23370 esac
23371 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23372   (eval "$ac_compile") 2>conftest.er1
23373   ac_status=$?
23374   grep -v '^ *+' conftest.er1 >conftest.err
23375   rm -f conftest.er1
23376   cat conftest.err >&5
23377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23378   (exit $ac_status); } && {
23379          test -z "$ac_c_werror_flag" ||
23380          test ! -s conftest.err
23381        } && test -s conftest.$ac_objext; then
23382   ac_cv_type_uint8=yes
23383 else
23384   echo "$as_me: failed program was:" >&5
23385 sed 's/^/| /' conftest.$ac_ext >&5
23386
23387         ac_cv_type_uint8=no
23388 fi
23389
23390 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23391 fi
23392 { echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
23393 echo "${ECHO_T}$ac_cv_type_uint8" >&6; }
23394 if test $ac_cv_type_uint8 = yes; then
23395
23396 cat >>confdefs.h <<_ACEOF
23397 #define HAVE_UINT8 1
23398 _ACEOF
23399
23400
23401 fi
23402 { echo "$as_me:$LINENO: checking for int64" >&5
23403 echo $ECHO_N "checking for int64... $ECHO_C" >&6; }
23404 if test "${ac_cv_type_int64+set}" = set; then
23405   echo $ECHO_N "(cached) $ECHO_C" >&6
23406 else
23407   cat >conftest.$ac_ext <<_ACEOF
23408 /* confdefs.h.  */
23409 _ACEOF
23410 cat confdefs.h >>conftest.$ac_ext
23411 cat >>conftest.$ac_ext <<_ACEOF
23412 /* end confdefs.h.  */
23413 #include <stdio.h>
23414 #ifdef HAVE_SUPPORTDEFS_H
23415 #include <SupportDefs.h>
23416 #endif
23417
23418 typedef int64 ac__type_new_;
23419 int
23420 main ()
23421 {
23422 if ((ac__type_new_ *) 0)
23423   return 0;
23424 if (sizeof (ac__type_new_))
23425   return 0;
23426   ;
23427   return 0;
23428 }
23429 _ACEOF
23430 rm -f conftest.$ac_objext
23431 if { (ac_try="$ac_compile"
23432 case "(($ac_try" in
23433   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23434   *) ac_try_echo=$ac_try;;
23435 esac
23436 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23437   (eval "$ac_compile") 2>conftest.er1
23438   ac_status=$?
23439   grep -v '^ *+' conftest.er1 >conftest.err
23440   rm -f conftest.er1
23441   cat conftest.err >&5
23442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23443   (exit $ac_status); } && {
23444          test -z "$ac_c_werror_flag" ||
23445          test ! -s conftest.err
23446        } && test -s conftest.$ac_objext; then
23447   ac_cv_type_int64=yes
23448 else
23449   echo "$as_me: failed program was:" >&5
23450 sed 's/^/| /' conftest.$ac_ext >&5
23451
23452         ac_cv_type_int64=no
23453 fi
23454
23455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23456 fi
23457 { echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
23458 echo "${ECHO_T}$ac_cv_type_int64" >&6; }
23459 if test $ac_cv_type_int64 = yes; then
23460
23461 cat >>confdefs.h <<_ACEOF
23462 #define HAVE_INT64 1
23463 _ACEOF
23464
23465
23466 fi
23467 { echo "$as_me:$LINENO: checking for uint64" >&5
23468 echo $ECHO_N "checking for uint64... $ECHO_C" >&6; }
23469 if test "${ac_cv_type_uint64+set}" = set; then
23470   echo $ECHO_N "(cached) $ECHO_C" >&6
23471 else
23472   cat >conftest.$ac_ext <<_ACEOF
23473 /* confdefs.h.  */
23474 _ACEOF
23475 cat confdefs.h >>conftest.$ac_ext
23476 cat >>conftest.$ac_ext <<_ACEOF
23477 /* end confdefs.h.  */
23478 #include <stdio.h>
23479 #ifdef HAVE_SUPPORTDEFS_H
23480 #include <SupportDefs.h>
23481 #endif
23482
23483 typedef uint64 ac__type_new_;
23484 int
23485 main ()
23486 {
23487 if ((ac__type_new_ *) 0)
23488   return 0;
23489 if (sizeof (ac__type_new_))
23490   return 0;
23491   ;
23492   return 0;
23493 }
23494 _ACEOF
23495 rm -f conftest.$ac_objext
23496 if { (ac_try="$ac_compile"
23497 case "(($ac_try" in
23498   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23499   *) ac_try_echo=$ac_try;;
23500 esac
23501 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23502   (eval "$ac_compile") 2>conftest.er1
23503   ac_status=$?
23504   grep -v '^ *+' conftest.er1 >conftest.err
23505   rm -f conftest.er1
23506   cat conftest.err >&5
23507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23508   (exit $ac_status); } && {
23509          test -z "$ac_c_werror_flag" ||
23510          test ! -s conftest.err
23511        } && test -s conftest.$ac_objext; then
23512   ac_cv_type_uint64=yes
23513 else
23514   echo "$as_me: failed program was:" >&5
23515 sed 's/^/| /' conftest.$ac_ext >&5
23516
23517         ac_cv_type_uint64=no
23518 fi
23519
23520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23521 fi
23522 { echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
23523 echo "${ECHO_T}$ac_cv_type_uint64" >&6; }
23524 if test $ac_cv_type_uint64 = yes; then
23525
23526 cat >>confdefs.h <<_ACEOF
23527 #define HAVE_UINT64 1
23528 _ACEOF
23529
23530
23531 fi
23532
23533
23534 # We also check for sig_atomic_t, which *should* be defined per ANSI
23535 # C, but is missing on some old platforms.
23536 { echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
23537 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6; }
23538 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
23539   echo $ECHO_N "(cached) $ECHO_C" >&6
23540 else
23541   cat >conftest.$ac_ext <<_ACEOF
23542 /* confdefs.h.  */
23543 _ACEOF
23544 cat confdefs.h >>conftest.$ac_ext
23545 cat >>conftest.$ac_ext <<_ACEOF
23546 /* end confdefs.h.  */
23547 #include <signal.h>
23548
23549 typedef sig_atomic_t ac__type_new_;
23550 int
23551 main ()
23552 {
23553 if ((ac__type_new_ *) 0)
23554   return 0;
23555 if (sizeof (ac__type_new_))
23556   return 0;
23557   ;
23558   return 0;
23559 }
23560 _ACEOF
23561 rm -f conftest.$ac_objext
23562 if { (ac_try="$ac_compile"
23563 case "(($ac_try" in
23564   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23565   *) ac_try_echo=$ac_try;;
23566 esac
23567 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23568   (eval "$ac_compile") 2>conftest.er1
23569   ac_status=$?
23570   grep -v '^ *+' conftest.er1 >conftest.err
23571   rm -f conftest.er1
23572   cat conftest.err >&5
23573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23574   (exit $ac_status); } && {
23575          test -z "$ac_c_werror_flag" ||
23576          test ! -s conftest.err
23577        } && test -s conftest.$ac_objext; then
23578   ac_cv_type_sig_atomic_t=yes
23579 else
23580   echo "$as_me: failed program was:" >&5
23581 sed 's/^/| /' conftest.$ac_ext >&5
23582
23583         ac_cv_type_sig_atomic_t=no
23584 fi
23585
23586 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23587 fi
23588 { echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
23589 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6; }
23590 if test $ac_cv_type_sig_atomic_t = yes; then
23591
23592 cat >>confdefs.h <<_ACEOF
23593 #define HAVE_SIG_ATOMIC_T 1
23594 _ACEOF
23595
23596
23597 fi
23598
23599
23600
23601 # If the user did not disable integer datetimes, check that
23602 # there is a working 64-bit integral type to use.
23603 if test x"$USE_INTEGER_DATETIMES" = x"yes" &&
23604    test x"$HAVE_LONG_INT_64" = x"no" &&
23605    test x"$HAVE_LONG_LONG_INT_64" = x"no" &&
23606    test x"$HAVE_INT64" = x"no" ; then
23607   { { echo "$as_me:$LINENO: error:
23608 Integer-based datetime support requires a 64-bit integer type,
23609 but no such type could be found. The --disable-integer-datetimes
23610 configure option can be used to disable integer-based storage
23611 of datetime values." >&5
23612 echo "$as_me: error:
23613 Integer-based datetime support requires a 64-bit integer type,
23614 but no such type could be found. The --disable-integer-datetimes
23615 configure option can be used to disable integer-based storage
23616 of datetime values." >&2;}
23617    { (exit 1); exit 1; }; }
23618 fi
23619
23620
23621 if test "$PORTNAME" != "win32"
23622 then
23623 { echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
23624 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6; }
23625 if test "${pgac_cv_func_posix_signals+set}" = set; then
23626   echo $ECHO_N "(cached) $ECHO_C" >&6
23627 else
23628   cat >conftest.$ac_ext <<_ACEOF
23629 /* confdefs.h.  */
23630 _ACEOF
23631 cat confdefs.h >>conftest.$ac_ext
23632 cat >>conftest.$ac_ext <<_ACEOF
23633 /* end confdefs.h.  */
23634 #include <signal.h>
23635
23636 int
23637 main ()
23638 {
23639 struct sigaction act, oact;
23640 sigemptyset(&act.sa_mask);
23641 act.sa_flags = SA_RESTART;
23642 sigaction(0, &act, &oact);
23643   ;
23644   return 0;
23645 }
23646 _ACEOF
23647 rm -f conftest.$ac_objext conftest$ac_exeext
23648 if { (ac_try="$ac_link"
23649 case "(($ac_try" in
23650   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23651   *) ac_try_echo=$ac_try;;
23652 esac
23653 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23654   (eval "$ac_link") 2>conftest.er1
23655   ac_status=$?
23656   grep -v '^ *+' conftest.er1 >conftest.err
23657   rm -f conftest.er1
23658   cat conftest.err >&5
23659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23660   (exit $ac_status); } && {
23661          test -z "$ac_c_werror_flag" ||
23662          test ! -s conftest.err
23663        } && test -s conftest$ac_exeext &&
23664        $as_test_x conftest$ac_exeext; then
23665   pgac_cv_func_posix_signals=yes
23666 else
23667   echo "$as_me: failed program was:" >&5
23668 sed 's/^/| /' conftest.$ac_ext >&5
23669
23670         pgac_cv_func_posix_signals=no
23671 fi
23672
23673 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23674       conftest$ac_exeext conftest.$ac_ext
23675 fi
23676 { echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
23677 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6; }
23678 if test x"$pgac_cv_func_posix_signals" = xyes ; then
23679
23680 cat >>confdefs.h <<\_ACEOF
23681 #define HAVE_POSIX_SIGNALS
23682 _ACEOF
23683
23684 fi
23685 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
23686
23687 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
23688   { { echo "$as_me:$LINENO: error:
23689 Thread-safety requires POSIX signals, which are not supported by this
23690 operating system." >&5
23691 echo "$as_me: error:
23692 Thread-safety requires POSIX signals, which are not supported by this
23693 operating system." >&2;}
23694    { (exit 1); exit 1; }; }
23695 fi
23696 fi
23697
23698 if test $ac_cv_func_fseeko = yes; then
23699 # Check whether --enable-largefile was given.
23700 if test "${enable_largefile+set}" = set; then
23701   enableval=$enable_largefile;
23702 fi
23703
23704 if test "$enable_largefile" != no; then
23705
23706   { echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
23707 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6; }
23708 if test "${ac_cv_sys_largefile_CC+set}" = set; then
23709   echo $ECHO_N "(cached) $ECHO_C" >&6
23710 else
23711   ac_cv_sys_largefile_CC=no
23712      if test "$GCC" != yes; then
23713        ac_save_CC=$CC
23714        while :; do
23715          # IRIX 6.2 and later do not support large files by default,
23716          # so use the C compiler's -n32 option if that helps.
23717          cat >conftest.$ac_ext <<_ACEOF
23718 /* confdefs.h.  */
23719 _ACEOF
23720 cat confdefs.h >>conftest.$ac_ext
23721 cat >>conftest.$ac_ext <<_ACEOF
23722 /* end confdefs.h.  */
23723 #include <sys/types.h>
23724  /* Check that off_t can represent 2**63 - 1 correctly.
23725     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23726     since some C++ compilers masquerading as C compilers
23727     incorrectly reject 9223372036854775807.  */
23728 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23729   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23730                        && LARGE_OFF_T % 2147483647 == 1)
23731                       ? 1 : -1];
23732 int
23733 main ()
23734 {
23735
23736   ;
23737   return 0;
23738 }
23739 _ACEOF
23740          rm -f conftest.$ac_objext
23741 if { (ac_try="$ac_compile"
23742 case "(($ac_try" in
23743   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23744   *) ac_try_echo=$ac_try;;
23745 esac
23746 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23747   (eval "$ac_compile") 2>conftest.er1
23748   ac_status=$?
23749   grep -v '^ *+' conftest.er1 >conftest.err
23750   rm -f conftest.er1
23751   cat conftest.err >&5
23752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23753   (exit $ac_status); } && {
23754          test -z "$ac_c_werror_flag" ||
23755          test ! -s conftest.err
23756        } && test -s conftest.$ac_objext; then
23757   break
23758 else
23759   echo "$as_me: failed program was:" >&5
23760 sed 's/^/| /' conftest.$ac_ext >&5
23761
23762
23763 fi
23764
23765 rm -f core conftest.err conftest.$ac_objext
23766          CC="$CC -n32"
23767          rm -f conftest.$ac_objext
23768 if { (ac_try="$ac_compile"
23769 case "(($ac_try" in
23770   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23771   *) ac_try_echo=$ac_try;;
23772 esac
23773 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23774   (eval "$ac_compile") 2>conftest.er1
23775   ac_status=$?
23776   grep -v '^ *+' conftest.er1 >conftest.err
23777   rm -f conftest.er1
23778   cat conftest.err >&5
23779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23780   (exit $ac_status); } && {
23781          test -z "$ac_c_werror_flag" ||
23782          test ! -s conftest.err
23783        } && test -s conftest.$ac_objext; then
23784   ac_cv_sys_largefile_CC=' -n32'; break
23785 else
23786   echo "$as_me: failed program was:" >&5
23787 sed 's/^/| /' conftest.$ac_ext >&5
23788
23789
23790 fi
23791
23792 rm -f core conftest.err conftest.$ac_objext
23793          break
23794        done
23795        CC=$ac_save_CC
23796        rm -f conftest.$ac_ext
23797     fi
23798 fi
23799 { echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
23800 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6; }
23801   if test "$ac_cv_sys_largefile_CC" != no; then
23802     CC=$CC$ac_cv_sys_largefile_CC
23803   fi
23804
23805   { echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
23806 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6; }
23807 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
23808   echo $ECHO_N "(cached) $ECHO_C" >&6
23809 else
23810   while :; do
23811   cat >conftest.$ac_ext <<_ACEOF
23812 /* confdefs.h.  */
23813 _ACEOF
23814 cat confdefs.h >>conftest.$ac_ext
23815 cat >>conftest.$ac_ext <<_ACEOF
23816 /* end confdefs.h.  */
23817 #include <sys/types.h>
23818  /* Check that off_t can represent 2**63 - 1 correctly.
23819     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23820     since some C++ compilers masquerading as C compilers
23821     incorrectly reject 9223372036854775807.  */
23822 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23823   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23824                        && LARGE_OFF_T % 2147483647 == 1)
23825                       ? 1 : -1];
23826 int
23827 main ()
23828 {
23829
23830   ;
23831   return 0;
23832 }
23833 _ACEOF
23834 rm -f conftest.$ac_objext
23835 if { (ac_try="$ac_compile"
23836 case "(($ac_try" in
23837   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23838   *) ac_try_echo=$ac_try;;
23839 esac
23840 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23841   (eval "$ac_compile") 2>conftest.er1
23842   ac_status=$?
23843   grep -v '^ *+' conftest.er1 >conftest.err
23844   rm -f conftest.er1
23845   cat conftest.err >&5
23846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23847   (exit $ac_status); } && {
23848          test -z "$ac_c_werror_flag" ||
23849          test ! -s conftest.err
23850        } && test -s conftest.$ac_objext; then
23851   ac_cv_sys_file_offset_bits=no; break
23852 else
23853   echo "$as_me: failed program was:" >&5
23854 sed 's/^/| /' conftest.$ac_ext >&5
23855
23856
23857 fi
23858
23859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23860   cat >conftest.$ac_ext <<_ACEOF
23861 /* confdefs.h.  */
23862 _ACEOF
23863 cat confdefs.h >>conftest.$ac_ext
23864 cat >>conftest.$ac_ext <<_ACEOF
23865 /* end confdefs.h.  */
23866 #define _FILE_OFFSET_BITS 64
23867 #include <sys/types.h>
23868  /* Check that off_t can represent 2**63 - 1 correctly.
23869     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23870     since some C++ compilers masquerading as C compilers
23871     incorrectly reject 9223372036854775807.  */
23872 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23873   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23874                        && LARGE_OFF_T % 2147483647 == 1)
23875                       ? 1 : -1];
23876 int
23877 main ()
23878 {
23879
23880   ;
23881   return 0;
23882 }
23883 _ACEOF
23884 rm -f conftest.$ac_objext
23885 if { (ac_try="$ac_compile"
23886 case "(($ac_try" in
23887   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23888   *) ac_try_echo=$ac_try;;
23889 esac
23890 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23891   (eval "$ac_compile") 2>conftest.er1
23892   ac_status=$?
23893   grep -v '^ *+' conftest.er1 >conftest.err
23894   rm -f conftest.er1
23895   cat conftest.err >&5
23896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23897   (exit $ac_status); } && {
23898          test -z "$ac_c_werror_flag" ||
23899          test ! -s conftest.err
23900        } && test -s conftest.$ac_objext; then
23901   ac_cv_sys_file_offset_bits=64; break
23902 else
23903   echo "$as_me: failed program was:" >&5
23904 sed 's/^/| /' conftest.$ac_ext >&5
23905
23906
23907 fi
23908
23909 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23910   ac_cv_sys_file_offset_bits=unknown
23911   break
23912 done
23913 fi
23914 { echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
23915 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6; }
23916 case $ac_cv_sys_file_offset_bits in #(
23917   no | unknown) ;;
23918   *)
23919 cat >>confdefs.h <<_ACEOF
23920 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
23921 _ACEOF
23922 ;;
23923 esac
23924 rm -f conftest*
23925   if test $ac_cv_sys_file_offset_bits = unknown; then
23926     { echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
23927 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6; }
23928 if test "${ac_cv_sys_large_files+set}" = set; then
23929   echo $ECHO_N "(cached) $ECHO_C" >&6
23930 else
23931   while :; do
23932   cat >conftest.$ac_ext <<_ACEOF
23933 /* confdefs.h.  */
23934 _ACEOF
23935 cat confdefs.h >>conftest.$ac_ext
23936 cat >>conftest.$ac_ext <<_ACEOF
23937 /* end confdefs.h.  */
23938 #include <sys/types.h>
23939  /* Check that off_t can represent 2**63 - 1 correctly.
23940     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23941     since some C++ compilers masquerading as C compilers
23942     incorrectly reject 9223372036854775807.  */
23943 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23944   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23945                        && LARGE_OFF_T % 2147483647 == 1)
23946                       ? 1 : -1];
23947 int
23948 main ()
23949 {
23950
23951   ;
23952   return 0;
23953 }
23954 _ACEOF
23955 rm -f conftest.$ac_objext
23956 if { (ac_try="$ac_compile"
23957 case "(($ac_try" in
23958   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23959   *) ac_try_echo=$ac_try;;
23960 esac
23961 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23962   (eval "$ac_compile") 2>conftest.er1
23963   ac_status=$?
23964   grep -v '^ *+' conftest.er1 >conftest.err
23965   rm -f conftest.er1
23966   cat conftest.err >&5
23967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23968   (exit $ac_status); } && {
23969          test -z "$ac_c_werror_flag" ||
23970          test ! -s conftest.err
23971        } && test -s conftest.$ac_objext; then
23972   ac_cv_sys_large_files=no; break
23973 else
23974   echo "$as_me: failed program was:" >&5
23975 sed 's/^/| /' conftest.$ac_ext >&5
23976
23977
23978 fi
23979
23980 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23981   cat >conftest.$ac_ext <<_ACEOF
23982 /* confdefs.h.  */
23983 _ACEOF
23984 cat confdefs.h >>conftest.$ac_ext
23985 cat >>conftest.$ac_ext <<_ACEOF
23986 /* end confdefs.h.  */
23987 #define _LARGE_FILES 1
23988 #include <sys/types.h>
23989  /* Check that off_t can represent 2**63 - 1 correctly.
23990     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23991     since some C++ compilers masquerading as C compilers
23992     incorrectly reject 9223372036854775807.  */
23993 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23994   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23995                        && LARGE_OFF_T % 2147483647 == 1)
23996                       ? 1 : -1];
23997 int
23998 main ()
23999 {
24000
24001   ;
24002   return 0;
24003 }
24004 _ACEOF
24005 rm -f conftest.$ac_objext
24006 if { (ac_try="$ac_compile"
24007 case "(($ac_try" in
24008   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24009   *) ac_try_echo=$ac_try;;
24010 esac
24011 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24012   (eval "$ac_compile") 2>conftest.er1
24013   ac_status=$?
24014   grep -v '^ *+' conftest.er1 >conftest.err
24015   rm -f conftest.er1
24016   cat conftest.err >&5
24017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24018   (exit $ac_status); } && {
24019          test -z "$ac_c_werror_flag" ||
24020          test ! -s conftest.err
24021        } && test -s conftest.$ac_objext; then
24022   ac_cv_sys_large_files=1; break
24023 else
24024   echo "$as_me: failed program was:" >&5
24025 sed 's/^/| /' conftest.$ac_ext >&5
24026
24027
24028 fi
24029
24030 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24031   ac_cv_sys_large_files=unknown
24032   break
24033 done
24034 fi
24035 { echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
24036 echo "${ECHO_T}$ac_cv_sys_large_files" >&6; }
24037 case $ac_cv_sys_large_files in #(
24038   no | unknown) ;;
24039   *)
24040 cat >>confdefs.h <<_ACEOF
24041 #define _LARGE_FILES $ac_cv_sys_large_files
24042 _ACEOF
24043 ;;
24044 esac
24045 rm -f conftest*
24046   fi
24047 fi
24048
24049 fi
24050
24051 # Check for largefile support (must be after AC_SYS_LARGEFILE)
24052 { echo "$as_me:$LINENO: checking for off_t" >&5
24053 echo $ECHO_N "checking for off_t... $ECHO_C" >&6; }
24054 if test "${ac_cv_type_off_t+set}" = set; then
24055   echo $ECHO_N "(cached) $ECHO_C" >&6
24056 else
24057   cat >conftest.$ac_ext <<_ACEOF
24058 /* confdefs.h.  */
24059 _ACEOF
24060 cat confdefs.h >>conftest.$ac_ext
24061 cat >>conftest.$ac_ext <<_ACEOF
24062 /* end confdefs.h.  */
24063 $ac_includes_default
24064 typedef off_t ac__type_new_;
24065 int
24066 main ()
24067 {
24068 if ((ac__type_new_ *) 0)
24069   return 0;
24070 if (sizeof (ac__type_new_))
24071   return 0;
24072   ;
24073   return 0;
24074 }
24075 _ACEOF
24076 rm -f conftest.$ac_objext
24077 if { (ac_try="$ac_compile"
24078 case "(($ac_try" in
24079   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24080   *) ac_try_echo=$ac_try;;
24081 esac
24082 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24083   (eval "$ac_compile") 2>conftest.er1
24084   ac_status=$?
24085   grep -v '^ *+' conftest.er1 >conftest.err
24086   rm -f conftest.er1
24087   cat conftest.err >&5
24088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24089   (exit $ac_status); } && {
24090          test -z "$ac_c_werror_flag" ||
24091          test ! -s conftest.err
24092        } && test -s conftest.$ac_objext; then
24093   ac_cv_type_off_t=yes
24094 else
24095   echo "$as_me: failed program was:" >&5
24096 sed 's/^/| /' conftest.$ac_ext >&5
24097
24098         ac_cv_type_off_t=no
24099 fi
24100
24101 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24102 fi
24103 { echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
24104 echo "${ECHO_T}$ac_cv_type_off_t" >&6; }
24105
24106 # The cast to long int works around a bug in the HP C Compiler
24107 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24108 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24109 # This bug is HP SR number 8606223364.
24110 { echo "$as_me:$LINENO: checking size of off_t" >&5
24111 echo $ECHO_N "checking size of off_t... $ECHO_C" >&6; }
24112 if test "${ac_cv_sizeof_off_t+set}" = set; then
24113   echo $ECHO_N "(cached) $ECHO_C" >&6
24114 else
24115   if test "$cross_compiling" = yes; then
24116   # Depending upon the size, compute the lo and hi bounds.
24117 cat >conftest.$ac_ext <<_ACEOF
24118 /* confdefs.h.  */
24119 _ACEOF
24120 cat confdefs.h >>conftest.$ac_ext
24121 cat >>conftest.$ac_ext <<_ACEOF
24122 /* end confdefs.h.  */
24123 $ac_includes_default
24124    typedef off_t ac__type_sizeof_;
24125 int
24126 main ()
24127 {
24128 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
24129 test_array [0] = 0
24130
24131   ;
24132   return 0;
24133 }
24134 _ACEOF
24135 rm -f conftest.$ac_objext
24136 if { (ac_try="$ac_compile"
24137 case "(($ac_try" in
24138   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24139   *) ac_try_echo=$ac_try;;
24140 esac
24141 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24142   (eval "$ac_compile") 2>conftest.er1
24143   ac_status=$?
24144   grep -v '^ *+' conftest.er1 >conftest.err
24145   rm -f conftest.er1
24146   cat conftest.err >&5
24147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24148   (exit $ac_status); } && {
24149          test -z "$ac_c_werror_flag" ||
24150          test ! -s conftest.err
24151        } && test -s conftest.$ac_objext; then
24152   ac_lo=0 ac_mid=0
24153   while :; do
24154     cat >conftest.$ac_ext <<_ACEOF
24155 /* confdefs.h.  */
24156 _ACEOF
24157 cat confdefs.h >>conftest.$ac_ext
24158 cat >>conftest.$ac_ext <<_ACEOF
24159 /* end confdefs.h.  */
24160 $ac_includes_default
24161    typedef off_t ac__type_sizeof_;
24162 int
24163 main ()
24164 {
24165 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
24166 test_array [0] = 0
24167
24168   ;
24169   return 0;
24170 }
24171 _ACEOF
24172 rm -f conftest.$ac_objext
24173 if { (ac_try="$ac_compile"
24174 case "(($ac_try" in
24175   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24176   *) ac_try_echo=$ac_try;;
24177 esac
24178 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24179   (eval "$ac_compile") 2>conftest.er1
24180   ac_status=$?
24181   grep -v '^ *+' conftest.er1 >conftest.err
24182   rm -f conftest.er1
24183   cat conftest.err >&5
24184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24185   (exit $ac_status); } && {
24186          test -z "$ac_c_werror_flag" ||
24187          test ! -s conftest.err
24188        } && test -s conftest.$ac_objext; then
24189   ac_hi=$ac_mid; break
24190 else
24191   echo "$as_me: failed program was:" >&5
24192 sed 's/^/| /' conftest.$ac_ext >&5
24193
24194         ac_lo=`expr $ac_mid + 1`
24195                         if test $ac_lo -le $ac_mid; then
24196                           ac_lo= ac_hi=
24197                           break
24198                         fi
24199                         ac_mid=`expr 2 '*' $ac_mid + 1`
24200 fi
24201
24202 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24203   done
24204 else
24205   echo "$as_me: failed program was:" >&5
24206 sed 's/^/| /' conftest.$ac_ext >&5
24207
24208         cat >conftest.$ac_ext <<_ACEOF
24209 /* confdefs.h.  */
24210 _ACEOF
24211 cat confdefs.h >>conftest.$ac_ext
24212 cat >>conftest.$ac_ext <<_ACEOF
24213 /* end confdefs.h.  */
24214 $ac_includes_default
24215    typedef off_t ac__type_sizeof_;
24216 int
24217 main ()
24218 {
24219 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
24220 test_array [0] = 0
24221
24222   ;
24223   return 0;
24224 }
24225 _ACEOF
24226 rm -f conftest.$ac_objext
24227 if { (ac_try="$ac_compile"
24228 case "(($ac_try" in
24229   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24230   *) ac_try_echo=$ac_try;;
24231 esac
24232 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24233   (eval "$ac_compile") 2>conftest.er1
24234   ac_status=$?
24235   grep -v '^ *+' conftest.er1 >conftest.err
24236   rm -f conftest.er1
24237   cat conftest.err >&5
24238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24239   (exit $ac_status); } && {
24240          test -z "$ac_c_werror_flag" ||
24241          test ! -s conftest.err
24242        } && test -s conftest.$ac_objext; then
24243   ac_hi=-1 ac_mid=-1
24244   while :; do
24245     cat >conftest.$ac_ext <<_ACEOF
24246 /* confdefs.h.  */
24247 _ACEOF
24248 cat confdefs.h >>conftest.$ac_ext
24249 cat >>conftest.$ac_ext <<_ACEOF
24250 /* end confdefs.h.  */
24251 $ac_includes_default
24252    typedef off_t ac__type_sizeof_;
24253 int
24254 main ()
24255 {
24256 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
24257 test_array [0] = 0
24258
24259   ;
24260   return 0;
24261 }
24262 _ACEOF
24263 rm -f conftest.$ac_objext
24264 if { (ac_try="$ac_compile"
24265 case "(($ac_try" in
24266   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24267   *) ac_try_echo=$ac_try;;
24268 esac
24269 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24270   (eval "$ac_compile") 2>conftest.er1
24271   ac_status=$?
24272   grep -v '^ *+' conftest.er1 >conftest.err
24273   rm -f conftest.er1
24274   cat conftest.err >&5
24275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24276   (exit $ac_status); } && {
24277          test -z "$ac_c_werror_flag" ||
24278          test ! -s conftest.err
24279        } && test -s conftest.$ac_objext; then
24280   ac_lo=$ac_mid; break
24281 else
24282   echo "$as_me: failed program was:" >&5
24283 sed 's/^/| /' conftest.$ac_ext >&5
24284
24285         ac_hi=`expr '(' $ac_mid ')' - 1`
24286                         if test $ac_mid -le $ac_hi; then
24287                           ac_lo= ac_hi=
24288                           break
24289                         fi
24290                         ac_mid=`expr 2 '*' $ac_mid`
24291 fi
24292
24293 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24294   done
24295 else
24296   echo "$as_me: failed program was:" >&5
24297 sed 's/^/| /' conftest.$ac_ext >&5
24298
24299         ac_lo= ac_hi=
24300 fi
24301
24302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24303 fi
24304
24305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24306 # Binary search between lo and hi bounds.
24307 while test "x$ac_lo" != "x$ac_hi"; do
24308   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24309   cat >conftest.$ac_ext <<_ACEOF
24310 /* confdefs.h.  */
24311 _ACEOF
24312 cat confdefs.h >>conftest.$ac_ext
24313 cat >>conftest.$ac_ext <<_ACEOF
24314 /* end confdefs.h.  */
24315 $ac_includes_default
24316    typedef off_t ac__type_sizeof_;
24317 int
24318 main ()
24319 {
24320 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
24321 test_array [0] = 0
24322
24323   ;
24324   return 0;
24325 }
24326 _ACEOF
24327 rm -f conftest.$ac_objext
24328 if { (ac_try="$ac_compile"
24329 case "(($ac_try" in
24330   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24331   *) ac_try_echo=$ac_try;;
24332 esac
24333 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24334   (eval "$ac_compile") 2>conftest.er1
24335   ac_status=$?
24336   grep -v '^ *+' conftest.er1 >conftest.err
24337   rm -f conftest.er1
24338   cat conftest.err >&5
24339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24340   (exit $ac_status); } && {
24341          test -z "$ac_c_werror_flag" ||
24342          test ! -s conftest.err
24343        } && test -s conftest.$ac_objext; then
24344   ac_hi=$ac_mid
24345 else
24346   echo "$as_me: failed program was:" >&5
24347 sed 's/^/| /' conftest.$ac_ext >&5
24348
24349         ac_lo=`expr '(' $ac_mid ')' + 1`
24350 fi
24351
24352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24353 done
24354 case $ac_lo in
24355 ?*) ac_cv_sizeof_off_t=$ac_lo;;
24356 '') if test "$ac_cv_type_off_t" = yes; then
24357      { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
24358 See \`config.log' for more details." >&5
24359 echo "$as_me: error: cannot compute sizeof (off_t)
24360 See \`config.log' for more details." >&2;}
24361    { (exit 77); exit 77; }; }
24362    else
24363      ac_cv_sizeof_off_t=0
24364    fi ;;
24365 esac
24366 else
24367   cat >conftest.$ac_ext <<_ACEOF
24368 /* confdefs.h.  */
24369 _ACEOF
24370 cat confdefs.h >>conftest.$ac_ext
24371 cat >>conftest.$ac_ext <<_ACEOF
24372 /* end confdefs.h.  */
24373 $ac_includes_default
24374    typedef off_t ac__type_sizeof_;
24375 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
24376 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
24377 #include <stdio.h>
24378 #include <stdlib.h>
24379 int
24380 main ()
24381 {
24382
24383   FILE *f = fopen ("conftest.val", "w");
24384   if (! f)
24385     return 1;
24386   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
24387     {
24388       long int i = longval ();
24389       if (i != ((long int) (sizeof (ac__type_sizeof_))))
24390         return 1;
24391       fprintf (f, "%ld\n", i);
24392     }
24393   else
24394     {
24395       unsigned long int i = ulongval ();
24396       if (i != ((long int) (sizeof (ac__type_sizeof_))))
24397         return 1;
24398       fprintf (f, "%lu\n", i);
24399     }
24400   return ferror (f) || fclose (f) != 0;
24401
24402   ;
24403   return 0;
24404 }
24405 _ACEOF
24406 rm -f conftest$ac_exeext
24407 if { (ac_try="$ac_link"
24408 case "(($ac_try" in
24409   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24410   *) ac_try_echo=$ac_try;;
24411 esac
24412 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24413   (eval "$ac_link") 2>&5
24414   ac_status=$?
24415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24416   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24417   { (case "(($ac_try" in
24418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24419   *) ac_try_echo=$ac_try;;
24420 esac
24421 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24422   (eval "$ac_try") 2>&5
24423   ac_status=$?
24424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24425   (exit $ac_status); }; }; then
24426   ac_cv_sizeof_off_t=`cat conftest.val`
24427 else
24428   echo "$as_me: program exited with status $ac_status" >&5
24429 echo "$as_me: failed program was:" >&5
24430 sed 's/^/| /' conftest.$ac_ext >&5
24431
24432 ( exit $ac_status )
24433 if test "$ac_cv_type_off_t" = yes; then
24434      { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
24435 See \`config.log' for more details." >&5
24436 echo "$as_me: error: cannot compute sizeof (off_t)
24437 See \`config.log' for more details." >&2;}
24438    { (exit 77); exit 77; }; }
24439    else
24440      ac_cv_sizeof_off_t=0
24441    fi
24442 fi
24443 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24444 fi
24445 rm -f conftest.val
24446 fi
24447 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
24448 echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6; }
24449
24450
24451
24452 cat >>confdefs.h <<_ACEOF
24453 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
24454 _ACEOF
24455
24456
24457
24458 # If we don't have largefile support, can't handle segsize >= 2GB.
24459 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
24460    { { echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
24461 echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
24462    { (exit 1); exit 1; }; }
24463 fi
24464
24465 # SunOS doesn't handle negative byte comparisons properly with +/- return
24466 { echo "$as_me:$LINENO: checking for working memcmp" >&5
24467 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6; }
24468 if test "${ac_cv_func_memcmp_working+set}" = set; then
24469   echo $ECHO_N "(cached) $ECHO_C" >&6
24470 else
24471   if test "$cross_compiling" = yes; then
24472   ac_cv_func_memcmp_working=no
24473 else
24474   cat >conftest.$ac_ext <<_ACEOF
24475 /* confdefs.h.  */
24476 _ACEOF
24477 cat confdefs.h >>conftest.$ac_ext
24478 cat >>conftest.$ac_ext <<_ACEOF
24479 /* end confdefs.h.  */
24480 $ac_includes_default
24481 int
24482 main ()
24483 {
24484
24485   /* Some versions of memcmp are not 8-bit clean.  */
24486   char c0 = '\100', c1 = '\200', c2 = '\201';
24487   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
24488     return 1;
24489
24490   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
24491      or more and with at least one buffer not starting on a 4-byte boundary.
24492      William Lewis provided this test program.   */
24493   {
24494     char foo[21];
24495     char bar[21];
24496     int i;
24497     for (i = 0; i < 4; i++)
24498       {
24499         char *a = foo + i;
24500         char *b = bar + i;
24501         strcpy (a, "--------01111111");
24502         strcpy (b, "--------10000000");
24503         if (memcmp (a, b, 16) >= 0)
24504           return 1;
24505       }
24506     return 0;
24507   }
24508
24509   ;
24510   return 0;
24511 }
24512 _ACEOF
24513 rm -f conftest$ac_exeext
24514 if { (ac_try="$ac_link"
24515 case "(($ac_try" in
24516   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24517   *) ac_try_echo=$ac_try;;
24518 esac
24519 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24520   (eval "$ac_link") 2>&5
24521   ac_status=$?
24522   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24523   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24524   { (case "(($ac_try" in
24525   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24526   *) ac_try_echo=$ac_try;;
24527 esac
24528 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24529   (eval "$ac_try") 2>&5
24530   ac_status=$?
24531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24532   (exit $ac_status); }; }; then
24533   ac_cv_func_memcmp_working=yes
24534 else
24535   echo "$as_me: program exited with status $ac_status" >&5
24536 echo "$as_me: failed program was:" >&5
24537 sed 's/^/| /' conftest.$ac_ext >&5
24538
24539 ( exit $ac_status )
24540 ac_cv_func_memcmp_working=no
24541 fi
24542 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24543 fi
24544
24545
24546 fi
24547 { echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
24548 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6; }
24549 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
24550   *" memcmp.$ac_objext "* ) ;;
24551   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
24552  ;;
24553 esac
24554
24555
24556
24557
24558 # Select semaphore implementation type.
24559 if test "$PORTNAME" != "win32"; then
24560   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
24561
24562 cat >>confdefs.h <<\_ACEOF
24563 #define USE_NAMED_POSIX_SEMAPHORES 1
24564 _ACEOF
24565
24566     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
24567   else
24568     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
24569
24570 cat >>confdefs.h <<\_ACEOF
24571 #define USE_UNNAMED_POSIX_SEMAPHORES 1
24572 _ACEOF
24573
24574       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
24575     else
24576
24577 cat >>confdefs.h <<\_ACEOF
24578 #define USE_SYSV_SEMAPHORES 1
24579 _ACEOF
24580
24581       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
24582     fi
24583   fi
24584 else
24585
24586 cat >>confdefs.h <<\_ACEOF
24587 #define USE_WIN32_SEMAPHORES 1
24588 _ACEOF
24589
24590   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
24591 fi
24592
24593
24594 # Select shared-memory implementation type.
24595 if test "$PORTNAME" != "win32"; then
24596
24597 cat >>confdefs.h <<\_ACEOF
24598 #define USE_SYSV_SHARED_MEMORY 1
24599 _ACEOF
24600
24601   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
24602 else
24603
24604 cat >>confdefs.h <<\_ACEOF
24605 #define USE_WIN32_SHARED_MEMORY 1
24606 _ACEOF
24607
24608   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
24609 fi
24610
24611 # If not set in template file, set bytes to use libc memset()
24612 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
24613   MEMSET_LOOP_LIMIT=1024
24614 fi
24615
24616 cat >>confdefs.h <<_ACEOF
24617 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
24618 _ACEOF
24619
24620
24621
24622 if test "$enable_nls" = yes ; then
24623
24624   { echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
24625 echo $ECHO_N "checking for library containing bind_textdomain_codeset... $ECHO_C" >&6; }
24626 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
24627   echo $ECHO_N "(cached) $ECHO_C" >&6
24628 else
24629   ac_func_search_save_LIBS=$LIBS
24630 cat >conftest.$ac_ext <<_ACEOF
24631 /* confdefs.h.  */
24632 _ACEOF
24633 cat confdefs.h >>conftest.$ac_ext
24634 cat >>conftest.$ac_ext <<_ACEOF
24635 /* end confdefs.h.  */
24636
24637 /* Override any GCC internal prototype to avoid an error.
24638    Use char because int might match the return type of a GCC
24639    builtin and then its argument prototype would still apply.  */
24640 #ifdef __cplusplus
24641 extern "C"
24642 #endif
24643 char bind_textdomain_codeset ();
24644 int
24645 main ()
24646 {
24647 return bind_textdomain_codeset ();
24648   ;
24649   return 0;
24650 }
24651 _ACEOF
24652 for ac_lib in '' intl; do
24653   if test -z "$ac_lib"; then
24654     ac_res="none required"
24655   else
24656     ac_res=-l$ac_lib
24657     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24658   fi
24659   rm -f conftest.$ac_objext conftest$ac_exeext
24660 if { (ac_try="$ac_link"
24661 case "(($ac_try" in
24662   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24663   *) ac_try_echo=$ac_try;;
24664 esac
24665 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24666   (eval "$ac_link") 2>conftest.er1
24667   ac_status=$?
24668   grep -v '^ *+' conftest.er1 >conftest.err
24669   rm -f conftest.er1
24670   cat conftest.err >&5
24671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24672   (exit $ac_status); } && {
24673          test -z "$ac_c_werror_flag" ||
24674          test ! -s conftest.err
24675        } && test -s conftest$ac_exeext &&
24676        $as_test_x conftest$ac_exeext; then
24677   ac_cv_search_bind_textdomain_codeset=$ac_res
24678 else
24679   echo "$as_me: failed program was:" >&5
24680 sed 's/^/| /' conftest.$ac_ext >&5
24681
24682
24683 fi
24684
24685 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24686       conftest$ac_exeext
24687   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
24688   break
24689 fi
24690 done
24691 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
24692   :
24693 else
24694   ac_cv_search_bind_textdomain_codeset=no
24695 fi
24696 rm conftest.$ac_ext
24697 LIBS=$ac_func_search_save_LIBS
24698 fi
24699 { echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
24700 echo "${ECHO_T}$ac_cv_search_bind_textdomain_codeset" >&6; }
24701 ac_res=$ac_cv_search_bind_textdomain_codeset
24702 if test "$ac_res" != no; then
24703   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24704
24705 else
24706   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
24707 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
24708    { (exit 1); exit 1; }; }
24709 fi
24710
24711   if test "${ac_cv_header_libintl_h+set}" = set; then
24712   { echo "$as_me:$LINENO: checking for libintl.h" >&5
24713 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6; }
24714 if test "${ac_cv_header_libintl_h+set}" = set; then
24715   echo $ECHO_N "(cached) $ECHO_C" >&6
24716 fi
24717 { echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
24718 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6; }
24719 else
24720   # Is the header compilable?
24721 { echo "$as_me:$LINENO: checking libintl.h usability" >&5
24722 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6; }
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 #include <libintl.h>
24731 _ACEOF
24732 rm -f conftest.$ac_objext
24733 if { (ac_try="$ac_compile"
24734 case "(($ac_try" in
24735   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24736   *) ac_try_echo=$ac_try;;
24737 esac
24738 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24739   (eval "$ac_compile") 2>conftest.er1
24740   ac_status=$?
24741   grep -v '^ *+' conftest.er1 >conftest.err
24742   rm -f conftest.er1
24743   cat conftest.err >&5
24744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24745   (exit $ac_status); } && {
24746          test -z "$ac_c_werror_flag" ||
24747          test ! -s conftest.err
24748        } && test -s conftest.$ac_objext; then
24749   ac_header_compiler=yes
24750 else
24751   echo "$as_me: failed program was:" >&5
24752 sed 's/^/| /' conftest.$ac_ext >&5
24753
24754         ac_header_compiler=no
24755 fi
24756
24757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24758 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24759 echo "${ECHO_T}$ac_header_compiler" >&6; }
24760
24761 # Is the header present?
24762 { echo "$as_me:$LINENO: checking libintl.h presence" >&5
24763 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6; }
24764 cat >conftest.$ac_ext <<_ACEOF
24765 /* confdefs.h.  */
24766 _ACEOF
24767 cat confdefs.h >>conftest.$ac_ext
24768 cat >>conftest.$ac_ext <<_ACEOF
24769 /* end confdefs.h.  */
24770 #include <libintl.h>
24771 _ACEOF
24772 if { (ac_try="$ac_cpp conftest.$ac_ext"
24773 case "(($ac_try" in
24774   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24775   *) ac_try_echo=$ac_try;;
24776 esac
24777 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24778   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
24779   ac_status=$?
24780   grep -v '^ *+' conftest.er1 >conftest.err
24781   rm -f conftest.er1
24782   cat conftest.err >&5
24783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24784   (exit $ac_status); } >/dev/null && {
24785          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
24786          test ! -s conftest.err
24787        }; then
24788   ac_header_preproc=yes
24789 else
24790   echo "$as_me: failed program was:" >&5
24791 sed 's/^/| /' conftest.$ac_ext >&5
24792
24793   ac_header_preproc=no
24794 fi
24795
24796 rm -f conftest.err conftest.$ac_ext
24797 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24798 echo "${ECHO_T}$ac_header_preproc" >&6; }
24799
24800 # So?  What about this header?
24801 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
24802   yes:no: )
24803     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
24804 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
24805     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
24806 echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
24807     ac_header_preproc=yes
24808     ;;
24809   no:yes:* )
24810     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
24811 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
24812     { echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
24813 echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
24814     { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
24815 echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
24816     { echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
24817 echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
24818     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
24819 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
24820     { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
24821 echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
24822     ( cat <<\_ASBOX
24823 ## ---------------------------------------- ##
24824 ## Report this to pgsql-bugs@postgresql.org ##
24825 ## ---------------------------------------- ##
24826 _ASBOX
24827      ) | sed "s/^/$as_me: WARNING:     /" >&2
24828     ;;
24829 esac
24830 { echo "$as_me:$LINENO: checking for libintl.h" >&5
24831 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6; }
24832 if test "${ac_cv_header_libintl_h+set}" = set; then
24833   echo $ECHO_N "(cached) $ECHO_C" >&6
24834 else
24835   ac_cv_header_libintl_h=$ac_header_preproc
24836 fi
24837 { echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
24838 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6; }
24839
24840 fi
24841 if test $ac_cv_header_libintl_h = yes; then
24842   :
24843 else
24844   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
24845 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
24846    { (exit 1); exit 1; }; }
24847 fi
24848
24849
24850   for ac_prog in msgfmt
24851 do
24852   # Extract the first word of "$ac_prog", so it can be a program name with args.
24853 set dummy $ac_prog; ac_word=$2
24854 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24855 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24856 if test "${ac_cv_prog_MSGFMT+set}" = set; then
24857   echo $ECHO_N "(cached) $ECHO_C" >&6
24858 else
24859   if test -n "$MSGFMT"; then
24860   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
24861 else
24862 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24863 for as_dir in $PATH
24864 do
24865   IFS=$as_save_IFS
24866   test -z "$as_dir" && as_dir=.
24867   for ac_exec_ext in '' $ac_executable_extensions; do
24868   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24869     ac_cv_prog_MSGFMT="$ac_prog"
24870     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24871     break 2
24872   fi
24873 done
24874 done
24875 IFS=$as_save_IFS
24876
24877 fi
24878 fi
24879 MSGFMT=$ac_cv_prog_MSGFMT
24880 if test -n "$MSGFMT"; then
24881   { echo "$as_me:$LINENO: result: $MSGFMT" >&5
24882 echo "${ECHO_T}$MSGFMT" >&6; }
24883 else
24884   { echo "$as_me:$LINENO: result: no" >&5
24885 echo "${ECHO_T}no" >&6; }
24886 fi
24887
24888
24889   test -n "$MSGFMT" && break
24890 done
24891
24892   if test -z "$MSGFMT"; then
24893     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
24894 echo "$as_me: error: msgfmt is required for NLS" >&2;}
24895    { (exit 1); exit 1; }; }
24896   fi
24897   for ac_prog in msgmerge
24898 do
24899   # Extract the first word of "$ac_prog", so it can be a program name with args.
24900 set dummy $ac_prog; ac_word=$2
24901 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24902 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24903 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
24904   echo $ECHO_N "(cached) $ECHO_C" >&6
24905 else
24906   if test -n "$MSGMERGE"; then
24907   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
24908 else
24909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24910 for as_dir in $PATH
24911 do
24912   IFS=$as_save_IFS
24913   test -z "$as_dir" && as_dir=.
24914   for ac_exec_ext in '' $ac_executable_extensions; do
24915   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24916     ac_cv_prog_MSGMERGE="$ac_prog"
24917     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24918     break 2
24919   fi
24920 done
24921 done
24922 IFS=$as_save_IFS
24923
24924 fi
24925 fi
24926 MSGMERGE=$ac_cv_prog_MSGMERGE
24927 if test -n "$MSGMERGE"; then
24928   { echo "$as_me:$LINENO: result: $MSGMERGE" >&5
24929 echo "${ECHO_T}$MSGMERGE" >&6; }
24930 else
24931   { echo "$as_me:$LINENO: result: no" >&5
24932 echo "${ECHO_T}no" >&6; }
24933 fi
24934
24935
24936   test -n "$MSGMERGE" && break
24937 done
24938
24939   for ac_prog in xgettext
24940 do
24941   # Extract the first word of "$ac_prog", so it can be a program name with args.
24942 set dummy $ac_prog; ac_word=$2
24943 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24944 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24945 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
24946   echo $ECHO_N "(cached) $ECHO_C" >&6
24947 else
24948   if test -n "$XGETTEXT"; then
24949   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
24950 else
24951 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24952 for as_dir in $PATH
24953 do
24954   IFS=$as_save_IFS
24955   test -z "$as_dir" && as_dir=.
24956   for ac_exec_ext in '' $ac_executable_extensions; do
24957   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24958     ac_cv_prog_XGETTEXT="$ac_prog"
24959     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24960     break 2
24961   fi
24962 done
24963 done
24964 IFS=$as_save_IFS
24965
24966 fi
24967 fi
24968 XGETTEXT=$ac_cv_prog_XGETTEXT
24969 if test -n "$XGETTEXT"; then
24970   { echo "$as_me:$LINENO: result: $XGETTEXT" >&5
24971 echo "${ECHO_T}$XGETTEXT" >&6; }
24972 else
24973   { echo "$as_me:$LINENO: result: no" >&5
24974 echo "${ECHO_T}no" >&6; }
24975 fi
24976
24977
24978   test -n "$XGETTEXT" && break
24979 done
24980
24981
24982 fi
24983
24984 # Check for Tcl configuration script tclConfig.sh
24985 if test "$with_tcl" = yes; then
24986     for ac_prog in tclsh tcl tclsh8.5 tclsh8.4 tclsh8.3
24987 do
24988   # Extract the first word of "$ac_prog", so it can be a program name with args.
24989 set dummy $ac_prog; ac_word=$2
24990 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24991 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24992 if test "${ac_cv_path_TCLSH+set}" = set; then
24993   echo $ECHO_N "(cached) $ECHO_C" >&6
24994 else
24995   case $TCLSH in
24996   [\\/]* | ?:[\\/]*)
24997   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
24998   ;;
24999   *)
25000   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25001 for as_dir in $PATH
25002 do
25003   IFS=$as_save_IFS
25004   test -z "$as_dir" && as_dir=.
25005   for ac_exec_ext in '' $ac_executable_extensions; do
25006   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25007     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
25008     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25009     break 2
25010   fi
25011 done
25012 done
25013 IFS=$as_save_IFS
25014
25015   ;;
25016 esac
25017 fi
25018 TCLSH=$ac_cv_path_TCLSH
25019 if test -n "$TCLSH"; then
25020   { echo "$as_me:$LINENO: result: $TCLSH" >&5
25021 echo "${ECHO_T}$TCLSH" >&6; }
25022 else
25023   { echo "$as_me:$LINENO: result: no" >&5
25024 echo "${ECHO_T}no" >&6; }
25025 fi
25026
25027
25028   test -n "$TCLSH" && break
25029 done
25030
25031 if test x"$TCLSH" = x""; then
25032   { { echo "$as_me:$LINENO: error: Tcl shell not found" >&5
25033 echo "$as_me: error: Tcl shell not found" >&2;}
25034    { (exit 1); exit 1; }; }
25035 fi
25036
25037 { echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
25038 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6; }
25039 # Let user override test
25040 if test -z "$TCL_CONFIG_SH"; then
25041     pgac_test_dirs="$with_tclconfig"
25042
25043     set X $pgac_test_dirs; shift
25044     if test $# -eq 0; then
25045         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
25046 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
25047    { (exit 1); exit 1; }; }
25048         set X `echo 'puts $auto_path' | $TCLSH`; shift
25049     fi
25050
25051     for pgac_dir do
25052         if test -r "$pgac_dir/tclConfig.sh"; then
25053             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
25054             break
25055         fi
25056     done
25057 fi
25058
25059 if test -z "$TCL_CONFIG_SH"; then
25060     { echo "$as_me:$LINENO: result: no" >&5
25061 echo "${ECHO_T}no" >&6; }
25062     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
25063 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
25064    { (exit 1); exit 1; }; }
25065 else
25066     { echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
25067 echo "${ECHO_T}$TCL_CONFIG_SH" >&6; }
25068 fi
25069
25070
25071
25072     . "$TCL_CONFIG_SH"
25073 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
25074 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
25075 eval TCL_LIBS=\"$TCL_LIBS\"
25076 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
25077 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
25078
25079         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
25080     ac_save_CPPFLAGS=$CPPFLAGS
25081     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
25082     if test "${ac_cv_header_tcl_h+set}" = set; then
25083   { echo "$as_me:$LINENO: checking for tcl.h" >&5
25084 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6; }
25085 if test "${ac_cv_header_tcl_h+set}" = set; then
25086   echo $ECHO_N "(cached) $ECHO_C" >&6
25087 fi
25088 { echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
25089 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6; }
25090 else
25091   # Is the header compilable?
25092 { echo "$as_me:$LINENO: checking tcl.h usability" >&5
25093 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6; }
25094 cat >conftest.$ac_ext <<_ACEOF
25095 /* confdefs.h.  */
25096 _ACEOF
25097 cat confdefs.h >>conftest.$ac_ext
25098 cat >>conftest.$ac_ext <<_ACEOF
25099 /* end confdefs.h.  */
25100 $ac_includes_default
25101 #include <tcl.h>
25102 _ACEOF
25103 rm -f conftest.$ac_objext
25104 if { (ac_try="$ac_compile"
25105 case "(($ac_try" in
25106   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25107   *) ac_try_echo=$ac_try;;
25108 esac
25109 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25110   (eval "$ac_compile") 2>conftest.er1
25111   ac_status=$?
25112   grep -v '^ *+' conftest.er1 >conftest.err
25113   rm -f conftest.er1
25114   cat conftest.err >&5
25115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25116   (exit $ac_status); } && {
25117          test -z "$ac_c_werror_flag" ||
25118          test ! -s conftest.err
25119        } && test -s conftest.$ac_objext; then
25120   ac_header_compiler=yes
25121 else
25122   echo "$as_me: failed program was:" >&5
25123 sed 's/^/| /' conftest.$ac_ext >&5
25124
25125         ac_header_compiler=no
25126 fi
25127
25128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25129 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25130 echo "${ECHO_T}$ac_header_compiler" >&6; }
25131
25132 # Is the header present?
25133 { echo "$as_me:$LINENO: checking tcl.h presence" >&5
25134 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6; }
25135 cat >conftest.$ac_ext <<_ACEOF
25136 /* confdefs.h.  */
25137 _ACEOF
25138 cat confdefs.h >>conftest.$ac_ext
25139 cat >>conftest.$ac_ext <<_ACEOF
25140 /* end confdefs.h.  */
25141 #include <tcl.h>
25142 _ACEOF
25143 if { (ac_try="$ac_cpp conftest.$ac_ext"
25144 case "(($ac_try" in
25145   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25146   *) ac_try_echo=$ac_try;;
25147 esac
25148 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25149   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
25150   ac_status=$?
25151   grep -v '^ *+' conftest.er1 >conftest.err
25152   rm -f conftest.er1
25153   cat conftest.err >&5
25154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25155   (exit $ac_status); } >/dev/null && {
25156          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
25157          test ! -s conftest.err
25158        }; then
25159   ac_header_preproc=yes
25160 else
25161   echo "$as_me: failed program was:" >&5
25162 sed 's/^/| /' conftest.$ac_ext >&5
25163
25164   ac_header_preproc=no
25165 fi
25166
25167 rm -f conftest.err conftest.$ac_ext
25168 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25169 echo "${ECHO_T}$ac_header_preproc" >&6; }
25170
25171 # So?  What about this header?
25172 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25173   yes:no: )
25174     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
25175 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
25176     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
25177 echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
25178     ac_header_preproc=yes
25179     ;;
25180   no:yes:* )
25181     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
25182 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
25183     { echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
25184 echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
25185     { echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
25186 echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
25187     { echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
25188 echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
25189     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
25190 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
25191     { echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
25192 echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
25193     ( cat <<\_ASBOX
25194 ## ---------------------------------------- ##
25195 ## Report this to pgsql-bugs@postgresql.org ##
25196 ## ---------------------------------------- ##
25197 _ASBOX
25198      ) | sed "s/^/$as_me: WARNING:     /" >&2
25199     ;;
25200 esac
25201 { echo "$as_me:$LINENO: checking for tcl.h" >&5
25202 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6; }
25203 if test "${ac_cv_header_tcl_h+set}" = set; then
25204   echo $ECHO_N "(cached) $ECHO_C" >&6
25205 else
25206   ac_cv_header_tcl_h=$ac_header_preproc
25207 fi
25208 { echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
25209 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6; }
25210
25211 fi
25212 if test $ac_cv_header_tcl_h = yes; then
25213   :
25214 else
25215   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
25216 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
25217    { (exit 1); exit 1; }; }
25218 fi
25219
25220
25221     CPPFLAGS=$ac_save_CPPFLAGS
25222 fi
25223
25224 #
25225 # Check for DocBook and tools
25226 #
25227 for ac_prog in onsgmls nsgmls
25228 do
25229   # Extract the first word of "$ac_prog", so it can be a program name with args.
25230 set dummy $ac_prog; ac_word=$2
25231 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25232 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25233 if test "${ac_cv_prog_NSGMLS+set}" = set; then
25234   echo $ECHO_N "(cached) $ECHO_C" >&6
25235 else
25236   if test -n "$NSGMLS"; then
25237   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
25238 else
25239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25240 for as_dir in $PATH
25241 do
25242   IFS=$as_save_IFS
25243   test -z "$as_dir" && as_dir=.
25244   for ac_exec_ext in '' $ac_executable_extensions; do
25245   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25246     ac_cv_prog_NSGMLS="$ac_prog"
25247     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25248     break 2
25249   fi
25250 done
25251 done
25252 IFS=$as_save_IFS
25253
25254 fi
25255 fi
25256 NSGMLS=$ac_cv_prog_NSGMLS
25257 if test -n "$NSGMLS"; then
25258   { echo "$as_me:$LINENO: result: $NSGMLS" >&5
25259 echo "${ECHO_T}$NSGMLS" >&6; }
25260 else
25261   { echo "$as_me:$LINENO: result: no" >&5
25262 echo "${ECHO_T}no" >&6; }
25263 fi
25264
25265
25266   test -n "$NSGMLS" && break
25267 done
25268
25269 for ac_prog in openjade jade
25270 do
25271   # Extract the first word of "$ac_prog", so it can be a program name with args.
25272 set dummy $ac_prog; ac_word=$2
25273 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25274 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25275 if test "${ac_cv_prog_JADE+set}" = set; then
25276   echo $ECHO_N "(cached) $ECHO_C" >&6
25277 else
25278   if test -n "$JADE"; then
25279   ac_cv_prog_JADE="$JADE" # Let the user override the test.
25280 else
25281 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25282 for as_dir in $PATH
25283 do
25284   IFS=$as_save_IFS
25285   test -z "$as_dir" && as_dir=.
25286   for ac_exec_ext in '' $ac_executable_extensions; do
25287   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25288     ac_cv_prog_JADE="$ac_prog"
25289     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25290     break 2
25291   fi
25292 done
25293 done
25294 IFS=$as_save_IFS
25295
25296 fi
25297 fi
25298 JADE=$ac_cv_prog_JADE
25299 if test -n "$JADE"; then
25300   { echo "$as_me:$LINENO: result: $JADE" >&5
25301 echo "${ECHO_T}$JADE" >&6; }
25302 else
25303   { echo "$as_me:$LINENO: result: no" >&5
25304 echo "${ECHO_T}no" >&6; }
25305 fi
25306
25307
25308   test -n "$JADE" && break
25309 done
25310
25311
25312 { echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
25313 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6; }
25314 if test "${pgac_cv_check_docbook+set}" = set; then
25315   echo $ECHO_N "(cached) $ECHO_C" >&6
25316 else
25317   cat >conftest.sgml <<EOF
25318 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
25319 <book>
25320  <title>test</title>
25321  <chapter>
25322   <title>random</title>
25323    <sect1>
25324     <title>testsect</title>
25325     <para>text</para>
25326   </sect1>
25327  </chapter>
25328 </book>
25329 EOF
25330
25331 pgac_cv_check_docbook=no
25332
25333 if test -n "$NSGMLS"; then
25334   $NSGMLS -s conftest.sgml 1>&5 2>&1
25335   if test $? -eq 0; then
25336     pgac_cv_check_docbook=yes
25337   fi
25338 fi
25339 rm -f conftest.sgml
25340 fi
25341 { echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
25342 echo "${ECHO_T}$pgac_cv_check_docbook" >&6; }
25343
25344 have_docbook=$pgac_cv_check_docbook
25345
25346
25347 { echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
25348 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6; }
25349 if test "${pgac_cv_path_stylesheets+set}" = set; then
25350   echo $ECHO_N "(cached) $ECHO_C" >&6
25351 else
25352   if test -n "$DOCBOOKSTYLE"; then
25353   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
25354 else
25355   for pgac_prefix in /usr /usr/local /opt; do
25356     for pgac_infix in share lib; do
25357       for pgac_postfix in \
25358         sgml/stylesheets/nwalsh-modular \
25359         sgml/stylesheets/docbook \
25360         sgml/stylesheets/dsssl/docbook \
25361         sgml/docbook-dsssl \
25362         sgml/docbook/dsssl/modular \
25363         sgml/docbook/stylesheet/dsssl/modular \
25364         sgml/docbook/dsssl-stylesheets
25365       do
25366         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
25367         if test -r "$pgac_candidate/html/docbook.dsl" \
25368            && test -r "$pgac_candidate/print/docbook.dsl"
25369         then
25370           pgac_cv_path_stylesheets=$pgac_candidate
25371           break 3
25372         fi
25373       done
25374     done
25375   done
25376 fi
25377 fi
25378
25379 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
25380
25381 if test -n "$DOCBOOKSTYLE"; then
25382   { echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
25383 echo "${ECHO_T}$DOCBOOKSTYLE" >&6; }
25384 else
25385   { echo "$as_me:$LINENO: result: no" >&5
25386 echo "${ECHO_T}no" >&6; }
25387 fi
25388 if test -n "$DOCBOOKSTYLE"; then
25389   for ac_prog in collateindex.pl
25390 do
25391   # Extract the first word of "$ac_prog", so it can be a program name with args.
25392 set dummy $ac_prog; ac_word=$2
25393 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25394 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25395 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
25396   echo $ECHO_N "(cached) $ECHO_C" >&6
25397 else
25398   case $COLLATEINDEX in
25399   [\\/]* | ?:[\\/]*)
25400   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
25401   ;;
25402   *)
25403   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25404 for as_dir in $DOCBOOKSTYLE/bin $PATH
25405 do
25406   IFS=$as_save_IFS
25407   test -z "$as_dir" && as_dir=.
25408   for ac_exec_ext in '' $ac_executable_extensions; do
25409   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25410     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
25411     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25412     break 2
25413   fi
25414 done
25415 done
25416 IFS=$as_save_IFS
25417
25418   ;;
25419 esac
25420 fi
25421 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
25422 if test -n "$COLLATEINDEX"; then
25423   { echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
25424 echo "${ECHO_T}$COLLATEINDEX" >&6; }
25425 else
25426   { echo "$as_me:$LINENO: result: no" >&5
25427 echo "${ECHO_T}no" >&6; }
25428 fi
25429
25430
25431   test -n "$COLLATEINDEX" && break
25432 done
25433
25434 else
25435   for ac_prog in collateindex.pl
25436 do
25437   # Extract the first word of "$ac_prog", so it can be a program name with args.
25438 set dummy $ac_prog; ac_word=$2
25439 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25440 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25441 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
25442   echo $ECHO_N "(cached) $ECHO_C" >&6
25443 else
25444   case $COLLATEINDEX in
25445   [\\/]* | ?:[\\/]*)
25446   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
25447   ;;
25448   *)
25449   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25450 for as_dir in $PATH
25451 do
25452   IFS=$as_save_IFS
25453   test -z "$as_dir" && as_dir=.
25454   for ac_exec_ext in '' $ac_executable_extensions; do
25455   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25456     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
25457     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25458     break 2
25459   fi
25460 done
25461 done
25462 IFS=$as_save_IFS
25463
25464   ;;
25465 esac
25466 fi
25467 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
25468 if test -n "$COLLATEINDEX"; then
25469   { echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
25470 echo "${ECHO_T}$COLLATEINDEX" >&6; }
25471 else
25472   { echo "$as_me:$LINENO: result: no" >&5
25473 echo "${ECHO_T}no" >&6; }
25474 fi
25475
25476
25477   test -n "$COLLATEINDEX" && break
25478 done
25479
25480 fi
25481 for ac_prog in sgmlspl
25482 do
25483   # Extract the first word of "$ac_prog", so it can be a program name with args.
25484 set dummy $ac_prog; ac_word=$2
25485 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25486 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25487 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
25488   echo $ECHO_N "(cached) $ECHO_C" >&6
25489 else
25490   if test -n "$SGMLSPL"; then
25491   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
25492 else
25493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25494 for as_dir in $PATH
25495 do
25496   IFS=$as_save_IFS
25497   test -z "$as_dir" && as_dir=.
25498   for ac_exec_ext in '' $ac_executable_extensions; do
25499   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25500     ac_cv_prog_SGMLSPL="$ac_prog"
25501     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25502     break 2
25503   fi
25504 done
25505 done
25506 IFS=$as_save_IFS
25507
25508 fi
25509 fi
25510 SGMLSPL=$ac_cv_prog_SGMLSPL
25511 if test -n "$SGMLSPL"; then
25512   { echo "$as_me:$LINENO: result: $SGMLSPL" >&5
25513 echo "${ECHO_T}$SGMLSPL" >&6; }
25514 else
25515   { echo "$as_me:$LINENO: result: no" >&5
25516 echo "${ECHO_T}no" >&6; }
25517 fi
25518
25519
25520   test -n "$SGMLSPL" && break
25521 done
25522
25523
25524 # Thread testing
25525
25526 # We have to run the thread test near the end so we have all our symbols
25527 # defined.  Cross compiling throws a warning.
25528 #
25529 if test "$enable_thread_safety_force" = yes; then
25530 if test "$PORTNAME" != "win32"
25531 then
25532   { echo "$as_me:$LINENO: WARNING:
25533 *** Skipping thread test program.  --enable-thread-safety-force was used.
25534 *** Run the program in src/test/thread on the your machine and add proper
25535 *** locking function calls to your applications to guarantee thread safety.
25536 " >&5
25537 echo "$as_me: WARNING:
25538 *** Skipping thread test program.  --enable-thread-safety-force was used.
25539 *** Run the program in src/test/thread on the your machine and add proper
25540 *** locking function calls to your applications to guarantee thread safety.
25541 " >&2;}
25542 else
25543 { echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
25544 echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
25545 fi
25546 elif test "$enable_thread_safety" = yes; then
25547 if test "$PORTNAME" != "win32"
25548 then
25549 { echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
25550 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6; }
25551
25552 _CFLAGS="$CFLAGS"
25553 _LIBS="$LIBS"
25554 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
25555 LIBS="$LIBS $PTHREAD_LIBS"
25556 if test "$cross_compiling" = yes; then
25557   { echo "$as_me:$LINENO: result: maybe" >&5
25558 echo "${ECHO_T}maybe" >&6; }
25559   { echo "$as_me:$LINENO: WARNING:
25560 *** Skipping thread test program because of cross-compile build.
25561 *** Run the program in src/test/thread on the target machine.
25562 " >&5
25563 echo "$as_me: WARNING:
25564 *** Skipping thread test program because of cross-compile build.
25565 *** Run the program in src/test/thread on the target machine.
25566 " >&2;}
25567 else
25568   cat >conftest.$ac_ext <<_ACEOF
25569 /* confdefs.h.  */
25570 _ACEOF
25571 cat confdefs.h >>conftest.$ac_ext
25572 cat >>conftest.$ac_ext <<_ACEOF
25573 /* end confdefs.h.  */
25574 #include "$srcdir/src/test/thread/thread_test.c"
25575 _ACEOF
25576 rm -f conftest$ac_exeext
25577 if { (ac_try="$ac_link"
25578 case "(($ac_try" in
25579   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25580   *) ac_try_echo=$ac_try;;
25581 esac
25582 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25583   (eval "$ac_link") 2>&5
25584   ac_status=$?
25585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25586   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25587   { (case "(($ac_try" in
25588   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25589   *) ac_try_echo=$ac_try;;
25590 esac
25591 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25592   (eval "$ac_try") 2>&5
25593   ac_status=$?
25594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25595   (exit $ac_status); }; }; then
25596   { echo "$as_me:$LINENO: result: yes" >&5
25597 echo "${ECHO_T}yes" >&6; }
25598 else
25599   echo "$as_me: program exited with status $ac_status" >&5
25600 echo "$as_me: failed program was:" >&5
25601 sed 's/^/| /' conftest.$ac_ext >&5
25602
25603 ( exit $ac_status )
25604 { echo "$as_me:$LINENO: result: no" >&5
25605 echo "${ECHO_T}no" >&6; }
25606   { { echo "$as_me:$LINENO: error: thread test program failed
25607 This platform is not thread-safe.  Check the file 'config.log'for the
25608 exact reason.
25609
25610 You can use the configure option --enable-thread-safety-force to force
25611 threads to be enabled.  But you must then run the program in
25612 src/test/thread and add locking function calls to your applications to
25613 guarantee thread safety." >&5
25614 echo "$as_me: error: thread test program failed
25615 This platform is not thread-safe.  Check the file 'config.log'for the
25616 exact reason.
25617
25618 You can use the configure option --enable-thread-safety-force to force
25619 threads to be enabled.  But you must then run the program in
25620 src/test/thread and add locking function calls to your applications to
25621 guarantee thread safety." >&2;}
25622    { (exit 1); exit 1; }; }
25623 fi
25624 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25625 fi
25626
25627
25628 CFLAGS="$_CFLAGS"
25629 LIBS="$_LIBS"
25630 else
25631 { echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
25632 echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
25633 fi
25634 fi
25635
25636 # If compiler will take -Wl,--as-needed then add that to LDFLAGS.
25637 # This is much easier than trying to filter LIBS to the minimum for each
25638 # executable.  (Note that shared library links won't use this switch, though.)
25639 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
25640 # libreadline; therefore we postpone testing it until we know what library
25641 # dependencies readline has.  The test code will try to link with $LIBS.
25642 if test "$with_readline" = yes; then
25643   link_test_func=readline
25644 else
25645   link_test_func=exit
25646 fi
25647 if test "$PORTNAME" != "darwin"; then
25648   { echo "$as_me:$LINENO: checking if $CC supports -Wl,--as-needed" >&5
25649 echo $ECHO_N "checking if $CC supports -Wl,--as-needed... $ECHO_C" >&6; }
25650 pgac_save_LDFLAGS=$LDFLAGS
25651 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
25652 if test "$cross_compiling" = yes; then
25653   LDFLAGS="$pgac_save_LDFLAGS"
25654                { echo "$as_me:$LINENO: result: assuming no" >&5
25655 echo "${ECHO_T}assuming no" >&6; }
25656 else
25657   cat >conftest.$ac_ext <<_ACEOF
25658 /* confdefs.h.  */
25659 _ACEOF
25660 cat confdefs.h >>conftest.$ac_ext
25661 cat >>conftest.$ac_ext <<_ACEOF
25662 /* end confdefs.h.  */
25663 extern void $link_test_func (); void (*fptr) () = $link_test_func;
25664 int
25665 main ()
25666 {
25667
25668   ;
25669   return 0;
25670 }
25671 _ACEOF
25672 rm -f conftest$ac_exeext
25673 if { (ac_try="$ac_link"
25674 case "(($ac_try" in
25675   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25676   *) ac_try_echo=$ac_try;;
25677 esac
25678 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25679   (eval "$ac_link") 2>&5
25680   ac_status=$?
25681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25682   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25683   { (case "(($ac_try" in
25684   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25685   *) ac_try_echo=$ac_try;;
25686 esac
25687 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25688   (eval "$ac_try") 2>&5
25689   ac_status=$?
25690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25691   (exit $ac_status); }; }; then
25692   { echo "$as_me:$LINENO: result: yes" >&5
25693 echo "${ECHO_T}yes" >&6; }
25694 else
25695   echo "$as_me: program exited with status $ac_status" >&5
25696 echo "$as_me: failed program was:" >&5
25697 sed 's/^/| /' conftest.$ac_ext >&5
25698
25699 ( exit $ac_status )
25700 LDFLAGS="$pgac_save_LDFLAGS"
25701                { echo "$as_me:$LINENO: result: no" >&5
25702 echo "${ECHO_T}no" >&6; }
25703 fi
25704 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25705 fi
25706
25707
25708
25709 else
25710   # On Darwin it's spelled -Wl,-dead_strip_dylibs, but don't try that elsewhere
25711   { echo "$as_me:$LINENO: checking if $CC supports -Wl,-dead_strip_dylibs" >&5
25712 echo $ECHO_N "checking if $CC supports -Wl,-dead_strip_dylibs... $ECHO_C" >&6; }
25713 pgac_save_LDFLAGS=$LDFLAGS
25714 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
25715 if test "$cross_compiling" = yes; then
25716   LDFLAGS="$pgac_save_LDFLAGS"
25717                { echo "$as_me:$LINENO: result: assuming no" >&5
25718 echo "${ECHO_T}assuming no" >&6; }
25719 else
25720   cat >conftest.$ac_ext <<_ACEOF
25721 /* confdefs.h.  */
25722 _ACEOF
25723 cat confdefs.h >>conftest.$ac_ext
25724 cat >>conftest.$ac_ext <<_ACEOF
25725 /* end confdefs.h.  */
25726 extern void $link_test_func (); void (*fptr) () = $link_test_func;
25727 int
25728 main ()
25729 {
25730
25731   ;
25732   return 0;
25733 }
25734 _ACEOF
25735 rm -f conftest$ac_exeext
25736 if { (ac_try="$ac_link"
25737 case "(($ac_try" in
25738   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25739   *) ac_try_echo=$ac_try;;
25740 esac
25741 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25742   (eval "$ac_link") 2>&5
25743   ac_status=$?
25744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25745   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25746   { (case "(($ac_try" in
25747   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25748   *) ac_try_echo=$ac_try;;
25749 esac
25750 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25751   (eval "$ac_try") 2>&5
25752   ac_status=$?
25753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25754   (exit $ac_status); }; }; then
25755   { echo "$as_me:$LINENO: result: yes" >&5
25756 echo "${ECHO_T}yes" >&6; }
25757 else
25758   echo "$as_me: program exited with status $ac_status" >&5
25759 echo "$as_me: failed program was:" >&5
25760 sed 's/^/| /' conftest.$ac_ext >&5
25761
25762 ( exit $ac_status )
25763 LDFLAGS="$pgac_save_LDFLAGS"
25764                { echo "$as_me:$LINENO: result: no" >&5
25765 echo "${ECHO_T}no" >&6; }
25766 fi
25767 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25768 fi
25769
25770
25771
25772 fi
25773
25774
25775 # Begin output steps
25776
25777 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
25778 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
25779 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
25780 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
25781 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
25782 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
25783
25784 # prepare build tree if outside source tree
25785 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
25786 # Note 2: /bin/pwd might be better than shell's built-in at getting
25787 #         a symlink-free name.
25788 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
25789   vpath_build=no
25790 else
25791   vpath_build=yes
25792   if test "$no_create" != yes; then
25793     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
25794     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
25795     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
25796       || { { echo "$as_me:$LINENO: error: failed" >&5
25797 echo "$as_me: error: failed" >&2;}
25798    { (exit 1); exit 1; }; }
25799     { echo "$as_me:$LINENO: result: done" >&5
25800 echo "${ECHO_T}done" >&6; }
25801   fi
25802 fi
25803
25804
25805
25806 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
25807
25808
25809 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/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}"
25810
25811
25812 if test "$PORTNAME" = "win32"; then
25813 ac_config_commands="$ac_config_commands check_win32_symlinks"
25814
25815 fi
25816
25817 ac_config_headers="$ac_config_headers src/include/pg_config.h"
25818
25819
25820 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
25821
25822
25823 cat >confcache <<\_ACEOF
25824 # This file is a shell script that caches the results of configure
25825 # tests run on this system so they can be shared between configure
25826 # scripts and configure runs, see configure's option --config-cache.
25827 # It is not useful on other systems.  If it contains results you don't
25828 # want to keep, you may remove or edit it.
25829 #
25830 # config.status only pays attention to the cache file if you give it
25831 # the --recheck option to rerun configure.
25832 #
25833 # `ac_cv_env_foo' variables (set or unset) will be overridden when
25834 # loading this file, other *unset* `ac_cv_foo' will be assigned the
25835 # following values.
25836
25837 _ACEOF
25838
25839 # The following way of writing the cache mishandles newlines in values,
25840 # but we know of no workaround that is simple, portable, and efficient.
25841 # So, we kill variables containing newlines.
25842 # Ultrix sh set writes to stderr and can't be redirected directly,
25843 # and sets the high bit in the cache file unless we assign to the vars.
25844 (
25845   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
25846     eval ac_val=\$$ac_var
25847     case $ac_val in #(
25848     *${as_nl}*)
25849       case $ac_var in #(
25850       *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
25851 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
25852       esac
25853       case $ac_var in #(
25854       _ | IFS | as_nl) ;; #(
25855       *) $as_unset $ac_var ;;
25856       esac ;;
25857     esac
25858   done
25859
25860   (set) 2>&1 |
25861     case $as_nl`(ac_space=' '; set) 2>&1` in #(
25862     *${as_nl}ac_space=\ *)
25863       # `set' does not quote correctly, so add quotes (double-quote
25864       # substitution turns \\\\ into \\, and sed turns \\ into \).
25865       sed -n \
25866         "s/'/'\\\\''/g;
25867           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
25868       ;; #(
25869     *)
25870       # `set' quotes correctly as required by POSIX, so do not add quotes.
25871       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
25872       ;;
25873     esac |
25874     sort
25875 ) |
25876   sed '
25877      /^ac_cv_env_/b end
25878      t clear
25879      :clear
25880      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
25881      t end
25882      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
25883      :end' >>confcache
25884 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
25885   if test -w "$cache_file"; then
25886     test "x$cache_file" != "x/dev/null" &&
25887       { echo "$as_me:$LINENO: updating cache $cache_file" >&5
25888 echo "$as_me: updating cache $cache_file" >&6;}
25889     cat confcache >$cache_file
25890   else
25891     { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
25892 echo "$as_me: not updating unwritable cache $cache_file" >&6;}
25893   fi
25894 fi
25895 rm -f confcache
25896
25897 test "x$prefix" = xNONE && prefix=$ac_default_prefix
25898 # Let make expand exec_prefix.
25899 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
25900
25901 DEFS=-DHAVE_CONFIG_H
25902
25903 ac_libobjs=
25904 ac_ltlibobjs=
25905 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
25906   # 1. Remove the extension, and $U if already installed.
25907   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
25908   ac_i=`echo "$ac_i" | sed "$ac_script"`
25909   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
25910   #    will be set to the directory where LIBOBJS objects are built.
25911   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
25912   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
25913 done
25914 LIBOBJS=$ac_libobjs
25915
25916 LTLIBOBJS=$ac_ltlibobjs
25917
25918
25919
25920 : ${CONFIG_STATUS=./config.status}
25921 ac_clean_files_save=$ac_clean_files
25922 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
25923 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
25924 echo "$as_me: creating $CONFIG_STATUS" >&6;}
25925 cat >$CONFIG_STATUS <<_ACEOF
25926 #! $SHELL
25927 # Generated by $as_me.
25928 # Run this file to recreate the current configuration.
25929 # Compiler output produced by configure, useful for debugging
25930 # configure, is in config.log if it exists.
25931
25932 debug=false
25933 ac_cs_recheck=false
25934 ac_cs_silent=false
25935 SHELL=\${CONFIG_SHELL-$SHELL}
25936 _ACEOF
25937
25938 cat >>$CONFIG_STATUS <<\_ACEOF
25939 ## --------------------- ##
25940 ## M4sh Initialization.  ##
25941 ## --------------------- ##
25942
25943 # Be more Bourne compatible
25944 DUALCASE=1; export DUALCASE # for MKS sh
25945 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
25946   emulate sh
25947   NULLCMD=:
25948   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
25949   # is contrary to our usage.  Disable this feature.
25950   alias -g '${1+"$@"}'='"$@"'
25951   setopt NO_GLOB_SUBST
25952 else
25953   case `(set -o) 2>/dev/null` in
25954   *posix*) set -o posix ;;
25955 esac
25956
25957 fi
25958
25959
25960
25961
25962 # PATH needs CR
25963 # Avoid depending upon Character Ranges.
25964 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
25965 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
25966 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
25967 as_cr_digits='0123456789'
25968 as_cr_alnum=$as_cr_Letters$as_cr_digits
25969
25970 # The user is always right.
25971 if test "${PATH_SEPARATOR+set}" != set; then
25972   echo "#! /bin/sh" >conf$$.sh
25973   echo  "exit 0"   >>conf$$.sh
25974   chmod +x conf$$.sh
25975   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
25976     PATH_SEPARATOR=';'
25977   else
25978     PATH_SEPARATOR=:
25979   fi
25980   rm -f conf$$.sh
25981 fi
25982
25983 # Support unset when possible.
25984 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
25985   as_unset=unset
25986 else
25987   as_unset=false
25988 fi
25989
25990
25991 # IFS
25992 # We need space, tab and new line, in precisely that order.  Quoting is
25993 # there to prevent editors from complaining about space-tab.
25994 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
25995 # splitting by setting IFS to empty value.)
25996 as_nl='
25997 '
25998 IFS=" ""        $as_nl"
25999
26000 # Find who we are.  Look in the path if we contain no directory separator.
26001 case $0 in
26002   *[\\/]* ) as_myself=$0 ;;
26003   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26004 for as_dir in $PATH
26005 do
26006   IFS=$as_save_IFS
26007   test -z "$as_dir" && as_dir=.
26008   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26009 done
26010 IFS=$as_save_IFS
26011
26012      ;;
26013 esac
26014 # We did not find ourselves, most probably we were run as `sh COMMAND'
26015 # in which case we are not to be found in the path.
26016 if test "x$as_myself" = x; then
26017   as_myself=$0
26018 fi
26019 if test ! -f "$as_myself"; then
26020   echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
26021   { (exit 1); exit 1; }
26022 fi
26023
26024 # Work around bugs in pre-3.0 UWIN ksh.
26025 for as_var in ENV MAIL MAILPATH
26026 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
26027 done
26028 PS1='$ '
26029 PS2='> '
26030 PS4='+ '
26031
26032 # NLS nuisances.
26033 for as_var in \
26034   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
26035   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
26036   LC_TELEPHONE LC_TIME
26037 do
26038   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
26039     eval $as_var=C; export $as_var
26040   else
26041     ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
26042   fi
26043 done
26044
26045 # Required to use basename.
26046 if expr a : '\(a\)' >/dev/null 2>&1 &&
26047    test "X`expr 00001 : '.*\(...\)'`" = X001; then
26048   as_expr=expr
26049 else
26050   as_expr=false
26051 fi
26052
26053 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26054   as_basename=basename
26055 else
26056   as_basename=false
26057 fi
26058
26059
26060 # Name of the executable.
26061 as_me=`$as_basename -- "$0" ||
26062 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26063          X"$0" : 'X\(//\)$' \| \
26064          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
26065 echo X/"$0" |
26066     sed '/^.*\/\([^/][^/]*\)\/*$/{
26067             s//\1/
26068             q
26069           }
26070           /^X\/\(\/\/\)$/{
26071             s//\1/
26072             q
26073           }
26074           /^X\/\(\/\).*/{
26075             s//\1/
26076             q
26077           }
26078           s/.*/./; q'`
26079
26080 # CDPATH.
26081 $as_unset CDPATH
26082
26083
26084
26085   as_lineno_1=$LINENO
26086   as_lineno_2=$LINENO
26087   test "x$as_lineno_1" != "x$as_lineno_2" &&
26088   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
26089
26090   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
26091   # uniformly replaced by the line number.  The first 'sed' inserts a
26092   # line-number line after each line using $LINENO; the second 'sed'
26093   # does the real work.  The second script uses 'N' to pair each
26094   # line-number line with the line containing $LINENO, and appends
26095   # trailing '-' during substitution so that $LINENO is not a special
26096   # case at line end.
26097   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
26098   # scripts with optimization help from Paolo Bonzini.  Blame Lee
26099   # E. McMahon (1931-1989) for sed's syntax.  :-)
26100   sed -n '
26101     p
26102     /[$]LINENO/=
26103   ' <$as_myself |
26104     sed '
26105       s/[$]LINENO.*/&-/
26106       t lineno
26107       b
26108       :lineno
26109       N
26110       :loop
26111       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
26112       t loop
26113       s/-\n.*//
26114     ' >$as_me.lineno &&
26115   chmod +x "$as_me.lineno" ||
26116     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
26117    { (exit 1); exit 1; }; }
26118
26119   # Don't try to exec as it changes $[0], causing all sort of problems
26120   # (the dirname of $[0] is not the place where we might find the
26121   # original and so on.  Autoconf is especially sensitive to this).
26122   . "./$as_me.lineno"
26123   # Exit status is that of the last command.
26124   exit
26125 }
26126
26127
26128 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26129   as_dirname=dirname
26130 else
26131   as_dirname=false
26132 fi
26133
26134 ECHO_C= ECHO_N= ECHO_T=
26135 case `echo -n x` in
26136 -n*)
26137   case `echo 'x\c'` in
26138   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
26139   *)   ECHO_C='\c';;
26140   esac;;
26141 *)
26142   ECHO_N='-n';;
26143 esac
26144
26145 if expr a : '\(a\)' >/dev/null 2>&1 &&
26146    test "X`expr 00001 : '.*\(...\)'`" = X001; then
26147   as_expr=expr
26148 else
26149   as_expr=false
26150 fi
26151
26152 rm -f conf$$ conf$$.exe conf$$.file
26153 if test -d conf$$.dir; then
26154   rm -f conf$$.dir/conf$$.file
26155 else
26156   rm -f conf$$.dir
26157   mkdir conf$$.dir
26158 fi
26159 echo >conf$$.file
26160 if ln -s conf$$.file conf$$ 2>/dev/null; then
26161   as_ln_s='ln -s'
26162   # ... but there are two gotchas:
26163   # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26164   # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26165   # In both cases, we have to default to `cp -p'.
26166   ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26167     as_ln_s='cp -p'
26168 elif ln conf$$.file conf$$ 2>/dev/null; then
26169   as_ln_s=ln
26170 else
26171   as_ln_s='cp -p'
26172 fi
26173 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26174 rmdir conf$$.dir 2>/dev/null
26175
26176 if mkdir -p . 2>/dev/null; then
26177   as_mkdir_p=:
26178 else
26179   test -d ./-p && rmdir ./-p
26180   as_mkdir_p=false
26181 fi
26182
26183 if test -x / >/dev/null 2>&1; then
26184   as_test_x='test -x'
26185 else
26186   if ls -dL / >/dev/null 2>&1; then
26187     as_ls_L_option=L
26188   else
26189     as_ls_L_option=
26190   fi
26191   as_test_x='
26192     eval sh -c '\''
26193       if test -d "$1"; then
26194         test -d "$1/.";
26195       else
26196         case $1 in
26197         -*)set "./$1";;
26198         esac;
26199         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
26200         ???[sx]*):;;*)false;;esac;fi
26201     '\'' sh
26202   '
26203 fi
26204 as_executable_p=$as_test_x
26205
26206 # Sed expression to map a string onto a valid CPP name.
26207 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
26208
26209 # Sed expression to map a string onto a valid variable name.
26210 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
26211
26212
26213 exec 6>&1
26214
26215 # Save the log message, to keep $[0] and so on meaningful, and to
26216 # report actual input values of CONFIG_FILES etc. instead of their
26217 # values after options handling.
26218 ac_log="
26219 This file was extended by PostgreSQL $as_me 8.4devel, which was
26220 generated by GNU Autoconf 2.61.  Invocation command line was
26221
26222   CONFIG_FILES    = $CONFIG_FILES
26223   CONFIG_HEADERS  = $CONFIG_HEADERS
26224   CONFIG_LINKS    = $CONFIG_LINKS
26225   CONFIG_COMMANDS = $CONFIG_COMMANDS
26226   $ $0 $@
26227
26228 on `(hostname || uname -n) 2>/dev/null | sed 1q`
26229 "
26230
26231 _ACEOF
26232
26233 cat >>$CONFIG_STATUS <<_ACEOF
26234 # Files that config.status was made for.
26235 config_files="$ac_config_files"
26236 config_headers="$ac_config_headers"
26237 config_links="$ac_config_links"
26238 config_commands="$ac_config_commands"
26239
26240 _ACEOF
26241
26242 cat >>$CONFIG_STATUS <<\_ACEOF
26243 ac_cs_usage="\
26244 \`$as_me' instantiates files from templates according to the
26245 current configuration.
26246
26247 Usage: $0 [OPTIONS] [FILE]...
26248
26249   -h, --help       print this help, then exit
26250   -V, --version    print version number and configuration settings, then exit
26251   -q, --quiet      do not print progress messages
26252   -d, --debug      don't remove temporary files
26253       --recheck    update $as_me by reconfiguring in the same conditions
26254   --file=FILE[:TEMPLATE]
26255                    instantiate the configuration file FILE
26256   --header=FILE[:TEMPLATE]
26257                    instantiate the configuration header FILE
26258
26259 Configuration files:
26260 $config_files
26261
26262 Configuration headers:
26263 $config_headers
26264
26265 Configuration links:
26266 $config_links
26267
26268 Configuration commands:
26269 $config_commands
26270
26271 Report bugs to <bug-autoconf@gnu.org>."
26272
26273 _ACEOF
26274 cat >>$CONFIG_STATUS <<_ACEOF
26275 ac_cs_version="\\
26276 PostgreSQL config.status 8.4devel
26277 configured by $0, generated by GNU Autoconf 2.61,
26278   with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
26279
26280 Copyright (C) 2006 Free Software Foundation, Inc.
26281 This config.status script is free software; the Free Software Foundation
26282 gives unlimited permission to copy, distribute and modify it."
26283
26284 ac_pwd='$ac_pwd'
26285 srcdir='$srcdir'
26286 _ACEOF
26287
26288 cat >>$CONFIG_STATUS <<\_ACEOF
26289 # If no file are specified by the user, then we need to provide default
26290 # value.  By we need to know if files were specified by the user.
26291 ac_need_defaults=:
26292 while test $# != 0
26293 do
26294   case $1 in
26295   --*=*)
26296     ac_option=`expr "X$1" : 'X\([^=]*\)='`
26297     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
26298     ac_shift=:
26299     ;;
26300   *)
26301     ac_option=$1
26302     ac_optarg=$2
26303     ac_shift=shift
26304     ;;
26305   esac
26306
26307   case $ac_option in
26308   # Handling of the options.
26309   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
26310     ac_cs_recheck=: ;;
26311   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
26312     echo "$ac_cs_version"; exit ;;
26313   --debug | --debu | --deb | --de | --d | -d )
26314     debug=: ;;
26315   --file | --fil | --fi | --f )
26316     $ac_shift
26317     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
26318     ac_need_defaults=false;;
26319   --header | --heade | --head | --hea )
26320     $ac_shift
26321     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
26322     ac_need_defaults=false;;
26323   --he | --h)
26324     # Conflict between --help and --header
26325     { echo "$as_me: error: ambiguous option: $1
26326 Try \`$0 --help' for more information." >&2
26327    { (exit 1); exit 1; }; };;
26328   --help | --hel | -h )
26329     echo "$ac_cs_usage"; exit ;;
26330   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
26331   | -silent | --silent | --silen | --sile | --sil | --si | --s)
26332     ac_cs_silent=: ;;
26333
26334   # This is an error.
26335   -*) { echo "$as_me: error: unrecognized option: $1
26336 Try \`$0 --help' for more information." >&2
26337    { (exit 1); exit 1; }; } ;;
26338
26339   *) ac_config_targets="$ac_config_targets $1"
26340      ac_need_defaults=false ;;
26341
26342   esac
26343   shift
26344 done
26345
26346 ac_configure_extra_args=
26347
26348 if $ac_cs_silent; then
26349   exec 6>/dev/null
26350   ac_configure_extra_args="$ac_configure_extra_args --silent"
26351 fi
26352
26353 _ACEOF
26354 cat >>$CONFIG_STATUS <<_ACEOF
26355 if \$ac_cs_recheck; then
26356   echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
26357   CONFIG_SHELL=$SHELL
26358   export CONFIG_SHELL
26359   exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
26360 fi
26361
26362 _ACEOF
26363 cat >>$CONFIG_STATUS <<\_ACEOF
26364 exec 5>>config.log
26365 {
26366   echo
26367   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
26368 ## Running $as_me. ##
26369 _ASBOX
26370   echo "$ac_log"
26371 } >&5
26372
26373 _ACEOF
26374 cat >>$CONFIG_STATUS <<_ACEOF
26375 _ACEOF
26376
26377 cat >>$CONFIG_STATUS <<\_ACEOF
26378
26379 # Handling of arguments.
26380 for ac_config_target in $ac_config_targets
26381 do
26382   case $ac_config_target in
26383     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
26384     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
26385     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
26386     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
26387     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
26388     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
26389     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
26390     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
26391     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
26392     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
26393     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
26394     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
26395
26396   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
26397 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
26398    { (exit 1); exit 1; }; };;
26399   esac
26400 done
26401
26402
26403 # If the user did not use the arguments to specify the items to instantiate,
26404 # then the envvar interface is used.  Set only those that are not.
26405 # We use the long form for the default assignment because of an extremely
26406 # bizarre bug on SunOS 4.1.3.
26407 if $ac_need_defaults; then
26408   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
26409   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
26410   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
26411   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
26412 fi
26413
26414 # Have a temporary directory for convenience.  Make it in the build tree
26415 # simply because there is no reason against having it here, and in addition,
26416 # creating and moving files from /tmp can sometimes cause problems.
26417 # Hook for its removal unless debugging.
26418 # Note that there is a small window in which the directory will not be cleaned:
26419 # after its creation but before its name has been assigned to `$tmp'.
26420 $debug ||
26421 {
26422   tmp=
26423   trap 'exit_status=$?
26424   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
26425 ' 0
26426   trap '{ (exit 1); exit 1; }' 1 2 13 15
26427 }
26428 # Create a (secure) tmp directory for tmp files.
26429
26430 {
26431   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
26432   test -n "$tmp" && test -d "$tmp"
26433 }  ||
26434 {
26435   tmp=./conf$$-$RANDOM
26436   (umask 077 && mkdir "$tmp")
26437 } ||
26438 {
26439    echo "$me: cannot create a temporary directory in ." >&2
26440    { (exit 1); exit 1; }
26441 }
26442
26443 #
26444 # Set up the sed scripts for CONFIG_FILES section.
26445 #
26446
26447 # No need to generate the scripts if there are no CONFIG_FILES.
26448 # This happens for instance when ./config.status config.h
26449 if test -n "$CONFIG_FILES"; then
26450
26451 _ACEOF
26452
26453
26454
26455 ac_delim='%!_!# '
26456 for ac_last_try in false false false false false :; do
26457   cat >conf$$subs.sed <<_ACEOF
26458 SHELL!$SHELL$ac_delim
26459 PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
26460 PACKAGE_NAME!$PACKAGE_NAME$ac_delim
26461 PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
26462 PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
26463 PACKAGE_STRING!$PACKAGE_STRING$ac_delim
26464 PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
26465 exec_prefix!$exec_prefix$ac_delim
26466 prefix!$prefix$ac_delim
26467 program_transform_name!$program_transform_name$ac_delim
26468 bindir!$bindir$ac_delim
26469 sbindir!$sbindir$ac_delim
26470 libexecdir!$libexecdir$ac_delim
26471 datarootdir!$datarootdir$ac_delim
26472 datadir!$datadir$ac_delim
26473 sysconfdir!$sysconfdir$ac_delim
26474 sharedstatedir!$sharedstatedir$ac_delim
26475 localstatedir!$localstatedir$ac_delim
26476 includedir!$includedir$ac_delim
26477 oldincludedir!$oldincludedir$ac_delim
26478 docdir!$docdir$ac_delim
26479 infodir!$infodir$ac_delim
26480 htmldir!$htmldir$ac_delim
26481 dvidir!$dvidir$ac_delim
26482 pdfdir!$pdfdir$ac_delim
26483 psdir!$psdir$ac_delim
26484 libdir!$libdir$ac_delim
26485 localedir!$localedir$ac_delim
26486 mandir!$mandir$ac_delim
26487 DEFS!$DEFS$ac_delim
26488 ECHO_C!$ECHO_C$ac_delim
26489 ECHO_N!$ECHO_N$ac_delim
26490 ECHO_T!$ECHO_T$ac_delim
26491 LIBS!$LIBS$ac_delim
26492 build_alias!$build_alias$ac_delim
26493 host_alias!$host_alias$ac_delim
26494 target_alias!$target_alias$ac_delim
26495 configure_args!$configure_args$ac_delim
26496 build!$build$ac_delim
26497 build_cpu!$build_cpu$ac_delim
26498 build_vendor!$build_vendor$ac_delim
26499 build_os!$build_os$ac_delim
26500 host!$host$ac_delim
26501 host_cpu!$host_cpu$ac_delim
26502 host_vendor!$host_vendor$ac_delim
26503 host_os!$host_os$ac_delim
26504 PORTNAME!$PORTNAME$ac_delim
26505 enable_nls!$enable_nls$ac_delim
26506 WANTED_LANGUAGES!$WANTED_LANGUAGES$ac_delim
26507 default_port!$default_port$ac_delim
26508 enable_shared!$enable_shared$ac_delim
26509 enable_rpath!$enable_rpath$ac_delim
26510 enable_debug!$enable_debug$ac_delim
26511 enable_profiling!$enable_profiling$ac_delim
26512 DTRACE!$DTRACE$ac_delim
26513 DTRACEFLAGS!$DTRACEFLAGS$ac_delim
26514 enable_dtrace!$enable_dtrace$ac_delim
26515 CC!$CC$ac_delim
26516 CFLAGS!$CFLAGS$ac_delim
26517 LDFLAGS!$LDFLAGS$ac_delim
26518 CPPFLAGS!$CPPFLAGS$ac_delim
26519 ac_ct_CC!$ac_ct_CC$ac_delim
26520 EXEEXT!$EXEEXT$ac_delim
26521 OBJEXT!$OBJEXT$ac_delim
26522 CPP!$CPP$ac_delim
26523 GCC!$GCC$ac_delim
26524 TAS!$TAS$ac_delim
26525 autodepend!$autodepend$ac_delim
26526 INCLUDES!$INCLUDES$ac_delim
26527 enable_thread_safety!$enable_thread_safety$ac_delim
26528 with_tcl!$with_tcl$ac_delim
26529 with_perl!$with_perl$ac_delim
26530 with_python!$with_python$ac_delim
26531 with_gssapi!$with_gssapi$ac_delim
26532 with_krb5!$with_krb5$ac_delim
26533 krb_srvtab!$krb_srvtab$ac_delim
26534 with_pam!$with_pam$ac_delim
26535 with_ldap!$with_ldap$ac_delim
26536 with_bonjour!$with_bonjour$ac_delim
26537 with_openssl!$with_openssl$ac_delim
26538 with_ossp_uuid!$with_ossp_uuid$ac_delim
26539 XML2_CONFIG!$XML2_CONFIG$ac_delim
26540 with_libxml!$with_libxml$ac_delim
26541 with_libxslt!$with_libxslt$ac_delim
26542 with_system_tzdata!$with_system_tzdata$ac_delim
26543 with_zlib!$with_zlib$ac_delim
26544 GREP!$GREP$ac_delim
26545 EGREP!$EGREP$ac_delim
26546 ELF_SYS!$ELF_SYS$ac_delim
26547 LDFLAGS_SL!$LDFLAGS_SL$ac_delim
26548 LD!$LD$ac_delim
26549 with_gnu_ld!$with_gnu_ld$ac_delim
26550 ld_R_works!$ld_R_works$ac_delim
26551 RANLIB!$RANLIB$ac_delim
26552 STRIP!$STRIP$ac_delim
26553 STRIP_STATIC_LIB!$STRIP_STATIC_LIB$ac_delim
26554 STRIP_SHARED_LIB!$STRIP_SHARED_LIB$ac_delim
26555 _ACEOF
26556
26557   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
26558     break
26559   elif $ac_last_try; then
26560     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26561 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
26562    { (exit 1); exit 1; }; }
26563   else
26564     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26565   fi
26566 done
26567
26568 ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
26569 if test -n "$ac_eof"; then
26570   ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
26571   ac_eof=`expr $ac_eof + 1`
26572 fi
26573
26574 cat >>$CONFIG_STATUS <<_ACEOF
26575 cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
26576 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
26577 _ACEOF
26578 sed '
26579 s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
26580 s/^/s,@/; s/!/@,|#_!!_#|/
26581 :n
26582 t n
26583 s/'"$ac_delim"'$/,g/; t
26584 s/$/\\/; p
26585 N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
26586 ' >>$CONFIG_STATUS <conf$$subs.sed
26587 rm -f conf$$subs.sed
26588 cat >>$CONFIG_STATUS <<_ACEOF
26589 CEOF$ac_eof
26590 _ACEOF
26591
26592
26593 ac_delim='%!_!# '
26594 for ac_last_try in false false false false false :; do
26595   cat >conf$$subs.sed <<_ACEOF
26596 TAR!$TAR$ac_delim
26597 LN_S!$LN_S$ac_delim
26598 AWK!$AWK$ac_delim
26599 BISON!$BISON$ac_delim
26600 BISONFLAGS!$BISONFLAGS$ac_delim
26601 FLEX!$FLEX$ac_delim
26602 FLEXFLAGS!$FLEXFLAGS$ac_delim
26603 PERL!$PERL$ac_delim
26604 perl_archlibexp!$perl_archlibexp$ac_delim
26605 perl_privlibexp!$perl_privlibexp$ac_delim
26606 perl_useshrplib!$perl_useshrplib$ac_delim
26607 perl_embed_ldflags!$perl_embed_ldflags$ac_delim
26608 PYTHON!$PYTHON$ac_delim
26609 python_version!$python_version$ac_delim
26610 python_configdir!$python_configdir$ac_delim
26611 python_includespec!$python_includespec$ac_delim
26612 python_libdir!$python_libdir$ac_delim
26613 python_libspec!$python_libspec$ac_delim
26614 python_additional_libs!$python_additional_libs$ac_delim
26615 OSSP_UUID_LIBS!$OSSP_UUID_LIBS$ac_delim
26616 HAVE_IPV6!$HAVE_IPV6$ac_delim
26617 LIBOBJS!$LIBOBJS$ac_delim
26618 acx_pthread_config!$acx_pthread_config$ac_delim
26619 PTHREAD_CC!$PTHREAD_CC$ac_delim
26620 PTHREAD_LIBS!$PTHREAD_LIBS$ac_delim
26621 PTHREAD_CFLAGS!$PTHREAD_CFLAGS$ac_delim
26622 LDAP_LIBS_FE!$LDAP_LIBS_FE$ac_delim
26623 LDAP_LIBS_BE!$LDAP_LIBS_BE$ac_delim
26624 HAVE_POSIX_SIGNALS!$HAVE_POSIX_SIGNALS$ac_delim
26625 MSGFMT!$MSGFMT$ac_delim
26626 MSGMERGE!$MSGMERGE$ac_delim
26627 XGETTEXT!$XGETTEXT$ac_delim
26628 TCLSH!$TCLSH$ac_delim
26629 TCL_CONFIG_SH!$TCL_CONFIG_SH$ac_delim
26630 TCL_INCLUDE_SPEC!$TCL_INCLUDE_SPEC$ac_delim
26631 TCL_LIB_FILE!$TCL_LIB_FILE$ac_delim
26632 TCL_LIBS!$TCL_LIBS$ac_delim
26633 TCL_LIB_SPEC!$TCL_LIB_SPEC$ac_delim
26634 TCL_SHARED_BUILD!$TCL_SHARED_BUILD$ac_delim
26635 TCL_SHLIB_LD_LIBS!$TCL_SHLIB_LD_LIBS$ac_delim
26636 NSGMLS!$NSGMLS$ac_delim
26637 JADE!$JADE$ac_delim
26638 have_docbook!$have_docbook$ac_delim
26639 DOCBOOKSTYLE!$DOCBOOKSTYLE$ac_delim
26640 COLLATEINDEX!$COLLATEINDEX$ac_delim
26641 SGMLSPL!$SGMLSPL$ac_delim
26642 vpath_build!$vpath_build$ac_delim
26643 LTLIBOBJS!$LTLIBOBJS$ac_delim
26644 _ACEOF
26645
26646   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 48; then
26647     break
26648   elif $ac_last_try; then
26649     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26650 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
26651    { (exit 1); exit 1; }; }
26652   else
26653     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26654   fi
26655 done
26656
26657 ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
26658 if test -n "$ac_eof"; then
26659   ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
26660   ac_eof=`expr $ac_eof + 1`
26661 fi
26662
26663 cat >>$CONFIG_STATUS <<_ACEOF
26664 cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
26665 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
26666 _ACEOF
26667 sed '
26668 s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
26669 s/^/s,@/; s/!/@,|#_!!_#|/
26670 :n
26671 t n
26672 s/'"$ac_delim"'$/,g/; t
26673 s/$/\\/; p
26674 N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
26675 ' >>$CONFIG_STATUS <conf$$subs.sed
26676 rm -f conf$$subs.sed
26677 cat >>$CONFIG_STATUS <<_ACEOF
26678 :end
26679 s/|#_!!_#|//g
26680 CEOF$ac_eof
26681 _ACEOF
26682
26683
26684 # VPATH may cause trouble with some makes, so we remove $(srcdir),
26685 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
26686 # trailing colons and then remove the whole line if VPATH becomes empty
26687 # (actually we leave an empty line to preserve line numbers).
26688 if test "x$srcdir" = x.; then
26689   ac_vpsub='/^[  ]*VPATH[        ]*=/{
26690 s/:*\$(srcdir):*/:/
26691 s/:*\${srcdir}:*/:/
26692 s/:*@srcdir@:*/:/
26693 s/^\([^=]*=[     ]*\):*/\1/
26694 s/:*$//
26695 s/^[^=]*=[       ]*$//
26696 }'
26697 fi
26698
26699 cat >>$CONFIG_STATUS <<\_ACEOF
26700 fi # test -n "$CONFIG_FILES"
26701
26702
26703 for ac_tag in  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS
26704 do
26705   case $ac_tag in
26706   :[FHLC]) ac_mode=$ac_tag; continue;;
26707   esac
26708   case $ac_mode$ac_tag in
26709   :[FHL]*:*);;
26710   :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
26711 echo "$as_me: error: Invalid tag $ac_tag." >&2;}
26712    { (exit 1); exit 1; }; };;
26713   :[FH]-) ac_tag=-:-;;
26714   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
26715   esac
26716   ac_save_IFS=$IFS
26717   IFS=:
26718   set x $ac_tag
26719   IFS=$ac_save_IFS
26720   shift
26721   ac_file=$1
26722   shift
26723
26724   case $ac_mode in
26725   :L) ac_source=$1;;
26726   :[FH])
26727     ac_file_inputs=
26728     for ac_f
26729     do
26730       case $ac_f in
26731       -) ac_f="$tmp/stdin";;
26732       *) # Look for the file first in the build tree, then in the source tree
26733          # (if the path is not absolute).  The absolute path cannot be DOS-style,
26734          # because $ac_f cannot contain `:'.
26735          test -f "$ac_f" ||
26736            case $ac_f in
26737            [\\/$]*) false;;
26738            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
26739            esac ||
26740            { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
26741 echo "$as_me: error: cannot find input file: $ac_f" >&2;}
26742    { (exit 1); exit 1; }; };;
26743       esac
26744       ac_file_inputs="$ac_file_inputs $ac_f"
26745     done
26746
26747     # Let's still pretend it is `configure' which instantiates (i.e., don't
26748     # use $as_me), people would be surprised to read:
26749     #    /* config.h.  Generated by config.status.  */
26750     configure_input="Generated from "`IFS=:
26751           echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
26752     if test x"$ac_file" != x-; then
26753       configure_input="$ac_file.  $configure_input"
26754       { echo "$as_me:$LINENO: creating $ac_file" >&5
26755 echo "$as_me: creating $ac_file" >&6;}
26756     fi
26757
26758     case $ac_tag in
26759     *:-:* | *:-) cat >"$tmp/stdin";;
26760     esac
26761     ;;
26762   esac
26763
26764   ac_dir=`$as_dirname -- "$ac_file" ||
26765 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26766          X"$ac_file" : 'X\(//\)[^/]' \| \
26767          X"$ac_file" : 'X\(//\)$' \| \
26768          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
26769 echo X"$ac_file" |
26770     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26771             s//\1/
26772             q
26773           }
26774           /^X\(\/\/\)[^/].*/{
26775             s//\1/
26776             q
26777           }
26778           /^X\(\/\/\)$/{
26779             s//\1/
26780             q
26781           }
26782           /^X\(\/\).*/{
26783             s//\1/
26784             q
26785           }
26786           s/.*/./; q'`
26787   { as_dir="$ac_dir"
26788   case $as_dir in #(
26789   -*) as_dir=./$as_dir;;
26790   esac
26791   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
26792     as_dirs=
26793     while :; do
26794       case $as_dir in #(
26795       *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
26796       *) as_qdir=$as_dir;;
26797       esac
26798       as_dirs="'$as_qdir' $as_dirs"
26799       as_dir=`$as_dirname -- "$as_dir" ||
26800 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26801          X"$as_dir" : 'X\(//\)[^/]' \| \
26802          X"$as_dir" : 'X\(//\)$' \| \
26803          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
26804 echo X"$as_dir" |
26805     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26806             s//\1/
26807             q
26808           }
26809           /^X\(\/\/\)[^/].*/{
26810             s//\1/
26811             q
26812           }
26813           /^X\(\/\/\)$/{
26814             s//\1/
26815             q
26816           }
26817           /^X\(\/\).*/{
26818             s//\1/
26819             q
26820           }
26821           s/.*/./; q'`
26822       test -d "$as_dir" && break
26823     done
26824     test -z "$as_dirs" || eval "mkdir $as_dirs"
26825   } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
26826 echo "$as_me: error: cannot create directory $as_dir" >&2;}
26827    { (exit 1); exit 1; }; }; }
26828   ac_builddir=.
26829
26830 case "$ac_dir" in
26831 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
26832 *)
26833   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
26834   # A ".." for each directory in $ac_dir_suffix.
26835   ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
26836   case $ac_top_builddir_sub in
26837   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
26838   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
26839   esac ;;
26840 esac
26841 ac_abs_top_builddir=$ac_pwd
26842 ac_abs_builddir=$ac_pwd$ac_dir_suffix
26843 # for backward compatibility:
26844 ac_top_builddir=$ac_top_build_prefix
26845
26846 case $srcdir in
26847   .)  # We are building in place.
26848     ac_srcdir=.
26849     ac_top_srcdir=$ac_top_builddir_sub
26850     ac_abs_top_srcdir=$ac_pwd ;;
26851   [\\/]* | ?:[\\/]* )  # Absolute name.
26852     ac_srcdir=$srcdir$ac_dir_suffix;
26853     ac_top_srcdir=$srcdir
26854     ac_abs_top_srcdir=$srcdir ;;
26855   *) # Relative name.
26856     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
26857     ac_top_srcdir=$ac_top_build_prefix$srcdir
26858     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
26859 esac
26860 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
26861
26862
26863   case $ac_mode in
26864   :F)
26865   #
26866   # CONFIG_FILE
26867   #
26868
26869 _ACEOF
26870
26871 cat >>$CONFIG_STATUS <<\_ACEOF
26872 # If the template does not know about datarootdir, expand it.
26873 # FIXME: This hack should be removed a few years after 2.60.
26874 ac_datarootdir_hack=; ac_datarootdir_seen=
26875
26876 case `sed -n '/datarootdir/ {
26877   p
26878   q
26879 }
26880 /@datadir@/p
26881 /@docdir@/p
26882 /@infodir@/p
26883 /@localedir@/p
26884 /@mandir@/p
26885 ' $ac_file_inputs` in
26886 *datarootdir*) ac_datarootdir_seen=yes;;
26887 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
26888   { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
26889 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
26890 _ACEOF
26891 cat >>$CONFIG_STATUS <<_ACEOF
26892   ac_datarootdir_hack='
26893   s&@datadir@&$datadir&g
26894   s&@docdir@&$docdir&g
26895   s&@infodir@&$infodir&g
26896   s&@localedir@&$localedir&g
26897   s&@mandir@&$mandir&g
26898     s&\\\${datarootdir}&$datarootdir&g' ;;
26899 esac
26900 _ACEOF
26901
26902 # Neutralize VPATH when `$srcdir' = `.'.
26903 # Shell code in configure.ac might set extrasub.
26904 # FIXME: do we really want to maintain this feature?
26905 cat >>$CONFIG_STATUS <<_ACEOF
26906   sed "$ac_vpsub
26907 $extrasub
26908 _ACEOF
26909 cat >>$CONFIG_STATUS <<\_ACEOF
26910 :t
26911 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
26912 s&@configure_input@&$configure_input&;t t
26913 s&@top_builddir@&$ac_top_builddir_sub&;t t
26914 s&@srcdir@&$ac_srcdir&;t t
26915 s&@abs_srcdir@&$ac_abs_srcdir&;t t
26916 s&@top_srcdir@&$ac_top_srcdir&;t t
26917 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
26918 s&@builddir@&$ac_builddir&;t t
26919 s&@abs_builddir@&$ac_abs_builddir&;t t
26920 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
26921 $ac_datarootdir_hack
26922 " $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
26923
26924 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
26925   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
26926   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
26927   { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26928 which seems to be undefined.  Please make sure it is defined." >&5
26929 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26930 which seems to be undefined.  Please make sure it is defined." >&2;}
26931
26932   rm -f "$tmp/stdin"
26933   case $ac_file in
26934   -) cat "$tmp/out"; rm -f "$tmp/out";;
26935   *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
26936   esac
26937  ;;
26938   :H)
26939   #
26940   # CONFIG_HEADER
26941   #
26942 _ACEOF
26943
26944 # Transform confdefs.h into a sed script `conftest.defines', that
26945 # substitutes the proper values into config.h.in to produce config.h.
26946 rm -f conftest.defines conftest.tail
26947 # First, append a space to every undef/define line, to ease matching.
26948 echo 's/$/ /' >conftest.defines
26949 # Then, protect against being on the right side of a sed subst, or in
26950 # an unquoted here document, in config.status.  If some macros were
26951 # called several times there might be several #defines for the same
26952 # symbol, which is useless.  But do not sort them, since the last
26953 # AC_DEFINE must be honored.
26954 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
26955 # These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
26956 # NAME is the cpp macro being defined, VALUE is the value it is being given.
26957 # PARAMS is the parameter list in the macro definition--in most cases, it's
26958 # just an empty string.
26959 ac_dA='s,^\\([   #]*\\)[^        ]*\\([  ]*'
26960 ac_dB='\\)[      (].*,\\1define\\2'
26961 ac_dC=' '
26962 ac_dD=' ,'
26963
26964 uniq confdefs.h |
26965   sed -n '
26966         t rset
26967         :rset
26968         s/^[     ]*#[    ]*define[       ][      ]*//
26969         t ok
26970         d
26971         :ok
26972         s/[\\&,]/\\&/g
26973         s/^\('"$ac_word_re"'\)\(([^()]*)\)[      ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
26974         s/^\('"$ac_word_re"'\)[  ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
26975   ' >>conftest.defines
26976
26977 # Remove the space that was appended to ease matching.
26978 # Then replace #undef with comments.  This is necessary, for
26979 # example, in the case of _POSIX_SOURCE, which is predefined and required
26980 # on some systems where configure will not decide to define it.
26981 # (The regexp can be short, since the line contains either #define or #undef.)
26982 echo 's/ $//
26983 s,^[     #]*u.*,/* & */,' >>conftest.defines
26984
26985 # Break up conftest.defines:
26986 ac_max_sed_lines=50
26987
26988 # First sed command is:  sed -f defines.sed $ac_file_inputs >"$tmp/out1"
26989 # Second one is:         sed -f defines.sed "$tmp/out1" >"$tmp/out2"
26990 # Third one will be:     sed -f defines.sed "$tmp/out2" >"$tmp/out1"
26991 # et cetera.
26992 ac_in='$ac_file_inputs'
26993 ac_out='"$tmp/out1"'
26994 ac_nxt='"$tmp/out2"'
26995
26996 while :
26997 do
26998   # Write a here document:
26999     cat >>$CONFIG_STATUS <<_ACEOF
27000     # First, check the format of the line:
27001     cat >"\$tmp/defines.sed" <<\\CEOF
27002 /^[      ]*#[    ]*undef[        ][      ]*$ac_word_re[  ]*\$/b def
27003 /^[      ]*#[    ]*define[       ][      ]*$ac_word_re[(         ]/b def
27004 b
27005 :def
27006 _ACEOF
27007   sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
27008   echo 'CEOF
27009     sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
27010   ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
27011   sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
27012   grep . conftest.tail >/dev/null || break
27013   rm -f conftest.defines
27014   mv conftest.tail conftest.defines
27015 done
27016 rm -f conftest.defines conftest.tail
27017
27018 echo "ac_result=$ac_in" >>$CONFIG_STATUS
27019 cat >>$CONFIG_STATUS <<\_ACEOF
27020   if test x"$ac_file" != x-; then
27021     echo "/* $configure_input  */" >"$tmp/config.h"
27022     cat "$ac_result" >>"$tmp/config.h"
27023     if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
27024       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
27025 echo "$as_me: $ac_file is unchanged" >&6;}
27026     else
27027       rm -f $ac_file
27028       mv "$tmp/config.h" $ac_file
27029     fi
27030   else
27031     echo "/* $configure_input  */"
27032     cat "$ac_result"
27033   fi
27034   rm -f "$tmp/out12"
27035  ;;
27036   :L)
27037   #
27038   # CONFIG_LINK
27039   #
27040
27041   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_file" >&5
27042 echo "$as_me: linking $srcdir/$ac_source to $ac_file" >&6;}
27043
27044   if test ! -r "$srcdir/$ac_source"; then
27045     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
27046 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
27047    { (exit 1); exit 1; }; }
27048   fi
27049   rm -f "$ac_file"
27050
27051   # Try a relative symlink, then a hard link, then a copy.
27052   case $srcdir in
27053   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
27054       *) ac_rel_source=$ac_top_build_prefix$srcdir/$ac_source ;;
27055   esac
27056   ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
27057     ln "$srcdir/$ac_source" "$ac_file" 2>/dev/null ||
27058     cp -p "$srcdir/$ac_source" "$ac_file" ||
27059     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_file" >&5
27060 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_file" >&2;}
27061    { (exit 1); exit 1; }; }
27062  ;;
27063   :C)  { echo "$as_me:$LINENO: executing $ac_file commands" >&5
27064 echo "$as_me: executing $ac_file commands" >&6;}
27065  ;;
27066   esac
27067
27068
27069   case $ac_file$ac_mode in
27070     "check_win32_symlinks":C)
27071 # Links sometimes fail undetected on Mingw -
27072 # so here we detect it and warn the user
27073 for FILE in $CONFIG_LINKS
27074  do
27075         # test -e works for symlinks in the MinGW console
27076         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
27077 echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
27078  done
27079  ;;
27080     "src/include/pg_config.h":H)
27081 # Update timestamp for pg_config.h (see Makefile.global)
27082 echo >src/include/stamp-h
27083  ;;
27084
27085   esac
27086 done # for ac_tag
27087
27088
27089 { (exit 0); exit 0; }
27090 _ACEOF
27091 chmod +x $CONFIG_STATUS
27092 ac_clean_files=$ac_clean_files_save
27093
27094
27095 # configure is writing to config.log, and then calls config.status.
27096 # config.status does its own redirection, appending to config.log.
27097 # Unfortunately, on DOS this fails, as config.log is still kept open
27098 # by configure, so config.status won't be able to write to it; its
27099 # output is simply discarded.  So we exec the FD to /dev/null,
27100 # effectively closing config.log, so it can be properly (re)opened and
27101 # appended to by config.status.  When coming back to configure, we
27102 # need to make the FD available again.
27103 if test "$no_create" != yes; then
27104   ac_cs_success=:
27105   ac_config_status_args=
27106   test "$silent" = yes &&
27107     ac_config_status_args="$ac_config_status_args --quiet"
27108   exec 5>/dev/null
27109   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
27110   exec 5>>config.log
27111   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
27112   # would make configure fail if this is the last instruction.
27113   $ac_cs_success || { (exit 1); exit 1; }
27114 fi
27115
27116
27117 # Warn about unknown options
27118 for pgac_var in `set | sed 's/=.*//' | $EGREP 'with_|enable_'`; do
27119   for pgac_arg in $pgac_args with_gnu_ld; do
27120     if test "$pgac_var" = "$pgac_arg"; then
27121       continue 2
27122     fi
27123   done
27124   pgac_txt=`echo $pgac_var | sed 's/_/-/g'`
27125   { echo "$as_me:$LINENO: WARNING: option ignored: --$pgac_txt" >&5
27126 echo "$as_me: WARNING: option ignored: --$pgac_txt" >&2;}
27127 done