]> granicus.if.org Git - postgresql/blob - configure
Fix postgres --describe-config for guc enums, breakage noted by Alvaro.
[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 YACC
722 YFLAGS
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   --enable-integer-datetimes  enable 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   --disable-segmented-files disable data file segmentation (requires largefile support)
1361   --enable-depend         turn on automatic dependency tracking
1362   --enable-cassert        enable assertion checks (for debugging)
1363   --enable-thread-safety  make client libraries thread-safe
1364   --enable-thread-safety-force  force thread-safety despite thread test failure
1365   --disable-largefile     omit support for large files
1366
1367 Optional Packages:
1368   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1369   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1370
1371   --with-includes=DIRS    look for additional header files in DIRS
1372   --with-libraries=DIRS   look for additional libraries in DIRS
1373   --with-libs=DIRS        alternative spelling of --with-libraries
1374   --with-pgport=PORTNUM   change default port number [5432]
1375   --with-tcl              build Tcl modules (PL/Tcl)
1376   --with-tclconfig=DIR    tclConfig.sh is in DIR
1377   --with-perl             build Perl modules (PL/Perl)
1378   --with-python           build Python modules (PL/Python)
1379   --with-gssapi           build with GSSAPI support
1380   --with-krb5             build with Kerberos 5 support
1381   --with-krb-srvnam=NAME  default service principal name in Kerberos [postgres]
1382   --with-pam              build with PAM support
1383   --with-ldap             build with LDAP support
1384   --with-bonjour          build with Bonjour support
1385   --with-openssl          build with OpenSSL support
1386   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1387   --with-libedit-preferred  prefer BSD Libedit over GNU Readline
1388   --with-ossp-uuid        use OSSP UUID library when building contrib/uuid-ossp
1389   --with-libxml           build with XML support
1390   --with-libxslt          use XSLT support when building contrib/xml2
1391   --with-system-tzdata=DIR  use system time zone data in DIR
1392   --without-zlib          do not use Zlib
1393   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1394
1395 Some influential environment variables:
1396   CC          C compiler command
1397   CFLAGS      C compiler flags
1398   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1399               nonstandard directory <lib dir>
1400   LIBS        libraries to pass to the linker, e.g. -l<library>
1401   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1402               you have headers in a nonstandard directory <include dir>
1403   CPP         C preprocessor
1404   LDFLAGS_SL
1405   DOCBOOKSTYLE
1406               location of DocBook stylesheets
1407
1408 Use these variables to override the choices made by `configure' or to help
1409 it to find libraries and programs with nonstandard names/locations.
1410
1411 Report bugs to <pgsql-bugs@postgresql.org>.
1412 _ACEOF
1413 ac_status=$?
1414 fi
1415
1416 if test "$ac_init_help" = "recursive"; then
1417   # If there are subdirs, report their specific --help.
1418   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1419     test -d "$ac_dir" || continue
1420     ac_builddir=.
1421
1422 case "$ac_dir" in
1423 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1424 *)
1425   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1426   # A ".." for each directory in $ac_dir_suffix.
1427   ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
1428   case $ac_top_builddir_sub in
1429   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1430   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1431   esac ;;
1432 esac
1433 ac_abs_top_builddir=$ac_pwd
1434 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1435 # for backward compatibility:
1436 ac_top_builddir=$ac_top_build_prefix
1437
1438 case $srcdir in
1439   .)  # We are building in place.
1440     ac_srcdir=.
1441     ac_top_srcdir=$ac_top_builddir_sub
1442     ac_abs_top_srcdir=$ac_pwd ;;
1443   [\\/]* | ?:[\\/]* )  # Absolute name.
1444     ac_srcdir=$srcdir$ac_dir_suffix;
1445     ac_top_srcdir=$srcdir
1446     ac_abs_top_srcdir=$srcdir ;;
1447   *) # Relative name.
1448     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1449     ac_top_srcdir=$ac_top_build_prefix$srcdir
1450     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1451 esac
1452 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1453
1454     cd "$ac_dir" || { ac_status=$?; continue; }
1455     # Check for guested configure.
1456     if test -f "$ac_srcdir/configure.gnu"; then
1457       echo &&
1458       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1459     elif test -f "$ac_srcdir/configure"; then
1460       echo &&
1461       $SHELL "$ac_srcdir/configure" --help=recursive
1462     else
1463       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1464     fi || ac_status=$?
1465     cd "$ac_pwd" || { ac_status=$?; break; }
1466   done
1467 fi
1468
1469 test -n "$ac_init_help" && exit $ac_status
1470 if $ac_init_version; then
1471   cat <<\_ACEOF
1472 PostgreSQL configure 8.4devel
1473 generated by GNU Autoconf 2.61
1474
1475 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1476 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
1477 This configure script is free software; the Free Software Foundation
1478 gives unlimited permission to copy, distribute and modify it.
1479
1480 Copyright (c) 1996-2008, PostgreSQL Global Development Group
1481 _ACEOF
1482   exit
1483 fi
1484 cat >config.log <<_ACEOF
1485 This file contains any messages produced by compilers while
1486 running configure, to aid debugging if configure makes a mistake.
1487
1488 It was created by PostgreSQL $as_me 8.4devel, which was
1489 generated by GNU Autoconf 2.61.  Invocation command line was
1490
1491   $ $0 $@
1492
1493 _ACEOF
1494 exec 5>>config.log
1495 {
1496 cat <<_ASUNAME
1497 ## --------- ##
1498 ## Platform. ##
1499 ## --------- ##
1500
1501 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1502 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1503 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1504 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1505 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1506
1507 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1508 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1509
1510 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1511 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1512 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1513 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1514 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1515 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1516 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1517
1518 _ASUNAME
1519
1520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1521 for as_dir in $PATH
1522 do
1523   IFS=$as_save_IFS
1524   test -z "$as_dir" && as_dir=.
1525   echo "PATH: $as_dir"
1526 done
1527 IFS=$as_save_IFS
1528
1529 } >&5
1530
1531 cat >&5 <<_ACEOF
1532
1533
1534 ## ----------- ##
1535 ## Core tests. ##
1536 ## ----------- ##
1537
1538 _ACEOF
1539
1540
1541 # Keep a trace of the command line.
1542 # Strip out --no-create and --no-recursion so they do not pile up.
1543 # Strip out --silent because we don't want to record it for future runs.
1544 # Also quote any args containing shell meta-characters.
1545 # Make two passes to allow for proper duplicate-argument suppression.
1546 ac_configure_args=
1547 ac_configure_args0=
1548 ac_configure_args1=
1549 ac_must_keep_next=false
1550 for ac_pass in 1 2
1551 do
1552   for ac_arg
1553   do
1554     case $ac_arg in
1555     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1556     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1557     | -silent | --silent | --silen | --sile | --sil)
1558       continue ;;
1559     *\'*)
1560       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1561     esac
1562     case $ac_pass in
1563     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1564     2)
1565       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1566       if test $ac_must_keep_next = true; then
1567         ac_must_keep_next=false # Got value, back to normal.
1568       else
1569         case $ac_arg in
1570           *=* | --config-cache | -C | -disable-* | --disable-* \
1571           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1572           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1573           | -with-* | --with-* | -without-* | --without-* | --x)
1574             case "$ac_configure_args0 " in
1575               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1576             esac
1577             ;;
1578           -* ) ac_must_keep_next=true ;;
1579         esac
1580       fi
1581       ac_configure_args="$ac_configure_args '$ac_arg'"
1582       ;;
1583     esac
1584   done
1585 done
1586 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1587 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1588
1589 # When interrupted or exit'd, cleanup temporary files, and complete
1590 # config.log.  We remove comments because anyway the quotes in there
1591 # would cause problems or look ugly.
1592 # WARNING: Use '\'' to represent an apostrophe within the trap.
1593 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1594 trap 'exit_status=$?
1595   # Save into config.log some information that might help in debugging.
1596   {
1597     echo
1598
1599     cat <<\_ASBOX
1600 ## ---------------- ##
1601 ## Cache variables. ##
1602 ## ---------------- ##
1603 _ASBOX
1604     echo
1605     # The following way of writing the cache mishandles newlines in values,
1606 (
1607   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1608     eval ac_val=\$$ac_var
1609     case $ac_val in #(
1610     *${as_nl}*)
1611       case $ac_var in #(
1612       *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
1613 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
1614       esac
1615       case $ac_var in #(
1616       _ | IFS | as_nl) ;; #(
1617       *) $as_unset $ac_var ;;
1618       esac ;;
1619     esac
1620   done
1621   (set) 2>&1 |
1622     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1623     *${as_nl}ac_space=\ *)
1624       sed -n \
1625         "s/'\''/'\''\\\\'\'''\''/g;
1626           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1627       ;; #(
1628     *)
1629       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1630       ;;
1631     esac |
1632     sort
1633 )
1634     echo
1635
1636     cat <<\_ASBOX
1637 ## ----------------- ##
1638 ## Output variables. ##
1639 ## ----------------- ##
1640 _ASBOX
1641     echo
1642     for ac_var in $ac_subst_vars
1643     do
1644       eval ac_val=\$$ac_var
1645       case $ac_val in
1646       *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1647       esac
1648       echo "$ac_var='\''$ac_val'\''"
1649     done | sort
1650     echo
1651
1652     if test -n "$ac_subst_files"; then
1653       cat <<\_ASBOX
1654 ## ------------------- ##
1655 ## File substitutions. ##
1656 ## ------------------- ##
1657 _ASBOX
1658       echo
1659       for ac_var in $ac_subst_files
1660       do
1661         eval ac_val=\$$ac_var
1662         case $ac_val in
1663         *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1664         esac
1665         echo "$ac_var='\''$ac_val'\''"
1666       done | sort
1667       echo
1668     fi
1669
1670     if test -s confdefs.h; then
1671       cat <<\_ASBOX
1672 ## ----------- ##
1673 ## confdefs.h. ##
1674 ## ----------- ##
1675 _ASBOX
1676       echo
1677       cat confdefs.h
1678       echo
1679     fi
1680     test "$ac_signal" != 0 &&
1681       echo "$as_me: caught signal $ac_signal"
1682     echo "$as_me: exit $exit_status"
1683   } >&5
1684   rm -f core *.core core.conftest.* &&
1685     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1686     exit $exit_status
1687 ' 0
1688 for ac_signal in 1 2 13 15; do
1689   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1690 done
1691 ac_signal=0
1692
1693 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1694 rm -f -r conftest* confdefs.h
1695
1696 # Predefined preprocessor variables.
1697
1698 cat >>confdefs.h <<_ACEOF
1699 #define PACKAGE_NAME "$PACKAGE_NAME"
1700 _ACEOF
1701
1702
1703 cat >>confdefs.h <<_ACEOF
1704 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1705 _ACEOF
1706
1707
1708 cat >>confdefs.h <<_ACEOF
1709 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1710 _ACEOF
1711
1712
1713 cat >>confdefs.h <<_ACEOF
1714 #define PACKAGE_STRING "$PACKAGE_STRING"
1715 _ACEOF
1716
1717
1718 cat >>confdefs.h <<_ACEOF
1719 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1720 _ACEOF
1721
1722
1723 # Let the site file select an alternate cache file if it wants to.
1724 # Prefer explicitly selected file to automatically selected ones.
1725 if test -n "$CONFIG_SITE"; then
1726   set x "$CONFIG_SITE"
1727 elif test "x$prefix" != xNONE; then
1728   set x "$prefix/share/config.site" "$prefix/etc/config.site"
1729 else
1730   set x "$ac_default_prefix/share/config.site" \
1731         "$ac_default_prefix/etc/config.site"
1732 fi
1733 shift
1734 for ac_site_file
1735 do
1736   if test -r "$ac_site_file"; then
1737     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1738 echo "$as_me: loading site script $ac_site_file" >&6;}
1739     sed 's/^/| /' "$ac_site_file" >&5
1740     . "$ac_site_file"
1741   fi
1742 done
1743
1744 if test -r "$cache_file"; then
1745   # Some versions of bash will fail to source /dev/null (special
1746   # files actually), so we avoid doing that.
1747   if test -f "$cache_file"; then
1748     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1749 echo "$as_me: loading cache $cache_file" >&6;}
1750     case $cache_file in
1751       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1752       *)                      . "./$cache_file";;
1753     esac
1754   fi
1755 else
1756   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1757 echo "$as_me: creating cache $cache_file" >&6;}
1758   >$cache_file
1759 fi
1760
1761 # Check that the precious variables saved in the cache have kept the same
1762 # value.
1763 ac_cache_corrupted=false
1764 for ac_var in $ac_precious_vars; do
1765   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1766   eval ac_new_set=\$ac_env_${ac_var}_set
1767   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1768   eval ac_new_val=\$ac_env_${ac_var}_value
1769   case $ac_old_set,$ac_new_set in
1770     set,)
1771       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1772 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1773       ac_cache_corrupted=: ;;
1774     ,set)
1775       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1776 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1777       ac_cache_corrupted=: ;;
1778     ,);;
1779     *)
1780       if test "x$ac_old_val" != "x$ac_new_val"; then
1781         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1782 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1783         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1784 echo "$as_me:   former value:  $ac_old_val" >&2;}
1785         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1786 echo "$as_me:   current value: $ac_new_val" >&2;}
1787         ac_cache_corrupted=:
1788       fi;;
1789   esac
1790   # Pass precious variables to config.status.
1791   if test "$ac_new_set" = set; then
1792     case $ac_new_val in
1793     *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1794     *) ac_arg=$ac_var=$ac_new_val ;;
1795     esac
1796     case " $ac_configure_args " in
1797       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1798       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1799     esac
1800   fi
1801 done
1802 if $ac_cache_corrupted; then
1803   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1804 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1805   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1806 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1807    { (exit 1); exit 1; }; }
1808 fi
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834 ac_ext=c
1835 ac_cpp='$CPP $CPPFLAGS'
1836 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1837 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1838 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1839
1840
1841
1842
1843
1844
1845 ac_aux_dir=
1846 for ac_dir in config "$srcdir"/config; do
1847   if test -f "$ac_dir/install-sh"; then
1848     ac_aux_dir=$ac_dir
1849     ac_install_sh="$ac_aux_dir/install-sh -c"
1850     break
1851   elif test -f "$ac_dir/install.sh"; then
1852     ac_aux_dir=$ac_dir
1853     ac_install_sh="$ac_aux_dir/install.sh -c"
1854     break
1855   elif test -f "$ac_dir/shtool"; then
1856     ac_aux_dir=$ac_dir
1857     ac_install_sh="$ac_aux_dir/shtool install -c"
1858     break
1859   fi
1860 done
1861 if test -z "$ac_aux_dir"; then
1862   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
1863 echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
1864    { (exit 1); exit 1; }; }
1865 fi
1866
1867 # These three variables are undocumented and unsupported,
1868 # and are intended to be withdrawn in a future Autoconf release.
1869 # They can cause serious problems if a builder's source tree is in a directory
1870 # whose full name contains unusual characters.
1871 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
1872 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
1873 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
1874
1875
1876
1877 configure_args=$ac_configure_args
1878
1879
1880
1881 cat >>confdefs.h <<_ACEOF
1882 #define PG_VERSION "$PACKAGE_VERSION"
1883 _ACEOF
1884
1885
1886 # Make sure we can run config.sub.
1887 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
1888   { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
1889 echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
1890    { (exit 1); exit 1; }; }
1891
1892 { echo "$as_me:$LINENO: checking build system type" >&5
1893 echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
1894 if test "${ac_cv_build+set}" = set; then
1895   echo $ECHO_N "(cached) $ECHO_C" >&6
1896 else
1897   ac_build_alias=$build_alias
1898 test "x$ac_build_alias" = x &&
1899   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
1900 test "x$ac_build_alias" = x &&
1901   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1902 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1903    { (exit 1); exit 1; }; }
1904 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
1905   { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
1906 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
1907    { (exit 1); exit 1; }; }
1908
1909 fi
1910 { echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1911 echo "${ECHO_T}$ac_cv_build" >&6; }
1912 case $ac_cv_build in
1913 *-*-*) ;;
1914 *) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
1915 echo "$as_me: error: invalid value of canonical build" >&2;}
1916    { (exit 1); exit 1; }; };;
1917 esac
1918 build=$ac_cv_build
1919 ac_save_IFS=$IFS; IFS='-'
1920 set x $ac_cv_build
1921 shift
1922 build_cpu=$1
1923 build_vendor=$2
1924 shift; shift
1925 # Remember, the first character of IFS is used to create $*,
1926 # except with old shells:
1927 build_os=$*
1928 IFS=$ac_save_IFS
1929 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
1930
1931
1932 { echo "$as_me:$LINENO: checking host system type" >&5
1933 echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
1934 if test "${ac_cv_host+set}" = set; then
1935   echo $ECHO_N "(cached) $ECHO_C" >&6
1936 else
1937   if test "x$host_alias" = x; then
1938   ac_cv_host=$ac_cv_build
1939 else
1940   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
1941     { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
1942 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
1943    { (exit 1); exit 1; }; }
1944 fi
1945
1946 fi
1947 { echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1948 echo "${ECHO_T}$ac_cv_host" >&6; }
1949 case $ac_cv_host in
1950 *-*-*) ;;
1951 *) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
1952 echo "$as_me: error: invalid value of canonical host" >&2;}
1953    { (exit 1); exit 1; }; };;
1954 esac
1955 host=$ac_cv_host
1956 ac_save_IFS=$IFS; IFS='-'
1957 set x $ac_cv_host
1958 shift
1959 host_cpu=$1
1960 host_vendor=$2
1961 shift; shift
1962 # Remember, the first character of IFS is used to create $*,
1963 # except with old shells:
1964 host_os=$*
1965 IFS=$ac_save_IFS
1966 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
1967
1968
1969
1970 template=
1971 { echo "$as_me:$LINENO: checking which template to use" >&5
1972 echo $ECHO_N "checking which template to use... $ECHO_C" >&6; }
1973
1974
1975 pgac_args="$pgac_args with_template"
1976
1977
1978 # Check whether --with-template was given.
1979 if test "${with_template+set}" = set; then
1980   withval=$with_template;
1981   case $withval in
1982     yes)
1983       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1984 echo "$as_me: error: argument required for --with-template option" >&2;}
1985    { (exit 1); exit 1; }; }
1986       ;;
1987     no)
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     *)
1993
1994   case $withval in
1995     list)   echo; ls "$srcdir/src/template"; exit;;
1996     *)      if test -f "$srcdir/src/template/$with_template" ; then
1997               template=$withval
1998             else
1999               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2000 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2001    { (exit 1); exit 1; }; }
2002             fi;;
2003   esac
2004
2005       ;;
2006   esac
2007
2008 else
2009
2010 # --with-template not given
2011
2012 case $host_os in
2013      aix*) template=aix ;;
2014     bsdi*) template=bsdi ;;
2015   cygwin*) template=cygwin ;;
2016   darwin*) template=darwin ;;
2017     dgux*) template=dgux ;;
2018  freebsd*) template=freebsd ;;
2019     hpux*) template=hpux ;;
2020     irix*) template=irix ;;
2021  linux*|gnu*|k*bsd*-gnu)
2022            template=linux ;;
2023    mingw*) template=win32 ;;
2024   netbsd*) template=netbsd ;;
2025 nextstep*) template=nextstep ;;
2026  openbsd*) template=openbsd ;;
2027      osf*) template=osf ;;
2028      sco*) template=sco ;;
2029  solaris*) template=solaris ;;
2030    sunos*) template=sunos4 ;;
2031  sysv4.2*)
2032         case $host_vendor in
2033           univel) template=univel ;;
2034         esac ;;
2035    sysv4*) template=svr4 ;;
2036    sysv5*) template=unixware ;;
2037   ultrix*) template=ultrix4 ;;
2038 esac
2039
2040   if test x"$template" = x"" ; then
2041     { { echo "$as_me:$LINENO: error:
2042 *******************************************************************
2043 PostgreSQL has apparently not been ported to your platform yet.
2044 To try a manual configuration, look into the src/template directory
2045 for a similar platform and use the '--with-template=' option.
2046
2047 Please also contact <pgsql-ports@postgresql.org> to see about
2048 rectifying this.  Include the above 'checking host system type...'
2049 line.
2050 *******************************************************************
2051 " >&5
2052 echo "$as_me: error:
2053 *******************************************************************
2054 PostgreSQL has apparently not been ported to your platform yet.
2055 To try a manual configuration, look into the src/template directory
2056 for a similar platform and use the '--with-template=' option.
2057
2058 Please also contact <pgsql-ports@postgresql.org> to see about
2059 rectifying this.  Include the above 'checking host system type...'
2060 line.
2061 *******************************************************************
2062 " >&2;}
2063    { (exit 1); exit 1; }; }
2064   fi
2065
2066
2067 fi
2068
2069
2070
2071 { echo "$as_me:$LINENO: result: $template" >&5
2072 echo "${ECHO_T}$template" >&6; }
2073
2074 PORTNAME=$template
2075
2076
2077 # Initialize default assumption that we do not need separate assembly code
2078 # for TAS (test-and-set).  This can be overridden by the template file
2079 # when it's executed.
2080 need_tas=no
2081 tas_file=dummy.s
2082
2083
2084
2085 ##
2086 ## Command line options
2087 ##
2088
2089 #
2090 # Add non-standard directories to the include path
2091 #
2092
2093 pgac_args="$pgac_args with_includes"
2094
2095
2096 # Check whether --with-includes was given.
2097 if test "${with_includes+set}" = set; then
2098   withval=$with_includes;
2099   case $withval in
2100     yes)
2101       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2102 echo "$as_me: error: argument required for --with-includes option" >&2;}
2103    { (exit 1); exit 1; }; }
2104       ;;
2105     no)
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     *)
2111
2112       ;;
2113   esac
2114
2115 fi
2116
2117
2118
2119
2120 #
2121 # Add non-standard directories to the library search path
2122 #
2123
2124 pgac_args="$pgac_args with_libraries"
2125
2126
2127 # Check whether --with-libraries was given.
2128 if test "${with_libraries+set}" = set; then
2129   withval=$with_libraries;
2130   case $withval in
2131     yes)
2132       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2133 echo "$as_me: error: argument required for --with-libraries option" >&2;}
2134    { (exit 1); exit 1; }; }
2135       ;;
2136     no)
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     *)
2142       LIBRARY_DIRS=$withval
2143       ;;
2144   esac
2145
2146 fi
2147
2148
2149
2150
2151 pgac_args="$pgac_args with_libs"
2152
2153
2154 # Check whether --with-libs was given.
2155 if test "${with_libs+set}" = set; then
2156   withval=$with_libs;
2157   case $withval in
2158     yes)
2159       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2160 echo "$as_me: error: argument required for --with-libs option" >&2;}
2161    { (exit 1); exit 1; }; }
2162       ;;
2163     no)
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     *)
2169       LIBRARY_DIRS=$withval
2170       ;;
2171   esac
2172
2173 fi
2174
2175
2176
2177
2178 #
2179 # 64-bit integer date/time storage (--enable-integer-datetimes)
2180 #
2181 { echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2182 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6; }
2183
2184 pgac_args="$pgac_args enable_integer_datetimes"
2185
2186 # Check whether --enable-integer-datetimes was given.
2187 if test "${enable_integer_datetimes+set}" = set; then
2188   enableval=$enable_integer_datetimes;
2189   case $enableval in
2190     yes)
2191
2192 cat >>confdefs.h <<\_ACEOF
2193 #define USE_INTEGER_DATETIMES 1
2194 _ACEOF
2195
2196       ;;
2197     no)
2198       :
2199       ;;
2200     *)
2201       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2202 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2203    { (exit 1); exit 1; }; }
2204       ;;
2205   esac
2206
2207 else
2208   enable_integer_datetimes=no
2209
2210 fi
2211
2212
2213 { echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2214 echo "${ECHO_T}$enable_integer_datetimes" >&6; }
2215
2216
2217 #
2218 # NLS
2219 #
2220 { echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2221 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6; }
2222
2223 pgac_args="$pgac_args enable_nls"
2224
2225 # Check whether --enable-nls was given.
2226 if test "${enable_nls+set}" = set; then
2227   enableval=$enable_nls;
2228   case $enableval in
2229     yes)
2230       :
2231       ;;
2232     no)
2233       :
2234       ;;
2235     *)
2236       enable_nls=yes
2237 WANTED_LANGUAGES=$enableval
2238       ;;
2239   esac
2240
2241 else
2242   enable_nls=no
2243 fi
2244
2245
2246
2247 if test "$enable_nls" = yes; then
2248
2249 cat >>confdefs.h <<\_ACEOF
2250 #define ENABLE_NLS 1
2251 _ACEOF
2252
2253 fi
2254
2255 { echo "$as_me:$LINENO: result: $enable_nls" >&5
2256 echo "${ECHO_T}$enable_nls" >&6; }
2257
2258
2259
2260 #
2261 # Default port number (--with-pgport), default 5432
2262 #
2263 { echo "$as_me:$LINENO: checking for default port number" >&5
2264 echo $ECHO_N "checking for default port number... $ECHO_C" >&6; }
2265
2266 pgac_args="$pgac_args with_pgport"
2267
2268
2269 # Check whether --with-pgport was given.
2270 if test "${with_pgport+set}" = set; then
2271   withval=$with_pgport;
2272   case $withval in
2273     yes)
2274       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2275 echo "$as_me: error: argument required for --with-pgport option" >&2;}
2276    { (exit 1); exit 1; }; }
2277       ;;
2278     no)
2279       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2280 echo "$as_me: error: argument required for --with-pgport option" >&2;}
2281    { (exit 1); exit 1; }; }
2282       ;;
2283     *)
2284       default_port=$withval
2285       ;;
2286   esac
2287
2288 else
2289   default_port=5432
2290 fi
2291
2292
2293 { echo "$as_me:$LINENO: result: $default_port" >&5
2294 echo "${ECHO_T}$default_port" >&6; }
2295 # Need both of these because some places want an integer and some a string
2296
2297 cat >>confdefs.h <<_ACEOF
2298 #define DEF_PGPORT ${default_port}
2299 _ACEOF
2300
2301
2302 cat >>confdefs.h <<_ACEOF
2303 #define DEF_PGPORT_STR "${default_port}"
2304 _ACEOF
2305
2306
2307
2308 #
2309 # Option to disable shared libraries
2310 #
2311
2312 pgac_args="$pgac_args enable_shared"
2313
2314 # Check whether --enable-shared was given.
2315 if test "${enable_shared+set}" = set; then
2316   enableval=$enable_shared;
2317   case $enableval in
2318     yes)
2319       :
2320       ;;
2321     no)
2322       :
2323       ;;
2324     *)
2325       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2326 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2327    { (exit 1); exit 1; }; }
2328       ;;
2329   esac
2330
2331 else
2332   enable_shared=yes
2333
2334 fi
2335
2336
2337
2338
2339 #
2340 # '-rpath'-like feature can be disabled
2341 #
2342
2343 pgac_args="$pgac_args enable_rpath"
2344
2345 # Check whether --enable-rpath was given.
2346 if test "${enable_rpath+set}" = set; then
2347   enableval=$enable_rpath;
2348   case $enableval in
2349     yes)
2350       :
2351       ;;
2352     no)
2353       :
2354       ;;
2355     *)
2356       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2357 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2358    { (exit 1); exit 1; }; }
2359       ;;
2360   esac
2361
2362 else
2363   enable_rpath=yes
2364
2365 fi
2366
2367
2368
2369
2370 #
2371 # Spinlocks
2372 #
2373
2374 pgac_args="$pgac_args enable_spinlocks"
2375
2376 # Check whether --enable-spinlocks was given.
2377 if test "${enable_spinlocks+set}" = set; then
2378   enableval=$enable_spinlocks;
2379   case $enableval in
2380     yes)
2381       :
2382       ;;
2383     no)
2384       :
2385       ;;
2386     *)
2387       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2388 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2389    { (exit 1); exit 1; }; }
2390       ;;
2391   esac
2392
2393 else
2394   enable_spinlocks=yes
2395
2396 fi
2397
2398
2399
2400 #
2401 # --enable-debug adds -g to compiler flags
2402 #
2403
2404 pgac_args="$pgac_args enable_debug"
2405
2406 # Check whether --enable-debug was given.
2407 if test "${enable_debug+set}" = set; then
2408   enableval=$enable_debug;
2409   case $enableval in
2410     yes)
2411       :
2412       ;;
2413     no)
2414       :
2415       ;;
2416     *)
2417       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2418 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2419    { (exit 1); exit 1; }; }
2420       ;;
2421   esac
2422
2423 else
2424   enable_debug=no
2425
2426 fi
2427
2428
2429
2430
2431 #
2432 # --enable-profiling enables gcc profiling
2433 #
2434
2435 pgac_args="$pgac_args enable_profiling"
2436
2437 # Check whether --enable-profiling was given.
2438 if test "${enable_profiling+set}" = set; then
2439   enableval=$enable_profiling;
2440   case $enableval in
2441     yes)
2442       :
2443       ;;
2444     no)
2445       :
2446       ;;
2447     *)
2448       { { echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2449 echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2450    { (exit 1); exit 1; }; }
2451       ;;
2452   esac
2453
2454 else
2455   enable_profiling=no
2456
2457 fi
2458
2459
2460
2461
2462 #
2463 # DTrace
2464 #
2465
2466 pgac_args="$pgac_args enable_dtrace"
2467
2468 # Check whether --enable-dtrace was given.
2469 if test "${enable_dtrace+set}" = set; then
2470   enableval=$enable_dtrace;
2471   case $enableval in
2472     yes)
2473
2474 cat >>confdefs.h <<\_ACEOF
2475 #define ENABLE_DTRACE 1
2476 _ACEOF
2477
2478 for ac_prog in dtrace
2479 do
2480   # Extract the first word of "$ac_prog", so it can be a program name with args.
2481 set dummy $ac_prog; ac_word=$2
2482 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2483 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2484 if test "${ac_cv_prog_DTRACE+set}" = set; then
2485   echo $ECHO_N "(cached) $ECHO_C" >&6
2486 else
2487   if test -n "$DTRACE"; then
2488   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2489 else
2490 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2491 for as_dir in $PATH
2492 do
2493   IFS=$as_save_IFS
2494   test -z "$as_dir" && as_dir=.
2495   for ac_exec_ext in '' $ac_executable_extensions; do
2496   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2497     ac_cv_prog_DTRACE="$ac_prog"
2498     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2499     break 2
2500   fi
2501 done
2502 done
2503 IFS=$as_save_IFS
2504
2505 fi
2506 fi
2507 DTRACE=$ac_cv_prog_DTRACE
2508 if test -n "$DTRACE"; then
2509   { echo "$as_me:$LINENO: result: $DTRACE" >&5
2510 echo "${ECHO_T}$DTRACE" >&6; }
2511 else
2512   { echo "$as_me:$LINENO: result: no" >&5
2513 echo "${ECHO_T}no" >&6; }
2514 fi
2515
2516
2517   test -n "$DTRACE" && break
2518 done
2519
2520 if test -z "$DTRACE"; then
2521   { { echo "$as_me:$LINENO: error: dtrace not found" >&5
2522 echo "$as_me: error: dtrace not found" >&2;}
2523    { (exit 1); exit 1; }; }
2524 fi
2525
2526       ;;
2527     no)
2528       :
2529       ;;
2530     *)
2531       { { echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2532 echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2533    { (exit 1); exit 1; }; }
2534       ;;
2535   esac
2536
2537 else
2538   enable_dtrace=no
2539
2540 fi
2541
2542
2543
2544
2545 #
2546 # Data file segmentation
2547 #
2548
2549 pgac_args="$pgac_args enable_segmented_files"
2550
2551 # Check whether --enable-segmented-files was given.
2552 if test "${enable_segmented_files+set}" = set; then
2553   enableval=$enable_segmented_files;
2554   case $enableval in
2555     yes)
2556       :
2557       ;;
2558     no)
2559       :
2560       ;;
2561     *)
2562       { { echo "$as_me:$LINENO: error: no argument expected for --enable-segmented-files option" >&5
2563 echo "$as_me: error: no argument expected for --enable-segmented-files option" >&2;}
2564    { (exit 1); exit 1; }; }
2565       ;;
2566   esac
2567
2568 else
2569   enable_segmented_files=yes
2570
2571 fi
2572
2573
2574
2575 #
2576 # C compiler
2577 #
2578
2579 # For historical reasons you can also use --with-CC to specify the C compiler
2580 # to use, although the standard way to do this is to set the CC environment
2581 # variable.
2582
2583 pgac_args="$pgac_args with_CC"
2584
2585
2586 # Check whether --with-CC was given.
2587 if test "${with_CC+set}" = set; then
2588   withval=$with_CC;
2589   case $withval in
2590     yes)
2591       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
2592 echo "$as_me: error: argument required for --with-CC option" >&2;}
2593    { (exit 1); exit 1; }; }
2594       ;;
2595     no)
2596       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
2597 echo "$as_me: error: argument required for --with-CC option" >&2;}
2598    { (exit 1); exit 1; }; }
2599       ;;
2600     *)
2601       CC=$with_CC
2602       ;;
2603   esac
2604
2605 fi
2606
2607
2608
2609 case $template in
2610   aix) pgac_cc_list="gcc xlc";;
2611  irix) pgac_cc_list="cc";; # no gcc
2612     *) pgac_cc_list="gcc cc";;
2613 esac
2614
2615 ac_ext=c
2616 ac_cpp='$CPP $CPPFLAGS'
2617 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2618 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2619 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2620 if test -n "$ac_tool_prefix"; then
2621   for ac_prog in $pgac_cc_list
2622   do
2623     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2624 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2625 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2626 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2627 if test "${ac_cv_prog_CC+set}" = set; then
2628   echo $ECHO_N "(cached) $ECHO_C" >&6
2629 else
2630   if test -n "$CC"; then
2631   ac_cv_prog_CC="$CC" # Let the user override the test.
2632 else
2633 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2634 for as_dir in $PATH
2635 do
2636   IFS=$as_save_IFS
2637   test -z "$as_dir" && as_dir=.
2638   for ac_exec_ext in '' $ac_executable_extensions; do
2639   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2640     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2641     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2642     break 2
2643   fi
2644 done
2645 done
2646 IFS=$as_save_IFS
2647
2648 fi
2649 fi
2650 CC=$ac_cv_prog_CC
2651 if test -n "$CC"; then
2652   { echo "$as_me:$LINENO: result: $CC" >&5
2653 echo "${ECHO_T}$CC" >&6; }
2654 else
2655   { echo "$as_me:$LINENO: result: no" >&5
2656 echo "${ECHO_T}no" >&6; }
2657 fi
2658
2659
2660     test -n "$CC" && break
2661   done
2662 fi
2663 if test -z "$CC"; then
2664   ac_ct_CC=$CC
2665   for ac_prog in $pgac_cc_list
2666 do
2667   # Extract the first word of "$ac_prog", so it can be a program name with args.
2668 set dummy $ac_prog; ac_word=$2
2669 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2670 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2671 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2672   echo $ECHO_N "(cached) $ECHO_C" >&6
2673 else
2674   if test -n "$ac_ct_CC"; then
2675   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2676 else
2677 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2678 for as_dir in $PATH
2679 do
2680   IFS=$as_save_IFS
2681   test -z "$as_dir" && as_dir=.
2682   for ac_exec_ext in '' $ac_executable_extensions; do
2683   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2684     ac_cv_prog_ac_ct_CC="$ac_prog"
2685     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2686     break 2
2687   fi
2688 done
2689 done
2690 IFS=$as_save_IFS
2691
2692 fi
2693 fi
2694 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2695 if test -n "$ac_ct_CC"; then
2696   { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2697 echo "${ECHO_T}$ac_ct_CC" >&6; }
2698 else
2699   { echo "$as_me:$LINENO: result: no" >&5
2700 echo "${ECHO_T}no" >&6; }
2701 fi
2702
2703
2704   test -n "$ac_ct_CC" && break
2705 done
2706
2707   if test "x$ac_ct_CC" = x; then
2708     CC=""
2709   else
2710     case $cross_compiling:$ac_tool_warned in
2711 yes:)
2712 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
2713 whose name does not start with the host triplet.  If you think this
2714 configuration is useful to you, please write to autoconf@gnu.org." >&5
2715 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
2716 whose name does not start with the host triplet.  If you think this
2717 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
2718 ac_tool_warned=yes ;;
2719 esac
2720     CC=$ac_ct_CC
2721   fi
2722 fi
2723
2724
2725 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2726 See \`config.log' for more details." >&5
2727 echo "$as_me: error: no acceptable C compiler found in \$PATH
2728 See \`config.log' for more details." >&2;}
2729    { (exit 1); exit 1; }; }
2730
2731 # Provide some information about the compiler.
2732 echo "$as_me:$LINENO: checking for C compiler version" >&5
2733 ac_compiler=`set X $ac_compile; echo $2`
2734 { (ac_try="$ac_compiler --version >&5"
2735 case "(($ac_try" in
2736   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2737   *) ac_try_echo=$ac_try;;
2738 esac
2739 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2740   (eval "$ac_compiler --version >&5") 2>&5
2741   ac_status=$?
2742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2743   (exit $ac_status); }
2744 { (ac_try="$ac_compiler -v >&5"
2745 case "(($ac_try" in
2746   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2747   *) ac_try_echo=$ac_try;;
2748 esac
2749 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2750   (eval "$ac_compiler -v >&5") 2>&5
2751   ac_status=$?
2752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2753   (exit $ac_status); }
2754 { (ac_try="$ac_compiler -V >&5"
2755 case "(($ac_try" in
2756   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2757   *) ac_try_echo=$ac_try;;
2758 esac
2759 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2760   (eval "$ac_compiler -V >&5") 2>&5
2761   ac_status=$?
2762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2763   (exit $ac_status); }
2764
2765 cat >conftest.$ac_ext <<_ACEOF
2766 /* confdefs.h.  */
2767 _ACEOF
2768 cat confdefs.h >>conftest.$ac_ext
2769 cat >>conftest.$ac_ext <<_ACEOF
2770 /* end confdefs.h.  */
2771
2772 int
2773 main ()
2774 {
2775
2776   ;
2777   return 0;
2778 }
2779 _ACEOF
2780 ac_clean_files_save=$ac_clean_files
2781 ac_clean_files="$ac_clean_files a.out a.exe b.out"
2782 # Try to create an executable without -o first, disregard a.out.
2783 # It will help us diagnose broken compilers, and finding out an intuition
2784 # of exeext.
2785 { echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2786 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
2787 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2788 #
2789 # List of possible output files, starting from the most likely.
2790 # The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
2791 # only as a last resort.  b.out is created by i960 compilers.
2792 ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
2793 #
2794 # The IRIX 6 linker writes into existing files which may not be
2795 # executable, retaining their permissions.  Remove them first so a
2796 # subsequent execution test works.
2797 ac_rmfiles=
2798 for ac_file in $ac_files
2799 do
2800   case $ac_file in
2801     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
2802     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2803   esac
2804 done
2805 rm -f $ac_rmfiles
2806
2807 if { (ac_try="$ac_link_default"
2808 case "(($ac_try" in
2809   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2810   *) ac_try_echo=$ac_try;;
2811 esac
2812 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2813   (eval "$ac_link_default") 2>&5
2814   ac_status=$?
2815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2816   (exit $ac_status); }; then
2817   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2818 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2819 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
2820 # so that the user can short-circuit this test for compilers unknown to
2821 # Autoconf.
2822 for ac_file in $ac_files ''
2823 do
2824   test -f "$ac_file" || continue
2825   case $ac_file in
2826     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
2827         ;;
2828     [ab].out )
2829         # We found the default executable, but exeext='' is most
2830         # certainly right.
2831         break;;
2832     *.* )
2833         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2834         then :; else
2835            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2836         fi
2837         # We set ac_cv_exeext here because the later test for it is not
2838         # safe: cross compilers may not add the suffix if given an `-o'
2839         # argument, so we may need to know it at that point already.
2840         # Even if this section looks crufty: it has the advantage of
2841         # actually working.
2842         break;;
2843     * )
2844         break;;
2845   esac
2846 done
2847 test "$ac_cv_exeext" = no && ac_cv_exeext=
2848
2849 else
2850   ac_file=''
2851 fi
2852
2853 { echo "$as_me:$LINENO: result: $ac_file" >&5
2854 echo "${ECHO_T}$ac_file" >&6; }
2855 if test -z "$ac_file"; then
2856   echo "$as_me: failed program was:" >&5
2857 sed 's/^/| /' conftest.$ac_ext >&5
2858
2859 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
2860 See \`config.log' for more details." >&5
2861 echo "$as_me: error: C compiler cannot create executables
2862 See \`config.log' for more details." >&2;}
2863    { (exit 77); exit 77; }; }
2864 fi
2865
2866 ac_exeext=$ac_cv_exeext
2867
2868 # Check that the compiler produces executables we can run.  If not, either
2869 # the compiler is broken, or we cross compile.
2870 { echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2871 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
2872 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2873 # If not cross compiling, check that we can run a simple program.
2874 if test "$cross_compiling" != yes; then
2875   if { ac_try='./$ac_file'
2876   { (case "(($ac_try" in
2877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2878   *) ac_try_echo=$ac_try;;
2879 esac
2880 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2881   (eval "$ac_try") 2>&5
2882   ac_status=$?
2883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2884   (exit $ac_status); }; }; then
2885     cross_compiling=no
2886   else
2887     if test "$cross_compiling" = maybe; then
2888         cross_compiling=yes
2889     else
2890         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2891 If you meant to cross compile, use \`--host'.
2892 See \`config.log' for more details." >&5
2893 echo "$as_me: error: cannot run C compiled programs.
2894 If you meant to cross compile, use \`--host'.
2895 See \`config.log' for more details." >&2;}
2896    { (exit 1); exit 1; }; }
2897     fi
2898   fi
2899 fi
2900 { echo "$as_me:$LINENO: result: yes" >&5
2901 echo "${ECHO_T}yes" >&6; }
2902
2903 rm -f a.out a.exe conftest$ac_cv_exeext b.out
2904 ac_clean_files=$ac_clean_files_save
2905 # Check that the compiler produces executables we can run.  If not, either
2906 # the compiler is broken, or we cross compile.
2907 { echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2908 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
2909 { echo "$as_me:$LINENO: result: $cross_compiling" >&5
2910 echo "${ECHO_T}$cross_compiling" >&6; }
2911
2912 { echo "$as_me:$LINENO: checking for suffix of executables" >&5
2913 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
2914 if { (ac_try="$ac_link"
2915 case "(($ac_try" in
2916   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2917   *) ac_try_echo=$ac_try;;
2918 esac
2919 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2920   (eval "$ac_link") 2>&5
2921   ac_status=$?
2922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2923   (exit $ac_status); }; then
2924   # If both `conftest.exe' and `conftest' are `present' (well, observable)
2925 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2926 # work properly (i.e., refer to `conftest.exe'), while it won't with
2927 # `rm'.
2928 for ac_file in conftest.exe conftest conftest.*; do
2929   test -f "$ac_file" || continue
2930   case $ac_file in
2931     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
2932     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2933           break;;
2934     * ) break;;
2935   esac
2936 done
2937 else
2938   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2939 See \`config.log' for more details." >&5
2940 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2941 See \`config.log' for more details." >&2;}
2942    { (exit 1); exit 1; }; }
2943 fi
2944
2945 rm -f conftest$ac_cv_exeext
2946 { echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2947 echo "${ECHO_T}$ac_cv_exeext" >&6; }
2948
2949 rm -f conftest.$ac_ext
2950 EXEEXT=$ac_cv_exeext
2951 ac_exeext=$EXEEXT
2952 { echo "$as_me:$LINENO: checking for suffix of object files" >&5
2953 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
2954 if test "${ac_cv_objext+set}" = set; then
2955   echo $ECHO_N "(cached) $ECHO_C" >&6
2956 else
2957   cat >conftest.$ac_ext <<_ACEOF
2958 /* confdefs.h.  */
2959 _ACEOF
2960 cat confdefs.h >>conftest.$ac_ext
2961 cat >>conftest.$ac_ext <<_ACEOF
2962 /* end confdefs.h.  */
2963
2964 int
2965 main ()
2966 {
2967
2968   ;
2969   return 0;
2970 }
2971 _ACEOF
2972 rm -f conftest.o conftest.obj
2973 if { (ac_try="$ac_compile"
2974 case "(($ac_try" in
2975   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2976   *) ac_try_echo=$ac_try;;
2977 esac
2978 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2979   (eval "$ac_compile") 2>&5
2980   ac_status=$?
2981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2982   (exit $ac_status); }; then
2983   for ac_file in conftest.o conftest.obj conftest.*; do
2984   test -f "$ac_file" || continue;
2985   case $ac_file in
2986     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
2987     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2988        break;;
2989   esac
2990 done
2991 else
2992   echo "$as_me: failed program was:" >&5
2993 sed 's/^/| /' conftest.$ac_ext >&5
2994
2995 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2996 See \`config.log' for more details." >&5
2997 echo "$as_me: error: cannot compute suffix of object files: cannot compile
2998 See \`config.log' for more details." >&2;}
2999    { (exit 1); exit 1; }; }
3000 fi
3001
3002 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3003 fi
3004 { echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3005 echo "${ECHO_T}$ac_cv_objext" >&6; }
3006 OBJEXT=$ac_cv_objext
3007 ac_objext=$OBJEXT
3008 { echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3009 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
3010 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3011   echo $ECHO_N "(cached) $ECHO_C" >&6
3012 else
3013   cat >conftest.$ac_ext <<_ACEOF
3014 /* confdefs.h.  */
3015 _ACEOF
3016 cat confdefs.h >>conftest.$ac_ext
3017 cat >>conftest.$ac_ext <<_ACEOF
3018 /* end confdefs.h.  */
3019
3020 int
3021 main ()
3022 {
3023 #ifndef __GNUC__
3024        choke me
3025 #endif
3026
3027   ;
3028   return 0;
3029 }
3030 _ACEOF
3031 rm -f conftest.$ac_objext
3032 if { (ac_try="$ac_compile"
3033 case "(($ac_try" in
3034   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3035   *) ac_try_echo=$ac_try;;
3036 esac
3037 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3038   (eval "$ac_compile") 2>conftest.er1
3039   ac_status=$?
3040   grep -v '^ *+' conftest.er1 >conftest.err
3041   rm -f conftest.er1
3042   cat conftest.err >&5
3043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3044   (exit $ac_status); } && {
3045          test -z "$ac_c_werror_flag" ||
3046          test ! -s conftest.err
3047        } && test -s conftest.$ac_objext; then
3048   ac_compiler_gnu=yes
3049 else
3050   echo "$as_me: failed program was:" >&5
3051 sed 's/^/| /' conftest.$ac_ext >&5
3052
3053         ac_compiler_gnu=no
3054 fi
3055
3056 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3057 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3058
3059 fi
3060 { echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3061 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
3062 GCC=`test $ac_compiler_gnu = yes && echo yes`
3063 ac_test_CFLAGS=${CFLAGS+set}
3064 ac_save_CFLAGS=$CFLAGS
3065 { echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3066 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
3067 if test "${ac_cv_prog_cc_g+set}" = set; then
3068   echo $ECHO_N "(cached) $ECHO_C" >&6
3069 else
3070   ac_save_c_werror_flag=$ac_c_werror_flag
3071    ac_c_werror_flag=yes
3072    ac_cv_prog_cc_g=no
3073    CFLAGS="-g"
3074    cat >conftest.$ac_ext <<_ACEOF
3075 /* confdefs.h.  */
3076 _ACEOF
3077 cat confdefs.h >>conftest.$ac_ext
3078 cat >>conftest.$ac_ext <<_ACEOF
3079 /* end confdefs.h.  */
3080
3081 int
3082 main ()
3083 {
3084
3085   ;
3086   return 0;
3087 }
3088 _ACEOF
3089 rm -f conftest.$ac_objext
3090 if { (ac_try="$ac_compile"
3091 case "(($ac_try" in
3092   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3093   *) ac_try_echo=$ac_try;;
3094 esac
3095 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3096   (eval "$ac_compile") 2>conftest.er1
3097   ac_status=$?
3098   grep -v '^ *+' conftest.er1 >conftest.err
3099   rm -f conftest.er1
3100   cat conftest.err >&5
3101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3102   (exit $ac_status); } && {
3103          test -z "$ac_c_werror_flag" ||
3104          test ! -s conftest.err
3105        } && test -s conftest.$ac_objext; then
3106   ac_cv_prog_cc_g=yes
3107 else
3108   echo "$as_me: failed program was:" >&5
3109 sed 's/^/| /' conftest.$ac_ext >&5
3110
3111         CFLAGS=""
3112       cat >conftest.$ac_ext <<_ACEOF
3113 /* confdefs.h.  */
3114 _ACEOF
3115 cat confdefs.h >>conftest.$ac_ext
3116 cat >>conftest.$ac_ext <<_ACEOF
3117 /* end confdefs.h.  */
3118
3119 int
3120 main ()
3121 {
3122
3123   ;
3124   return 0;
3125 }
3126 _ACEOF
3127 rm -f conftest.$ac_objext
3128 if { (ac_try="$ac_compile"
3129 case "(($ac_try" in
3130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3131   *) ac_try_echo=$ac_try;;
3132 esac
3133 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3134   (eval "$ac_compile") 2>conftest.er1
3135   ac_status=$?
3136   grep -v '^ *+' conftest.er1 >conftest.err
3137   rm -f conftest.er1
3138   cat conftest.err >&5
3139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3140   (exit $ac_status); } && {
3141          test -z "$ac_c_werror_flag" ||
3142          test ! -s conftest.err
3143        } && test -s conftest.$ac_objext; then
3144   :
3145 else
3146   echo "$as_me: failed program was:" >&5
3147 sed 's/^/| /' conftest.$ac_ext >&5
3148
3149         ac_c_werror_flag=$ac_save_c_werror_flag
3150          CFLAGS="-g"
3151          cat >conftest.$ac_ext <<_ACEOF
3152 /* confdefs.h.  */
3153 _ACEOF
3154 cat confdefs.h >>conftest.$ac_ext
3155 cat >>conftest.$ac_ext <<_ACEOF
3156 /* end confdefs.h.  */
3157
3158 int
3159 main ()
3160 {
3161
3162   ;
3163   return 0;
3164 }
3165 _ACEOF
3166 rm -f conftest.$ac_objext
3167 if { (ac_try="$ac_compile"
3168 case "(($ac_try" in
3169   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3170   *) ac_try_echo=$ac_try;;
3171 esac
3172 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3173   (eval "$ac_compile") 2>conftest.er1
3174   ac_status=$?
3175   grep -v '^ *+' conftest.er1 >conftest.err
3176   rm -f conftest.er1
3177   cat conftest.err >&5
3178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3179   (exit $ac_status); } && {
3180          test -z "$ac_c_werror_flag" ||
3181          test ! -s conftest.err
3182        } && test -s conftest.$ac_objext; then
3183   ac_cv_prog_cc_g=yes
3184 else
3185   echo "$as_me: failed program was:" >&5
3186 sed 's/^/| /' conftest.$ac_ext >&5
3187
3188
3189 fi
3190
3191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3192 fi
3193
3194 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3195 fi
3196
3197 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3198    ac_c_werror_flag=$ac_save_c_werror_flag
3199 fi
3200 { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3201 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
3202 if test "$ac_test_CFLAGS" = set; then
3203   CFLAGS=$ac_save_CFLAGS
3204 elif test $ac_cv_prog_cc_g = yes; then
3205   if test "$GCC" = yes; then
3206     CFLAGS="-g -O2"
3207   else
3208     CFLAGS="-g"
3209   fi
3210 else
3211   if test "$GCC" = yes; then
3212     CFLAGS="-O2"
3213   else
3214     CFLAGS=
3215   fi
3216 fi
3217 { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3218 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
3219 if test "${ac_cv_prog_cc_c89+set}" = set; then
3220   echo $ECHO_N "(cached) $ECHO_C" >&6
3221 else
3222   ac_cv_prog_cc_c89=no
3223 ac_save_CC=$CC
3224 cat >conftest.$ac_ext <<_ACEOF
3225 /* confdefs.h.  */
3226 _ACEOF
3227 cat confdefs.h >>conftest.$ac_ext
3228 cat >>conftest.$ac_ext <<_ACEOF
3229 /* end confdefs.h.  */
3230 #include <stdarg.h>
3231 #include <stdio.h>
3232 #include <sys/types.h>
3233 #include <sys/stat.h>
3234 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3235 struct buf { int x; };
3236 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3237 static char *e (p, i)
3238      char **p;
3239      int i;
3240 {
3241   return p[i];
3242 }
3243 static char *f (char * (*g) (char **, int), char **p, ...)
3244 {
3245   char *s;
3246   va_list v;
3247   va_start (v,p);
3248   s = g (p, va_arg (v,int));
3249   va_end (v);
3250   return s;
3251 }
3252
3253 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3254    function prototypes and stuff, but not '\xHH' hex character constants.
3255    These don't provoke an error unfortunately, instead are silently treated
3256    as 'x'.  The following induces an error, until -std is added to get
3257    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3258    array size at least.  It's necessary to write '\x00'==0 to get something
3259    that's true only with -std.  */
3260 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3261
3262 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3263    inside strings and character constants.  */
3264 #define FOO(x) 'x'
3265 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3266
3267 int test (int i, double x);
3268 struct s1 {int (*f) (int a);};
3269 struct s2 {int (*f) (double a);};
3270 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3271 int argc;
3272 char **argv;
3273 int
3274 main ()
3275 {
3276 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3277   ;
3278   return 0;
3279 }
3280 _ACEOF
3281 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3282         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3283 do
3284   CC="$ac_save_CC $ac_arg"
3285   rm -f conftest.$ac_objext
3286 if { (ac_try="$ac_compile"
3287 case "(($ac_try" in
3288   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3289   *) ac_try_echo=$ac_try;;
3290 esac
3291 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3292   (eval "$ac_compile") 2>conftest.er1
3293   ac_status=$?
3294   grep -v '^ *+' conftest.er1 >conftest.err
3295   rm -f conftest.er1
3296   cat conftest.err >&5
3297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3298   (exit $ac_status); } && {
3299          test -z "$ac_c_werror_flag" ||
3300          test ! -s conftest.err
3301        } && test -s conftest.$ac_objext; then
3302   ac_cv_prog_cc_c89=$ac_arg
3303 else
3304   echo "$as_me: failed program was:" >&5
3305 sed 's/^/| /' conftest.$ac_ext >&5
3306
3307
3308 fi
3309
3310 rm -f core conftest.err conftest.$ac_objext
3311   test "x$ac_cv_prog_cc_c89" != "xno" && break
3312 done
3313 rm -f conftest.$ac_ext
3314 CC=$ac_save_CC
3315
3316 fi
3317 # AC_CACHE_VAL
3318 case "x$ac_cv_prog_cc_c89" in
3319   x)
3320     { echo "$as_me:$LINENO: result: none needed" >&5
3321 echo "${ECHO_T}none needed" >&6; } ;;
3322   xno)
3323     { echo "$as_me:$LINENO: result: unsupported" >&5
3324 echo "${ECHO_T}unsupported" >&6; } ;;
3325   *)
3326     CC="$CC $ac_cv_prog_cc_c89"
3327     { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3328 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
3329 esac
3330
3331
3332 ac_ext=c
3333 ac_cpp='$CPP $CPPFLAGS'
3334 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3335 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3336 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3337
3338
3339 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3340 # but has idiosyncrasies of its own.  We assume icc will define
3341 # __INTEL_COMPILER regardless of CFLAGS.
3342
3343 cat >conftest.$ac_ext <<_ACEOF
3344 /* confdefs.h.  */
3345 _ACEOF
3346 cat confdefs.h >>conftest.$ac_ext
3347 cat >>conftest.$ac_ext <<_ACEOF
3348 /* end confdefs.h.  */
3349
3350 int
3351 main ()
3352 {
3353 #ifndef __INTEL_COMPILER
3354 choke me
3355 #endif
3356   ;
3357   return 0;
3358 }
3359 _ACEOF
3360 rm -f conftest.$ac_objext
3361 if { (ac_try="$ac_compile"
3362 case "(($ac_try" in
3363   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3364   *) ac_try_echo=$ac_try;;
3365 esac
3366 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3367   (eval "$ac_compile") 2>conftest.er1
3368   ac_status=$?
3369   grep -v '^ *+' conftest.er1 >conftest.err
3370   rm -f conftest.er1
3371   cat conftest.err >&5
3372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3373   (exit $ac_status); } && {
3374          test -z "$ac_c_werror_flag" ||
3375          test ! -s conftest.err
3376        } && test -s conftest.$ac_objext; then
3377   ICC=yes
3378 else
3379   echo "$as_me: failed program was:" >&5
3380 sed 's/^/| /' conftest.$ac_ext >&5
3381
3382         ICC=no
3383 fi
3384
3385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3386
3387 unset CFLAGS
3388
3389 #
3390 # Read the template
3391 #
3392 . "$srcdir/src/template/$template" || exit
3393
3394 # CFLAGS are selected so:
3395 # If the user specifies something in the environment, that is used.
3396 # else:  If the template file set something, that is used.
3397 # else:  If the compiler is GCC, then we use -O2.
3398 # else:  If the compiler is something else, then we use -0.
3399
3400 if test "$ac_env_CFLAGS_set" = set; then
3401   CFLAGS=$ac_env_CFLAGS_value
3402 elif test "${CFLAGS+set}" = set; then
3403   : # (keep what template set)
3404 elif test "$GCC" = yes; then
3405   CFLAGS="-O2"
3406 else
3407   # if the user selected debug mode, don't use -O
3408   if test "$enable_debug" != yes; then
3409     CFLAGS="-O"
3410   fi
3411 fi
3412
3413 # Some versions of GCC support some additional useful warning flags.
3414 # Check whether they are supported, and add them to CFLAGS if so.
3415 # ICC pretends to be GCC but it's lying; it doesn't support these options.
3416
3417 if test "$GCC" = yes -a "$ICC" = no; then
3418   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
3419   # These work in some but not all gcc versions
3420   { echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
3421 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6; }
3422 pgac_save_CFLAGS=$CFLAGS
3423 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
3424 cat >conftest.$ac_ext <<_ACEOF
3425 /* confdefs.h.  */
3426 _ACEOF
3427 cat confdefs.h >>conftest.$ac_ext
3428 cat >>conftest.$ac_ext <<_ACEOF
3429 /* end confdefs.h.  */
3430
3431 int
3432 main ()
3433 {
3434
3435   ;
3436   return 0;
3437 }
3438 _ACEOF
3439 rm -f conftest.$ac_objext
3440 if { (ac_try="$ac_compile"
3441 case "(($ac_try" in
3442   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3443   *) ac_try_echo=$ac_try;;
3444 esac
3445 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3446   (eval "$ac_compile") 2>conftest.er1
3447   ac_status=$?
3448   grep -v '^ *+' conftest.er1 >conftest.err
3449   rm -f conftest.er1
3450   cat conftest.err >&5
3451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3452   (exit $ac_status); } && {
3453          test -z "$ac_c_werror_flag" ||
3454          test ! -s conftest.err
3455        } && test -s conftest.$ac_objext; then
3456   { echo "$as_me:$LINENO: result: yes" >&5
3457 echo "${ECHO_T}yes" >&6; }
3458 else
3459   echo "$as_me: failed program was:" >&5
3460 sed 's/^/| /' conftest.$ac_ext >&5
3461
3462         CFLAGS="$pgac_save_CFLAGS"
3463                     { echo "$as_me:$LINENO: result: no" >&5
3464 echo "${ECHO_T}no" >&6; }
3465 fi
3466
3467 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3468
3469   { echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
3470 echo $ECHO_N "checking if $CC supports -Wendif-labels... $ECHO_C" >&6; }
3471 pgac_save_CFLAGS=$CFLAGS
3472 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
3473 cat >conftest.$ac_ext <<_ACEOF
3474 /* confdefs.h.  */
3475 _ACEOF
3476 cat confdefs.h >>conftest.$ac_ext
3477 cat >>conftest.$ac_ext <<_ACEOF
3478 /* end confdefs.h.  */
3479
3480 int
3481 main ()
3482 {
3483
3484   ;
3485   return 0;
3486 }
3487 _ACEOF
3488 rm -f conftest.$ac_objext
3489 if { (ac_try="$ac_compile"
3490 case "(($ac_try" in
3491   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3492   *) ac_try_echo=$ac_try;;
3493 esac
3494 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3495   (eval "$ac_compile") 2>conftest.er1
3496   ac_status=$?
3497   grep -v '^ *+' conftest.er1 >conftest.err
3498   rm -f conftest.er1
3499   cat conftest.err >&5
3500   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3501   (exit $ac_status); } && {
3502          test -z "$ac_c_werror_flag" ||
3503          test ! -s conftest.err
3504        } && test -s conftest.$ac_objext; then
3505   { echo "$as_me:$LINENO: result: yes" >&5
3506 echo "${ECHO_T}yes" >&6; }
3507 else
3508   echo "$as_me: failed program was:" >&5
3509 sed 's/^/| /' conftest.$ac_ext >&5
3510
3511         CFLAGS="$pgac_save_CFLAGS"
3512                     { echo "$as_me:$LINENO: result: no" >&5
3513 echo "${ECHO_T}no" >&6; }
3514 fi
3515
3516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3517
3518   # Disable strict-aliasing rules; needed for gcc 3.3+
3519   { echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
3520 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6; }
3521 pgac_save_CFLAGS=$CFLAGS
3522 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
3523 cat >conftest.$ac_ext <<_ACEOF
3524 /* confdefs.h.  */
3525 _ACEOF
3526 cat confdefs.h >>conftest.$ac_ext
3527 cat >>conftest.$ac_ext <<_ACEOF
3528 /* end confdefs.h.  */
3529
3530 int
3531 main ()
3532 {
3533
3534   ;
3535   return 0;
3536 }
3537 _ACEOF
3538 rm -f conftest.$ac_objext
3539 if { (ac_try="$ac_compile"
3540 case "(($ac_try" in
3541   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3542   *) ac_try_echo=$ac_try;;
3543 esac
3544 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3545   (eval "$ac_compile") 2>conftest.er1
3546   ac_status=$?
3547   grep -v '^ *+' conftest.er1 >conftest.err
3548   rm -f conftest.er1
3549   cat conftest.err >&5
3550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3551   (exit $ac_status); } && {
3552          test -z "$ac_c_werror_flag" ||
3553          test ! -s conftest.err
3554        } && test -s conftest.$ac_objext; then
3555   { echo "$as_me:$LINENO: result: yes" >&5
3556 echo "${ECHO_T}yes" >&6; }
3557 else
3558   echo "$as_me: failed program was:" >&5
3559 sed 's/^/| /' conftest.$ac_ext >&5
3560
3561         CFLAGS="$pgac_save_CFLAGS"
3562                     { echo "$as_me:$LINENO: result: no" >&5
3563 echo "${ECHO_T}no" >&6; }
3564 fi
3565
3566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3567
3568   # Disable optimizations that assume no overflow; needed for gcc 4.3+
3569   { echo "$as_me:$LINENO: checking if $CC supports -fwrapv" >&5
3570 echo $ECHO_N "checking if $CC supports -fwrapv... $ECHO_C" >&6; }
3571 pgac_save_CFLAGS=$CFLAGS
3572 CFLAGS="$pgac_save_CFLAGS -fwrapv"
3573 cat >conftest.$ac_ext <<_ACEOF
3574 /* confdefs.h.  */
3575 _ACEOF
3576 cat confdefs.h >>conftest.$ac_ext
3577 cat >>conftest.$ac_ext <<_ACEOF
3578 /* end confdefs.h.  */
3579
3580 int
3581 main ()
3582 {
3583
3584   ;
3585   return 0;
3586 }
3587 _ACEOF
3588 rm -f conftest.$ac_objext
3589 if { (ac_try="$ac_compile"
3590 case "(($ac_try" in
3591   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3592   *) ac_try_echo=$ac_try;;
3593 esac
3594 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3595   (eval "$ac_compile") 2>conftest.er1
3596   ac_status=$?
3597   grep -v '^ *+' conftest.er1 >conftest.err
3598   rm -f conftest.er1
3599   cat conftest.err >&5
3600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3601   (exit $ac_status); } && {
3602          test -z "$ac_c_werror_flag" ||
3603          test ! -s conftest.err
3604        } && test -s conftest.$ac_objext; then
3605   { echo "$as_me:$LINENO: result: yes" >&5
3606 echo "${ECHO_T}yes" >&6; }
3607 else
3608   echo "$as_me: failed program was:" >&5
3609 sed 's/^/| /' conftest.$ac_ext >&5
3610
3611         CFLAGS="$pgac_save_CFLAGS"
3612                     { echo "$as_me:$LINENO: result: no" >&5
3613 echo "${ECHO_T}no" >&6; }
3614 fi
3615
3616 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3617
3618 elif test "$ICC" = yes; then
3619   # Intel's compiler has a bug/misoptimization in checking for
3620   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
3621   { echo "$as_me:$LINENO: checking if $CC supports -mp1" >&5
3622 echo $ECHO_N "checking if $CC supports -mp1... $ECHO_C" >&6; }
3623 pgac_save_CFLAGS=$CFLAGS
3624 CFLAGS="$pgac_save_CFLAGS -mp1"
3625 cat >conftest.$ac_ext <<_ACEOF
3626 /* confdefs.h.  */
3627 _ACEOF
3628 cat confdefs.h >>conftest.$ac_ext
3629 cat >>conftest.$ac_ext <<_ACEOF
3630 /* end confdefs.h.  */
3631
3632 int
3633 main ()
3634 {
3635
3636   ;
3637   return 0;
3638 }
3639 _ACEOF
3640 rm -f conftest.$ac_objext
3641 if { (ac_try="$ac_compile"
3642 case "(($ac_try" in
3643   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3644   *) ac_try_echo=$ac_try;;
3645 esac
3646 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3647   (eval "$ac_compile") 2>conftest.er1
3648   ac_status=$?
3649   grep -v '^ *+' conftest.er1 >conftest.err
3650   rm -f conftest.er1
3651   cat conftest.err >&5
3652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3653   (exit $ac_status); } && {
3654          test -z "$ac_c_werror_flag" ||
3655          test ! -s conftest.err
3656        } && test -s conftest.$ac_objext; then
3657   { echo "$as_me:$LINENO: result: yes" >&5
3658 echo "${ECHO_T}yes" >&6; }
3659 else
3660   echo "$as_me: failed program was:" >&5
3661 sed 's/^/| /' conftest.$ac_ext >&5
3662
3663         CFLAGS="$pgac_save_CFLAGS"
3664                     { echo "$as_me:$LINENO: result: no" >&5
3665 echo "${ECHO_T}no" >&6; }
3666 fi
3667
3668 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3669
3670   # Make sure strict aliasing is off (though this is said to be the default)
3671   { echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
3672 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6; }
3673 pgac_save_CFLAGS=$CFLAGS
3674 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
3675 cat >conftest.$ac_ext <<_ACEOF
3676 /* confdefs.h.  */
3677 _ACEOF
3678 cat confdefs.h >>conftest.$ac_ext
3679 cat >>conftest.$ac_ext <<_ACEOF
3680 /* end confdefs.h.  */
3681
3682 int
3683 main ()
3684 {
3685
3686   ;
3687   return 0;
3688 }
3689 _ACEOF
3690 rm -f conftest.$ac_objext
3691 if { (ac_try="$ac_compile"
3692 case "(($ac_try" in
3693   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3694   *) ac_try_echo=$ac_try;;
3695 esac
3696 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3697   (eval "$ac_compile") 2>conftest.er1
3698   ac_status=$?
3699   grep -v '^ *+' conftest.er1 >conftest.err
3700   rm -f conftest.er1
3701   cat conftest.err >&5
3702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3703   (exit $ac_status); } && {
3704          test -z "$ac_c_werror_flag" ||
3705          test ! -s conftest.err
3706        } && test -s conftest.$ac_objext; then
3707   { echo "$as_me:$LINENO: result: yes" >&5
3708 echo "${ECHO_T}yes" >&6; }
3709 else
3710   echo "$as_me: failed program was:" >&5
3711 sed 's/^/| /' conftest.$ac_ext >&5
3712
3713         CFLAGS="$pgac_save_CFLAGS"
3714                     { echo "$as_me:$LINENO: result: no" >&5
3715 echo "${ECHO_T}no" >&6; }
3716 fi
3717
3718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3719
3720 elif test x"${CC}" = x"xlc"; then
3721   # AIX xlc has to have strict aliasing turned off too
3722   { echo "$as_me:$LINENO: checking if $CC supports -qnoansialias" >&5
3723 echo $ECHO_N "checking if $CC supports -qnoansialias... $ECHO_C" >&6; }
3724 pgac_save_CFLAGS=$CFLAGS
3725 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
3726 cat >conftest.$ac_ext <<_ACEOF
3727 /* confdefs.h.  */
3728 _ACEOF
3729 cat confdefs.h >>conftest.$ac_ext
3730 cat >>conftest.$ac_ext <<_ACEOF
3731 /* end confdefs.h.  */
3732
3733 int
3734 main ()
3735 {
3736
3737   ;
3738   return 0;
3739 }
3740 _ACEOF
3741 rm -f conftest.$ac_objext
3742 if { (ac_try="$ac_compile"
3743 case "(($ac_try" in
3744   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3745   *) ac_try_echo=$ac_try;;
3746 esac
3747 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3748   (eval "$ac_compile") 2>conftest.er1
3749   ac_status=$?
3750   grep -v '^ *+' conftest.er1 >conftest.err
3751   rm -f conftest.er1
3752   cat conftest.err >&5
3753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3754   (exit $ac_status); } && {
3755          test -z "$ac_c_werror_flag" ||
3756          test ! -s conftest.err
3757        } && test -s conftest.$ac_objext; then
3758   { echo "$as_me:$LINENO: result: yes" >&5
3759 echo "${ECHO_T}yes" >&6; }
3760 else
3761   echo "$as_me: failed program was:" >&5
3762 sed 's/^/| /' conftest.$ac_ext >&5
3763
3764         CFLAGS="$pgac_save_CFLAGS"
3765                     { echo "$as_me:$LINENO: result: no" >&5
3766 echo "${ECHO_T}no" >&6; }
3767 fi
3768
3769 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3770
3771 fi
3772
3773 # supply -g if --enable-debug
3774 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
3775   CFLAGS="$CFLAGS -g"
3776 fi
3777
3778 # enable profiling if --enable-profiling
3779 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
3780   if test "$GCC" = yes; then
3781
3782 cat >>confdefs.h <<\_ACEOF
3783 #define PROFILE_PID_DIR 1
3784 _ACEOF
3785
3786     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
3787   else
3788     { { echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
3789 echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
3790    { (exit 1); exit 1; }; }
3791   fi
3792 fi
3793
3794 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
3795 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
3796
3797 # We already have this in Makefile.win32, but configure needs it too
3798 if test "$PORTNAME" = "win32"; then
3799   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
3800 fi
3801
3802 # Check if the compiler still works with the template settings
3803 { echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
3804 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6; }
3805 cat >conftest.$ac_ext <<_ACEOF
3806 /* confdefs.h.  */
3807 _ACEOF
3808 cat confdefs.h >>conftest.$ac_ext
3809 cat >>conftest.$ac_ext <<_ACEOF
3810 /* end confdefs.h.  */
3811
3812 int
3813 main ()
3814 {
3815 return 0;
3816   ;
3817   return 0;
3818 }
3819 _ACEOF
3820 rm -f conftest.$ac_objext conftest$ac_exeext
3821 if { (ac_try="$ac_link"
3822 case "(($ac_try" in
3823   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3824   *) ac_try_echo=$ac_try;;
3825 esac
3826 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3827   (eval "$ac_link") 2>conftest.er1
3828   ac_status=$?
3829   grep -v '^ *+' conftest.er1 >conftest.err
3830   rm -f conftest.er1
3831   cat conftest.err >&5
3832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3833   (exit $ac_status); } && {
3834          test -z "$ac_c_werror_flag" ||
3835          test ! -s conftest.err
3836        } && test -s conftest$ac_exeext &&
3837        $as_test_x conftest$ac_exeext; then
3838   { echo "$as_me:$LINENO: result: yes" >&5
3839 echo "${ECHO_T}yes" >&6; }
3840 else
3841   echo "$as_me: failed program was:" >&5
3842 sed 's/^/| /' conftest.$ac_ext >&5
3843
3844         { echo "$as_me:$LINENO: result: no" >&5
3845 echo "${ECHO_T}no" >&6; }
3846    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
3847 echo "$as_me: error: cannot proceed" >&2;}
3848    { (exit 1); exit 1; }; }
3849 fi
3850
3851 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
3852       conftest$ac_exeext conftest.$ac_ext
3853
3854 # Defend against gcc -ffast-math
3855 if test "$GCC" = yes; then
3856 cat >conftest.$ac_ext <<_ACEOF
3857 /* confdefs.h.  */
3858 _ACEOF
3859 cat confdefs.h >>conftest.$ac_ext
3860 cat >>conftest.$ac_ext <<_ACEOF
3861 /* end confdefs.h.  */
3862
3863 int
3864 main ()
3865 {
3866 #ifdef __FAST_MATH__
3867 choke me
3868 #endif
3869   ;
3870   return 0;
3871 }
3872 _ACEOF
3873 rm -f conftest.$ac_objext
3874 if { (ac_try="$ac_compile"
3875 case "(($ac_try" in
3876   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3877   *) ac_try_echo=$ac_try;;
3878 esac
3879 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3880   (eval "$ac_compile") 2>conftest.er1
3881   ac_status=$?
3882   grep -v '^ *+' conftest.er1 >conftest.err
3883   rm -f conftest.er1
3884   cat conftest.err >&5
3885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3886   (exit $ac_status); } && {
3887          test -z "$ac_c_werror_flag" ||
3888          test ! -s conftest.err
3889        } && test -s conftest.$ac_objext; then
3890   :
3891 else
3892   echo "$as_me: failed program was:" >&5
3893 sed 's/^/| /' conftest.$ac_ext >&5
3894
3895         { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
3896 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
3897    { (exit 1); exit 1; }; }
3898 fi
3899
3900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3901 fi
3902
3903 ac_ext=c
3904 ac_cpp='$CPP $CPPFLAGS'
3905 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3906 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3907 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3908 { echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3909 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
3910 # On Suns, sometimes $CPP names a directory.
3911 if test -n "$CPP" && test -d "$CPP"; then
3912   CPP=
3913 fi
3914 if test -z "$CPP"; then
3915   if test "${ac_cv_prog_CPP+set}" = set; then
3916   echo $ECHO_N "(cached) $ECHO_C" >&6
3917 else
3918       # Double quotes because CPP needs to be expanded
3919     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3920     do
3921       ac_preproc_ok=false
3922 for ac_c_preproc_warn_flag in '' yes
3923 do
3924   # Use a header file that comes with gcc, so configuring glibc
3925   # with a fresh cross-compiler works.
3926   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3927   # <limits.h> exists even on freestanding compilers.
3928   # On the NeXT, cc -E runs the code through the compiler's parser,
3929   # not just through cpp. "Syntax error" is here to catch this case.
3930   cat >conftest.$ac_ext <<_ACEOF
3931 /* confdefs.h.  */
3932 _ACEOF
3933 cat confdefs.h >>conftest.$ac_ext
3934 cat >>conftest.$ac_ext <<_ACEOF
3935 /* end confdefs.h.  */
3936 #ifdef __STDC__
3937 # include <limits.h>
3938 #else
3939 # include <assert.h>
3940 #endif
3941                      Syntax error
3942 _ACEOF
3943 if { (ac_try="$ac_cpp conftest.$ac_ext"
3944 case "(($ac_try" in
3945   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3946   *) ac_try_echo=$ac_try;;
3947 esac
3948 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3949   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3950   ac_status=$?
3951   grep -v '^ *+' conftest.er1 >conftest.err
3952   rm -f conftest.er1
3953   cat conftest.err >&5
3954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3955   (exit $ac_status); } >/dev/null && {
3956          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3957          test ! -s conftest.err
3958        }; then
3959   :
3960 else
3961   echo "$as_me: failed program was:" >&5
3962 sed 's/^/| /' conftest.$ac_ext >&5
3963
3964   # Broken: fails on valid input.
3965 continue
3966 fi
3967
3968 rm -f conftest.err conftest.$ac_ext
3969
3970   # OK, works on sane cases.  Now check whether nonexistent headers
3971   # can be detected and how.
3972   cat >conftest.$ac_ext <<_ACEOF
3973 /* confdefs.h.  */
3974 _ACEOF
3975 cat confdefs.h >>conftest.$ac_ext
3976 cat >>conftest.$ac_ext <<_ACEOF
3977 /* end confdefs.h.  */
3978 #include <ac_nonexistent.h>
3979 _ACEOF
3980 if { (ac_try="$ac_cpp conftest.$ac_ext"
3981 case "(($ac_try" in
3982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3983   *) ac_try_echo=$ac_try;;
3984 esac
3985 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3986   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3987   ac_status=$?
3988   grep -v '^ *+' conftest.er1 >conftest.err
3989   rm -f conftest.er1
3990   cat conftest.err >&5
3991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3992   (exit $ac_status); } >/dev/null && {
3993          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3994          test ! -s conftest.err
3995        }; then
3996   # Broken: success on invalid input.
3997 continue
3998 else
3999   echo "$as_me: failed program was:" >&5
4000 sed 's/^/| /' conftest.$ac_ext >&5
4001
4002   # Passes both tests.
4003 ac_preproc_ok=:
4004 break
4005 fi
4006
4007 rm -f conftest.err conftest.$ac_ext
4008
4009 done
4010 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4011 rm -f conftest.err conftest.$ac_ext
4012 if $ac_preproc_ok; then
4013   break
4014 fi
4015
4016     done
4017     ac_cv_prog_CPP=$CPP
4018
4019 fi
4020   CPP=$ac_cv_prog_CPP
4021 else
4022   ac_cv_prog_CPP=$CPP
4023 fi
4024 { echo "$as_me:$LINENO: result: $CPP" >&5
4025 echo "${ECHO_T}$CPP" >&6; }
4026 ac_preproc_ok=false
4027 for ac_c_preproc_warn_flag in '' yes
4028 do
4029   # Use a header file that comes with gcc, so configuring glibc
4030   # with a fresh cross-compiler works.
4031   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4032   # <limits.h> exists even on freestanding compilers.
4033   # On the NeXT, cc -E runs the code through the compiler's parser,
4034   # not just through cpp. "Syntax error" is here to catch this case.
4035   cat >conftest.$ac_ext <<_ACEOF
4036 /* confdefs.h.  */
4037 _ACEOF
4038 cat confdefs.h >>conftest.$ac_ext
4039 cat >>conftest.$ac_ext <<_ACEOF
4040 /* end confdefs.h.  */
4041 #ifdef __STDC__
4042 # include <limits.h>
4043 #else
4044 # include <assert.h>
4045 #endif
4046                      Syntax error
4047 _ACEOF
4048 if { (ac_try="$ac_cpp conftest.$ac_ext"
4049 case "(($ac_try" in
4050   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4051   *) ac_try_echo=$ac_try;;
4052 esac
4053 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4054   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4055   ac_status=$?
4056   grep -v '^ *+' conftest.er1 >conftest.err
4057   rm -f conftest.er1
4058   cat conftest.err >&5
4059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4060   (exit $ac_status); } >/dev/null && {
4061          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4062          test ! -s conftest.err
4063        }; then
4064   :
4065 else
4066   echo "$as_me: failed program was:" >&5
4067 sed 's/^/| /' conftest.$ac_ext >&5
4068
4069   # Broken: fails on valid input.
4070 continue
4071 fi
4072
4073 rm -f conftest.err conftest.$ac_ext
4074
4075   # OK, works on sane cases.  Now check whether nonexistent headers
4076   # can be detected and how.
4077   cat >conftest.$ac_ext <<_ACEOF
4078 /* confdefs.h.  */
4079 _ACEOF
4080 cat confdefs.h >>conftest.$ac_ext
4081 cat >>conftest.$ac_ext <<_ACEOF
4082 /* end confdefs.h.  */
4083 #include <ac_nonexistent.h>
4084 _ACEOF
4085 if { (ac_try="$ac_cpp conftest.$ac_ext"
4086 case "(($ac_try" in
4087   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4088   *) ac_try_echo=$ac_try;;
4089 esac
4090 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4091   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4092   ac_status=$?
4093   grep -v '^ *+' conftest.er1 >conftest.err
4094   rm -f conftest.er1
4095   cat conftest.err >&5
4096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4097   (exit $ac_status); } >/dev/null && {
4098          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4099          test ! -s conftest.err
4100        }; then
4101   # Broken: success on invalid input.
4102 continue
4103 else
4104   echo "$as_me: failed program was:" >&5
4105 sed 's/^/| /' conftest.$ac_ext >&5
4106
4107   # Passes both tests.
4108 ac_preproc_ok=:
4109 break
4110 fi
4111
4112 rm -f conftest.err conftest.$ac_ext
4113
4114 done
4115 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4116 rm -f conftest.err conftest.$ac_ext
4117 if $ac_preproc_ok; then
4118   :
4119 else
4120   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4121 See \`config.log' for more details." >&5
4122 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4123 See \`config.log' for more details." >&2;}
4124    { (exit 1); exit 1; }; }
4125 fi
4126
4127 ac_ext=c
4128 ac_cpp='$CPP $CPPFLAGS'
4129 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4130 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4131 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4132
4133
4134
4135 # Create compiler version string
4136 if test x"$GCC" = x"yes" ; then
4137   cc_string="GCC `${CC} --version | sed q`"
4138 else
4139   cc_string=$CC
4140 fi
4141
4142 cat >>confdefs.h <<_ACEOF
4143 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
4144 _ACEOF
4145
4146
4147
4148 #
4149 # Set up TAS assembly code if needed; the template file has now had its
4150 # chance to request this.
4151 #
4152 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4153
4154
4155 if test "$need_tas" = yes ; then
4156   TAS=tas.o
4157 else
4158   TAS=""
4159 fi
4160
4161
4162
4163 #
4164 # Automatic dependency tracking
4165 #
4166
4167 pgac_args="$pgac_args enable_depend"
4168
4169 # Check whether --enable-depend was given.
4170 if test "${enable_depend+set}" = set; then
4171   enableval=$enable_depend;
4172   case $enableval in
4173     yes)
4174       autodepend=yes
4175       ;;
4176     no)
4177       :
4178       ;;
4179     *)
4180       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4181 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4182    { (exit 1); exit 1; }; }
4183       ;;
4184   esac
4185
4186 else
4187   enable_depend=no
4188
4189 fi
4190
4191
4192
4193
4194
4195 #
4196 # Enable assert checks
4197 #
4198
4199 pgac_args="$pgac_args enable_cassert"
4200
4201 # Check whether --enable-cassert was given.
4202 if test "${enable_cassert+set}" = set; then
4203   enableval=$enable_cassert;
4204   case $enableval in
4205     yes)
4206
4207 cat >>confdefs.h <<\_ACEOF
4208 #define USE_ASSERT_CHECKING 1
4209 _ACEOF
4210
4211       ;;
4212     no)
4213       :
4214       ;;
4215     *)
4216       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4217 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4218    { (exit 1); exit 1; }; }
4219       ;;
4220   esac
4221
4222 else
4223   enable_cassert=no
4224
4225 fi
4226
4227
4228
4229
4230 #
4231 # Include directories
4232 #
4233 ac_save_IFS=$IFS
4234 IFS="${IFS}${PATH_SEPARATOR}"
4235 # SRCH_INC comes from the template file
4236 for dir in $with_includes $SRCH_INC; do
4237   if test -d "$dir"; then
4238     INCLUDES="$INCLUDES -I$dir"
4239   else
4240     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4241 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4242   fi
4243 done
4244 IFS=$ac_save_IFS
4245
4246
4247
4248 #
4249 # Library directories
4250 #
4251 ac_save_IFS=$IFS
4252 IFS="${IFS}${PATH_SEPARATOR}"
4253 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4254 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4255   if test -d "$dir"; then
4256     LIBDIRS="$LIBDIRS -L$dir"
4257   else
4258     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4259 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4260   fi
4261 done
4262 IFS=$ac_save_IFS
4263
4264 #
4265 # Enable thread-safe client libraries
4266 #
4267 { echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4268 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6; }
4269 if test "$PORTNAME" != "win32"; then
4270
4271 pgac_args="$pgac_args enable_thread_safety"
4272
4273 # Check whether --enable-thread-safety was given.
4274 if test "${enable_thread_safety+set}" = set; then
4275   enableval=$enable_thread_safety;
4276   case $enableval in
4277     yes)
4278       :
4279       ;;
4280     no)
4281       :
4282       ;;
4283     *)
4284       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4285 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4286    { (exit 1); exit 1; }; }
4287       ;;
4288   esac
4289
4290 else
4291   enable_thread_safety=no
4292
4293 fi
4294
4295
4296 else
4297 # Win32 should always use threads
4298
4299 pgac_args="$pgac_args enable_thread_safety"
4300
4301 # Check whether --enable-thread-safety was given.
4302 if test "${enable_thread_safety+set}" = set; then
4303   enableval=$enable_thread_safety;
4304   case $enableval in
4305     yes)
4306       :
4307       ;;
4308     no)
4309       :
4310       ;;
4311     *)
4312       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4313 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4314    { (exit 1); exit 1; }; }
4315       ;;
4316   esac
4317
4318 else
4319   enable_thread_safety=yes
4320
4321 fi
4322
4323
4324 fi
4325
4326
4327 pgac_args="$pgac_args enable_thread_safety_force"
4328
4329 # Check whether --enable-thread-safety-force was given.
4330 if test "${enable_thread_safety_force+set}" = set; then
4331   enableval=$enable_thread_safety_force;
4332   case $enableval in
4333     yes)
4334       :
4335       ;;
4336     no)
4337       :
4338       ;;
4339     *)
4340       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety-force option" >&5
4341 echo "$as_me: error: no argument expected for --enable-thread-safety-force option" >&2;}
4342    { (exit 1); exit 1; }; }
4343       ;;
4344   esac
4345
4346 else
4347   enable_thread_safety_force=no
4348
4349 fi
4350
4351
4352 if test "$enable_thread_safety" = yes -o \
4353         "$enable_thread_safety_force" = yes; then
4354   enable_thread_safety="yes"    # for 'force'
4355
4356 cat >>confdefs.h <<\_ACEOF
4357 #define ENABLE_THREAD_SAFETY 1
4358 _ACEOF
4359
4360 fi
4361 { echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
4362 echo "${ECHO_T}$enable_thread_safety" >&6; }
4363
4364
4365 #
4366 # Optionally build Tcl modules (PL/Tcl)
4367 #
4368 { echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
4369 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6; }
4370
4371 pgac_args="$pgac_args with_tcl"
4372
4373
4374 # Check whether --with-tcl was given.
4375 if test "${with_tcl+set}" = set; then
4376   withval=$with_tcl;
4377   case $withval in
4378     yes)
4379       :
4380       ;;
4381     no)
4382       :
4383       ;;
4384     *)
4385       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
4386 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
4387    { (exit 1); exit 1; }; }
4388       ;;
4389   esac
4390
4391 else
4392   with_tcl=no
4393
4394 fi
4395
4396
4397 { echo "$as_me:$LINENO: result: $with_tcl" >&5
4398 echo "${ECHO_T}$with_tcl" >&6; }
4399
4400
4401 # We see if the path to the Tcl/Tk configuration scripts is specified.
4402 # This will override the use of tclsh to find the paths to search.
4403
4404
4405 pgac_args="$pgac_args with_tclconfig"
4406
4407
4408 # Check whether --with-tclconfig was given.
4409 if test "${with_tclconfig+set}" = set; then
4410   withval=$with_tclconfig;
4411   case $withval in
4412     yes)
4413       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4414 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4415    { (exit 1); exit 1; }; }
4416       ;;
4417     no)
4418       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4419 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4420    { (exit 1); exit 1; }; }
4421       ;;
4422     *)
4423
4424       ;;
4425   esac
4426
4427 fi
4428
4429
4430
4431 #
4432 # Optionally build Perl modules (PL/Perl)
4433 #
4434 { echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
4435 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6; }
4436
4437 pgac_args="$pgac_args with_perl"
4438
4439
4440 # Check whether --with-perl was given.
4441 if test "${with_perl+set}" = set; then
4442   withval=$with_perl;
4443   case $withval in
4444     yes)
4445       :
4446       ;;
4447     no)
4448       :
4449       ;;
4450     *)
4451       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
4452 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
4453    { (exit 1); exit 1; }; }
4454       ;;
4455   esac
4456
4457 else
4458   with_perl=no
4459
4460 fi
4461
4462
4463 { echo "$as_me:$LINENO: result: $with_perl" >&5
4464 echo "${ECHO_T}$with_perl" >&6; }
4465
4466
4467 #
4468 # Optionally build Python modules (PL/Python)
4469 #
4470 { echo "$as_me:$LINENO: checking whether to build Python modules" >&5
4471 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6; }
4472
4473 pgac_args="$pgac_args with_python"
4474
4475
4476 # Check whether --with-python was given.
4477 if test "${with_python+set}" = set; then
4478   withval=$with_python;
4479   case $withval in
4480     yes)
4481       :
4482       ;;
4483     no)
4484       :
4485       ;;
4486     *)
4487       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
4488 echo "$as_me: error: no argument expected for --with-python option" >&2;}
4489    { (exit 1); exit 1; }; }
4490       ;;
4491   esac
4492
4493 else
4494   with_python=no
4495
4496 fi
4497
4498
4499 { echo "$as_me:$LINENO: result: $with_python" >&5
4500 echo "${ECHO_T}$with_python" >&6; }
4501
4502
4503 #
4504 # GSSAPI
4505 #
4506 { echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
4507 echo $ECHO_N "checking whether to build with GSSAPI support... $ECHO_C" >&6; }
4508
4509 pgac_args="$pgac_args with_gssapi"
4510
4511
4512 # Check whether --with-gssapi was given.
4513 if test "${with_gssapi+set}" = set; then
4514   withval=$with_gssapi;
4515   case $withval in
4516     yes)
4517
4518
4519 cat >>confdefs.h <<\_ACEOF
4520 #define ENABLE_GSS 1
4521 _ACEOF
4522
4523   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
4524
4525       ;;
4526     no)
4527       :
4528       ;;
4529     *)
4530       { { echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
4531 echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
4532    { (exit 1); exit 1; }; }
4533       ;;
4534   esac
4535
4536 else
4537   with_gssapi=no
4538
4539 fi
4540
4541
4542 { echo "$as_me:$LINENO: result: $with_gssapi" >&5
4543 echo "${ECHO_T}$with_gssapi" >&6; }
4544
4545
4546 #
4547 # Kerberos 5
4548 #
4549 { echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
4550 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6; }
4551
4552 pgac_args="$pgac_args with_krb5"
4553
4554
4555 # Check whether --with-krb5 was given.
4556 if test "${with_krb5+set}" = set; then
4557   withval=$with_krb5;
4558   case $withval in
4559     yes)
4560
4561
4562 cat >>confdefs.h <<\_ACEOF
4563 #define KRB5 1
4564 _ACEOF
4565
4566   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
4567
4568       ;;
4569     no)
4570       :
4571       ;;
4572     *)
4573       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
4574 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
4575    { (exit 1); exit 1; }; }
4576       ;;
4577   esac
4578
4579 else
4580   with_krb5=no
4581
4582 fi
4583
4584
4585 { echo "$as_me:$LINENO: result: $with_krb5" >&5
4586 echo "${ECHO_T}$with_krb5" >&6; }
4587
4588
4589
4590
4591
4592
4593 #
4594 # Kerberos configuration parameters
4595 #
4596
4597 pgac_args="$pgac_args with_krb_srvnam"
4598
4599
4600 # Check whether --with-krb-srvnam was given.
4601 if test "${with_krb_srvnam+set}" = set; then
4602   withval=$with_krb_srvnam;
4603   case $withval in
4604     yes)
4605       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
4606 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
4607    { (exit 1); exit 1; }; }
4608       ;;
4609     no)
4610       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
4611 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
4612    { (exit 1); exit 1; }; }
4613       ;;
4614     *)
4615
4616       ;;
4617   esac
4618
4619 else
4620   with_krb_srvnam="postgres"
4621 fi
4622
4623
4624
4625 cat >>confdefs.h <<_ACEOF
4626 #define PG_KRB_SRVNAM "$with_krb_srvnam"
4627 _ACEOF
4628
4629
4630
4631 #
4632 # PAM
4633 #
4634 { echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
4635 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6; }
4636
4637 pgac_args="$pgac_args with_pam"
4638
4639
4640 # Check whether --with-pam was given.
4641 if test "${with_pam+set}" = set; then
4642   withval=$with_pam;
4643   case $withval in
4644     yes)
4645
4646 cat >>confdefs.h <<\_ACEOF
4647 #define USE_PAM 1
4648 _ACEOF
4649
4650       ;;
4651     no)
4652       :
4653       ;;
4654     *)
4655       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
4656 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
4657    { (exit 1); exit 1; }; }
4658       ;;
4659   esac
4660
4661 else
4662   with_pam=no
4663
4664 fi
4665
4666
4667 { echo "$as_me:$LINENO: result: $with_pam" >&5
4668 echo "${ECHO_T}$with_pam" >&6; }
4669
4670
4671
4672 #
4673 # LDAP
4674 #
4675 { echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
4676 echo $ECHO_N "checking whether to build with LDAP support... $ECHO_C" >&6; }
4677
4678 pgac_args="$pgac_args with_ldap"
4679
4680
4681 # Check whether --with-ldap was given.
4682 if test "${with_ldap+set}" = set; then
4683   withval=$with_ldap;
4684   case $withval in
4685     yes)
4686
4687 cat >>confdefs.h <<\_ACEOF
4688 #define USE_LDAP 1
4689 _ACEOF
4690
4691       ;;
4692     no)
4693       :
4694       ;;
4695     *)
4696       { { echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
4697 echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
4698    { (exit 1); exit 1; }; }
4699       ;;
4700   esac
4701
4702 else
4703   with_ldap=no
4704
4705 fi
4706
4707
4708 { echo "$as_me:$LINENO: result: $with_ldap" >&5
4709 echo "${ECHO_T}$with_ldap" >&6; }
4710
4711
4712
4713 #
4714 # Bonjour
4715 #
4716 { echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
4717 echo $ECHO_N "checking whether to build with Bonjour support... $ECHO_C" >&6; }
4718
4719 pgac_args="$pgac_args with_bonjour"
4720
4721
4722 # Check whether --with-bonjour was given.
4723 if test "${with_bonjour+set}" = set; then
4724   withval=$with_bonjour;
4725   case $withval in
4726     yes)
4727
4728 cat >>confdefs.h <<\_ACEOF
4729 #define USE_BONJOUR 1
4730 _ACEOF
4731
4732       ;;
4733     no)
4734       :
4735       ;;
4736     *)
4737       { { echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
4738 echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
4739    { (exit 1); exit 1; }; }
4740       ;;
4741   esac
4742
4743 else
4744   with_bonjour=no
4745
4746 fi
4747
4748
4749 { echo "$as_me:$LINENO: result: $with_bonjour" >&5
4750 echo "${ECHO_T}$with_bonjour" >&6; }
4751
4752
4753
4754 #
4755 # OpenSSL
4756 #
4757 { echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
4758 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6; }
4759
4760 pgac_args="$pgac_args with_openssl"
4761
4762
4763 # Check whether --with-openssl was given.
4764 if test "${with_openssl+set}" = set; then
4765   withval=$with_openssl;
4766   case $withval in
4767     yes)
4768
4769 cat >>confdefs.h <<\_ACEOF
4770 #define USE_SSL 1
4771 _ACEOF
4772
4773       ;;
4774     no)
4775       :
4776       ;;
4777     *)
4778       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
4779 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
4780    { (exit 1); exit 1; }; }
4781       ;;
4782   esac
4783
4784 else
4785   with_openssl=no
4786
4787 fi
4788
4789
4790 { echo "$as_me:$LINENO: result: $with_openssl" >&5
4791 echo "${ECHO_T}$with_openssl" >&6; }
4792
4793
4794
4795 #
4796 # Readline
4797 #
4798
4799 pgac_args="$pgac_args with_readline"
4800
4801
4802 # Check whether --with-readline was given.
4803 if test "${with_readline+set}" = set; then
4804   withval=$with_readline;
4805   case $withval in
4806     yes)
4807       :
4808       ;;
4809     no)
4810       :
4811       ;;
4812     *)
4813       { { echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
4814 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
4815    { (exit 1); exit 1; }; }
4816       ;;
4817   esac
4818
4819 else
4820   with_readline=yes
4821
4822 fi
4823
4824
4825 # readline on MinGW has problems with backslashes in psql and other bugs.
4826 # This is particularly a problem with non-US code pages.
4827 # Therefore disable its use until we understand the cause. 2004-07-20
4828 if test "$PORTNAME" = "win32"; then
4829   if test "$with_readline" = yes; then
4830     { echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
4831 echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
4832     with_readline=no
4833   fi
4834 fi
4835
4836
4837 #
4838 # Prefer libedit
4839 #
4840
4841 pgac_args="$pgac_args with_libedit_preferred"
4842
4843
4844 # Check whether --with-libedit-preferred was given.
4845 if test "${with_libedit_preferred+set}" = set; then
4846   withval=$with_libedit_preferred;
4847   case $withval in
4848     yes)
4849       :
4850       ;;
4851     no)
4852       :
4853       ;;
4854     *)
4855       { { echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
4856 echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
4857    { (exit 1); exit 1; }; }
4858       ;;
4859   esac
4860
4861 else
4862   with_libedit_preferred=no
4863
4864 fi
4865
4866
4867
4868
4869 #
4870 # OSSP UUID library
4871 #
4872
4873 pgac_args="$pgac_args with_ossp_uuid"
4874
4875
4876 # Check whether --with-ossp-uuid was given.
4877 if test "${with_ossp_uuid+set}" = set; then
4878   withval=$with_ossp_uuid;
4879   case $withval in
4880     yes)
4881       :
4882       ;;
4883     no)
4884       :
4885       ;;
4886     *)
4887       { { echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
4888 echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
4889    { (exit 1); exit 1; }; }
4890       ;;
4891   esac
4892
4893 else
4894   with_ossp_uuid=no
4895
4896 fi
4897
4898
4899
4900
4901
4902 #
4903 # XML
4904 #
4905
4906 pgac_args="$pgac_args with_libxml"
4907
4908
4909 # Check whether --with-libxml was given.
4910 if test "${with_libxml+set}" = set; then
4911   withval=$with_libxml;
4912   case $withval in
4913     yes)
4914
4915 cat >>confdefs.h <<\_ACEOF
4916 #define USE_LIBXML 1
4917 _ACEOF
4918
4919       ;;
4920     no)
4921       :
4922       ;;
4923     *)
4924       { { echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
4925 echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
4926    { (exit 1); exit 1; }; }
4927       ;;
4928   esac
4929
4930 else
4931   with_libxml=no
4932
4933 fi
4934
4935
4936
4937 if test "$with_libxml" = yes ; then
4938   for ac_prog in xml2-config
4939 do
4940   # Extract the first word of "$ac_prog", so it can be a program name with args.
4941 set dummy $ac_prog; ac_word=$2
4942 { echo "$as_me:$LINENO: checking for $ac_word" >&5
4943 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4944 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
4945   echo $ECHO_N "(cached) $ECHO_C" >&6
4946 else
4947   if test -n "$XML2_CONFIG"; then
4948   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
4949 else
4950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4951 for as_dir in $PATH
4952 do
4953   IFS=$as_save_IFS
4954   test -z "$as_dir" && as_dir=.
4955   for ac_exec_ext in '' $ac_executable_extensions; do
4956   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4957     ac_cv_prog_XML2_CONFIG="$ac_prog"
4958     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4959     break 2
4960   fi
4961 done
4962 done
4963 IFS=$as_save_IFS
4964
4965 fi
4966 fi
4967 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
4968 if test -n "$XML2_CONFIG"; then
4969   { echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
4970 echo "${ECHO_T}$XML2_CONFIG" >&6; }
4971 else
4972   { echo "$as_me:$LINENO: result: no" >&5
4973 echo "${ECHO_T}no" >&6; }
4974 fi
4975
4976
4977   test -n "$XML2_CONFIG" && break
4978 done
4979
4980   if test -n "$XML2_CONFIG"; then
4981     for pgac_option in `$XML2_CONFIG --cflags`; do
4982       case $pgac_option in
4983         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
4984       esac
4985     done
4986     for pgac_option in `$XML2_CONFIG --libs`; do
4987       case $pgac_option in
4988         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
4989       esac
4990     done
4991   fi
4992 fi
4993
4994
4995
4996 #
4997 # XSLT
4998 #
4999
5000 pgac_args="$pgac_args with_libxslt"
5001
5002
5003 # Check whether --with-libxslt was given.
5004 if test "${with_libxslt+set}" = set; then
5005   withval=$with_libxslt;
5006   case $withval in
5007     yes)
5008
5009 cat >>confdefs.h <<\_ACEOF
5010 #define USE_LIBXSLT 1
5011 _ACEOF
5012
5013       ;;
5014     no)
5015       :
5016       ;;
5017     *)
5018       { { echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5019 echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5020    { (exit 1); exit 1; }; }
5021       ;;
5022   esac
5023
5024 else
5025   with_libxslt=no
5026
5027 fi
5028
5029
5030
5031
5032
5033
5034 #
5035 # tzdata
5036 #
5037
5038 pgac_args="$pgac_args with_system_tzdata"
5039
5040
5041 # Check whether --with-system-tzdata was given.
5042 if test "${with_system_tzdata+set}" = set; then
5043   withval=$with_system_tzdata;
5044   case $withval in
5045     yes)
5046       { { echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5047 echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5048    { (exit 1); exit 1; }; }
5049       ;;
5050     no)
5051       { { echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5052 echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5053    { (exit 1); exit 1; }; }
5054       ;;
5055     *)
5056
5057       ;;
5058   esac
5059
5060 fi
5061
5062
5063
5064
5065 #
5066 # Zlib
5067 #
5068
5069 pgac_args="$pgac_args with_zlib"
5070
5071
5072 # Check whether --with-zlib was given.
5073 if test "${with_zlib+set}" = set; then
5074   withval=$with_zlib;
5075   case $withval in
5076     yes)
5077       :
5078       ;;
5079     no)
5080       :
5081       ;;
5082     *)
5083       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5084 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5085    { (exit 1); exit 1; }; }
5086       ;;
5087   esac
5088
5089 else
5090   with_zlib=yes
5091
5092 fi
5093
5094
5095
5096
5097 #
5098 # Elf
5099 #
5100
5101 # Assume system is ELF if it predefines __ELF__ as 1,
5102 # otherwise believe host_os based default.
5103 case $host_os in
5104     freebsd1*|freebsd2*) elf=no;;
5105     freebsd3*|freebsd4*) elf=yes;;
5106 esac
5107
5108
5109 { echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5110 echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
5111 if test "${ac_cv_path_GREP+set}" = set; then
5112   echo $ECHO_N "(cached) $ECHO_C" >&6
5113 else
5114   # Extract the first word of "grep ggrep" to use in msg output
5115 if test -z "$GREP"; then
5116 set dummy grep ggrep; ac_prog_name=$2
5117 if test "${ac_cv_path_GREP+set}" = set; then
5118   echo $ECHO_N "(cached) $ECHO_C" >&6
5119 else
5120   ac_path_GREP_found=false
5121 # Loop through the user's path and test for each of PROGNAME-LIST
5122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5123 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5124 do
5125   IFS=$as_save_IFS
5126   test -z "$as_dir" && as_dir=.
5127   for ac_prog in grep ggrep; do
5128   for ac_exec_ext in '' $ac_executable_extensions; do
5129     ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5130     { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5131     # Check for GNU ac_path_GREP and select it if it is found.
5132   # Check for GNU $ac_path_GREP
5133 case `"$ac_path_GREP" --version 2>&1` in
5134 *GNU*)
5135   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5136 *)
5137   ac_count=0
5138   echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
5139   while :
5140   do
5141     cat "conftest.in" "conftest.in" >"conftest.tmp"
5142     mv "conftest.tmp" "conftest.in"
5143     cp "conftest.in" "conftest.nl"
5144     echo 'GREP' >> "conftest.nl"
5145     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5146     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5147     ac_count=`expr $ac_count + 1`
5148     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5149       # Best one so far, save it but keep looking for a better one
5150       ac_cv_path_GREP="$ac_path_GREP"
5151       ac_path_GREP_max=$ac_count
5152     fi
5153     # 10*(2^10) chars as input seems more than enough
5154     test $ac_count -gt 10 && break
5155   done
5156   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5157 esac
5158
5159
5160     $ac_path_GREP_found && break 3
5161   done
5162 done
5163
5164 done
5165 IFS=$as_save_IFS
5166
5167
5168 fi
5169
5170 GREP="$ac_cv_path_GREP"
5171 if test -z "$GREP"; then
5172   { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5173 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5174    { (exit 1); exit 1; }; }
5175 fi
5176
5177 else
5178   ac_cv_path_GREP=$GREP
5179 fi
5180
5181
5182 fi
5183 { echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5184 echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
5185  GREP="$ac_cv_path_GREP"
5186
5187
5188 { echo "$as_me:$LINENO: checking for egrep" >&5
5189 echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
5190 if test "${ac_cv_path_EGREP+set}" = set; then
5191   echo $ECHO_N "(cached) $ECHO_C" >&6
5192 else
5193   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5194    then ac_cv_path_EGREP="$GREP -E"
5195    else
5196      # Extract the first word of "egrep" to use in msg output
5197 if test -z "$EGREP"; then
5198 set dummy egrep; ac_prog_name=$2
5199 if test "${ac_cv_path_EGREP+set}" = set; then
5200   echo $ECHO_N "(cached) $ECHO_C" >&6
5201 else
5202   ac_path_EGREP_found=false
5203 # Loop through the user's path and test for each of PROGNAME-LIST
5204 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5205 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5206 do
5207   IFS=$as_save_IFS
5208   test -z "$as_dir" && as_dir=.
5209   for ac_prog in egrep; do
5210   for ac_exec_ext in '' $ac_executable_extensions; do
5211     ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5212     { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5213     # Check for GNU ac_path_EGREP and select it if it is found.
5214   # Check for GNU $ac_path_EGREP
5215 case `"$ac_path_EGREP" --version 2>&1` in
5216 *GNU*)
5217   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5218 *)
5219   ac_count=0
5220   echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
5221   while :
5222   do
5223     cat "conftest.in" "conftest.in" >"conftest.tmp"
5224     mv "conftest.tmp" "conftest.in"
5225     cp "conftest.in" "conftest.nl"
5226     echo 'EGREP' >> "conftest.nl"
5227     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5228     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5229     ac_count=`expr $ac_count + 1`
5230     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5231       # Best one so far, save it but keep looking for a better one
5232       ac_cv_path_EGREP="$ac_path_EGREP"
5233       ac_path_EGREP_max=$ac_count
5234     fi
5235     # 10*(2^10) chars as input seems more than enough
5236     test $ac_count -gt 10 && break
5237   done
5238   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5239 esac
5240
5241
5242     $ac_path_EGREP_found && break 3
5243   done
5244 done
5245
5246 done
5247 IFS=$as_save_IFS
5248
5249
5250 fi
5251
5252 EGREP="$ac_cv_path_EGREP"
5253 if test -z "$EGREP"; then
5254   { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5255 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5256    { (exit 1); exit 1; }; }
5257 fi
5258
5259 else
5260   ac_cv_path_EGREP=$EGREP
5261 fi
5262
5263
5264    fi
5265 fi
5266 { echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5267 echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
5268  EGREP="$ac_cv_path_EGREP"
5269
5270
5271 cat >conftest.$ac_ext <<_ACEOF
5272 /* confdefs.h.  */
5273 _ACEOF
5274 cat confdefs.h >>conftest.$ac_ext
5275 cat >>conftest.$ac_ext <<_ACEOF
5276 /* end confdefs.h.  */
5277 #if __ELF__
5278   yes
5279 #endif
5280
5281 _ACEOF
5282 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5283   $EGREP "yes" >/dev/null 2>&1; then
5284   ELF_SYS=true
5285 else
5286   if test "X$elf" = "Xyes" ; then
5287   ELF_SYS=true
5288 else
5289   ELF_SYS=
5290 fi
5291 fi
5292 rm -f conftest*
5293
5294
5295
5296 #
5297 # Assignments
5298 #
5299
5300 CPPFLAGS="$CPPFLAGS $INCLUDES"
5301 LDFLAGS="$LDFLAGS $LIBDIRS"
5302
5303 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
5304 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
5305 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
5306 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
5307
5308
5309
5310
5311 # Check whether --with-gnu-ld was given.
5312 if test "${with_gnu_ld+set}" = set; then
5313   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5314 else
5315   with_gnu_ld=no
5316 fi
5317
5318 ac_prog=ld
5319 if test "$GCC" = yes; then
5320   # Check if gcc -print-prog-name=ld gives a path.
5321   { echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5322 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6; }
5323   case $host in
5324   *-*-mingw*)
5325     # gcc leaves a trailing carriage return which upsets mingw
5326     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5327   *)
5328     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5329   esac
5330   case "$ac_prog" in
5331     # Accept absolute paths.
5332     [\\/]* | [A-Za-z]:[\\/]*)
5333       re_direlt='/[^/][^/]*/\.\./'
5334       # Canonicalize the path of ld
5335       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5336       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5337         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5338       done
5339       test -z "$LD" && LD="$ac_prog"
5340       ;;
5341   "")
5342     # If it fails, then pretend we aren't using GCC.
5343     ac_prog=ld
5344     ;;
5345   *)
5346     # If it is relative, then search for the first ld in PATH.
5347     with_gnu_ld=unknown
5348     ;;
5349   esac
5350 elif test "$with_gnu_ld" = yes; then
5351   { echo "$as_me:$LINENO: checking for GNU ld" >&5
5352 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
5353 else
5354   { echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5355 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; }
5356 fi
5357 if test "${ac_cv_path_LD+set}" = set; then
5358   echo $ECHO_N "(cached) $ECHO_C" >&6
5359 else
5360   if test -z "$LD"; then
5361   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5362   for ac_dir in $PATH; do
5363     test -z "$ac_dir" && ac_dir=.
5364     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5365       ac_cv_path_LD="$ac_dir/$ac_prog"
5366       # Check to see if the program is GNU ld.  I'd rather use --version,
5367       # but apparently some GNU ld's only accept -v.
5368       # Break only if it was the GNU/non-GNU ld that we prefer.
5369       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
5370         test "$with_gnu_ld" != no && break
5371       else
5372         test "$with_gnu_ld" != yes && break
5373       fi
5374     fi
5375   done
5376   IFS="$ac_save_ifs"
5377 else
5378   ac_cv_path_LD="$LD" # Let the user override the test with a path.
5379 fi
5380 fi
5381
5382 LD="$ac_cv_path_LD"
5383 if test -n "$LD"; then
5384   { echo "$as_me:$LINENO: result: $LD" >&5
5385 echo "${ECHO_T}$LD" >&6; }
5386 else
5387   { echo "$as_me:$LINENO: result: no" >&5
5388 echo "${ECHO_T}no" >&6; }
5389 fi
5390 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5391 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5392    { (exit 1); exit 1; }; }
5393 { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5394 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; }
5395 if test "${ac_cv_prog_gnu_ld+set}" = set; then
5396   echo $ECHO_N "(cached) $ECHO_C" >&6
5397 else
5398   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
5399 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
5400   ac_cv_prog_gnu_ld=yes
5401 else
5402   ac_cv_prog_gnu_ld=no
5403 fi
5404 fi
5405 { echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
5406 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6; }
5407 with_gnu_ld=$ac_cv_prog_gnu_ld
5408
5409
5410
5411
5412 case $host_os in sysv5*)
5413   { echo "$as_me:$LINENO: checking whether ld -R works" >&5
5414 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6; }
5415 if test "${pgac_cv_prog_ld_R+set}" = set; then
5416   echo $ECHO_N "(cached) $ECHO_C" >&6
5417 else
5418
5419     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
5420     cat >conftest.$ac_ext <<_ACEOF
5421 /* confdefs.h.  */
5422 _ACEOF
5423 cat confdefs.h >>conftest.$ac_ext
5424 cat >>conftest.$ac_ext <<_ACEOF
5425 /* end confdefs.h.  */
5426
5427 int
5428 main ()
5429 {
5430
5431   ;
5432   return 0;
5433 }
5434 _ACEOF
5435 rm -f conftest.$ac_objext conftest$ac_exeext
5436 if { (ac_try="$ac_link"
5437 case "(($ac_try" in
5438   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5439   *) ac_try_echo=$ac_try;;
5440 esac
5441 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5442   (eval "$ac_link") 2>conftest.er1
5443   ac_status=$?
5444   grep -v '^ *+' conftest.er1 >conftest.err
5445   rm -f conftest.er1
5446   cat conftest.err >&5
5447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5448   (exit $ac_status); } && {
5449          test -z "$ac_c_werror_flag" ||
5450          test ! -s conftest.err
5451        } && test -s conftest$ac_exeext &&
5452        $as_test_x conftest$ac_exeext; then
5453   pgac_cv_prog_ld_R=yes
5454 else
5455   echo "$as_me: failed program was:" >&5
5456 sed 's/^/| /' conftest.$ac_ext >&5
5457
5458         pgac_cv_prog_ld_R=no
5459 fi
5460
5461 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5462       conftest$ac_exeext conftest.$ac_ext
5463     LDFLAGS=$pgac_save_LDFLAGS
5464
5465 fi
5466 { echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
5467 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6; }
5468   ld_R_works=$pgac_cv_prog_ld_R
5469
5470 esac
5471 if test -n "$ac_tool_prefix"; then
5472   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5473 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5474 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5475 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5476 if test "${ac_cv_prog_RANLIB+set}" = set; then
5477   echo $ECHO_N "(cached) $ECHO_C" >&6
5478 else
5479   if test -n "$RANLIB"; then
5480   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5481 else
5482 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5483 for as_dir in $PATH
5484 do
5485   IFS=$as_save_IFS
5486   test -z "$as_dir" && as_dir=.
5487   for ac_exec_ext in '' $ac_executable_extensions; do
5488   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5489     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5490     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5491     break 2
5492   fi
5493 done
5494 done
5495 IFS=$as_save_IFS
5496
5497 fi
5498 fi
5499 RANLIB=$ac_cv_prog_RANLIB
5500 if test -n "$RANLIB"; then
5501   { echo "$as_me:$LINENO: result: $RANLIB" >&5
5502 echo "${ECHO_T}$RANLIB" >&6; }
5503 else
5504   { echo "$as_me:$LINENO: result: no" >&5
5505 echo "${ECHO_T}no" >&6; }
5506 fi
5507
5508
5509 fi
5510 if test -z "$ac_cv_prog_RANLIB"; then
5511   ac_ct_RANLIB=$RANLIB
5512   # Extract the first word of "ranlib", so it can be a program name with args.
5513 set dummy ranlib; ac_word=$2
5514 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5515 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5516 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
5517   echo $ECHO_N "(cached) $ECHO_C" >&6
5518 else
5519   if test -n "$ac_ct_RANLIB"; then
5520   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5521 else
5522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5523 for as_dir in $PATH
5524 do
5525   IFS=$as_save_IFS
5526   test -z "$as_dir" && as_dir=.
5527   for ac_exec_ext in '' $ac_executable_extensions; do
5528   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5529     ac_cv_prog_ac_ct_RANLIB="ranlib"
5530     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5531     break 2
5532   fi
5533 done
5534 done
5535 IFS=$as_save_IFS
5536
5537 fi
5538 fi
5539 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5540 if test -n "$ac_ct_RANLIB"; then
5541   { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
5542 echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
5543 else
5544   { echo "$as_me:$LINENO: result: no" >&5
5545 echo "${ECHO_T}no" >&6; }
5546 fi
5547
5548   if test "x$ac_ct_RANLIB" = x; then
5549     RANLIB=":"
5550   else
5551     case $cross_compiling:$ac_tool_warned in
5552 yes:)
5553 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
5554 whose name does not start with the host triplet.  If you think this
5555 configuration is useful to you, please write to autoconf@gnu.org." >&5
5556 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
5557 whose name does not start with the host triplet.  If you think this
5558 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
5559 ac_tool_warned=yes ;;
5560 esac
5561     RANLIB=$ac_ct_RANLIB
5562   fi
5563 else
5564   RANLIB="$ac_cv_prog_RANLIB"
5565 fi
5566
5567
5568   if test -n "$ac_tool_prefix"; then
5569   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5570 set dummy ${ac_tool_prefix}strip; ac_word=$2
5571 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5572 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5573 if test "${ac_cv_prog_STRIP+set}" = set; then
5574   echo $ECHO_N "(cached) $ECHO_C" >&6
5575 else
5576   if test -n "$STRIP"; then
5577   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5578 else
5579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5580 for as_dir in $PATH
5581 do
5582   IFS=$as_save_IFS
5583   test -z "$as_dir" && as_dir=.
5584   for ac_exec_ext in '' $ac_executable_extensions; do
5585   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5586     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5587     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5588     break 2
5589   fi
5590 done
5591 done
5592 IFS=$as_save_IFS
5593
5594 fi
5595 fi
5596 STRIP=$ac_cv_prog_STRIP
5597 if test -n "$STRIP"; then
5598   { echo "$as_me:$LINENO: result: $STRIP" >&5
5599 echo "${ECHO_T}$STRIP" >&6; }
5600 else
5601   { echo "$as_me:$LINENO: result: no" >&5
5602 echo "${ECHO_T}no" >&6; }
5603 fi
5604
5605
5606 fi
5607 if test -z "$ac_cv_prog_STRIP"; then
5608   ac_ct_STRIP=$STRIP
5609   # Extract the first word of "strip", so it can be a program name with args.
5610 set dummy strip; ac_word=$2
5611 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5612 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5613 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
5614   echo $ECHO_N "(cached) $ECHO_C" >&6
5615 else
5616   if test -n "$ac_ct_STRIP"; then
5617   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5618 else
5619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5620 for as_dir in $PATH
5621 do
5622   IFS=$as_save_IFS
5623   test -z "$as_dir" && as_dir=.
5624   for ac_exec_ext in '' $ac_executable_extensions; do
5625   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5626     ac_cv_prog_ac_ct_STRIP="strip"
5627     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5628     break 2
5629   fi
5630 done
5631 done
5632 IFS=$as_save_IFS
5633
5634 fi
5635 fi
5636 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5637 if test -n "$ac_ct_STRIP"; then
5638   { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
5639 echo "${ECHO_T}$ac_ct_STRIP" >&6; }
5640 else
5641   { echo "$as_me:$LINENO: result: no" >&5
5642 echo "${ECHO_T}no" >&6; }
5643 fi
5644
5645   if test "x$ac_ct_STRIP" = x; then
5646     STRIP=":"
5647   else
5648     case $cross_compiling:$ac_tool_warned in
5649 yes:)
5650 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
5651 whose name does not start with the host triplet.  If you think this
5652 configuration is useful to you, please write to autoconf@gnu.org." >&5
5653 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
5654 whose name does not start with the host triplet.  If you think this
5655 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
5656 ac_tool_warned=yes ;;
5657 esac
5658     STRIP=$ac_ct_STRIP
5659   fi
5660 else
5661   STRIP="$ac_cv_prog_STRIP"
5662 fi
5663
5664
5665   { echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
5666 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6; }
5667   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
5668     STRIP_STATIC_LIB="$STRIP -x"
5669     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
5670     { echo "$as_me:$LINENO: result: yes" >&5
5671 echo "${ECHO_T}yes" >&6; }
5672   else
5673     STRIP_STATIC_LIB=:
5674     STRIP_SHARED_LIB=:
5675     { echo "$as_me:$LINENO: result: no" >&5
5676 echo "${ECHO_T}no" >&6; }
5677   fi
5678
5679
5680
5681
5682 # Extract the first word of "tar", so it can be a program name with args.
5683 set dummy tar; ac_word=$2
5684 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5685 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5686 if test "${ac_cv_path_TAR+set}" = set; then
5687   echo $ECHO_N "(cached) $ECHO_C" >&6
5688 else
5689   case $TAR in
5690   [\\/]* | ?:[\\/]*)
5691   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
5692   ;;
5693   *)
5694   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5695 for as_dir in $PATH
5696 do
5697   IFS=$as_save_IFS
5698   test -z "$as_dir" && as_dir=.
5699   for ac_exec_ext in '' $ac_executable_extensions; do
5700   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5701     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
5702     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5703     break 2
5704   fi
5705 done
5706 done
5707 IFS=$as_save_IFS
5708
5709   ;;
5710 esac
5711 fi
5712 TAR=$ac_cv_path_TAR
5713 if test -n "$TAR"; then
5714   { echo "$as_me:$LINENO: result: $TAR" >&5
5715 echo "${ECHO_T}$TAR" >&6; }
5716 else
5717   { echo "$as_me:$LINENO: result: no" >&5
5718 echo "${ECHO_T}no" >&6; }
5719 fi
5720
5721
5722 { echo "$as_me:$LINENO: checking whether ln -s works" >&5
5723 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
5724 LN_S=$as_ln_s
5725 if test "$LN_S" = "ln -s"; then
5726   { echo "$as_me:$LINENO: result: yes" >&5
5727 echo "${ECHO_T}yes" >&6; }
5728 else
5729   { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
5730 echo "${ECHO_T}no, using $LN_S" >&6; }
5731 fi
5732
5733 for ac_prog in gawk mawk nawk awk
5734 do
5735   # Extract the first word of "$ac_prog", so it can be a program name with args.
5736 set dummy $ac_prog; ac_word=$2
5737 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5738 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5739 if test "${ac_cv_prog_AWK+set}" = set; then
5740   echo $ECHO_N "(cached) $ECHO_C" >&6
5741 else
5742   if test -n "$AWK"; then
5743   ac_cv_prog_AWK="$AWK" # Let the user override the test.
5744 else
5745 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5746 for as_dir in $PATH
5747 do
5748   IFS=$as_save_IFS
5749   test -z "$as_dir" && as_dir=.
5750   for ac_exec_ext in '' $ac_executable_extensions; do
5751   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5752     ac_cv_prog_AWK="$ac_prog"
5753     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5754     break 2
5755   fi
5756 done
5757 done
5758 IFS=$as_save_IFS
5759
5760 fi
5761 fi
5762 AWK=$ac_cv_prog_AWK
5763 if test -n "$AWK"; then
5764   { echo "$as_me:$LINENO: result: $AWK" >&5
5765 echo "${ECHO_T}$AWK" >&6; }
5766 else
5767   { echo "$as_me:$LINENO: result: no" >&5
5768 echo "${ECHO_T}no" >&6; }
5769 fi
5770
5771
5772   test -n "$AWK" && break
5773 done
5774
5775
5776 # Let the user override the search
5777 if test -z "$YACC"; then
5778   for ac_prog in 'bison -y'
5779 do
5780   # Extract the first word of "$ac_prog", so it can be a program name with args.
5781 set dummy $ac_prog; ac_word=$2
5782 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5783 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5784 if test "${ac_cv_prog_YACC+set}" = set; then
5785   echo $ECHO_N "(cached) $ECHO_C" >&6
5786 else
5787   if test -n "$YACC"; then
5788   ac_cv_prog_YACC="$YACC" # Let the user override the test.
5789 else
5790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5791 for as_dir in $PATH
5792 do
5793   IFS=$as_save_IFS
5794   test -z "$as_dir" && as_dir=.
5795   for ac_exec_ext in '' $ac_executable_extensions; do
5796   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5797     ac_cv_prog_YACC="$ac_prog"
5798     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5799     break 2
5800   fi
5801 done
5802 done
5803 IFS=$as_save_IFS
5804
5805 fi
5806 fi
5807 YACC=$ac_cv_prog_YACC
5808 if test -n "$YACC"; then
5809   { echo "$as_me:$LINENO: result: $YACC" >&5
5810 echo "${ECHO_T}$YACC" >&6; }
5811 else
5812   { echo "$as_me:$LINENO: result: no" >&5
5813 echo "${ECHO_T}no" >&6; }
5814 fi
5815
5816
5817   test -n "$YACC" && break
5818 done
5819
5820 fi
5821
5822 if test "$YACC"; then
5823   pgac_yacc_version=`$YACC --version 2>/dev/null | sed q`
5824   { echo "$as_me:$LINENO: using $pgac_yacc_version" >&5
5825 echo "$as_me: using $pgac_yacc_version" >&6;}
5826   if echo "$pgac_yacc_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
5827   then
5828     { echo "$as_me:$LINENO: WARNING:
5829 *** The installed version of Bison is too old to use with PostgreSQL.
5830 *** Bison version 1.875 or later is required." >&5
5831 echo "$as_me: WARNING:
5832 *** The installed version of Bison is too old to use with PostgreSQL.
5833 *** Bison version 1.875 or later is required." >&2;}
5834     YACC=""
5835   fi
5836 fi
5837
5838 if test -z "$YACC"; then
5839   { echo "$as_me:$LINENO: WARNING:
5840 *** Without Bison you will not be able to build PostgreSQL from CVS nor
5841 *** change any of the parser definition files.  You can obtain Bison from
5842 *** a GNU mirror site.  (If you are using the official distribution of
5843 *** PostgreSQL then you do not need to worry about this, because the Bison
5844 *** output is pre-generated.)  To use a different yacc program (possible,
5845 *** but not recommended), set the environment variable YACC before running
5846 *** 'configure'." >&5
5847 echo "$as_me: WARNING:
5848 *** Without Bison you will not be able to build PostgreSQL from CVS nor
5849 *** change any of the parser definition files.  You can obtain Bison from
5850 *** a GNU mirror site.  (If you are using the official distribution of
5851 *** PostgreSQL then you do not need to worry about this, because the Bison
5852 *** output is pre-generated.)  To use a different yacc program (possible,
5853 *** but not recommended), set the environment variable YACC before running
5854 *** 'configure'." >&2;}
5855 fi
5856 # We don't need AC_SUBST(YACC) because AC_PATH_PROG did it
5857
5858
5859 { echo "$as_me:$LINENO: checking for flex" >&5
5860 echo $ECHO_N "checking for flex... $ECHO_C" >&6; }
5861 if test "${pgac_cv_path_flex+set}" = set; then
5862   echo $ECHO_N "(cached) $ECHO_C" >&6
5863 else
5864   # Let the user override the test
5865 if test -n "$FLEX"; then
5866   pgac_cv_path_flex=$FLEX
5867 else
5868   pgac_save_IFS=$IFS
5869   IFS=$PATH_SEPARATOR
5870   for pgac_dir in $PATH; do
5871     IFS=$pgac_save_IFS
5872     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
5873       pgac_dir=`pwd`
5874     fi
5875     for pgac_prog in flex lex; do
5876       pgac_candidate="$pgac_dir/$pgac_prog"
5877       if test -f "$pgac_candidate" \
5878         && $pgac_candidate --version </dev/null >/dev/null 2>&1
5879       then
5880         echo '%%'  > conftest.l
5881         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
5882           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
5883             pgac_broken_flex=$pgac_candidate
5884             continue
5885           fi
5886
5887           pgac_cv_path_flex=$pgac_candidate
5888           break 2
5889         fi
5890       fi
5891     done
5892   done
5893   rm -f conftest.l lex.yy.c
5894   : ${pgac_cv_path_flex=no}
5895 fi
5896
5897 fi
5898 { echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
5899 echo "${ECHO_T}$pgac_cv_path_flex" >&6; }
5900 if test x"$pgac_cv_path_flex" = x"no"; then
5901   if test -n "$pgac_broken_flex"; then
5902     { echo "$as_me:$LINENO: WARNING:
5903 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
5904 *** should get version 2.5.4 or later." >&5
5905 echo "$as_me: WARNING:
5906 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
5907 *** should get version 2.5.4 or later." >&2;}
5908   fi
5909
5910   { echo "$as_me:$LINENO: WARNING:
5911 *** Without Flex you will not be able to build PostgreSQL from CVS or
5912 *** change any of the scanner definition files.  You can obtain Flex from
5913 *** a GNU mirror site.  (If you are using the official distribution of
5914 *** PostgreSQL then you do not need to worry about this because the Flex
5915 *** output is pre-generated.)" >&5
5916 echo "$as_me: WARNING:
5917 *** Without Flex you will not be able to build PostgreSQL from CVS or
5918 *** change any of the scanner definition files.  You can obtain Flex from
5919 *** a GNU mirror site.  (If you are using the official distribution of
5920 *** PostgreSQL then you do not need to worry about this because the Flex
5921 *** output is pre-generated.)" >&2;}
5922
5923   FLEX=
5924 else
5925   FLEX=$pgac_cv_path_flex
5926   pgac_flex_version=`$FLEX -V 2>/dev/null`
5927   { echo "$as_me:$LINENO: using $pgac_flex_version" >&5
5928 echo "$as_me: using $pgac_flex_version" >&6;}
5929 fi
5930
5931
5932
5933
5934
5935 # Extract the first word of "perl", so it can be a program name with args.
5936 set dummy perl; ac_word=$2
5937 { echo "$as_me:$LINENO: checking for $ac_word" >&5
5938 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5939 if test "${ac_cv_path_PERL+set}" = set; then
5940   echo $ECHO_N "(cached) $ECHO_C" >&6
5941 else
5942   case $PERL in
5943   [\\/]* | ?:[\\/]*)
5944   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
5945   ;;
5946   *)
5947   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5948 for as_dir in $PATH
5949 do
5950   IFS=$as_save_IFS
5951   test -z "$as_dir" && as_dir=.
5952   for ac_exec_ext in '' $ac_executable_extensions; do
5953   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5954     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
5955     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5956     break 2
5957   fi
5958 done
5959 done
5960 IFS=$as_save_IFS
5961
5962   ;;
5963 esac
5964 fi
5965 PERL=$ac_cv_path_PERL
5966 if test -n "$PERL"; then
5967   { echo "$as_me:$LINENO: result: $PERL" >&5
5968 echo "${ECHO_T}$PERL" >&6; }
5969 else
5970   { echo "$as_me:$LINENO: result: no" >&5
5971 echo "${ECHO_T}no" >&6; }
5972 fi
5973
5974
5975 if test "$with_perl" = yes; then
5976
5977 { echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
5978 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6; }
5979 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
5980 { echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
5981 echo "${ECHO_T}$perl_archlibexp" >&6; }
5982 { echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
5983 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6; }
5984 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
5985 { echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
5986 echo "${ECHO_T}$perl_privlibexp" >&6; }
5987 { echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
5988 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6; }
5989 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
5990 { echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
5991 echo "${ECHO_T}$perl_useshrplib" >&6; }
5992
5993 { echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
5994 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6; }
5995 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
5996 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
5997 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
5998 { echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
5999 echo "${ECHO_T}$perl_embed_ldflags" >&6; }
6000 fi
6001
6002 if test "$with_python" = yes; then
6003   # Extract the first word of "python", so it can be a program name with args.
6004 set dummy python; ac_word=$2
6005 { echo "$as_me:$LINENO: checking for $ac_word" >&5
6006 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
6007 if test "${ac_cv_path_PYTHON+set}" = set; then
6008   echo $ECHO_N "(cached) $ECHO_C" >&6
6009 else
6010   case $PYTHON in
6011   [\\/]* | ?:[\\/]*)
6012   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
6013   ;;
6014   *)
6015   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6016 for as_dir in $PATH
6017 do
6018   IFS=$as_save_IFS
6019   test -z "$as_dir" && as_dir=.
6020   for ac_exec_ext in '' $ac_executable_extensions; do
6021   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6022     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
6023     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6024     break 2
6025   fi
6026 done
6027 done
6028 IFS=$as_save_IFS
6029
6030   ;;
6031 esac
6032 fi
6033 PYTHON=$ac_cv_path_PYTHON
6034 if test -n "$PYTHON"; then
6035   { echo "$as_me:$LINENO: result: $PYTHON" >&5
6036 echo "${ECHO_T}$PYTHON" >&6; }
6037 else
6038   { echo "$as_me:$LINENO: result: no" >&5
6039 echo "${ECHO_T}no" >&6; }
6040 fi
6041
6042
6043 if test x"$PYTHON" = x""; then
6044   { { echo "$as_me:$LINENO: error: Python not found" >&5
6045 echo "$as_me: error: Python not found" >&2;}
6046    { (exit 1); exit 1; }; }
6047 fi
6048
6049
6050 { echo "$as_me:$LINENO: checking for Python distutils module" >&5
6051 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6; }
6052 if "${PYTHON}" 2>&- -c 'import distutils'
6053 then
6054     { echo "$as_me:$LINENO: result: yes" >&5
6055 echo "${ECHO_T}yes" >&6; }
6056 else
6057     { echo "$as_me:$LINENO: result: no" >&5
6058 echo "${ECHO_T}no" >&6; }
6059     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
6060 echo "$as_me: error: distutils module not found" >&2;}
6061    { (exit 1); exit 1; }; }
6062 fi
6063 { echo "$as_me:$LINENO: checking Python configuration directory" >&5
6064 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6; }
6065 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
6066 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')"`
6067 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
6068
6069 # This should be enough of a message.
6070 { echo "$as_me:$LINENO: result: $python_configdir" >&5
6071 echo "${ECHO_T}$python_configdir" >&6; }
6072
6073
6074 { echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
6075 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6; }
6076
6077 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
6078 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
6079 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
6080 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
6081
6082 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
6083 then
6084         # New way: use the official shared library
6085         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
6086         python_libspec="-L${python_libdir} -l${ldlibrary}"
6087 else
6088         # Old way: use libpython from python_configdir
6089         python_libdir="${python_configdir}"
6090         python_libspec="-L${python_libdir} -lpython${python_version}"
6091 fi
6092
6093 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
6094
6095 { echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
6096 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6; }
6097
6098
6099 # threaded python is not supported on bsd's
6100 { echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
6101 echo $ECHO_N "checking whether Python is compiled with thread support... $ECHO_C" >&6; }
6102 pythreads=`${PYTHON} -c "import sys; print int('thread' in sys.builtin_module_names)"`
6103 if test "$pythreads" = "1"; then
6104   { echo "$as_me:$LINENO: result: yes" >&5
6105 echo "${ECHO_T}yes" >&6; }
6106   case $host_os in
6107   openbsd*|freebsd*)
6108     { { echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
6109 echo "$as_me: error: threaded Python not supported on this platform" >&2;}
6110    { (exit 1); exit 1; }; }
6111     ;;
6112   esac
6113 else
6114   { echo "$as_me:$LINENO: result: no" >&5
6115 echo "${ECHO_T}no" >&6; }
6116 fi
6117
6118
6119 fi
6120
6121 # Supply a numeric version string for use by 3rd party add-ons
6122 # awk -F is a regex on some platforms, and not on others, so make "." a tab
6123 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
6124 tr '.' '        ' |
6125 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
6126
6127 cat >>confdefs.h <<_ACEOF
6128 #define PG_VERSION_NUM $PG_VERSION_NUM
6129 _ACEOF
6130
6131
6132 ##
6133 ## Libraries
6134 ##
6135 ## Most libraries are included only if they demonstrably provide a function
6136 ## we need, but libm is an exception: always include it, because there are
6137 ## too many compilers that play cute optimization games that will break
6138 ## probes for standard functions such as pow().
6139 ##
6140
6141
6142 { echo "$as_me:$LINENO: checking for main in -lm" >&5
6143 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6; }
6144 if test "${ac_cv_lib_m_main+set}" = set; then
6145   echo $ECHO_N "(cached) $ECHO_C" >&6
6146 else
6147   ac_check_lib_save_LIBS=$LIBS
6148 LIBS="-lm  $LIBS"
6149 cat >conftest.$ac_ext <<_ACEOF
6150 /* confdefs.h.  */
6151 _ACEOF
6152 cat confdefs.h >>conftest.$ac_ext
6153 cat >>conftest.$ac_ext <<_ACEOF
6154 /* end confdefs.h.  */
6155
6156
6157 int
6158 main ()
6159 {
6160 return main ();
6161   ;
6162   return 0;
6163 }
6164 _ACEOF
6165 rm -f conftest.$ac_objext conftest$ac_exeext
6166 if { (ac_try="$ac_link"
6167 case "(($ac_try" in
6168   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6169   *) ac_try_echo=$ac_try;;
6170 esac
6171 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6172   (eval "$ac_link") 2>conftest.er1
6173   ac_status=$?
6174   grep -v '^ *+' conftest.er1 >conftest.err
6175   rm -f conftest.er1
6176   cat conftest.err >&5
6177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6178   (exit $ac_status); } && {
6179          test -z "$ac_c_werror_flag" ||
6180          test ! -s conftest.err
6181        } && test -s conftest$ac_exeext &&
6182        $as_test_x conftest$ac_exeext; then
6183   ac_cv_lib_m_main=yes
6184 else
6185   echo "$as_me: failed program was:" >&5
6186 sed 's/^/| /' conftest.$ac_ext >&5
6187
6188         ac_cv_lib_m_main=no
6189 fi
6190
6191 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6192       conftest$ac_exeext conftest.$ac_ext
6193 LIBS=$ac_check_lib_save_LIBS
6194 fi
6195 { echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
6196 echo "${ECHO_T}$ac_cv_lib_m_main" >&6; }
6197 if test $ac_cv_lib_m_main = yes; then
6198   cat >>confdefs.h <<_ACEOF
6199 #define HAVE_LIBM 1
6200 _ACEOF
6201
6202   LIBS="-lm $LIBS"
6203
6204 fi
6205
6206 { echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
6207 echo $ECHO_N "checking for library containing setproctitle... $ECHO_C" >&6; }
6208 if test "${ac_cv_search_setproctitle+set}" = set; then
6209   echo $ECHO_N "(cached) $ECHO_C" >&6
6210 else
6211   ac_func_search_save_LIBS=$LIBS
6212 cat >conftest.$ac_ext <<_ACEOF
6213 /* confdefs.h.  */
6214 _ACEOF
6215 cat confdefs.h >>conftest.$ac_ext
6216 cat >>conftest.$ac_ext <<_ACEOF
6217 /* end confdefs.h.  */
6218
6219 /* Override any GCC internal prototype to avoid an error.
6220    Use char because int might match the return type of a GCC
6221    builtin and then its argument prototype would still apply.  */
6222 #ifdef __cplusplus
6223 extern "C"
6224 #endif
6225 char setproctitle ();
6226 int
6227 main ()
6228 {
6229 return setproctitle ();
6230   ;
6231   return 0;
6232 }
6233 _ACEOF
6234 for ac_lib in '' util; do
6235   if test -z "$ac_lib"; then
6236     ac_res="none required"
6237   else
6238     ac_res=-l$ac_lib
6239     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6240   fi
6241   rm -f conftest.$ac_objext conftest$ac_exeext
6242 if { (ac_try="$ac_link"
6243 case "(($ac_try" in
6244   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6245   *) ac_try_echo=$ac_try;;
6246 esac
6247 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6248   (eval "$ac_link") 2>conftest.er1
6249   ac_status=$?
6250   grep -v '^ *+' conftest.er1 >conftest.err
6251   rm -f conftest.er1
6252   cat conftest.err >&5
6253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6254   (exit $ac_status); } && {
6255          test -z "$ac_c_werror_flag" ||
6256          test ! -s conftest.err
6257        } && test -s conftest$ac_exeext &&
6258        $as_test_x conftest$ac_exeext; then
6259   ac_cv_search_setproctitle=$ac_res
6260 else
6261   echo "$as_me: failed program was:" >&5
6262 sed 's/^/| /' conftest.$ac_ext >&5
6263
6264
6265 fi
6266
6267 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6268       conftest$ac_exeext
6269   if test "${ac_cv_search_setproctitle+set}" = set; then
6270   break
6271 fi
6272 done
6273 if test "${ac_cv_search_setproctitle+set}" = set; then
6274   :
6275 else
6276   ac_cv_search_setproctitle=no
6277 fi
6278 rm conftest.$ac_ext
6279 LIBS=$ac_func_search_save_LIBS
6280 fi
6281 { echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
6282 echo "${ECHO_T}$ac_cv_search_setproctitle" >&6; }
6283 ac_res=$ac_cv_search_setproctitle
6284 if test "$ac_res" != no; then
6285   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6286
6287 fi
6288
6289 { echo "$as_me:$LINENO: checking for library containing dlopen" >&5
6290 echo $ECHO_N "checking for library containing dlopen... $ECHO_C" >&6; }
6291 if test "${ac_cv_search_dlopen+set}" = set; then
6292   echo $ECHO_N "(cached) $ECHO_C" >&6
6293 else
6294   ac_func_search_save_LIBS=$LIBS
6295 cat >conftest.$ac_ext <<_ACEOF
6296 /* confdefs.h.  */
6297 _ACEOF
6298 cat confdefs.h >>conftest.$ac_ext
6299 cat >>conftest.$ac_ext <<_ACEOF
6300 /* end confdefs.h.  */
6301
6302 /* Override any GCC internal prototype to avoid an error.
6303    Use char because int might match the return type of a GCC
6304    builtin and then its argument prototype would still apply.  */
6305 #ifdef __cplusplus
6306 extern "C"
6307 #endif
6308 char dlopen ();
6309 int
6310 main ()
6311 {
6312 return dlopen ();
6313   ;
6314   return 0;
6315 }
6316 _ACEOF
6317 for ac_lib in '' dl; do
6318   if test -z "$ac_lib"; then
6319     ac_res="none required"
6320   else
6321     ac_res=-l$ac_lib
6322     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6323   fi
6324   rm -f conftest.$ac_objext conftest$ac_exeext
6325 if { (ac_try="$ac_link"
6326 case "(($ac_try" in
6327   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6328   *) ac_try_echo=$ac_try;;
6329 esac
6330 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6331   (eval "$ac_link") 2>conftest.er1
6332   ac_status=$?
6333   grep -v '^ *+' conftest.er1 >conftest.err
6334   rm -f conftest.er1
6335   cat conftest.err >&5
6336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6337   (exit $ac_status); } && {
6338          test -z "$ac_c_werror_flag" ||
6339          test ! -s conftest.err
6340        } && test -s conftest$ac_exeext &&
6341        $as_test_x conftest$ac_exeext; then
6342   ac_cv_search_dlopen=$ac_res
6343 else
6344   echo "$as_me: failed program was:" >&5
6345 sed 's/^/| /' conftest.$ac_ext >&5
6346
6347
6348 fi
6349
6350 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6351       conftest$ac_exeext
6352   if test "${ac_cv_search_dlopen+set}" = set; then
6353   break
6354 fi
6355 done
6356 if test "${ac_cv_search_dlopen+set}" = set; then
6357   :
6358 else
6359   ac_cv_search_dlopen=no
6360 fi
6361 rm conftest.$ac_ext
6362 LIBS=$ac_func_search_save_LIBS
6363 fi
6364 { echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
6365 echo "${ECHO_T}$ac_cv_search_dlopen" >&6; }
6366 ac_res=$ac_cv_search_dlopen
6367 if test "$ac_res" != no; then
6368   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6369
6370 fi
6371
6372 { echo "$as_me:$LINENO: checking for library containing socket" >&5
6373 echo $ECHO_N "checking for library containing socket... $ECHO_C" >&6; }
6374 if test "${ac_cv_search_socket+set}" = set; then
6375   echo $ECHO_N "(cached) $ECHO_C" >&6
6376 else
6377   ac_func_search_save_LIBS=$LIBS
6378 cat >conftest.$ac_ext <<_ACEOF
6379 /* confdefs.h.  */
6380 _ACEOF
6381 cat confdefs.h >>conftest.$ac_ext
6382 cat >>conftest.$ac_ext <<_ACEOF
6383 /* end confdefs.h.  */
6384
6385 /* Override any GCC internal prototype to avoid an error.
6386    Use char because int might match the return type of a GCC
6387    builtin and then its argument prototype would still apply.  */
6388 #ifdef __cplusplus
6389 extern "C"
6390 #endif
6391 char socket ();
6392 int
6393 main ()
6394 {
6395 return socket ();
6396   ;
6397   return 0;
6398 }
6399 _ACEOF
6400 for ac_lib in '' socket wsock32; do
6401   if test -z "$ac_lib"; then
6402     ac_res="none required"
6403   else
6404     ac_res=-l$ac_lib
6405     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6406   fi
6407   rm -f conftest.$ac_objext conftest$ac_exeext
6408 if { (ac_try="$ac_link"
6409 case "(($ac_try" in
6410   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6411   *) ac_try_echo=$ac_try;;
6412 esac
6413 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6414   (eval "$ac_link") 2>conftest.er1
6415   ac_status=$?
6416   grep -v '^ *+' conftest.er1 >conftest.err
6417   rm -f conftest.er1
6418   cat conftest.err >&5
6419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6420   (exit $ac_status); } && {
6421          test -z "$ac_c_werror_flag" ||
6422          test ! -s conftest.err
6423        } && test -s conftest$ac_exeext &&
6424        $as_test_x conftest$ac_exeext; then
6425   ac_cv_search_socket=$ac_res
6426 else
6427   echo "$as_me: failed program was:" >&5
6428 sed 's/^/| /' conftest.$ac_ext >&5
6429
6430
6431 fi
6432
6433 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6434       conftest$ac_exeext
6435   if test "${ac_cv_search_socket+set}" = set; then
6436   break
6437 fi
6438 done
6439 if test "${ac_cv_search_socket+set}" = set; then
6440   :
6441 else
6442   ac_cv_search_socket=no
6443 fi
6444 rm conftest.$ac_ext
6445 LIBS=$ac_func_search_save_LIBS
6446 fi
6447 { echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
6448 echo "${ECHO_T}$ac_cv_search_socket" >&6; }
6449 ac_res=$ac_cv_search_socket
6450 if test "$ac_res" != no; then
6451   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6452
6453 fi
6454
6455 { echo "$as_me:$LINENO: checking for library containing shl_load" >&5
6456 echo $ECHO_N "checking for library containing shl_load... $ECHO_C" >&6; }
6457 if test "${ac_cv_search_shl_load+set}" = set; then
6458   echo $ECHO_N "(cached) $ECHO_C" >&6
6459 else
6460   ac_func_search_save_LIBS=$LIBS
6461 cat >conftest.$ac_ext <<_ACEOF
6462 /* confdefs.h.  */
6463 _ACEOF
6464 cat confdefs.h >>conftest.$ac_ext
6465 cat >>conftest.$ac_ext <<_ACEOF
6466 /* end confdefs.h.  */
6467
6468 /* Override any GCC internal prototype to avoid an error.
6469    Use char because int might match the return type of a GCC
6470    builtin and then its argument prototype would still apply.  */
6471 #ifdef __cplusplus
6472 extern "C"
6473 #endif
6474 char shl_load ();
6475 int
6476 main ()
6477 {
6478 return shl_load ();
6479   ;
6480   return 0;
6481 }
6482 _ACEOF
6483 for ac_lib in '' dld; do
6484   if test -z "$ac_lib"; then
6485     ac_res="none required"
6486   else
6487     ac_res=-l$ac_lib
6488     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6489   fi
6490   rm -f conftest.$ac_objext conftest$ac_exeext
6491 if { (ac_try="$ac_link"
6492 case "(($ac_try" in
6493   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6494   *) ac_try_echo=$ac_try;;
6495 esac
6496 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6497   (eval "$ac_link") 2>conftest.er1
6498   ac_status=$?
6499   grep -v '^ *+' conftest.er1 >conftest.err
6500   rm -f conftest.er1
6501   cat conftest.err >&5
6502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6503   (exit $ac_status); } && {
6504          test -z "$ac_c_werror_flag" ||
6505          test ! -s conftest.err
6506        } && test -s conftest$ac_exeext &&
6507        $as_test_x conftest$ac_exeext; then
6508   ac_cv_search_shl_load=$ac_res
6509 else
6510   echo "$as_me: failed program was:" >&5
6511 sed 's/^/| /' conftest.$ac_ext >&5
6512
6513
6514 fi
6515
6516 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6517       conftest$ac_exeext
6518   if test "${ac_cv_search_shl_load+set}" = set; then
6519   break
6520 fi
6521 done
6522 if test "${ac_cv_search_shl_load+set}" = set; then
6523   :
6524 else
6525   ac_cv_search_shl_load=no
6526 fi
6527 rm conftest.$ac_ext
6528 LIBS=$ac_func_search_save_LIBS
6529 fi
6530 { echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
6531 echo "${ECHO_T}$ac_cv_search_shl_load" >&6; }
6532 ac_res=$ac_cv_search_shl_load
6533 if test "$ac_res" != no; then
6534   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6535
6536 fi
6537
6538 # We only use libld in port/dynloader/aix.c
6539 case $host_os in
6540      aix*)
6541         { echo "$as_me:$LINENO: checking for library containing ldopen" >&5
6542 echo $ECHO_N "checking for library containing ldopen... $ECHO_C" >&6; }
6543 if test "${ac_cv_search_ldopen+set}" = set; then
6544   echo $ECHO_N "(cached) $ECHO_C" >&6
6545 else
6546   ac_func_search_save_LIBS=$LIBS
6547 cat >conftest.$ac_ext <<_ACEOF
6548 /* confdefs.h.  */
6549 _ACEOF
6550 cat confdefs.h >>conftest.$ac_ext
6551 cat >>conftest.$ac_ext <<_ACEOF
6552 /* end confdefs.h.  */
6553
6554 /* Override any GCC internal prototype to avoid an error.
6555    Use char because int might match the return type of a GCC
6556    builtin and then its argument prototype would still apply.  */
6557 #ifdef __cplusplus
6558 extern "C"
6559 #endif
6560 char ldopen ();
6561 int
6562 main ()
6563 {
6564 return ldopen ();
6565   ;
6566   return 0;
6567 }
6568 _ACEOF
6569 for ac_lib in '' ld; do
6570   if test -z "$ac_lib"; then
6571     ac_res="none required"
6572   else
6573     ac_res=-l$ac_lib
6574     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6575   fi
6576   rm -f conftest.$ac_objext conftest$ac_exeext
6577 if { (ac_try="$ac_link"
6578 case "(($ac_try" in
6579   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6580   *) ac_try_echo=$ac_try;;
6581 esac
6582 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6583   (eval "$ac_link") 2>conftest.er1
6584   ac_status=$?
6585   grep -v '^ *+' conftest.er1 >conftest.err
6586   rm -f conftest.er1
6587   cat conftest.err >&5
6588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6589   (exit $ac_status); } && {
6590          test -z "$ac_c_werror_flag" ||
6591          test ! -s conftest.err
6592        } && test -s conftest$ac_exeext &&
6593        $as_test_x conftest$ac_exeext; then
6594   ac_cv_search_ldopen=$ac_res
6595 else
6596   echo "$as_me: failed program was:" >&5
6597 sed 's/^/| /' conftest.$ac_ext >&5
6598
6599
6600 fi
6601
6602 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6603       conftest$ac_exeext
6604   if test "${ac_cv_search_ldopen+set}" = set; then
6605   break
6606 fi
6607 done
6608 if test "${ac_cv_search_ldopen+set}" = set; then
6609   :
6610 else
6611   ac_cv_search_ldopen=no
6612 fi
6613 rm conftest.$ac_ext
6614 LIBS=$ac_func_search_save_LIBS
6615 fi
6616 { echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
6617 echo "${ECHO_T}$ac_cv_search_ldopen" >&6; }
6618 ac_res=$ac_cv_search_ldopen
6619 if test "$ac_res" != no; then
6620   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6621
6622 fi
6623
6624         ;;
6625 esac
6626 { echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
6627 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6; }
6628 if test "${ac_cv_search_getopt_long+set}" = set; then
6629   echo $ECHO_N "(cached) $ECHO_C" >&6
6630 else
6631   ac_func_search_save_LIBS=$LIBS
6632 cat >conftest.$ac_ext <<_ACEOF
6633 /* confdefs.h.  */
6634 _ACEOF
6635 cat confdefs.h >>conftest.$ac_ext
6636 cat >>conftest.$ac_ext <<_ACEOF
6637 /* end confdefs.h.  */
6638
6639 /* Override any GCC internal prototype to avoid an error.
6640    Use char because int might match the return type of a GCC
6641    builtin and then its argument prototype would still apply.  */
6642 #ifdef __cplusplus
6643 extern "C"
6644 #endif
6645 char getopt_long ();
6646 int
6647 main ()
6648 {
6649 return getopt_long ();
6650   ;
6651   return 0;
6652 }
6653 _ACEOF
6654 for ac_lib in '' getopt gnugetopt; do
6655   if test -z "$ac_lib"; then
6656     ac_res="none required"
6657   else
6658     ac_res=-l$ac_lib
6659     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6660   fi
6661   rm -f conftest.$ac_objext conftest$ac_exeext
6662 if { (ac_try="$ac_link"
6663 case "(($ac_try" in
6664   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6665   *) ac_try_echo=$ac_try;;
6666 esac
6667 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6668   (eval "$ac_link") 2>conftest.er1
6669   ac_status=$?
6670   grep -v '^ *+' conftest.er1 >conftest.err
6671   rm -f conftest.er1
6672   cat conftest.err >&5
6673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6674   (exit $ac_status); } && {
6675          test -z "$ac_c_werror_flag" ||
6676          test ! -s conftest.err
6677        } && test -s conftest$ac_exeext &&
6678        $as_test_x conftest$ac_exeext; then
6679   ac_cv_search_getopt_long=$ac_res
6680 else
6681   echo "$as_me: failed program was:" >&5
6682 sed 's/^/| /' conftest.$ac_ext >&5
6683
6684
6685 fi
6686
6687 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6688       conftest$ac_exeext
6689   if test "${ac_cv_search_getopt_long+set}" = set; then
6690   break
6691 fi
6692 done
6693 if test "${ac_cv_search_getopt_long+set}" = set; then
6694   :
6695 else
6696   ac_cv_search_getopt_long=no
6697 fi
6698 rm conftest.$ac_ext
6699 LIBS=$ac_func_search_save_LIBS
6700 fi
6701 { echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
6702 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6; }
6703 ac_res=$ac_cv_search_getopt_long
6704 if test "$ac_res" != no; then
6705   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6706
6707 fi
6708
6709 { echo "$as_me:$LINENO: checking for library containing crypt" >&5
6710 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6; }
6711 if test "${ac_cv_search_crypt+set}" = set; then
6712   echo $ECHO_N "(cached) $ECHO_C" >&6
6713 else
6714   ac_func_search_save_LIBS=$LIBS
6715 cat >conftest.$ac_ext <<_ACEOF
6716 /* confdefs.h.  */
6717 _ACEOF
6718 cat confdefs.h >>conftest.$ac_ext
6719 cat >>conftest.$ac_ext <<_ACEOF
6720 /* end confdefs.h.  */
6721
6722 /* Override any GCC internal prototype to avoid an error.
6723    Use char because int might match the return type of a GCC
6724    builtin and then its argument prototype would still apply.  */
6725 #ifdef __cplusplus
6726 extern "C"
6727 #endif
6728 char crypt ();
6729 int
6730 main ()
6731 {
6732 return crypt ();
6733   ;
6734   return 0;
6735 }
6736 _ACEOF
6737 for ac_lib in '' crypt; do
6738   if test -z "$ac_lib"; then
6739     ac_res="none required"
6740   else
6741     ac_res=-l$ac_lib
6742     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6743   fi
6744   rm -f conftest.$ac_objext conftest$ac_exeext
6745 if { (ac_try="$ac_link"
6746 case "(($ac_try" in
6747   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6748   *) ac_try_echo=$ac_try;;
6749 esac
6750 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6751   (eval "$ac_link") 2>conftest.er1
6752   ac_status=$?
6753   grep -v '^ *+' conftest.er1 >conftest.err
6754   rm -f conftest.er1
6755   cat conftest.err >&5
6756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6757   (exit $ac_status); } && {
6758          test -z "$ac_c_werror_flag" ||
6759          test ! -s conftest.err
6760        } && test -s conftest$ac_exeext &&
6761        $as_test_x conftest$ac_exeext; then
6762   ac_cv_search_crypt=$ac_res
6763 else
6764   echo "$as_me: failed program was:" >&5
6765 sed 's/^/| /' conftest.$ac_ext >&5
6766
6767
6768 fi
6769
6770 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6771       conftest$ac_exeext
6772   if test "${ac_cv_search_crypt+set}" = set; then
6773   break
6774 fi
6775 done
6776 if test "${ac_cv_search_crypt+set}" = set; then
6777   :
6778 else
6779   ac_cv_search_crypt=no
6780 fi
6781 rm conftest.$ac_ext
6782 LIBS=$ac_func_search_save_LIBS
6783 fi
6784 { echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
6785 echo "${ECHO_T}$ac_cv_search_crypt" >&6; }
6786 ac_res=$ac_cv_search_crypt
6787 if test "$ac_res" != no; then
6788   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6789
6790 fi
6791
6792 # Solaris:
6793 { echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
6794 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6; }
6795 if test "${ac_cv_search_fdatasync+set}" = set; then
6796   echo $ECHO_N "(cached) $ECHO_C" >&6
6797 else
6798   ac_func_search_save_LIBS=$LIBS
6799 cat >conftest.$ac_ext <<_ACEOF
6800 /* confdefs.h.  */
6801 _ACEOF
6802 cat confdefs.h >>conftest.$ac_ext
6803 cat >>conftest.$ac_ext <<_ACEOF
6804 /* end confdefs.h.  */
6805
6806 /* Override any GCC internal prototype to avoid an error.
6807    Use char because int might match the return type of a GCC
6808    builtin and then its argument prototype would still apply.  */
6809 #ifdef __cplusplus
6810 extern "C"
6811 #endif
6812 char fdatasync ();
6813 int
6814 main ()
6815 {
6816 return fdatasync ();
6817   ;
6818   return 0;
6819 }
6820 _ACEOF
6821 for ac_lib in '' rt posix4; do
6822   if test -z "$ac_lib"; then
6823     ac_res="none required"
6824   else
6825     ac_res=-l$ac_lib
6826     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6827   fi
6828   rm -f conftest.$ac_objext conftest$ac_exeext
6829 if { (ac_try="$ac_link"
6830 case "(($ac_try" in
6831   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6832   *) ac_try_echo=$ac_try;;
6833 esac
6834 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6835   (eval "$ac_link") 2>conftest.er1
6836   ac_status=$?
6837   grep -v '^ *+' conftest.er1 >conftest.err
6838   rm -f conftest.er1
6839   cat conftest.err >&5
6840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6841   (exit $ac_status); } && {
6842          test -z "$ac_c_werror_flag" ||
6843          test ! -s conftest.err
6844        } && test -s conftest$ac_exeext &&
6845        $as_test_x conftest$ac_exeext; then
6846   ac_cv_search_fdatasync=$ac_res
6847 else
6848   echo "$as_me: failed program was:" >&5
6849 sed 's/^/| /' conftest.$ac_ext >&5
6850
6851
6852 fi
6853
6854 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6855       conftest$ac_exeext
6856   if test "${ac_cv_search_fdatasync+set}" = set; then
6857   break
6858 fi
6859 done
6860 if test "${ac_cv_search_fdatasync+set}" = set; then
6861   :
6862 else
6863   ac_cv_search_fdatasync=no
6864 fi
6865 rm conftest.$ac_ext
6866 LIBS=$ac_func_search_save_LIBS
6867 fi
6868 { echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
6869 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6; }
6870 ac_res=$ac_cv_search_fdatasync
6871 if test "$ac_res" != no; then
6872   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6873
6874 fi
6875
6876 # Cygwin:
6877 { echo "$as_me:$LINENO: checking for library containing shmget" >&5
6878 echo $ECHO_N "checking for library containing shmget... $ECHO_C" >&6; }
6879 if test "${ac_cv_search_shmget+set}" = set; then
6880   echo $ECHO_N "(cached) $ECHO_C" >&6
6881 else
6882   ac_func_search_save_LIBS=$LIBS
6883 cat >conftest.$ac_ext <<_ACEOF
6884 /* confdefs.h.  */
6885 _ACEOF
6886 cat confdefs.h >>conftest.$ac_ext
6887 cat >>conftest.$ac_ext <<_ACEOF
6888 /* end confdefs.h.  */
6889
6890 /* Override any GCC internal prototype to avoid an error.
6891    Use char because int might match the return type of a GCC
6892    builtin and then its argument prototype would still apply.  */
6893 #ifdef __cplusplus
6894 extern "C"
6895 #endif
6896 char shmget ();
6897 int
6898 main ()
6899 {
6900 return shmget ();
6901   ;
6902   return 0;
6903 }
6904 _ACEOF
6905 for ac_lib in '' cygipc; do
6906   if test -z "$ac_lib"; then
6907     ac_res="none required"
6908   else
6909     ac_res=-l$ac_lib
6910     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6911   fi
6912   rm -f conftest.$ac_objext conftest$ac_exeext
6913 if { (ac_try="$ac_link"
6914 case "(($ac_try" in
6915   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6916   *) ac_try_echo=$ac_try;;
6917 esac
6918 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6919   (eval "$ac_link") 2>conftest.er1
6920   ac_status=$?
6921   grep -v '^ *+' conftest.er1 >conftest.err
6922   rm -f conftest.er1
6923   cat conftest.err >&5
6924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6925   (exit $ac_status); } && {
6926          test -z "$ac_c_werror_flag" ||
6927          test ! -s conftest.err
6928        } && test -s conftest$ac_exeext &&
6929        $as_test_x conftest$ac_exeext; then
6930   ac_cv_search_shmget=$ac_res
6931 else
6932   echo "$as_me: failed program was:" >&5
6933 sed 's/^/| /' conftest.$ac_ext >&5
6934
6935
6936 fi
6937
6938 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6939       conftest$ac_exeext
6940   if test "${ac_cv_search_shmget+set}" = set; then
6941   break
6942 fi
6943 done
6944 if test "${ac_cv_search_shmget+set}" = set; then
6945   :
6946 else
6947   ac_cv_search_shmget=no
6948 fi
6949 rm conftest.$ac_ext
6950 LIBS=$ac_func_search_save_LIBS
6951 fi
6952 { echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
6953 echo "${ECHO_T}$ac_cv_search_shmget" >&6; }
6954 ac_res=$ac_cv_search_shmget
6955 if test "$ac_res" != no; then
6956   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
6957
6958 fi
6959
6960
6961 if test "$with_readline" = yes; then
6962
6963
6964 if test "${pgac_cv_check_readline+set}" = set; then
6965   echo $ECHO_N "(cached) $ECHO_C" >&6
6966 else
6967   pgac_cv_check_readline=no
6968 pgac_save_LIBS=$LIBS
6969 if test x"$with_libedit_preferred" != x"yes"
6970 then    READLINE_ORDER="-lreadline -ledit"
6971 else    READLINE_ORDER="-ledit -lreadline"
6972 fi
6973 for pgac_rllib in $READLINE_ORDER ; do
6974   { echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
6975 echo $ECHO_N "checking for ${pgac_rllib}... $ECHO_C" >&6; }
6976   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
6977     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
6978     cat >conftest.$ac_ext <<_ACEOF
6979 /* confdefs.h.  */
6980 _ACEOF
6981 cat confdefs.h >>conftest.$ac_ext
6982 cat >>conftest.$ac_ext <<_ACEOF
6983 /* end confdefs.h.  */
6984
6985 /* Override any GCC internal prototype to avoid an error.
6986    Use char because int might match the return type of a GCC
6987    builtin and then its argument prototype would still apply.  */
6988 #ifdef __cplusplus
6989 extern "C"
6990 #endif
6991 char readline ();
6992 int
6993 main ()
6994 {
6995 return readline ();
6996   ;
6997   return 0;
6998 }
6999 _ACEOF
7000 rm -f conftest.$ac_objext conftest$ac_exeext
7001 if { (ac_try="$ac_link"
7002 case "(($ac_try" in
7003   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7004   *) ac_try_echo=$ac_try;;
7005 esac
7006 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7007   (eval "$ac_link") 2>conftest.er1
7008   ac_status=$?
7009   grep -v '^ *+' conftest.er1 >conftest.err
7010   rm -f conftest.er1
7011   cat conftest.err >&5
7012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7013   (exit $ac_status); } && {
7014          test -z "$ac_c_werror_flag" ||
7015          test ! -s conftest.err
7016        } && test -s conftest$ac_exeext &&
7017        $as_test_x conftest$ac_exeext; then
7018
7019       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
7020       # recognize dependent libraries; assume curses is needed if we didn't
7021       # find any dependency.
7022       case $host_os in
7023         netbsd* | openbsd* | irix*)
7024           if test x"$pgac_lib" = x"" ; then
7025             pgac_lib=" -lcurses"
7026           fi ;;
7027       esac
7028
7029       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
7030       break
7031
7032 else
7033   echo "$as_me: failed program was:" >&5
7034 sed 's/^/| /' conftest.$ac_ext >&5
7035
7036
7037 fi
7038
7039 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7040       conftest$ac_exeext conftest.$ac_ext
7041   done
7042   if test "$pgac_cv_check_readline" != no ; then
7043     { echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
7044 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6; }
7045     break
7046   else
7047     { echo "$as_me:$LINENO: result: no" >&5
7048 echo "${ECHO_T}no" >&6; }
7049   fi
7050 done
7051 LIBS=$pgac_save_LIBS
7052
7053 fi
7054
7055 if test "$pgac_cv_check_readline" != no ; then
7056   LIBS="$pgac_cv_check_readline $LIBS"
7057
7058 cat >>confdefs.h <<\_ACEOF
7059 #define HAVE_LIBREADLINE 1
7060 _ACEOF
7061
7062 fi
7063
7064
7065   if test x"$pgac_cv_check_readline" = x"no"; then
7066     { { echo "$as_me:$LINENO: error: readline library not found
7067 If you have readline already installed, see config.log for details on the
7068 failure.  It is possible the compiler isn't looking in the proper directory.
7069 Use --without-readline to disable readline support." >&5
7070 echo "$as_me: error: readline library not found
7071 If you have readline already installed, see config.log for details on the
7072 failure.  It is possible the compiler isn't looking in the proper directory.
7073 Use --without-readline to disable readline support." >&2;}
7074    { (exit 1); exit 1; }; }
7075   fi
7076 fi
7077
7078 if test "$with_zlib" = yes; then
7079
7080 { echo "$as_me:$LINENO: checking for inflate in -lz" >&5
7081 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6; }
7082 if test "${ac_cv_lib_z_inflate+set}" = set; then
7083   echo $ECHO_N "(cached) $ECHO_C" >&6
7084 else
7085   ac_check_lib_save_LIBS=$LIBS
7086 LIBS="-lz  $LIBS"
7087 cat >conftest.$ac_ext <<_ACEOF
7088 /* confdefs.h.  */
7089 _ACEOF
7090 cat confdefs.h >>conftest.$ac_ext
7091 cat >>conftest.$ac_ext <<_ACEOF
7092 /* end confdefs.h.  */
7093
7094 /* Override any GCC internal prototype to avoid an error.
7095    Use char because int might match the return type of a GCC
7096    builtin and then its argument prototype would still apply.  */
7097 #ifdef __cplusplus
7098 extern "C"
7099 #endif
7100 char inflate ();
7101 int
7102 main ()
7103 {
7104 return inflate ();
7105   ;
7106   return 0;
7107 }
7108 _ACEOF
7109 rm -f conftest.$ac_objext conftest$ac_exeext
7110 if { (ac_try="$ac_link"
7111 case "(($ac_try" in
7112   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7113   *) ac_try_echo=$ac_try;;
7114 esac
7115 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7116   (eval "$ac_link") 2>conftest.er1
7117   ac_status=$?
7118   grep -v '^ *+' conftest.er1 >conftest.err
7119   rm -f conftest.er1
7120   cat conftest.err >&5
7121   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7122   (exit $ac_status); } && {
7123          test -z "$ac_c_werror_flag" ||
7124          test ! -s conftest.err
7125        } && test -s conftest$ac_exeext &&
7126        $as_test_x conftest$ac_exeext; then
7127   ac_cv_lib_z_inflate=yes
7128 else
7129   echo "$as_me: failed program was:" >&5
7130 sed 's/^/| /' conftest.$ac_ext >&5
7131
7132         ac_cv_lib_z_inflate=no
7133 fi
7134
7135 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7136       conftest$ac_exeext conftest.$ac_ext
7137 LIBS=$ac_check_lib_save_LIBS
7138 fi
7139 { echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
7140 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6; }
7141 if test $ac_cv_lib_z_inflate = yes; then
7142   cat >>confdefs.h <<_ACEOF
7143 #define HAVE_LIBZ 1
7144 _ACEOF
7145
7146   LIBS="-lz $LIBS"
7147
7148 else
7149   { { echo "$as_me:$LINENO: error: zlib library not found
7150 If you have zlib already installed, see config.log for details on the
7151 failure.  It is possible the compiler isn't looking in the proper directory.
7152 Use --without-zlib to disable zlib support." >&5
7153 echo "$as_me: error: zlib library not found
7154 If you have zlib already installed, see config.log for details on the
7155 failure.  It is possible the compiler isn't looking in the proper directory.
7156 Use --without-zlib to disable zlib support." >&2;}
7157    { (exit 1); exit 1; }; }
7158 fi
7159
7160 fi
7161
7162 if test "$enable_spinlocks" = yes; then
7163
7164 cat >>confdefs.h <<\_ACEOF
7165 #define HAVE_SPINLOCKS 1
7166 _ACEOF
7167
7168 else
7169   { echo "$as_me:$LINENO: WARNING:
7170 *** Not using spinlocks will cause poor performance." >&5
7171 echo "$as_me: WARNING:
7172 *** Not using spinlocks will cause poor performance." >&2;}
7173 fi
7174
7175 if test "$with_gssapi" = yes ; then
7176   if test "$PORTNAME" != "win32"; then
7177     { echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
7178 echo $ECHO_N "checking for library containing gss_init_sec_context... $ECHO_C" >&6; }
7179 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
7180   echo $ECHO_N "(cached) $ECHO_C" >&6
7181 else
7182   ac_func_search_save_LIBS=$LIBS
7183 cat >conftest.$ac_ext <<_ACEOF
7184 /* confdefs.h.  */
7185 _ACEOF
7186 cat confdefs.h >>conftest.$ac_ext
7187 cat >>conftest.$ac_ext <<_ACEOF
7188 /* end confdefs.h.  */
7189
7190 /* Override any GCC internal prototype to avoid an error.
7191    Use char because int might match the return type of a GCC
7192    builtin and then its argument prototype would still apply.  */
7193 #ifdef __cplusplus
7194 extern "C"
7195 #endif
7196 char gss_init_sec_context ();
7197 int
7198 main ()
7199 {
7200 return gss_init_sec_context ();
7201   ;
7202   return 0;
7203 }
7204 _ACEOF
7205 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
7206   if test -z "$ac_lib"; then
7207     ac_res="none required"
7208   else
7209     ac_res=-l$ac_lib
7210     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7211   fi
7212   rm -f conftest.$ac_objext conftest$ac_exeext
7213 if { (ac_try="$ac_link"
7214 case "(($ac_try" in
7215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7216   *) ac_try_echo=$ac_try;;
7217 esac
7218 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7219   (eval "$ac_link") 2>conftest.er1
7220   ac_status=$?
7221   grep -v '^ *+' conftest.er1 >conftest.err
7222   rm -f conftest.er1
7223   cat conftest.err >&5
7224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7225   (exit $ac_status); } && {
7226          test -z "$ac_c_werror_flag" ||
7227          test ! -s conftest.err
7228        } && test -s conftest$ac_exeext &&
7229        $as_test_x conftest$ac_exeext; then
7230   ac_cv_search_gss_init_sec_context=$ac_res
7231 else
7232   echo "$as_me: failed program was:" >&5
7233 sed 's/^/| /' conftest.$ac_ext >&5
7234
7235
7236 fi
7237
7238 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7239       conftest$ac_exeext
7240   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
7241   break
7242 fi
7243 done
7244 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
7245   :
7246 else
7247   ac_cv_search_gss_init_sec_context=no
7248 fi
7249 rm conftest.$ac_ext
7250 LIBS=$ac_func_search_save_LIBS
7251 fi
7252 { echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
7253 echo "${ECHO_T}$ac_cv_search_gss_init_sec_context" >&6; }
7254 ac_res=$ac_cv_search_gss_init_sec_context
7255 if test "$ac_res" != no; then
7256   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7257
7258 else
7259   { { echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
7260 echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
7261    { (exit 1); exit 1; }; }
7262 fi
7263
7264   else
7265     LIBS="$LIBS -lgssapi32"
7266   fi
7267 fi
7268
7269 if test "$with_krb5" = yes ; then
7270   if test "$PORTNAME" != "win32"; then
7271      { echo "$as_me:$LINENO: checking for library containing com_err" >&5
7272 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6; }
7273 if test "${ac_cv_search_com_err+set}" = set; then
7274   echo $ECHO_N "(cached) $ECHO_C" >&6
7275 else
7276   ac_func_search_save_LIBS=$LIBS
7277 cat >conftest.$ac_ext <<_ACEOF
7278 /* confdefs.h.  */
7279 _ACEOF
7280 cat confdefs.h >>conftest.$ac_ext
7281 cat >>conftest.$ac_ext <<_ACEOF
7282 /* end confdefs.h.  */
7283
7284 /* Override any GCC internal prototype to avoid an error.
7285    Use char because int might match the return type of a GCC
7286    builtin and then its argument prototype would still apply.  */
7287 #ifdef __cplusplus
7288 extern "C"
7289 #endif
7290 char com_err ();
7291 int
7292 main ()
7293 {
7294 return com_err ();
7295   ;
7296   return 0;
7297 }
7298 _ACEOF
7299 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err; do
7300   if test -z "$ac_lib"; then
7301     ac_res="none required"
7302   else
7303     ac_res=-l$ac_lib
7304     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7305   fi
7306   rm -f conftest.$ac_objext conftest$ac_exeext
7307 if { (ac_try="$ac_link"
7308 case "(($ac_try" in
7309   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7310   *) ac_try_echo=$ac_try;;
7311 esac
7312 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7313   (eval "$ac_link") 2>conftest.er1
7314   ac_status=$?
7315   grep -v '^ *+' conftest.er1 >conftest.err
7316   rm -f conftest.er1
7317   cat conftest.err >&5
7318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7319   (exit $ac_status); } && {
7320          test -z "$ac_c_werror_flag" ||
7321          test ! -s conftest.err
7322        } && test -s conftest$ac_exeext &&
7323        $as_test_x conftest$ac_exeext; then
7324   ac_cv_search_com_err=$ac_res
7325 else
7326   echo "$as_me: failed program was:" >&5
7327 sed 's/^/| /' conftest.$ac_ext >&5
7328
7329
7330 fi
7331
7332 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7333       conftest$ac_exeext
7334   if test "${ac_cv_search_com_err+set}" = set; then
7335   break
7336 fi
7337 done
7338 if test "${ac_cv_search_com_err+set}" = set; then
7339   :
7340 else
7341   ac_cv_search_com_err=no
7342 fi
7343 rm conftest.$ac_ext
7344 LIBS=$ac_func_search_save_LIBS
7345 fi
7346 { echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
7347 echo "${ECHO_T}$ac_cv_search_com_err" >&6; }
7348 ac_res=$ac_cv_search_com_err
7349 if test "$ac_res" != no; then
7350   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7351
7352 else
7353   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
7354 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
7355    { (exit 1); exit 1; }; }
7356 fi
7357
7358      { echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
7359 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6; }
7360 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
7361   echo $ECHO_N "(cached) $ECHO_C" >&6
7362 else
7363   ac_func_search_save_LIBS=$LIBS
7364 cat >conftest.$ac_ext <<_ACEOF
7365 /* confdefs.h.  */
7366 _ACEOF
7367 cat confdefs.h >>conftest.$ac_ext
7368 cat >>conftest.$ac_ext <<_ACEOF
7369 /* end confdefs.h.  */
7370
7371 /* Override any GCC internal prototype to avoid an error.
7372    Use char because int might match the return type of a GCC
7373    builtin and then its argument prototype would still apply.  */
7374 #ifdef __cplusplus
7375 extern "C"
7376 #endif
7377 char krb5_sendauth ();
7378 int
7379 main ()
7380 {
7381 return krb5_sendauth ();
7382   ;
7383   return 0;
7384 }
7385 _ACEOF
7386 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
7387   if test -z "$ac_lib"; then
7388     ac_res="none required"
7389   else
7390     ac_res=-l$ac_lib
7391     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7392   fi
7393   rm -f conftest.$ac_objext conftest$ac_exeext
7394 if { (ac_try="$ac_link"
7395 case "(($ac_try" in
7396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7397   *) ac_try_echo=$ac_try;;
7398 esac
7399 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7400   (eval "$ac_link") 2>conftest.er1
7401   ac_status=$?
7402   grep -v '^ *+' conftest.er1 >conftest.err
7403   rm -f conftest.er1
7404   cat conftest.err >&5
7405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7406   (exit $ac_status); } && {
7407          test -z "$ac_c_werror_flag" ||
7408          test ! -s conftest.err
7409        } && test -s conftest$ac_exeext &&
7410        $as_test_x conftest$ac_exeext; then
7411   ac_cv_search_krb5_sendauth=$ac_res
7412 else
7413   echo "$as_me: failed program was:" >&5
7414 sed 's/^/| /' conftest.$ac_ext >&5
7415
7416
7417 fi
7418
7419 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7420       conftest$ac_exeext
7421   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
7422   break
7423 fi
7424 done
7425 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
7426   :
7427 else
7428   ac_cv_search_krb5_sendauth=no
7429 fi
7430 rm conftest.$ac_ext
7431 LIBS=$ac_func_search_save_LIBS
7432 fi
7433 { echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
7434 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6; }
7435 ac_res=$ac_cv_search_krb5_sendauth
7436 if test "$ac_res" != no; then
7437   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7438
7439 else
7440   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
7441 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
7442    { (exit 1); exit 1; }; }
7443 fi
7444
7445   else
7446      { echo "$as_me:$LINENO: checking for library containing com_err" >&5
7447 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6; }
7448 if test "${ac_cv_search_com_err+set}" = set; then
7449   echo $ECHO_N "(cached) $ECHO_C" >&6
7450 else
7451   ac_func_search_save_LIBS=$LIBS
7452 cat >conftest.$ac_ext <<_ACEOF
7453 /* confdefs.h.  */
7454 _ACEOF
7455 cat confdefs.h >>conftest.$ac_ext
7456 cat >>conftest.$ac_ext <<_ACEOF
7457 /* end confdefs.h.  */
7458
7459 /* Override any GCC internal prototype to avoid an error.
7460    Use char because int might match the return type of a GCC
7461    builtin and then its argument prototype would still apply.  */
7462 #ifdef __cplusplus
7463 extern "C"
7464 #endif
7465 char com_err ();
7466 int
7467 main ()
7468 {
7469 return com_err ();
7470   ;
7471   return 0;
7472 }
7473 _ACEOF
7474 for ac_lib in '' 'comerr32 -lkrb5_32'; do
7475   if test -z "$ac_lib"; then
7476     ac_res="none required"
7477   else
7478     ac_res=-l$ac_lib
7479     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7480   fi
7481   rm -f conftest.$ac_objext conftest$ac_exeext
7482 if { (ac_try="$ac_link"
7483 case "(($ac_try" in
7484   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7485   *) ac_try_echo=$ac_try;;
7486 esac
7487 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7488   (eval "$ac_link") 2>conftest.er1
7489   ac_status=$?
7490   grep -v '^ *+' conftest.er1 >conftest.err
7491   rm -f conftest.er1
7492   cat conftest.err >&5
7493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7494   (exit $ac_status); } && {
7495          test -z "$ac_c_werror_flag" ||
7496          test ! -s conftest.err
7497        } && test -s conftest$ac_exeext &&
7498        $as_test_x conftest$ac_exeext; then
7499   ac_cv_search_com_err=$ac_res
7500 else
7501   echo "$as_me: failed program was:" >&5
7502 sed 's/^/| /' conftest.$ac_ext >&5
7503
7504
7505 fi
7506
7507 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7508       conftest$ac_exeext
7509   if test "${ac_cv_search_com_err+set}" = set; then
7510   break
7511 fi
7512 done
7513 if test "${ac_cv_search_com_err+set}" = set; then
7514   :
7515 else
7516   ac_cv_search_com_err=no
7517 fi
7518 rm conftest.$ac_ext
7519 LIBS=$ac_func_search_save_LIBS
7520 fi
7521 { echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
7522 echo "${ECHO_T}$ac_cv_search_com_err" >&6; }
7523 ac_res=$ac_cv_search_com_err
7524 if test "$ac_res" != no; then
7525   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7526
7527 else
7528   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
7529 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
7530    { (exit 1); exit 1; }; }
7531 fi
7532
7533   fi
7534 fi
7535
7536 if test "$with_openssl" = yes ; then
7537     if test "$PORTNAME" != "win32"; then
7538
7539 { echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
7540 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6; }
7541 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
7542   echo $ECHO_N "(cached) $ECHO_C" >&6
7543 else
7544   ac_check_lib_save_LIBS=$LIBS
7545 LIBS="-lcrypto  $LIBS"
7546 cat >conftest.$ac_ext <<_ACEOF
7547 /* confdefs.h.  */
7548 _ACEOF
7549 cat confdefs.h >>conftest.$ac_ext
7550 cat >>conftest.$ac_ext <<_ACEOF
7551 /* end confdefs.h.  */
7552
7553 /* Override any GCC internal prototype to avoid an error.
7554    Use char because int might match the return type of a GCC
7555    builtin and then its argument prototype would still apply.  */
7556 #ifdef __cplusplus
7557 extern "C"
7558 #endif
7559 char CRYPTO_new_ex_data ();
7560 int
7561 main ()
7562 {
7563 return CRYPTO_new_ex_data ();
7564   ;
7565   return 0;
7566 }
7567 _ACEOF
7568 rm -f conftest.$ac_objext conftest$ac_exeext
7569 if { (ac_try="$ac_link"
7570 case "(($ac_try" in
7571   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7572   *) ac_try_echo=$ac_try;;
7573 esac
7574 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7575   (eval "$ac_link") 2>conftest.er1
7576   ac_status=$?
7577   grep -v '^ *+' conftest.er1 >conftest.err
7578   rm -f conftest.er1
7579   cat conftest.err >&5
7580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7581   (exit $ac_status); } && {
7582          test -z "$ac_c_werror_flag" ||
7583          test ! -s conftest.err
7584        } && test -s conftest$ac_exeext &&
7585        $as_test_x conftest$ac_exeext; then
7586   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
7587 else
7588   echo "$as_me: failed program was:" >&5
7589 sed 's/^/| /' conftest.$ac_ext >&5
7590
7591         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
7592 fi
7593
7594 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7595       conftest$ac_exeext conftest.$ac_ext
7596 LIBS=$ac_check_lib_save_LIBS
7597 fi
7598 { echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
7599 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
7600 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
7601   cat >>confdefs.h <<_ACEOF
7602 #define HAVE_LIBCRYPTO 1
7603 _ACEOF
7604
7605   LIBS="-lcrypto $LIBS"
7606
7607 else
7608   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
7609 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
7610    { (exit 1); exit 1; }; }
7611 fi
7612
7613
7614 { echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
7615 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6; }
7616 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
7617   echo $ECHO_N "(cached) $ECHO_C" >&6
7618 else
7619   ac_check_lib_save_LIBS=$LIBS
7620 LIBS="-lssl  $LIBS"
7621 cat >conftest.$ac_ext <<_ACEOF
7622 /* confdefs.h.  */
7623 _ACEOF
7624 cat confdefs.h >>conftest.$ac_ext
7625 cat >>conftest.$ac_ext <<_ACEOF
7626 /* end confdefs.h.  */
7627
7628 /* Override any GCC internal prototype to avoid an error.
7629    Use char because int might match the return type of a GCC
7630    builtin and then its argument prototype would still apply.  */
7631 #ifdef __cplusplus
7632 extern "C"
7633 #endif
7634 char SSL_library_init ();
7635 int
7636 main ()
7637 {
7638 return SSL_library_init ();
7639   ;
7640   return 0;
7641 }
7642 _ACEOF
7643 rm -f conftest.$ac_objext conftest$ac_exeext
7644 if { (ac_try="$ac_link"
7645 case "(($ac_try" in
7646   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7647   *) ac_try_echo=$ac_try;;
7648 esac
7649 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7650   (eval "$ac_link") 2>conftest.er1
7651   ac_status=$?
7652   grep -v '^ *+' conftest.er1 >conftest.err
7653   rm -f conftest.er1
7654   cat conftest.err >&5
7655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7656   (exit $ac_status); } && {
7657          test -z "$ac_c_werror_flag" ||
7658          test ! -s conftest.err
7659        } && test -s conftest$ac_exeext &&
7660        $as_test_x conftest$ac_exeext; then
7661   ac_cv_lib_ssl_SSL_library_init=yes
7662 else
7663   echo "$as_me: failed program was:" >&5
7664 sed 's/^/| /' conftest.$ac_ext >&5
7665
7666         ac_cv_lib_ssl_SSL_library_init=no
7667 fi
7668
7669 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7670       conftest$ac_exeext conftest.$ac_ext
7671 LIBS=$ac_check_lib_save_LIBS
7672 fi
7673 { echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
7674 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6; }
7675 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
7676   cat >>confdefs.h <<_ACEOF
7677 #define HAVE_LIBSSL 1
7678 _ACEOF
7679
7680   LIBS="-lssl $LIBS"
7681
7682 else
7683   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
7684 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
7685    { (exit 1); exit 1; }; }
7686 fi
7687
7688   else
7689
7690 { echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
7691 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6; }
7692 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
7693   echo $ECHO_N "(cached) $ECHO_C" >&6
7694 else
7695   ac_check_lib_save_LIBS=$LIBS
7696 LIBS="-leay32  $LIBS"
7697 cat >conftest.$ac_ext <<_ACEOF
7698 /* confdefs.h.  */
7699 _ACEOF
7700 cat confdefs.h >>conftest.$ac_ext
7701 cat >>conftest.$ac_ext <<_ACEOF
7702 /* end confdefs.h.  */
7703
7704 /* Override any GCC internal prototype to avoid an error.
7705    Use char because int might match the return type of a GCC
7706    builtin and then its argument prototype would still apply.  */
7707 #ifdef __cplusplus
7708 extern "C"
7709 #endif
7710 char CRYPTO_new_ex_data ();
7711 int
7712 main ()
7713 {
7714 return CRYPTO_new_ex_data ();
7715   ;
7716   return 0;
7717 }
7718 _ACEOF
7719 rm -f conftest.$ac_objext conftest$ac_exeext
7720 if { (ac_try="$ac_link"
7721 case "(($ac_try" in
7722   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7723   *) ac_try_echo=$ac_try;;
7724 esac
7725 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7726   (eval "$ac_link") 2>conftest.er1
7727   ac_status=$?
7728   grep -v '^ *+' conftest.er1 >conftest.err
7729   rm -f conftest.er1
7730   cat conftest.err >&5
7731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7732   (exit $ac_status); } && {
7733          test -z "$ac_c_werror_flag" ||
7734          test ! -s conftest.err
7735        } && test -s conftest$ac_exeext &&
7736        $as_test_x conftest$ac_exeext; then
7737   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
7738 else
7739   echo "$as_me: failed program was:" >&5
7740 sed 's/^/| /' conftest.$ac_ext >&5
7741
7742         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
7743 fi
7744
7745 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7746       conftest$ac_exeext conftest.$ac_ext
7747 LIBS=$ac_check_lib_save_LIBS
7748 fi
7749 { echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
7750 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
7751 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
7752   cat >>confdefs.h <<_ACEOF
7753 #define HAVE_LIBEAY32 1
7754 _ACEOF
7755
7756   LIBS="-leay32 $LIBS"
7757
7758 else
7759   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
7760 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
7761    { (exit 1); exit 1; }; }
7762 fi
7763
7764
7765 { echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
7766 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6; }
7767 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
7768   echo $ECHO_N "(cached) $ECHO_C" >&6
7769 else
7770   ac_check_lib_save_LIBS=$LIBS
7771 LIBS="-lssleay32  $LIBS"
7772 cat >conftest.$ac_ext <<_ACEOF
7773 /* confdefs.h.  */
7774 _ACEOF
7775 cat confdefs.h >>conftest.$ac_ext
7776 cat >>conftest.$ac_ext <<_ACEOF
7777 /* end confdefs.h.  */
7778
7779 /* Override any GCC internal prototype to avoid an error.
7780    Use char because int might match the return type of a GCC
7781    builtin and then its argument prototype would still apply.  */
7782 #ifdef __cplusplus
7783 extern "C"
7784 #endif
7785 char SSL_library_init ();
7786 int
7787 main ()
7788 {
7789 return SSL_library_init ();
7790   ;
7791   return 0;
7792 }
7793 _ACEOF
7794 rm -f conftest.$ac_objext conftest$ac_exeext
7795 if { (ac_try="$ac_link"
7796 case "(($ac_try" in
7797   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7798   *) ac_try_echo=$ac_try;;
7799 esac
7800 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7801   (eval "$ac_link") 2>conftest.er1
7802   ac_status=$?
7803   grep -v '^ *+' conftest.er1 >conftest.err
7804   rm -f conftest.er1
7805   cat conftest.err >&5
7806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7807   (exit $ac_status); } && {
7808          test -z "$ac_c_werror_flag" ||
7809          test ! -s conftest.err
7810        } && test -s conftest$ac_exeext &&
7811        $as_test_x conftest$ac_exeext; then
7812   ac_cv_lib_ssleay32_SSL_library_init=yes
7813 else
7814   echo "$as_me: failed program was:" >&5
7815 sed 's/^/| /' conftest.$ac_ext >&5
7816
7817         ac_cv_lib_ssleay32_SSL_library_init=no
7818 fi
7819
7820 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7821       conftest$ac_exeext conftest.$ac_ext
7822 LIBS=$ac_check_lib_save_LIBS
7823 fi
7824 { echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7825 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
7826 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
7827   cat >>confdefs.h <<_ACEOF
7828 #define HAVE_LIBSSLEAY32 1
7829 _ACEOF
7830
7831   LIBS="-lssleay32 $LIBS"
7832
7833 else
7834   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
7835 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
7836    { (exit 1); exit 1; }; }
7837 fi
7838
7839   fi
7840 fi
7841
7842 if test "$with_pam" = yes ; then
7843
7844 { echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
7845 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6; }
7846 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
7847   echo $ECHO_N "(cached) $ECHO_C" >&6
7848 else
7849   ac_check_lib_save_LIBS=$LIBS
7850 LIBS="-lpam  $LIBS"
7851 cat >conftest.$ac_ext <<_ACEOF
7852 /* confdefs.h.  */
7853 _ACEOF
7854 cat confdefs.h >>conftest.$ac_ext
7855 cat >>conftest.$ac_ext <<_ACEOF
7856 /* end confdefs.h.  */
7857
7858 /* Override any GCC internal prototype to avoid an error.
7859    Use char because int might match the return type of a GCC
7860    builtin and then its argument prototype would still apply.  */
7861 #ifdef __cplusplus
7862 extern "C"
7863 #endif
7864 char pam_start ();
7865 int
7866 main ()
7867 {
7868 return pam_start ();
7869   ;
7870   return 0;
7871 }
7872 _ACEOF
7873 rm -f conftest.$ac_objext conftest$ac_exeext
7874 if { (ac_try="$ac_link"
7875 case "(($ac_try" in
7876   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7877   *) ac_try_echo=$ac_try;;
7878 esac
7879 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7880   (eval "$ac_link") 2>conftest.er1
7881   ac_status=$?
7882   grep -v '^ *+' conftest.er1 >conftest.err
7883   rm -f conftest.er1
7884   cat conftest.err >&5
7885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7886   (exit $ac_status); } && {
7887          test -z "$ac_c_werror_flag" ||
7888          test ! -s conftest.err
7889        } && test -s conftest$ac_exeext &&
7890        $as_test_x conftest$ac_exeext; then
7891   ac_cv_lib_pam_pam_start=yes
7892 else
7893   echo "$as_me: failed program was:" >&5
7894 sed 's/^/| /' conftest.$ac_ext >&5
7895
7896         ac_cv_lib_pam_pam_start=no
7897 fi
7898
7899 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7900       conftest$ac_exeext conftest.$ac_ext
7901 LIBS=$ac_check_lib_save_LIBS
7902 fi
7903 { echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7904 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6; }
7905 if test $ac_cv_lib_pam_pam_start = yes; then
7906   cat >>confdefs.h <<_ACEOF
7907 #define HAVE_LIBPAM 1
7908 _ACEOF
7909
7910   LIBS="-lpam $LIBS"
7911
7912 else
7913   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7914 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7915    { (exit 1); exit 1; }; }
7916 fi
7917
7918 fi
7919
7920 if test "$with_libxml" = yes ; then
7921
7922 { echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
7923 echo $ECHO_N "checking for xmlSaveToBuffer in -lxml2... $ECHO_C" >&6; }
7924 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
7925   echo $ECHO_N "(cached) $ECHO_C" >&6
7926 else
7927   ac_check_lib_save_LIBS=$LIBS
7928 LIBS="-lxml2  $LIBS"
7929 cat >conftest.$ac_ext <<_ACEOF
7930 /* confdefs.h.  */
7931 _ACEOF
7932 cat confdefs.h >>conftest.$ac_ext
7933 cat >>conftest.$ac_ext <<_ACEOF
7934 /* end confdefs.h.  */
7935
7936 /* Override any GCC internal prototype to avoid an error.
7937    Use char because int might match the return type of a GCC
7938    builtin and then its argument prototype would still apply.  */
7939 #ifdef __cplusplus
7940 extern "C"
7941 #endif
7942 char xmlSaveToBuffer ();
7943 int
7944 main ()
7945 {
7946 return xmlSaveToBuffer ();
7947   ;
7948   return 0;
7949 }
7950 _ACEOF
7951 rm -f conftest.$ac_objext conftest$ac_exeext
7952 if { (ac_try="$ac_link"
7953 case "(($ac_try" in
7954   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7955   *) ac_try_echo=$ac_try;;
7956 esac
7957 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7958   (eval "$ac_link") 2>conftest.er1
7959   ac_status=$?
7960   grep -v '^ *+' conftest.er1 >conftest.err
7961   rm -f conftest.er1
7962   cat conftest.err >&5
7963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7964   (exit $ac_status); } && {
7965          test -z "$ac_c_werror_flag" ||
7966          test ! -s conftest.err
7967        } && test -s conftest$ac_exeext &&
7968        $as_test_x conftest$ac_exeext; then
7969   ac_cv_lib_xml2_xmlSaveToBuffer=yes
7970 else
7971   echo "$as_me: failed program was:" >&5
7972 sed 's/^/| /' conftest.$ac_ext >&5
7973
7974         ac_cv_lib_xml2_xmlSaveToBuffer=no
7975 fi
7976
7977 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7978       conftest$ac_exeext conftest.$ac_ext
7979 LIBS=$ac_check_lib_save_LIBS
7980 fi
7981 { echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
7982 echo "${ECHO_T}$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
7983 if test $ac_cv_lib_xml2_xmlSaveToBuffer = yes; then
7984   cat >>confdefs.h <<_ACEOF
7985 #define HAVE_LIBXML2 1
7986 _ACEOF
7987
7988   LIBS="-lxml2 $LIBS"
7989
7990 else
7991   { { echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
7992 echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
7993    { (exit 1); exit 1; }; }
7994 fi
7995
7996 fi
7997
7998 if test "$with_libxslt" = yes ; then
7999
8000 { echo "$as_me:$LINENO: checking for xsltLibxmlVersion in -lxslt" >&5
8001 echo $ECHO_N "checking for xsltLibxmlVersion in -lxslt... $ECHO_C" >&6; }
8002 if test "${ac_cv_lib_xslt_xsltLibxmlVersion+set}" = set; then
8003   echo $ECHO_N "(cached) $ECHO_C" >&6
8004 else
8005   ac_check_lib_save_LIBS=$LIBS
8006 LIBS="-lxslt  $LIBS"
8007 cat >conftest.$ac_ext <<_ACEOF
8008 /* confdefs.h.  */
8009 _ACEOF
8010 cat confdefs.h >>conftest.$ac_ext
8011 cat >>conftest.$ac_ext <<_ACEOF
8012 /* end confdefs.h.  */
8013
8014 /* Override any GCC internal prototype to avoid an error.
8015    Use char because int might match the return type of a GCC
8016    builtin and then its argument prototype would still apply.  */
8017 #ifdef __cplusplus
8018 extern "C"
8019 #endif
8020 char xsltLibxmlVersion ();
8021 int
8022 main ()
8023 {
8024 return xsltLibxmlVersion ();
8025   ;
8026   return 0;
8027 }
8028 _ACEOF
8029 rm -f conftest.$ac_objext conftest$ac_exeext
8030 if { (ac_try="$ac_link"
8031 case "(($ac_try" in
8032   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8033   *) ac_try_echo=$ac_try;;
8034 esac
8035 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8036   (eval "$ac_link") 2>conftest.er1
8037   ac_status=$?
8038   grep -v '^ *+' conftest.er1 >conftest.err
8039   rm -f conftest.er1
8040   cat conftest.err >&5
8041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8042   (exit $ac_status); } && {
8043          test -z "$ac_c_werror_flag" ||
8044          test ! -s conftest.err
8045        } && test -s conftest$ac_exeext &&
8046        $as_test_x conftest$ac_exeext; then
8047   ac_cv_lib_xslt_xsltLibxmlVersion=yes
8048 else
8049   echo "$as_me: failed program was:" >&5
8050 sed 's/^/| /' conftest.$ac_ext >&5
8051
8052         ac_cv_lib_xslt_xsltLibxmlVersion=no
8053 fi
8054
8055 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8056       conftest$ac_exeext conftest.$ac_ext
8057 LIBS=$ac_check_lib_save_LIBS
8058 fi
8059 { echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltLibxmlVersion" >&5
8060 echo "${ECHO_T}$ac_cv_lib_xslt_xsltLibxmlVersion" >&6; }
8061 if test $ac_cv_lib_xslt_xsltLibxmlVersion = yes; then
8062   cat >>confdefs.h <<_ACEOF
8063 #define HAVE_LIBXSLT 1
8064 _ACEOF
8065
8066   LIBS="-lxslt $LIBS"
8067
8068 else
8069   { { echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
8070 echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
8071    { (exit 1); exit 1; }; }
8072 fi
8073
8074 fi
8075
8076 # for contrib/uuid-ossp
8077 if test "$with_ossp_uuid" = yes ; then
8078   { echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
8079 echo $ECHO_N "checking for uuid_export in -lossp-uuid... $ECHO_C" >&6; }
8080 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
8081   echo $ECHO_N "(cached) $ECHO_C" >&6
8082 else
8083   ac_check_lib_save_LIBS=$LIBS
8084 LIBS="-lossp-uuid  $LIBS"
8085 cat >conftest.$ac_ext <<_ACEOF
8086 /* confdefs.h.  */
8087 _ACEOF
8088 cat confdefs.h >>conftest.$ac_ext
8089 cat >>conftest.$ac_ext <<_ACEOF
8090 /* end confdefs.h.  */
8091
8092 /* Override any GCC internal prototype to avoid an error.
8093    Use char because int might match the return type of a GCC
8094    builtin and then its argument prototype would still apply.  */
8095 #ifdef __cplusplus
8096 extern "C"
8097 #endif
8098 char uuid_export ();
8099 int
8100 main ()
8101 {
8102 return uuid_export ();
8103   ;
8104   return 0;
8105 }
8106 _ACEOF
8107 rm -f conftest.$ac_objext conftest$ac_exeext
8108 if { (ac_try="$ac_link"
8109 case "(($ac_try" in
8110   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8111   *) ac_try_echo=$ac_try;;
8112 esac
8113 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8114   (eval "$ac_link") 2>conftest.er1
8115   ac_status=$?
8116   grep -v '^ *+' conftest.er1 >conftest.err
8117   rm -f conftest.er1
8118   cat conftest.err >&5
8119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8120   (exit $ac_status); } && {
8121          test -z "$ac_c_werror_flag" ||
8122          test ! -s conftest.err
8123        } && test -s conftest$ac_exeext &&
8124        $as_test_x conftest$ac_exeext; then
8125   ac_cv_lib_ossp_uuid_uuid_export=yes
8126 else
8127   echo "$as_me: failed program was:" >&5
8128 sed 's/^/| /' conftest.$ac_ext >&5
8129
8130         ac_cv_lib_ossp_uuid_uuid_export=no
8131 fi
8132
8133 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8134       conftest$ac_exeext conftest.$ac_ext
8135 LIBS=$ac_check_lib_save_LIBS
8136 fi
8137 { echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
8138 echo "${ECHO_T}$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
8139 if test $ac_cv_lib_ossp_uuid_uuid_export = yes; then
8140   OSSP_UUID_LIBS="-lossp-uuid"
8141 else
8142   { echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
8143 echo $ECHO_N "checking for uuid_export in -luuid... $ECHO_C" >&6; }
8144 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
8145   echo $ECHO_N "(cached) $ECHO_C" >&6
8146 else
8147   ac_check_lib_save_LIBS=$LIBS
8148 LIBS="-luuid  $LIBS"
8149 cat >conftest.$ac_ext <<_ACEOF
8150 /* confdefs.h.  */
8151 _ACEOF
8152 cat confdefs.h >>conftest.$ac_ext
8153 cat >>conftest.$ac_ext <<_ACEOF
8154 /* end confdefs.h.  */
8155
8156 /* Override any GCC internal prototype to avoid an error.
8157    Use char because int might match the return type of a GCC
8158    builtin and then its argument prototype would still apply.  */
8159 #ifdef __cplusplus
8160 extern "C"
8161 #endif
8162 char uuid_export ();
8163 int
8164 main ()
8165 {
8166 return uuid_export ();
8167   ;
8168   return 0;
8169 }
8170 _ACEOF
8171 rm -f conftest.$ac_objext conftest$ac_exeext
8172 if { (ac_try="$ac_link"
8173 case "(($ac_try" in
8174   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8175   *) ac_try_echo=$ac_try;;
8176 esac
8177 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8178   (eval "$ac_link") 2>conftest.er1
8179   ac_status=$?
8180   grep -v '^ *+' conftest.er1 >conftest.err
8181   rm -f conftest.er1
8182   cat conftest.err >&5
8183   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8184   (exit $ac_status); } && {
8185          test -z "$ac_c_werror_flag" ||
8186          test ! -s conftest.err
8187        } && test -s conftest$ac_exeext &&
8188        $as_test_x conftest$ac_exeext; then
8189   ac_cv_lib_uuid_uuid_export=yes
8190 else
8191   echo "$as_me: failed program was:" >&5
8192 sed 's/^/| /' conftest.$ac_ext >&5
8193
8194         ac_cv_lib_uuid_uuid_export=no
8195 fi
8196
8197 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8198       conftest$ac_exeext conftest.$ac_ext
8199 LIBS=$ac_check_lib_save_LIBS
8200 fi
8201 { echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
8202 echo "${ECHO_T}$ac_cv_lib_uuid_uuid_export" >&6; }
8203 if test $ac_cv_lib_uuid_uuid_export = yes; then
8204   OSSP_UUID_LIBS="-luuid"
8205 else
8206   { { echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
8207 echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
8208    { (exit 1); exit 1; }; }
8209 fi
8210
8211 fi
8212
8213 fi
8214
8215
8216
8217 ##
8218 ## Header files
8219 ##
8220
8221 { echo "$as_me:$LINENO: checking for ANSI C header files" >&5
8222 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
8223 if test "${ac_cv_header_stdc+set}" = set; then
8224   echo $ECHO_N "(cached) $ECHO_C" >&6
8225 else
8226   cat >conftest.$ac_ext <<_ACEOF
8227 /* confdefs.h.  */
8228 _ACEOF
8229 cat confdefs.h >>conftest.$ac_ext
8230 cat >>conftest.$ac_ext <<_ACEOF
8231 /* end confdefs.h.  */
8232 #include <stdlib.h>
8233 #include <stdarg.h>
8234 #include <string.h>
8235 #include <float.h>
8236
8237 int
8238 main ()
8239 {
8240
8241   ;
8242   return 0;
8243 }
8244 _ACEOF
8245 rm -f conftest.$ac_objext
8246 if { (ac_try="$ac_compile"
8247 case "(($ac_try" in
8248   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8249   *) ac_try_echo=$ac_try;;
8250 esac
8251 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8252   (eval "$ac_compile") 2>conftest.er1
8253   ac_status=$?
8254   grep -v '^ *+' conftest.er1 >conftest.err
8255   rm -f conftest.er1
8256   cat conftest.err >&5
8257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8258   (exit $ac_status); } && {
8259          test -z "$ac_c_werror_flag" ||
8260          test ! -s conftest.err
8261        } && test -s conftest.$ac_objext; then
8262   ac_cv_header_stdc=yes
8263 else
8264   echo "$as_me: failed program was:" >&5
8265 sed 's/^/| /' conftest.$ac_ext >&5
8266
8267         ac_cv_header_stdc=no
8268 fi
8269
8270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8271
8272 if test $ac_cv_header_stdc = yes; then
8273   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
8274   cat >conftest.$ac_ext <<_ACEOF
8275 /* confdefs.h.  */
8276 _ACEOF
8277 cat confdefs.h >>conftest.$ac_ext
8278 cat >>conftest.$ac_ext <<_ACEOF
8279 /* end confdefs.h.  */
8280 #include <string.h>
8281
8282 _ACEOF
8283 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8284   $EGREP "memchr" >/dev/null 2>&1; then
8285   :
8286 else
8287   ac_cv_header_stdc=no
8288 fi
8289 rm -f conftest*
8290
8291 fi
8292
8293 if test $ac_cv_header_stdc = yes; then
8294   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
8295   cat >conftest.$ac_ext <<_ACEOF
8296 /* confdefs.h.  */
8297 _ACEOF
8298 cat confdefs.h >>conftest.$ac_ext
8299 cat >>conftest.$ac_ext <<_ACEOF
8300 /* end confdefs.h.  */
8301 #include <stdlib.h>
8302
8303 _ACEOF
8304 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8305   $EGREP "free" >/dev/null 2>&1; then
8306   :
8307 else
8308   ac_cv_header_stdc=no
8309 fi
8310 rm -f conftest*
8311
8312 fi
8313
8314 if test $ac_cv_header_stdc = yes; then
8315   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
8316   if test "$cross_compiling" = yes; then
8317   :
8318 else
8319   cat >conftest.$ac_ext <<_ACEOF
8320 /* confdefs.h.  */
8321 _ACEOF
8322 cat confdefs.h >>conftest.$ac_ext
8323 cat >>conftest.$ac_ext <<_ACEOF
8324 /* end confdefs.h.  */
8325 #include <ctype.h>
8326 #include <stdlib.h>
8327 #if ((' ' & 0x0FF) == 0x020)
8328 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8329 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8330 #else
8331 # define ISLOWER(c) \
8332                    (('a' <= (c) && (c) <= 'i') \
8333                      || ('j' <= (c) && (c) <= 'r') \
8334                      || ('s' <= (c) && (c) <= 'z'))
8335 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8336 #endif
8337
8338 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8339 int
8340 main ()
8341 {
8342   int i;
8343   for (i = 0; i < 256; i++)
8344     if (XOR (islower (i), ISLOWER (i))
8345         || toupper (i) != TOUPPER (i))
8346       return 2;
8347   return 0;
8348 }
8349 _ACEOF
8350 rm -f conftest$ac_exeext
8351 if { (ac_try="$ac_link"
8352 case "(($ac_try" in
8353   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8354   *) ac_try_echo=$ac_try;;
8355 esac
8356 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8357   (eval "$ac_link") 2>&5
8358   ac_status=$?
8359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8360   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8361   { (case "(($ac_try" in
8362   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8363   *) ac_try_echo=$ac_try;;
8364 esac
8365 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8366   (eval "$ac_try") 2>&5
8367   ac_status=$?
8368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8369   (exit $ac_status); }; }; then
8370   :
8371 else
8372   echo "$as_me: program exited with status $ac_status" >&5
8373 echo "$as_me: failed program was:" >&5
8374 sed 's/^/| /' conftest.$ac_ext >&5
8375
8376 ( exit $ac_status )
8377 ac_cv_header_stdc=no
8378 fi
8379 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8380 fi
8381
8382
8383 fi
8384 fi
8385 { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
8386 echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
8387 if test $ac_cv_header_stdc = yes; then
8388
8389 cat >>confdefs.h <<\_ACEOF
8390 #define STDC_HEADERS 1
8391 _ACEOF
8392
8393 fi
8394
8395 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
8396
8397
8398
8399
8400
8401
8402
8403
8404
8405 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
8406                   inttypes.h stdint.h unistd.h
8407 do
8408 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8409 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8410 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8411 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8412   echo $ECHO_N "(cached) $ECHO_C" >&6
8413 else
8414   cat >conftest.$ac_ext <<_ACEOF
8415 /* confdefs.h.  */
8416 _ACEOF
8417 cat confdefs.h >>conftest.$ac_ext
8418 cat >>conftest.$ac_ext <<_ACEOF
8419 /* end confdefs.h.  */
8420 $ac_includes_default
8421
8422 #include <$ac_header>
8423 _ACEOF
8424 rm -f conftest.$ac_objext
8425 if { (ac_try="$ac_compile"
8426 case "(($ac_try" in
8427   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8428   *) ac_try_echo=$ac_try;;
8429 esac
8430 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8431   (eval "$ac_compile") 2>conftest.er1
8432   ac_status=$?
8433   grep -v '^ *+' conftest.er1 >conftest.err
8434   rm -f conftest.er1
8435   cat conftest.err >&5
8436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8437   (exit $ac_status); } && {
8438          test -z "$ac_c_werror_flag" ||
8439          test ! -s conftest.err
8440        } && test -s conftest.$ac_objext; then
8441   eval "$as_ac_Header=yes"
8442 else
8443   echo "$as_me: failed program was:" >&5
8444 sed 's/^/| /' conftest.$ac_ext >&5
8445
8446         eval "$as_ac_Header=no"
8447 fi
8448
8449 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8450 fi
8451 ac_res=`eval echo '${'$as_ac_Header'}'`
8452                { echo "$as_me:$LINENO: result: $ac_res" >&5
8453 echo "${ECHO_T}$ac_res" >&6; }
8454 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8455   cat >>confdefs.h <<_ACEOF
8456 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8457 _ACEOF
8458
8459 fi
8460
8461 done
8462
8463
8464
8465
8466
8467
8468
8469
8470
8471
8472
8473
8474
8475
8476
8477
8478
8479
8480
8481
8482
8483
8484
8485
8486
8487
8488
8489
8490 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
8491 do
8492 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8493 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8494   { echo "$as_me:$LINENO: checking for $ac_header" >&5
8495 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8496 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8497   echo $ECHO_N "(cached) $ECHO_C" >&6
8498 fi
8499 ac_res=`eval echo '${'$as_ac_Header'}'`
8500                { echo "$as_me:$LINENO: result: $ac_res" >&5
8501 echo "${ECHO_T}$ac_res" >&6; }
8502 else
8503   # Is the header compilable?
8504 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
8505 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
8506 cat >conftest.$ac_ext <<_ACEOF
8507 /* confdefs.h.  */
8508 _ACEOF
8509 cat confdefs.h >>conftest.$ac_ext
8510 cat >>conftest.$ac_ext <<_ACEOF
8511 /* end confdefs.h.  */
8512 $ac_includes_default
8513 #include <$ac_header>
8514 _ACEOF
8515 rm -f conftest.$ac_objext
8516 if { (ac_try="$ac_compile"
8517 case "(($ac_try" in
8518   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8519   *) ac_try_echo=$ac_try;;
8520 esac
8521 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8522   (eval "$ac_compile") 2>conftest.er1
8523   ac_status=$?
8524   grep -v '^ *+' conftest.er1 >conftest.err
8525   rm -f conftest.er1
8526   cat conftest.err >&5
8527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8528   (exit $ac_status); } && {
8529          test -z "$ac_c_werror_flag" ||
8530          test ! -s conftest.err
8531        } && test -s conftest.$ac_objext; then
8532   ac_header_compiler=yes
8533 else
8534   echo "$as_me: failed program was:" >&5
8535 sed 's/^/| /' conftest.$ac_ext >&5
8536
8537         ac_header_compiler=no
8538 fi
8539
8540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8541 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8542 echo "${ECHO_T}$ac_header_compiler" >&6; }
8543
8544 # Is the header present?
8545 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
8546 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
8547 cat >conftest.$ac_ext <<_ACEOF
8548 /* confdefs.h.  */
8549 _ACEOF
8550 cat confdefs.h >>conftest.$ac_ext
8551 cat >>conftest.$ac_ext <<_ACEOF
8552 /* end confdefs.h.  */
8553 #include <$ac_header>
8554 _ACEOF
8555 if { (ac_try="$ac_cpp conftest.$ac_ext"
8556 case "(($ac_try" in
8557   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8558   *) ac_try_echo=$ac_try;;
8559 esac
8560 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8561   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8562   ac_status=$?
8563   grep -v '^ *+' conftest.er1 >conftest.err
8564   rm -f conftest.er1
8565   cat conftest.err >&5
8566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8567   (exit $ac_status); } >/dev/null && {
8568          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8569          test ! -s conftest.err
8570        }; then
8571   ac_header_preproc=yes
8572 else
8573   echo "$as_me: failed program was:" >&5
8574 sed 's/^/| /' conftest.$ac_ext >&5
8575
8576   ac_header_preproc=no
8577 fi
8578
8579 rm -f conftest.err conftest.$ac_ext
8580 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8581 echo "${ECHO_T}$ac_header_preproc" >&6; }
8582
8583 # So?  What about this header?
8584 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8585   yes:no: )
8586     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8587 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8588     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8589 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8590     ac_header_preproc=yes
8591     ;;
8592   no:yes:* )
8593     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8594 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8595     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8596 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8597     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8598 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8599     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8600 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8601     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8602 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8603     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8604 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8605     ( cat <<\_ASBOX
8606 ## ---------------------------------------- ##
8607 ## Report this to pgsql-bugs@postgresql.org ##
8608 ## ---------------------------------------- ##
8609 _ASBOX
8610      ) | sed "s/^/$as_me: WARNING:     /" >&2
8611     ;;
8612 esac
8613 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8614 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8615 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8616   echo $ECHO_N "(cached) $ECHO_C" >&6
8617 else
8618   eval "$as_ac_Header=\$ac_header_preproc"
8619 fi
8620 ac_res=`eval echo '${'$as_ac_Header'}'`
8621                { echo "$as_me:$LINENO: result: $ac_res" >&5
8622 echo "${ECHO_T}$ac_res" >&6; }
8623
8624 fi
8625 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8626   cat >>confdefs.h <<_ACEOF
8627 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8628 _ACEOF
8629
8630 fi
8631
8632 done
8633
8634
8635 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
8636 # netinet/in.h is included first.
8637
8638 for ac_header in netinet/in.h
8639 do
8640 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8641 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8642   { echo "$as_me:$LINENO: checking for $ac_header" >&5
8643 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8644 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8645   echo $ECHO_N "(cached) $ECHO_C" >&6
8646 fi
8647 ac_res=`eval echo '${'$as_ac_Header'}'`
8648                { echo "$as_me:$LINENO: result: $ac_res" >&5
8649 echo "${ECHO_T}$ac_res" >&6; }
8650 else
8651   # Is the header compilable?
8652 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
8653 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
8654 cat >conftest.$ac_ext <<_ACEOF
8655 /* confdefs.h.  */
8656 _ACEOF
8657 cat confdefs.h >>conftest.$ac_ext
8658 cat >>conftest.$ac_ext <<_ACEOF
8659 /* end confdefs.h.  */
8660 $ac_includes_default
8661 #include <$ac_header>
8662 _ACEOF
8663 rm -f conftest.$ac_objext
8664 if { (ac_try="$ac_compile"
8665 case "(($ac_try" in
8666   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8667   *) ac_try_echo=$ac_try;;
8668 esac
8669 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8670   (eval "$ac_compile") 2>conftest.er1
8671   ac_status=$?
8672   grep -v '^ *+' conftest.er1 >conftest.err
8673   rm -f conftest.er1
8674   cat conftest.err >&5
8675   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8676   (exit $ac_status); } && {
8677          test -z "$ac_c_werror_flag" ||
8678          test ! -s conftest.err
8679        } && test -s conftest.$ac_objext; then
8680   ac_header_compiler=yes
8681 else
8682   echo "$as_me: failed program was:" >&5
8683 sed 's/^/| /' conftest.$ac_ext >&5
8684
8685         ac_header_compiler=no
8686 fi
8687
8688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8689 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8690 echo "${ECHO_T}$ac_header_compiler" >&6; }
8691
8692 # Is the header present?
8693 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
8694 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
8695 cat >conftest.$ac_ext <<_ACEOF
8696 /* confdefs.h.  */
8697 _ACEOF
8698 cat confdefs.h >>conftest.$ac_ext
8699 cat >>conftest.$ac_ext <<_ACEOF
8700 /* end confdefs.h.  */
8701 #include <$ac_header>
8702 _ACEOF
8703 if { (ac_try="$ac_cpp conftest.$ac_ext"
8704 case "(($ac_try" in
8705   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8706   *) ac_try_echo=$ac_try;;
8707 esac
8708 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8709   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8710   ac_status=$?
8711   grep -v '^ *+' conftest.er1 >conftest.err
8712   rm -f conftest.er1
8713   cat conftest.err >&5
8714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8715   (exit $ac_status); } >/dev/null && {
8716          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8717          test ! -s conftest.err
8718        }; then
8719   ac_header_preproc=yes
8720 else
8721   echo "$as_me: failed program was:" >&5
8722 sed 's/^/| /' conftest.$ac_ext >&5
8723
8724   ac_header_preproc=no
8725 fi
8726
8727 rm -f conftest.err conftest.$ac_ext
8728 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8729 echo "${ECHO_T}$ac_header_preproc" >&6; }
8730
8731 # So?  What about this header?
8732 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8733   yes:no: )
8734     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8735 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8736     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8737 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8738     ac_header_preproc=yes
8739     ;;
8740   no:yes:* )
8741     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8742 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8743     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8744 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8745     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8746 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8747     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8748 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8749     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8750 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8751     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8752 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8753     ( cat <<\_ASBOX
8754 ## ---------------------------------------- ##
8755 ## Report this to pgsql-bugs@postgresql.org ##
8756 ## ---------------------------------------- ##
8757 _ASBOX
8758      ) | sed "s/^/$as_me: WARNING:     /" >&2
8759     ;;
8760 esac
8761 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8762 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8763 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8764   echo $ECHO_N "(cached) $ECHO_C" >&6
8765 else
8766   eval "$as_ac_Header=\$ac_header_preproc"
8767 fi
8768 ac_res=`eval echo '${'$as_ac_Header'}'`
8769                { echo "$as_me:$LINENO: result: $ac_res" >&5
8770 echo "${ECHO_T}$ac_res" >&6; }
8771
8772 fi
8773 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8774   cat >>confdefs.h <<_ACEOF
8775 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8776 _ACEOF
8777
8778 fi
8779
8780 done
8781
8782
8783 for ac_header in netinet/tcp.h
8784 do
8785 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8786 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8787 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8788 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8789   echo $ECHO_N "(cached) $ECHO_C" >&6
8790 else
8791   cat >conftest.$ac_ext <<_ACEOF
8792 /* confdefs.h.  */
8793 _ACEOF
8794 cat confdefs.h >>conftest.$ac_ext
8795 cat >>conftest.$ac_ext <<_ACEOF
8796 /* end confdefs.h.  */
8797 $ac_includes_default
8798 #ifdef HAVE_NETINET_IN_H
8799 #include <netinet/in.h>
8800 #endif
8801
8802
8803 #include <$ac_header>
8804 _ACEOF
8805 rm -f conftest.$ac_objext
8806 if { (ac_try="$ac_compile"
8807 case "(($ac_try" in
8808   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8809   *) ac_try_echo=$ac_try;;
8810 esac
8811 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8812   (eval "$ac_compile") 2>conftest.er1
8813   ac_status=$?
8814   grep -v '^ *+' conftest.er1 >conftest.err
8815   rm -f conftest.er1
8816   cat conftest.err >&5
8817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8818   (exit $ac_status); } && {
8819          test -z "$ac_c_werror_flag" ||
8820          test ! -s conftest.err
8821        } && test -s conftest.$ac_objext; then
8822   eval "$as_ac_Header=yes"
8823 else
8824   echo "$as_me: failed program was:" >&5
8825 sed 's/^/| /' conftest.$ac_ext >&5
8826
8827         eval "$as_ac_Header=no"
8828 fi
8829
8830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8831 fi
8832 ac_res=`eval echo '${'$as_ac_Header'}'`
8833                { echo "$as_me:$LINENO: result: $ac_res" >&5
8834 echo "${ECHO_T}$ac_res" >&6; }
8835 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8836   cat >>confdefs.h <<_ACEOF
8837 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8838 _ACEOF
8839
8840 fi
8841
8842 done
8843
8844
8845 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
8846
8847 for ac_header in readline/readline.h
8848 do
8849 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8850 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8851   { echo "$as_me:$LINENO: checking for $ac_header" >&5
8852 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8853 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8854   echo $ECHO_N "(cached) $ECHO_C" >&6
8855 fi
8856 ac_res=`eval echo '${'$as_ac_Header'}'`
8857                { echo "$as_me:$LINENO: result: $ac_res" >&5
8858 echo "${ECHO_T}$ac_res" >&6; }
8859 else
8860   # Is the header compilable?
8861 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
8862 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
8863 cat >conftest.$ac_ext <<_ACEOF
8864 /* confdefs.h.  */
8865 _ACEOF
8866 cat confdefs.h >>conftest.$ac_ext
8867 cat >>conftest.$ac_ext <<_ACEOF
8868 /* end confdefs.h.  */
8869 $ac_includes_default
8870 #include <$ac_header>
8871 _ACEOF
8872 rm -f conftest.$ac_objext
8873 if { (ac_try="$ac_compile"
8874 case "(($ac_try" in
8875   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8876   *) ac_try_echo=$ac_try;;
8877 esac
8878 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8879   (eval "$ac_compile") 2>conftest.er1
8880   ac_status=$?
8881   grep -v '^ *+' conftest.er1 >conftest.err
8882   rm -f conftest.er1
8883   cat conftest.err >&5
8884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8885   (exit $ac_status); } && {
8886          test -z "$ac_c_werror_flag" ||
8887          test ! -s conftest.err
8888        } && test -s conftest.$ac_objext; then
8889   ac_header_compiler=yes
8890 else
8891   echo "$as_me: failed program was:" >&5
8892 sed 's/^/| /' conftest.$ac_ext >&5
8893
8894         ac_header_compiler=no
8895 fi
8896
8897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8898 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8899 echo "${ECHO_T}$ac_header_compiler" >&6; }
8900
8901 # Is the header present?
8902 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
8903 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
8904 cat >conftest.$ac_ext <<_ACEOF
8905 /* confdefs.h.  */
8906 _ACEOF
8907 cat confdefs.h >>conftest.$ac_ext
8908 cat >>conftest.$ac_ext <<_ACEOF
8909 /* end confdefs.h.  */
8910 #include <$ac_header>
8911 _ACEOF
8912 if { (ac_try="$ac_cpp conftest.$ac_ext"
8913 case "(($ac_try" in
8914   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8915   *) ac_try_echo=$ac_try;;
8916 esac
8917 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8918   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8919   ac_status=$?
8920   grep -v '^ *+' conftest.er1 >conftest.err
8921   rm -f conftest.er1
8922   cat conftest.err >&5
8923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8924   (exit $ac_status); } >/dev/null && {
8925          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8926          test ! -s conftest.err
8927        }; then
8928   ac_header_preproc=yes
8929 else
8930   echo "$as_me: failed program was:" >&5
8931 sed 's/^/| /' conftest.$ac_ext >&5
8932
8933   ac_header_preproc=no
8934 fi
8935
8936 rm -f conftest.err conftest.$ac_ext
8937 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8938 echo "${ECHO_T}$ac_header_preproc" >&6; }
8939
8940 # So?  What about this header?
8941 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8942   yes:no: )
8943     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8944 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8945     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8946 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8947     ac_header_preproc=yes
8948     ;;
8949   no:yes:* )
8950     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8951 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8952     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8953 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8954     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8955 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8956     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8957 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8958     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8959 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8960     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8961 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8962     ( cat <<\_ASBOX
8963 ## ---------------------------------------- ##
8964 ## Report this to pgsql-bugs@postgresql.org ##
8965 ## ---------------------------------------- ##
8966 _ASBOX
8967      ) | sed "s/^/$as_me: WARNING:     /" >&2
8968     ;;
8969 esac
8970 { echo "$as_me:$LINENO: checking for $ac_header" >&5
8971 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8972 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8973   echo $ECHO_N "(cached) $ECHO_C" >&6
8974 else
8975   eval "$as_ac_Header=\$ac_header_preproc"
8976 fi
8977 ac_res=`eval echo '${'$as_ac_Header'}'`
8978                { echo "$as_me:$LINENO: result: $ac_res" >&5
8979 echo "${ECHO_T}$ac_res" >&6; }
8980
8981 fi
8982 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8983   cat >>confdefs.h <<_ACEOF
8984 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8985 _ACEOF
8986
8987 else
8988
8989 for ac_header in readline.h
8990 do
8991 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8992 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8993   { echo "$as_me:$LINENO: checking for $ac_header" >&5
8994 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
8995 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
8996   echo $ECHO_N "(cached) $ECHO_C" >&6
8997 fi
8998 ac_res=`eval echo '${'$as_ac_Header'}'`
8999                { echo "$as_me:$LINENO: result: $ac_res" >&5
9000 echo "${ECHO_T}$ac_res" >&6; }
9001 else
9002   # Is the header compilable?
9003 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9004 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9005 cat >conftest.$ac_ext <<_ACEOF
9006 /* confdefs.h.  */
9007 _ACEOF
9008 cat confdefs.h >>conftest.$ac_ext
9009 cat >>conftest.$ac_ext <<_ACEOF
9010 /* end confdefs.h.  */
9011 $ac_includes_default
9012 #include <$ac_header>
9013 _ACEOF
9014 rm -f conftest.$ac_objext
9015 if { (ac_try="$ac_compile"
9016 case "(($ac_try" in
9017   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9018   *) ac_try_echo=$ac_try;;
9019 esac
9020 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9021   (eval "$ac_compile") 2>conftest.er1
9022   ac_status=$?
9023   grep -v '^ *+' conftest.er1 >conftest.err
9024   rm -f conftest.er1
9025   cat conftest.err >&5
9026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9027   (exit $ac_status); } && {
9028          test -z "$ac_c_werror_flag" ||
9029          test ! -s conftest.err
9030        } && test -s conftest.$ac_objext; then
9031   ac_header_compiler=yes
9032 else
9033   echo "$as_me: failed program was:" >&5
9034 sed 's/^/| /' conftest.$ac_ext >&5
9035
9036         ac_header_compiler=no
9037 fi
9038
9039 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9040 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9041 echo "${ECHO_T}$ac_header_compiler" >&6; }
9042
9043 # Is the header present?
9044 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9045 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9046 cat >conftest.$ac_ext <<_ACEOF
9047 /* confdefs.h.  */
9048 _ACEOF
9049 cat confdefs.h >>conftest.$ac_ext
9050 cat >>conftest.$ac_ext <<_ACEOF
9051 /* end confdefs.h.  */
9052 #include <$ac_header>
9053 _ACEOF
9054 if { (ac_try="$ac_cpp conftest.$ac_ext"
9055 case "(($ac_try" in
9056   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9057   *) ac_try_echo=$ac_try;;
9058 esac
9059 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9060   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9061   ac_status=$?
9062   grep -v '^ *+' conftest.er1 >conftest.err
9063   rm -f conftest.er1
9064   cat conftest.err >&5
9065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9066   (exit $ac_status); } >/dev/null && {
9067          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9068          test ! -s conftest.err
9069        }; then
9070   ac_header_preproc=yes
9071 else
9072   echo "$as_me: failed program was:" >&5
9073 sed 's/^/| /' conftest.$ac_ext >&5
9074
9075   ac_header_preproc=no
9076 fi
9077
9078 rm -f conftest.err conftest.$ac_ext
9079 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9080 echo "${ECHO_T}$ac_header_preproc" >&6; }
9081
9082 # So?  What about this header?
9083 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9084   yes:no: )
9085     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9086 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9087     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9088 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9089     ac_header_preproc=yes
9090     ;;
9091   no:yes:* )
9092     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9093 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9094     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9095 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9096     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9097 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9098     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9099 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9100     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9101 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9102     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9103 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9104     ( cat <<\_ASBOX
9105 ## ---------------------------------------- ##
9106 ## Report this to pgsql-bugs@postgresql.org ##
9107 ## ---------------------------------------- ##
9108 _ASBOX
9109      ) | sed "s/^/$as_me: WARNING:     /" >&2
9110     ;;
9111 esac
9112 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9113 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9114 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9115   echo $ECHO_N "(cached) $ECHO_C" >&6
9116 else
9117   eval "$as_ac_Header=\$ac_header_preproc"
9118 fi
9119 ac_res=`eval echo '${'$as_ac_Header'}'`
9120                { echo "$as_me:$LINENO: result: $ac_res" >&5
9121 echo "${ECHO_T}$ac_res" >&6; }
9122
9123 fi
9124 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9125   cat >>confdefs.h <<_ACEOF
9126 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9127 _ACEOF
9128
9129 else
9130   { { echo "$as_me:$LINENO: error: readline header not found
9131 If you have readline already installed, see config.log for details on the
9132 failure.  It is possible the compiler isn't looking in the proper directory.
9133 Use --without-readline to disable readline support." >&5
9134 echo "$as_me: error: readline header not found
9135 If you have readline already installed, see config.log for details on the
9136 failure.  It is possible the compiler isn't looking in the proper directory.
9137 Use --without-readline to disable readline support." >&2;}
9138    { (exit 1); exit 1; }; }
9139 fi
9140
9141 done
9142
9143 fi
9144
9145 done
9146
9147
9148 for ac_header in readline/history.h
9149 do
9150 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9151 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9152   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9153 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9154 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9155   echo $ECHO_N "(cached) $ECHO_C" >&6
9156 fi
9157 ac_res=`eval echo '${'$as_ac_Header'}'`
9158                { echo "$as_me:$LINENO: result: $ac_res" >&5
9159 echo "${ECHO_T}$ac_res" >&6; }
9160 else
9161   # Is the header compilable?
9162 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9163 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9164 cat >conftest.$ac_ext <<_ACEOF
9165 /* confdefs.h.  */
9166 _ACEOF
9167 cat confdefs.h >>conftest.$ac_ext
9168 cat >>conftest.$ac_ext <<_ACEOF
9169 /* end confdefs.h.  */
9170 $ac_includes_default
9171 #include <$ac_header>
9172 _ACEOF
9173 rm -f conftest.$ac_objext
9174 if { (ac_try="$ac_compile"
9175 case "(($ac_try" in
9176   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9177   *) ac_try_echo=$ac_try;;
9178 esac
9179 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9180   (eval "$ac_compile") 2>conftest.er1
9181   ac_status=$?
9182   grep -v '^ *+' conftest.er1 >conftest.err
9183   rm -f conftest.er1
9184   cat conftest.err >&5
9185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9186   (exit $ac_status); } && {
9187          test -z "$ac_c_werror_flag" ||
9188          test ! -s conftest.err
9189        } && test -s conftest.$ac_objext; then
9190   ac_header_compiler=yes
9191 else
9192   echo "$as_me: failed program was:" >&5
9193 sed 's/^/| /' conftest.$ac_ext >&5
9194
9195         ac_header_compiler=no
9196 fi
9197
9198 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9199 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9200 echo "${ECHO_T}$ac_header_compiler" >&6; }
9201
9202 # Is the header present?
9203 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9204 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9205 cat >conftest.$ac_ext <<_ACEOF
9206 /* confdefs.h.  */
9207 _ACEOF
9208 cat confdefs.h >>conftest.$ac_ext
9209 cat >>conftest.$ac_ext <<_ACEOF
9210 /* end confdefs.h.  */
9211 #include <$ac_header>
9212 _ACEOF
9213 if { (ac_try="$ac_cpp conftest.$ac_ext"
9214 case "(($ac_try" in
9215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9216   *) ac_try_echo=$ac_try;;
9217 esac
9218 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9219   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9220   ac_status=$?
9221   grep -v '^ *+' conftest.er1 >conftest.err
9222   rm -f conftest.er1
9223   cat conftest.err >&5
9224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9225   (exit $ac_status); } >/dev/null && {
9226          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9227          test ! -s conftest.err
9228        }; then
9229   ac_header_preproc=yes
9230 else
9231   echo "$as_me: failed program was:" >&5
9232 sed 's/^/| /' conftest.$ac_ext >&5
9233
9234   ac_header_preproc=no
9235 fi
9236
9237 rm -f conftest.err conftest.$ac_ext
9238 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9239 echo "${ECHO_T}$ac_header_preproc" >&6; }
9240
9241 # So?  What about this header?
9242 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9243   yes:no: )
9244     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9245 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9246     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9247 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9248     ac_header_preproc=yes
9249     ;;
9250   no:yes:* )
9251     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9252 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9253     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9254 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9255     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9256 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9257     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9258 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9259     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9260 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9261     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9262 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9263     ( cat <<\_ASBOX
9264 ## ---------------------------------------- ##
9265 ## Report this to pgsql-bugs@postgresql.org ##
9266 ## ---------------------------------------- ##
9267 _ASBOX
9268      ) | sed "s/^/$as_me: WARNING:     /" >&2
9269     ;;
9270 esac
9271 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9272 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9273 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9274   echo $ECHO_N "(cached) $ECHO_C" >&6
9275 else
9276   eval "$as_ac_Header=\$ac_header_preproc"
9277 fi
9278 ac_res=`eval echo '${'$as_ac_Header'}'`
9279                { echo "$as_me:$LINENO: result: $ac_res" >&5
9280 echo "${ECHO_T}$ac_res" >&6; }
9281
9282 fi
9283 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9284   cat >>confdefs.h <<_ACEOF
9285 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9286 _ACEOF
9287
9288 else
9289
9290 for ac_header in history.h
9291 do
9292 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9293 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9294   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9295 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9296 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9297   echo $ECHO_N "(cached) $ECHO_C" >&6
9298 fi
9299 ac_res=`eval echo '${'$as_ac_Header'}'`
9300                { echo "$as_me:$LINENO: result: $ac_res" >&5
9301 echo "${ECHO_T}$ac_res" >&6; }
9302 else
9303   # Is the header compilable?
9304 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9305 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9306 cat >conftest.$ac_ext <<_ACEOF
9307 /* confdefs.h.  */
9308 _ACEOF
9309 cat confdefs.h >>conftest.$ac_ext
9310 cat >>conftest.$ac_ext <<_ACEOF
9311 /* end confdefs.h.  */
9312 $ac_includes_default
9313 #include <$ac_header>
9314 _ACEOF
9315 rm -f conftest.$ac_objext
9316 if { (ac_try="$ac_compile"
9317 case "(($ac_try" in
9318   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9319   *) ac_try_echo=$ac_try;;
9320 esac
9321 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9322   (eval "$ac_compile") 2>conftest.er1
9323   ac_status=$?
9324   grep -v '^ *+' conftest.er1 >conftest.err
9325   rm -f conftest.er1
9326   cat conftest.err >&5
9327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9328   (exit $ac_status); } && {
9329          test -z "$ac_c_werror_flag" ||
9330          test ! -s conftest.err
9331        } && test -s conftest.$ac_objext; then
9332   ac_header_compiler=yes
9333 else
9334   echo "$as_me: failed program was:" >&5
9335 sed 's/^/| /' conftest.$ac_ext >&5
9336
9337         ac_header_compiler=no
9338 fi
9339
9340 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9341 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9342 echo "${ECHO_T}$ac_header_compiler" >&6; }
9343
9344 # Is the header present?
9345 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9346 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9347 cat >conftest.$ac_ext <<_ACEOF
9348 /* confdefs.h.  */
9349 _ACEOF
9350 cat confdefs.h >>conftest.$ac_ext
9351 cat >>conftest.$ac_ext <<_ACEOF
9352 /* end confdefs.h.  */
9353 #include <$ac_header>
9354 _ACEOF
9355 if { (ac_try="$ac_cpp conftest.$ac_ext"
9356 case "(($ac_try" in
9357   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9358   *) ac_try_echo=$ac_try;;
9359 esac
9360 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9361   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9362   ac_status=$?
9363   grep -v '^ *+' conftest.er1 >conftest.err
9364   rm -f conftest.er1
9365   cat conftest.err >&5
9366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9367   (exit $ac_status); } >/dev/null && {
9368          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9369          test ! -s conftest.err
9370        }; then
9371   ac_header_preproc=yes
9372 else
9373   echo "$as_me: failed program was:" >&5
9374 sed 's/^/| /' conftest.$ac_ext >&5
9375
9376   ac_header_preproc=no
9377 fi
9378
9379 rm -f conftest.err conftest.$ac_ext
9380 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9381 echo "${ECHO_T}$ac_header_preproc" >&6; }
9382
9383 # So?  What about this header?
9384 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9385   yes:no: )
9386     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9387 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9388     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9389 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9390     ac_header_preproc=yes
9391     ;;
9392   no:yes:* )
9393     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9394 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9395     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9396 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9397     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9398 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9399     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9400 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9401     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9402 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9403     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9404 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9405     ( cat <<\_ASBOX
9406 ## ---------------------------------------- ##
9407 ## Report this to pgsql-bugs@postgresql.org ##
9408 ## ---------------------------------------- ##
9409 _ASBOX
9410      ) | sed "s/^/$as_me: WARNING:     /" >&2
9411     ;;
9412 esac
9413 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9414 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9415 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9416   echo $ECHO_N "(cached) $ECHO_C" >&6
9417 else
9418   eval "$as_ac_Header=\$ac_header_preproc"
9419 fi
9420 ac_res=`eval echo '${'$as_ac_Header'}'`
9421                { echo "$as_me:$LINENO: result: $ac_res" >&5
9422 echo "${ECHO_T}$ac_res" >&6; }
9423
9424 fi
9425 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9426   cat >>confdefs.h <<_ACEOF
9427 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9428 _ACEOF
9429
9430 else
9431   { { echo "$as_me:$LINENO: error: history header not found
9432 If you have readline already installed, see config.log for details on the
9433 failure.  It is possible the compiler isn't looking in the proper directory.
9434 Use --without-readline to disable readline support." >&5
9435 echo "$as_me: error: history header not found
9436 If you have readline already installed, see config.log for details on the
9437 failure.  It is possible the compiler isn't looking in the proper directory.
9438 Use --without-readline to disable readline support." >&2;}
9439    { (exit 1); exit 1; }; }
9440 fi
9441
9442 done
9443
9444 fi
9445
9446 done
9447
9448 fi
9449
9450 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
9451 # Some installations of libedit usurp /usr/include/readline/, which seems
9452 # bad practice, since in combined installations readline will have its headers
9453 # there.  We might have to resort to AC_EGREP checks to make sure we found
9454 # the proper header...
9455
9456 for ac_header in editline/readline.h
9457 do
9458 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9459 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9460   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9461 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9462 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9463   echo $ECHO_N "(cached) $ECHO_C" >&6
9464 fi
9465 ac_res=`eval echo '${'$as_ac_Header'}'`
9466                { echo "$as_me:$LINENO: result: $ac_res" >&5
9467 echo "${ECHO_T}$ac_res" >&6; }
9468 else
9469   # Is the header compilable?
9470 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9471 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9472 cat >conftest.$ac_ext <<_ACEOF
9473 /* confdefs.h.  */
9474 _ACEOF
9475 cat confdefs.h >>conftest.$ac_ext
9476 cat >>conftest.$ac_ext <<_ACEOF
9477 /* end confdefs.h.  */
9478 $ac_includes_default
9479 #include <$ac_header>
9480 _ACEOF
9481 rm -f conftest.$ac_objext
9482 if { (ac_try="$ac_compile"
9483 case "(($ac_try" in
9484   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9485   *) ac_try_echo=$ac_try;;
9486 esac
9487 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9488   (eval "$ac_compile") 2>conftest.er1
9489   ac_status=$?
9490   grep -v '^ *+' conftest.er1 >conftest.err
9491   rm -f conftest.er1
9492   cat conftest.err >&5
9493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9494   (exit $ac_status); } && {
9495          test -z "$ac_c_werror_flag" ||
9496          test ! -s conftest.err
9497        } && test -s conftest.$ac_objext; then
9498   ac_header_compiler=yes
9499 else
9500   echo "$as_me: failed program was:" >&5
9501 sed 's/^/| /' conftest.$ac_ext >&5
9502
9503         ac_header_compiler=no
9504 fi
9505
9506 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9507 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9508 echo "${ECHO_T}$ac_header_compiler" >&6; }
9509
9510 # Is the header present?
9511 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9512 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9513 cat >conftest.$ac_ext <<_ACEOF
9514 /* confdefs.h.  */
9515 _ACEOF
9516 cat confdefs.h >>conftest.$ac_ext
9517 cat >>conftest.$ac_ext <<_ACEOF
9518 /* end confdefs.h.  */
9519 #include <$ac_header>
9520 _ACEOF
9521 if { (ac_try="$ac_cpp conftest.$ac_ext"
9522 case "(($ac_try" in
9523   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9524   *) ac_try_echo=$ac_try;;
9525 esac
9526 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9527   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9528   ac_status=$?
9529   grep -v '^ *+' conftest.er1 >conftest.err
9530   rm -f conftest.er1
9531   cat conftest.err >&5
9532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9533   (exit $ac_status); } >/dev/null && {
9534          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9535          test ! -s conftest.err
9536        }; then
9537   ac_header_preproc=yes
9538 else
9539   echo "$as_me: failed program was:" >&5
9540 sed 's/^/| /' conftest.$ac_ext >&5
9541
9542   ac_header_preproc=no
9543 fi
9544
9545 rm -f conftest.err conftest.$ac_ext
9546 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9547 echo "${ECHO_T}$ac_header_preproc" >&6; }
9548
9549 # So?  What about this header?
9550 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9551   yes:no: )
9552     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9553 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9554     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9555 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9556     ac_header_preproc=yes
9557     ;;
9558   no:yes:* )
9559     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9560 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9561     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9562 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9563     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9564 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9565     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9566 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9567     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9568 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9569     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9570 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9571     ( cat <<\_ASBOX
9572 ## ---------------------------------------- ##
9573 ## Report this to pgsql-bugs@postgresql.org ##
9574 ## ---------------------------------------- ##
9575 _ASBOX
9576      ) | sed "s/^/$as_me: WARNING:     /" >&2
9577     ;;
9578 esac
9579 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9580 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9581 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9582   echo $ECHO_N "(cached) $ECHO_C" >&6
9583 else
9584   eval "$as_ac_Header=\$ac_header_preproc"
9585 fi
9586 ac_res=`eval echo '${'$as_ac_Header'}'`
9587                { echo "$as_me:$LINENO: result: $ac_res" >&5
9588 echo "${ECHO_T}$ac_res" >&6; }
9589
9590 fi
9591 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9592   cat >>confdefs.h <<_ACEOF
9593 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9594 _ACEOF
9595
9596 else
9597
9598 for ac_header in readline.h
9599 do
9600 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9601 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9602   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9603 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9604 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9605   echo $ECHO_N "(cached) $ECHO_C" >&6
9606 fi
9607 ac_res=`eval echo '${'$as_ac_Header'}'`
9608                { echo "$as_me:$LINENO: result: $ac_res" >&5
9609 echo "${ECHO_T}$ac_res" >&6; }
9610 else
9611   # Is the header compilable?
9612 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9613 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9614 cat >conftest.$ac_ext <<_ACEOF
9615 /* confdefs.h.  */
9616 _ACEOF
9617 cat confdefs.h >>conftest.$ac_ext
9618 cat >>conftest.$ac_ext <<_ACEOF
9619 /* end confdefs.h.  */
9620 $ac_includes_default
9621 #include <$ac_header>
9622 _ACEOF
9623 rm -f conftest.$ac_objext
9624 if { (ac_try="$ac_compile"
9625 case "(($ac_try" in
9626   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9627   *) ac_try_echo=$ac_try;;
9628 esac
9629 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9630   (eval "$ac_compile") 2>conftest.er1
9631   ac_status=$?
9632   grep -v '^ *+' conftest.er1 >conftest.err
9633   rm -f conftest.er1
9634   cat conftest.err >&5
9635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9636   (exit $ac_status); } && {
9637          test -z "$ac_c_werror_flag" ||
9638          test ! -s conftest.err
9639        } && test -s conftest.$ac_objext; then
9640   ac_header_compiler=yes
9641 else
9642   echo "$as_me: failed program was:" >&5
9643 sed 's/^/| /' conftest.$ac_ext >&5
9644
9645         ac_header_compiler=no
9646 fi
9647
9648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9649 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9650 echo "${ECHO_T}$ac_header_compiler" >&6; }
9651
9652 # Is the header present?
9653 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9654 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9655 cat >conftest.$ac_ext <<_ACEOF
9656 /* confdefs.h.  */
9657 _ACEOF
9658 cat confdefs.h >>conftest.$ac_ext
9659 cat >>conftest.$ac_ext <<_ACEOF
9660 /* end confdefs.h.  */
9661 #include <$ac_header>
9662 _ACEOF
9663 if { (ac_try="$ac_cpp conftest.$ac_ext"
9664 case "(($ac_try" in
9665   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9666   *) ac_try_echo=$ac_try;;
9667 esac
9668 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9669   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9670   ac_status=$?
9671   grep -v '^ *+' conftest.er1 >conftest.err
9672   rm -f conftest.er1
9673   cat conftest.err >&5
9674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9675   (exit $ac_status); } >/dev/null && {
9676          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9677          test ! -s conftest.err
9678        }; then
9679   ac_header_preproc=yes
9680 else
9681   echo "$as_me: failed program was:" >&5
9682 sed 's/^/| /' conftest.$ac_ext >&5
9683
9684   ac_header_preproc=no
9685 fi
9686
9687 rm -f conftest.err conftest.$ac_ext
9688 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9689 echo "${ECHO_T}$ac_header_preproc" >&6; }
9690
9691 # So?  What about this header?
9692 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9693   yes:no: )
9694     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9695 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9696     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9697 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9698     ac_header_preproc=yes
9699     ;;
9700   no:yes:* )
9701     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9702 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9703     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9704 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9705     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9706 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9707     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9708 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9709     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9710 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9711     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9712 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9713     ( cat <<\_ASBOX
9714 ## ---------------------------------------- ##
9715 ## Report this to pgsql-bugs@postgresql.org ##
9716 ## ---------------------------------------- ##
9717 _ASBOX
9718      ) | sed "s/^/$as_me: WARNING:     /" >&2
9719     ;;
9720 esac
9721 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9722 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9723 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9724   echo $ECHO_N "(cached) $ECHO_C" >&6
9725 else
9726   eval "$as_ac_Header=\$ac_header_preproc"
9727 fi
9728 ac_res=`eval echo '${'$as_ac_Header'}'`
9729                { echo "$as_me:$LINENO: result: $ac_res" >&5
9730 echo "${ECHO_T}$ac_res" >&6; }
9731
9732 fi
9733 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9734   cat >>confdefs.h <<_ACEOF
9735 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9736 _ACEOF
9737
9738 else
9739
9740 for ac_header in readline/readline.h
9741 do
9742 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9743 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9744   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9745 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9746 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9747   echo $ECHO_N "(cached) $ECHO_C" >&6
9748 fi
9749 ac_res=`eval echo '${'$as_ac_Header'}'`
9750                { echo "$as_me:$LINENO: result: $ac_res" >&5
9751 echo "${ECHO_T}$ac_res" >&6; }
9752 else
9753   # Is the header compilable?
9754 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9755 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9756 cat >conftest.$ac_ext <<_ACEOF
9757 /* confdefs.h.  */
9758 _ACEOF
9759 cat confdefs.h >>conftest.$ac_ext
9760 cat >>conftest.$ac_ext <<_ACEOF
9761 /* end confdefs.h.  */
9762 $ac_includes_default
9763 #include <$ac_header>
9764 _ACEOF
9765 rm -f conftest.$ac_objext
9766 if { (ac_try="$ac_compile"
9767 case "(($ac_try" in
9768   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9769   *) ac_try_echo=$ac_try;;
9770 esac
9771 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9772   (eval "$ac_compile") 2>conftest.er1
9773   ac_status=$?
9774   grep -v '^ *+' conftest.er1 >conftest.err
9775   rm -f conftest.er1
9776   cat conftest.err >&5
9777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9778   (exit $ac_status); } && {
9779          test -z "$ac_c_werror_flag" ||
9780          test ! -s conftest.err
9781        } && test -s conftest.$ac_objext; then
9782   ac_header_compiler=yes
9783 else
9784   echo "$as_me: failed program was:" >&5
9785 sed 's/^/| /' conftest.$ac_ext >&5
9786
9787         ac_header_compiler=no
9788 fi
9789
9790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9791 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9792 echo "${ECHO_T}$ac_header_compiler" >&6; }
9793
9794 # Is the header present?
9795 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9796 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9797 cat >conftest.$ac_ext <<_ACEOF
9798 /* confdefs.h.  */
9799 _ACEOF
9800 cat confdefs.h >>conftest.$ac_ext
9801 cat >>conftest.$ac_ext <<_ACEOF
9802 /* end confdefs.h.  */
9803 #include <$ac_header>
9804 _ACEOF
9805 if { (ac_try="$ac_cpp conftest.$ac_ext"
9806 case "(($ac_try" in
9807   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9808   *) ac_try_echo=$ac_try;;
9809 esac
9810 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9811   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9812   ac_status=$?
9813   grep -v '^ *+' conftest.er1 >conftest.err
9814   rm -f conftest.er1
9815   cat conftest.err >&5
9816   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9817   (exit $ac_status); } >/dev/null && {
9818          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9819          test ! -s conftest.err
9820        }; then
9821   ac_header_preproc=yes
9822 else
9823   echo "$as_me: failed program was:" >&5
9824 sed 's/^/| /' conftest.$ac_ext >&5
9825
9826   ac_header_preproc=no
9827 fi
9828
9829 rm -f conftest.err conftest.$ac_ext
9830 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9831 echo "${ECHO_T}$ac_header_preproc" >&6; }
9832
9833 # So?  What about this header?
9834 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9835   yes:no: )
9836     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9837 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9838     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9839 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9840     ac_header_preproc=yes
9841     ;;
9842   no:yes:* )
9843     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9844 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9845     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9846 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9847     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9848 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9849     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9850 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9851     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9852 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9853     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9854 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9855     ( cat <<\_ASBOX
9856 ## ---------------------------------------- ##
9857 ## Report this to pgsql-bugs@postgresql.org ##
9858 ## ---------------------------------------- ##
9859 _ASBOX
9860      ) | sed "s/^/$as_me: WARNING:     /" >&2
9861     ;;
9862 esac
9863 { echo "$as_me:$LINENO: checking for $ac_header" >&5
9864 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9865 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9866   echo $ECHO_N "(cached) $ECHO_C" >&6
9867 else
9868   eval "$as_ac_Header=\$ac_header_preproc"
9869 fi
9870 ac_res=`eval echo '${'$as_ac_Header'}'`
9871                { echo "$as_me:$LINENO: result: $ac_res" >&5
9872 echo "${ECHO_T}$ac_res" >&6; }
9873
9874 fi
9875 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9876   cat >>confdefs.h <<_ACEOF
9877 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9878 _ACEOF
9879
9880 else
9881   { { echo "$as_me:$LINENO: error: readline header not found
9882 If you have libedit already installed, see config.log for details on the
9883 failure.  It is possible the compiler isn't looking in the proper directory.
9884 Use --without-readline to disable libedit support." >&5
9885 echo "$as_me: error: readline header not found
9886 If you have libedit already installed, see config.log for details on the
9887 failure.  It is possible the compiler isn't looking in the proper directory.
9888 Use --without-readline to disable libedit support." >&2;}
9889    { (exit 1); exit 1; }; }
9890 fi
9891
9892 done
9893
9894 fi
9895
9896 done
9897
9898 fi
9899
9900 done
9901
9902 # Note: in a libedit installation, history.h is sometimes a dummy, and may
9903 # not be there at all.  Hence, don't complain if not found.  We must check
9904 # though, since in yet other versions it is an independent header.
9905
9906 for ac_header in editline/history.h
9907 do
9908 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9909 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9910   { echo "$as_me:$LINENO: checking for $ac_header" >&5
9911 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9912 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9913   echo $ECHO_N "(cached) $ECHO_C" >&6
9914 fi
9915 ac_res=`eval echo '${'$as_ac_Header'}'`
9916                { echo "$as_me:$LINENO: result: $ac_res" >&5
9917 echo "${ECHO_T}$ac_res" >&6; }
9918 else
9919   # Is the header compilable?
9920 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
9921 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9922 cat >conftest.$ac_ext <<_ACEOF
9923 /* confdefs.h.  */
9924 _ACEOF
9925 cat confdefs.h >>conftest.$ac_ext
9926 cat >>conftest.$ac_ext <<_ACEOF
9927 /* end confdefs.h.  */
9928 $ac_includes_default
9929 #include <$ac_header>
9930 _ACEOF
9931 rm -f conftest.$ac_objext
9932 if { (ac_try="$ac_compile"
9933 case "(($ac_try" in
9934   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9935   *) ac_try_echo=$ac_try;;
9936 esac
9937 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9938   (eval "$ac_compile") 2>conftest.er1
9939   ac_status=$?
9940   grep -v '^ *+' conftest.er1 >conftest.err
9941   rm -f conftest.er1
9942   cat conftest.err >&5
9943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9944   (exit $ac_status); } && {
9945          test -z "$ac_c_werror_flag" ||
9946          test ! -s conftest.err
9947        } && test -s conftest.$ac_objext; then
9948   ac_header_compiler=yes
9949 else
9950   echo "$as_me: failed program was:" >&5
9951 sed 's/^/| /' conftest.$ac_ext >&5
9952
9953         ac_header_compiler=no
9954 fi
9955
9956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9957 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9958 echo "${ECHO_T}$ac_header_compiler" >&6; }
9959
9960 # Is the header present?
9961 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
9962 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9963 cat >conftest.$ac_ext <<_ACEOF
9964 /* confdefs.h.  */
9965 _ACEOF
9966 cat confdefs.h >>conftest.$ac_ext
9967 cat >>conftest.$ac_ext <<_ACEOF
9968 /* end confdefs.h.  */
9969 #include <$ac_header>
9970 _ACEOF
9971 if { (ac_try="$ac_cpp conftest.$ac_ext"
9972 case "(($ac_try" in
9973   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9974   *) ac_try_echo=$ac_try;;
9975 esac
9976 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9977   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9978   ac_status=$?
9979   grep -v '^ *+' conftest.er1 >conftest.err
9980   rm -f conftest.er1
9981   cat conftest.err >&5
9982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9983   (exit $ac_status); } >/dev/null && {
9984          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9985          test ! -s conftest.err
9986        }; then
9987   ac_header_preproc=yes
9988 else
9989   echo "$as_me: failed program was:" >&5
9990 sed 's/^/| /' conftest.$ac_ext >&5
9991
9992   ac_header_preproc=no
9993 fi
9994
9995 rm -f conftest.err conftest.$ac_ext
9996 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9997 echo "${ECHO_T}$ac_header_preproc" >&6; }
9998
9999 # So?  What about this header?
10000 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10001   yes:no: )
10002     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10003 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10004     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10005 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10006     ac_header_preproc=yes
10007     ;;
10008   no:yes:* )
10009     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10010 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10011     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10012 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10013     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10014 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10015     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10016 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10017     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10018 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10019     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10020 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10021     ( cat <<\_ASBOX
10022 ## ---------------------------------------- ##
10023 ## Report this to pgsql-bugs@postgresql.org ##
10024 ## ---------------------------------------- ##
10025 _ASBOX
10026      ) | sed "s/^/$as_me: WARNING:     /" >&2
10027     ;;
10028 esac
10029 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10030 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10031 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10032   echo $ECHO_N "(cached) $ECHO_C" >&6
10033 else
10034   eval "$as_ac_Header=\$ac_header_preproc"
10035 fi
10036 ac_res=`eval echo '${'$as_ac_Header'}'`
10037                { echo "$as_me:$LINENO: result: $ac_res" >&5
10038 echo "${ECHO_T}$ac_res" >&6; }
10039
10040 fi
10041 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10042   cat >>confdefs.h <<_ACEOF
10043 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10044 _ACEOF
10045
10046 else
10047
10048 for ac_header in history.h
10049 do
10050 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10051 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10052   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10053 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10054 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10055   echo $ECHO_N "(cached) $ECHO_C" >&6
10056 fi
10057 ac_res=`eval echo '${'$as_ac_Header'}'`
10058                { echo "$as_me:$LINENO: result: $ac_res" >&5
10059 echo "${ECHO_T}$ac_res" >&6; }
10060 else
10061   # Is the header compilable?
10062 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10063 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10064 cat >conftest.$ac_ext <<_ACEOF
10065 /* confdefs.h.  */
10066 _ACEOF
10067 cat confdefs.h >>conftest.$ac_ext
10068 cat >>conftest.$ac_ext <<_ACEOF
10069 /* end confdefs.h.  */
10070 $ac_includes_default
10071 #include <$ac_header>
10072 _ACEOF
10073 rm -f conftest.$ac_objext
10074 if { (ac_try="$ac_compile"
10075 case "(($ac_try" in
10076   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10077   *) ac_try_echo=$ac_try;;
10078 esac
10079 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10080   (eval "$ac_compile") 2>conftest.er1
10081   ac_status=$?
10082   grep -v '^ *+' conftest.er1 >conftest.err
10083   rm -f conftest.er1
10084   cat conftest.err >&5
10085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10086   (exit $ac_status); } && {
10087          test -z "$ac_c_werror_flag" ||
10088          test ! -s conftest.err
10089        } && test -s conftest.$ac_objext; then
10090   ac_header_compiler=yes
10091 else
10092   echo "$as_me: failed program was:" >&5
10093 sed 's/^/| /' conftest.$ac_ext >&5
10094
10095         ac_header_compiler=no
10096 fi
10097
10098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10099 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10100 echo "${ECHO_T}$ac_header_compiler" >&6; }
10101
10102 # Is the header present?
10103 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10104 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10105 cat >conftest.$ac_ext <<_ACEOF
10106 /* confdefs.h.  */
10107 _ACEOF
10108 cat confdefs.h >>conftest.$ac_ext
10109 cat >>conftest.$ac_ext <<_ACEOF
10110 /* end confdefs.h.  */
10111 #include <$ac_header>
10112 _ACEOF
10113 if { (ac_try="$ac_cpp conftest.$ac_ext"
10114 case "(($ac_try" in
10115   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10116   *) ac_try_echo=$ac_try;;
10117 esac
10118 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10119   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10120   ac_status=$?
10121   grep -v '^ *+' conftest.er1 >conftest.err
10122   rm -f conftest.er1
10123   cat conftest.err >&5
10124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10125   (exit $ac_status); } >/dev/null && {
10126          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10127          test ! -s conftest.err
10128        }; then
10129   ac_header_preproc=yes
10130 else
10131   echo "$as_me: failed program was:" >&5
10132 sed 's/^/| /' conftest.$ac_ext >&5
10133
10134   ac_header_preproc=no
10135 fi
10136
10137 rm -f conftest.err conftest.$ac_ext
10138 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10139 echo "${ECHO_T}$ac_header_preproc" >&6; }
10140
10141 # So?  What about this header?
10142 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10143   yes:no: )
10144     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10145 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10146     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10147 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10148     ac_header_preproc=yes
10149     ;;
10150   no:yes:* )
10151     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10152 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10153     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10154 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10155     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10156 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10157     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10158 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10159     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10160 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10161     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10162 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10163     ( cat <<\_ASBOX
10164 ## ---------------------------------------- ##
10165 ## Report this to pgsql-bugs@postgresql.org ##
10166 ## ---------------------------------------- ##
10167 _ASBOX
10168      ) | sed "s/^/$as_me: WARNING:     /" >&2
10169     ;;
10170 esac
10171 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10172 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10173 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10174   echo $ECHO_N "(cached) $ECHO_C" >&6
10175 else
10176   eval "$as_ac_Header=\$ac_header_preproc"
10177 fi
10178 ac_res=`eval echo '${'$as_ac_Header'}'`
10179                { echo "$as_me:$LINENO: result: $ac_res" >&5
10180 echo "${ECHO_T}$ac_res" >&6; }
10181
10182 fi
10183 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10184   cat >>confdefs.h <<_ACEOF
10185 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10186 _ACEOF
10187
10188 else
10189
10190 for ac_header in readline/history.h
10191 do
10192 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10193 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10194   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10195 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10196 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10197   echo $ECHO_N "(cached) $ECHO_C" >&6
10198 fi
10199 ac_res=`eval echo '${'$as_ac_Header'}'`
10200                { echo "$as_me:$LINENO: result: $ac_res" >&5
10201 echo "${ECHO_T}$ac_res" >&6; }
10202 else
10203   # Is the header compilable?
10204 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10205 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10206 cat >conftest.$ac_ext <<_ACEOF
10207 /* confdefs.h.  */
10208 _ACEOF
10209 cat confdefs.h >>conftest.$ac_ext
10210 cat >>conftest.$ac_ext <<_ACEOF
10211 /* end confdefs.h.  */
10212 $ac_includes_default
10213 #include <$ac_header>
10214 _ACEOF
10215 rm -f conftest.$ac_objext
10216 if { (ac_try="$ac_compile"
10217 case "(($ac_try" in
10218   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10219   *) ac_try_echo=$ac_try;;
10220 esac
10221 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10222   (eval "$ac_compile") 2>conftest.er1
10223   ac_status=$?
10224   grep -v '^ *+' conftest.er1 >conftest.err
10225   rm -f conftest.er1
10226   cat conftest.err >&5
10227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10228   (exit $ac_status); } && {
10229          test -z "$ac_c_werror_flag" ||
10230          test ! -s conftest.err
10231        } && test -s conftest.$ac_objext; then
10232   ac_header_compiler=yes
10233 else
10234   echo "$as_me: failed program was:" >&5
10235 sed 's/^/| /' conftest.$ac_ext >&5
10236
10237         ac_header_compiler=no
10238 fi
10239
10240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10241 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10242 echo "${ECHO_T}$ac_header_compiler" >&6; }
10243
10244 # Is the header present?
10245 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10246 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10247 cat >conftest.$ac_ext <<_ACEOF
10248 /* confdefs.h.  */
10249 _ACEOF
10250 cat confdefs.h >>conftest.$ac_ext
10251 cat >>conftest.$ac_ext <<_ACEOF
10252 /* end confdefs.h.  */
10253 #include <$ac_header>
10254 _ACEOF
10255 if { (ac_try="$ac_cpp conftest.$ac_ext"
10256 case "(($ac_try" in
10257   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10258   *) ac_try_echo=$ac_try;;
10259 esac
10260 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10261   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10262   ac_status=$?
10263   grep -v '^ *+' conftest.er1 >conftest.err
10264   rm -f conftest.er1
10265   cat conftest.err >&5
10266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10267   (exit $ac_status); } >/dev/null && {
10268          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10269          test ! -s conftest.err
10270        }; then
10271   ac_header_preproc=yes
10272 else
10273   echo "$as_me: failed program was:" >&5
10274 sed 's/^/| /' conftest.$ac_ext >&5
10275
10276   ac_header_preproc=no
10277 fi
10278
10279 rm -f conftest.err conftest.$ac_ext
10280 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10281 echo "${ECHO_T}$ac_header_preproc" >&6; }
10282
10283 # So?  What about this header?
10284 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10285   yes:no: )
10286     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10287 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10288     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10289 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10290     ac_header_preproc=yes
10291     ;;
10292   no:yes:* )
10293     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10294 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10295     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10296 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10297     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10298 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10299     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10300 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10301     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10302 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10303     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10304 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10305     ( cat <<\_ASBOX
10306 ## ---------------------------------------- ##
10307 ## Report this to pgsql-bugs@postgresql.org ##
10308 ## ---------------------------------------- ##
10309 _ASBOX
10310      ) | sed "s/^/$as_me: WARNING:     /" >&2
10311     ;;
10312 esac
10313 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10314 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10315 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10316   echo $ECHO_N "(cached) $ECHO_C" >&6
10317 else
10318   eval "$as_ac_Header=\$ac_header_preproc"
10319 fi
10320 ac_res=`eval echo '${'$as_ac_Header'}'`
10321                { echo "$as_me:$LINENO: result: $ac_res" >&5
10322 echo "${ECHO_T}$ac_res" >&6; }
10323
10324 fi
10325 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10326   cat >>confdefs.h <<_ACEOF
10327 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10328 _ACEOF
10329
10330 fi
10331
10332 done
10333
10334 fi
10335
10336 done
10337
10338 fi
10339
10340 done
10341
10342 fi
10343
10344 if test "$with_zlib" = yes; then
10345   if test "${ac_cv_header_zlib_h+set}" = set; then
10346   { echo "$as_me:$LINENO: checking for zlib.h" >&5
10347 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6; }
10348 if test "${ac_cv_header_zlib_h+set}" = set; then
10349   echo $ECHO_N "(cached) $ECHO_C" >&6
10350 fi
10351 { echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
10352 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6; }
10353 else
10354   # Is the header compilable?
10355 { echo "$as_me:$LINENO: checking zlib.h usability" >&5
10356 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6; }
10357 cat >conftest.$ac_ext <<_ACEOF
10358 /* confdefs.h.  */
10359 _ACEOF
10360 cat confdefs.h >>conftest.$ac_ext
10361 cat >>conftest.$ac_ext <<_ACEOF
10362 /* end confdefs.h.  */
10363 $ac_includes_default
10364 #include <zlib.h>
10365 _ACEOF
10366 rm -f conftest.$ac_objext
10367 if { (ac_try="$ac_compile"
10368 case "(($ac_try" in
10369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10370   *) ac_try_echo=$ac_try;;
10371 esac
10372 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10373   (eval "$ac_compile") 2>conftest.er1
10374   ac_status=$?
10375   grep -v '^ *+' conftest.er1 >conftest.err
10376   rm -f conftest.er1
10377   cat conftest.err >&5
10378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10379   (exit $ac_status); } && {
10380          test -z "$ac_c_werror_flag" ||
10381          test ! -s conftest.err
10382        } && test -s conftest.$ac_objext; then
10383   ac_header_compiler=yes
10384 else
10385   echo "$as_me: failed program was:" >&5
10386 sed 's/^/| /' conftest.$ac_ext >&5
10387
10388         ac_header_compiler=no
10389 fi
10390
10391 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10392 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10393 echo "${ECHO_T}$ac_header_compiler" >&6; }
10394
10395 # Is the header present?
10396 { echo "$as_me:$LINENO: checking zlib.h presence" >&5
10397 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6; }
10398 cat >conftest.$ac_ext <<_ACEOF
10399 /* confdefs.h.  */
10400 _ACEOF
10401 cat confdefs.h >>conftest.$ac_ext
10402 cat >>conftest.$ac_ext <<_ACEOF
10403 /* end confdefs.h.  */
10404 #include <zlib.h>
10405 _ACEOF
10406 if { (ac_try="$ac_cpp conftest.$ac_ext"
10407 case "(($ac_try" in
10408   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10409   *) ac_try_echo=$ac_try;;
10410 esac
10411 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10412   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10413   ac_status=$?
10414   grep -v '^ *+' conftest.er1 >conftest.err
10415   rm -f conftest.er1
10416   cat conftest.err >&5
10417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10418   (exit $ac_status); } >/dev/null && {
10419          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10420          test ! -s conftest.err
10421        }; then
10422   ac_header_preproc=yes
10423 else
10424   echo "$as_me: failed program was:" >&5
10425 sed 's/^/| /' conftest.$ac_ext >&5
10426
10427   ac_header_preproc=no
10428 fi
10429
10430 rm -f conftest.err conftest.$ac_ext
10431 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10432 echo "${ECHO_T}$ac_header_preproc" >&6; }
10433
10434 # So?  What about this header?
10435 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10436   yes:no: )
10437     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
10438 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10439     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
10440 echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
10441     ac_header_preproc=yes
10442     ;;
10443   no:yes:* )
10444     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
10445 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
10446     { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
10447 echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
10448     { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
10449 echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
10450     { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
10451 echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10452     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
10453 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
10454     { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
10455 echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
10456     ( cat <<\_ASBOX
10457 ## ---------------------------------------- ##
10458 ## Report this to pgsql-bugs@postgresql.org ##
10459 ## ---------------------------------------- ##
10460 _ASBOX
10461      ) | sed "s/^/$as_me: WARNING:     /" >&2
10462     ;;
10463 esac
10464 { echo "$as_me:$LINENO: checking for zlib.h" >&5
10465 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6; }
10466 if test "${ac_cv_header_zlib_h+set}" = set; then
10467   echo $ECHO_N "(cached) $ECHO_C" >&6
10468 else
10469   ac_cv_header_zlib_h=$ac_header_preproc
10470 fi
10471 { echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
10472 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6; }
10473
10474 fi
10475 if test $ac_cv_header_zlib_h = yes; then
10476   :
10477 else
10478   { { echo "$as_me:$LINENO: error: zlib header not found
10479 If you have zlib already installed, see config.log for details on the
10480 failure.  It is possible the compiler isn't looking in the proper directory.
10481 Use --without-zlib to disable zlib support." >&5
10482 echo "$as_me: error: zlib header not found
10483 If you have zlib already installed, see config.log for details on the
10484 failure.  It is possible the compiler isn't looking in the proper directory.
10485 Use --without-zlib to disable zlib support." >&2;}
10486    { (exit 1); exit 1; }; }
10487 fi
10488
10489
10490 fi
10491
10492 if test "$with_gssapi" = yes ; then
10493
10494 for ac_header in gssapi/gssapi.h
10495 do
10496 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10497 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10498   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10499 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10500 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10501   echo $ECHO_N "(cached) $ECHO_C" >&6
10502 fi
10503 ac_res=`eval echo '${'$as_ac_Header'}'`
10504                { echo "$as_me:$LINENO: result: $ac_res" >&5
10505 echo "${ECHO_T}$ac_res" >&6; }
10506 else
10507   # Is the header compilable?
10508 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10509 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10510 cat >conftest.$ac_ext <<_ACEOF
10511 /* confdefs.h.  */
10512 _ACEOF
10513 cat confdefs.h >>conftest.$ac_ext
10514 cat >>conftest.$ac_ext <<_ACEOF
10515 /* end confdefs.h.  */
10516 $ac_includes_default
10517 #include <$ac_header>
10518 _ACEOF
10519 rm -f conftest.$ac_objext
10520 if { (ac_try="$ac_compile"
10521 case "(($ac_try" in
10522   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10523   *) ac_try_echo=$ac_try;;
10524 esac
10525 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10526   (eval "$ac_compile") 2>conftest.er1
10527   ac_status=$?
10528   grep -v '^ *+' conftest.er1 >conftest.err
10529   rm -f conftest.er1
10530   cat conftest.err >&5
10531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10532   (exit $ac_status); } && {
10533          test -z "$ac_c_werror_flag" ||
10534          test ! -s conftest.err
10535        } && test -s conftest.$ac_objext; then
10536   ac_header_compiler=yes
10537 else
10538   echo "$as_me: failed program was:" >&5
10539 sed 's/^/| /' conftest.$ac_ext >&5
10540
10541         ac_header_compiler=no
10542 fi
10543
10544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10545 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10546 echo "${ECHO_T}$ac_header_compiler" >&6; }
10547
10548 # Is the header present?
10549 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10550 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10551 cat >conftest.$ac_ext <<_ACEOF
10552 /* confdefs.h.  */
10553 _ACEOF
10554 cat confdefs.h >>conftest.$ac_ext
10555 cat >>conftest.$ac_ext <<_ACEOF
10556 /* end confdefs.h.  */
10557 #include <$ac_header>
10558 _ACEOF
10559 if { (ac_try="$ac_cpp conftest.$ac_ext"
10560 case "(($ac_try" in
10561   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10562   *) ac_try_echo=$ac_try;;
10563 esac
10564 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10565   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10566   ac_status=$?
10567   grep -v '^ *+' conftest.er1 >conftest.err
10568   rm -f conftest.er1
10569   cat conftest.err >&5
10570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10571   (exit $ac_status); } >/dev/null && {
10572          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10573          test ! -s conftest.err
10574        }; then
10575   ac_header_preproc=yes
10576 else
10577   echo "$as_me: failed program was:" >&5
10578 sed 's/^/| /' conftest.$ac_ext >&5
10579
10580   ac_header_preproc=no
10581 fi
10582
10583 rm -f conftest.err conftest.$ac_ext
10584 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10585 echo "${ECHO_T}$ac_header_preproc" >&6; }
10586
10587 # So?  What about this header?
10588 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10589   yes:no: )
10590     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10591 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10592     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10593 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10594     ac_header_preproc=yes
10595     ;;
10596   no:yes:* )
10597     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10598 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10599     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10600 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10601     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10602 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10603     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10604 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10605     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10606 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10607     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10608 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10609     ( cat <<\_ASBOX
10610 ## ---------------------------------------- ##
10611 ## Report this to pgsql-bugs@postgresql.org ##
10612 ## ---------------------------------------- ##
10613 _ASBOX
10614      ) | sed "s/^/$as_me: WARNING:     /" >&2
10615     ;;
10616 esac
10617 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10618 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10619 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10620   echo $ECHO_N "(cached) $ECHO_C" >&6
10621 else
10622   eval "$as_ac_Header=\$ac_header_preproc"
10623 fi
10624 ac_res=`eval echo '${'$as_ac_Header'}'`
10625                { echo "$as_me:$LINENO: result: $ac_res" >&5
10626 echo "${ECHO_T}$ac_res" >&6; }
10627
10628 fi
10629 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10630   cat >>confdefs.h <<_ACEOF
10631 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10632 _ACEOF
10633
10634 else
10635
10636 for ac_header in gssapi.h
10637 do
10638 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10639 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10640   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10641 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10642 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10643   echo $ECHO_N "(cached) $ECHO_C" >&6
10644 fi
10645 ac_res=`eval echo '${'$as_ac_Header'}'`
10646                { echo "$as_me:$LINENO: result: $ac_res" >&5
10647 echo "${ECHO_T}$ac_res" >&6; }
10648 else
10649   # Is the header compilable?
10650 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10651 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10652 cat >conftest.$ac_ext <<_ACEOF
10653 /* confdefs.h.  */
10654 _ACEOF
10655 cat confdefs.h >>conftest.$ac_ext
10656 cat >>conftest.$ac_ext <<_ACEOF
10657 /* end confdefs.h.  */
10658 $ac_includes_default
10659 #include <$ac_header>
10660 _ACEOF
10661 rm -f conftest.$ac_objext
10662 if { (ac_try="$ac_compile"
10663 case "(($ac_try" in
10664   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10665   *) ac_try_echo=$ac_try;;
10666 esac
10667 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10668   (eval "$ac_compile") 2>conftest.er1
10669   ac_status=$?
10670   grep -v '^ *+' conftest.er1 >conftest.err
10671   rm -f conftest.er1
10672   cat conftest.err >&5
10673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10674   (exit $ac_status); } && {
10675          test -z "$ac_c_werror_flag" ||
10676          test ! -s conftest.err
10677        } && test -s conftest.$ac_objext; then
10678   ac_header_compiler=yes
10679 else
10680   echo "$as_me: failed program was:" >&5
10681 sed 's/^/| /' conftest.$ac_ext >&5
10682
10683         ac_header_compiler=no
10684 fi
10685
10686 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10687 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10688 echo "${ECHO_T}$ac_header_compiler" >&6; }
10689
10690 # Is the header present?
10691 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10692 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10693 cat >conftest.$ac_ext <<_ACEOF
10694 /* confdefs.h.  */
10695 _ACEOF
10696 cat confdefs.h >>conftest.$ac_ext
10697 cat >>conftest.$ac_ext <<_ACEOF
10698 /* end confdefs.h.  */
10699 #include <$ac_header>
10700 _ACEOF
10701 if { (ac_try="$ac_cpp conftest.$ac_ext"
10702 case "(($ac_try" in
10703   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10704   *) ac_try_echo=$ac_try;;
10705 esac
10706 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10707   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10708   ac_status=$?
10709   grep -v '^ *+' conftest.er1 >conftest.err
10710   rm -f conftest.er1
10711   cat conftest.err >&5
10712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10713   (exit $ac_status); } >/dev/null && {
10714          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10715          test ! -s conftest.err
10716        }; then
10717   ac_header_preproc=yes
10718 else
10719   echo "$as_me: failed program was:" >&5
10720 sed 's/^/| /' conftest.$ac_ext >&5
10721
10722   ac_header_preproc=no
10723 fi
10724
10725 rm -f conftest.err conftest.$ac_ext
10726 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10727 echo "${ECHO_T}$ac_header_preproc" >&6; }
10728
10729 # So?  What about this header?
10730 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10731   yes:no: )
10732     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10733 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10734     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10735 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10736     ac_header_preproc=yes
10737     ;;
10738   no:yes:* )
10739     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10740 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10741     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10742 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10743     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10744 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10745     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10746 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10747     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10748 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10749     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10750 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10751     ( cat <<\_ASBOX
10752 ## ---------------------------------------- ##
10753 ## Report this to pgsql-bugs@postgresql.org ##
10754 ## ---------------------------------------- ##
10755 _ASBOX
10756      ) | sed "s/^/$as_me: WARNING:     /" >&2
10757     ;;
10758 esac
10759 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10760 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10761 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10762   echo $ECHO_N "(cached) $ECHO_C" >&6
10763 else
10764   eval "$as_ac_Header=\$ac_header_preproc"
10765 fi
10766 ac_res=`eval echo '${'$as_ac_Header'}'`
10767                { echo "$as_me:$LINENO: result: $ac_res" >&5
10768 echo "${ECHO_T}$ac_res" >&6; }
10769
10770 fi
10771 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10772   cat >>confdefs.h <<_ACEOF
10773 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10774 _ACEOF
10775
10776 else
10777   { { echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
10778 echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
10779    { (exit 1); exit 1; }; }
10780 fi
10781
10782 done
10783
10784 fi
10785
10786 done
10787
10788 fi
10789
10790 if test "$with_krb5" = yes ; then
10791   if test "${ac_cv_header_krb5_h+set}" = set; then
10792   { echo "$as_me:$LINENO: checking for krb5.h" >&5
10793 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6; }
10794 if test "${ac_cv_header_krb5_h+set}" = set; then
10795   echo $ECHO_N "(cached) $ECHO_C" >&6
10796 fi
10797 { echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
10798 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6; }
10799 else
10800   # Is the header compilable?
10801 { echo "$as_me:$LINENO: checking krb5.h usability" >&5
10802 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6; }
10803 cat >conftest.$ac_ext <<_ACEOF
10804 /* confdefs.h.  */
10805 _ACEOF
10806 cat confdefs.h >>conftest.$ac_ext
10807 cat >>conftest.$ac_ext <<_ACEOF
10808 /* end confdefs.h.  */
10809 $ac_includes_default
10810 #include <krb5.h>
10811 _ACEOF
10812 rm -f conftest.$ac_objext
10813 if { (ac_try="$ac_compile"
10814 case "(($ac_try" in
10815   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10816   *) ac_try_echo=$ac_try;;
10817 esac
10818 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10819   (eval "$ac_compile") 2>conftest.er1
10820   ac_status=$?
10821   grep -v '^ *+' conftest.er1 >conftest.err
10822   rm -f conftest.er1
10823   cat conftest.err >&5
10824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10825   (exit $ac_status); } && {
10826          test -z "$ac_c_werror_flag" ||
10827          test ! -s conftest.err
10828        } && test -s conftest.$ac_objext; then
10829   ac_header_compiler=yes
10830 else
10831   echo "$as_me: failed program was:" >&5
10832 sed 's/^/| /' conftest.$ac_ext >&5
10833
10834         ac_header_compiler=no
10835 fi
10836
10837 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10838 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10839 echo "${ECHO_T}$ac_header_compiler" >&6; }
10840
10841 # Is the header present?
10842 { echo "$as_me:$LINENO: checking krb5.h presence" >&5
10843 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6; }
10844 cat >conftest.$ac_ext <<_ACEOF
10845 /* confdefs.h.  */
10846 _ACEOF
10847 cat confdefs.h >>conftest.$ac_ext
10848 cat >>conftest.$ac_ext <<_ACEOF
10849 /* end confdefs.h.  */
10850 #include <krb5.h>
10851 _ACEOF
10852 if { (ac_try="$ac_cpp conftest.$ac_ext"
10853 case "(($ac_try" in
10854   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10855   *) ac_try_echo=$ac_try;;
10856 esac
10857 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10858   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10859   ac_status=$?
10860   grep -v '^ *+' conftest.er1 >conftest.err
10861   rm -f conftest.er1
10862   cat conftest.err >&5
10863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10864   (exit $ac_status); } >/dev/null && {
10865          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10866          test ! -s conftest.err
10867        }; then
10868   ac_header_preproc=yes
10869 else
10870   echo "$as_me: failed program was:" >&5
10871 sed 's/^/| /' conftest.$ac_ext >&5
10872
10873   ac_header_preproc=no
10874 fi
10875
10876 rm -f conftest.err conftest.$ac_ext
10877 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10878 echo "${ECHO_T}$ac_header_preproc" >&6; }
10879
10880 # So?  What about this header?
10881 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10882   yes:no: )
10883     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
10884 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10885     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
10886 echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
10887     ac_header_preproc=yes
10888     ;;
10889   no:yes:* )
10890     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
10891 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
10892     { echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
10893 echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
10894     { echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
10895 echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
10896     { echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
10897 echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10898     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
10899 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
10900     { echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
10901 echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
10902     ( cat <<\_ASBOX
10903 ## ---------------------------------------- ##
10904 ## Report this to pgsql-bugs@postgresql.org ##
10905 ## ---------------------------------------- ##
10906 _ASBOX
10907      ) | sed "s/^/$as_me: WARNING:     /" >&2
10908     ;;
10909 esac
10910 { echo "$as_me:$LINENO: checking for krb5.h" >&5
10911 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6; }
10912 if test "${ac_cv_header_krb5_h+set}" = set; then
10913   echo $ECHO_N "(cached) $ECHO_C" >&6
10914 else
10915   ac_cv_header_krb5_h=$ac_header_preproc
10916 fi
10917 { echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
10918 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6; }
10919
10920 fi
10921 if test $ac_cv_header_krb5_h = yes; then
10922   :
10923 else
10924   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
10925 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
10926    { (exit 1); exit 1; }; }
10927 fi
10928
10929
10930 fi
10931
10932 if test "$with_openssl" = yes ; then
10933   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
10934   { echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
10935 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6; }
10936 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
10937   echo $ECHO_N "(cached) $ECHO_C" >&6
10938 fi
10939 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
10940 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6; }
10941 else
10942   # Is the header compilable?
10943 { echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
10944 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6; }
10945 cat >conftest.$ac_ext <<_ACEOF
10946 /* confdefs.h.  */
10947 _ACEOF
10948 cat confdefs.h >>conftest.$ac_ext
10949 cat >>conftest.$ac_ext <<_ACEOF
10950 /* end confdefs.h.  */
10951 $ac_includes_default
10952 #include <openssl/ssl.h>
10953 _ACEOF
10954 rm -f conftest.$ac_objext
10955 if { (ac_try="$ac_compile"
10956 case "(($ac_try" in
10957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10958   *) ac_try_echo=$ac_try;;
10959 esac
10960 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10961   (eval "$ac_compile") 2>conftest.er1
10962   ac_status=$?
10963   grep -v '^ *+' conftest.er1 >conftest.err
10964   rm -f conftest.er1
10965   cat conftest.err >&5
10966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10967   (exit $ac_status); } && {
10968          test -z "$ac_c_werror_flag" ||
10969          test ! -s conftest.err
10970        } && test -s conftest.$ac_objext; then
10971   ac_header_compiler=yes
10972 else
10973   echo "$as_me: failed program was:" >&5
10974 sed 's/^/| /' conftest.$ac_ext >&5
10975
10976         ac_header_compiler=no
10977 fi
10978
10979 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10980 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10981 echo "${ECHO_T}$ac_header_compiler" >&6; }
10982
10983 # Is the header present?
10984 { echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
10985 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6; }
10986 cat >conftest.$ac_ext <<_ACEOF
10987 /* confdefs.h.  */
10988 _ACEOF
10989 cat confdefs.h >>conftest.$ac_ext
10990 cat >>conftest.$ac_ext <<_ACEOF
10991 /* end confdefs.h.  */
10992 #include <openssl/ssl.h>
10993 _ACEOF
10994 if { (ac_try="$ac_cpp conftest.$ac_ext"
10995 case "(($ac_try" in
10996   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10997   *) ac_try_echo=$ac_try;;
10998 esac
10999 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11000   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11001   ac_status=$?
11002   grep -v '^ *+' conftest.er1 >conftest.err
11003   rm -f conftest.er1
11004   cat conftest.err >&5
11005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11006   (exit $ac_status); } >/dev/null && {
11007          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11008          test ! -s conftest.err
11009        }; then
11010   ac_header_preproc=yes
11011 else
11012   echo "$as_me: failed program was:" >&5
11013 sed 's/^/| /' conftest.$ac_ext >&5
11014
11015   ac_header_preproc=no
11016 fi
11017
11018 rm -f conftest.err conftest.$ac_ext
11019 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11020 echo "${ECHO_T}$ac_header_preproc" >&6; }
11021
11022 # So?  What about this header?
11023 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11024   yes:no: )
11025     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
11026 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11027     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
11028 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
11029     ac_header_preproc=yes
11030     ;;
11031   no:yes:* )
11032     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
11033 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
11034     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
11035 echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
11036     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
11037 echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
11038     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
11039 echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11040     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
11041 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
11042     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
11043 echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
11044     ( cat <<\_ASBOX
11045 ## ---------------------------------------- ##
11046 ## Report this to pgsql-bugs@postgresql.org ##
11047 ## ---------------------------------------- ##
11048 _ASBOX
11049      ) | sed "s/^/$as_me: WARNING:     /" >&2
11050     ;;
11051 esac
11052 { echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
11053 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6; }
11054 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
11055   echo $ECHO_N "(cached) $ECHO_C" >&6
11056 else
11057   ac_cv_header_openssl_ssl_h=$ac_header_preproc
11058 fi
11059 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
11060 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6; }
11061
11062 fi
11063 if test $ac_cv_header_openssl_ssl_h = yes; then
11064   :
11065 else
11066   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
11067 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
11068    { (exit 1); exit 1; }; }
11069 fi
11070
11071
11072   if test "${ac_cv_header_openssl_err_h+set}" = set; then
11073   { echo "$as_me:$LINENO: checking for openssl/err.h" >&5
11074 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6; }
11075 if test "${ac_cv_header_openssl_err_h+set}" = set; then
11076   echo $ECHO_N "(cached) $ECHO_C" >&6
11077 fi
11078 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
11079 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6; }
11080 else
11081   # Is the header compilable?
11082 { echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
11083 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6; }
11084 cat >conftest.$ac_ext <<_ACEOF
11085 /* confdefs.h.  */
11086 _ACEOF
11087 cat confdefs.h >>conftest.$ac_ext
11088 cat >>conftest.$ac_ext <<_ACEOF
11089 /* end confdefs.h.  */
11090 $ac_includes_default
11091 #include <openssl/err.h>
11092 _ACEOF
11093 rm -f conftest.$ac_objext
11094 if { (ac_try="$ac_compile"
11095 case "(($ac_try" in
11096   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11097   *) ac_try_echo=$ac_try;;
11098 esac
11099 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11100   (eval "$ac_compile") 2>conftest.er1
11101   ac_status=$?
11102   grep -v '^ *+' conftest.er1 >conftest.err
11103   rm -f conftest.er1
11104   cat conftest.err >&5
11105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11106   (exit $ac_status); } && {
11107          test -z "$ac_c_werror_flag" ||
11108          test ! -s conftest.err
11109        } && test -s conftest.$ac_objext; then
11110   ac_header_compiler=yes
11111 else
11112   echo "$as_me: failed program was:" >&5
11113 sed 's/^/| /' conftest.$ac_ext >&5
11114
11115         ac_header_compiler=no
11116 fi
11117
11118 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11119 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11120 echo "${ECHO_T}$ac_header_compiler" >&6; }
11121
11122 # Is the header present?
11123 { echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
11124 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6; }
11125 cat >conftest.$ac_ext <<_ACEOF
11126 /* confdefs.h.  */
11127 _ACEOF
11128 cat confdefs.h >>conftest.$ac_ext
11129 cat >>conftest.$ac_ext <<_ACEOF
11130 /* end confdefs.h.  */
11131 #include <openssl/err.h>
11132 _ACEOF
11133 if { (ac_try="$ac_cpp conftest.$ac_ext"
11134 case "(($ac_try" in
11135   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11136   *) ac_try_echo=$ac_try;;
11137 esac
11138 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11139   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11140   ac_status=$?
11141   grep -v '^ *+' conftest.er1 >conftest.err
11142   rm -f conftest.er1
11143   cat conftest.err >&5
11144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11145   (exit $ac_status); } >/dev/null && {
11146          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11147          test ! -s conftest.err
11148        }; then
11149   ac_header_preproc=yes
11150 else
11151   echo "$as_me: failed program was:" >&5
11152 sed 's/^/| /' conftest.$ac_ext >&5
11153
11154   ac_header_preproc=no
11155 fi
11156
11157 rm -f conftest.err conftest.$ac_ext
11158 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11159 echo "${ECHO_T}$ac_header_preproc" >&6; }
11160
11161 # So?  What about this header?
11162 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11163   yes:no: )
11164     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
11165 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11166     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
11167 echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
11168     ac_header_preproc=yes
11169     ;;
11170   no:yes:* )
11171     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
11172 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
11173     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
11174 echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
11175     { echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
11176 echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
11177     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
11178 echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11179     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
11180 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
11181     { echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
11182 echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
11183     ( cat <<\_ASBOX
11184 ## ---------------------------------------- ##
11185 ## Report this to pgsql-bugs@postgresql.org ##
11186 ## ---------------------------------------- ##
11187 _ASBOX
11188      ) | sed "s/^/$as_me: WARNING:     /" >&2
11189     ;;
11190 esac
11191 { echo "$as_me:$LINENO: checking for openssl/err.h" >&5
11192 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6; }
11193 if test "${ac_cv_header_openssl_err_h+set}" = set; then
11194   echo $ECHO_N "(cached) $ECHO_C" >&6
11195 else
11196   ac_cv_header_openssl_err_h=$ac_header_preproc
11197 fi
11198 { echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
11199 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6; }
11200
11201 fi
11202 if test $ac_cv_header_openssl_err_h = yes; then
11203   :
11204 else
11205   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
11206 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
11207    { (exit 1); exit 1; }; }
11208 fi
11209
11210
11211
11212 for ac_func in ERR_set_mark
11213 do
11214 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11215 { echo "$as_me:$LINENO: checking for $ac_func" >&5
11216 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11217 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11218   echo $ECHO_N "(cached) $ECHO_C" >&6
11219 else
11220   cat >conftest.$ac_ext <<_ACEOF
11221 /* confdefs.h.  */
11222 _ACEOF
11223 cat confdefs.h >>conftest.$ac_ext
11224 cat >>conftest.$ac_ext <<_ACEOF
11225 /* end confdefs.h.  */
11226 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11227    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11228 #define $ac_func innocuous_$ac_func
11229
11230 /* System header to define __stub macros and hopefully few prototypes,
11231     which can conflict with char $ac_func (); below.
11232     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11233     <limits.h> exists even on freestanding compilers.  */
11234
11235 #ifdef __STDC__
11236 # include <limits.h>
11237 #else
11238 # include <assert.h>
11239 #endif
11240
11241 #undef $ac_func
11242
11243 /* Override any GCC internal prototype to avoid an error.
11244    Use char because int might match the return type of a GCC
11245    builtin and then its argument prototype would still apply.  */
11246 #ifdef __cplusplus
11247 extern "C"
11248 #endif
11249 char $ac_func ();
11250 /* The GNU C library defines this for functions which it implements
11251     to always fail with ENOSYS.  Some functions are actually named
11252     something starting with __ and the normal name is an alias.  */
11253 #if defined __stub_$ac_func || defined __stub___$ac_func
11254 choke me
11255 #endif
11256
11257 int
11258 main ()
11259 {
11260 return $ac_func ();
11261   ;
11262   return 0;
11263 }
11264 _ACEOF
11265 rm -f conftest.$ac_objext conftest$ac_exeext
11266 if { (ac_try="$ac_link"
11267 case "(($ac_try" in
11268   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11269   *) ac_try_echo=$ac_try;;
11270 esac
11271 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11272   (eval "$ac_link") 2>conftest.er1
11273   ac_status=$?
11274   grep -v '^ *+' conftest.er1 >conftest.err
11275   rm -f conftest.er1
11276   cat conftest.err >&5
11277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11278   (exit $ac_status); } && {
11279          test -z "$ac_c_werror_flag" ||
11280          test ! -s conftest.err
11281        } && test -s conftest$ac_exeext &&
11282        $as_test_x conftest$ac_exeext; then
11283   eval "$as_ac_var=yes"
11284 else
11285   echo "$as_me: failed program was:" >&5
11286 sed 's/^/| /' conftest.$ac_ext >&5
11287
11288         eval "$as_ac_var=no"
11289 fi
11290
11291 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11292       conftest$ac_exeext conftest.$ac_ext
11293 fi
11294 ac_res=`eval echo '${'$as_ac_var'}'`
11295                { echo "$as_me:$LINENO: result: $ac_res" >&5
11296 echo "${ECHO_T}$ac_res" >&6; }
11297 if test `eval echo '${'$as_ac_var'}'` = yes; then
11298   cat >>confdefs.h <<_ACEOF
11299 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11300 _ACEOF
11301
11302 fi
11303 done
11304
11305 fi
11306
11307 if test "$with_pam" = yes ; then
11308
11309 for ac_header in security/pam_appl.h
11310 do
11311 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11312 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11313   { echo "$as_me:$LINENO: checking for $ac_header" >&5
11314 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11315 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11316   echo $ECHO_N "(cached) $ECHO_C" >&6
11317 fi
11318 ac_res=`eval echo '${'$as_ac_Header'}'`
11319                { echo "$as_me:$LINENO: result: $ac_res" >&5
11320 echo "${ECHO_T}$ac_res" >&6; }
11321 else
11322   # Is the header compilable?
11323 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
11324 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11325 cat >conftest.$ac_ext <<_ACEOF
11326 /* confdefs.h.  */
11327 _ACEOF
11328 cat confdefs.h >>conftest.$ac_ext
11329 cat >>conftest.$ac_ext <<_ACEOF
11330 /* end confdefs.h.  */
11331 $ac_includes_default
11332 #include <$ac_header>
11333 _ACEOF
11334 rm -f conftest.$ac_objext
11335 if { (ac_try="$ac_compile"
11336 case "(($ac_try" in
11337   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11338   *) ac_try_echo=$ac_try;;
11339 esac
11340 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11341   (eval "$ac_compile") 2>conftest.er1
11342   ac_status=$?
11343   grep -v '^ *+' conftest.er1 >conftest.err
11344   rm -f conftest.er1
11345   cat conftest.err >&5
11346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11347   (exit $ac_status); } && {
11348          test -z "$ac_c_werror_flag" ||
11349          test ! -s conftest.err
11350        } && test -s conftest.$ac_objext; then
11351   ac_header_compiler=yes
11352 else
11353   echo "$as_me: failed program was:" >&5
11354 sed 's/^/| /' conftest.$ac_ext >&5
11355
11356         ac_header_compiler=no
11357 fi
11358
11359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11360 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11361 echo "${ECHO_T}$ac_header_compiler" >&6; }
11362
11363 # Is the header present?
11364 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
11365 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11366 cat >conftest.$ac_ext <<_ACEOF
11367 /* confdefs.h.  */
11368 _ACEOF
11369 cat confdefs.h >>conftest.$ac_ext
11370 cat >>conftest.$ac_ext <<_ACEOF
11371 /* end confdefs.h.  */
11372 #include <$ac_header>
11373 _ACEOF
11374 if { (ac_try="$ac_cpp conftest.$ac_ext"
11375 case "(($ac_try" in
11376   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11377   *) ac_try_echo=$ac_try;;
11378 esac
11379 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11380   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11381   ac_status=$?
11382   grep -v '^ *+' conftest.er1 >conftest.err
11383   rm -f conftest.er1
11384   cat conftest.err >&5
11385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11386   (exit $ac_status); } >/dev/null && {
11387          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11388          test ! -s conftest.err
11389        }; then
11390   ac_header_preproc=yes
11391 else
11392   echo "$as_me: failed program was:" >&5
11393 sed 's/^/| /' conftest.$ac_ext >&5
11394
11395   ac_header_preproc=no
11396 fi
11397
11398 rm -f conftest.err conftest.$ac_ext
11399 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11400 echo "${ECHO_T}$ac_header_preproc" >&6; }
11401
11402 # So?  What about this header?
11403 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11404   yes:no: )
11405     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11406 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11407     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11408 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11409     ac_header_preproc=yes
11410     ;;
11411   no:yes:* )
11412     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11413 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11414     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11415 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11416     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11417 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11418     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11419 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11420     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11421 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11422     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11423 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11424     ( cat <<\_ASBOX
11425 ## ---------------------------------------- ##
11426 ## Report this to pgsql-bugs@postgresql.org ##
11427 ## ---------------------------------------- ##
11428 _ASBOX
11429      ) | sed "s/^/$as_me: WARNING:     /" >&2
11430     ;;
11431 esac
11432 { echo "$as_me:$LINENO: checking for $ac_header" >&5
11433 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11434 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11435   echo $ECHO_N "(cached) $ECHO_C" >&6
11436 else
11437   eval "$as_ac_Header=\$ac_header_preproc"
11438 fi
11439 ac_res=`eval echo '${'$as_ac_Header'}'`
11440                { echo "$as_me:$LINENO: result: $ac_res" >&5
11441 echo "${ECHO_T}$ac_res" >&6; }
11442
11443 fi
11444 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11445   cat >>confdefs.h <<_ACEOF
11446 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11447 _ACEOF
11448
11449 else
11450
11451 for ac_header in pam/pam_appl.h
11452 do
11453 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11454 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11455   { echo "$as_me:$LINENO: checking for $ac_header" >&5
11456 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11457 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11458   echo $ECHO_N "(cached) $ECHO_C" >&6
11459 fi
11460 ac_res=`eval echo '${'$as_ac_Header'}'`
11461                { echo "$as_me:$LINENO: result: $ac_res" >&5
11462 echo "${ECHO_T}$ac_res" >&6; }
11463 else
11464   # Is the header compilable?
11465 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
11466 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11467 cat >conftest.$ac_ext <<_ACEOF
11468 /* confdefs.h.  */
11469 _ACEOF
11470 cat confdefs.h >>conftest.$ac_ext
11471 cat >>conftest.$ac_ext <<_ACEOF
11472 /* end confdefs.h.  */
11473 $ac_includes_default
11474 #include <$ac_header>
11475 _ACEOF
11476 rm -f conftest.$ac_objext
11477 if { (ac_try="$ac_compile"
11478 case "(($ac_try" in
11479   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11480   *) ac_try_echo=$ac_try;;
11481 esac
11482 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11483   (eval "$ac_compile") 2>conftest.er1
11484   ac_status=$?
11485   grep -v '^ *+' conftest.er1 >conftest.err
11486   rm -f conftest.er1
11487   cat conftest.err >&5
11488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11489   (exit $ac_status); } && {
11490          test -z "$ac_c_werror_flag" ||
11491          test ! -s conftest.err
11492        } && test -s conftest.$ac_objext; then
11493   ac_header_compiler=yes
11494 else
11495   echo "$as_me: failed program was:" >&5
11496 sed 's/^/| /' conftest.$ac_ext >&5
11497
11498         ac_header_compiler=no
11499 fi
11500
11501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11502 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11503 echo "${ECHO_T}$ac_header_compiler" >&6; }
11504
11505 # Is the header present?
11506 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
11507 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11508 cat >conftest.$ac_ext <<_ACEOF
11509 /* confdefs.h.  */
11510 _ACEOF
11511 cat confdefs.h >>conftest.$ac_ext
11512 cat >>conftest.$ac_ext <<_ACEOF
11513 /* end confdefs.h.  */
11514 #include <$ac_header>
11515 _ACEOF
11516 if { (ac_try="$ac_cpp conftest.$ac_ext"
11517 case "(($ac_try" in
11518   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11519   *) ac_try_echo=$ac_try;;
11520 esac
11521 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11522   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11523   ac_status=$?
11524   grep -v '^ *+' conftest.er1 >conftest.err
11525   rm -f conftest.er1
11526   cat conftest.err >&5
11527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11528   (exit $ac_status); } >/dev/null && {
11529          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11530          test ! -s conftest.err
11531        }; then
11532   ac_header_preproc=yes
11533 else
11534   echo "$as_me: failed program was:" >&5
11535 sed 's/^/| /' conftest.$ac_ext >&5
11536
11537   ac_header_preproc=no
11538 fi
11539
11540 rm -f conftest.err conftest.$ac_ext
11541 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11542 echo "${ECHO_T}$ac_header_preproc" >&6; }
11543
11544 # So?  What about this header?
11545 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11546   yes:no: )
11547     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11548 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11549     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11550 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11551     ac_header_preproc=yes
11552     ;;
11553   no:yes:* )
11554     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11555 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11556     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11557 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11558     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11559 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11560     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11561 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11562     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11563 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11564     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11565 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11566     ( cat <<\_ASBOX
11567 ## ---------------------------------------- ##
11568 ## Report this to pgsql-bugs@postgresql.org ##
11569 ## ---------------------------------------- ##
11570 _ASBOX
11571      ) | sed "s/^/$as_me: WARNING:     /" >&2
11572     ;;
11573 esac
11574 { echo "$as_me:$LINENO: checking for $ac_header" >&5
11575 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11576 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11577   echo $ECHO_N "(cached) $ECHO_C" >&6
11578 else
11579   eval "$as_ac_Header=\$ac_header_preproc"
11580 fi
11581 ac_res=`eval echo '${'$as_ac_Header'}'`
11582                { echo "$as_me:$LINENO: result: $ac_res" >&5
11583 echo "${ECHO_T}$ac_res" >&6; }
11584
11585 fi
11586 if test `eval echo '${'$as_ac_Header'}'` = yes; then
11587   cat >>confdefs.h <<_ACEOF
11588 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11589 _ACEOF
11590
11591 else
11592   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
11593 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
11594    { (exit 1); exit 1; }; }
11595 fi
11596
11597 done
11598
11599 fi
11600
11601 done
11602
11603 fi
11604
11605 if test "$with_libxml" = yes ; then
11606   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
11607   { echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
11608 echo $ECHO_N "checking for libxml/parser.h... $ECHO_C" >&6; }
11609 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
11610   echo $ECHO_N "(cached) $ECHO_C" >&6
11611 fi
11612 { echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
11613 echo "${ECHO_T}$ac_cv_header_libxml_parser_h" >&6; }
11614 else
11615   # Is the header compilable?
11616 { echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
11617 echo $ECHO_N "checking libxml/parser.h usability... $ECHO_C" >&6; }
11618 cat >conftest.$ac_ext <<_ACEOF
11619 /* confdefs.h.  */
11620 _ACEOF
11621 cat confdefs.h >>conftest.$ac_ext
11622 cat >>conftest.$ac_ext <<_ACEOF
11623 /* end confdefs.h.  */
11624 $ac_includes_default
11625 #include <libxml/parser.h>
11626 _ACEOF
11627 rm -f conftest.$ac_objext
11628 if { (ac_try="$ac_compile"
11629 case "(($ac_try" in
11630   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11631   *) ac_try_echo=$ac_try;;
11632 esac
11633 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11634   (eval "$ac_compile") 2>conftest.er1
11635   ac_status=$?
11636   grep -v '^ *+' conftest.er1 >conftest.err
11637   rm -f conftest.er1
11638   cat conftest.err >&5
11639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11640   (exit $ac_status); } && {
11641          test -z "$ac_c_werror_flag" ||
11642          test ! -s conftest.err
11643        } && test -s conftest.$ac_objext; then
11644   ac_header_compiler=yes
11645 else
11646   echo "$as_me: failed program was:" >&5
11647 sed 's/^/| /' conftest.$ac_ext >&5
11648
11649         ac_header_compiler=no
11650 fi
11651
11652 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11653 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11654 echo "${ECHO_T}$ac_header_compiler" >&6; }
11655
11656 # Is the header present?
11657 { echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
11658 echo $ECHO_N "checking libxml/parser.h presence... $ECHO_C" >&6; }
11659 cat >conftest.$ac_ext <<_ACEOF
11660 /* confdefs.h.  */
11661 _ACEOF
11662 cat confdefs.h >>conftest.$ac_ext
11663 cat >>conftest.$ac_ext <<_ACEOF
11664 /* end confdefs.h.  */
11665 #include <libxml/parser.h>
11666 _ACEOF
11667 if { (ac_try="$ac_cpp conftest.$ac_ext"
11668 case "(($ac_try" in
11669   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11670   *) ac_try_echo=$ac_try;;
11671 esac
11672 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11673   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11674   ac_status=$?
11675   grep -v '^ *+' conftest.er1 >conftest.err
11676   rm -f conftest.er1
11677   cat conftest.err >&5
11678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11679   (exit $ac_status); } >/dev/null && {
11680          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11681          test ! -s conftest.err
11682        }; then
11683   ac_header_preproc=yes
11684 else
11685   echo "$as_me: failed program was:" >&5
11686 sed 's/^/| /' conftest.$ac_ext >&5
11687
11688   ac_header_preproc=no
11689 fi
11690
11691 rm -f conftest.err conftest.$ac_ext
11692 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11693 echo "${ECHO_T}$ac_header_preproc" >&6; }
11694
11695 # So?  What about this header?
11696 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11697   yes:no: )
11698     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
11699 echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11700     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
11701 echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
11702     ac_header_preproc=yes
11703     ;;
11704   no:yes:* )
11705     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
11706 echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
11707     { echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
11708 echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
11709     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
11710 echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
11711     { echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
11712 echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11713     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
11714 echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
11715     { echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
11716 echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
11717     ( cat <<\_ASBOX
11718 ## ---------------------------------------- ##
11719 ## Report this to pgsql-bugs@postgresql.org ##
11720 ## ---------------------------------------- ##
11721 _ASBOX
11722      ) | sed "s/^/$as_me: WARNING:     /" >&2
11723     ;;
11724 esac
11725 { echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
11726 echo $ECHO_N "checking for libxml/parser.h... $ECHO_C" >&6; }
11727 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
11728   echo $ECHO_N "(cached) $ECHO_C" >&6
11729 else
11730   ac_cv_header_libxml_parser_h=$ac_header_preproc
11731 fi
11732 { echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
11733 echo "${ECHO_T}$ac_cv_header_libxml_parser_h" >&6; }
11734
11735 fi
11736 if test $ac_cv_header_libxml_parser_h = yes; then
11737   :
11738 else
11739   { { echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
11740 echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
11741    { (exit 1); exit 1; }; }
11742 fi
11743
11744
11745 fi
11746
11747 if test "$with_libxslt" = yes ; then
11748   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
11749   { echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
11750 echo $ECHO_N "checking for libxslt/xslt.h... $ECHO_C" >&6; }
11751 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
11752   echo $ECHO_N "(cached) $ECHO_C" >&6
11753 fi
11754 { echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
11755 echo "${ECHO_T}$ac_cv_header_libxslt_xslt_h" >&6; }
11756 else
11757   # Is the header compilable?
11758 { echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
11759 echo $ECHO_N "checking libxslt/xslt.h usability... $ECHO_C" >&6; }
11760 cat >conftest.$ac_ext <<_ACEOF
11761 /* confdefs.h.  */
11762 _ACEOF
11763 cat confdefs.h >>conftest.$ac_ext
11764 cat >>conftest.$ac_ext <<_ACEOF
11765 /* end confdefs.h.  */
11766 $ac_includes_default
11767 #include <libxslt/xslt.h>
11768 _ACEOF
11769 rm -f conftest.$ac_objext
11770 if { (ac_try="$ac_compile"
11771 case "(($ac_try" in
11772   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11773   *) ac_try_echo=$ac_try;;
11774 esac
11775 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11776   (eval "$ac_compile") 2>conftest.er1
11777   ac_status=$?
11778   grep -v '^ *+' conftest.er1 >conftest.err
11779   rm -f conftest.er1
11780   cat conftest.err >&5
11781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11782   (exit $ac_status); } && {
11783          test -z "$ac_c_werror_flag" ||
11784          test ! -s conftest.err
11785        } && test -s conftest.$ac_objext; then
11786   ac_header_compiler=yes
11787 else
11788   echo "$as_me: failed program was:" >&5
11789 sed 's/^/| /' conftest.$ac_ext >&5
11790
11791         ac_header_compiler=no
11792 fi
11793
11794 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11795 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11796 echo "${ECHO_T}$ac_header_compiler" >&6; }
11797
11798 # Is the header present?
11799 { echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
11800 echo $ECHO_N "checking libxslt/xslt.h presence... $ECHO_C" >&6; }
11801 cat >conftest.$ac_ext <<_ACEOF
11802 /* confdefs.h.  */
11803 _ACEOF
11804 cat confdefs.h >>conftest.$ac_ext
11805 cat >>conftest.$ac_ext <<_ACEOF
11806 /* end confdefs.h.  */
11807 #include <libxslt/xslt.h>
11808 _ACEOF
11809 if { (ac_try="$ac_cpp conftest.$ac_ext"
11810 case "(($ac_try" in
11811   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11812   *) ac_try_echo=$ac_try;;
11813 esac
11814 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11815   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11816   ac_status=$?
11817   grep -v '^ *+' conftest.er1 >conftest.err
11818   rm -f conftest.er1
11819   cat conftest.err >&5
11820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11821   (exit $ac_status); } >/dev/null && {
11822          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11823          test ! -s conftest.err
11824        }; then
11825   ac_header_preproc=yes
11826 else
11827   echo "$as_me: failed program was:" >&5
11828 sed 's/^/| /' conftest.$ac_ext >&5
11829
11830   ac_header_preproc=no
11831 fi
11832
11833 rm -f conftest.err conftest.$ac_ext
11834 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11835 echo "${ECHO_T}$ac_header_preproc" >&6; }
11836
11837 # So?  What about this header?
11838 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11839   yes:no: )
11840     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
11841 echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11842     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
11843 echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
11844     ac_header_preproc=yes
11845     ;;
11846   no:yes:* )
11847     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
11848 echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
11849     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
11850 echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
11851     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
11852 echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
11853     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
11854 echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11855     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
11856 echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
11857     { echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
11858 echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
11859     ( cat <<\_ASBOX
11860 ## ---------------------------------------- ##
11861 ## Report this to pgsql-bugs@postgresql.org ##
11862 ## ---------------------------------------- ##
11863 _ASBOX
11864      ) | sed "s/^/$as_me: WARNING:     /" >&2
11865     ;;
11866 esac
11867 { echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
11868 echo $ECHO_N "checking for libxslt/xslt.h... $ECHO_C" >&6; }
11869 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
11870   echo $ECHO_N "(cached) $ECHO_C" >&6
11871 else
11872   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
11873 fi
11874 { echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
11875 echo "${ECHO_T}$ac_cv_header_libxslt_xslt_h" >&6; }
11876
11877 fi
11878 if test $ac_cv_header_libxslt_xslt_h = yes; then
11879   :
11880 else
11881   { { echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
11882 echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
11883    { (exit 1); exit 1; }; }
11884 fi
11885
11886
11887 fi
11888
11889 if test "$with_ldap" = yes ; then
11890   if test "$PORTNAME" != "win32"; then
11891
11892 for ac_header in ldap.h
11893 do
11894 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11895 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11896   { echo "$as_me:$LINENO: checking for $ac_header" >&5
11897 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11898 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11899   echo $ECHO_N "(cached) $ECHO_C" >&6
11900 fi
11901 ac_res=`eval echo '${'$as_ac_Header'}'`
11902                { echo "$as_me:$LINENO: result: $ac_res" >&5
11903 echo "${ECHO_T}$ac_res" >&6; }
11904 else
11905   # Is the header compilable?
11906 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
11907 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11908 cat >conftest.$ac_ext <<_ACEOF
11909 /* confdefs.h.  */
11910 _ACEOF
11911 cat confdefs.h >>conftest.$ac_ext
11912 cat >>conftest.$ac_ext <<_ACEOF
11913 /* end confdefs.h.  */
11914 $ac_includes_default
11915 #include <$ac_header>
11916 _ACEOF
11917 rm -f conftest.$ac_objext
11918 if { (ac_try="$ac_compile"
11919 case "(($ac_try" in
11920   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11921   *) ac_try_echo=$ac_try;;
11922 esac
11923 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11924   (eval "$ac_compile") 2>conftest.er1
11925   ac_status=$?
11926   grep -v '^ *+' conftest.er1 >conftest.err
11927   rm -f conftest.er1
11928   cat conftest.err >&5
11929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11930   (exit $ac_status); } && {
11931          test -z "$ac_c_werror_flag" ||
11932          test ! -s conftest.err
11933        } && test -s conftest.$ac_objext; then
11934   ac_header_compiler=yes
11935 else
11936   echo "$as_me: failed program was:" >&5
11937 sed 's/^/| /' conftest.$ac_ext >&5
11938
11939         ac_header_compiler=no
11940 fi
11941
11942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11943 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11944 echo "${ECHO_T}$ac_header_compiler" >&6; }
11945
11946 # Is the header present?
11947 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
11948 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11949 cat >conftest.$ac_ext <<_ACEOF
11950 /* confdefs.h.  */
11951 _ACEOF
11952 cat confdefs.h >>conftest.$ac_ext
11953 cat >>conftest.$ac_ext <<_ACEOF
11954 /* end confdefs.h.  */
11955 #include <$ac_header>
11956 _ACEOF
11957 if { (ac_try="$ac_cpp conftest.$ac_ext"
11958 case "(($ac_try" in
11959   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11960   *) ac_try_echo=$ac_try;;
11961 esac
11962 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11963   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11964   ac_status=$?
11965   grep -v '^ *+' conftest.er1 >conftest.err
11966   rm -f conftest.er1
11967   cat conftest.err >&5
11968   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11969   (exit $ac_status); } >/dev/null && {
11970          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11971          test ! -s conftest.err
11972        }; then
11973   ac_header_preproc=yes
11974 else
11975   echo "$as_me: failed program was:" >&5
11976 sed 's/^/| /' conftest.$ac_ext >&5
11977
11978   ac_header_preproc=no
11979 fi
11980
11981 rm -f conftest.err conftest.$ac_ext
11982 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11983 echo "${ECHO_T}$ac_header_preproc" >&6; }
11984
11985 # So?  What about this header?
11986 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11987   yes:no: )
11988     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11989 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11990     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11991 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11992     ac_header_preproc=yes
11993     ;;
11994   no:yes:* )
11995     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11996 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11997     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11998 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11999     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12000 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12001     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12002 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12003     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12004 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12005     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12006 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12007     ( cat <<\_ASBOX
12008 ## ---------------------------------------- ##
12009 ## Report this to pgsql-bugs@postgresql.org ##
12010 ## ---------------------------------------- ##
12011 _ASBOX
12012      ) | sed "s/^/$as_me: WARNING:     /" >&2
12013     ;;
12014 esac
12015 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12016 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12017 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12018   echo $ECHO_N "(cached) $ECHO_C" >&6
12019 else
12020   eval "$as_ac_Header=\$ac_header_preproc"
12021 fi
12022 ac_res=`eval echo '${'$as_ac_Header'}'`
12023                { echo "$as_me:$LINENO: result: $ac_res" >&5
12024 echo "${ECHO_T}$ac_res" >&6; }
12025
12026 fi
12027 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12028   cat >>confdefs.h <<_ACEOF
12029 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12030 _ACEOF
12031
12032 else
12033   { { echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
12034 echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
12035    { (exit 1); exit 1; }; }
12036 fi
12037
12038 done
12039
12040   else
12041
12042 for ac_header in winldap.h
12043 do
12044 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12045 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12046 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12047 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12048   echo $ECHO_N "(cached) $ECHO_C" >&6
12049 else
12050   cat >conftest.$ac_ext <<_ACEOF
12051 /* confdefs.h.  */
12052 _ACEOF
12053 cat confdefs.h >>conftest.$ac_ext
12054 cat >>conftest.$ac_ext <<_ACEOF
12055 /* end confdefs.h.  */
12056 $ac_includes_default
12057 #include <windows.h>
12058
12059
12060 #include <$ac_header>
12061 _ACEOF
12062 rm -f conftest.$ac_objext
12063 if { (ac_try="$ac_compile"
12064 case "(($ac_try" in
12065   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12066   *) ac_try_echo=$ac_try;;
12067 esac
12068 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12069   (eval "$ac_compile") 2>conftest.er1
12070   ac_status=$?
12071   grep -v '^ *+' conftest.er1 >conftest.err
12072   rm -f conftest.er1
12073   cat conftest.err >&5
12074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12075   (exit $ac_status); } && {
12076          test -z "$ac_c_werror_flag" ||
12077          test ! -s conftest.err
12078        } && test -s conftest.$ac_objext; then
12079   eval "$as_ac_Header=yes"
12080 else
12081   echo "$as_me: failed program was:" >&5
12082 sed 's/^/| /' conftest.$ac_ext >&5
12083
12084         eval "$as_ac_Header=no"
12085 fi
12086
12087 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12088 fi
12089 ac_res=`eval echo '${'$as_ac_Header'}'`
12090                { echo "$as_me:$LINENO: result: $ac_res" >&5
12091 echo "${ECHO_T}$ac_res" >&6; }
12092 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12093   cat >>confdefs.h <<_ACEOF
12094 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12095 _ACEOF
12096
12097 else
12098   { { echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
12099 echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
12100    { (exit 1); exit 1; }; }
12101 fi
12102
12103 done
12104
12105   fi
12106 fi
12107
12108 if test "$with_bonjour" = yes ; then
12109   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
12110   { echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
12111 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6; }
12112 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
12113   echo $ECHO_N "(cached) $ECHO_C" >&6
12114 fi
12115 { echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
12116 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6; }
12117 else
12118   # Is the header compilable?
12119 { echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
12120 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6; }
12121 cat >conftest.$ac_ext <<_ACEOF
12122 /* confdefs.h.  */
12123 _ACEOF
12124 cat confdefs.h >>conftest.$ac_ext
12125 cat >>conftest.$ac_ext <<_ACEOF
12126 /* end confdefs.h.  */
12127 $ac_includes_default
12128 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
12129 _ACEOF
12130 rm -f conftest.$ac_objext
12131 if { (ac_try="$ac_compile"
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_compile") 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); } && {
12144          test -z "$ac_c_werror_flag" ||
12145          test ! -s conftest.err
12146        } && test -s conftest.$ac_objext; then
12147   ac_header_compiler=yes
12148 else
12149   echo "$as_me: failed program was:" >&5
12150 sed 's/^/| /' conftest.$ac_ext >&5
12151
12152         ac_header_compiler=no
12153 fi
12154
12155 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12156 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12157 echo "${ECHO_T}$ac_header_compiler" >&6; }
12158
12159 # Is the header present?
12160 { echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
12161 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6; }
12162 cat >conftest.$ac_ext <<_ACEOF
12163 /* confdefs.h.  */
12164 _ACEOF
12165 cat confdefs.h >>conftest.$ac_ext
12166 cat >>conftest.$ac_ext <<_ACEOF
12167 /* end confdefs.h.  */
12168 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
12169 _ACEOF
12170 if { (ac_try="$ac_cpp conftest.$ac_ext"
12171 case "(($ac_try" in
12172   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12173   *) ac_try_echo=$ac_try;;
12174 esac
12175 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12176   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12177   ac_status=$?
12178   grep -v '^ *+' conftest.er1 >conftest.err
12179   rm -f conftest.er1
12180   cat conftest.err >&5
12181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12182   (exit $ac_status); } >/dev/null && {
12183          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12184          test ! -s conftest.err
12185        }; then
12186   ac_header_preproc=yes
12187 else
12188   echo "$as_me: failed program was:" >&5
12189 sed 's/^/| /' conftest.$ac_ext >&5
12190
12191   ac_header_preproc=no
12192 fi
12193
12194 rm -f conftest.err conftest.$ac_ext
12195 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12196 echo "${ECHO_T}$ac_header_preproc" >&6; }
12197
12198 # So?  What about this header?
12199 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12200   yes:no: )
12201     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
12202 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12203     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&5
12204 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&2;}
12205     ac_header_preproc=yes
12206     ;;
12207   no:yes:* )
12208     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
12209 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
12210     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&5
12211 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&2;}
12212     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&5
12213 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&2;}
12214     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&5
12215 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12216     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
12217 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;}
12218     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&5
12219 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&2;}
12220     ( cat <<\_ASBOX
12221 ## ---------------------------------------- ##
12222 ## Report this to pgsql-bugs@postgresql.org ##
12223 ## ---------------------------------------- ##
12224 _ASBOX
12225      ) | sed "s/^/$as_me: WARNING:     /" >&2
12226     ;;
12227 esac
12228 { echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
12229 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6; }
12230 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
12231   echo $ECHO_N "(cached) $ECHO_C" >&6
12232 else
12233   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
12234 fi
12235 { echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
12236 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6; }
12237
12238 fi
12239 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
12240   :
12241 else
12242   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&5
12243 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&2;}
12244    { (exit 1); exit 1; }; }
12245 fi
12246
12247
12248 fi
12249
12250 # for contrib/uuid-ossp
12251 if test "$with_ossp_uuid" = yes ; then
12252
12253 for ac_header in ossp/uuid.h
12254 do
12255 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12256 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12257   { echo "$as_me:$LINENO: checking for $ac_header" >&5
12258 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12259 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12260   echo $ECHO_N "(cached) $ECHO_C" >&6
12261 fi
12262 ac_res=`eval echo '${'$as_ac_Header'}'`
12263                { echo "$as_me:$LINENO: result: $ac_res" >&5
12264 echo "${ECHO_T}$ac_res" >&6; }
12265 else
12266   # Is the header compilable?
12267 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
12268 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12269 cat >conftest.$ac_ext <<_ACEOF
12270 /* confdefs.h.  */
12271 _ACEOF
12272 cat confdefs.h >>conftest.$ac_ext
12273 cat >>conftest.$ac_ext <<_ACEOF
12274 /* end confdefs.h.  */
12275 $ac_includes_default
12276 #include <$ac_header>
12277 _ACEOF
12278 rm -f conftest.$ac_objext
12279 if { (ac_try="$ac_compile"
12280 case "(($ac_try" in
12281   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12282   *) ac_try_echo=$ac_try;;
12283 esac
12284 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12285   (eval "$ac_compile") 2>conftest.er1
12286   ac_status=$?
12287   grep -v '^ *+' conftest.er1 >conftest.err
12288   rm -f conftest.er1
12289   cat conftest.err >&5
12290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12291   (exit $ac_status); } && {
12292          test -z "$ac_c_werror_flag" ||
12293          test ! -s conftest.err
12294        } && test -s conftest.$ac_objext; then
12295   ac_header_compiler=yes
12296 else
12297   echo "$as_me: failed program was:" >&5
12298 sed 's/^/| /' conftest.$ac_ext >&5
12299
12300         ac_header_compiler=no
12301 fi
12302
12303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12304 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12305 echo "${ECHO_T}$ac_header_compiler" >&6; }
12306
12307 # Is the header present?
12308 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
12309 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12310 cat >conftest.$ac_ext <<_ACEOF
12311 /* confdefs.h.  */
12312 _ACEOF
12313 cat confdefs.h >>conftest.$ac_ext
12314 cat >>conftest.$ac_ext <<_ACEOF
12315 /* end confdefs.h.  */
12316 #include <$ac_header>
12317 _ACEOF
12318 if { (ac_try="$ac_cpp conftest.$ac_ext"
12319 case "(($ac_try" in
12320   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12321   *) ac_try_echo=$ac_try;;
12322 esac
12323 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12324   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12325   ac_status=$?
12326   grep -v '^ *+' conftest.er1 >conftest.err
12327   rm -f conftest.er1
12328   cat conftest.err >&5
12329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12330   (exit $ac_status); } >/dev/null && {
12331          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12332          test ! -s conftest.err
12333        }; then
12334   ac_header_preproc=yes
12335 else
12336   echo "$as_me: failed program was:" >&5
12337 sed 's/^/| /' conftest.$ac_ext >&5
12338
12339   ac_header_preproc=no
12340 fi
12341
12342 rm -f conftest.err conftest.$ac_ext
12343 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12344 echo "${ECHO_T}$ac_header_preproc" >&6; }
12345
12346 # So?  What about this header?
12347 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12348   yes:no: )
12349     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12350 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12351     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12352 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12353     ac_header_preproc=yes
12354     ;;
12355   no:yes:* )
12356     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12357 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12358     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12359 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12360     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12361 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12362     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12363 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12364     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12365 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12366     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12367 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12368     ( cat <<\_ASBOX
12369 ## ---------------------------------------- ##
12370 ## Report this to pgsql-bugs@postgresql.org ##
12371 ## ---------------------------------------- ##
12372 _ASBOX
12373      ) | sed "s/^/$as_me: WARNING:     /" >&2
12374     ;;
12375 esac
12376 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12377 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12378 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12379   echo $ECHO_N "(cached) $ECHO_C" >&6
12380 else
12381   eval "$as_ac_Header=\$ac_header_preproc"
12382 fi
12383 ac_res=`eval echo '${'$as_ac_Header'}'`
12384                { echo "$as_me:$LINENO: result: $ac_res" >&5
12385 echo "${ECHO_T}$ac_res" >&6; }
12386
12387 fi
12388 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12389   cat >>confdefs.h <<_ACEOF
12390 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12391 _ACEOF
12392
12393 else
12394
12395
12396 for ac_header in uuid.h
12397 do
12398 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12399 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12400   { echo "$as_me:$LINENO: checking for $ac_header" >&5
12401 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12402 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12403   echo $ECHO_N "(cached) $ECHO_C" >&6
12404 fi
12405 ac_res=`eval echo '${'$as_ac_Header'}'`
12406                { echo "$as_me:$LINENO: result: $ac_res" >&5
12407 echo "${ECHO_T}$ac_res" >&6; }
12408 else
12409   # Is the header compilable?
12410 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
12411 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12412 cat >conftest.$ac_ext <<_ACEOF
12413 /* confdefs.h.  */
12414 _ACEOF
12415 cat confdefs.h >>conftest.$ac_ext
12416 cat >>conftest.$ac_ext <<_ACEOF
12417 /* end confdefs.h.  */
12418 $ac_includes_default
12419 #include <$ac_header>
12420 _ACEOF
12421 rm -f conftest.$ac_objext
12422 if { (ac_try="$ac_compile"
12423 case "(($ac_try" in
12424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12425   *) ac_try_echo=$ac_try;;
12426 esac
12427 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12428   (eval "$ac_compile") 2>conftest.er1
12429   ac_status=$?
12430   grep -v '^ *+' conftest.er1 >conftest.err
12431   rm -f conftest.er1
12432   cat conftest.err >&5
12433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12434   (exit $ac_status); } && {
12435          test -z "$ac_c_werror_flag" ||
12436          test ! -s conftest.err
12437        } && test -s conftest.$ac_objext; then
12438   ac_header_compiler=yes
12439 else
12440   echo "$as_me: failed program was:" >&5
12441 sed 's/^/| /' conftest.$ac_ext >&5
12442
12443         ac_header_compiler=no
12444 fi
12445
12446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12447 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12448 echo "${ECHO_T}$ac_header_compiler" >&6; }
12449
12450 # Is the header present?
12451 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
12452 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12453 cat >conftest.$ac_ext <<_ACEOF
12454 /* confdefs.h.  */
12455 _ACEOF
12456 cat confdefs.h >>conftest.$ac_ext
12457 cat >>conftest.$ac_ext <<_ACEOF
12458 /* end confdefs.h.  */
12459 #include <$ac_header>
12460 _ACEOF
12461 if { (ac_try="$ac_cpp conftest.$ac_ext"
12462 case "(($ac_try" in
12463   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12464   *) ac_try_echo=$ac_try;;
12465 esac
12466 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12467   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12468   ac_status=$?
12469   grep -v '^ *+' conftest.er1 >conftest.err
12470   rm -f conftest.er1
12471   cat conftest.err >&5
12472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12473   (exit $ac_status); } >/dev/null && {
12474          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12475          test ! -s conftest.err
12476        }; then
12477   ac_header_preproc=yes
12478 else
12479   echo "$as_me: failed program was:" >&5
12480 sed 's/^/| /' conftest.$ac_ext >&5
12481
12482   ac_header_preproc=no
12483 fi
12484
12485 rm -f conftest.err conftest.$ac_ext
12486 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12487 echo "${ECHO_T}$ac_header_preproc" >&6; }
12488
12489 # So?  What about this header?
12490 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12491   yes:no: )
12492     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12493 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12494     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12495 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12496     ac_header_preproc=yes
12497     ;;
12498   no:yes:* )
12499     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12500 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12501     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12502 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12503     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12504 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12505     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12506 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12507     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12508 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12509     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12510 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12511     ( cat <<\_ASBOX
12512 ## ---------------------------------------- ##
12513 ## Report this to pgsql-bugs@postgresql.org ##
12514 ## ---------------------------------------- ##
12515 _ASBOX
12516      ) | sed "s/^/$as_me: WARNING:     /" >&2
12517     ;;
12518 esac
12519 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12520 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12521 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12522   echo $ECHO_N "(cached) $ECHO_C" >&6
12523 else
12524   eval "$as_ac_Header=\$ac_header_preproc"
12525 fi
12526 ac_res=`eval echo '${'$as_ac_Header'}'`
12527                { echo "$as_me:$LINENO: result: $ac_res" >&5
12528 echo "${ECHO_T}$ac_res" >&6; }
12529
12530 fi
12531 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12532   cat >>confdefs.h <<_ACEOF
12533 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12534 _ACEOF
12535
12536 else
12537   { { echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
12538 echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
12539    { (exit 1); exit 1; }; }
12540 fi
12541
12542 done
12543
12544 fi
12545
12546 done
12547
12548 fi
12549
12550
12551 ##
12552 ## Types, structures, compiler characteristics
12553 ##
12554
12555  { echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
12556 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
12557 if test "${ac_cv_c_bigendian+set}" = set; then
12558   echo $ECHO_N "(cached) $ECHO_C" >&6
12559 else
12560   # See if sys/param.h defines the BYTE_ORDER macro.
12561 cat >conftest.$ac_ext <<_ACEOF
12562 /* confdefs.h.  */
12563 _ACEOF
12564 cat confdefs.h >>conftest.$ac_ext
12565 cat >>conftest.$ac_ext <<_ACEOF
12566 /* end confdefs.h.  */
12567 #include <sys/types.h>
12568 #include <sys/param.h>
12569
12570 int
12571 main ()
12572 {
12573 #if  ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
12574         && BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
12575  bogus endian macros
12576 #endif
12577
12578   ;
12579   return 0;
12580 }
12581 _ACEOF
12582 rm -f conftest.$ac_objext
12583 if { (ac_try="$ac_compile"
12584 case "(($ac_try" in
12585   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12586   *) ac_try_echo=$ac_try;;
12587 esac
12588 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12589   (eval "$ac_compile") 2>conftest.er1
12590   ac_status=$?
12591   grep -v '^ *+' conftest.er1 >conftest.err
12592   rm -f conftest.er1
12593   cat conftest.err >&5
12594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12595   (exit $ac_status); } && {
12596          test -z "$ac_c_werror_flag" ||
12597          test ! -s conftest.err
12598        } && test -s conftest.$ac_objext; then
12599   # It does; now see whether it defined to BIG_ENDIAN or not.
12600 cat >conftest.$ac_ext <<_ACEOF
12601 /* confdefs.h.  */
12602 _ACEOF
12603 cat confdefs.h >>conftest.$ac_ext
12604 cat >>conftest.$ac_ext <<_ACEOF
12605 /* end confdefs.h.  */
12606 #include <sys/types.h>
12607 #include <sys/param.h>
12608
12609 int
12610 main ()
12611 {
12612 #if BYTE_ORDER != BIG_ENDIAN
12613  not big endian
12614 #endif
12615
12616   ;
12617   return 0;
12618 }
12619 _ACEOF
12620 rm -f conftest.$ac_objext
12621 if { (ac_try="$ac_compile"
12622 case "(($ac_try" in
12623   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12624   *) ac_try_echo=$ac_try;;
12625 esac
12626 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12627   (eval "$ac_compile") 2>conftest.er1
12628   ac_status=$?
12629   grep -v '^ *+' conftest.er1 >conftest.err
12630   rm -f conftest.er1
12631   cat conftest.err >&5
12632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12633   (exit $ac_status); } && {
12634          test -z "$ac_c_werror_flag" ||
12635          test ! -s conftest.err
12636        } && test -s conftest.$ac_objext; then
12637   ac_cv_c_bigendian=yes
12638 else
12639   echo "$as_me: failed program was:" >&5
12640 sed 's/^/| /' conftest.$ac_ext >&5
12641
12642         ac_cv_c_bigendian=no
12643 fi
12644
12645 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12646 else
12647   echo "$as_me: failed program was:" >&5
12648 sed 's/^/| /' conftest.$ac_ext >&5
12649
12650         # It does not; compile a test program.
12651 if test "$cross_compiling" = yes; then
12652   # try to guess the endianness by grepping values into an object file
12653   ac_cv_c_bigendian=unknown
12654   cat >conftest.$ac_ext <<_ACEOF
12655 /* confdefs.h.  */
12656 _ACEOF
12657 cat confdefs.h >>conftest.$ac_ext
12658 cat >>conftest.$ac_ext <<_ACEOF
12659 /* end confdefs.h.  */
12660 short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
12661 short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
12662 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
12663 short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
12664 short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
12665 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
12666 int
12667 main ()
12668 {
12669  _ascii (); _ebcdic ();
12670   ;
12671   return 0;
12672 }
12673 _ACEOF
12674 rm -f conftest.$ac_objext
12675 if { (ac_try="$ac_compile"
12676 case "(($ac_try" in
12677   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12678   *) ac_try_echo=$ac_try;;
12679 esac
12680 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12681   (eval "$ac_compile") 2>conftest.er1
12682   ac_status=$?
12683   grep -v '^ *+' conftest.er1 >conftest.err
12684   rm -f conftest.er1
12685   cat conftest.err >&5
12686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12687   (exit $ac_status); } && {
12688          test -z "$ac_c_werror_flag" ||
12689          test ! -s conftest.err
12690        } && test -s conftest.$ac_objext; then
12691   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
12692   ac_cv_c_bigendian=yes
12693 fi
12694 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
12695   if test "$ac_cv_c_bigendian" = unknown; then
12696     ac_cv_c_bigendian=no
12697   else
12698     # finding both strings is unlikely to happen, but who knows?
12699     ac_cv_c_bigendian=unknown
12700   fi
12701 fi
12702 else
12703   echo "$as_me: failed program was:" >&5
12704 sed 's/^/| /' conftest.$ac_ext >&5
12705
12706
12707 fi
12708
12709 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12710 else
12711   cat >conftest.$ac_ext <<_ACEOF
12712 /* confdefs.h.  */
12713 _ACEOF
12714 cat confdefs.h >>conftest.$ac_ext
12715 cat >>conftest.$ac_ext <<_ACEOF
12716 /* end confdefs.h.  */
12717 $ac_includes_default
12718 int
12719 main ()
12720 {
12721
12722   /* Are we little or big endian?  From Harbison&Steele.  */
12723   union
12724   {
12725     long int l;
12726     char c[sizeof (long int)];
12727   } u;
12728   u.l = 1;
12729   return u.c[sizeof (long int) - 1] == 1;
12730
12731   ;
12732   return 0;
12733 }
12734 _ACEOF
12735 rm -f conftest$ac_exeext
12736 if { (ac_try="$ac_link"
12737 case "(($ac_try" in
12738   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12739   *) ac_try_echo=$ac_try;;
12740 esac
12741 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12742   (eval "$ac_link") 2>&5
12743   ac_status=$?
12744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12745   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12746   { (case "(($ac_try" in
12747   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12748   *) ac_try_echo=$ac_try;;
12749 esac
12750 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12751   (eval "$ac_try") 2>&5
12752   ac_status=$?
12753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12754   (exit $ac_status); }; }; then
12755   ac_cv_c_bigendian=no
12756 else
12757   echo "$as_me: program exited with status $ac_status" >&5
12758 echo "$as_me: failed program was:" >&5
12759 sed 's/^/| /' conftest.$ac_ext >&5
12760
12761 ( exit $ac_status )
12762 ac_cv_c_bigendian=yes
12763 fi
12764 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12765 fi
12766
12767
12768 fi
12769
12770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12771 fi
12772 { echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
12773 echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
12774 case $ac_cv_c_bigendian in
12775   yes)
12776
12777 cat >>confdefs.h <<\_ACEOF
12778 #define WORDS_BIGENDIAN 1
12779 _ACEOF
12780  ;;
12781   no)
12782      ;;
12783   *)
12784     { { echo "$as_me:$LINENO: error: unknown endianness
12785 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
12786 echo "$as_me: error: unknown endianness
12787 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
12788    { (exit 1); exit 1; }; } ;;
12789 esac
12790
12791 { echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
12792 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; }
12793 if test "${ac_cv_c_const+set}" = set; then
12794   echo $ECHO_N "(cached) $ECHO_C" >&6
12795 else
12796   cat >conftest.$ac_ext <<_ACEOF
12797 /* confdefs.h.  */
12798 _ACEOF
12799 cat confdefs.h >>conftest.$ac_ext
12800 cat >>conftest.$ac_ext <<_ACEOF
12801 /* end confdefs.h.  */
12802
12803 int
12804 main ()
12805 {
12806 /* FIXME: Include the comments suggested by Paul. */
12807 #ifndef __cplusplus
12808   /* Ultrix mips cc rejects this.  */
12809   typedef int charset[2];
12810   const charset cs;
12811   /* SunOS 4.1.1 cc rejects this.  */
12812   char const *const *pcpcc;
12813   char **ppc;
12814   /* NEC SVR4.0.2 mips cc rejects this.  */
12815   struct point {int x, y;};
12816   static struct point const zero = {0,0};
12817   /* AIX XL C 1.02.0.0 rejects this.
12818      It does not let you subtract one const X* pointer from another in
12819      an arm of an if-expression whose if-part is not a constant
12820      expression */
12821   const char *g = "string";
12822   pcpcc = &g + (g ? g-g : 0);
12823   /* HPUX 7.0 cc rejects these. */
12824   ++pcpcc;
12825   ppc = (char**) pcpcc;
12826   pcpcc = (char const *const *) ppc;
12827   { /* SCO 3.2v4 cc rejects this.  */
12828     char *t;
12829     char const *s = 0 ? (char *) 0 : (char const *) 0;
12830
12831     *t++ = 0;
12832     if (s) return 0;
12833   }
12834   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
12835     int x[] = {25, 17};
12836     const int *foo = &x[0];
12837     ++foo;
12838   }
12839   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
12840     typedef const int *iptr;
12841     iptr p = 0;
12842     ++p;
12843   }
12844   { /* AIX XL C 1.02.0.0 rejects this saying
12845        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
12846     struct s { int j; const int *ap[3]; };
12847     struct s *b; b->j = 5;
12848   }
12849   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
12850     const int foo = 10;
12851     if (!foo) return 0;
12852   }
12853   return !cs[0] && !zero.x;
12854 #endif
12855
12856   ;
12857   return 0;
12858 }
12859 _ACEOF
12860 rm -f conftest.$ac_objext
12861 if { (ac_try="$ac_compile"
12862 case "(($ac_try" in
12863   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12864   *) ac_try_echo=$ac_try;;
12865 esac
12866 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12867   (eval "$ac_compile") 2>conftest.er1
12868   ac_status=$?
12869   grep -v '^ *+' conftest.er1 >conftest.err
12870   rm -f conftest.er1
12871   cat conftest.err >&5
12872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12873   (exit $ac_status); } && {
12874          test -z "$ac_c_werror_flag" ||
12875          test ! -s conftest.err
12876        } && test -s conftest.$ac_objext; then
12877   ac_cv_c_const=yes
12878 else
12879   echo "$as_me: failed program was:" >&5
12880 sed 's/^/| /' conftest.$ac_ext >&5
12881
12882         ac_cv_c_const=no
12883 fi
12884
12885 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12886 fi
12887 { echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
12888 echo "${ECHO_T}$ac_cv_c_const" >&6; }
12889 if test $ac_cv_c_const = no; then
12890
12891 cat >>confdefs.h <<\_ACEOF
12892 #define const
12893 _ACEOF
12894
12895 fi
12896
12897 { echo "$as_me:$LINENO: checking for inline" >&5
12898 echo $ECHO_N "checking for inline... $ECHO_C" >&6; }
12899 if test "${ac_cv_c_inline+set}" = set; then
12900   echo $ECHO_N "(cached) $ECHO_C" >&6
12901 else
12902   ac_cv_c_inline=no
12903 for ac_kw in inline __inline__ __inline; do
12904   cat >conftest.$ac_ext <<_ACEOF
12905 /* confdefs.h.  */
12906 _ACEOF
12907 cat confdefs.h >>conftest.$ac_ext
12908 cat >>conftest.$ac_ext <<_ACEOF
12909 /* end confdefs.h.  */
12910 #ifndef __cplusplus
12911 typedef int foo_t;
12912 static $ac_kw foo_t static_foo () {return 0; }
12913 $ac_kw foo_t foo () {return 0; }
12914 #endif
12915
12916 _ACEOF
12917 rm -f conftest.$ac_objext
12918 if { (ac_try="$ac_compile"
12919 case "(($ac_try" in
12920   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12921   *) ac_try_echo=$ac_try;;
12922 esac
12923 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12924   (eval "$ac_compile") 2>conftest.er1
12925   ac_status=$?
12926   grep -v '^ *+' conftest.er1 >conftest.err
12927   rm -f conftest.er1
12928   cat conftest.err >&5
12929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12930   (exit $ac_status); } && {
12931          test -z "$ac_c_werror_flag" ||
12932          test ! -s conftest.err
12933        } && test -s conftest.$ac_objext; then
12934   ac_cv_c_inline=$ac_kw
12935 else
12936   echo "$as_me: failed program was:" >&5
12937 sed 's/^/| /' conftest.$ac_ext >&5
12938
12939
12940 fi
12941
12942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12943   test "$ac_cv_c_inline" != no && break
12944 done
12945
12946 fi
12947 { echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
12948 echo "${ECHO_T}$ac_cv_c_inline" >&6; }
12949
12950
12951 case $ac_cv_c_inline in
12952   inline | yes) ;;
12953   *)
12954     case $ac_cv_c_inline in
12955       no) ac_val=;;
12956       *) ac_val=$ac_cv_c_inline;;
12957     esac
12958     cat >>confdefs.h <<_ACEOF
12959 #ifndef __cplusplus
12960 #define inline $ac_val
12961 #endif
12962 _ACEOF
12963     ;;
12964 esac
12965
12966 { echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
12967 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6; }
12968 if test "${ac_cv_c_stringize+set}" = set; then
12969   echo $ECHO_N "(cached) $ECHO_C" >&6
12970 else
12971   cat >conftest.$ac_ext <<_ACEOF
12972 /* confdefs.h.  */
12973 _ACEOF
12974 cat confdefs.h >>conftest.$ac_ext
12975 cat >>conftest.$ac_ext <<_ACEOF
12976 /* end confdefs.h.  */
12977 #define x(y) #y
12978
12979 char *s = x(teststring);
12980 _ACEOF
12981 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12982   $EGREP "#teststring" >/dev/null 2>&1; then
12983   ac_cv_c_stringize=no
12984 else
12985   ac_cv_c_stringize=yes
12986 fi
12987 rm -f conftest*
12988
12989 fi
12990 { echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
12991 echo "${ECHO_T}$ac_cv_c_stringize" >&6; }
12992 if test $ac_cv_c_stringize = yes; then
12993
12994 cat >>confdefs.h <<\_ACEOF
12995 #define HAVE_STRINGIZE 1
12996 _ACEOF
12997
12998 fi
12999
13000 { echo "$as_me:$LINENO: checking for signed types" >&5
13001 echo $ECHO_N "checking for signed types... $ECHO_C" >&6; }
13002 if test "${pgac_cv_c_signed+set}" = set; then
13003   echo $ECHO_N "(cached) $ECHO_C" >&6
13004 else
13005   cat >conftest.$ac_ext <<_ACEOF
13006 /* confdefs.h.  */
13007 _ACEOF
13008 cat confdefs.h >>conftest.$ac_ext
13009 cat >>conftest.$ac_ext <<_ACEOF
13010 /* end confdefs.h.  */
13011
13012 int
13013 main ()
13014 {
13015 signed char c; signed short s; signed int i;
13016   ;
13017   return 0;
13018 }
13019 _ACEOF
13020 rm -f conftest.$ac_objext
13021 if { (ac_try="$ac_compile"
13022 case "(($ac_try" in
13023   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13024   *) ac_try_echo=$ac_try;;
13025 esac
13026 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13027   (eval "$ac_compile") 2>conftest.er1
13028   ac_status=$?
13029   grep -v '^ *+' conftest.er1 >conftest.err
13030   rm -f conftest.er1
13031   cat conftest.err >&5
13032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13033   (exit $ac_status); } && {
13034          test -z "$ac_c_werror_flag" ||
13035          test ! -s conftest.err
13036        } && test -s conftest.$ac_objext; then
13037   pgac_cv_c_signed=yes
13038 else
13039   echo "$as_me: failed program was:" >&5
13040 sed 's/^/| /' conftest.$ac_ext >&5
13041
13042         pgac_cv_c_signed=no
13043 fi
13044
13045 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13046 fi
13047 { echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
13048 echo "${ECHO_T}$pgac_cv_c_signed" >&6; }
13049 if test x"$pgac_cv_c_signed" = xno ; then
13050
13051 cat >>confdefs.h <<\_ACEOF
13052 #define signed
13053 _ACEOF
13054
13055 fi
13056 { echo "$as_me:$LINENO: checking for working volatile" >&5
13057 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6; }
13058 if test "${ac_cv_c_volatile+set}" = set; then
13059   echo $ECHO_N "(cached) $ECHO_C" >&6
13060 else
13061   cat >conftest.$ac_ext <<_ACEOF
13062 /* confdefs.h.  */
13063 _ACEOF
13064 cat confdefs.h >>conftest.$ac_ext
13065 cat >>conftest.$ac_ext <<_ACEOF
13066 /* end confdefs.h.  */
13067
13068 int
13069 main ()
13070 {
13071
13072 volatile int x;
13073 int * volatile y = (int *) 0;
13074 return !x && !y;
13075   ;
13076   return 0;
13077 }
13078 _ACEOF
13079 rm -f conftest.$ac_objext
13080 if { (ac_try="$ac_compile"
13081 case "(($ac_try" in
13082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13083   *) ac_try_echo=$ac_try;;
13084 esac
13085 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13086   (eval "$ac_compile") 2>conftest.er1
13087   ac_status=$?
13088   grep -v '^ *+' conftest.er1 >conftest.err
13089   rm -f conftest.er1
13090   cat conftest.err >&5
13091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13092   (exit $ac_status); } && {
13093          test -z "$ac_c_werror_flag" ||
13094          test ! -s conftest.err
13095        } && test -s conftest.$ac_objext; then
13096   ac_cv_c_volatile=yes
13097 else
13098   echo "$as_me: failed program was:" >&5
13099 sed 's/^/| /' conftest.$ac_ext >&5
13100
13101         ac_cv_c_volatile=no
13102 fi
13103
13104 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13105 fi
13106 { echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
13107 echo "${ECHO_T}$ac_cv_c_volatile" >&6; }
13108 if test $ac_cv_c_volatile = no; then
13109
13110 cat >>confdefs.h <<\_ACEOF
13111 #define volatile
13112 _ACEOF
13113
13114 fi
13115
13116 { echo "$as_me:$LINENO: checking for __func__" >&5
13117 echo $ECHO_N "checking for __func__... $ECHO_C" >&6; }
13118 if test "${pgac_cv_funcname_func_support+set}" = set; then
13119   echo $ECHO_N "(cached) $ECHO_C" >&6
13120 else
13121   cat >conftest.$ac_ext <<_ACEOF
13122 /* confdefs.h.  */
13123 _ACEOF
13124 cat confdefs.h >>conftest.$ac_ext
13125 cat >>conftest.$ac_ext <<_ACEOF
13126 /* end confdefs.h.  */
13127 #include <stdio.h>
13128 int
13129 main ()
13130 {
13131 printf("%s\n", __func__);
13132   ;
13133   return 0;
13134 }
13135 _ACEOF
13136 rm -f conftest.$ac_objext
13137 if { (ac_try="$ac_compile"
13138 case "(($ac_try" in
13139   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13140   *) ac_try_echo=$ac_try;;
13141 esac
13142 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13143   (eval "$ac_compile") 2>conftest.er1
13144   ac_status=$?
13145   grep -v '^ *+' conftest.er1 >conftest.err
13146   rm -f conftest.er1
13147   cat conftest.err >&5
13148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13149   (exit $ac_status); } && {
13150          test -z "$ac_c_werror_flag" ||
13151          test ! -s conftest.err
13152        } && test -s conftest.$ac_objext; then
13153   pgac_cv_funcname_func_support=yes
13154 else
13155   echo "$as_me: failed program was:" >&5
13156 sed 's/^/| /' conftest.$ac_ext >&5
13157
13158         pgac_cv_funcname_func_support=no
13159 fi
13160
13161 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13162 fi
13163 { echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
13164 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6; }
13165 if test x"$pgac_cv_funcname_func_support" = xyes ; then
13166
13167 cat >>confdefs.h <<\_ACEOF
13168 #define HAVE_FUNCNAME__FUNC 1
13169 _ACEOF
13170
13171 else
13172 { echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
13173 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6; }
13174 if test "${pgac_cv_funcname_function_support+set}" = set; then
13175   echo $ECHO_N "(cached) $ECHO_C" >&6
13176 else
13177   cat >conftest.$ac_ext <<_ACEOF
13178 /* confdefs.h.  */
13179 _ACEOF
13180 cat confdefs.h >>conftest.$ac_ext
13181 cat >>conftest.$ac_ext <<_ACEOF
13182 /* end confdefs.h.  */
13183 #include <stdio.h>
13184 int
13185 main ()
13186 {
13187 printf("%s\n", __FUNCTION__);
13188   ;
13189   return 0;
13190 }
13191 _ACEOF
13192 rm -f conftest.$ac_objext
13193 if { (ac_try="$ac_compile"
13194 case "(($ac_try" in
13195   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13196   *) ac_try_echo=$ac_try;;
13197 esac
13198 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13199   (eval "$ac_compile") 2>conftest.er1
13200   ac_status=$?
13201   grep -v '^ *+' conftest.er1 >conftest.err
13202   rm -f conftest.er1
13203   cat conftest.err >&5
13204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13205   (exit $ac_status); } && {
13206          test -z "$ac_c_werror_flag" ||
13207          test ! -s conftest.err
13208        } && test -s conftest.$ac_objext; then
13209   pgac_cv_funcname_function_support=yes
13210 else
13211   echo "$as_me: failed program was:" >&5
13212 sed 's/^/| /' conftest.$ac_ext >&5
13213
13214         pgac_cv_funcname_function_support=no
13215 fi
13216
13217 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13218 fi
13219 { echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
13220 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6; }
13221 if test x"$pgac_cv_funcname_function_support" = xyes ; then
13222
13223 cat >>confdefs.h <<\_ACEOF
13224 #define HAVE_FUNCNAME__FUNCTION 1
13225 _ACEOF
13226
13227 fi
13228 fi
13229 { echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
13230 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; }
13231 if test "${ac_cv_struct_tm+set}" = set; then
13232   echo $ECHO_N "(cached) $ECHO_C" >&6
13233 else
13234   cat >conftest.$ac_ext <<_ACEOF
13235 /* confdefs.h.  */
13236 _ACEOF
13237 cat confdefs.h >>conftest.$ac_ext
13238 cat >>conftest.$ac_ext <<_ACEOF
13239 /* end confdefs.h.  */
13240 #include <sys/types.h>
13241 #include <time.h>
13242
13243 int
13244 main ()
13245 {
13246 struct tm tm;
13247                                      int *p = &tm.tm_sec;
13248                                      return !p;
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_struct_tm=time.h
13271 else
13272   echo "$as_me: failed program was:" >&5
13273 sed 's/^/| /' conftest.$ac_ext >&5
13274
13275         ac_cv_struct_tm=sys/time.h
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_struct_tm" >&5
13281 echo "${ECHO_T}$ac_cv_struct_tm" >&6; }
13282 if test $ac_cv_struct_tm = sys/time.h; then
13283
13284 cat >>confdefs.h <<\_ACEOF
13285 #define TM_IN_SYS_TIME 1
13286 _ACEOF
13287
13288 fi
13289
13290 { echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
13291 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6; }
13292 if test "${ac_cv_member_struct_tm_tm_zone+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 <sys/types.h>
13302 #include <$ac_cv_struct_tm>
13303
13304
13305 int
13306 main ()
13307 {
13308 static struct tm ac_aggr;
13309 if (ac_aggr.tm_zone)
13310 return 0;
13311   ;
13312   return 0;
13313 }
13314 _ACEOF
13315 rm -f conftest.$ac_objext
13316 if { (ac_try="$ac_compile"
13317 case "(($ac_try" in
13318   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13319   *) ac_try_echo=$ac_try;;
13320 esac
13321 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13322   (eval "$ac_compile") 2>conftest.er1
13323   ac_status=$?
13324   grep -v '^ *+' conftest.er1 >conftest.err
13325   rm -f conftest.er1
13326   cat conftest.err >&5
13327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13328   (exit $ac_status); } && {
13329          test -z "$ac_c_werror_flag" ||
13330          test ! -s conftest.err
13331        } && test -s conftest.$ac_objext; then
13332   ac_cv_member_struct_tm_tm_zone=yes
13333 else
13334   echo "$as_me: failed program was:" >&5
13335 sed 's/^/| /' conftest.$ac_ext >&5
13336
13337         cat >conftest.$ac_ext <<_ACEOF
13338 /* confdefs.h.  */
13339 _ACEOF
13340 cat confdefs.h >>conftest.$ac_ext
13341 cat >>conftest.$ac_ext <<_ACEOF
13342 /* end confdefs.h.  */
13343 #include <sys/types.h>
13344 #include <$ac_cv_struct_tm>
13345
13346
13347 int
13348 main ()
13349 {
13350 static struct tm ac_aggr;
13351 if (sizeof ac_aggr.tm_zone)
13352 return 0;
13353   ;
13354   return 0;
13355 }
13356 _ACEOF
13357 rm -f conftest.$ac_objext
13358 if { (ac_try="$ac_compile"
13359 case "(($ac_try" in
13360   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13361   *) ac_try_echo=$ac_try;;
13362 esac
13363 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13364   (eval "$ac_compile") 2>conftest.er1
13365   ac_status=$?
13366   grep -v '^ *+' conftest.er1 >conftest.err
13367   rm -f conftest.er1
13368   cat conftest.err >&5
13369   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13370   (exit $ac_status); } && {
13371          test -z "$ac_c_werror_flag" ||
13372          test ! -s conftest.err
13373        } && test -s conftest.$ac_objext; then
13374   ac_cv_member_struct_tm_tm_zone=yes
13375 else
13376   echo "$as_me: failed program was:" >&5
13377 sed 's/^/| /' conftest.$ac_ext >&5
13378
13379         ac_cv_member_struct_tm_tm_zone=no
13380 fi
13381
13382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13383 fi
13384
13385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13386 fi
13387 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
13388 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6; }
13389 if test $ac_cv_member_struct_tm_tm_zone = yes; then
13390
13391 cat >>confdefs.h <<_ACEOF
13392 #define HAVE_STRUCT_TM_TM_ZONE 1
13393 _ACEOF
13394
13395
13396 fi
13397
13398 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13399
13400 cat >>confdefs.h <<\_ACEOF
13401 #define HAVE_TM_ZONE 1
13402 _ACEOF
13403
13404 fi
13405 { echo "$as_me:$LINENO: checking for tzname" >&5
13406 echo $ECHO_N "checking for tzname... $ECHO_C" >&6; }
13407 if test "${ac_cv_var_tzname+set}" = set; then
13408   echo $ECHO_N "(cached) $ECHO_C" >&6
13409 else
13410   cat >conftest.$ac_ext <<_ACEOF
13411 /* confdefs.h.  */
13412 _ACEOF
13413 cat confdefs.h >>conftest.$ac_ext
13414 cat >>conftest.$ac_ext <<_ACEOF
13415 /* end confdefs.h.  */
13416 #include <time.h>
13417 #ifndef tzname /* For SGI.  */
13418 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
13419 #endif
13420
13421 int
13422 main ()
13423 {
13424 atoi(*tzname);
13425   ;
13426   return 0;
13427 }
13428 _ACEOF
13429 rm -f conftest.$ac_objext conftest$ac_exeext
13430 if { (ac_try="$ac_link"
13431 case "(($ac_try" in
13432   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13433   *) ac_try_echo=$ac_try;;
13434 esac
13435 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13436   (eval "$ac_link") 2>conftest.er1
13437   ac_status=$?
13438   grep -v '^ *+' conftest.er1 >conftest.err
13439   rm -f conftest.er1
13440   cat conftest.err >&5
13441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13442   (exit $ac_status); } && {
13443          test -z "$ac_c_werror_flag" ||
13444          test ! -s conftest.err
13445        } && test -s conftest$ac_exeext &&
13446        $as_test_x conftest$ac_exeext; then
13447   ac_cv_var_tzname=yes
13448 else
13449   echo "$as_me: failed program was:" >&5
13450 sed 's/^/| /' conftest.$ac_ext >&5
13451
13452         ac_cv_var_tzname=no
13453 fi
13454
13455 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13456       conftest$ac_exeext conftest.$ac_ext
13457 fi
13458 { echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
13459 echo "${ECHO_T}$ac_cv_var_tzname" >&6; }
13460 if test $ac_cv_var_tzname = yes; then
13461
13462 cat >>confdefs.h <<\_ACEOF
13463 #define HAVE_TZNAME 1
13464 _ACEOF
13465
13466 fi
13467
13468 { echo "$as_me:$LINENO: checking for union semun" >&5
13469 echo $ECHO_N "checking for union semun... $ECHO_C" >&6; }
13470 if test "${ac_cv_type_union_semun+set}" = set; then
13471   echo $ECHO_N "(cached) $ECHO_C" >&6
13472 else
13473   cat >conftest.$ac_ext <<_ACEOF
13474 /* confdefs.h.  */
13475 _ACEOF
13476 cat confdefs.h >>conftest.$ac_ext
13477 cat >>conftest.$ac_ext <<_ACEOF
13478 /* end confdefs.h.  */
13479 #include <sys/types.h>
13480 #include <sys/ipc.h>
13481 #include <sys/sem.h>
13482
13483 typedef union semun ac__type_new_;
13484 int
13485 main ()
13486 {
13487 if ((ac__type_new_ *) 0)
13488   return 0;
13489 if (sizeof (ac__type_new_))
13490   return 0;
13491   ;
13492   return 0;
13493 }
13494 _ACEOF
13495 rm -f conftest.$ac_objext
13496 if { (ac_try="$ac_compile"
13497 case "(($ac_try" in
13498   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13499   *) ac_try_echo=$ac_try;;
13500 esac
13501 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13502   (eval "$ac_compile") 2>conftest.er1
13503   ac_status=$?
13504   grep -v '^ *+' conftest.er1 >conftest.err
13505   rm -f conftest.er1
13506   cat conftest.err >&5
13507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13508   (exit $ac_status); } && {
13509          test -z "$ac_c_werror_flag" ||
13510          test ! -s conftest.err
13511        } && test -s conftest.$ac_objext; then
13512   ac_cv_type_union_semun=yes
13513 else
13514   echo "$as_me: failed program was:" >&5
13515 sed 's/^/| /' conftest.$ac_ext >&5
13516
13517         ac_cv_type_union_semun=no
13518 fi
13519
13520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13521 fi
13522 { echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
13523 echo "${ECHO_T}$ac_cv_type_union_semun" >&6; }
13524 if test $ac_cv_type_union_semun = yes; then
13525
13526 cat >>confdefs.h <<_ACEOF
13527 #define HAVE_UNION_SEMUN 1
13528 _ACEOF
13529
13530
13531 fi
13532
13533 { echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
13534 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6; }
13535 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
13536   echo $ECHO_N "(cached) $ECHO_C" >&6
13537 else
13538   cat >conftest.$ac_ext <<_ACEOF
13539 /* confdefs.h.  */
13540 _ACEOF
13541 cat confdefs.h >>conftest.$ac_ext
13542 cat >>conftest.$ac_ext <<_ACEOF
13543 /* end confdefs.h.  */
13544 #include <sys/types.h>
13545 #ifdef HAVE_SYS_UN_H
13546 #include <sys/un.h>
13547 #endif
13548
13549
13550 typedef struct sockaddr_un ac__type_new_;
13551 int
13552 main ()
13553 {
13554 if ((ac__type_new_ *) 0)
13555   return 0;
13556 if (sizeof (ac__type_new_))
13557   return 0;
13558   ;
13559   return 0;
13560 }
13561 _ACEOF
13562 rm -f conftest.$ac_objext
13563 if { (ac_try="$ac_compile"
13564 case "(($ac_try" in
13565   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13566   *) ac_try_echo=$ac_try;;
13567 esac
13568 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13569   (eval "$ac_compile") 2>conftest.er1
13570   ac_status=$?
13571   grep -v '^ *+' conftest.er1 >conftest.err
13572   rm -f conftest.er1
13573   cat conftest.err >&5
13574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13575   (exit $ac_status); } && {
13576          test -z "$ac_c_werror_flag" ||
13577          test ! -s conftest.err
13578        } && test -s conftest.$ac_objext; then
13579   ac_cv_type_struct_sockaddr_un=yes
13580 else
13581   echo "$as_me: failed program was:" >&5
13582 sed 's/^/| /' conftest.$ac_ext >&5
13583
13584         ac_cv_type_struct_sockaddr_un=no
13585 fi
13586
13587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13588 fi
13589 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
13590 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6; }
13591 if test $ac_cv_type_struct_sockaddr_un = yes; then
13592
13593 cat >>confdefs.h <<_ACEOF
13594 #define HAVE_STRUCT_SOCKADDR_UN 1
13595 _ACEOF
13596
13597
13598 cat >>confdefs.h <<\_ACEOF
13599 #define HAVE_UNIX_SOCKETS 1
13600 _ACEOF
13601
13602 fi
13603
13604 { echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
13605 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6; }
13606 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
13607   echo $ECHO_N "(cached) $ECHO_C" >&6
13608 else
13609   cat >conftest.$ac_ext <<_ACEOF
13610 /* confdefs.h.  */
13611 _ACEOF
13612 cat confdefs.h >>conftest.$ac_ext
13613 cat >>conftest.$ac_ext <<_ACEOF
13614 /* end confdefs.h.  */
13615 #include <sys/types.h>
13616 #ifdef HAVE_SYS_SOCKET_H
13617 #include <sys/socket.h>
13618 #endif
13619
13620
13621 typedef struct sockaddr_storage ac__type_new_;
13622 int
13623 main ()
13624 {
13625 if ((ac__type_new_ *) 0)
13626   return 0;
13627 if (sizeof (ac__type_new_))
13628   return 0;
13629   ;
13630   return 0;
13631 }
13632 _ACEOF
13633 rm -f conftest.$ac_objext
13634 if { (ac_try="$ac_compile"
13635 case "(($ac_try" in
13636   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13637   *) ac_try_echo=$ac_try;;
13638 esac
13639 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13640   (eval "$ac_compile") 2>conftest.er1
13641   ac_status=$?
13642   grep -v '^ *+' conftest.er1 >conftest.err
13643   rm -f conftest.er1
13644   cat conftest.err >&5
13645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13646   (exit $ac_status); } && {
13647          test -z "$ac_c_werror_flag" ||
13648          test ! -s conftest.err
13649        } && test -s conftest.$ac_objext; then
13650   ac_cv_type_struct_sockaddr_storage=yes
13651 else
13652   echo "$as_me: failed program was:" >&5
13653 sed 's/^/| /' conftest.$ac_ext >&5
13654
13655         ac_cv_type_struct_sockaddr_storage=no
13656 fi
13657
13658 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13659 fi
13660 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
13661 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6; }
13662 if test $ac_cv_type_struct_sockaddr_storage = yes; then
13663
13664 cat >>confdefs.h <<_ACEOF
13665 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
13666 _ACEOF
13667
13668
13669 fi
13670
13671 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
13672 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6; }
13673 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
13674   echo $ECHO_N "(cached) $ECHO_C" >&6
13675 else
13676   cat >conftest.$ac_ext <<_ACEOF
13677 /* confdefs.h.  */
13678 _ACEOF
13679 cat confdefs.h >>conftest.$ac_ext
13680 cat >>conftest.$ac_ext <<_ACEOF
13681 /* end confdefs.h.  */
13682 #include <sys/types.h>
13683 #ifdef HAVE_SYS_SOCKET_H
13684 #include <sys/socket.h>
13685 #endif
13686
13687
13688 int
13689 main ()
13690 {
13691 static struct sockaddr_storage ac_aggr;
13692 if (ac_aggr.ss_family)
13693 return 0;
13694   ;
13695   return 0;
13696 }
13697 _ACEOF
13698 rm -f conftest.$ac_objext
13699 if { (ac_try="$ac_compile"
13700 case "(($ac_try" in
13701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13702   *) ac_try_echo=$ac_try;;
13703 esac
13704 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13705   (eval "$ac_compile") 2>conftest.er1
13706   ac_status=$?
13707   grep -v '^ *+' conftest.er1 >conftest.err
13708   rm -f conftest.er1
13709   cat conftest.err >&5
13710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13711   (exit $ac_status); } && {
13712          test -z "$ac_c_werror_flag" ||
13713          test ! -s conftest.err
13714        } && test -s conftest.$ac_objext; then
13715   ac_cv_member_struct_sockaddr_storage_ss_family=yes
13716 else
13717   echo "$as_me: failed program was:" >&5
13718 sed 's/^/| /' conftest.$ac_ext >&5
13719
13720         cat >conftest.$ac_ext <<_ACEOF
13721 /* confdefs.h.  */
13722 _ACEOF
13723 cat confdefs.h >>conftest.$ac_ext
13724 cat >>conftest.$ac_ext <<_ACEOF
13725 /* end confdefs.h.  */
13726 #include <sys/types.h>
13727 #ifdef HAVE_SYS_SOCKET_H
13728 #include <sys/socket.h>
13729 #endif
13730
13731
13732 int
13733 main ()
13734 {
13735 static struct sockaddr_storage ac_aggr;
13736 if (sizeof ac_aggr.ss_family)
13737 return 0;
13738   ;
13739   return 0;
13740 }
13741 _ACEOF
13742 rm -f conftest.$ac_objext
13743 if { (ac_try="$ac_compile"
13744 case "(($ac_try" in
13745   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13746   *) ac_try_echo=$ac_try;;
13747 esac
13748 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13749   (eval "$ac_compile") 2>conftest.er1
13750   ac_status=$?
13751   grep -v '^ *+' conftest.er1 >conftest.err
13752   rm -f conftest.er1
13753   cat conftest.err >&5
13754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13755   (exit $ac_status); } && {
13756          test -z "$ac_c_werror_flag" ||
13757          test ! -s conftest.err
13758        } && test -s conftest.$ac_objext; then
13759   ac_cv_member_struct_sockaddr_storage_ss_family=yes
13760 else
13761   echo "$as_me: failed program was:" >&5
13762 sed 's/^/| /' conftest.$ac_ext >&5
13763
13764         ac_cv_member_struct_sockaddr_storage_ss_family=no
13765 fi
13766
13767 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13768 fi
13769
13770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13771 fi
13772 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
13773 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
13774 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
13775
13776 cat >>confdefs.h <<_ACEOF
13777 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
13778 _ACEOF
13779
13780
13781 fi
13782 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
13783 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6; }
13784 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
13785   echo $ECHO_N "(cached) $ECHO_C" >&6
13786 else
13787   cat >conftest.$ac_ext <<_ACEOF
13788 /* confdefs.h.  */
13789 _ACEOF
13790 cat confdefs.h >>conftest.$ac_ext
13791 cat >>conftest.$ac_ext <<_ACEOF
13792 /* end confdefs.h.  */
13793 #include <sys/types.h>
13794 #ifdef HAVE_SYS_SOCKET_H
13795 #include <sys/socket.h>
13796 #endif
13797
13798
13799 int
13800 main ()
13801 {
13802 static struct sockaddr_storage ac_aggr;
13803 if (ac_aggr.__ss_family)
13804 return 0;
13805   ;
13806   return 0;
13807 }
13808 _ACEOF
13809 rm -f conftest.$ac_objext
13810 if { (ac_try="$ac_compile"
13811 case "(($ac_try" in
13812   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13813   *) ac_try_echo=$ac_try;;
13814 esac
13815 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13816   (eval "$ac_compile") 2>conftest.er1
13817   ac_status=$?
13818   grep -v '^ *+' conftest.er1 >conftest.err
13819   rm -f conftest.er1
13820   cat conftest.err >&5
13821   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13822   (exit $ac_status); } && {
13823          test -z "$ac_c_werror_flag" ||
13824          test ! -s conftest.err
13825        } && test -s conftest.$ac_objext; then
13826   ac_cv_member_struct_sockaddr_storage___ss_family=yes
13827 else
13828   echo "$as_me: failed program was:" >&5
13829 sed 's/^/| /' conftest.$ac_ext >&5
13830
13831         cat >conftest.$ac_ext <<_ACEOF
13832 /* confdefs.h.  */
13833 _ACEOF
13834 cat confdefs.h >>conftest.$ac_ext
13835 cat >>conftest.$ac_ext <<_ACEOF
13836 /* end confdefs.h.  */
13837 #include <sys/types.h>
13838 #ifdef HAVE_SYS_SOCKET_H
13839 #include <sys/socket.h>
13840 #endif
13841
13842
13843 int
13844 main ()
13845 {
13846 static struct sockaddr_storage ac_aggr;
13847 if (sizeof ac_aggr.__ss_family)
13848 return 0;
13849   ;
13850   return 0;
13851 }
13852 _ACEOF
13853 rm -f conftest.$ac_objext
13854 if { (ac_try="$ac_compile"
13855 case "(($ac_try" in
13856   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13857   *) ac_try_echo=$ac_try;;
13858 esac
13859 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13860   (eval "$ac_compile") 2>conftest.er1
13861   ac_status=$?
13862   grep -v '^ *+' conftest.er1 >conftest.err
13863   rm -f conftest.er1
13864   cat conftest.err >&5
13865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13866   (exit $ac_status); } && {
13867          test -z "$ac_c_werror_flag" ||
13868          test ! -s conftest.err
13869        } && test -s conftest.$ac_objext; then
13870   ac_cv_member_struct_sockaddr_storage___ss_family=yes
13871 else
13872   echo "$as_me: failed program was:" >&5
13873 sed 's/^/| /' conftest.$ac_ext >&5
13874
13875         ac_cv_member_struct_sockaddr_storage___ss_family=no
13876 fi
13877
13878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13879 fi
13880
13881 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13882 fi
13883 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
13884 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
13885 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
13886
13887 cat >>confdefs.h <<_ACEOF
13888 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
13889 _ACEOF
13890
13891
13892 fi
13893 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
13894 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6; }
13895 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
13896   echo $ECHO_N "(cached) $ECHO_C" >&6
13897 else
13898   cat >conftest.$ac_ext <<_ACEOF
13899 /* confdefs.h.  */
13900 _ACEOF
13901 cat confdefs.h >>conftest.$ac_ext
13902 cat >>conftest.$ac_ext <<_ACEOF
13903 /* end confdefs.h.  */
13904 #include <sys/types.h>
13905 #ifdef HAVE_SYS_SOCKET_H
13906 #include <sys/socket.h>
13907 #endif
13908
13909
13910 int
13911 main ()
13912 {
13913 static struct sockaddr_storage ac_aggr;
13914 if (ac_aggr.ss_len)
13915 return 0;
13916   ;
13917   return 0;
13918 }
13919 _ACEOF
13920 rm -f conftest.$ac_objext
13921 if { (ac_try="$ac_compile"
13922 case "(($ac_try" in
13923   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13924   *) ac_try_echo=$ac_try;;
13925 esac
13926 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13927   (eval "$ac_compile") 2>conftest.er1
13928   ac_status=$?
13929   grep -v '^ *+' conftest.er1 >conftest.err
13930   rm -f conftest.er1
13931   cat conftest.err >&5
13932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13933   (exit $ac_status); } && {
13934          test -z "$ac_c_werror_flag" ||
13935          test ! -s conftest.err
13936        } && test -s conftest.$ac_objext; then
13937   ac_cv_member_struct_sockaddr_storage_ss_len=yes
13938 else
13939   echo "$as_me: failed program was:" >&5
13940 sed 's/^/| /' conftest.$ac_ext >&5
13941
13942         cat >conftest.$ac_ext <<_ACEOF
13943 /* confdefs.h.  */
13944 _ACEOF
13945 cat confdefs.h >>conftest.$ac_ext
13946 cat >>conftest.$ac_ext <<_ACEOF
13947 /* end confdefs.h.  */
13948 #include <sys/types.h>
13949 #ifdef HAVE_SYS_SOCKET_H
13950 #include <sys/socket.h>
13951 #endif
13952
13953
13954 int
13955 main ()
13956 {
13957 static struct sockaddr_storage ac_aggr;
13958 if (sizeof ac_aggr.ss_len)
13959 return 0;
13960   ;
13961   return 0;
13962 }
13963 _ACEOF
13964 rm -f conftest.$ac_objext
13965 if { (ac_try="$ac_compile"
13966 case "(($ac_try" in
13967   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13968   *) ac_try_echo=$ac_try;;
13969 esac
13970 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13971   (eval "$ac_compile") 2>conftest.er1
13972   ac_status=$?
13973   grep -v '^ *+' conftest.er1 >conftest.err
13974   rm -f conftest.er1
13975   cat conftest.err >&5
13976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13977   (exit $ac_status); } && {
13978          test -z "$ac_c_werror_flag" ||
13979          test ! -s conftest.err
13980        } && test -s conftest.$ac_objext; then
13981   ac_cv_member_struct_sockaddr_storage_ss_len=yes
13982 else
13983   echo "$as_me: failed program was:" >&5
13984 sed 's/^/| /' conftest.$ac_ext >&5
13985
13986         ac_cv_member_struct_sockaddr_storage_ss_len=no
13987 fi
13988
13989 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13990 fi
13991
13992 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13993 fi
13994 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
13995 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
13996 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
13997
13998 cat >>confdefs.h <<_ACEOF
13999 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
14000 _ACEOF
14001
14002
14003 fi
14004 { echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
14005 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6; }
14006 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
14007   echo $ECHO_N "(cached) $ECHO_C" >&6
14008 else
14009   cat >conftest.$ac_ext <<_ACEOF
14010 /* confdefs.h.  */
14011 _ACEOF
14012 cat confdefs.h >>conftest.$ac_ext
14013 cat >>conftest.$ac_ext <<_ACEOF
14014 /* end confdefs.h.  */
14015 #include <sys/types.h>
14016 #ifdef HAVE_SYS_SOCKET_H
14017 #include <sys/socket.h>
14018 #endif
14019
14020
14021 int
14022 main ()
14023 {
14024 static struct sockaddr_storage ac_aggr;
14025 if (ac_aggr.__ss_len)
14026 return 0;
14027   ;
14028   return 0;
14029 }
14030 _ACEOF
14031 rm -f conftest.$ac_objext
14032 if { (ac_try="$ac_compile"
14033 case "(($ac_try" in
14034   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14035   *) ac_try_echo=$ac_try;;
14036 esac
14037 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14038   (eval "$ac_compile") 2>conftest.er1
14039   ac_status=$?
14040   grep -v '^ *+' conftest.er1 >conftest.err
14041   rm -f conftest.er1
14042   cat conftest.err >&5
14043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14044   (exit $ac_status); } && {
14045          test -z "$ac_c_werror_flag" ||
14046          test ! -s conftest.err
14047        } && test -s conftest.$ac_objext; then
14048   ac_cv_member_struct_sockaddr_storage___ss_len=yes
14049 else
14050   echo "$as_me: failed program was:" >&5
14051 sed 's/^/| /' conftest.$ac_ext >&5
14052
14053         cat >conftest.$ac_ext <<_ACEOF
14054 /* confdefs.h.  */
14055 _ACEOF
14056 cat confdefs.h >>conftest.$ac_ext
14057 cat >>conftest.$ac_ext <<_ACEOF
14058 /* end confdefs.h.  */
14059 #include <sys/types.h>
14060 #ifdef HAVE_SYS_SOCKET_H
14061 #include <sys/socket.h>
14062 #endif
14063
14064
14065 int
14066 main ()
14067 {
14068 static struct sockaddr_storage ac_aggr;
14069 if (sizeof ac_aggr.__ss_len)
14070 return 0;
14071   ;
14072   return 0;
14073 }
14074 _ACEOF
14075 rm -f conftest.$ac_objext
14076 if { (ac_try="$ac_compile"
14077 case "(($ac_try" in
14078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14079   *) ac_try_echo=$ac_try;;
14080 esac
14081 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14082   (eval "$ac_compile") 2>conftest.er1
14083   ac_status=$?
14084   grep -v '^ *+' conftest.er1 >conftest.err
14085   rm -f conftest.er1
14086   cat conftest.err >&5
14087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14088   (exit $ac_status); } && {
14089          test -z "$ac_c_werror_flag" ||
14090          test ! -s conftest.err
14091        } && test -s conftest.$ac_objext; then
14092   ac_cv_member_struct_sockaddr_storage___ss_len=yes
14093 else
14094   echo "$as_me: failed program was:" >&5
14095 sed 's/^/| /' conftest.$ac_ext >&5
14096
14097         ac_cv_member_struct_sockaddr_storage___ss_len=no
14098 fi
14099
14100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14101 fi
14102
14103 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14104 fi
14105 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
14106 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
14107 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
14108
14109 cat >>confdefs.h <<_ACEOF
14110 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
14111 _ACEOF
14112
14113
14114 fi
14115 { echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
14116 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6; }
14117 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
14118   echo $ECHO_N "(cached) $ECHO_C" >&6
14119 else
14120   cat >conftest.$ac_ext <<_ACEOF
14121 /* confdefs.h.  */
14122 _ACEOF
14123 cat confdefs.h >>conftest.$ac_ext
14124 cat >>conftest.$ac_ext <<_ACEOF
14125 /* end confdefs.h.  */
14126 #include <sys/types.h>
14127 #ifdef HAVE_SYS_SOCKET_H
14128 #include <sys/socket.h>
14129 #endif
14130
14131
14132 int
14133 main ()
14134 {
14135 static struct sockaddr ac_aggr;
14136 if (ac_aggr.sa_len)
14137 return 0;
14138   ;
14139   return 0;
14140 }
14141 _ACEOF
14142 rm -f conftest.$ac_objext
14143 if { (ac_try="$ac_compile"
14144 case "(($ac_try" in
14145   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14146   *) ac_try_echo=$ac_try;;
14147 esac
14148 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14149   (eval "$ac_compile") 2>conftest.er1
14150   ac_status=$?
14151   grep -v '^ *+' conftest.er1 >conftest.err
14152   rm -f conftest.er1
14153   cat conftest.err >&5
14154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14155   (exit $ac_status); } && {
14156          test -z "$ac_c_werror_flag" ||
14157          test ! -s conftest.err
14158        } && test -s conftest.$ac_objext; then
14159   ac_cv_member_struct_sockaddr_sa_len=yes
14160 else
14161   echo "$as_me: failed program was:" >&5
14162 sed 's/^/| /' conftest.$ac_ext >&5
14163
14164         cat >conftest.$ac_ext <<_ACEOF
14165 /* confdefs.h.  */
14166 _ACEOF
14167 cat confdefs.h >>conftest.$ac_ext
14168 cat >>conftest.$ac_ext <<_ACEOF
14169 /* end confdefs.h.  */
14170 #include <sys/types.h>
14171 #ifdef HAVE_SYS_SOCKET_H
14172 #include <sys/socket.h>
14173 #endif
14174
14175
14176 int
14177 main ()
14178 {
14179 static struct sockaddr ac_aggr;
14180 if (sizeof ac_aggr.sa_len)
14181 return 0;
14182   ;
14183   return 0;
14184 }
14185 _ACEOF
14186 rm -f conftest.$ac_objext
14187 if { (ac_try="$ac_compile"
14188 case "(($ac_try" in
14189   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14190   *) ac_try_echo=$ac_try;;
14191 esac
14192 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14193   (eval "$ac_compile") 2>conftest.er1
14194   ac_status=$?
14195   grep -v '^ *+' conftest.er1 >conftest.err
14196   rm -f conftest.er1
14197   cat conftest.err >&5
14198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14199   (exit $ac_status); } && {
14200          test -z "$ac_c_werror_flag" ||
14201          test ! -s conftest.err
14202        } && test -s conftest.$ac_objext; then
14203   ac_cv_member_struct_sockaddr_sa_len=yes
14204 else
14205   echo "$as_me: failed program was:" >&5
14206 sed 's/^/| /' conftest.$ac_ext >&5
14207
14208         ac_cv_member_struct_sockaddr_sa_len=no
14209 fi
14210
14211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14212 fi
14213
14214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14215 fi
14216 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
14217 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6; }
14218 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
14219
14220 cat >>confdefs.h <<_ACEOF
14221 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
14222 _ACEOF
14223
14224
14225 fi
14226
14227 { echo "$as_me:$LINENO: checking for struct addrinfo" >&5
14228 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6; }
14229 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
14230   echo $ECHO_N "(cached) $ECHO_C" >&6
14231 else
14232   cat >conftest.$ac_ext <<_ACEOF
14233 /* confdefs.h.  */
14234 _ACEOF
14235 cat confdefs.h >>conftest.$ac_ext
14236 cat >>conftest.$ac_ext <<_ACEOF
14237 /* end confdefs.h.  */
14238 #include <sys/types.h>
14239 #include <sys/socket.h>
14240 #include <netdb.h>
14241
14242
14243 typedef struct addrinfo ac__type_new_;
14244 int
14245 main ()
14246 {
14247 if ((ac__type_new_ *) 0)
14248   return 0;
14249 if (sizeof (ac__type_new_))
14250   return 0;
14251   ;
14252   return 0;
14253 }
14254 _ACEOF
14255 rm -f conftest.$ac_objext
14256 if { (ac_try="$ac_compile"
14257 case "(($ac_try" in
14258   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14259   *) ac_try_echo=$ac_try;;
14260 esac
14261 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14262   (eval "$ac_compile") 2>conftest.er1
14263   ac_status=$?
14264   grep -v '^ *+' conftest.er1 >conftest.err
14265   rm -f conftest.er1
14266   cat conftest.err >&5
14267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14268   (exit $ac_status); } && {
14269          test -z "$ac_c_werror_flag" ||
14270          test ! -s conftest.err
14271        } && test -s conftest.$ac_objext; then
14272   ac_cv_type_struct_addrinfo=yes
14273 else
14274   echo "$as_me: failed program was:" >&5
14275 sed 's/^/| /' conftest.$ac_ext >&5
14276
14277         ac_cv_type_struct_addrinfo=no
14278 fi
14279
14280 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14281 fi
14282 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
14283 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6; }
14284 if test $ac_cv_type_struct_addrinfo = yes; then
14285
14286 cat >>confdefs.h <<_ACEOF
14287 #define HAVE_STRUCT_ADDRINFO 1
14288 _ACEOF
14289
14290
14291 fi
14292
14293
14294 { echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
14295 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6; }
14296 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
14297   echo $ECHO_N "(cached) $ECHO_C" >&6
14298 else
14299   cat >conftest.$ac_ext <<_ACEOF
14300 /* confdefs.h.  */
14301 _ACEOF
14302 cat confdefs.h >>conftest.$ac_ext
14303 cat >>conftest.$ac_ext <<_ACEOF
14304 /* end confdefs.h.  */
14305 #include <sys/param.h>
14306 #include <sys/types.h>
14307 #include <sys/socket.h>
14308 #include <sys/ucred.h>
14309
14310 typedef struct cmsgcred ac__type_new_;
14311 int
14312 main ()
14313 {
14314 if ((ac__type_new_ *) 0)
14315   return 0;
14316 if (sizeof (ac__type_new_))
14317   return 0;
14318   ;
14319   return 0;
14320 }
14321 _ACEOF
14322 rm -f conftest.$ac_objext
14323 if { (ac_try="$ac_compile"
14324 case "(($ac_try" in
14325   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14326   *) ac_try_echo=$ac_try;;
14327 esac
14328 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14329   (eval "$ac_compile") 2>conftest.er1
14330   ac_status=$?
14331   grep -v '^ *+' conftest.er1 >conftest.err
14332   rm -f conftest.er1
14333   cat conftest.err >&5
14334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14335   (exit $ac_status); } && {
14336          test -z "$ac_c_werror_flag" ||
14337          test ! -s conftest.err
14338        } && test -s conftest.$ac_objext; then
14339   ac_cv_type_struct_cmsgcred=yes
14340 else
14341   echo "$as_me: failed program was:" >&5
14342 sed 's/^/| /' conftest.$ac_ext >&5
14343
14344         ac_cv_type_struct_cmsgcred=no
14345 fi
14346
14347 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14348 fi
14349 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
14350 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6; }
14351 if test $ac_cv_type_struct_cmsgcred = yes; then
14352
14353 cat >>confdefs.h <<_ACEOF
14354 #define HAVE_STRUCT_CMSGCRED 1
14355 _ACEOF
14356
14357
14358 fi
14359 { echo "$as_me:$LINENO: checking for struct fcred" >&5
14360 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6; }
14361 if test "${ac_cv_type_struct_fcred+set}" = set; then
14362   echo $ECHO_N "(cached) $ECHO_C" >&6
14363 else
14364   cat >conftest.$ac_ext <<_ACEOF
14365 /* confdefs.h.  */
14366 _ACEOF
14367 cat confdefs.h >>conftest.$ac_ext
14368 cat >>conftest.$ac_ext <<_ACEOF
14369 /* end confdefs.h.  */
14370 #include <sys/param.h>
14371 #include <sys/types.h>
14372 #include <sys/socket.h>
14373 #include <sys/ucred.h>
14374
14375 typedef struct fcred ac__type_new_;
14376 int
14377 main ()
14378 {
14379 if ((ac__type_new_ *) 0)
14380   return 0;
14381 if (sizeof (ac__type_new_))
14382   return 0;
14383   ;
14384   return 0;
14385 }
14386 _ACEOF
14387 rm -f conftest.$ac_objext
14388 if { (ac_try="$ac_compile"
14389 case "(($ac_try" in
14390   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14391   *) ac_try_echo=$ac_try;;
14392 esac
14393 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14394   (eval "$ac_compile") 2>conftest.er1
14395   ac_status=$?
14396   grep -v '^ *+' conftest.er1 >conftest.err
14397   rm -f conftest.er1
14398   cat conftest.err >&5
14399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14400   (exit $ac_status); } && {
14401          test -z "$ac_c_werror_flag" ||
14402          test ! -s conftest.err
14403        } && test -s conftest.$ac_objext; then
14404   ac_cv_type_struct_fcred=yes
14405 else
14406   echo "$as_me: failed program was:" >&5
14407 sed 's/^/| /' conftest.$ac_ext >&5
14408
14409         ac_cv_type_struct_fcred=no
14410 fi
14411
14412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14413 fi
14414 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
14415 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6; }
14416 if test $ac_cv_type_struct_fcred = yes; then
14417
14418 cat >>confdefs.h <<_ACEOF
14419 #define HAVE_STRUCT_FCRED 1
14420 _ACEOF
14421
14422
14423 fi
14424 { echo "$as_me:$LINENO: checking for struct sockcred" >&5
14425 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6; }
14426 if test "${ac_cv_type_struct_sockcred+set}" = set; then
14427   echo $ECHO_N "(cached) $ECHO_C" >&6
14428 else
14429   cat >conftest.$ac_ext <<_ACEOF
14430 /* confdefs.h.  */
14431 _ACEOF
14432 cat confdefs.h >>conftest.$ac_ext
14433 cat >>conftest.$ac_ext <<_ACEOF
14434 /* end confdefs.h.  */
14435 #include <sys/param.h>
14436 #include <sys/types.h>
14437 #include <sys/socket.h>
14438 #include <sys/ucred.h>
14439
14440 typedef struct sockcred ac__type_new_;
14441 int
14442 main ()
14443 {
14444 if ((ac__type_new_ *) 0)
14445   return 0;
14446 if (sizeof (ac__type_new_))
14447   return 0;
14448   ;
14449   return 0;
14450 }
14451 _ACEOF
14452 rm -f conftest.$ac_objext
14453 if { (ac_try="$ac_compile"
14454 case "(($ac_try" in
14455   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14456   *) ac_try_echo=$ac_try;;
14457 esac
14458 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14459   (eval "$ac_compile") 2>conftest.er1
14460   ac_status=$?
14461   grep -v '^ *+' conftest.er1 >conftest.err
14462   rm -f conftest.er1
14463   cat conftest.err >&5
14464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14465   (exit $ac_status); } && {
14466          test -z "$ac_c_werror_flag" ||
14467          test ! -s conftest.err
14468        } && test -s conftest.$ac_objext; then
14469   ac_cv_type_struct_sockcred=yes
14470 else
14471   echo "$as_me: failed program was:" >&5
14472 sed 's/^/| /' conftest.$ac_ext >&5
14473
14474         ac_cv_type_struct_sockcred=no
14475 fi
14476
14477 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14478 fi
14479 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
14480 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6; }
14481 if test $ac_cv_type_struct_sockcred = yes; then
14482
14483 cat >>confdefs.h <<_ACEOF
14484 #define HAVE_STRUCT_SOCKCRED 1
14485 _ACEOF
14486
14487
14488 fi
14489
14490
14491 { echo "$as_me:$LINENO: checking for struct option" >&5
14492 echo $ECHO_N "checking for struct option... $ECHO_C" >&6; }
14493 if test "${ac_cv_type_struct_option+set}" = set; then
14494   echo $ECHO_N "(cached) $ECHO_C" >&6
14495 else
14496   cat >conftest.$ac_ext <<_ACEOF
14497 /* confdefs.h.  */
14498 _ACEOF
14499 cat confdefs.h >>conftest.$ac_ext
14500 cat >>conftest.$ac_ext <<_ACEOF
14501 /* end confdefs.h.  */
14502 #ifdef HAVE_GETOPT_H
14503 #include <getopt.h>
14504 #endif
14505
14506 typedef struct option ac__type_new_;
14507 int
14508 main ()
14509 {
14510 if ((ac__type_new_ *) 0)
14511   return 0;
14512 if (sizeof (ac__type_new_))
14513   return 0;
14514   ;
14515   return 0;
14516 }
14517 _ACEOF
14518 rm -f conftest.$ac_objext
14519 if { (ac_try="$ac_compile"
14520 case "(($ac_try" in
14521   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14522   *) ac_try_echo=$ac_try;;
14523 esac
14524 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14525   (eval "$ac_compile") 2>conftest.er1
14526   ac_status=$?
14527   grep -v '^ *+' conftest.er1 >conftest.err
14528   rm -f conftest.er1
14529   cat conftest.err >&5
14530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14531   (exit $ac_status); } && {
14532          test -z "$ac_c_werror_flag" ||
14533          test ! -s conftest.err
14534        } && test -s conftest.$ac_objext; then
14535   ac_cv_type_struct_option=yes
14536 else
14537   echo "$as_me: failed program was:" >&5
14538 sed 's/^/| /' conftest.$ac_ext >&5
14539
14540         ac_cv_type_struct_option=no
14541 fi
14542
14543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14544 fi
14545 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
14546 echo "${ECHO_T}$ac_cv_type_struct_option" >&6; }
14547 if test $ac_cv_type_struct_option = yes; then
14548
14549 cat >>confdefs.h <<_ACEOF
14550 #define HAVE_STRUCT_OPTION 1
14551 _ACEOF
14552
14553
14554 fi
14555
14556
14557 if test "$with_zlib" = yes; then
14558   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
14559   # did not).  While we could work around the lack of z_streamp, it
14560   # seems unwise to encourage people to use such old zlib versions...
14561   { echo "$as_me:$LINENO: checking for z_streamp" >&5
14562 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6; }
14563 if test "${ac_cv_type_z_streamp+set}" = set; then
14564   echo $ECHO_N "(cached) $ECHO_C" >&6
14565 else
14566   cat >conftest.$ac_ext <<_ACEOF
14567 /* confdefs.h.  */
14568 _ACEOF
14569 cat confdefs.h >>conftest.$ac_ext
14570 cat >>conftest.$ac_ext <<_ACEOF
14571 /* end confdefs.h.  */
14572 #include <zlib.h>
14573
14574 typedef z_streamp ac__type_new_;
14575 int
14576 main ()
14577 {
14578 if ((ac__type_new_ *) 0)
14579   return 0;
14580 if (sizeof (ac__type_new_))
14581   return 0;
14582   ;
14583   return 0;
14584 }
14585 _ACEOF
14586 rm -f conftest.$ac_objext
14587 if { (ac_try="$ac_compile"
14588 case "(($ac_try" in
14589   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14590   *) ac_try_echo=$ac_try;;
14591 esac
14592 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14593   (eval "$ac_compile") 2>conftest.er1
14594   ac_status=$?
14595   grep -v '^ *+' conftest.er1 >conftest.err
14596   rm -f conftest.er1
14597   cat conftest.err >&5
14598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14599   (exit $ac_status); } && {
14600          test -z "$ac_c_werror_flag" ||
14601          test ! -s conftest.err
14602        } && test -s conftest.$ac_objext; then
14603   ac_cv_type_z_streamp=yes
14604 else
14605   echo "$as_me: failed program was:" >&5
14606 sed 's/^/| /' conftest.$ac_ext >&5
14607
14608         ac_cv_type_z_streamp=no
14609 fi
14610
14611 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14612 fi
14613 { echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
14614 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6; }
14615 if test $ac_cv_type_z_streamp = yes; then
14616   :
14617 else
14618   { { echo "$as_me:$LINENO: error: zlib version is too old
14619 Use --without-zlib to disable zlib support." >&5
14620 echo "$as_me: error: zlib version is too old
14621 Use --without-zlib to disable zlib support." >&2;}
14622    { (exit 1); exit 1; }; }
14623 fi
14624
14625 fi
14626
14627 if test "$with_krb5" = yes; then
14628 # Check for differences between MIT and Heimdal (KTH) releases
14629   { echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
14630 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6; }
14631 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
14632   echo $ECHO_N "(cached) $ECHO_C" >&6
14633 else
14634   cat >conftest.$ac_ext <<_ACEOF
14635 /* confdefs.h.  */
14636 _ACEOF
14637 cat confdefs.h >>conftest.$ac_ext
14638 cat >>conftest.$ac_ext <<_ACEOF
14639 /* end confdefs.h.  */
14640 #include <krb5.h>
14641
14642 int
14643 main ()
14644 {
14645 static krb5_ticket ac_aggr;
14646 if (ac_aggr.enc_part2)
14647 return 0;
14648   ;
14649   return 0;
14650 }
14651 _ACEOF
14652 rm -f conftest.$ac_objext
14653 if { (ac_try="$ac_compile"
14654 case "(($ac_try" in
14655   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14656   *) ac_try_echo=$ac_try;;
14657 esac
14658 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14659   (eval "$ac_compile") 2>conftest.er1
14660   ac_status=$?
14661   grep -v '^ *+' conftest.er1 >conftest.err
14662   rm -f conftest.er1
14663   cat conftest.err >&5
14664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14665   (exit $ac_status); } && {
14666          test -z "$ac_c_werror_flag" ||
14667          test ! -s conftest.err
14668        } && test -s conftest.$ac_objext; then
14669   ac_cv_member_krb5_ticket_enc_part2=yes
14670 else
14671   echo "$as_me: failed program was:" >&5
14672 sed 's/^/| /' conftest.$ac_ext >&5
14673
14674         cat >conftest.$ac_ext <<_ACEOF
14675 /* confdefs.h.  */
14676 _ACEOF
14677 cat confdefs.h >>conftest.$ac_ext
14678 cat >>conftest.$ac_ext <<_ACEOF
14679 /* end confdefs.h.  */
14680 #include <krb5.h>
14681
14682 int
14683 main ()
14684 {
14685 static krb5_ticket ac_aggr;
14686 if (sizeof ac_aggr.enc_part2)
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_member_krb5_ticket_enc_part2=yes
14710 else
14711   echo "$as_me: failed program was:" >&5
14712 sed 's/^/| /' conftest.$ac_ext >&5
14713
14714         ac_cv_member_krb5_ticket_enc_part2=no
14715 fi
14716
14717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14718 fi
14719
14720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14721 fi
14722 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
14723 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6; }
14724 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
14725
14726 cat >>confdefs.h <<_ACEOF
14727 #define HAVE_KRB5_TICKET_ENC_PART2 1
14728 _ACEOF
14729
14730
14731 else
14732   { echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
14733 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6; }
14734 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
14735   echo $ECHO_N "(cached) $ECHO_C" >&6
14736 else
14737   cat >conftest.$ac_ext <<_ACEOF
14738 /* confdefs.h.  */
14739 _ACEOF
14740 cat confdefs.h >>conftest.$ac_ext
14741 cat >>conftest.$ac_ext <<_ACEOF
14742 /* end confdefs.h.  */
14743 #include <krb5.h>
14744
14745 int
14746 main ()
14747 {
14748 static krb5_ticket ac_aggr;
14749 if (ac_aggr.client)
14750 return 0;
14751   ;
14752   return 0;
14753 }
14754 _ACEOF
14755 rm -f conftest.$ac_objext
14756 if { (ac_try="$ac_compile"
14757 case "(($ac_try" in
14758   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14759   *) ac_try_echo=$ac_try;;
14760 esac
14761 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14762   (eval "$ac_compile") 2>conftest.er1
14763   ac_status=$?
14764   grep -v '^ *+' conftest.er1 >conftest.err
14765   rm -f conftest.er1
14766   cat conftest.err >&5
14767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14768   (exit $ac_status); } && {
14769          test -z "$ac_c_werror_flag" ||
14770          test ! -s conftest.err
14771        } && test -s conftest.$ac_objext; then
14772   ac_cv_member_krb5_ticket_client=yes
14773 else
14774   echo "$as_me: failed program was:" >&5
14775 sed 's/^/| /' conftest.$ac_ext >&5
14776
14777         cat >conftest.$ac_ext <<_ACEOF
14778 /* confdefs.h.  */
14779 _ACEOF
14780 cat confdefs.h >>conftest.$ac_ext
14781 cat >>conftest.$ac_ext <<_ACEOF
14782 /* end confdefs.h.  */
14783 #include <krb5.h>
14784
14785 int
14786 main ()
14787 {
14788 static krb5_ticket ac_aggr;
14789 if (sizeof ac_aggr.client)
14790 return 0;
14791   ;
14792   return 0;
14793 }
14794 _ACEOF
14795 rm -f conftest.$ac_objext
14796 if { (ac_try="$ac_compile"
14797 case "(($ac_try" in
14798   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14799   *) ac_try_echo=$ac_try;;
14800 esac
14801 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14802   (eval "$ac_compile") 2>conftest.er1
14803   ac_status=$?
14804   grep -v '^ *+' conftest.er1 >conftest.err
14805   rm -f conftest.er1
14806   cat conftest.err >&5
14807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14808   (exit $ac_status); } && {
14809          test -z "$ac_c_werror_flag" ||
14810          test ! -s conftest.err
14811        } && test -s conftest.$ac_objext; then
14812   ac_cv_member_krb5_ticket_client=yes
14813 else
14814   echo "$as_me: failed program was:" >&5
14815 sed 's/^/| /' conftest.$ac_ext >&5
14816
14817         ac_cv_member_krb5_ticket_client=no
14818 fi
14819
14820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14821 fi
14822
14823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14824 fi
14825 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
14826 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6; }
14827 if test $ac_cv_member_krb5_ticket_client = yes; then
14828
14829 cat >>confdefs.h <<_ACEOF
14830 #define HAVE_KRB5_TICKET_CLIENT 1
14831 _ACEOF
14832
14833
14834 else
14835   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
14836 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
14837    { (exit 1); exit 1; }; }
14838 fi
14839
14840 fi
14841
14842   { echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
14843 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6; }
14844 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
14845   echo $ECHO_N "(cached) $ECHO_C" >&6
14846 else
14847   cat >conftest.$ac_ext <<_ACEOF
14848 /* confdefs.h.  */
14849 _ACEOF
14850 cat confdefs.h >>conftest.$ac_ext
14851 cat >>conftest.$ac_ext <<_ACEOF
14852 /* end confdefs.h.  */
14853 #include <krb5.h>
14854
14855 int
14856 main ()
14857 {
14858 static krb5_error ac_aggr;
14859 if (ac_aggr.text.data)
14860 return 0;
14861   ;
14862   return 0;
14863 }
14864 _ACEOF
14865 rm -f conftest.$ac_objext
14866 if { (ac_try="$ac_compile"
14867 case "(($ac_try" in
14868   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14869   *) ac_try_echo=$ac_try;;
14870 esac
14871 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14872   (eval "$ac_compile") 2>conftest.er1
14873   ac_status=$?
14874   grep -v '^ *+' conftest.er1 >conftest.err
14875   rm -f conftest.er1
14876   cat conftest.err >&5
14877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14878   (exit $ac_status); } && {
14879          test -z "$ac_c_werror_flag" ||
14880          test ! -s conftest.err
14881        } && test -s conftest.$ac_objext; then
14882   ac_cv_member_krb5_error_text_data=yes
14883 else
14884   echo "$as_me: failed program was:" >&5
14885 sed 's/^/| /' conftest.$ac_ext >&5
14886
14887         cat >conftest.$ac_ext <<_ACEOF
14888 /* confdefs.h.  */
14889 _ACEOF
14890 cat confdefs.h >>conftest.$ac_ext
14891 cat >>conftest.$ac_ext <<_ACEOF
14892 /* end confdefs.h.  */
14893 #include <krb5.h>
14894
14895 int
14896 main ()
14897 {
14898 static krb5_error ac_aggr;
14899 if (sizeof ac_aggr.text.data)
14900 return 0;
14901   ;
14902   return 0;
14903 }
14904 _ACEOF
14905 rm -f conftest.$ac_objext
14906 if { (ac_try="$ac_compile"
14907 case "(($ac_try" in
14908   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14909   *) ac_try_echo=$ac_try;;
14910 esac
14911 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14912   (eval "$ac_compile") 2>conftest.er1
14913   ac_status=$?
14914   grep -v '^ *+' conftest.er1 >conftest.err
14915   rm -f conftest.er1
14916   cat conftest.err >&5
14917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14918   (exit $ac_status); } && {
14919          test -z "$ac_c_werror_flag" ||
14920          test ! -s conftest.err
14921        } && test -s conftest.$ac_objext; then
14922   ac_cv_member_krb5_error_text_data=yes
14923 else
14924   echo "$as_me: failed program was:" >&5
14925 sed 's/^/| /' conftest.$ac_ext >&5
14926
14927         ac_cv_member_krb5_error_text_data=no
14928 fi
14929
14930 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14931 fi
14932
14933 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14934 fi
14935 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
14936 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6; }
14937 if test $ac_cv_member_krb5_error_text_data = yes; then
14938
14939 cat >>confdefs.h <<_ACEOF
14940 #define HAVE_KRB5_ERROR_TEXT_DATA 1
14941 _ACEOF
14942
14943
14944 else
14945   { echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
14946 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6; }
14947 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
14948   echo $ECHO_N "(cached) $ECHO_C" >&6
14949 else
14950   cat >conftest.$ac_ext <<_ACEOF
14951 /* confdefs.h.  */
14952 _ACEOF
14953 cat confdefs.h >>conftest.$ac_ext
14954 cat >>conftest.$ac_ext <<_ACEOF
14955 /* end confdefs.h.  */
14956 #include <krb5.h>
14957
14958 int
14959 main ()
14960 {
14961 static krb5_error ac_aggr;
14962 if (ac_aggr.e_data)
14963 return 0;
14964   ;
14965   return 0;
14966 }
14967 _ACEOF
14968 rm -f conftest.$ac_objext
14969 if { (ac_try="$ac_compile"
14970 case "(($ac_try" in
14971   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14972   *) ac_try_echo=$ac_try;;
14973 esac
14974 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14975   (eval "$ac_compile") 2>conftest.er1
14976   ac_status=$?
14977   grep -v '^ *+' conftest.er1 >conftest.err
14978   rm -f conftest.er1
14979   cat conftest.err >&5
14980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14981   (exit $ac_status); } && {
14982          test -z "$ac_c_werror_flag" ||
14983          test ! -s conftest.err
14984        } && test -s conftest.$ac_objext; then
14985   ac_cv_member_krb5_error_e_data=yes
14986 else
14987   echo "$as_me: failed program was:" >&5
14988 sed 's/^/| /' conftest.$ac_ext >&5
14989
14990         cat >conftest.$ac_ext <<_ACEOF
14991 /* confdefs.h.  */
14992 _ACEOF
14993 cat confdefs.h >>conftest.$ac_ext
14994 cat >>conftest.$ac_ext <<_ACEOF
14995 /* end confdefs.h.  */
14996 #include <krb5.h>
14997
14998 int
14999 main ()
15000 {
15001 static krb5_error ac_aggr;
15002 if (sizeof ac_aggr.e_data)
15003 return 0;
15004   ;
15005   return 0;
15006 }
15007 _ACEOF
15008 rm -f conftest.$ac_objext
15009 if { (ac_try="$ac_compile"
15010 case "(($ac_try" in
15011   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15012   *) ac_try_echo=$ac_try;;
15013 esac
15014 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15015   (eval "$ac_compile") 2>conftest.er1
15016   ac_status=$?
15017   grep -v '^ *+' conftest.er1 >conftest.err
15018   rm -f conftest.er1
15019   cat conftest.err >&5
15020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15021   (exit $ac_status); } && {
15022          test -z "$ac_c_werror_flag" ||
15023          test ! -s conftest.err
15024        } && test -s conftest.$ac_objext; then
15025   ac_cv_member_krb5_error_e_data=yes
15026 else
15027   echo "$as_me: failed program was:" >&5
15028 sed 's/^/| /' conftest.$ac_ext >&5
15029
15030         ac_cv_member_krb5_error_e_data=no
15031 fi
15032
15033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15034 fi
15035
15036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15037 fi
15038 { echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
15039 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6; }
15040 if test $ac_cv_member_krb5_error_e_data = yes; then
15041
15042 cat >>confdefs.h <<_ACEOF
15043 #define HAVE_KRB5_ERROR_E_DATA 1
15044 _ACEOF
15045
15046
15047 else
15048   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
15049 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
15050    { (exit 1); exit 1; }; }
15051 fi
15052
15053 fi
15054
15055
15056 # Win32 requires headers to be loaded for __stdcall, so can't use
15057 # AC_CHECK_FUNCS here.
15058   { echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
15059 echo $ECHO_N "checking for krb5_free_unparsed_name... $ECHO_C" >&6; }
15060   cat >conftest.$ac_ext <<_ACEOF
15061 /* confdefs.h.  */
15062 _ACEOF
15063 cat confdefs.h >>conftest.$ac_ext
15064 cat >>conftest.$ac_ext <<_ACEOF
15065 /* end confdefs.h.  */
15066 #include <krb5.h>
15067 int
15068 main ()
15069 {
15070 krb5_free_unparsed_name(NULL,NULL);
15071   ;
15072   return 0;
15073 }
15074 _ACEOF
15075 rm -f conftest.$ac_objext conftest$ac_exeext
15076 if { (ac_try="$ac_link"
15077 case "(($ac_try" in
15078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15079   *) ac_try_echo=$ac_try;;
15080 esac
15081 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15082   (eval "$ac_link") 2>conftest.er1
15083   ac_status=$?
15084   grep -v '^ *+' conftest.er1 >conftest.err
15085   rm -f conftest.er1
15086   cat conftest.err >&5
15087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15088   (exit $ac_status); } && {
15089          test -z "$ac_c_werror_flag" ||
15090          test ! -s conftest.err
15091        } && test -s conftest$ac_exeext &&
15092        $as_test_x conftest$ac_exeext; then
15093
15094 cat >>confdefs.h <<\_ACEOF
15095 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
15096 _ACEOF
15097
15098 { echo "$as_me:$LINENO: result: yes" >&5
15099 echo "${ECHO_T}yes" >&6; }
15100 else
15101   echo "$as_me: failed program was:" >&5
15102 sed 's/^/| /' conftest.$ac_ext >&5
15103
15104         { echo "$as_me:$LINENO: result: no" >&5
15105 echo "${ECHO_T}no" >&6; }
15106 fi
15107
15108 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15109       conftest$ac_exeext conftest.$ac_ext
15110 fi
15111
15112
15113 ##
15114 ## Functions, global variables
15115 ##
15116
15117 { echo "$as_me:$LINENO: checking for int timezone" >&5
15118 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6; }
15119 if test "${pgac_cv_var_int_timezone+set}" = set; then
15120   echo $ECHO_N "(cached) $ECHO_C" >&6
15121 else
15122   cat >conftest.$ac_ext <<_ACEOF
15123 /* confdefs.h.  */
15124 _ACEOF
15125 cat confdefs.h >>conftest.$ac_ext
15126 cat >>conftest.$ac_ext <<_ACEOF
15127 /* end confdefs.h.  */
15128 #include <time.h>
15129 int res;
15130 int
15131 main ()
15132 {
15133 #ifndef __CYGWIN__
15134 res = timezone / 60;
15135 #else
15136 res = _timezone / 60;
15137 #endif
15138   ;
15139   return 0;
15140 }
15141 _ACEOF
15142 rm -f conftest.$ac_objext conftest$ac_exeext
15143 if { (ac_try="$ac_link"
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_link") 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_exeext &&
15159        $as_test_x conftest$ac_exeext; then
15160   pgac_cv_var_int_timezone=yes
15161 else
15162   echo "$as_me: failed program was:" >&5
15163 sed 's/^/| /' conftest.$ac_ext >&5
15164
15165         pgac_cv_var_int_timezone=no
15166 fi
15167
15168 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15169       conftest$ac_exeext conftest.$ac_ext
15170 fi
15171 { echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
15172 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6; }
15173 if test x"$pgac_cv_var_int_timezone" = xyes ; then
15174
15175 cat >>confdefs.h <<\_ACEOF
15176 #define HAVE_INT_TIMEZONE
15177 _ACEOF
15178
15179 fi
15180 { echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
15181 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6; }
15182  if test "${ac_cv_func_accept_return+set}" = set; then
15183   echo $ECHO_N "(cached) $ECHO_C" >&6
15184 else
15185    if test "${ac_cv_func_accept_arg1+set}" = set; then
15186   echo $ECHO_N "(cached) $ECHO_C" >&6
15187 else
15188     if test "${ac_cv_func_accept_arg2+set}" = set; then
15189   echo $ECHO_N "(cached) $ECHO_C" >&6
15190 else
15191      if test "${ac_cv_func_accept_arg3+set}" = set; then
15192   echo $ECHO_N "(cached) $ECHO_C" >&6
15193 else
15194       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
15195       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
15196        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
15197         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
15198          cat >conftest.$ac_ext <<_ACEOF
15199 /* confdefs.h.  */
15200 _ACEOF
15201 cat confdefs.h >>conftest.$ac_ext
15202 cat >>conftest.$ac_ext <<_ACEOF
15203 /* end confdefs.h.  */
15204 #ifdef HAVE_SYS_TYPES_H
15205 #include <sys/types.h>
15206 #endif
15207 #ifdef HAVE_SYS_SOCKET_H
15208 #include <sys/socket.h>
15209 #endif
15210 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
15211 int
15212 main ()
15213 {
15214
15215   ;
15216   return 0;
15217 }
15218 _ACEOF
15219 rm -f conftest.$ac_objext
15220 if { (ac_try="$ac_compile"
15221 case "(($ac_try" in
15222   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15223   *) ac_try_echo=$ac_try;;
15224 esac
15225 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15226   (eval "$ac_compile") 2>conftest.er1
15227   ac_status=$?
15228   grep -v '^ *+' conftest.er1 >conftest.err
15229   rm -f conftest.er1
15230   cat conftest.err >&5
15231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15232   (exit $ac_status); } && {
15233          test -z "$ac_c_werror_flag" ||
15234          test ! -s conftest.err
15235        } && test -s conftest.$ac_objext; then
15236   ac_not_found=no; break 4
15237 else
15238   echo "$as_me: failed program was:" >&5
15239 sed 's/^/| /' conftest.$ac_ext >&5
15240
15241         ac_not_found=yes
15242 fi
15243
15244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15245        done
15246       done
15247      done
15248     done
15249     if test "$ac_not_found" = yes; then
15250       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
15251 echo "$as_me: error: could not determine argument types" >&2;}
15252    { (exit 1); exit 1; }; }
15253     fi
15254     if test "$ac_cv_func_accept_arg3" = "void"; then
15255       ac_cv_func_accept_arg3=int
15256     fi
15257
15258 fi
15259
15260 fi
15261
15262 fi
15263
15264 fi
15265  { 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
15266 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
15267
15268 cat >>confdefs.h <<_ACEOF
15269 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
15270 _ACEOF
15271
15272
15273 cat >>confdefs.h <<_ACEOF
15274 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
15275 _ACEOF
15276
15277
15278 cat >>confdefs.h <<_ACEOF
15279 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
15280 _ACEOF
15281
15282
15283 cat >>confdefs.h <<_ACEOF
15284 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
15285 _ACEOF
15286
15287
15288 { echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
15289 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6; }
15290 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
15291   echo $ECHO_N "(cached) $ECHO_C" >&6
15292 else
15293   cat >conftest.$ac_ext <<_ACEOF
15294 /* confdefs.h.  */
15295 _ACEOF
15296 cat confdefs.h >>conftest.$ac_ext
15297 cat >>conftest.$ac_ext <<_ACEOF
15298 /* end confdefs.h.  */
15299 #include <sys/time.h>
15300 int
15301 main ()
15302 {
15303 struct timeval *tp;
15304 struct timezone *tzp;
15305 gettimeofday(tp,tzp);
15306   ;
15307   return 0;
15308 }
15309 _ACEOF
15310 rm -f conftest.$ac_objext
15311 if { (ac_try="$ac_compile"
15312 case "(($ac_try" in
15313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15314   *) ac_try_echo=$ac_try;;
15315 esac
15316 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15317   (eval "$ac_compile") 2>conftest.er1
15318   ac_status=$?
15319   grep -v '^ *+' conftest.er1 >conftest.err
15320   rm -f conftest.er1
15321   cat conftest.err >&5
15322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15323   (exit $ac_status); } && {
15324          test -z "$ac_c_werror_flag" ||
15325          test ! -s conftest.err
15326        } && test -s conftest.$ac_objext; then
15327   pgac_cv_func_gettimeofday_1arg=no
15328 else
15329   echo "$as_me: failed program was:" >&5
15330 sed 's/^/| /' conftest.$ac_ext >&5
15331
15332         pgac_cv_func_gettimeofday_1arg=yes
15333 fi
15334
15335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15336 fi
15337 { echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
15338 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6; }
15339 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
15340
15341 cat >>confdefs.h <<\_ACEOF
15342 #define GETTIMEOFDAY_1ARG
15343 _ACEOF
15344
15345 fi
15346
15347
15348
15349
15350
15351
15352
15353
15354
15355
15356
15357
15358
15359
15360
15361
15362
15363
15364
15365
15366
15367
15368
15369 for ac_func in cbrt dlopen fcvt fdatasync getpeereid getrlimit memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
15370 do
15371 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15372 { echo "$as_me:$LINENO: checking for $ac_func" >&5
15373 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15374 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15375   echo $ECHO_N "(cached) $ECHO_C" >&6
15376 else
15377   cat >conftest.$ac_ext <<_ACEOF
15378 /* confdefs.h.  */
15379 _ACEOF
15380 cat confdefs.h >>conftest.$ac_ext
15381 cat >>conftest.$ac_ext <<_ACEOF
15382 /* end confdefs.h.  */
15383 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15384    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15385 #define $ac_func innocuous_$ac_func
15386
15387 /* System header to define __stub macros and hopefully few prototypes,
15388     which can conflict with char $ac_func (); below.
15389     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15390     <limits.h> exists even on freestanding compilers.  */
15391
15392 #ifdef __STDC__
15393 # include <limits.h>
15394 #else
15395 # include <assert.h>
15396 #endif
15397
15398 #undef $ac_func
15399
15400 /* Override any GCC internal prototype to avoid an error.
15401    Use char because int might match the return type of a GCC
15402    builtin and then its argument prototype would still apply.  */
15403 #ifdef __cplusplus
15404 extern "C"
15405 #endif
15406 char $ac_func ();
15407 /* The GNU C library defines this for functions which it implements
15408     to always fail with ENOSYS.  Some functions are actually named
15409     something starting with __ and the normal name is an alias.  */
15410 #if defined __stub_$ac_func || defined __stub___$ac_func
15411 choke me
15412 #endif
15413
15414 int
15415 main ()
15416 {
15417 return $ac_func ();
15418   ;
15419   return 0;
15420 }
15421 _ACEOF
15422 rm -f conftest.$ac_objext conftest$ac_exeext
15423 if { (ac_try="$ac_link"
15424 case "(($ac_try" in
15425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15426   *) ac_try_echo=$ac_try;;
15427 esac
15428 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15429   (eval "$ac_link") 2>conftest.er1
15430   ac_status=$?
15431   grep -v '^ *+' conftest.er1 >conftest.err
15432   rm -f conftest.er1
15433   cat conftest.err >&5
15434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15435   (exit $ac_status); } && {
15436          test -z "$ac_c_werror_flag" ||
15437          test ! -s conftest.err
15438        } && test -s conftest$ac_exeext &&
15439        $as_test_x conftest$ac_exeext; then
15440   eval "$as_ac_var=yes"
15441 else
15442   echo "$as_me: failed program was:" >&5
15443 sed 's/^/| /' conftest.$ac_ext >&5
15444
15445         eval "$as_ac_var=no"
15446 fi
15447
15448 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15449       conftest$ac_exeext conftest.$ac_ext
15450 fi
15451 ac_res=`eval echo '${'$as_ac_var'}'`
15452                { echo "$as_me:$LINENO: result: $ac_res" >&5
15453 echo "${ECHO_T}$ac_res" >&6; }
15454 if test `eval echo '${'$as_ac_var'}'` = yes; then
15455   cat >>confdefs.h <<_ACEOF
15456 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15457 _ACEOF
15458
15459 fi
15460 done
15461
15462
15463 { echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
15464 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6; }
15465 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
15466   echo $ECHO_N "(cached) $ECHO_C" >&6
15467 else
15468   cat >conftest.$ac_ext <<_ACEOF
15469 /* confdefs.h.  */
15470 _ACEOF
15471 cat confdefs.h >>conftest.$ac_ext
15472 cat >>conftest.$ac_ext <<_ACEOF
15473 /* end confdefs.h.  */
15474 #include <unistd.h>
15475
15476 int
15477 main ()
15478 {
15479 #ifndef fdatasync
15480   (void) fdatasync;
15481 #endif
15482
15483   ;
15484   return 0;
15485 }
15486 _ACEOF
15487 rm -f conftest.$ac_objext
15488 if { (ac_try="$ac_compile"
15489 case "(($ac_try" in
15490   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15491   *) ac_try_echo=$ac_try;;
15492 esac
15493 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15494   (eval "$ac_compile") 2>conftest.er1
15495   ac_status=$?
15496   grep -v '^ *+' conftest.er1 >conftest.err
15497   rm -f conftest.er1
15498   cat conftest.err >&5
15499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15500   (exit $ac_status); } && {
15501          test -z "$ac_c_werror_flag" ||
15502          test ! -s conftest.err
15503        } && test -s conftest.$ac_objext; then
15504   ac_cv_have_decl_fdatasync=yes
15505 else
15506   echo "$as_me: failed program was:" >&5
15507 sed 's/^/| /' conftest.$ac_ext >&5
15508
15509         ac_cv_have_decl_fdatasync=no
15510 fi
15511
15512 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15513 fi
15514 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
15515 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6; }
15516 if test $ac_cv_have_decl_fdatasync = yes; then
15517
15518 cat >>confdefs.h <<_ACEOF
15519 #define HAVE_DECL_FDATASYNC 1
15520 _ACEOF
15521
15522
15523 else
15524   cat >>confdefs.h <<_ACEOF
15525 #define HAVE_DECL_FDATASYNC 0
15526 _ACEOF
15527
15528
15529 fi
15530
15531
15532 { echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
15533 echo $ECHO_N "checking whether posix_fadvise is declared... $ECHO_C" >&6; }
15534 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
15535   echo $ECHO_N "(cached) $ECHO_C" >&6
15536 else
15537   cat >conftest.$ac_ext <<_ACEOF
15538 /* confdefs.h.  */
15539 _ACEOF
15540 cat confdefs.h >>conftest.$ac_ext
15541 cat >>conftest.$ac_ext <<_ACEOF
15542 /* end confdefs.h.  */
15543 #include <fcntl.h>
15544
15545 int
15546 main ()
15547 {
15548 #ifndef posix_fadvise
15549   (void) posix_fadvise;
15550 #endif
15551
15552   ;
15553   return 0;
15554 }
15555 _ACEOF
15556 rm -f conftest.$ac_objext
15557 if { (ac_try="$ac_compile"
15558 case "(($ac_try" in
15559   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15560   *) ac_try_echo=$ac_try;;
15561 esac
15562 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15563   (eval "$ac_compile") 2>conftest.er1
15564   ac_status=$?
15565   grep -v '^ *+' conftest.er1 >conftest.err
15566   rm -f conftest.er1
15567   cat conftest.err >&5
15568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15569   (exit $ac_status); } && {
15570          test -z "$ac_c_werror_flag" ||
15571          test ! -s conftest.err
15572        } && test -s conftest.$ac_objext; then
15573   ac_cv_have_decl_posix_fadvise=yes
15574 else
15575   echo "$as_me: failed program was:" >&5
15576 sed 's/^/| /' conftest.$ac_ext >&5
15577
15578         ac_cv_have_decl_posix_fadvise=no
15579 fi
15580
15581 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15582 fi
15583 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
15584 echo "${ECHO_T}$ac_cv_have_decl_posix_fadvise" >&6; }
15585 if test $ac_cv_have_decl_posix_fadvise = yes; then
15586
15587 cat >>confdefs.h <<_ACEOF
15588 #define HAVE_DECL_POSIX_FADVISE 1
15589 _ACEOF
15590
15591
15592 else
15593   cat >>confdefs.h <<_ACEOF
15594 #define HAVE_DECL_POSIX_FADVISE 0
15595 _ACEOF
15596
15597
15598 fi
15599
15600
15601 { echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
15602 echo $ECHO_N "checking whether strlcat is declared... $ECHO_C" >&6; }
15603 if test "${ac_cv_have_decl_strlcat+set}" = set; then
15604   echo $ECHO_N "(cached) $ECHO_C" >&6
15605 else
15606   cat >conftest.$ac_ext <<_ACEOF
15607 /* confdefs.h.  */
15608 _ACEOF
15609 cat confdefs.h >>conftest.$ac_ext
15610 cat >>conftest.$ac_ext <<_ACEOF
15611 /* end confdefs.h.  */
15612 $ac_includes_default
15613 int
15614 main ()
15615 {
15616 #ifndef strlcat
15617   (void) strlcat;
15618 #endif
15619
15620   ;
15621   return 0;
15622 }
15623 _ACEOF
15624 rm -f conftest.$ac_objext
15625 if { (ac_try="$ac_compile"
15626 case "(($ac_try" in
15627   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15628   *) ac_try_echo=$ac_try;;
15629 esac
15630 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15631   (eval "$ac_compile") 2>conftest.er1
15632   ac_status=$?
15633   grep -v '^ *+' conftest.er1 >conftest.err
15634   rm -f conftest.er1
15635   cat conftest.err >&5
15636   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15637   (exit $ac_status); } && {
15638          test -z "$ac_c_werror_flag" ||
15639          test ! -s conftest.err
15640        } && test -s conftest.$ac_objext; then
15641   ac_cv_have_decl_strlcat=yes
15642 else
15643   echo "$as_me: failed program was:" >&5
15644 sed 's/^/| /' conftest.$ac_ext >&5
15645
15646         ac_cv_have_decl_strlcat=no
15647 fi
15648
15649 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15650 fi
15651 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
15652 echo "${ECHO_T}$ac_cv_have_decl_strlcat" >&6; }
15653 if test $ac_cv_have_decl_strlcat = yes; then
15654
15655 cat >>confdefs.h <<_ACEOF
15656 #define HAVE_DECL_STRLCAT 1
15657 _ACEOF
15658
15659
15660 else
15661   cat >>confdefs.h <<_ACEOF
15662 #define HAVE_DECL_STRLCAT 0
15663 _ACEOF
15664
15665
15666 fi
15667 { echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
15668 echo $ECHO_N "checking whether strlcpy is declared... $ECHO_C" >&6; }
15669 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
15670   echo $ECHO_N "(cached) $ECHO_C" >&6
15671 else
15672   cat >conftest.$ac_ext <<_ACEOF
15673 /* confdefs.h.  */
15674 _ACEOF
15675 cat confdefs.h >>conftest.$ac_ext
15676 cat >>conftest.$ac_ext <<_ACEOF
15677 /* end confdefs.h.  */
15678 $ac_includes_default
15679 int
15680 main ()
15681 {
15682 #ifndef strlcpy
15683   (void) strlcpy;
15684 #endif
15685
15686   ;
15687   return 0;
15688 }
15689 _ACEOF
15690 rm -f conftest.$ac_objext
15691 if { (ac_try="$ac_compile"
15692 case "(($ac_try" in
15693   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15694   *) ac_try_echo=$ac_try;;
15695 esac
15696 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15697   (eval "$ac_compile") 2>conftest.er1
15698   ac_status=$?
15699   grep -v '^ *+' conftest.er1 >conftest.err
15700   rm -f conftest.er1
15701   cat conftest.err >&5
15702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15703   (exit $ac_status); } && {
15704          test -z "$ac_c_werror_flag" ||
15705          test ! -s conftest.err
15706        } && test -s conftest.$ac_objext; then
15707   ac_cv_have_decl_strlcpy=yes
15708 else
15709   echo "$as_me: failed program was:" >&5
15710 sed 's/^/| /' conftest.$ac_ext >&5
15711
15712         ac_cv_have_decl_strlcpy=no
15713 fi
15714
15715 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15716 fi
15717 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
15718 echo "${ECHO_T}$ac_cv_have_decl_strlcpy" >&6; }
15719 if test $ac_cv_have_decl_strlcpy = yes; then
15720
15721 cat >>confdefs.h <<_ACEOF
15722 #define HAVE_DECL_STRLCPY 1
15723 _ACEOF
15724
15725
15726 else
15727   cat >>confdefs.h <<_ACEOF
15728 #define HAVE_DECL_STRLCPY 0
15729 _ACEOF
15730
15731
15732 fi
15733
15734
15735 # This is probably only present on Darwin, but may as well check always
15736 { echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
15737 echo $ECHO_N "checking whether F_FULLFSYNC is declared... $ECHO_C" >&6; }
15738 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
15739   echo $ECHO_N "(cached) $ECHO_C" >&6
15740 else
15741   cat >conftest.$ac_ext <<_ACEOF
15742 /* confdefs.h.  */
15743 _ACEOF
15744 cat confdefs.h >>conftest.$ac_ext
15745 cat >>conftest.$ac_ext <<_ACEOF
15746 /* end confdefs.h.  */
15747 #include <fcntl.h>
15748
15749 int
15750 main ()
15751 {
15752 #ifndef F_FULLFSYNC
15753   (void) F_FULLFSYNC;
15754 #endif
15755
15756   ;
15757   return 0;
15758 }
15759 _ACEOF
15760 rm -f conftest.$ac_objext
15761 if { (ac_try="$ac_compile"
15762 case "(($ac_try" in
15763   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15764   *) ac_try_echo=$ac_try;;
15765 esac
15766 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15767   (eval "$ac_compile") 2>conftest.er1
15768   ac_status=$?
15769   grep -v '^ *+' conftest.er1 >conftest.err
15770   rm -f conftest.er1
15771   cat conftest.err >&5
15772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15773   (exit $ac_status); } && {
15774          test -z "$ac_c_werror_flag" ||
15775          test ! -s conftest.err
15776        } && test -s conftest.$ac_objext; then
15777   ac_cv_have_decl_F_FULLFSYNC=yes
15778 else
15779   echo "$as_me: failed program was:" >&5
15780 sed 's/^/| /' conftest.$ac_ext >&5
15781
15782         ac_cv_have_decl_F_FULLFSYNC=no
15783 fi
15784
15785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15786 fi
15787 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
15788 echo "${ECHO_T}$ac_cv_have_decl_F_FULLFSYNC" >&6; }
15789 if test $ac_cv_have_decl_F_FULLFSYNC = yes; then
15790
15791 cat >>confdefs.h <<_ACEOF
15792 #define HAVE_DECL_F_FULLFSYNC 1
15793 _ACEOF
15794
15795
15796 else
15797   cat >>confdefs.h <<_ACEOF
15798 #define HAVE_DECL_F_FULLFSYNC 0
15799 _ACEOF
15800
15801
15802 fi
15803
15804
15805
15806 HAVE_IPV6=no
15807 { echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
15808 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6; }
15809 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
15810   echo $ECHO_N "(cached) $ECHO_C" >&6
15811 else
15812   cat >conftest.$ac_ext <<_ACEOF
15813 /* confdefs.h.  */
15814 _ACEOF
15815 cat confdefs.h >>conftest.$ac_ext
15816 cat >>conftest.$ac_ext <<_ACEOF
15817 /* end confdefs.h.  */
15818 $ac_includes_default
15819 #include <netinet/in.h>
15820
15821 typedef struct sockaddr_in6 ac__type_new_;
15822 int
15823 main ()
15824 {
15825 if ((ac__type_new_ *) 0)
15826   return 0;
15827 if (sizeof (ac__type_new_))
15828   return 0;
15829   ;
15830   return 0;
15831 }
15832 _ACEOF
15833 rm -f conftest.$ac_objext
15834 if { (ac_try="$ac_compile"
15835 case "(($ac_try" in
15836   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15837   *) ac_try_echo=$ac_try;;
15838 esac
15839 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15840   (eval "$ac_compile") 2>conftest.er1
15841   ac_status=$?
15842   grep -v '^ *+' conftest.er1 >conftest.err
15843   rm -f conftest.er1
15844   cat conftest.err >&5
15845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15846   (exit $ac_status); } && {
15847          test -z "$ac_c_werror_flag" ||
15848          test ! -s conftest.err
15849        } && test -s conftest.$ac_objext; then
15850   ac_cv_type_struct_sockaddr_in6=yes
15851 else
15852   echo "$as_me: failed program was:" >&5
15853 sed 's/^/| /' conftest.$ac_ext >&5
15854
15855         ac_cv_type_struct_sockaddr_in6=no
15856 fi
15857
15858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15859 fi
15860 { echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
15861 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6; }
15862 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
15863
15864 cat >>confdefs.h <<\_ACEOF
15865 #define HAVE_IPV6 1
15866 _ACEOF
15867
15868          HAVE_IPV6=yes
15869 fi
15870
15871
15872
15873 { echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
15874 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6; }
15875 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
15876   echo $ECHO_N "(cached) $ECHO_C" >&6
15877 else
15878   cat >conftest.$ac_ext <<_ACEOF
15879 /* confdefs.h.  */
15880 _ACEOF
15881 cat confdefs.h >>conftest.$ac_ext
15882 cat >>conftest.$ac_ext <<_ACEOF
15883 /* end confdefs.h.  */
15884 #include <machine/vmparam.h>
15885 #include <sys/exec.h>
15886
15887 int
15888 main ()
15889 {
15890 PS_STRINGS->ps_nargvstr = 1;
15891 PS_STRINGS->ps_argvstr = "foo";
15892   ;
15893   return 0;
15894 }
15895 _ACEOF
15896 rm -f conftest.$ac_objext conftest$ac_exeext
15897 if { (ac_try="$ac_link"
15898 case "(($ac_try" in
15899   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15900   *) ac_try_echo=$ac_try;;
15901 esac
15902 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15903   (eval "$ac_link") 2>conftest.er1
15904   ac_status=$?
15905   grep -v '^ *+' conftest.er1 >conftest.err
15906   rm -f conftest.er1
15907   cat conftest.err >&5
15908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15909   (exit $ac_status); } && {
15910          test -z "$ac_c_werror_flag" ||
15911          test ! -s conftest.err
15912        } && test -s conftest$ac_exeext &&
15913        $as_test_x conftest$ac_exeext; then
15914   pgac_cv_var_PS_STRINGS=yes
15915 else
15916   echo "$as_me: failed program was:" >&5
15917 sed 's/^/| /' conftest.$ac_ext >&5
15918
15919         pgac_cv_var_PS_STRINGS=no
15920 fi
15921
15922 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15923       conftest$ac_exeext conftest.$ac_ext
15924 fi
15925 { echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
15926 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6; }
15927 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
15928
15929 cat >>confdefs.h <<\_ACEOF
15930 #define HAVE_PS_STRINGS
15931 _ACEOF
15932
15933 fi
15934
15935
15936 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
15937 # is missing.  Yes, there are machines that have only one.  We may
15938 # also decide to use snprintf.c if snprintf() is present but does not
15939 # have all the features we need --- see below.
15940
15941 if test "$PORTNAME" = "win32"; then
15942   # Win32 gets snprintf.c built unconditionally.
15943   #
15944   # To properly translate all NLS languages strings, we must support the
15945   # *printf() %$ format, which allows *printf() arguments to be selected
15946   # by position in the translated string.
15947   #
15948   # libintl versions < 0.13 use the native *printf() functions, and Win32
15949   # *printf() doesn't understand %$, so we must use our /port versions,
15950   # which do understand %$. libintl versions >= 0.13 include their own
15951   # *printf versions on Win32.  The libintl 0.13 release note text is:
15952   #
15953   #   C format strings with positions, as they arise when a translator
15954   #   needs to reorder a sentence, are now supported on all platforms.
15955   #   On those few platforms (NetBSD and Woe32) for which the native
15956   #   printf()/fprintf()/... functions don't support such format
15957   #   strings, replacements are provided through <libintl.h>.
15958   #
15959   # We could use libintl >= 0.13's *printf() if we were sure that we had
15960   # a litint >= 0.13 at runtime, but seeing that there is no clean way
15961   # to guarantee that, it is best to just use our own, so we are sure to
15962   # get %$ support. In include/port.h we disable the *printf() macros
15963   # that might have been defined by libintl.
15964   #
15965   # We do this unconditionally whether NLS is used or not so we are sure
15966   # that all Win32 libraries and binaries behave the same.
15967   pgac_need_repl_snprintf=yes
15968 else
15969   pgac_need_repl_snprintf=no
15970
15971 for ac_func in snprintf
15972 do
15973 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15974 { echo "$as_me:$LINENO: checking for $ac_func" >&5
15975 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15976 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15977   echo $ECHO_N "(cached) $ECHO_C" >&6
15978 else
15979   cat >conftest.$ac_ext <<_ACEOF
15980 /* confdefs.h.  */
15981 _ACEOF
15982 cat confdefs.h >>conftest.$ac_ext
15983 cat >>conftest.$ac_ext <<_ACEOF
15984 /* end confdefs.h.  */
15985 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15986    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15987 #define $ac_func innocuous_$ac_func
15988
15989 /* System header to define __stub macros and hopefully few prototypes,
15990     which can conflict with char $ac_func (); below.
15991     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15992     <limits.h> exists even on freestanding compilers.  */
15993
15994 #ifdef __STDC__
15995 # include <limits.h>
15996 #else
15997 # include <assert.h>
15998 #endif
15999
16000 #undef $ac_func
16001
16002 /* Override any GCC internal prototype to avoid an error.
16003    Use char because int might match the return type of a GCC
16004    builtin and then its argument prototype would still apply.  */
16005 #ifdef __cplusplus
16006 extern "C"
16007 #endif
16008 char $ac_func ();
16009 /* The GNU C library defines this for functions which it implements
16010     to always fail with ENOSYS.  Some functions are actually named
16011     something starting with __ and the normal name is an alias.  */
16012 #if defined __stub_$ac_func || defined __stub___$ac_func
16013 choke me
16014 #endif
16015
16016 int
16017 main ()
16018 {
16019 return $ac_func ();
16020   ;
16021   return 0;
16022 }
16023 _ACEOF
16024 rm -f conftest.$ac_objext conftest$ac_exeext
16025 if { (ac_try="$ac_link"
16026 case "(($ac_try" in
16027   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16028   *) ac_try_echo=$ac_try;;
16029 esac
16030 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16031   (eval "$ac_link") 2>conftest.er1
16032   ac_status=$?
16033   grep -v '^ *+' conftest.er1 >conftest.err
16034   rm -f conftest.er1
16035   cat conftest.err >&5
16036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16037   (exit $ac_status); } && {
16038          test -z "$ac_c_werror_flag" ||
16039          test ! -s conftest.err
16040        } && test -s conftest$ac_exeext &&
16041        $as_test_x conftest$ac_exeext; then
16042   eval "$as_ac_var=yes"
16043 else
16044   echo "$as_me: failed program was:" >&5
16045 sed 's/^/| /' conftest.$ac_ext >&5
16046
16047         eval "$as_ac_var=no"
16048 fi
16049
16050 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16051       conftest$ac_exeext conftest.$ac_ext
16052 fi
16053 ac_res=`eval echo '${'$as_ac_var'}'`
16054                { echo "$as_me:$LINENO: result: $ac_res" >&5
16055 echo "${ECHO_T}$ac_res" >&6; }
16056 if test `eval echo '${'$as_ac_var'}'` = yes; then
16057   cat >>confdefs.h <<_ACEOF
16058 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16059 _ACEOF
16060
16061 else
16062   pgac_need_repl_snprintf=yes
16063 fi
16064 done
16065
16066
16067 for ac_func in vsnprintf
16068 do
16069 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16070 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16071 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16072 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16073   echo $ECHO_N "(cached) $ECHO_C" >&6
16074 else
16075   cat >conftest.$ac_ext <<_ACEOF
16076 /* confdefs.h.  */
16077 _ACEOF
16078 cat confdefs.h >>conftest.$ac_ext
16079 cat >>conftest.$ac_ext <<_ACEOF
16080 /* end confdefs.h.  */
16081 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16082    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16083 #define $ac_func innocuous_$ac_func
16084
16085 /* System header to define __stub macros and hopefully few prototypes,
16086     which can conflict with char $ac_func (); below.
16087     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16088     <limits.h> exists even on freestanding compilers.  */
16089
16090 #ifdef __STDC__
16091 # include <limits.h>
16092 #else
16093 # include <assert.h>
16094 #endif
16095
16096 #undef $ac_func
16097
16098 /* Override any GCC internal prototype to avoid an error.
16099    Use char because int might match the return type of a GCC
16100    builtin and then its argument prototype would still apply.  */
16101 #ifdef __cplusplus
16102 extern "C"
16103 #endif
16104 char $ac_func ();
16105 /* The GNU C library defines this for functions which it implements
16106     to always fail with ENOSYS.  Some functions are actually named
16107     something starting with __ and the normal name is an alias.  */
16108 #if defined __stub_$ac_func || defined __stub___$ac_func
16109 choke me
16110 #endif
16111
16112 int
16113 main ()
16114 {
16115 return $ac_func ();
16116   ;
16117   return 0;
16118 }
16119 _ACEOF
16120 rm -f conftest.$ac_objext conftest$ac_exeext
16121 if { (ac_try="$ac_link"
16122 case "(($ac_try" in
16123   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16124   *) ac_try_echo=$ac_try;;
16125 esac
16126 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16127   (eval "$ac_link") 2>conftest.er1
16128   ac_status=$?
16129   grep -v '^ *+' conftest.er1 >conftest.err
16130   rm -f conftest.er1
16131   cat conftest.err >&5
16132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16133   (exit $ac_status); } && {
16134          test -z "$ac_c_werror_flag" ||
16135          test ! -s conftest.err
16136        } && test -s conftest$ac_exeext &&
16137        $as_test_x conftest$ac_exeext; then
16138   eval "$as_ac_var=yes"
16139 else
16140   echo "$as_me: failed program was:" >&5
16141 sed 's/^/| /' conftest.$ac_ext >&5
16142
16143         eval "$as_ac_var=no"
16144 fi
16145
16146 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16147       conftest$ac_exeext conftest.$ac_ext
16148 fi
16149 ac_res=`eval echo '${'$as_ac_var'}'`
16150                { echo "$as_me:$LINENO: result: $ac_res" >&5
16151 echo "${ECHO_T}$ac_res" >&6; }
16152 if test `eval echo '${'$as_ac_var'}'` = yes; then
16153   cat >>confdefs.h <<_ACEOF
16154 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16155 _ACEOF
16156
16157 else
16158   pgac_need_repl_snprintf=yes
16159 fi
16160 done
16161
16162 fi
16163
16164
16165 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
16166 # include/c.h will provide declarations.  Note this is a separate test
16167 # from whether the functions exist in the C library --- there are
16168 # systems that have the functions but don't bother to declare them :-(
16169
16170 { echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
16171 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6; }
16172 if test "${ac_cv_have_decl_snprintf+set}" = set; then
16173   echo $ECHO_N "(cached) $ECHO_C" >&6
16174 else
16175   cat >conftest.$ac_ext <<_ACEOF
16176 /* confdefs.h.  */
16177 _ACEOF
16178 cat confdefs.h >>conftest.$ac_ext
16179 cat >>conftest.$ac_ext <<_ACEOF
16180 /* end confdefs.h.  */
16181 $ac_includes_default
16182 int
16183 main ()
16184 {
16185 #ifndef snprintf
16186   (void) snprintf;
16187 #endif
16188
16189   ;
16190   return 0;
16191 }
16192 _ACEOF
16193 rm -f conftest.$ac_objext
16194 if { (ac_try="$ac_compile"
16195 case "(($ac_try" in
16196   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16197   *) ac_try_echo=$ac_try;;
16198 esac
16199 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16200   (eval "$ac_compile") 2>conftest.er1
16201   ac_status=$?
16202   grep -v '^ *+' conftest.er1 >conftest.err
16203   rm -f conftest.er1
16204   cat conftest.err >&5
16205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16206   (exit $ac_status); } && {
16207          test -z "$ac_c_werror_flag" ||
16208          test ! -s conftest.err
16209        } && test -s conftest.$ac_objext; then
16210   ac_cv_have_decl_snprintf=yes
16211 else
16212   echo "$as_me: failed program was:" >&5
16213 sed 's/^/| /' conftest.$ac_ext >&5
16214
16215         ac_cv_have_decl_snprintf=no
16216 fi
16217
16218 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16219 fi
16220 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
16221 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6; }
16222 if test $ac_cv_have_decl_snprintf = yes; then
16223
16224 cat >>confdefs.h <<_ACEOF
16225 #define HAVE_DECL_SNPRINTF 1
16226 _ACEOF
16227
16228
16229 else
16230   cat >>confdefs.h <<_ACEOF
16231 #define HAVE_DECL_SNPRINTF 0
16232 _ACEOF
16233
16234
16235 fi
16236 { echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
16237 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6; }
16238 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
16239   echo $ECHO_N "(cached) $ECHO_C" >&6
16240 else
16241   cat >conftest.$ac_ext <<_ACEOF
16242 /* confdefs.h.  */
16243 _ACEOF
16244 cat confdefs.h >>conftest.$ac_ext
16245 cat >>conftest.$ac_ext <<_ACEOF
16246 /* end confdefs.h.  */
16247 $ac_includes_default
16248 int
16249 main ()
16250 {
16251 #ifndef vsnprintf
16252   (void) vsnprintf;
16253 #endif
16254
16255   ;
16256   return 0;
16257 }
16258 _ACEOF
16259 rm -f conftest.$ac_objext
16260 if { (ac_try="$ac_compile"
16261 case "(($ac_try" in
16262   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16263   *) ac_try_echo=$ac_try;;
16264 esac
16265 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16266   (eval "$ac_compile") 2>conftest.er1
16267   ac_status=$?
16268   grep -v '^ *+' conftest.er1 >conftest.err
16269   rm -f conftest.er1
16270   cat conftest.err >&5
16271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16272   (exit $ac_status); } && {
16273          test -z "$ac_c_werror_flag" ||
16274          test ! -s conftest.err
16275        } && test -s conftest.$ac_objext; then
16276   ac_cv_have_decl_vsnprintf=yes
16277 else
16278   echo "$as_me: failed program was:" >&5
16279 sed 's/^/| /' conftest.$ac_ext >&5
16280
16281         ac_cv_have_decl_vsnprintf=no
16282 fi
16283
16284 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16285 fi
16286 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
16287 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6; }
16288 if test $ac_cv_have_decl_vsnprintf = yes; then
16289
16290 cat >>confdefs.h <<_ACEOF
16291 #define HAVE_DECL_VSNPRINTF 1
16292 _ACEOF
16293
16294
16295 else
16296   cat >>confdefs.h <<_ACEOF
16297 #define HAVE_DECL_VSNPRINTF 0
16298 _ACEOF
16299
16300
16301 fi
16302
16303
16304
16305
16306 { echo "$as_me:$LINENO: checking for isinf" >&5
16307 echo $ECHO_N "checking for isinf... $ECHO_C" >&6; }
16308 if test "${ac_cv_func_isinf+set}" = set; then
16309   echo $ECHO_N "(cached) $ECHO_C" >&6
16310 else
16311   cat >conftest.$ac_ext <<_ACEOF
16312 /* confdefs.h.  */
16313 _ACEOF
16314 cat confdefs.h >>conftest.$ac_ext
16315 cat >>conftest.$ac_ext <<_ACEOF
16316 /* end confdefs.h.  */
16317
16318 #include <math.h>
16319 double glob_double;
16320
16321 int
16322 main ()
16323 {
16324 return isinf(glob_double) ? 0 : 1;
16325   ;
16326   return 0;
16327 }
16328 _ACEOF
16329 rm -f conftest.$ac_objext conftest$ac_exeext
16330 if { (ac_try="$ac_link"
16331 case "(($ac_try" in
16332   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16333   *) ac_try_echo=$ac_try;;
16334 esac
16335 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16336   (eval "$ac_link") 2>conftest.er1
16337   ac_status=$?
16338   grep -v '^ *+' conftest.er1 >conftest.err
16339   rm -f conftest.er1
16340   cat conftest.err >&5
16341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16342   (exit $ac_status); } && {
16343          test -z "$ac_c_werror_flag" ||
16344          test ! -s conftest.err
16345        } && test -s conftest$ac_exeext &&
16346        $as_test_x conftest$ac_exeext; then
16347   ac_cv_func_isinf=yes
16348 else
16349   echo "$as_me: failed program was:" >&5
16350 sed 's/^/| /' conftest.$ac_ext >&5
16351
16352         ac_cv_func_isinf=no
16353 fi
16354
16355 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16356       conftest$ac_exeext conftest.$ac_ext
16357 fi
16358 { echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
16359 echo "${ECHO_T}$ac_cv_func_isinf" >&6; }
16360
16361 if test $ac_cv_func_isinf = yes ; then
16362
16363 cat >>confdefs.h <<\_ACEOF
16364 #define HAVE_ISINF 1
16365 _ACEOF
16366
16367 else
16368   case " $LIBOBJS " in
16369   *" isinf.$ac_objext "* ) ;;
16370   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
16371  ;;
16372 esac
16373
16374   # Look for a way to implement a substitute for isinf()
16375
16376
16377
16378
16379 for ac_func in fpclass fp_class fp_class_d class
16380 do
16381 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16382 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16383 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16384 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16385   echo $ECHO_N "(cached) $ECHO_C" >&6
16386 else
16387   cat >conftest.$ac_ext <<_ACEOF
16388 /* confdefs.h.  */
16389 _ACEOF
16390 cat confdefs.h >>conftest.$ac_ext
16391 cat >>conftest.$ac_ext <<_ACEOF
16392 /* end confdefs.h.  */
16393 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16394    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16395 #define $ac_func innocuous_$ac_func
16396
16397 /* System header to define __stub macros and hopefully few prototypes,
16398     which can conflict with char $ac_func (); below.
16399     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16400     <limits.h> exists even on freestanding compilers.  */
16401
16402 #ifdef __STDC__
16403 # include <limits.h>
16404 #else
16405 # include <assert.h>
16406 #endif
16407
16408 #undef $ac_func
16409
16410 /* Override any GCC internal prototype to avoid an error.
16411    Use char because int might match the return type of a GCC
16412    builtin and then its argument prototype would still apply.  */
16413 #ifdef __cplusplus
16414 extern "C"
16415 #endif
16416 char $ac_func ();
16417 /* The GNU C library defines this for functions which it implements
16418     to always fail with ENOSYS.  Some functions are actually named
16419     something starting with __ and the normal name is an alias.  */
16420 #if defined __stub_$ac_func || defined __stub___$ac_func
16421 choke me
16422 #endif
16423
16424 int
16425 main ()
16426 {
16427 return $ac_func ();
16428   ;
16429   return 0;
16430 }
16431 _ACEOF
16432 rm -f conftest.$ac_objext conftest$ac_exeext
16433 if { (ac_try="$ac_link"
16434 case "(($ac_try" in
16435   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16436   *) ac_try_echo=$ac_try;;
16437 esac
16438 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16439   (eval "$ac_link") 2>conftest.er1
16440   ac_status=$?
16441   grep -v '^ *+' conftest.er1 >conftest.err
16442   rm -f conftest.er1
16443   cat conftest.err >&5
16444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16445   (exit $ac_status); } && {
16446          test -z "$ac_c_werror_flag" ||
16447          test ! -s conftest.err
16448        } && test -s conftest$ac_exeext &&
16449        $as_test_x conftest$ac_exeext; then
16450   eval "$as_ac_var=yes"
16451 else
16452   echo "$as_me: failed program was:" >&5
16453 sed 's/^/| /' conftest.$ac_ext >&5
16454
16455         eval "$as_ac_var=no"
16456 fi
16457
16458 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16459       conftest$ac_exeext conftest.$ac_ext
16460 fi
16461 ac_res=`eval echo '${'$as_ac_var'}'`
16462                { echo "$as_me:$LINENO: result: $ac_res" >&5
16463 echo "${ECHO_T}$ac_res" >&6; }
16464 if test `eval echo '${'$as_ac_var'}'` = yes; then
16465   cat >>confdefs.h <<_ACEOF
16466 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16467 _ACEOF
16468  break
16469 fi
16470 done
16471
16472 fi
16473
16474 # Some versions of libedit contain strlcpy(); so disregard that library while
16475 # checking for these standard libc functions.
16476 pgac_save_LIBS="$LIBS"
16477 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
16478
16479
16480
16481
16482
16483
16484
16485
16486
16487
16488
16489
16490
16491
16492
16493 for ac_func in crypt getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul unsetenv
16494 do
16495 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16496 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16497 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16498 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16499   echo $ECHO_N "(cached) $ECHO_C" >&6
16500 else
16501   cat >conftest.$ac_ext <<_ACEOF
16502 /* confdefs.h.  */
16503 _ACEOF
16504 cat confdefs.h >>conftest.$ac_ext
16505 cat >>conftest.$ac_ext <<_ACEOF
16506 /* end confdefs.h.  */
16507 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16508    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16509 #define $ac_func innocuous_$ac_func
16510
16511 /* System header to define __stub macros and hopefully few prototypes,
16512     which can conflict with char $ac_func (); below.
16513     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16514     <limits.h> exists even on freestanding compilers.  */
16515
16516 #ifdef __STDC__
16517 # include <limits.h>
16518 #else
16519 # include <assert.h>
16520 #endif
16521
16522 #undef $ac_func
16523
16524 /* Override any GCC internal prototype to avoid an error.
16525    Use char because int might match the return type of a GCC
16526    builtin and then its argument prototype would still apply.  */
16527 #ifdef __cplusplus
16528 extern "C"
16529 #endif
16530 char $ac_func ();
16531 /* The GNU C library defines this for functions which it implements
16532     to always fail with ENOSYS.  Some functions are actually named
16533     something starting with __ and the normal name is an alias.  */
16534 #if defined __stub_$ac_func || defined __stub___$ac_func
16535 choke me
16536 #endif
16537
16538 int
16539 main ()
16540 {
16541 return $ac_func ();
16542   ;
16543   return 0;
16544 }
16545 _ACEOF
16546 rm -f conftest.$ac_objext conftest$ac_exeext
16547 if { (ac_try="$ac_link"
16548 case "(($ac_try" in
16549   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16550   *) ac_try_echo=$ac_try;;
16551 esac
16552 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16553   (eval "$ac_link") 2>conftest.er1
16554   ac_status=$?
16555   grep -v '^ *+' conftest.er1 >conftest.err
16556   rm -f conftest.er1
16557   cat conftest.err >&5
16558   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16559   (exit $ac_status); } && {
16560          test -z "$ac_c_werror_flag" ||
16561          test ! -s conftest.err
16562        } && test -s conftest$ac_exeext &&
16563        $as_test_x conftest$ac_exeext; then
16564   eval "$as_ac_var=yes"
16565 else
16566   echo "$as_me: failed program was:" >&5
16567 sed 's/^/| /' conftest.$ac_ext >&5
16568
16569         eval "$as_ac_var=no"
16570 fi
16571
16572 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16573       conftest$ac_exeext conftest.$ac_ext
16574 fi
16575 ac_res=`eval echo '${'$as_ac_var'}'`
16576                { echo "$as_me:$LINENO: result: $ac_res" >&5
16577 echo "${ECHO_T}$ac_res" >&6; }
16578 if test `eval echo '${'$as_ac_var'}'` = yes; then
16579   cat >>confdefs.h <<_ACEOF
16580 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16581 _ACEOF
16582
16583 else
16584   case " $LIBOBJS " in
16585   *" $ac_func.$ac_objext "* ) ;;
16586   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
16587  ;;
16588 esac
16589
16590 fi
16591 done
16592
16593
16594
16595 LIBS="$pgac_save_LIBS"
16596
16597 # System's version of getaddrinfo(), if any, may be used only if we found
16598 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
16599 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
16600 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
16601 # because we want to use our own getaddrinfo.c on Windows anyway.)
16602 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
16603
16604 for ac_func in getaddrinfo
16605 do
16606 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16607 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16608 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16609 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16610   echo $ECHO_N "(cached) $ECHO_C" >&6
16611 else
16612   cat >conftest.$ac_ext <<_ACEOF
16613 /* confdefs.h.  */
16614 _ACEOF
16615 cat confdefs.h >>conftest.$ac_ext
16616 cat >>conftest.$ac_ext <<_ACEOF
16617 /* end confdefs.h.  */
16618 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16619    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16620 #define $ac_func innocuous_$ac_func
16621
16622 /* System header to define __stub macros and hopefully few prototypes,
16623     which can conflict with char $ac_func (); below.
16624     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16625     <limits.h> exists even on freestanding compilers.  */
16626
16627 #ifdef __STDC__
16628 # include <limits.h>
16629 #else
16630 # include <assert.h>
16631 #endif
16632
16633 #undef $ac_func
16634
16635 /* Override any GCC internal prototype to avoid an error.
16636    Use char because int might match the return type of a GCC
16637    builtin and then its argument prototype would still apply.  */
16638 #ifdef __cplusplus
16639 extern "C"
16640 #endif
16641 char $ac_func ();
16642 /* The GNU C library defines this for functions which it implements
16643     to always fail with ENOSYS.  Some functions are actually named
16644     something starting with __ and the normal name is an alias.  */
16645 #if defined __stub_$ac_func || defined __stub___$ac_func
16646 choke me
16647 #endif
16648
16649 int
16650 main ()
16651 {
16652 return $ac_func ();
16653   ;
16654   return 0;
16655 }
16656 _ACEOF
16657 rm -f conftest.$ac_objext conftest$ac_exeext
16658 if { (ac_try="$ac_link"
16659 case "(($ac_try" in
16660   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16661   *) ac_try_echo=$ac_try;;
16662 esac
16663 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16664   (eval "$ac_link") 2>conftest.er1
16665   ac_status=$?
16666   grep -v '^ *+' conftest.er1 >conftest.err
16667   rm -f conftest.er1
16668   cat conftest.err >&5
16669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16670   (exit $ac_status); } && {
16671          test -z "$ac_c_werror_flag" ||
16672          test ! -s conftest.err
16673        } && test -s conftest$ac_exeext &&
16674        $as_test_x conftest$ac_exeext; then
16675   eval "$as_ac_var=yes"
16676 else
16677   echo "$as_me: failed program was:" >&5
16678 sed 's/^/| /' conftest.$ac_ext >&5
16679
16680         eval "$as_ac_var=no"
16681 fi
16682
16683 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16684       conftest$ac_exeext conftest.$ac_ext
16685 fi
16686 ac_res=`eval echo '${'$as_ac_var'}'`
16687                { echo "$as_me:$LINENO: result: $ac_res" >&5
16688 echo "${ECHO_T}$ac_res" >&6; }
16689 if test `eval echo '${'$as_ac_var'}'` = yes; then
16690   cat >>confdefs.h <<_ACEOF
16691 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16692 _ACEOF
16693
16694 else
16695   case " $LIBOBJS " in
16696   *" $ac_func.$ac_objext "* ) ;;
16697   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
16698  ;;
16699 esac
16700
16701 fi
16702 done
16703
16704
16705 else
16706   case " $LIBOBJS " in
16707   *" getaddrinfo.$ac_objext "* ) ;;
16708   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
16709  ;;
16710 esac
16711
16712 fi
16713
16714 # Similarly, use system's getopt_long() only if system provides struct option.
16715 # Solaris' getopt() doesn't do what we want for long options, so always use
16716 # our versions on that platform.
16717 if test "$PORTNAME" = "solaris"; then
16718   case " $LIBOBJS " in
16719   *" getopt.$ac_objext "* ) ;;
16720   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
16721  ;;
16722 esac
16723
16724   case " $LIBOBJS " in
16725   *" getopt_long.$ac_objext "* ) ;;
16726   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
16727  ;;
16728 esac
16729
16730 elif test x"$ac_cv_type_struct_option" = xyes ; then
16731
16732 for ac_func in getopt_long
16733 do
16734 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16735 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16736 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16737 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16738   echo $ECHO_N "(cached) $ECHO_C" >&6
16739 else
16740   cat >conftest.$ac_ext <<_ACEOF
16741 /* confdefs.h.  */
16742 _ACEOF
16743 cat confdefs.h >>conftest.$ac_ext
16744 cat >>conftest.$ac_ext <<_ACEOF
16745 /* end confdefs.h.  */
16746 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16747    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16748 #define $ac_func innocuous_$ac_func
16749
16750 /* System header to define __stub macros and hopefully few prototypes,
16751     which can conflict with char $ac_func (); below.
16752     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16753     <limits.h> exists even on freestanding compilers.  */
16754
16755 #ifdef __STDC__
16756 # include <limits.h>
16757 #else
16758 # include <assert.h>
16759 #endif
16760
16761 #undef $ac_func
16762
16763 /* Override any GCC internal prototype to avoid an error.
16764    Use char because int might match the return type of a GCC
16765    builtin and then its argument prototype would still apply.  */
16766 #ifdef __cplusplus
16767 extern "C"
16768 #endif
16769 char $ac_func ();
16770 /* The GNU C library defines this for functions which it implements
16771     to always fail with ENOSYS.  Some functions are actually named
16772     something starting with __ and the normal name is an alias.  */
16773 #if defined __stub_$ac_func || defined __stub___$ac_func
16774 choke me
16775 #endif
16776
16777 int
16778 main ()
16779 {
16780 return $ac_func ();
16781   ;
16782   return 0;
16783 }
16784 _ACEOF
16785 rm -f conftest.$ac_objext conftest$ac_exeext
16786 if { (ac_try="$ac_link"
16787 case "(($ac_try" in
16788   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16789   *) ac_try_echo=$ac_try;;
16790 esac
16791 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16792   (eval "$ac_link") 2>conftest.er1
16793   ac_status=$?
16794   grep -v '^ *+' conftest.er1 >conftest.err
16795   rm -f conftest.er1
16796   cat conftest.err >&5
16797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16798   (exit $ac_status); } && {
16799          test -z "$ac_c_werror_flag" ||
16800          test ! -s conftest.err
16801        } && test -s conftest$ac_exeext &&
16802        $as_test_x conftest$ac_exeext; then
16803   eval "$as_ac_var=yes"
16804 else
16805   echo "$as_me: failed program was:" >&5
16806 sed 's/^/| /' conftest.$ac_ext >&5
16807
16808         eval "$as_ac_var=no"
16809 fi
16810
16811 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16812       conftest$ac_exeext conftest.$ac_ext
16813 fi
16814 ac_res=`eval echo '${'$as_ac_var'}'`
16815                { echo "$as_me:$LINENO: result: $ac_res" >&5
16816 echo "${ECHO_T}$ac_res" >&6; }
16817 if test `eval echo '${'$as_ac_var'}'` = yes; then
16818   cat >>confdefs.h <<_ACEOF
16819 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16820 _ACEOF
16821
16822 else
16823   case " $LIBOBJS " in
16824   *" $ac_func.$ac_objext "* ) ;;
16825   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
16826  ;;
16827 esac
16828
16829 fi
16830 done
16831
16832
16833 else
16834   case " $LIBOBJS " in
16835   *" getopt_long.$ac_objext "* ) ;;
16836   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
16837  ;;
16838 esac
16839
16840 fi
16841
16842 # Win32 support
16843 if test "$PORTNAME" = "win32"; then
16844
16845 for ac_func in gettimeofday
16846 do
16847 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16848 { echo "$as_me:$LINENO: checking for $ac_func" >&5
16849 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16850 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16851   echo $ECHO_N "(cached) $ECHO_C" >&6
16852 else
16853   cat >conftest.$ac_ext <<_ACEOF
16854 /* confdefs.h.  */
16855 _ACEOF
16856 cat confdefs.h >>conftest.$ac_ext
16857 cat >>conftest.$ac_ext <<_ACEOF
16858 /* end confdefs.h.  */
16859 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16860    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16861 #define $ac_func innocuous_$ac_func
16862
16863 /* System header to define __stub macros and hopefully few prototypes,
16864     which can conflict with char $ac_func (); below.
16865     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16866     <limits.h> exists even on freestanding compilers.  */
16867
16868 #ifdef __STDC__
16869 # include <limits.h>
16870 #else
16871 # include <assert.h>
16872 #endif
16873
16874 #undef $ac_func
16875
16876 /* Override any GCC internal prototype to avoid an error.
16877    Use char because int might match the return type of a GCC
16878    builtin and then its argument prototype would still apply.  */
16879 #ifdef __cplusplus
16880 extern "C"
16881 #endif
16882 char $ac_func ();
16883 /* The GNU C library defines this for functions which it implements
16884     to always fail with ENOSYS.  Some functions are actually named
16885     something starting with __ and the normal name is an alias.  */
16886 #if defined __stub_$ac_func || defined __stub___$ac_func
16887 choke me
16888 #endif
16889
16890 int
16891 main ()
16892 {
16893 return $ac_func ();
16894   ;
16895   return 0;
16896 }
16897 _ACEOF
16898 rm -f conftest.$ac_objext conftest$ac_exeext
16899 if { (ac_try="$ac_link"
16900 case "(($ac_try" in
16901   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16902   *) ac_try_echo=$ac_try;;
16903 esac
16904 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16905   (eval "$ac_link") 2>conftest.er1
16906   ac_status=$?
16907   grep -v '^ *+' conftest.er1 >conftest.err
16908   rm -f conftest.er1
16909   cat conftest.err >&5
16910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16911   (exit $ac_status); } && {
16912          test -z "$ac_c_werror_flag" ||
16913          test ! -s conftest.err
16914        } && test -s conftest$ac_exeext &&
16915        $as_test_x conftest$ac_exeext; then
16916   eval "$as_ac_var=yes"
16917 else
16918   echo "$as_me: failed program was:" >&5
16919 sed 's/^/| /' conftest.$ac_ext >&5
16920
16921         eval "$as_ac_var=no"
16922 fi
16923
16924 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16925       conftest$ac_exeext conftest.$ac_ext
16926 fi
16927 ac_res=`eval echo '${'$as_ac_var'}'`
16928                { echo "$as_me:$LINENO: result: $ac_res" >&5
16929 echo "${ECHO_T}$ac_res" >&6; }
16930 if test `eval echo '${'$as_ac_var'}'` = yes; then
16931   cat >>confdefs.h <<_ACEOF
16932 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16933 _ACEOF
16934
16935 else
16936   case " $LIBOBJS " in
16937   *" $ac_func.$ac_objext "* ) ;;
16938   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
16939  ;;
16940 esac
16941
16942 fi
16943 done
16944
16945
16946 case " $LIBOBJS " in
16947   *" kill.$ac_objext "* ) ;;
16948   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
16949  ;;
16950 esac
16951
16952 case " $LIBOBJS " in
16953   *" open.$ac_objext "* ) ;;
16954   *) LIBOBJS="$LIBOBJS open.$ac_objext"
16955  ;;
16956 esac
16957
16958 case " $LIBOBJS " in
16959   *" rand.$ac_objext "* ) ;;
16960   *) LIBOBJS="$LIBOBJS rand.$ac_objext"
16961  ;;
16962 esac
16963
16964 case " $LIBOBJS " in
16965   *" win32error.$ac_objext "* ) ;;
16966   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
16967  ;;
16968 esac
16969
16970
16971 cat >>confdefs.h <<\_ACEOF
16972 #define HAVE_SYMLINK 1
16973 _ACEOF
16974
16975 fi
16976
16977 if test "$with_readline" = yes; then
16978   { echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
16979 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6; }
16980 cat >conftest.$ac_ext <<_ACEOF
16981 /* confdefs.h.  */
16982 _ACEOF
16983 cat confdefs.h >>conftest.$ac_ext
16984 cat >>conftest.$ac_ext <<_ACEOF
16985 /* end confdefs.h.  */
16986 #include <stdio.h>
16987 #ifdef HAVE_READLINE_READLINE_H
16988 # include <readline/readline.h>
16989 #elif defined(HAVE_READLINE_H)
16990 # include <readline.h>
16991 #endif
16992
16993 int
16994 main ()
16995 {
16996 rl_completion_append_character = 'x';
16997   ;
16998   return 0;
16999 }
17000 _ACEOF
17001 rm -f conftest.$ac_objext conftest$ac_exeext
17002 if { (ac_try="$ac_link"
17003 case "(($ac_try" in
17004   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17005   *) ac_try_echo=$ac_try;;
17006 esac
17007 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17008   (eval "$ac_link") 2>conftest.er1
17009   ac_status=$?
17010   grep -v '^ *+' conftest.er1 >conftest.err
17011   rm -f conftest.er1
17012   cat conftest.err >&5
17013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17014   (exit $ac_status); } && {
17015          test -z "$ac_c_werror_flag" ||
17016          test ! -s conftest.err
17017        } && test -s conftest$ac_exeext &&
17018        $as_test_x conftest$ac_exeext; then
17019   { echo "$as_me:$LINENO: result: yes" >&5
17020 echo "${ECHO_T}yes" >&6; }
17021
17022 cat >>confdefs.h <<\_ACEOF
17023 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
17024 _ACEOF
17025
17026 else
17027   echo "$as_me: failed program was:" >&5
17028 sed 's/^/| /' conftest.$ac_ext >&5
17029
17030         { echo "$as_me:$LINENO: result: no" >&5
17031 echo "${ECHO_T}no" >&6; }
17032 fi
17033
17034 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17035       conftest$ac_exeext conftest.$ac_ext
17036
17037
17038 for ac_func in rl_completion_matches rl_filename_completion_function
17039 do
17040 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17041 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17042 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17043 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17044   echo $ECHO_N "(cached) $ECHO_C" >&6
17045 else
17046   cat >conftest.$ac_ext <<_ACEOF
17047 /* confdefs.h.  */
17048 _ACEOF
17049 cat confdefs.h >>conftest.$ac_ext
17050 cat >>conftest.$ac_ext <<_ACEOF
17051 /* end confdefs.h.  */
17052 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17053    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17054 #define $ac_func innocuous_$ac_func
17055
17056 /* System header to define __stub macros and hopefully few prototypes,
17057     which can conflict with char $ac_func (); below.
17058     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17059     <limits.h> exists even on freestanding compilers.  */
17060
17061 #ifdef __STDC__
17062 # include <limits.h>
17063 #else
17064 # include <assert.h>
17065 #endif
17066
17067 #undef $ac_func
17068
17069 /* Override any GCC internal prototype to avoid an error.
17070    Use char because int might match the return type of a GCC
17071    builtin and then its argument prototype would still apply.  */
17072 #ifdef __cplusplus
17073 extern "C"
17074 #endif
17075 char $ac_func ();
17076 /* The GNU C library defines this for functions which it implements
17077     to always fail with ENOSYS.  Some functions are actually named
17078     something starting with __ and the normal name is an alias.  */
17079 #if defined __stub_$ac_func || defined __stub___$ac_func
17080 choke me
17081 #endif
17082
17083 int
17084 main ()
17085 {
17086 return $ac_func ();
17087   ;
17088   return 0;
17089 }
17090 _ACEOF
17091 rm -f conftest.$ac_objext conftest$ac_exeext
17092 if { (ac_try="$ac_link"
17093 case "(($ac_try" in
17094   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17095   *) ac_try_echo=$ac_try;;
17096 esac
17097 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17098   (eval "$ac_link") 2>conftest.er1
17099   ac_status=$?
17100   grep -v '^ *+' conftest.er1 >conftest.err
17101   rm -f conftest.er1
17102   cat conftest.err >&5
17103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17104   (exit $ac_status); } && {
17105          test -z "$ac_c_werror_flag" ||
17106          test ! -s conftest.err
17107        } && test -s conftest$ac_exeext &&
17108        $as_test_x conftest$ac_exeext; then
17109   eval "$as_ac_var=yes"
17110 else
17111   echo "$as_me: failed program was:" >&5
17112 sed 's/^/| /' conftest.$ac_ext >&5
17113
17114         eval "$as_ac_var=no"
17115 fi
17116
17117 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17118       conftest$ac_exeext conftest.$ac_ext
17119 fi
17120 ac_res=`eval echo '${'$as_ac_var'}'`
17121                { echo "$as_me:$LINENO: result: $ac_res" >&5
17122 echo "${ECHO_T}$ac_res" >&6; }
17123 if test `eval echo '${'$as_ac_var'}'` = yes; then
17124   cat >>confdefs.h <<_ACEOF
17125 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17126 _ACEOF
17127
17128 fi
17129 done
17130
17131
17132 for ac_func in replace_history_entry
17133 do
17134 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17135 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17136 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17137 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17138   echo $ECHO_N "(cached) $ECHO_C" >&6
17139 else
17140   cat >conftest.$ac_ext <<_ACEOF
17141 /* confdefs.h.  */
17142 _ACEOF
17143 cat confdefs.h >>conftest.$ac_ext
17144 cat >>conftest.$ac_ext <<_ACEOF
17145 /* end confdefs.h.  */
17146 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17147    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17148 #define $ac_func innocuous_$ac_func
17149
17150 /* System header to define __stub macros and hopefully few prototypes,
17151     which can conflict with char $ac_func (); below.
17152     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17153     <limits.h> exists even on freestanding compilers.  */
17154
17155 #ifdef __STDC__
17156 # include <limits.h>
17157 #else
17158 # include <assert.h>
17159 #endif
17160
17161 #undef $ac_func
17162
17163 /* Override any GCC internal prototype to avoid an error.
17164    Use char because int might match the return type of a GCC
17165    builtin and then its argument prototype would still apply.  */
17166 #ifdef __cplusplus
17167 extern "C"
17168 #endif
17169 char $ac_func ();
17170 /* The GNU C library defines this for functions which it implements
17171     to always fail with ENOSYS.  Some functions are actually named
17172     something starting with __ and the normal name is an alias.  */
17173 #if defined __stub_$ac_func || defined __stub___$ac_func
17174 choke me
17175 #endif
17176
17177 int
17178 main ()
17179 {
17180 return $ac_func ();
17181   ;
17182   return 0;
17183 }
17184 _ACEOF
17185 rm -f conftest.$ac_objext conftest$ac_exeext
17186 if { (ac_try="$ac_link"
17187 case "(($ac_try" in
17188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17189   *) ac_try_echo=$ac_try;;
17190 esac
17191 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17192   (eval "$ac_link") 2>conftest.er1
17193   ac_status=$?
17194   grep -v '^ *+' conftest.er1 >conftest.err
17195   rm -f conftest.er1
17196   cat conftest.err >&5
17197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17198   (exit $ac_status); } && {
17199          test -z "$ac_c_werror_flag" ||
17200          test ! -s conftest.err
17201        } && test -s conftest$ac_exeext &&
17202        $as_test_x conftest$ac_exeext; then
17203   eval "$as_ac_var=yes"
17204 else
17205   echo "$as_me: failed program was:" >&5
17206 sed 's/^/| /' conftest.$ac_ext >&5
17207
17208         eval "$as_ac_var=no"
17209 fi
17210
17211 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17212       conftest$ac_exeext conftest.$ac_ext
17213 fi
17214 ac_res=`eval echo '${'$as_ac_var'}'`
17215                { echo "$as_me:$LINENO: result: $ac_res" >&5
17216 echo "${ECHO_T}$ac_res" >&6; }
17217 if test `eval echo '${'$as_ac_var'}'` = yes; then
17218   cat >>confdefs.h <<_ACEOF
17219 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17220 _ACEOF
17221
17222 fi
17223 done
17224
17225 fi
17226
17227
17228 { echo "$as_me:$LINENO: checking for sigsetjmp" >&5
17229 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6; }
17230 cat >conftest.$ac_ext <<_ACEOF
17231 /* confdefs.h.  */
17232 _ACEOF
17233 cat confdefs.h >>conftest.$ac_ext
17234 cat >>conftest.$ac_ext <<_ACEOF
17235 /* end confdefs.h.  */
17236 #include <setjmp.h>
17237 int
17238 main ()
17239 {
17240 sigjmp_buf x; sigsetjmp(x, 1);
17241   ;
17242   return 0;
17243 }
17244 _ACEOF
17245 rm -f conftest.$ac_objext conftest$ac_exeext
17246 if { (ac_try="$ac_link"
17247 case "(($ac_try" in
17248   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17249   *) ac_try_echo=$ac_try;;
17250 esac
17251 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17252   (eval "$ac_link") 2>conftest.er1
17253   ac_status=$?
17254   grep -v '^ *+' conftest.er1 >conftest.err
17255   rm -f conftest.er1
17256   cat conftest.err >&5
17257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17258   (exit $ac_status); } && {
17259          test -z "$ac_c_werror_flag" ||
17260          test ! -s conftest.err
17261        } && test -s conftest$ac_exeext &&
17262        $as_test_x conftest$ac_exeext; then
17263
17264 cat >>confdefs.h <<\_ACEOF
17265 #define HAVE_SIGSETJMP 1
17266 _ACEOF
17267
17268 { echo "$as_me:$LINENO: result: yes" >&5
17269 echo "${ECHO_T}yes" >&6; }
17270 else
17271   echo "$as_me: failed program was:" >&5
17272 sed 's/^/| /' conftest.$ac_ext >&5
17273
17274         { echo "$as_me:$LINENO: result: no" >&5
17275 echo "${ECHO_T}no" >&6; }
17276 fi
17277
17278 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17279       conftest$ac_exeext conftest.$ac_ext
17280
17281 { echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
17282 echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6; }
17283 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
17284   echo $ECHO_N "(cached) $ECHO_C" >&6
17285 else
17286   cat >conftest.$ac_ext <<_ACEOF
17287 /* confdefs.h.  */
17288 _ACEOF
17289 cat confdefs.h >>conftest.$ac_ext
17290 cat >>conftest.$ac_ext <<_ACEOF
17291 /* end confdefs.h.  */
17292 #include <signal.h>
17293 /* NetBSD declares sys_siglist in unistd.h.  */
17294 #ifdef HAVE_UNISTD_H
17295 # include <unistd.h>
17296 #endif
17297
17298
17299 int
17300 main ()
17301 {
17302 #ifndef sys_siglist
17303   (void) sys_siglist;
17304 #endif
17305
17306   ;
17307   return 0;
17308 }
17309 _ACEOF
17310 rm -f conftest.$ac_objext
17311 if { (ac_try="$ac_compile"
17312 case "(($ac_try" in
17313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17314   *) ac_try_echo=$ac_try;;
17315 esac
17316 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17317   (eval "$ac_compile") 2>conftest.er1
17318   ac_status=$?
17319   grep -v '^ *+' conftest.er1 >conftest.err
17320   rm -f conftest.er1
17321   cat conftest.err >&5
17322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17323   (exit $ac_status); } && {
17324          test -z "$ac_c_werror_flag" ||
17325          test ! -s conftest.err
17326        } && test -s conftest.$ac_objext; then
17327   ac_cv_have_decl_sys_siglist=yes
17328 else
17329   echo "$as_me: failed program was:" >&5
17330 sed 's/^/| /' conftest.$ac_ext >&5
17331
17332         ac_cv_have_decl_sys_siglist=no
17333 fi
17334
17335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17336 fi
17337 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
17338 echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6; }
17339 if test $ac_cv_have_decl_sys_siglist = yes; then
17340
17341 cat >>confdefs.h <<_ACEOF
17342 #define HAVE_DECL_SYS_SIGLIST 1
17343 _ACEOF
17344
17345
17346 else
17347   cat >>confdefs.h <<_ACEOF
17348 #define HAVE_DECL_SYS_SIGLIST 0
17349 _ACEOF
17350
17351
17352 fi
17353
17354
17355
17356
17357 { echo "$as_me:$LINENO: checking for syslog" >&5
17358 echo $ECHO_N "checking for syslog... $ECHO_C" >&6; }
17359 if test "${ac_cv_func_syslog+set}" = set; then
17360   echo $ECHO_N "(cached) $ECHO_C" >&6
17361 else
17362   cat >conftest.$ac_ext <<_ACEOF
17363 /* confdefs.h.  */
17364 _ACEOF
17365 cat confdefs.h >>conftest.$ac_ext
17366 cat >>conftest.$ac_ext <<_ACEOF
17367 /* end confdefs.h.  */
17368 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
17369    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17370 #define syslog innocuous_syslog
17371
17372 /* System header to define __stub macros and hopefully few prototypes,
17373     which can conflict with char syslog (); below.
17374     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17375     <limits.h> exists even on freestanding compilers.  */
17376
17377 #ifdef __STDC__
17378 # include <limits.h>
17379 #else
17380 # include <assert.h>
17381 #endif
17382
17383 #undef syslog
17384
17385 /* Override any GCC internal prototype to avoid an error.
17386    Use char because int might match the return type of a GCC
17387    builtin and then its argument prototype would still apply.  */
17388 #ifdef __cplusplus
17389 extern "C"
17390 #endif
17391 char syslog ();
17392 /* The GNU C library defines this for functions which it implements
17393     to always fail with ENOSYS.  Some functions are actually named
17394     something starting with __ and the normal name is an alias.  */
17395 #if defined __stub_syslog || defined __stub___syslog
17396 choke me
17397 #endif
17398
17399 int
17400 main ()
17401 {
17402 return syslog ();
17403   ;
17404   return 0;
17405 }
17406 _ACEOF
17407 rm -f conftest.$ac_objext conftest$ac_exeext
17408 if { (ac_try="$ac_link"
17409 case "(($ac_try" in
17410   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17411   *) ac_try_echo=$ac_try;;
17412 esac
17413 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17414   (eval "$ac_link") 2>conftest.er1
17415   ac_status=$?
17416   grep -v '^ *+' conftest.er1 >conftest.err
17417   rm -f conftest.er1
17418   cat conftest.err >&5
17419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17420   (exit $ac_status); } && {
17421          test -z "$ac_c_werror_flag" ||
17422          test ! -s conftest.err
17423        } && test -s conftest$ac_exeext &&
17424        $as_test_x conftest$ac_exeext; then
17425   ac_cv_func_syslog=yes
17426 else
17427   echo "$as_me: failed program was:" >&5
17428 sed 's/^/| /' conftest.$ac_ext >&5
17429
17430         ac_cv_func_syslog=no
17431 fi
17432
17433 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17434       conftest$ac_exeext conftest.$ac_ext
17435 fi
17436 { echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
17437 echo "${ECHO_T}$ac_cv_func_syslog" >&6; }
17438 if test $ac_cv_func_syslog = yes; then
17439   if test "${ac_cv_header_syslog_h+set}" = set; then
17440   { echo "$as_me:$LINENO: checking for syslog.h" >&5
17441 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6; }
17442 if test "${ac_cv_header_syslog_h+set}" = set; then
17443   echo $ECHO_N "(cached) $ECHO_C" >&6
17444 fi
17445 { echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
17446 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6; }
17447 else
17448   # Is the header compilable?
17449 { echo "$as_me:$LINENO: checking syslog.h usability" >&5
17450 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6; }
17451 cat >conftest.$ac_ext <<_ACEOF
17452 /* confdefs.h.  */
17453 _ACEOF
17454 cat confdefs.h >>conftest.$ac_ext
17455 cat >>conftest.$ac_ext <<_ACEOF
17456 /* end confdefs.h.  */
17457 $ac_includes_default
17458 #include <syslog.h>
17459 _ACEOF
17460 rm -f conftest.$ac_objext
17461 if { (ac_try="$ac_compile"
17462 case "(($ac_try" in
17463   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17464   *) ac_try_echo=$ac_try;;
17465 esac
17466 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17467   (eval "$ac_compile") 2>conftest.er1
17468   ac_status=$?
17469   grep -v '^ *+' conftest.er1 >conftest.err
17470   rm -f conftest.er1
17471   cat conftest.err >&5
17472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17473   (exit $ac_status); } && {
17474          test -z "$ac_c_werror_flag" ||
17475          test ! -s conftest.err
17476        } && test -s conftest.$ac_objext; then
17477   ac_header_compiler=yes
17478 else
17479   echo "$as_me: failed program was:" >&5
17480 sed 's/^/| /' conftest.$ac_ext >&5
17481
17482         ac_header_compiler=no
17483 fi
17484
17485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17486 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17487 echo "${ECHO_T}$ac_header_compiler" >&6; }
17488
17489 # Is the header present?
17490 { echo "$as_me:$LINENO: checking syslog.h presence" >&5
17491 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6; }
17492 cat >conftest.$ac_ext <<_ACEOF
17493 /* confdefs.h.  */
17494 _ACEOF
17495 cat confdefs.h >>conftest.$ac_ext
17496 cat >>conftest.$ac_ext <<_ACEOF
17497 /* end confdefs.h.  */
17498 #include <syslog.h>
17499 _ACEOF
17500 if { (ac_try="$ac_cpp conftest.$ac_ext"
17501 case "(($ac_try" in
17502   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17503   *) ac_try_echo=$ac_try;;
17504 esac
17505 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17506   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
17507   ac_status=$?
17508   grep -v '^ *+' conftest.er1 >conftest.err
17509   rm -f conftest.er1
17510   cat conftest.err >&5
17511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17512   (exit $ac_status); } >/dev/null && {
17513          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
17514          test ! -s conftest.err
17515        }; then
17516   ac_header_preproc=yes
17517 else
17518   echo "$as_me: failed program was:" >&5
17519 sed 's/^/| /' conftest.$ac_ext >&5
17520
17521   ac_header_preproc=no
17522 fi
17523
17524 rm -f conftest.err conftest.$ac_ext
17525 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17526 echo "${ECHO_T}$ac_header_preproc" >&6; }
17527
17528 # So?  What about this header?
17529 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17530   yes:no: )
17531     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
17532 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17533     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
17534 echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
17535     ac_header_preproc=yes
17536     ;;
17537   no:yes:* )
17538     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
17539 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
17540     { echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
17541 echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
17542     { echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
17543 echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
17544     { echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
17545 echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
17546     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
17547 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
17548     { echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
17549 echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
17550     ( cat <<\_ASBOX
17551 ## ---------------------------------------- ##
17552 ## Report this to pgsql-bugs@postgresql.org ##
17553 ## ---------------------------------------- ##
17554 _ASBOX
17555      ) | sed "s/^/$as_me: WARNING:     /" >&2
17556     ;;
17557 esac
17558 { echo "$as_me:$LINENO: checking for syslog.h" >&5
17559 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6; }
17560 if test "${ac_cv_header_syslog_h+set}" = set; then
17561   echo $ECHO_N "(cached) $ECHO_C" >&6
17562 else
17563   ac_cv_header_syslog_h=$ac_header_preproc
17564 fi
17565 { echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
17566 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6; }
17567
17568 fi
17569 if test $ac_cv_header_syslog_h = yes; then
17570
17571 cat >>confdefs.h <<\_ACEOF
17572 #define HAVE_SYSLOG 1
17573 _ACEOF
17574
17575 fi
17576
17577
17578 fi
17579
17580
17581 { echo "$as_me:$LINENO: checking for optreset" >&5
17582 echo $ECHO_N "checking for optreset... $ECHO_C" >&6; }
17583 if test "${pgac_cv_var_int_optreset+set}" = set; then
17584   echo $ECHO_N "(cached) $ECHO_C" >&6
17585 else
17586   cat >conftest.$ac_ext <<_ACEOF
17587 /* confdefs.h.  */
17588 _ACEOF
17589 cat confdefs.h >>conftest.$ac_ext
17590 cat >>conftest.$ac_ext <<_ACEOF
17591 /* end confdefs.h.  */
17592 #include <unistd.h>
17593 int
17594 main ()
17595 {
17596 extern int optreset; optreset = 1;
17597   ;
17598   return 0;
17599 }
17600 _ACEOF
17601 rm -f conftest.$ac_objext conftest$ac_exeext
17602 if { (ac_try="$ac_link"
17603 case "(($ac_try" in
17604   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17605   *) ac_try_echo=$ac_try;;
17606 esac
17607 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17608   (eval "$ac_link") 2>conftest.er1
17609   ac_status=$?
17610   grep -v '^ *+' conftest.er1 >conftest.err
17611   rm -f conftest.er1
17612   cat conftest.err >&5
17613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17614   (exit $ac_status); } && {
17615          test -z "$ac_c_werror_flag" ||
17616          test ! -s conftest.err
17617        } && test -s conftest$ac_exeext &&
17618        $as_test_x conftest$ac_exeext; then
17619   pgac_cv_var_int_optreset=yes
17620 else
17621   echo "$as_me: failed program was:" >&5
17622 sed 's/^/| /' conftest.$ac_ext >&5
17623
17624         pgac_cv_var_int_optreset=no
17625 fi
17626
17627 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17628       conftest$ac_exeext conftest.$ac_ext
17629 fi
17630 { echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
17631 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6; }
17632 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
17633
17634 cat >>confdefs.h <<\_ACEOF
17635 #define HAVE_INT_OPTRESET 1
17636 _ACEOF
17637
17638 fi
17639
17640
17641
17642 for ac_func in strtoll strtoq
17643 do
17644 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17645 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17646 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17647 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17648   echo $ECHO_N "(cached) $ECHO_C" >&6
17649 else
17650   cat >conftest.$ac_ext <<_ACEOF
17651 /* confdefs.h.  */
17652 _ACEOF
17653 cat confdefs.h >>conftest.$ac_ext
17654 cat >>conftest.$ac_ext <<_ACEOF
17655 /* end confdefs.h.  */
17656 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17657    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17658 #define $ac_func innocuous_$ac_func
17659
17660 /* System header to define __stub macros and hopefully few prototypes,
17661     which can conflict with char $ac_func (); below.
17662     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17663     <limits.h> exists even on freestanding compilers.  */
17664
17665 #ifdef __STDC__
17666 # include <limits.h>
17667 #else
17668 # include <assert.h>
17669 #endif
17670
17671 #undef $ac_func
17672
17673 /* Override any GCC internal prototype to avoid an error.
17674    Use char because int might match the return type of a GCC
17675    builtin and then its argument prototype would still apply.  */
17676 #ifdef __cplusplus
17677 extern "C"
17678 #endif
17679 char $ac_func ();
17680 /* The GNU C library defines this for functions which it implements
17681     to always fail with ENOSYS.  Some functions are actually named
17682     something starting with __ and the normal name is an alias.  */
17683 #if defined __stub_$ac_func || defined __stub___$ac_func
17684 choke me
17685 #endif
17686
17687 int
17688 main ()
17689 {
17690 return $ac_func ();
17691   ;
17692   return 0;
17693 }
17694 _ACEOF
17695 rm -f conftest.$ac_objext conftest$ac_exeext
17696 if { (ac_try="$ac_link"
17697 case "(($ac_try" in
17698   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17699   *) ac_try_echo=$ac_try;;
17700 esac
17701 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17702   (eval "$ac_link") 2>conftest.er1
17703   ac_status=$?
17704   grep -v '^ *+' conftest.er1 >conftest.err
17705   rm -f conftest.er1
17706   cat conftest.err >&5
17707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17708   (exit $ac_status); } && {
17709          test -z "$ac_c_werror_flag" ||
17710          test ! -s conftest.err
17711        } && test -s conftest$ac_exeext &&
17712        $as_test_x conftest$ac_exeext; then
17713   eval "$as_ac_var=yes"
17714 else
17715   echo "$as_me: failed program was:" >&5
17716 sed 's/^/| /' conftest.$ac_ext >&5
17717
17718         eval "$as_ac_var=no"
17719 fi
17720
17721 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17722       conftest$ac_exeext conftest.$ac_ext
17723 fi
17724 ac_res=`eval echo '${'$as_ac_var'}'`
17725                { echo "$as_me:$LINENO: result: $ac_res" >&5
17726 echo "${ECHO_T}$ac_res" >&6; }
17727 if test `eval echo '${'$as_ac_var'}'` = yes; then
17728   cat >>confdefs.h <<_ACEOF
17729 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17730 _ACEOF
17731  break
17732 fi
17733 done
17734
17735
17736
17737 for ac_func in strtoull strtouq
17738 do
17739 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17740 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17741 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17742 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17743   echo $ECHO_N "(cached) $ECHO_C" >&6
17744 else
17745   cat >conftest.$ac_ext <<_ACEOF
17746 /* confdefs.h.  */
17747 _ACEOF
17748 cat confdefs.h >>conftest.$ac_ext
17749 cat >>conftest.$ac_ext <<_ACEOF
17750 /* end confdefs.h.  */
17751 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17752    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17753 #define $ac_func innocuous_$ac_func
17754
17755 /* System header to define __stub macros and hopefully few prototypes,
17756     which can conflict with char $ac_func (); below.
17757     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17758     <limits.h> exists even on freestanding compilers.  */
17759
17760 #ifdef __STDC__
17761 # include <limits.h>
17762 #else
17763 # include <assert.h>
17764 #endif
17765
17766 #undef $ac_func
17767
17768 /* Override any GCC internal prototype to avoid an error.
17769    Use char because int might match the return type of a GCC
17770    builtin and then its argument prototype would still apply.  */
17771 #ifdef __cplusplus
17772 extern "C"
17773 #endif
17774 char $ac_func ();
17775 /* The GNU C library defines this for functions which it implements
17776     to always fail with ENOSYS.  Some functions are actually named
17777     something starting with __ and the normal name is an alias.  */
17778 #if defined __stub_$ac_func || defined __stub___$ac_func
17779 choke me
17780 #endif
17781
17782 int
17783 main ()
17784 {
17785 return $ac_func ();
17786   ;
17787   return 0;
17788 }
17789 _ACEOF
17790 rm -f conftest.$ac_objext conftest$ac_exeext
17791 if { (ac_try="$ac_link"
17792 case "(($ac_try" in
17793   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17794   *) ac_try_echo=$ac_try;;
17795 esac
17796 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17797   (eval "$ac_link") 2>conftest.er1
17798   ac_status=$?
17799   grep -v '^ *+' conftest.er1 >conftest.err
17800   rm -f conftest.er1
17801   cat conftest.err >&5
17802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17803   (exit $ac_status); } && {
17804          test -z "$ac_c_werror_flag" ||
17805          test ! -s conftest.err
17806        } && test -s conftest$ac_exeext &&
17807        $as_test_x conftest$ac_exeext; then
17808   eval "$as_ac_var=yes"
17809 else
17810   echo "$as_me: failed program was:" >&5
17811 sed 's/^/| /' conftest.$ac_ext >&5
17812
17813         eval "$as_ac_var=no"
17814 fi
17815
17816 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17817       conftest$ac_exeext conftest.$ac_ext
17818 fi
17819 ac_res=`eval echo '${'$as_ac_var'}'`
17820                { echo "$as_me:$LINENO: result: $ac_res" >&5
17821 echo "${ECHO_T}$ac_res" >&6; }
17822 if test `eval echo '${'$as_ac_var'}'` = yes; then
17823   cat >>confdefs.h <<_ACEOF
17824 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17825 _ACEOF
17826  break
17827 fi
17828 done
17829
17830
17831 # Check for one of atexit() or on_exit()
17832
17833 for ac_func in atexit
17834 do
17835 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17836 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17837 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17838 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17839   echo $ECHO_N "(cached) $ECHO_C" >&6
17840 else
17841   cat >conftest.$ac_ext <<_ACEOF
17842 /* confdefs.h.  */
17843 _ACEOF
17844 cat confdefs.h >>conftest.$ac_ext
17845 cat >>conftest.$ac_ext <<_ACEOF
17846 /* end confdefs.h.  */
17847 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17848    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17849 #define $ac_func innocuous_$ac_func
17850
17851 /* System header to define __stub macros and hopefully few prototypes,
17852     which can conflict with char $ac_func (); below.
17853     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17854     <limits.h> exists even on freestanding compilers.  */
17855
17856 #ifdef __STDC__
17857 # include <limits.h>
17858 #else
17859 # include <assert.h>
17860 #endif
17861
17862 #undef $ac_func
17863
17864 /* Override any GCC internal prototype to avoid an error.
17865    Use char because int might match the return type of a GCC
17866    builtin and then its argument prototype would still apply.  */
17867 #ifdef __cplusplus
17868 extern "C"
17869 #endif
17870 char $ac_func ();
17871 /* The GNU C library defines this for functions which it implements
17872     to always fail with ENOSYS.  Some functions are actually named
17873     something starting with __ and the normal name is an alias.  */
17874 #if defined __stub_$ac_func || defined __stub___$ac_func
17875 choke me
17876 #endif
17877
17878 int
17879 main ()
17880 {
17881 return $ac_func ();
17882   ;
17883   return 0;
17884 }
17885 _ACEOF
17886 rm -f conftest.$ac_objext conftest$ac_exeext
17887 if { (ac_try="$ac_link"
17888 case "(($ac_try" in
17889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17890   *) ac_try_echo=$ac_try;;
17891 esac
17892 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17893   (eval "$ac_link") 2>conftest.er1
17894   ac_status=$?
17895   grep -v '^ *+' conftest.er1 >conftest.err
17896   rm -f conftest.er1
17897   cat conftest.err >&5
17898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17899   (exit $ac_status); } && {
17900          test -z "$ac_c_werror_flag" ||
17901          test ! -s conftest.err
17902        } && test -s conftest$ac_exeext &&
17903        $as_test_x conftest$ac_exeext; then
17904   eval "$as_ac_var=yes"
17905 else
17906   echo "$as_me: failed program was:" >&5
17907 sed 's/^/| /' conftest.$ac_ext >&5
17908
17909         eval "$as_ac_var=no"
17910 fi
17911
17912 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17913       conftest$ac_exeext conftest.$ac_ext
17914 fi
17915 ac_res=`eval echo '${'$as_ac_var'}'`
17916                { echo "$as_me:$LINENO: result: $ac_res" >&5
17917 echo "${ECHO_T}$ac_res" >&6; }
17918 if test `eval echo '${'$as_ac_var'}'` = yes; then
17919   cat >>confdefs.h <<_ACEOF
17920 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17921 _ACEOF
17922
17923 else
17924
17925 for ac_func in on_exit
17926 do
17927 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17928 { echo "$as_me:$LINENO: checking for $ac_func" >&5
17929 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17930 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17931   echo $ECHO_N "(cached) $ECHO_C" >&6
17932 else
17933   cat >conftest.$ac_ext <<_ACEOF
17934 /* confdefs.h.  */
17935 _ACEOF
17936 cat confdefs.h >>conftest.$ac_ext
17937 cat >>conftest.$ac_ext <<_ACEOF
17938 /* end confdefs.h.  */
17939 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17940    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17941 #define $ac_func innocuous_$ac_func
17942
17943 /* System header to define __stub macros and hopefully few prototypes,
17944     which can conflict with char $ac_func (); below.
17945     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17946     <limits.h> exists even on freestanding compilers.  */
17947
17948 #ifdef __STDC__
17949 # include <limits.h>
17950 #else
17951 # include <assert.h>
17952 #endif
17953
17954 #undef $ac_func
17955
17956 /* Override any GCC internal prototype to avoid an error.
17957    Use char because int might match the return type of a GCC
17958    builtin and then its argument prototype would still apply.  */
17959 #ifdef __cplusplus
17960 extern "C"
17961 #endif
17962 char $ac_func ();
17963 /* The GNU C library defines this for functions which it implements
17964     to always fail with ENOSYS.  Some functions are actually named
17965     something starting with __ and the normal name is an alias.  */
17966 #if defined __stub_$ac_func || defined __stub___$ac_func
17967 choke me
17968 #endif
17969
17970 int
17971 main ()
17972 {
17973 return $ac_func ();
17974   ;
17975   return 0;
17976 }
17977 _ACEOF
17978 rm -f conftest.$ac_objext conftest$ac_exeext
17979 if { (ac_try="$ac_link"
17980 case "(($ac_try" in
17981   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17982   *) ac_try_echo=$ac_try;;
17983 esac
17984 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17985   (eval "$ac_link") 2>conftest.er1
17986   ac_status=$?
17987   grep -v '^ *+' conftest.er1 >conftest.err
17988   rm -f conftest.er1
17989   cat conftest.err >&5
17990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17991   (exit $ac_status); } && {
17992          test -z "$ac_c_werror_flag" ||
17993          test ! -s conftest.err
17994        } && test -s conftest$ac_exeext &&
17995        $as_test_x conftest$ac_exeext; then
17996   eval "$as_ac_var=yes"
17997 else
17998   echo "$as_me: failed program was:" >&5
17999 sed 's/^/| /' conftest.$ac_ext >&5
18000
18001         eval "$as_ac_var=no"
18002 fi
18003
18004 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18005       conftest$ac_exeext conftest.$ac_ext
18006 fi
18007 ac_res=`eval echo '${'$as_ac_var'}'`
18008                { echo "$as_me:$LINENO: result: $ac_res" >&5
18009 echo "${ECHO_T}$ac_res" >&6; }
18010 if test `eval echo '${'$as_ac_var'}'` = yes; then
18011   cat >>confdefs.h <<_ACEOF
18012 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18013 _ACEOF
18014
18015 else
18016   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
18017 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
18018    { (exit 1); exit 1; }; }
18019 fi
18020 done
18021
18022 fi
18023 done
18024
18025
18026
18027 for ac_func in fseeko
18028 do
18029 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18030 { echo "$as_me:$LINENO: checking for $ac_func" >&5
18031 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18032 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18033   echo $ECHO_N "(cached) $ECHO_C" >&6
18034 else
18035   cat >conftest.$ac_ext <<_ACEOF
18036 /* confdefs.h.  */
18037 _ACEOF
18038 cat confdefs.h >>conftest.$ac_ext
18039 cat >>conftest.$ac_ext <<_ACEOF
18040 /* end confdefs.h.  */
18041 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18042    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18043 #define $ac_func innocuous_$ac_func
18044
18045 /* System header to define __stub macros and hopefully few prototypes,
18046     which can conflict with char $ac_func (); below.
18047     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18048     <limits.h> exists even on freestanding compilers.  */
18049
18050 #ifdef __STDC__
18051 # include <limits.h>
18052 #else
18053 # include <assert.h>
18054 #endif
18055
18056 #undef $ac_func
18057
18058 /* Override any GCC internal prototype to avoid an error.
18059    Use char because int might match the return type of a GCC
18060    builtin and then its argument prototype would still apply.  */
18061 #ifdef __cplusplus
18062 extern "C"
18063 #endif
18064 char $ac_func ();
18065 /* The GNU C library defines this for functions which it implements
18066     to always fail with ENOSYS.  Some functions are actually named
18067     something starting with __ and the normal name is an alias.  */
18068 #if defined __stub_$ac_func || defined __stub___$ac_func
18069 choke me
18070 #endif
18071
18072 int
18073 main ()
18074 {
18075 return $ac_func ();
18076   ;
18077   return 0;
18078 }
18079 _ACEOF
18080 rm -f conftest.$ac_objext conftest$ac_exeext
18081 if { (ac_try="$ac_link"
18082 case "(($ac_try" in
18083   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18084   *) ac_try_echo=$ac_try;;
18085 esac
18086 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18087   (eval "$ac_link") 2>conftest.er1
18088   ac_status=$?
18089   grep -v '^ *+' conftest.er1 >conftest.err
18090   rm -f conftest.er1
18091   cat conftest.err >&5
18092   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18093   (exit $ac_status); } && {
18094          test -z "$ac_c_werror_flag" ||
18095          test ! -s conftest.err
18096        } && test -s conftest$ac_exeext &&
18097        $as_test_x conftest$ac_exeext; then
18098   eval "$as_ac_var=yes"
18099 else
18100   echo "$as_me: failed program was:" >&5
18101 sed 's/^/| /' conftest.$ac_ext >&5
18102
18103         eval "$as_ac_var=no"
18104 fi
18105
18106 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18107       conftest$ac_exeext conftest.$ac_ext
18108 fi
18109 ac_res=`eval echo '${'$as_ac_var'}'`
18110                { echo "$as_me:$LINENO: result: $ac_res" >&5
18111 echo "${ECHO_T}$ac_res" >&6; }
18112 if test `eval echo '${'$as_ac_var'}'` = yes; then
18113   cat >>confdefs.h <<_ACEOF
18114 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18115 _ACEOF
18116
18117 else
18118   case " $LIBOBJS " in
18119   *" $ac_func.$ac_objext "* ) ;;
18120   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18121  ;;
18122 esac
18123
18124 fi
18125 done
18126
18127
18128 case $host_os in
18129         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
18130         bsdi*|netbsd*)
18131
18132 cat >>confdefs.h <<\_ACEOF
18133 #define HAVE_FSEEKO 1
18134 _ACEOF
18135
18136                 ac_cv_func_fseeko=yes;;
18137         *)
18138                 { echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
18139 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6; }
18140 if test "${ac_cv_sys_largefile_source+set}" = set; then
18141   echo $ECHO_N "(cached) $ECHO_C" >&6
18142 else
18143   while :; do
18144   cat >conftest.$ac_ext <<_ACEOF
18145 /* confdefs.h.  */
18146 _ACEOF
18147 cat confdefs.h >>conftest.$ac_ext
18148 cat >>conftest.$ac_ext <<_ACEOF
18149 /* end confdefs.h.  */
18150 #include <sys/types.h> /* for off_t */
18151      #include <stdio.h>
18152 int
18153 main ()
18154 {
18155 int (*fp) (FILE *, off_t, int) = fseeko;
18156      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18157   ;
18158   return 0;
18159 }
18160 _ACEOF
18161 rm -f conftest.$ac_objext conftest$ac_exeext
18162 if { (ac_try="$ac_link"
18163 case "(($ac_try" in
18164   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18165   *) ac_try_echo=$ac_try;;
18166 esac
18167 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18168   (eval "$ac_link") 2>conftest.er1
18169   ac_status=$?
18170   grep -v '^ *+' conftest.er1 >conftest.err
18171   rm -f conftest.er1
18172   cat conftest.err >&5
18173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18174   (exit $ac_status); } && {
18175          test -z "$ac_c_werror_flag" ||
18176          test ! -s conftest.err
18177        } && test -s conftest$ac_exeext &&
18178        $as_test_x conftest$ac_exeext; then
18179   ac_cv_sys_largefile_source=no; break
18180 else
18181   echo "$as_me: failed program was:" >&5
18182 sed 's/^/| /' conftest.$ac_ext >&5
18183
18184
18185 fi
18186
18187 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18188       conftest$ac_exeext conftest.$ac_ext
18189   cat >conftest.$ac_ext <<_ACEOF
18190 /* confdefs.h.  */
18191 _ACEOF
18192 cat confdefs.h >>conftest.$ac_ext
18193 cat >>conftest.$ac_ext <<_ACEOF
18194 /* end confdefs.h.  */
18195 #define _LARGEFILE_SOURCE 1
18196 #include <sys/types.h> /* for off_t */
18197      #include <stdio.h>
18198 int
18199 main ()
18200 {
18201 int (*fp) (FILE *, off_t, int) = fseeko;
18202      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18203   ;
18204   return 0;
18205 }
18206 _ACEOF
18207 rm -f conftest.$ac_objext conftest$ac_exeext
18208 if { (ac_try="$ac_link"
18209 case "(($ac_try" in
18210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18211   *) ac_try_echo=$ac_try;;
18212 esac
18213 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18214   (eval "$ac_link") 2>conftest.er1
18215   ac_status=$?
18216   grep -v '^ *+' conftest.er1 >conftest.err
18217   rm -f conftest.er1
18218   cat conftest.err >&5
18219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18220   (exit $ac_status); } && {
18221          test -z "$ac_c_werror_flag" ||
18222          test ! -s conftest.err
18223        } && test -s conftest$ac_exeext &&
18224        $as_test_x conftest$ac_exeext; then
18225   ac_cv_sys_largefile_source=1; break
18226 else
18227   echo "$as_me: failed program was:" >&5
18228 sed 's/^/| /' conftest.$ac_ext >&5
18229
18230
18231 fi
18232
18233 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18234       conftest$ac_exeext conftest.$ac_ext
18235   ac_cv_sys_largefile_source=unknown
18236   break
18237 done
18238 fi
18239 { echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
18240 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6; }
18241 case $ac_cv_sys_largefile_source in #(
18242   no | unknown) ;;
18243   *)
18244 cat >>confdefs.h <<_ACEOF
18245 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
18246 _ACEOF
18247 ;;
18248 esac
18249 rm -f conftest*
18250
18251 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
18252 # in glibc 2.1.3, but that breaks too many other things.
18253 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
18254 if test $ac_cv_sys_largefile_source != unknown; then
18255
18256 cat >>confdefs.h <<\_ACEOF
18257 #define HAVE_FSEEKO 1
18258 _ACEOF
18259
18260 fi
18261 ;;
18262 esac
18263
18264
18265 #
18266 # Pthreads
18267 #
18268 # For each platform, we need to know about any special compile and link
18269 # libraries, and whether the normal C function names are thread-safe.
18270 # See the comment at the top of src/port/thread.c for more information.
18271 # WIN32 doesn't need the pthread tests;  it always uses threads
18272 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
18273
18274
18275
18276 ac_ext=c
18277 ac_cpp='$CPP $CPPFLAGS'
18278 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18279 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18280 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18281
18282 acx_pthread_ok=no
18283
18284 # We used to check for pthread.h first, but this fails if pthread.h
18285 # requires special compiler flags (e.g. on True64 or Sequent).
18286 # It gets checked for in the link test anyway.
18287
18288 # First of all, check if the user has set any of the PTHREAD_LIBS,
18289 # etcetera environment variables, and if threads linking works using
18290 # them:
18291 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
18292         save_CFLAGS="$CFLAGS"
18293         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
18294         save_LIBS="$LIBS"
18295         LIBS="$PTHREAD_LIBS $LIBS"
18296         { echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
18297 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6; }
18298         cat >conftest.$ac_ext <<_ACEOF
18299 /* confdefs.h.  */
18300 _ACEOF
18301 cat confdefs.h >>conftest.$ac_ext
18302 cat >>conftest.$ac_ext <<_ACEOF
18303 /* end confdefs.h.  */
18304
18305 /* Override any GCC internal prototype to avoid an error.
18306    Use char because int might match the return type of a GCC
18307    builtin and then its argument prototype would still apply.  */
18308 #ifdef __cplusplus
18309 extern "C"
18310 #endif
18311 char pthread_join ();
18312 int
18313 main ()
18314 {
18315 return pthread_join ();
18316   ;
18317   return 0;
18318 }
18319 _ACEOF
18320 rm -f conftest.$ac_objext conftest$ac_exeext
18321 if { (ac_try="$ac_link"
18322 case "(($ac_try" in
18323   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18324   *) ac_try_echo=$ac_try;;
18325 esac
18326 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18327   (eval "$ac_link") 2>conftest.er1
18328   ac_status=$?
18329   grep -v '^ *+' conftest.er1 >conftest.err
18330   rm -f conftest.er1
18331   cat conftest.err >&5
18332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18333   (exit $ac_status); } && {
18334          test -z "$ac_c_werror_flag" ||
18335          test ! -s conftest.err
18336        } && test -s conftest$ac_exeext &&
18337        $as_test_x conftest$ac_exeext; then
18338   acx_pthread_ok=yes
18339 else
18340   echo "$as_me: failed program was:" >&5
18341 sed 's/^/| /' conftest.$ac_ext >&5
18342
18343
18344 fi
18345
18346 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18347       conftest$ac_exeext conftest.$ac_ext
18348         { echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
18349 echo "${ECHO_T}$acx_pthread_ok" >&6; }
18350         if test x"$acx_pthread_ok" = xno; then
18351                 PTHREAD_LIBS=""
18352                 PTHREAD_CFLAGS=""
18353         fi
18354         LIBS="$save_LIBS"
18355         CFLAGS="$save_CFLAGS"
18356 fi
18357
18358 # We must check for the threads library under a number of different
18359 # names; the ordering is very important because some systems
18360 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
18361 # libraries is broken (non-POSIX).
18362
18363 # Create a list of thread flags to try.  Items starting with a "-" are
18364 # C compiler flags, and other items are library names, except for "none"
18365 # which indicates that we try without any flags at all, and "pthread-config"
18366 # which is a program returning the flags for the Pth emulation library.
18367
18368 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
18369
18370 # The ordering *is* (sometimes) important.  Some notes on the
18371 # individual items follow:
18372
18373 # pthreads: AIX (must check this before -lpthread)
18374 # none: in case threads are in libc; should be tried before -Kthread and
18375 #       other compiler flags to prevent continual compiler warnings
18376 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
18377 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
18378 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
18379 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
18380 # -pthreads: Solaris/gcc
18381 # -mthreads: Mingw32/gcc, Lynx/gcc
18382 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
18383 #      doesn't hurt to check since this sometimes defines pthreads too;
18384 #      also defines -D_REENTRANT)
18385 # pthread: Linux, etcetera
18386 # --thread-safe: KAI C++
18387 # pthread-config: use pthread-config program (for GNU Pth library)
18388
18389 case "${host_cpu}-${host_os}" in
18390         *solaris*)
18391
18392         # On Solaris (at least, for some versions), libc contains stubbed
18393         # (non-functional) versions of the pthreads routines, so link-based
18394         # tests will erroneously succeed.  (We need to link with -pthread or
18395         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
18396         # a function called by this macro, so we could check for that, but
18397         # who knows whether they'll stub that too in a future libc.)  So,
18398         # we'll just look for -pthreads and -lpthread first:
18399
18400         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
18401         ;;
18402 esac
18403
18404 if test x"$acx_pthread_ok" = xno; then
18405 for flag in $acx_pthread_flags; do
18406
18407         tryPTHREAD_CFLAGS=""
18408         tryPTHREAD_LIBS=""
18409         case $flag in
18410                 none)
18411                 { echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
18412 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6; }
18413                 ;;
18414
18415                 -*)
18416                 { echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
18417 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6; }
18418                 tryPTHREAD_CFLAGS="$flag"
18419                 ;;
18420
18421                 pthread-config)
18422                 # skip this if we already have flags defined, for PostgreSQL
18423                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
18424                 # Extract the first word of "pthread-config", so it can be a program name with args.
18425 set dummy pthread-config; ac_word=$2
18426 { echo "$as_me:$LINENO: checking for $ac_word" >&5
18427 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
18428 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
18429   echo $ECHO_N "(cached) $ECHO_C" >&6
18430 else
18431   if test -n "$acx_pthread_config"; then
18432   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
18433 else
18434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18435 for as_dir in $PATH
18436 do
18437   IFS=$as_save_IFS
18438   test -z "$as_dir" && as_dir=.
18439   for ac_exec_ext in '' $ac_executable_extensions; do
18440   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18441     ac_cv_prog_acx_pthread_config="yes"
18442     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18443     break 2
18444   fi
18445 done
18446 done
18447 IFS=$as_save_IFS
18448
18449   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
18450 fi
18451 fi
18452 acx_pthread_config=$ac_cv_prog_acx_pthread_config
18453 if test -n "$acx_pthread_config"; then
18454   { echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
18455 echo "${ECHO_T}$acx_pthread_config" >&6; }
18456 else
18457   { echo "$as_me:$LINENO: result: no" >&5
18458 echo "${ECHO_T}no" >&6; }
18459 fi
18460
18461
18462                 if test x"$acx_pthread_config" = xno; then continue; fi
18463                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
18464                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
18465                 ;;
18466
18467                 *)
18468                 { echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
18469 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6; }
18470                 tryPTHREAD_LIBS="-l$flag"
18471                 ;;
18472         esac
18473
18474         save_LIBS="$LIBS"
18475         save_CFLAGS="$CFLAGS"
18476         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
18477         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
18478
18479         # Check for various functions.  We must include pthread.h,
18480         # since some functions may be macros.  (On the Sequent, we
18481         # need a special flag -Kthread to make this header compile.)
18482         # We check for pthread_join because it is in -lpthread on IRIX
18483         # while pthread_create is in libc.  We check for pthread_attr_init
18484         # due to DEC craziness with -lpthreads.  We check for
18485         # pthread_cleanup_push because it is one of the few pthread
18486         # functions on Solaris that doesn't have a non-functional libc stub.
18487         # We try pthread_create on general principles.
18488         cat >conftest.$ac_ext <<_ACEOF
18489 /* confdefs.h.  */
18490 _ACEOF
18491 cat confdefs.h >>conftest.$ac_ext
18492 cat >>conftest.$ac_ext <<_ACEOF
18493 /* end confdefs.h.  */
18494 #include <pthread.h>
18495 int
18496 main ()
18497 {
18498 pthread_t th; pthread_join(th, 0);
18499                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
18500                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
18501   ;
18502   return 0;
18503 }
18504 _ACEOF
18505 rm -f conftest.$ac_objext conftest$ac_exeext
18506 if { (ac_try="$ac_link"
18507 case "(($ac_try" in
18508   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18509   *) ac_try_echo=$ac_try;;
18510 esac
18511 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18512   (eval "$ac_link") 2>conftest.er1
18513   ac_status=$?
18514   grep -v '^ *+' conftest.er1 >conftest.err
18515   rm -f conftest.er1
18516   cat conftest.err >&5
18517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18518   (exit $ac_status); } && {
18519          test -z "$ac_c_werror_flag" ||
18520          test ! -s conftest.err
18521        } && test -s conftest$ac_exeext &&
18522        $as_test_x conftest$ac_exeext; then
18523   acx_pthread_ok=yes
18524 else
18525   echo "$as_me: failed program was:" >&5
18526 sed 's/^/| /' conftest.$ac_ext >&5
18527
18528         acx_pthread_ok=no
18529 fi
18530
18531 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18532       conftest$ac_exeext conftest.$ac_ext
18533
18534         if test "x$acx_pthread_ok" = xyes; then
18535             # Don't use options that are ignored by the compiler.
18536             # We find them by checking stderror.
18537             cat >conftest.$ac_ext <<_ACEOF
18538 int
18539 main (int argc, char **argv)
18540 {
18541   (void) argc;
18542   (void) argv;
18543   return 0;
18544 }
18545 _ACEOF
18546             rm -f conftest.$ac_objext conftest$ac_exeext
18547             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
18548                 # we continue with more flags because Linux needs -lpthread
18549                 # for libpq builds on PostgreSQL.  The test above only
18550                 # tests for building binaries, not shared libraries.
18551                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
18552                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
18553             else   acx_pthread_ok=no
18554             fi
18555         fi
18556
18557         LIBS="$save_LIBS"
18558         CFLAGS="$save_CFLAGS"
18559
18560         { echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
18561 echo "${ECHO_T}$acx_pthread_ok" >&6; }
18562 done
18563 fi
18564
18565 # Various other checks:
18566 if test "x$acx_pthread_ok" = xyes; then
18567         save_LIBS="$LIBS"
18568         LIBS="$PTHREAD_LIBS $LIBS"
18569         save_CFLAGS="$CFLAGS"
18570         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
18571
18572         # Detect AIX lossage: threads are created detached by default
18573         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
18574         { echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
18575 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6; }
18576         cat >conftest.$ac_ext <<_ACEOF
18577 /* confdefs.h.  */
18578 _ACEOF
18579 cat confdefs.h >>conftest.$ac_ext
18580 cat >>conftest.$ac_ext <<_ACEOF
18581 /* end confdefs.h.  */
18582 #include <pthread.h>
18583 int
18584 main ()
18585 {
18586 int attr=PTHREAD_CREATE_JOINABLE;
18587   ;
18588   return 0;
18589 }
18590 _ACEOF
18591 rm -f conftest.$ac_objext conftest$ac_exeext
18592 if { (ac_try="$ac_link"
18593 case "(($ac_try" in
18594   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18595   *) ac_try_echo=$ac_try;;
18596 esac
18597 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18598   (eval "$ac_link") 2>conftest.er1
18599   ac_status=$?
18600   grep -v '^ *+' conftest.er1 >conftest.err
18601   rm -f conftest.er1
18602   cat conftest.err >&5
18603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18604   (exit $ac_status); } && {
18605          test -z "$ac_c_werror_flag" ||
18606          test ! -s conftest.err
18607        } && test -s conftest$ac_exeext &&
18608        $as_test_x conftest$ac_exeext; then
18609   ok=PTHREAD_CREATE_JOINABLE
18610 else
18611   echo "$as_me: failed program was:" >&5
18612 sed 's/^/| /' conftest.$ac_ext >&5
18613
18614         ok=unknown
18615 fi
18616
18617 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18618       conftest$ac_exeext conftest.$ac_ext
18619         if test x"$ok" = xunknown; then
18620                 cat >conftest.$ac_ext <<_ACEOF
18621 /* confdefs.h.  */
18622 _ACEOF
18623 cat confdefs.h >>conftest.$ac_ext
18624 cat >>conftest.$ac_ext <<_ACEOF
18625 /* end confdefs.h.  */
18626 #include <pthread.h>
18627 int
18628 main ()
18629 {
18630 int attr=PTHREAD_CREATE_UNDETACHED;
18631   ;
18632   return 0;
18633 }
18634 _ACEOF
18635 rm -f conftest.$ac_objext conftest$ac_exeext
18636 if { (ac_try="$ac_link"
18637 case "(($ac_try" in
18638   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18639   *) ac_try_echo=$ac_try;;
18640 esac
18641 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18642   (eval "$ac_link") 2>conftest.er1
18643   ac_status=$?
18644   grep -v '^ *+' conftest.er1 >conftest.err
18645   rm -f conftest.er1
18646   cat conftest.err >&5
18647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18648   (exit $ac_status); } && {
18649          test -z "$ac_c_werror_flag" ||
18650          test ! -s conftest.err
18651        } && test -s conftest$ac_exeext &&
18652        $as_test_x conftest$ac_exeext; then
18653   ok=PTHREAD_CREATE_UNDETACHED
18654 else
18655   echo "$as_me: failed program was:" >&5
18656 sed 's/^/| /' conftest.$ac_ext >&5
18657
18658         ok=unknown
18659 fi
18660
18661 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18662       conftest$ac_exeext conftest.$ac_ext
18663         fi
18664         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
18665
18666 cat >>confdefs.h <<\_ACEOF
18667 #define PTHREAD_CREATE_JOINABLE $ok
18668 _ACEOF
18669
18670         fi
18671         { echo "$as_me:$LINENO: result: ${ok}" >&5
18672 echo "${ECHO_T}${ok}" >&6; }
18673         if test x"$ok" = xunknown; then
18674                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
18675 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
18676         fi
18677
18678         { echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
18679 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6; }
18680         flag=no
18681 # We always add these in PostgreSQL
18682 #       case "${host_cpu}-${host_os}" in
18683 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
18684 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
18685 #       esac
18686         { echo "$as_me:$LINENO: result: ${flag}" >&5
18687 echo "${ECHO_T}${flag}" >&6; }
18688         if test "x$flag" != xno; then
18689                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
18690         fi
18691
18692         LIBS="$save_LIBS"
18693         CFLAGS="$save_CFLAGS"
18694
18695 # Supporting cc_r would require a special CC in all places that
18696 # use libpq, and that is ugly, so we don't do it.  Users can still
18697 # define their compiler as cc_r to do thread builds of everything.
18698         # More AIX lossage: must compile with cc_r
18699         # Extract the first word of "cc_r", so it can be a program name with args.
18700 set dummy cc_r; ac_word=$2
18701 { echo "$as_me:$LINENO: checking for $ac_word" >&5
18702 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
18703 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
18704   echo $ECHO_N "(cached) $ECHO_C" >&6
18705 else
18706   if test -n "$PTHREAD_CC"; then
18707   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
18708 else
18709 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18710 for as_dir in $PATH
18711 do
18712   IFS=$as_save_IFS
18713   test -z "$as_dir" && as_dir=.
18714   for ac_exec_ext in '' $ac_executable_extensions; do
18715   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18716     ac_cv_prog_PTHREAD_CC="cc_r"
18717     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18718     break 2
18719   fi
18720 done
18721 done
18722 IFS=$as_save_IFS
18723
18724   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
18725 fi
18726 fi
18727 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
18728 if test -n "$PTHREAD_CC"; then
18729   { echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
18730 echo "${ECHO_T}$PTHREAD_CC" >&6; }
18731 else
18732   { echo "$as_me:$LINENO: result: no" >&5
18733 echo "${ECHO_T}no" >&6; }
18734 fi
18735
18736
18737 else
18738         PTHREAD_CC="$CC"
18739 fi
18740
18741
18742
18743
18744
18745 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
18746 if test x"$acx_pthread_ok" = xyes; then
18747
18748 cat >>confdefs.h <<\_ACEOF
18749 #define HAVE_PTHREAD 1
18750 _ACEOF
18751
18752         :
18753 else
18754         acx_pthread_ok=no
18755
18756 fi
18757 ac_ext=c
18758 ac_cpp='$CPP $CPPFLAGS'
18759 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18760 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18761 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18762
18763         # set thread flags
18764
18765 # Some platforms use these, so just defineed them.  They can't hurt if they
18766 # are not supported.
18767 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
18768
18769
18770 # At this point, we don't want to muck with the compiler name for threading.
18771 # Let's see who fails, perhaps AIX.  2004-04-23
18772 if test "$PTHREAD_CC" != "$CC"; then
18773 { { echo "$as_me:$LINENO: error:
18774 PostgreSQL does not support platforms that require a special compiler
18775 for thread safety." >&5
18776 echo "$as_me: error:
18777 PostgreSQL does not support platforms that require a special compiler
18778 for thread safety." >&2;}
18779    { (exit 1); exit 1; }; }
18780 fi
18781
18782 if test "$THREAD_SUPPORT" = no; then
18783 { { echo "$as_me:$LINENO: error: cannot enable threads on this platform
18784 This platform is known to not support thread-safe programs.  For details,
18785 compile and run src/bin/pg_thread_test." >&5
18786 echo "$as_me: error: cannot enable threads on this platform
18787 This platform is known to not support thread-safe programs.  For details,
18788 compile and run src/bin/pg_thread_test." >&2;}
18789    { (exit 1); exit 1; }; }
18790 fi
18791
18792 # Check for *_r functions
18793 _CFLAGS="$CFLAGS"
18794 _LIBS="$LIBS"
18795 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
18796 LIBS="$LIBS $PTHREAD_LIBS"
18797
18798 if test "$PORTNAME" != "win32"; then
18799 if test "${ac_cv_header_pthread_h+set}" = set; then
18800   { echo "$as_me:$LINENO: checking for pthread.h" >&5
18801 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6; }
18802 if test "${ac_cv_header_pthread_h+set}" = set; then
18803   echo $ECHO_N "(cached) $ECHO_C" >&6
18804 fi
18805 { echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
18806 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6; }
18807 else
18808   # Is the header compilable?
18809 { echo "$as_me:$LINENO: checking pthread.h usability" >&5
18810 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6; }
18811 cat >conftest.$ac_ext <<_ACEOF
18812 /* confdefs.h.  */
18813 _ACEOF
18814 cat confdefs.h >>conftest.$ac_ext
18815 cat >>conftest.$ac_ext <<_ACEOF
18816 /* end confdefs.h.  */
18817 $ac_includes_default
18818 #include <pthread.h>
18819 _ACEOF
18820 rm -f conftest.$ac_objext
18821 if { (ac_try="$ac_compile"
18822 case "(($ac_try" in
18823   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18824   *) ac_try_echo=$ac_try;;
18825 esac
18826 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18827   (eval "$ac_compile") 2>conftest.er1
18828   ac_status=$?
18829   grep -v '^ *+' conftest.er1 >conftest.err
18830   rm -f conftest.er1
18831   cat conftest.err >&5
18832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18833   (exit $ac_status); } && {
18834          test -z "$ac_c_werror_flag" ||
18835          test ! -s conftest.err
18836        } && test -s conftest.$ac_objext; then
18837   ac_header_compiler=yes
18838 else
18839   echo "$as_me: failed program was:" >&5
18840 sed 's/^/| /' conftest.$ac_ext >&5
18841
18842         ac_header_compiler=no
18843 fi
18844
18845 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18846 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18847 echo "${ECHO_T}$ac_header_compiler" >&6; }
18848
18849 # Is the header present?
18850 { echo "$as_me:$LINENO: checking pthread.h presence" >&5
18851 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6; }
18852 cat >conftest.$ac_ext <<_ACEOF
18853 /* confdefs.h.  */
18854 _ACEOF
18855 cat confdefs.h >>conftest.$ac_ext
18856 cat >>conftest.$ac_ext <<_ACEOF
18857 /* end confdefs.h.  */
18858 #include <pthread.h>
18859 _ACEOF
18860 if { (ac_try="$ac_cpp conftest.$ac_ext"
18861 case "(($ac_try" in
18862   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18863   *) ac_try_echo=$ac_try;;
18864 esac
18865 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18866   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
18867   ac_status=$?
18868   grep -v '^ *+' conftest.er1 >conftest.err
18869   rm -f conftest.er1
18870   cat conftest.err >&5
18871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18872   (exit $ac_status); } >/dev/null && {
18873          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
18874          test ! -s conftest.err
18875        }; then
18876   ac_header_preproc=yes
18877 else
18878   echo "$as_me: failed program was:" >&5
18879 sed 's/^/| /' conftest.$ac_ext >&5
18880
18881   ac_header_preproc=no
18882 fi
18883
18884 rm -f conftest.err conftest.$ac_ext
18885 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18886 echo "${ECHO_T}$ac_header_preproc" >&6; }
18887
18888 # So?  What about this header?
18889 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18890   yes:no: )
18891     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
18892 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18893     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
18894 echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
18895     ac_header_preproc=yes
18896     ;;
18897   no:yes:* )
18898     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
18899 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
18900     { echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
18901 echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
18902     { echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
18903 echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
18904     { echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
18905 echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
18906     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
18907 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
18908     { echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
18909 echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
18910     ( cat <<\_ASBOX
18911 ## ---------------------------------------- ##
18912 ## Report this to pgsql-bugs@postgresql.org ##
18913 ## ---------------------------------------- ##
18914 _ASBOX
18915      ) | sed "s/^/$as_me: WARNING:     /" >&2
18916     ;;
18917 esac
18918 { echo "$as_me:$LINENO: checking for pthread.h" >&5
18919 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6; }
18920 if test "${ac_cv_header_pthread_h+set}" = set; then
18921   echo $ECHO_N "(cached) $ECHO_C" >&6
18922 else
18923   ac_cv_header_pthread_h=$ac_header_preproc
18924 fi
18925 { echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
18926 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6; }
18927
18928 fi
18929 if test $ac_cv_header_pthread_h = yes; then
18930   :
18931 else
18932   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
18933 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
18934    { (exit 1); exit 1; }; }
18935 fi
18936
18937
18938 fi
18939
18940
18941
18942
18943 for ac_func in strerror_r getpwuid_r gethostbyname_r
18944 do
18945 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18946 { echo "$as_me:$LINENO: checking for $ac_func" >&5
18947 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18948 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18949   echo $ECHO_N "(cached) $ECHO_C" >&6
18950 else
18951   cat >conftest.$ac_ext <<_ACEOF
18952 /* confdefs.h.  */
18953 _ACEOF
18954 cat confdefs.h >>conftest.$ac_ext
18955 cat >>conftest.$ac_ext <<_ACEOF
18956 /* end confdefs.h.  */
18957 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18958    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18959 #define $ac_func innocuous_$ac_func
18960
18961 /* System header to define __stub macros and hopefully few prototypes,
18962     which can conflict with char $ac_func (); below.
18963     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18964     <limits.h> exists even on freestanding compilers.  */
18965
18966 #ifdef __STDC__
18967 # include <limits.h>
18968 #else
18969 # include <assert.h>
18970 #endif
18971
18972 #undef $ac_func
18973
18974 /* Override any GCC internal prototype to avoid an error.
18975    Use char because int might match the return type of a GCC
18976    builtin and then its argument prototype would still apply.  */
18977 #ifdef __cplusplus
18978 extern "C"
18979 #endif
18980 char $ac_func ();
18981 /* The GNU C library defines this for functions which it implements
18982     to always fail with ENOSYS.  Some functions are actually named
18983     something starting with __ and the normal name is an alias.  */
18984 #if defined __stub_$ac_func || defined __stub___$ac_func
18985 choke me
18986 #endif
18987
18988 int
18989 main ()
18990 {
18991 return $ac_func ();
18992   ;
18993   return 0;
18994 }
18995 _ACEOF
18996 rm -f conftest.$ac_objext conftest$ac_exeext
18997 if { (ac_try="$ac_link"
18998 case "(($ac_try" in
18999   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19000   *) ac_try_echo=$ac_try;;
19001 esac
19002 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19003   (eval "$ac_link") 2>conftest.er1
19004   ac_status=$?
19005   grep -v '^ *+' conftest.er1 >conftest.err
19006   rm -f conftest.er1
19007   cat conftest.err >&5
19008   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19009   (exit $ac_status); } && {
19010          test -z "$ac_c_werror_flag" ||
19011          test ! -s conftest.err
19012        } && test -s conftest$ac_exeext &&
19013        $as_test_x conftest$ac_exeext; then
19014   eval "$as_ac_var=yes"
19015 else
19016   echo "$as_me: failed program was:" >&5
19017 sed 's/^/| /' conftest.$ac_ext >&5
19018
19019         eval "$as_ac_var=no"
19020 fi
19021
19022 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19023       conftest$ac_exeext conftest.$ac_ext
19024 fi
19025 ac_res=`eval echo '${'$as_ac_var'}'`
19026                { echo "$as_me:$LINENO: result: $ac_res" >&5
19027 echo "${ECHO_T}$ac_res" >&6; }
19028 if test `eval echo '${'$as_ac_var'}'` = yes; then
19029   cat >>confdefs.h <<_ACEOF
19030 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19031 _ACEOF
19032
19033 fi
19034 done
19035
19036
19037 # Do test here with the proper thread flags
19038 { echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
19039 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6; }
19040 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
19041   echo $ECHO_N "(cached) $ECHO_C" >&6
19042 else
19043   cat >conftest.$ac_ext <<_ACEOF
19044 /* confdefs.h.  */
19045 _ACEOF
19046 cat confdefs.h >>conftest.$ac_ext
19047 cat >>conftest.$ac_ext <<_ACEOF
19048 /* end confdefs.h.  */
19049 #include <sys/types.h>
19050 #include <pwd.h>
19051 int
19052 main ()
19053 {
19054 uid_t uid;
19055 struct passwd *space;
19056 char *buf;
19057 size_t bufsize;
19058 struct passwd **result;
19059 getpwuid_r(uid, space, buf, bufsize, result);
19060   ;
19061   return 0;
19062 }
19063 _ACEOF
19064 rm -f conftest.$ac_objext
19065 if { (ac_try="$ac_compile"
19066 case "(($ac_try" in
19067   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19068   *) ac_try_echo=$ac_try;;
19069 esac
19070 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19071   (eval "$ac_compile") 2>conftest.er1
19072   ac_status=$?
19073   grep -v '^ *+' conftest.er1 >conftest.err
19074   rm -f conftest.er1
19075   cat conftest.err >&5
19076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19077   (exit $ac_status); } && {
19078          test -z "$ac_c_werror_flag" ||
19079          test ! -s conftest.err
19080        } && test -s conftest.$ac_objext; then
19081   pgac_func_getpwuid_r_5arg=yes
19082 else
19083   echo "$as_me: failed program was:" >&5
19084 sed 's/^/| /' conftest.$ac_ext >&5
19085
19086         pgac_func_getpwuid_r_5arg=no
19087 fi
19088
19089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19090 fi
19091 { echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
19092 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6; }
19093 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
19094
19095 cat >>confdefs.h <<\_ACEOF
19096 #define GETPWUID_R_5ARG
19097 _ACEOF
19098
19099 fi
19100
19101 { echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
19102 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6; }
19103 if test "${pgac_func_strerror_r_int+set}" = set; then
19104   echo $ECHO_N "(cached) $ECHO_C" >&6
19105 else
19106   cat >conftest.$ac_ext <<_ACEOF
19107 /* confdefs.h.  */
19108 _ACEOF
19109 cat confdefs.h >>conftest.$ac_ext
19110 cat >>conftest.$ac_ext <<_ACEOF
19111 /* end confdefs.h.  */
19112 #include <string.h>
19113 int
19114 main ()
19115 {
19116 #ifndef _AIX
19117 int strerror_r(int, char *, size_t);
19118 #else
19119 /* Older AIX has 'int' for the third argument so we don't test the args. */
19120 int strerror_r();
19121 #endif
19122   ;
19123   return 0;
19124 }
19125 _ACEOF
19126 rm -f conftest.$ac_objext
19127 if { (ac_try="$ac_compile"
19128 case "(($ac_try" in
19129   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19130   *) ac_try_echo=$ac_try;;
19131 esac
19132 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19133   (eval "$ac_compile") 2>conftest.er1
19134   ac_status=$?
19135   grep -v '^ *+' conftest.er1 >conftest.err
19136   rm -f conftest.er1
19137   cat conftest.err >&5
19138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19139   (exit $ac_status); } && {
19140          test -z "$ac_c_werror_flag" ||
19141          test ! -s conftest.err
19142        } && test -s conftest.$ac_objext; then
19143   pgac_func_strerror_r_int=yes
19144 else
19145   echo "$as_me: failed program was:" >&5
19146 sed 's/^/| /' conftest.$ac_ext >&5
19147
19148         pgac_func_strerror_r_int=no
19149 fi
19150
19151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19152 fi
19153 { echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
19154 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6; }
19155 if test x"$pgac_func_strerror_r_int" = xyes ; then
19156
19157 cat >>confdefs.h <<\_ACEOF
19158 #define STRERROR_R_INT
19159 _ACEOF
19160
19161 fi
19162
19163
19164 CFLAGS="$_CFLAGS"
19165 LIBS="$_LIBS"
19166
19167 else
19168 # do not use values from template file
19169 PTHREAD_CFLAGS=
19170 PTHREAD_LIBS=
19171 fi
19172
19173
19174
19175
19176
19177 # We can test for libldap_r only after we know PTHREAD_LIBS
19178 if test "$with_ldap" = yes ; then
19179   _LIBS="$LIBS"
19180   if test "$PORTNAME" != "win32"; then
19181
19182 { echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
19183 echo $ECHO_N "checking for ldap_bind in -lldap... $ECHO_C" >&6; }
19184 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
19185   echo $ECHO_N "(cached) $ECHO_C" >&6
19186 else
19187   ac_check_lib_save_LIBS=$LIBS
19188 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
19189 cat >conftest.$ac_ext <<_ACEOF
19190 /* confdefs.h.  */
19191 _ACEOF
19192 cat confdefs.h >>conftest.$ac_ext
19193 cat >>conftest.$ac_ext <<_ACEOF
19194 /* end confdefs.h.  */
19195
19196 /* Override any GCC internal prototype to avoid an error.
19197    Use char because int might match the return type of a GCC
19198    builtin and then its argument prototype would still apply.  */
19199 #ifdef __cplusplus
19200 extern "C"
19201 #endif
19202 char ldap_bind ();
19203 int
19204 main ()
19205 {
19206 return ldap_bind ();
19207   ;
19208   return 0;
19209 }
19210 _ACEOF
19211 rm -f conftest.$ac_objext conftest$ac_exeext
19212 if { (ac_try="$ac_link"
19213 case "(($ac_try" in
19214   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19215   *) ac_try_echo=$ac_try;;
19216 esac
19217 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19218   (eval "$ac_link") 2>conftest.er1
19219   ac_status=$?
19220   grep -v '^ *+' conftest.er1 >conftest.err
19221   rm -f conftest.er1
19222   cat conftest.err >&5
19223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19224   (exit $ac_status); } && {
19225          test -z "$ac_c_werror_flag" ||
19226          test ! -s conftest.err
19227        } && test -s conftest$ac_exeext &&
19228        $as_test_x conftest$ac_exeext; then
19229   ac_cv_lib_ldap_ldap_bind=yes
19230 else
19231   echo "$as_me: failed program was:" >&5
19232 sed 's/^/| /' conftest.$ac_ext >&5
19233
19234         ac_cv_lib_ldap_ldap_bind=no
19235 fi
19236
19237 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19238       conftest$ac_exeext conftest.$ac_ext
19239 LIBS=$ac_check_lib_save_LIBS
19240 fi
19241 { echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
19242 echo "${ECHO_T}$ac_cv_lib_ldap_ldap_bind" >&6; }
19243 if test $ac_cv_lib_ldap_ldap_bind = yes; then
19244   cat >>confdefs.h <<_ACEOF
19245 #define HAVE_LIBLDAP 1
19246 _ACEOF
19247
19248   LIBS="-lldap $LIBS"
19249
19250 else
19251   { { echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
19252 echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
19253    { (exit 1); exit 1; }; }
19254 fi
19255
19256     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
19257     if test "$enable_thread_safety" = yes; then
19258       # on some platforms ldap_r fails to link without PTHREAD_LIBS
19259
19260 { echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
19261 echo $ECHO_N "checking for ldap_simple_bind in -lldap_r... $ECHO_C" >&6; }
19262 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
19263   echo $ECHO_N "(cached) $ECHO_C" >&6
19264 else
19265   ac_check_lib_save_LIBS=$LIBS
19266 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
19267 cat >conftest.$ac_ext <<_ACEOF
19268 /* confdefs.h.  */
19269 _ACEOF
19270 cat confdefs.h >>conftest.$ac_ext
19271 cat >>conftest.$ac_ext <<_ACEOF
19272 /* end confdefs.h.  */
19273
19274 /* Override any GCC internal prototype to avoid an error.
19275    Use char because int might match the return type of a GCC
19276    builtin and then its argument prototype would still apply.  */
19277 #ifdef __cplusplus
19278 extern "C"
19279 #endif
19280 char ldap_simple_bind ();
19281 int
19282 main ()
19283 {
19284 return ldap_simple_bind ();
19285   ;
19286   return 0;
19287 }
19288 _ACEOF
19289 rm -f conftest.$ac_objext conftest$ac_exeext
19290 if { (ac_try="$ac_link"
19291 case "(($ac_try" in
19292   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19293   *) ac_try_echo=$ac_try;;
19294 esac
19295 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19296   (eval "$ac_link") 2>conftest.er1
19297   ac_status=$?
19298   grep -v '^ *+' conftest.er1 >conftest.err
19299   rm -f conftest.er1
19300   cat conftest.err >&5
19301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19302   (exit $ac_status); } && {
19303          test -z "$ac_c_werror_flag" ||
19304          test ! -s conftest.err
19305        } && test -s conftest$ac_exeext &&
19306        $as_test_x conftest$ac_exeext; then
19307   ac_cv_lib_ldap_r_ldap_simple_bind=yes
19308 else
19309   echo "$as_me: failed program was:" >&5
19310 sed 's/^/| /' conftest.$ac_ext >&5
19311
19312         ac_cv_lib_ldap_r_ldap_simple_bind=no
19313 fi
19314
19315 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19316       conftest$ac_exeext conftest.$ac_ext
19317 LIBS=$ac_check_lib_save_LIBS
19318 fi
19319 { echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
19320 echo "${ECHO_T}$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
19321 if test $ac_cv_lib_ldap_r_ldap_simple_bind = yes; then
19322   cat >>confdefs.h <<_ACEOF
19323 #define HAVE_LIBLDAP_R 1
19324 _ACEOF
19325
19326   LIBS="-lldap_r $LIBS"
19327
19328 else
19329   { { echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
19330 echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
19331    { (exit 1); exit 1; }; }
19332 fi
19333
19334       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
19335     else
19336       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
19337     fi
19338   else
19339
19340 { echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
19341 echo $ECHO_N "checking for ldap_bind in -lwldap32... $ECHO_C" >&6; }
19342 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
19343   echo $ECHO_N "(cached) $ECHO_C" >&6
19344 else
19345   ac_check_lib_save_LIBS=$LIBS
19346 LIBS="-lwldap32  $LIBS"
19347 cat >conftest.$ac_ext <<_ACEOF
19348 /* confdefs.h.  */
19349 _ACEOF
19350 cat confdefs.h >>conftest.$ac_ext
19351 cat >>conftest.$ac_ext <<_ACEOF
19352 /* end confdefs.h.  */
19353
19354 /* Override any GCC internal prototype to avoid an error.
19355    Use char because int might match the return type of a GCC
19356    builtin and then its argument prototype would still apply.  */
19357 #ifdef __cplusplus
19358 extern "C"
19359 #endif
19360 char ldap_bind ();
19361 int
19362 main ()
19363 {
19364 return ldap_bind ();
19365   ;
19366   return 0;
19367 }
19368 _ACEOF
19369 rm -f conftest.$ac_objext conftest$ac_exeext
19370 if { (ac_try="$ac_link"
19371 case "(($ac_try" in
19372   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19373   *) ac_try_echo=$ac_try;;
19374 esac
19375 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19376   (eval "$ac_link") 2>conftest.er1
19377   ac_status=$?
19378   grep -v '^ *+' conftest.er1 >conftest.err
19379   rm -f conftest.er1
19380   cat conftest.err >&5
19381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19382   (exit $ac_status); } && {
19383          test -z "$ac_c_werror_flag" ||
19384          test ! -s conftest.err
19385        } && test -s conftest$ac_exeext &&
19386        $as_test_x conftest$ac_exeext; then
19387   ac_cv_lib_wldap32_ldap_bind=yes
19388 else
19389   echo "$as_me: failed program was:" >&5
19390 sed 's/^/| /' conftest.$ac_ext >&5
19391
19392         ac_cv_lib_wldap32_ldap_bind=no
19393 fi
19394
19395 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19396       conftest$ac_exeext conftest.$ac_ext
19397 LIBS=$ac_check_lib_save_LIBS
19398 fi
19399 { echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
19400 echo "${ECHO_T}$ac_cv_lib_wldap32_ldap_bind" >&6; }
19401 if test $ac_cv_lib_wldap32_ldap_bind = yes; then
19402   cat >>confdefs.h <<_ACEOF
19403 #define HAVE_LIBWLDAP32 1
19404 _ACEOF
19405
19406   LIBS="-lwldap32 $LIBS"
19407
19408 else
19409   { { echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
19410 echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
19411    { (exit 1); exit 1; }; }
19412 fi
19413
19414     LDAP_LIBS_FE="-lwldap32"
19415     LDAP_LIBS_BE="-lwldap32"
19416   fi
19417   LIBS="$_LIBS"
19418 fi
19419
19420
19421
19422
19423 # This test makes sure that run tests work at all.  Sometimes a shared
19424 # library is found by the linker, but the runtime linker can't find it.
19425 # This check should come after all modifications of compiler or linker
19426 # variables, and before any other run tests.
19427 { echo "$as_me:$LINENO: checking test program" >&5
19428 echo $ECHO_N "checking test program... $ECHO_C" >&6; }
19429 if test "$cross_compiling" = yes; then
19430   { echo "$as_me:$LINENO: result: cross-compiling" >&5
19431 echo "${ECHO_T}cross-compiling" >&6; }
19432 else
19433   cat >conftest.$ac_ext <<_ACEOF
19434 /* confdefs.h.  */
19435 _ACEOF
19436 cat confdefs.h >>conftest.$ac_ext
19437 cat >>conftest.$ac_ext <<_ACEOF
19438 /* end confdefs.h.  */
19439 int main() { return 0; }
19440 _ACEOF
19441 rm -f conftest$ac_exeext
19442 if { (ac_try="$ac_link"
19443 case "(($ac_try" in
19444   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19445   *) ac_try_echo=$ac_try;;
19446 esac
19447 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19448   (eval "$ac_link") 2>&5
19449   ac_status=$?
19450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19451   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19452   { (case "(($ac_try" in
19453   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19454   *) ac_try_echo=$ac_try;;
19455 esac
19456 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19457   (eval "$ac_try") 2>&5
19458   ac_status=$?
19459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19460   (exit $ac_status); }; }; then
19461   { echo "$as_me:$LINENO: result: ok" >&5
19462 echo "${ECHO_T}ok" >&6; }
19463 else
19464   echo "$as_me: program exited with status $ac_status" >&5
19465 echo "$as_me: failed program was:" >&5
19466 sed 's/^/| /' conftest.$ac_ext >&5
19467
19468 ( exit $ac_status )
19469 { echo "$as_me:$LINENO: result: failed" >&5
19470 echo "${ECHO_T}failed" >&6; }
19471 { { echo "$as_me:$LINENO: error:
19472 Could not execute a simple test program.  This may be a problem
19473 related to locating shared libraries.  Check the file 'config.log'
19474 for the exact reason." >&5
19475 echo "$as_me: error:
19476 Could not execute a simple test program.  This may be a problem
19477 related to locating shared libraries.  Check the file 'config.log'
19478 for the exact reason." >&2;}
19479    { (exit 1); exit 1; }; }
19480 fi
19481 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19482 fi
19483
19484
19485
19486 # --------------------
19487 # Run tests below here
19488 # --------------------
19489
19490 # Force use of our snprintf if system's doesn't do arg control
19491 # See comment above at snprintf test for details.
19492 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
19493   { echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
19494 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6; }
19495 if test "${pgac_cv_printf_arg_control+set}" = set; then
19496   echo $ECHO_N "(cached) $ECHO_C" >&6
19497 else
19498   if test "$cross_compiling" = yes; then
19499   pgac_cv_printf_arg_control=cross
19500 else
19501   cat >conftest.$ac_ext <<_ACEOF
19502 /* confdefs.h.  */
19503 _ACEOF
19504 cat confdefs.h >>conftest.$ac_ext
19505 cat >>conftest.$ac_ext <<_ACEOF
19506 /* end confdefs.h.  */
19507 #include <stdio.h>
19508 #include <string.h>
19509
19510 int main()
19511 {
19512   char buf[100];
19513
19514   /* can it swap arguments? */
19515   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
19516   if (strcmp(buf, "4 3") != 0)
19517     return 1;
19518   return 0;
19519 }
19520 _ACEOF
19521 rm -f conftest$ac_exeext
19522 if { (ac_try="$ac_link"
19523 case "(($ac_try" in
19524   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19525   *) ac_try_echo=$ac_try;;
19526 esac
19527 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19528   (eval "$ac_link") 2>&5
19529   ac_status=$?
19530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19531   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19532   { (case "(($ac_try" in
19533   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19534   *) ac_try_echo=$ac_try;;
19535 esac
19536 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19537   (eval "$ac_try") 2>&5
19538   ac_status=$?
19539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19540   (exit $ac_status); }; }; then
19541   pgac_cv_printf_arg_control=yes
19542 else
19543   echo "$as_me: program exited with status $ac_status" >&5
19544 echo "$as_me: failed program was:" >&5
19545 sed 's/^/| /' conftest.$ac_ext >&5
19546
19547 ( exit $ac_status )
19548 pgac_cv_printf_arg_control=no
19549 fi
19550 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19551 fi
19552
19553
19554
19555 fi
19556 { echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
19557 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6; }
19558
19559   if test $pgac_cv_printf_arg_control != yes ; then
19560     pgac_need_repl_snprintf=yes
19561   fi
19562 fi
19563
19564
19565
19566 { echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
19567 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6; }
19568 if test "${pgac_cv_type_long_int_64+set}" = set; then
19569   echo $ECHO_N "(cached) $ECHO_C" >&6
19570 else
19571   if test "$cross_compiling" = yes; then
19572   # If cross-compiling, check the size reported by the compiler and
19573 # trust that the arithmetic works.
19574 cat >conftest.$ac_ext <<_ACEOF
19575 /* confdefs.h.  */
19576 _ACEOF
19577 cat confdefs.h >>conftest.$ac_ext
19578 cat >>conftest.$ac_ext <<_ACEOF
19579 /* end confdefs.h.  */
19580
19581 int
19582 main ()
19583 {
19584 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
19585 test_array [0] = 0
19586
19587   ;
19588   return 0;
19589 }
19590 _ACEOF
19591 rm -f conftest.$ac_objext
19592 if { (ac_try="$ac_compile"
19593 case "(($ac_try" in
19594   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19595   *) ac_try_echo=$ac_try;;
19596 esac
19597 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19598   (eval "$ac_compile") 2>conftest.er1
19599   ac_status=$?
19600   grep -v '^ *+' conftest.er1 >conftest.err
19601   rm -f conftest.er1
19602   cat conftest.err >&5
19603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19604   (exit $ac_status); } && {
19605          test -z "$ac_c_werror_flag" ||
19606          test ! -s conftest.err
19607        } && test -s conftest.$ac_objext; then
19608   pgac_cv_type_long_int_64=yes
19609 else
19610   echo "$as_me: failed program was:" >&5
19611 sed 's/^/| /' conftest.$ac_ext >&5
19612
19613         pgac_cv_type_long_int_64=no
19614 fi
19615
19616 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19617 else
19618   cat >conftest.$ac_ext <<_ACEOF
19619 /* confdefs.h.  */
19620 _ACEOF
19621 cat confdefs.h >>conftest.$ac_ext
19622 cat >>conftest.$ac_ext <<_ACEOF
19623 /* end confdefs.h.  */
19624 typedef long int ac_int64;
19625
19626 /*
19627  * These are globals to discourage the compiler from folding all the
19628  * arithmetic tests down to compile-time constants.
19629  */
19630 ac_int64 a = 20000001;
19631 ac_int64 b = 40000005;
19632
19633 int does_int64_work()
19634 {
19635   ac_int64 c,d;
19636
19637   if (sizeof(ac_int64) != 8)
19638     return 0;                   /* definitely not the right size */
19639
19640   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
19641   c = a * b;
19642   d = (c + b) / b;
19643   if (d != a+1)
19644     return 0;
19645   return 1;
19646 }
19647 main() {
19648   exit(! does_int64_work());
19649 }
19650 _ACEOF
19651 rm -f conftest$ac_exeext
19652 if { (ac_try="$ac_link"
19653 case "(($ac_try" in
19654   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19655   *) ac_try_echo=$ac_try;;
19656 esac
19657 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19658   (eval "$ac_link") 2>&5
19659   ac_status=$?
19660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19661   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19662   { (case "(($ac_try" in
19663   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19664   *) ac_try_echo=$ac_try;;
19665 esac
19666 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19667   (eval "$ac_try") 2>&5
19668   ac_status=$?
19669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19670   (exit $ac_status); }; }; then
19671   pgac_cv_type_long_int_64=yes
19672 else
19673   echo "$as_me: program exited with status $ac_status" >&5
19674 echo "$as_me: failed program was:" >&5
19675 sed 's/^/| /' conftest.$ac_ext >&5
19676
19677 ( exit $ac_status )
19678 pgac_cv_type_long_int_64=no
19679 fi
19680 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19681 fi
19682
19683
19684 fi
19685 { echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
19686 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6; }
19687
19688 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
19689 if test x"$pgac_cv_type_long_int_64" = xyes ; then
19690
19691 cat >>confdefs.h <<\_ACEOF
19692 #define HAVE_LONG_INT_64
19693 _ACEOF
19694
19695 fi
19696
19697
19698 if test x"$HAVE_LONG_INT_64" = x"no" ; then
19699   { echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
19700 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6; }
19701 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
19702   echo $ECHO_N "(cached) $ECHO_C" >&6
19703 else
19704   if test "$cross_compiling" = yes; then
19705   # If cross-compiling, check the size reported by the compiler and
19706 # trust that the arithmetic works.
19707 cat >conftest.$ac_ext <<_ACEOF
19708 /* confdefs.h.  */
19709 _ACEOF
19710 cat confdefs.h >>conftest.$ac_ext
19711 cat >>conftest.$ac_ext <<_ACEOF
19712 /* end confdefs.h.  */
19713
19714 int
19715 main ()
19716 {
19717 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
19718 test_array [0] = 0
19719
19720   ;
19721   return 0;
19722 }
19723 _ACEOF
19724 rm -f conftest.$ac_objext
19725 if { (ac_try="$ac_compile"
19726 case "(($ac_try" in
19727   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19728   *) ac_try_echo=$ac_try;;
19729 esac
19730 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19731   (eval "$ac_compile") 2>conftest.er1
19732   ac_status=$?
19733   grep -v '^ *+' conftest.er1 >conftest.err
19734   rm -f conftest.er1
19735   cat conftest.err >&5
19736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19737   (exit $ac_status); } && {
19738          test -z "$ac_c_werror_flag" ||
19739          test ! -s conftest.err
19740        } && test -s conftest.$ac_objext; then
19741   pgac_cv_type_long_long_int_64=yes
19742 else
19743   echo "$as_me: failed program was:" >&5
19744 sed 's/^/| /' conftest.$ac_ext >&5
19745
19746         pgac_cv_type_long_long_int_64=no
19747 fi
19748
19749 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19750 else
19751   cat >conftest.$ac_ext <<_ACEOF
19752 /* confdefs.h.  */
19753 _ACEOF
19754 cat confdefs.h >>conftest.$ac_ext
19755 cat >>conftest.$ac_ext <<_ACEOF
19756 /* end confdefs.h.  */
19757 typedef long long int ac_int64;
19758
19759 /*
19760  * These are globals to discourage the compiler from folding all the
19761  * arithmetic tests down to compile-time constants.
19762  */
19763 ac_int64 a = 20000001;
19764 ac_int64 b = 40000005;
19765
19766 int does_int64_work()
19767 {
19768   ac_int64 c,d;
19769
19770   if (sizeof(ac_int64) != 8)
19771     return 0;                   /* definitely not the right size */
19772
19773   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
19774   c = a * b;
19775   d = (c + b) / b;
19776   if (d != a+1)
19777     return 0;
19778   return 1;
19779 }
19780 main() {
19781   exit(! does_int64_work());
19782 }
19783 _ACEOF
19784 rm -f conftest$ac_exeext
19785 if { (ac_try="$ac_link"
19786 case "(($ac_try" in
19787   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19788   *) ac_try_echo=$ac_try;;
19789 esac
19790 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19791   (eval "$ac_link") 2>&5
19792   ac_status=$?
19793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19794   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19795   { (case "(($ac_try" in
19796   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19797   *) ac_try_echo=$ac_try;;
19798 esac
19799 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19800   (eval "$ac_try") 2>&5
19801   ac_status=$?
19802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19803   (exit $ac_status); }; }; then
19804   pgac_cv_type_long_long_int_64=yes
19805 else
19806   echo "$as_me: program exited with status $ac_status" >&5
19807 echo "$as_me: failed program was:" >&5
19808 sed 's/^/| /' conftest.$ac_ext >&5
19809
19810 ( exit $ac_status )
19811 pgac_cv_type_long_long_int_64=no
19812 fi
19813 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19814 fi
19815
19816
19817 fi
19818 { echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
19819 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6; }
19820
19821 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
19822 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
19823
19824 cat >>confdefs.h <<\_ACEOF
19825 #define HAVE_LONG_LONG_INT_64
19826 _ACEOF
19827
19828 fi
19829
19830 fi
19831
19832
19833
19834 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
19835   cat >conftest.$ac_ext <<_ACEOF
19836 /* confdefs.h.  */
19837 _ACEOF
19838 cat confdefs.h >>conftest.$ac_ext
19839 cat >>conftest.$ac_ext <<_ACEOF
19840 /* end confdefs.h.  */
19841
19842 #define INT64CONST(x)  x##LL
19843 long long int foo = INT64CONST(0x1234567890123456);
19844
19845 int
19846 main ()
19847 {
19848
19849   ;
19850   return 0;
19851 }
19852 _ACEOF
19853 rm -f conftest.$ac_objext
19854 if { (ac_try="$ac_compile"
19855 case "(($ac_try" in
19856   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19857   *) ac_try_echo=$ac_try;;
19858 esac
19859 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19860   (eval "$ac_compile") 2>conftest.er1
19861   ac_status=$?
19862   grep -v '^ *+' conftest.er1 >conftest.err
19863   rm -f conftest.er1
19864   cat conftest.err >&5
19865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19866   (exit $ac_status); } && {
19867          test -z "$ac_c_werror_flag" ||
19868          test ! -s conftest.err
19869        } && test -s conftest.$ac_objext; then
19870
19871 cat >>confdefs.h <<\_ACEOF
19872 #define HAVE_LL_CONSTANTS 1
19873 _ACEOF
19874
19875 else
19876   echo "$as_me: failed program was:" >&5
19877 sed 's/^/| /' conftest.$ac_ext >&5
19878
19879
19880 fi
19881
19882 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19883 fi
19884
19885
19886 # If we found "long int" is 64 bits, assume snprintf handles it.  If
19887 # we found we need to use "long long int", better check.  We cope with
19888 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
19889 # work, fall back to our own snprintf emulation (which we know uses %lld).
19890
19891 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
19892   if test $pgac_need_repl_snprintf = no; then
19893     { echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
19894 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6; }
19895 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
19896   echo $ECHO_N "(cached) $ECHO_C" >&6
19897 else
19898   for pgac_format in '%lld' '%qd' '%I64d'; do
19899 if test "$cross_compiling" = yes; then
19900   pgac_cv_snprintf_long_long_int_format=cross; break
19901 else
19902   cat >conftest.$ac_ext <<_ACEOF
19903 /* confdefs.h.  */
19904 _ACEOF
19905 cat confdefs.h >>conftest.$ac_ext
19906 cat >>conftest.$ac_ext <<_ACEOF
19907 /* end confdefs.h.  */
19908 #include <stdio.h>
19909 typedef long long int ac_int64;
19910 #define INT64_FORMAT "$pgac_format"
19911
19912 ac_int64 a = 20000001;
19913 ac_int64 b = 40000005;
19914
19915 int does_int64_snprintf_work()
19916 {
19917   ac_int64 c;
19918   char buf[100];
19919
19920   if (sizeof(ac_int64) != 8)
19921     return 0;                   /* doesn't look like the right size */
19922
19923   c = a * b;
19924   snprintf(buf, 100, INT64_FORMAT, c);
19925   if (strcmp(buf, "800000140000005") != 0)
19926     return 0;                   /* either multiply or snprintf is busted */
19927   return 1;
19928 }
19929 main() {
19930   exit(! does_int64_snprintf_work());
19931 }
19932 _ACEOF
19933 rm -f conftest$ac_exeext
19934 if { (ac_try="$ac_link"
19935 case "(($ac_try" in
19936   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19937   *) ac_try_echo=$ac_try;;
19938 esac
19939 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19940   (eval "$ac_link") 2>&5
19941   ac_status=$?
19942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19943   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19944   { (case "(($ac_try" in
19945   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19946   *) ac_try_echo=$ac_try;;
19947 esac
19948 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19949   (eval "$ac_try") 2>&5
19950   ac_status=$?
19951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19952   (exit $ac_status); }; }; then
19953   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
19954 else
19955   echo "$as_me: program exited with status $ac_status" >&5
19956 echo "$as_me: failed program was:" >&5
19957 sed 's/^/| /' conftest.$ac_ext >&5
19958
19959 fi
19960 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19961 fi
19962
19963
19964 done
19965 fi
19966
19967 LONG_LONG_INT_FORMAT=''
19968
19969 case $pgac_cv_snprintf_long_long_int_format in
19970   cross) { echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
19971 echo "${ECHO_T}cannot test (not on host machine)" >&6; };;
19972   ?*)    { echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
19973 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6; }
19974          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
19975   *)     { echo "$as_me:$LINENO: result: none" >&5
19976 echo "${ECHO_T}none" >&6; };;
19977 esac
19978     if test "$LONG_LONG_INT_FORMAT" = ""; then
19979       # Force usage of our own snprintf, since system snprintf is broken
19980       pgac_need_repl_snprintf=yes
19981       LONG_LONG_INT_FORMAT='%lld'
19982     fi
19983   else
19984     # Here if we previously decided we needed to use our own snprintf
19985     LONG_LONG_INT_FORMAT='%lld'
19986   fi
19987   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
19988   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
19989   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
19990 else
19991   # Here if we are not using 'long long int' at all
19992   INT64_FORMAT='"%ld"'
19993   UINT64_FORMAT='"%lu"'
19994 fi
19995
19996
19997 cat >>confdefs.h <<_ACEOF
19998 #define INT64_FORMAT $INT64_FORMAT
19999 _ACEOF
20000
20001
20002
20003 cat >>confdefs.h <<_ACEOF
20004 #define UINT64_FORMAT $UINT64_FORMAT
20005 _ACEOF
20006
20007
20008 # Now we have checked all the reasons to replace snprintf
20009 if test $pgac_need_repl_snprintf = yes; then
20010
20011 cat >>confdefs.h <<\_ACEOF
20012 #define USE_REPL_SNPRINTF 1
20013 _ACEOF
20014
20015   case " $LIBOBJS " in
20016   *" snprintf.$ac_objext "* ) ;;
20017   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
20018  ;;
20019 esac
20020
20021 fi
20022
20023 # Need a #define for the size of Datum (unsigned long)
20024 { echo "$as_me:$LINENO: checking for unsigned long" >&5
20025 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6; }
20026 if test "${ac_cv_type_unsigned_long+set}" = set; then
20027   echo $ECHO_N "(cached) $ECHO_C" >&6
20028 else
20029   cat >conftest.$ac_ext <<_ACEOF
20030 /* confdefs.h.  */
20031 _ACEOF
20032 cat confdefs.h >>conftest.$ac_ext
20033 cat >>conftest.$ac_ext <<_ACEOF
20034 /* end confdefs.h.  */
20035 $ac_includes_default
20036 typedef unsigned long ac__type_new_;
20037 int
20038 main ()
20039 {
20040 if ((ac__type_new_ *) 0)
20041   return 0;
20042 if (sizeof (ac__type_new_))
20043   return 0;
20044   ;
20045   return 0;
20046 }
20047 _ACEOF
20048 rm -f conftest.$ac_objext
20049 if { (ac_try="$ac_compile"
20050 case "(($ac_try" in
20051   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20052   *) ac_try_echo=$ac_try;;
20053 esac
20054 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20055   (eval "$ac_compile") 2>conftest.er1
20056   ac_status=$?
20057   grep -v '^ *+' conftest.er1 >conftest.err
20058   rm -f conftest.er1
20059   cat conftest.err >&5
20060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20061   (exit $ac_status); } && {
20062          test -z "$ac_c_werror_flag" ||
20063          test ! -s conftest.err
20064        } && test -s conftest.$ac_objext; then
20065   ac_cv_type_unsigned_long=yes
20066 else
20067   echo "$as_me: failed program was:" >&5
20068 sed 's/^/| /' conftest.$ac_ext >&5
20069
20070         ac_cv_type_unsigned_long=no
20071 fi
20072
20073 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20074 fi
20075 { echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
20076 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6; }
20077
20078 # The cast to long int works around a bug in the HP C Compiler
20079 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20080 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20081 # This bug is HP SR number 8606223364.
20082 { echo "$as_me:$LINENO: checking size of unsigned long" >&5
20083 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6; }
20084 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
20085   echo $ECHO_N "(cached) $ECHO_C" >&6
20086 else
20087   if test "$cross_compiling" = yes; then
20088   # Depending upon the size, compute the lo and hi bounds.
20089 cat >conftest.$ac_ext <<_ACEOF
20090 /* confdefs.h.  */
20091 _ACEOF
20092 cat confdefs.h >>conftest.$ac_ext
20093 cat >>conftest.$ac_ext <<_ACEOF
20094 /* end confdefs.h.  */
20095 $ac_includes_default
20096    typedef unsigned long ac__type_sizeof_;
20097 int
20098 main ()
20099 {
20100 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
20101 test_array [0] = 0
20102
20103   ;
20104   return 0;
20105 }
20106 _ACEOF
20107 rm -f conftest.$ac_objext
20108 if { (ac_try="$ac_compile"
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_compile") 2>conftest.er1
20115   ac_status=$?
20116   grep -v '^ *+' conftest.er1 >conftest.err
20117   rm -f conftest.er1
20118   cat conftest.err >&5
20119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20120   (exit $ac_status); } && {
20121          test -z "$ac_c_werror_flag" ||
20122          test ! -s conftest.err
20123        } && test -s conftest.$ac_objext; then
20124   ac_lo=0 ac_mid=0
20125   while :; do
20126     cat >conftest.$ac_ext <<_ACEOF
20127 /* confdefs.h.  */
20128 _ACEOF
20129 cat confdefs.h >>conftest.$ac_ext
20130 cat >>conftest.$ac_ext <<_ACEOF
20131 /* end confdefs.h.  */
20132 $ac_includes_default
20133    typedef unsigned long ac__type_sizeof_;
20134 int
20135 main ()
20136 {
20137 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20138 test_array [0] = 0
20139
20140   ;
20141   return 0;
20142 }
20143 _ACEOF
20144 rm -f conftest.$ac_objext
20145 if { (ac_try="$ac_compile"
20146 case "(($ac_try" in
20147   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20148   *) ac_try_echo=$ac_try;;
20149 esac
20150 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20151   (eval "$ac_compile") 2>conftest.er1
20152   ac_status=$?
20153   grep -v '^ *+' conftest.er1 >conftest.err
20154   rm -f conftest.er1
20155   cat conftest.err >&5
20156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20157   (exit $ac_status); } && {
20158          test -z "$ac_c_werror_flag" ||
20159          test ! -s conftest.err
20160        } && test -s conftest.$ac_objext; then
20161   ac_hi=$ac_mid; break
20162 else
20163   echo "$as_me: failed program was:" >&5
20164 sed 's/^/| /' conftest.$ac_ext >&5
20165
20166         ac_lo=`expr $ac_mid + 1`
20167                         if test $ac_lo -le $ac_mid; then
20168                           ac_lo= ac_hi=
20169                           break
20170                         fi
20171                         ac_mid=`expr 2 '*' $ac_mid + 1`
20172 fi
20173
20174 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20175   done
20176 else
20177   echo "$as_me: failed program was:" >&5
20178 sed 's/^/| /' conftest.$ac_ext >&5
20179
20180         cat >conftest.$ac_ext <<_ACEOF
20181 /* confdefs.h.  */
20182 _ACEOF
20183 cat confdefs.h >>conftest.$ac_ext
20184 cat >>conftest.$ac_ext <<_ACEOF
20185 /* end confdefs.h.  */
20186 $ac_includes_default
20187    typedef unsigned long ac__type_sizeof_;
20188 int
20189 main ()
20190 {
20191 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
20192 test_array [0] = 0
20193
20194   ;
20195   return 0;
20196 }
20197 _ACEOF
20198 rm -f conftest.$ac_objext
20199 if { (ac_try="$ac_compile"
20200 case "(($ac_try" in
20201   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20202   *) ac_try_echo=$ac_try;;
20203 esac
20204 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20205   (eval "$ac_compile") 2>conftest.er1
20206   ac_status=$?
20207   grep -v '^ *+' conftest.er1 >conftest.err
20208   rm -f conftest.er1
20209   cat conftest.err >&5
20210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20211   (exit $ac_status); } && {
20212          test -z "$ac_c_werror_flag" ||
20213          test ! -s conftest.err
20214        } && test -s conftest.$ac_objext; then
20215   ac_hi=-1 ac_mid=-1
20216   while :; do
20217     cat >conftest.$ac_ext <<_ACEOF
20218 /* confdefs.h.  */
20219 _ACEOF
20220 cat confdefs.h >>conftest.$ac_ext
20221 cat >>conftest.$ac_ext <<_ACEOF
20222 /* end confdefs.h.  */
20223 $ac_includes_default
20224    typedef unsigned long ac__type_sizeof_;
20225 int
20226 main ()
20227 {
20228 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
20229 test_array [0] = 0
20230
20231   ;
20232   return 0;
20233 }
20234 _ACEOF
20235 rm -f conftest.$ac_objext
20236 if { (ac_try="$ac_compile"
20237 case "(($ac_try" in
20238   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20239   *) ac_try_echo=$ac_try;;
20240 esac
20241 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20242   (eval "$ac_compile") 2>conftest.er1
20243   ac_status=$?
20244   grep -v '^ *+' conftest.er1 >conftest.err
20245   rm -f conftest.er1
20246   cat conftest.err >&5
20247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20248   (exit $ac_status); } && {
20249          test -z "$ac_c_werror_flag" ||
20250          test ! -s conftest.err
20251        } && test -s conftest.$ac_objext; then
20252   ac_lo=$ac_mid; break
20253 else
20254   echo "$as_me: failed program was:" >&5
20255 sed 's/^/| /' conftest.$ac_ext >&5
20256
20257         ac_hi=`expr '(' $ac_mid ')' - 1`
20258                         if test $ac_mid -le $ac_hi; then
20259                           ac_lo= ac_hi=
20260                           break
20261                         fi
20262                         ac_mid=`expr 2 '*' $ac_mid`
20263 fi
20264
20265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20266   done
20267 else
20268   echo "$as_me: failed program was:" >&5
20269 sed 's/^/| /' conftest.$ac_ext >&5
20270
20271         ac_lo= ac_hi=
20272 fi
20273
20274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20275 fi
20276
20277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20278 # Binary search between lo and hi bounds.
20279 while test "x$ac_lo" != "x$ac_hi"; do
20280   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20281   cat >conftest.$ac_ext <<_ACEOF
20282 /* confdefs.h.  */
20283 _ACEOF
20284 cat confdefs.h >>conftest.$ac_ext
20285 cat >>conftest.$ac_ext <<_ACEOF
20286 /* end confdefs.h.  */
20287 $ac_includes_default
20288    typedef unsigned long ac__type_sizeof_;
20289 int
20290 main ()
20291 {
20292 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20293 test_array [0] = 0
20294
20295   ;
20296   return 0;
20297 }
20298 _ACEOF
20299 rm -f conftest.$ac_objext
20300 if { (ac_try="$ac_compile"
20301 case "(($ac_try" in
20302   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20303   *) ac_try_echo=$ac_try;;
20304 esac
20305 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20306   (eval "$ac_compile") 2>conftest.er1
20307   ac_status=$?
20308   grep -v '^ *+' conftest.er1 >conftest.err
20309   rm -f conftest.er1
20310   cat conftest.err >&5
20311   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20312   (exit $ac_status); } && {
20313          test -z "$ac_c_werror_flag" ||
20314          test ! -s conftest.err
20315        } && test -s conftest.$ac_objext; then
20316   ac_hi=$ac_mid
20317 else
20318   echo "$as_me: failed program was:" >&5
20319 sed 's/^/| /' conftest.$ac_ext >&5
20320
20321         ac_lo=`expr '(' $ac_mid ')' + 1`
20322 fi
20323
20324 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20325 done
20326 case $ac_lo in
20327 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
20328 '') if test "$ac_cv_type_unsigned_long" = yes; then
20329      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
20330 See \`config.log' for more details." >&5
20331 echo "$as_me: error: cannot compute sizeof (unsigned long)
20332 See \`config.log' for more details." >&2;}
20333    { (exit 77); exit 77; }; }
20334    else
20335      ac_cv_sizeof_unsigned_long=0
20336    fi ;;
20337 esac
20338 else
20339   cat >conftest.$ac_ext <<_ACEOF
20340 /* confdefs.h.  */
20341 _ACEOF
20342 cat confdefs.h >>conftest.$ac_ext
20343 cat >>conftest.$ac_ext <<_ACEOF
20344 /* end confdefs.h.  */
20345 $ac_includes_default
20346    typedef unsigned long ac__type_sizeof_;
20347 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
20348 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
20349 #include <stdio.h>
20350 #include <stdlib.h>
20351 int
20352 main ()
20353 {
20354
20355   FILE *f = fopen ("conftest.val", "w");
20356   if (! f)
20357     return 1;
20358   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
20359     {
20360       long int i = longval ();
20361       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20362         return 1;
20363       fprintf (f, "%ld\n", i);
20364     }
20365   else
20366     {
20367       unsigned long int i = ulongval ();
20368       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20369         return 1;
20370       fprintf (f, "%lu\n", i);
20371     }
20372   return ferror (f) || fclose (f) != 0;
20373
20374   ;
20375   return 0;
20376 }
20377 _ACEOF
20378 rm -f conftest$ac_exeext
20379 if { (ac_try="$ac_link"
20380 case "(($ac_try" in
20381   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20382   *) ac_try_echo=$ac_try;;
20383 esac
20384 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20385   (eval "$ac_link") 2>&5
20386   ac_status=$?
20387   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20388   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20389   { (case "(($ac_try" in
20390   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20391   *) ac_try_echo=$ac_try;;
20392 esac
20393 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20394   (eval "$ac_try") 2>&5
20395   ac_status=$?
20396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20397   (exit $ac_status); }; }; then
20398   ac_cv_sizeof_unsigned_long=`cat conftest.val`
20399 else
20400   echo "$as_me: program exited with status $ac_status" >&5
20401 echo "$as_me: failed program was:" >&5
20402 sed 's/^/| /' conftest.$ac_ext >&5
20403
20404 ( exit $ac_status )
20405 if test "$ac_cv_type_unsigned_long" = yes; then
20406      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
20407 See \`config.log' for more details." >&5
20408 echo "$as_me: error: cannot compute sizeof (unsigned long)
20409 See \`config.log' for more details." >&2;}
20410    { (exit 77); exit 77; }; }
20411    else
20412      ac_cv_sizeof_unsigned_long=0
20413    fi
20414 fi
20415 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20416 fi
20417 rm -f conftest.val
20418 fi
20419 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
20420 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6; }
20421
20422
20423
20424 cat >>confdefs.h <<_ACEOF
20425 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
20426 _ACEOF
20427
20428
20429
20430 # And one for the size of size_t (enables tweaks for > 32bit address space)
20431 { echo "$as_me:$LINENO: checking for size_t" >&5
20432 echo $ECHO_N "checking for size_t... $ECHO_C" >&6; }
20433 if test "${ac_cv_type_size_t+set}" = set; then
20434   echo $ECHO_N "(cached) $ECHO_C" >&6
20435 else
20436   cat >conftest.$ac_ext <<_ACEOF
20437 /* confdefs.h.  */
20438 _ACEOF
20439 cat confdefs.h >>conftest.$ac_ext
20440 cat >>conftest.$ac_ext <<_ACEOF
20441 /* end confdefs.h.  */
20442 $ac_includes_default
20443 typedef size_t ac__type_new_;
20444 int
20445 main ()
20446 {
20447 if ((ac__type_new_ *) 0)
20448   return 0;
20449 if (sizeof (ac__type_new_))
20450   return 0;
20451   ;
20452   return 0;
20453 }
20454 _ACEOF
20455 rm -f conftest.$ac_objext
20456 if { (ac_try="$ac_compile"
20457 case "(($ac_try" in
20458   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20459   *) ac_try_echo=$ac_try;;
20460 esac
20461 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20462   (eval "$ac_compile") 2>conftest.er1
20463   ac_status=$?
20464   grep -v '^ *+' conftest.er1 >conftest.err
20465   rm -f conftest.er1
20466   cat conftest.err >&5
20467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20468   (exit $ac_status); } && {
20469          test -z "$ac_c_werror_flag" ||
20470          test ! -s conftest.err
20471        } && test -s conftest.$ac_objext; then
20472   ac_cv_type_size_t=yes
20473 else
20474   echo "$as_me: failed program was:" >&5
20475 sed 's/^/| /' conftest.$ac_ext >&5
20476
20477         ac_cv_type_size_t=no
20478 fi
20479
20480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20481 fi
20482 { echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
20483 echo "${ECHO_T}$ac_cv_type_size_t" >&6; }
20484
20485 # The cast to long int works around a bug in the HP C Compiler
20486 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20487 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
20488 # This bug is HP SR number 8606223364.
20489 { echo "$as_me:$LINENO: checking size of size_t" >&5
20490 echo $ECHO_N "checking size of size_t... $ECHO_C" >&6; }
20491 if test "${ac_cv_sizeof_size_t+set}" = set; then
20492   echo $ECHO_N "(cached) $ECHO_C" >&6
20493 else
20494   if test "$cross_compiling" = yes; then
20495   # Depending upon the size, compute the lo and hi bounds.
20496 cat >conftest.$ac_ext <<_ACEOF
20497 /* confdefs.h.  */
20498 _ACEOF
20499 cat confdefs.h >>conftest.$ac_ext
20500 cat >>conftest.$ac_ext <<_ACEOF
20501 /* end confdefs.h.  */
20502 $ac_includes_default
20503    typedef size_t ac__type_sizeof_;
20504 int
20505 main ()
20506 {
20507 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
20508 test_array [0] = 0
20509
20510   ;
20511   return 0;
20512 }
20513 _ACEOF
20514 rm -f conftest.$ac_objext
20515 if { (ac_try="$ac_compile"
20516 case "(($ac_try" in
20517   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20518   *) ac_try_echo=$ac_try;;
20519 esac
20520 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20521   (eval "$ac_compile") 2>conftest.er1
20522   ac_status=$?
20523   grep -v '^ *+' conftest.er1 >conftest.err
20524   rm -f conftest.er1
20525   cat conftest.err >&5
20526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20527   (exit $ac_status); } && {
20528          test -z "$ac_c_werror_flag" ||
20529          test ! -s conftest.err
20530        } && test -s conftest.$ac_objext; then
20531   ac_lo=0 ac_mid=0
20532   while :; do
20533     cat >conftest.$ac_ext <<_ACEOF
20534 /* confdefs.h.  */
20535 _ACEOF
20536 cat confdefs.h >>conftest.$ac_ext
20537 cat >>conftest.$ac_ext <<_ACEOF
20538 /* end confdefs.h.  */
20539 $ac_includes_default
20540    typedef size_t ac__type_sizeof_;
20541 int
20542 main ()
20543 {
20544 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20545 test_array [0] = 0
20546
20547   ;
20548   return 0;
20549 }
20550 _ACEOF
20551 rm -f conftest.$ac_objext
20552 if { (ac_try="$ac_compile"
20553 case "(($ac_try" in
20554   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20555   *) ac_try_echo=$ac_try;;
20556 esac
20557 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20558   (eval "$ac_compile") 2>conftest.er1
20559   ac_status=$?
20560   grep -v '^ *+' conftest.er1 >conftest.err
20561   rm -f conftest.er1
20562   cat conftest.err >&5
20563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20564   (exit $ac_status); } && {
20565          test -z "$ac_c_werror_flag" ||
20566          test ! -s conftest.err
20567        } && test -s conftest.$ac_objext; then
20568   ac_hi=$ac_mid; break
20569 else
20570   echo "$as_me: failed program was:" >&5
20571 sed 's/^/| /' conftest.$ac_ext >&5
20572
20573         ac_lo=`expr $ac_mid + 1`
20574                         if test $ac_lo -le $ac_mid; then
20575                           ac_lo= ac_hi=
20576                           break
20577                         fi
20578                         ac_mid=`expr 2 '*' $ac_mid + 1`
20579 fi
20580
20581 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20582   done
20583 else
20584   echo "$as_me: failed program was:" >&5
20585 sed 's/^/| /' conftest.$ac_ext >&5
20586
20587         cat >conftest.$ac_ext <<_ACEOF
20588 /* confdefs.h.  */
20589 _ACEOF
20590 cat confdefs.h >>conftest.$ac_ext
20591 cat >>conftest.$ac_ext <<_ACEOF
20592 /* end confdefs.h.  */
20593 $ac_includes_default
20594    typedef size_t ac__type_sizeof_;
20595 int
20596 main ()
20597 {
20598 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
20599 test_array [0] = 0
20600
20601   ;
20602   return 0;
20603 }
20604 _ACEOF
20605 rm -f conftest.$ac_objext
20606 if { (ac_try="$ac_compile"
20607 case "(($ac_try" in
20608   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20609   *) ac_try_echo=$ac_try;;
20610 esac
20611 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20612   (eval "$ac_compile") 2>conftest.er1
20613   ac_status=$?
20614   grep -v '^ *+' conftest.er1 >conftest.err
20615   rm -f conftest.er1
20616   cat conftest.err >&5
20617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20618   (exit $ac_status); } && {
20619          test -z "$ac_c_werror_flag" ||
20620          test ! -s conftest.err
20621        } && test -s conftest.$ac_objext; then
20622   ac_hi=-1 ac_mid=-1
20623   while :; do
20624     cat >conftest.$ac_ext <<_ACEOF
20625 /* confdefs.h.  */
20626 _ACEOF
20627 cat confdefs.h >>conftest.$ac_ext
20628 cat >>conftest.$ac_ext <<_ACEOF
20629 /* end confdefs.h.  */
20630 $ac_includes_default
20631    typedef size_t ac__type_sizeof_;
20632 int
20633 main ()
20634 {
20635 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
20636 test_array [0] = 0
20637
20638   ;
20639   return 0;
20640 }
20641 _ACEOF
20642 rm -f conftest.$ac_objext
20643 if { (ac_try="$ac_compile"
20644 case "(($ac_try" in
20645   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20646   *) ac_try_echo=$ac_try;;
20647 esac
20648 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20649   (eval "$ac_compile") 2>conftest.er1
20650   ac_status=$?
20651   grep -v '^ *+' conftest.er1 >conftest.err
20652   rm -f conftest.er1
20653   cat conftest.err >&5
20654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20655   (exit $ac_status); } && {
20656          test -z "$ac_c_werror_flag" ||
20657          test ! -s conftest.err
20658        } && test -s conftest.$ac_objext; then
20659   ac_lo=$ac_mid; break
20660 else
20661   echo "$as_me: failed program was:" >&5
20662 sed 's/^/| /' conftest.$ac_ext >&5
20663
20664         ac_hi=`expr '(' $ac_mid ')' - 1`
20665                         if test $ac_mid -le $ac_hi; then
20666                           ac_lo= ac_hi=
20667                           break
20668                         fi
20669                         ac_mid=`expr 2 '*' $ac_mid`
20670 fi
20671
20672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20673   done
20674 else
20675   echo "$as_me: failed program was:" >&5
20676 sed 's/^/| /' conftest.$ac_ext >&5
20677
20678         ac_lo= ac_hi=
20679 fi
20680
20681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20682 fi
20683
20684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20685 # Binary search between lo and hi bounds.
20686 while test "x$ac_lo" != "x$ac_hi"; do
20687   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20688   cat >conftest.$ac_ext <<_ACEOF
20689 /* confdefs.h.  */
20690 _ACEOF
20691 cat confdefs.h >>conftest.$ac_ext
20692 cat >>conftest.$ac_ext <<_ACEOF
20693 /* end confdefs.h.  */
20694 $ac_includes_default
20695    typedef size_t ac__type_sizeof_;
20696 int
20697 main ()
20698 {
20699 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
20700 test_array [0] = 0
20701
20702   ;
20703   return 0;
20704 }
20705 _ACEOF
20706 rm -f conftest.$ac_objext
20707 if { (ac_try="$ac_compile"
20708 case "(($ac_try" in
20709   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20710   *) ac_try_echo=$ac_try;;
20711 esac
20712 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20713   (eval "$ac_compile") 2>conftest.er1
20714   ac_status=$?
20715   grep -v '^ *+' conftest.er1 >conftest.err
20716   rm -f conftest.er1
20717   cat conftest.err >&5
20718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20719   (exit $ac_status); } && {
20720          test -z "$ac_c_werror_flag" ||
20721          test ! -s conftest.err
20722        } && test -s conftest.$ac_objext; then
20723   ac_hi=$ac_mid
20724 else
20725   echo "$as_me: failed program was:" >&5
20726 sed 's/^/| /' conftest.$ac_ext >&5
20727
20728         ac_lo=`expr '(' $ac_mid ')' + 1`
20729 fi
20730
20731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20732 done
20733 case $ac_lo in
20734 ?*) ac_cv_sizeof_size_t=$ac_lo;;
20735 '') if test "$ac_cv_type_size_t" = yes; then
20736      { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
20737 See \`config.log' for more details." >&5
20738 echo "$as_me: error: cannot compute sizeof (size_t)
20739 See \`config.log' for more details." >&2;}
20740    { (exit 77); exit 77; }; }
20741    else
20742      ac_cv_sizeof_size_t=0
20743    fi ;;
20744 esac
20745 else
20746   cat >conftest.$ac_ext <<_ACEOF
20747 /* confdefs.h.  */
20748 _ACEOF
20749 cat confdefs.h >>conftest.$ac_ext
20750 cat >>conftest.$ac_ext <<_ACEOF
20751 /* end confdefs.h.  */
20752 $ac_includes_default
20753    typedef size_t ac__type_sizeof_;
20754 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
20755 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
20756 #include <stdio.h>
20757 #include <stdlib.h>
20758 int
20759 main ()
20760 {
20761
20762   FILE *f = fopen ("conftest.val", "w");
20763   if (! f)
20764     return 1;
20765   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
20766     {
20767       long int i = longval ();
20768       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20769         return 1;
20770       fprintf (f, "%ld\n", i);
20771     }
20772   else
20773     {
20774       unsigned long int i = ulongval ();
20775       if (i != ((long int) (sizeof (ac__type_sizeof_))))
20776         return 1;
20777       fprintf (f, "%lu\n", i);
20778     }
20779   return ferror (f) || fclose (f) != 0;
20780
20781   ;
20782   return 0;
20783 }
20784 _ACEOF
20785 rm -f conftest$ac_exeext
20786 if { (ac_try="$ac_link"
20787 case "(($ac_try" in
20788   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20789   *) ac_try_echo=$ac_try;;
20790 esac
20791 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20792   (eval "$ac_link") 2>&5
20793   ac_status=$?
20794   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20795   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20796   { (case "(($ac_try" in
20797   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20798   *) ac_try_echo=$ac_try;;
20799 esac
20800 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20801   (eval "$ac_try") 2>&5
20802   ac_status=$?
20803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20804   (exit $ac_status); }; }; then
20805   ac_cv_sizeof_size_t=`cat conftest.val`
20806 else
20807   echo "$as_me: program exited with status $ac_status" >&5
20808 echo "$as_me: failed program was:" >&5
20809 sed 's/^/| /' conftest.$ac_ext >&5
20810
20811 ( exit $ac_status )
20812 if test "$ac_cv_type_size_t" = yes; then
20813      { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
20814 See \`config.log' for more details." >&5
20815 echo "$as_me: error: cannot compute sizeof (size_t)
20816 See \`config.log' for more details." >&2;}
20817    { (exit 77); exit 77; }; }
20818    else
20819      ac_cv_sizeof_size_t=0
20820    fi
20821 fi
20822 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20823 fi
20824 rm -f conftest.val
20825 fi
20826 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
20827 echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6; }
20828
20829
20830
20831 cat >>confdefs.h <<_ACEOF
20832 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
20833 _ACEOF
20834
20835
20836
20837 # Determine memory alignment requirements for the basic C data types.
20838
20839 { echo "$as_me:$LINENO: checking for short" >&5
20840 echo $ECHO_N "checking for short... $ECHO_C" >&6; }
20841 if test "${ac_cv_type_short+set}" = set; then
20842   echo $ECHO_N "(cached) $ECHO_C" >&6
20843 else
20844   cat >conftest.$ac_ext <<_ACEOF
20845 /* confdefs.h.  */
20846 _ACEOF
20847 cat confdefs.h >>conftest.$ac_ext
20848 cat >>conftest.$ac_ext <<_ACEOF
20849 /* end confdefs.h.  */
20850 $ac_includes_default
20851 typedef short ac__type_new_;
20852 int
20853 main ()
20854 {
20855 if ((ac__type_new_ *) 0)
20856   return 0;
20857 if (sizeof (ac__type_new_))
20858   return 0;
20859   ;
20860   return 0;
20861 }
20862 _ACEOF
20863 rm -f conftest.$ac_objext
20864 if { (ac_try="$ac_compile"
20865 case "(($ac_try" in
20866   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20867   *) ac_try_echo=$ac_try;;
20868 esac
20869 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20870   (eval "$ac_compile") 2>conftest.er1
20871   ac_status=$?
20872   grep -v '^ *+' conftest.er1 >conftest.err
20873   rm -f conftest.er1
20874   cat conftest.err >&5
20875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20876   (exit $ac_status); } && {
20877          test -z "$ac_c_werror_flag" ||
20878          test ! -s conftest.err
20879        } && test -s conftest.$ac_objext; then
20880   ac_cv_type_short=yes
20881 else
20882   echo "$as_me: failed program was:" >&5
20883 sed 's/^/| /' conftest.$ac_ext >&5
20884
20885         ac_cv_type_short=no
20886 fi
20887
20888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20889 fi
20890 { echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
20891 echo "${ECHO_T}$ac_cv_type_short" >&6; }
20892
20893 # The cast to long int works around a bug in the HP C Compiler,
20894 # see AC_CHECK_SIZEOF for more information.
20895 { echo "$as_me:$LINENO: checking alignment of short" >&5
20896 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6; }
20897 if test "${ac_cv_alignof_short+set}" = set; then
20898   echo $ECHO_N "(cached) $ECHO_C" >&6
20899 else
20900   if test "$cross_compiling" = yes; then
20901   # Depending upon the size, compute the lo and hi bounds.
20902 cat >conftest.$ac_ext <<_ACEOF
20903 /* confdefs.h.  */
20904 _ACEOF
20905 cat confdefs.h >>conftest.$ac_ext
20906 cat >>conftest.$ac_ext <<_ACEOF
20907 /* end confdefs.h.  */
20908 $ac_includes_default
20909 #ifndef offsetof
20910 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
20911 #endif
20912 typedef struct { char x; short y; } ac__type_alignof_;
20913 int
20914 main ()
20915 {
20916 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
20917 test_array [0] = 0
20918
20919   ;
20920   return 0;
20921 }
20922 _ACEOF
20923 rm -f conftest.$ac_objext
20924 if { (ac_try="$ac_compile"
20925 case "(($ac_try" in
20926   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20927   *) ac_try_echo=$ac_try;;
20928 esac
20929 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20930   (eval "$ac_compile") 2>conftest.er1
20931   ac_status=$?
20932   grep -v '^ *+' conftest.er1 >conftest.err
20933   rm -f conftest.er1
20934   cat conftest.err >&5
20935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20936   (exit $ac_status); } && {
20937          test -z "$ac_c_werror_flag" ||
20938          test ! -s conftest.err
20939        } && test -s conftest.$ac_objext; then
20940   ac_lo=0 ac_mid=0
20941   while :; do
20942     cat >conftest.$ac_ext <<_ACEOF
20943 /* confdefs.h.  */
20944 _ACEOF
20945 cat confdefs.h >>conftest.$ac_ext
20946 cat >>conftest.$ac_ext <<_ACEOF
20947 /* end confdefs.h.  */
20948 $ac_includes_default
20949 #ifndef offsetof
20950 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
20951 #endif
20952 typedef struct { char x; short y; } ac__type_alignof_;
20953 int
20954 main ()
20955 {
20956 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
20957 test_array [0] = 0
20958
20959   ;
20960   return 0;
20961 }
20962 _ACEOF
20963 rm -f conftest.$ac_objext
20964 if { (ac_try="$ac_compile"
20965 case "(($ac_try" in
20966   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20967   *) ac_try_echo=$ac_try;;
20968 esac
20969 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20970   (eval "$ac_compile") 2>conftest.er1
20971   ac_status=$?
20972   grep -v '^ *+' conftest.er1 >conftest.err
20973   rm -f conftest.er1
20974   cat conftest.err >&5
20975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20976   (exit $ac_status); } && {
20977          test -z "$ac_c_werror_flag" ||
20978          test ! -s conftest.err
20979        } && test -s conftest.$ac_objext; then
20980   ac_hi=$ac_mid; break
20981 else
20982   echo "$as_me: failed program was:" >&5
20983 sed 's/^/| /' conftest.$ac_ext >&5
20984
20985         ac_lo=`expr $ac_mid + 1`
20986                         if test $ac_lo -le $ac_mid; then
20987                           ac_lo= ac_hi=
20988                           break
20989                         fi
20990                         ac_mid=`expr 2 '*' $ac_mid + 1`
20991 fi
20992
20993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20994   done
20995 else
20996   echo "$as_me: failed program was:" >&5
20997 sed 's/^/| /' conftest.$ac_ext >&5
20998
20999         cat >conftest.$ac_ext <<_ACEOF
21000 /* confdefs.h.  */
21001 _ACEOF
21002 cat confdefs.h >>conftest.$ac_ext
21003 cat >>conftest.$ac_ext <<_ACEOF
21004 /* end confdefs.h.  */
21005 $ac_includes_default
21006 #ifndef offsetof
21007 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21008 #endif
21009 typedef struct { char x; short y; } ac__type_alignof_;
21010 int
21011 main ()
21012 {
21013 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
21014 test_array [0] = 0
21015
21016   ;
21017   return 0;
21018 }
21019 _ACEOF
21020 rm -f conftest.$ac_objext
21021 if { (ac_try="$ac_compile"
21022 case "(($ac_try" in
21023   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21024   *) ac_try_echo=$ac_try;;
21025 esac
21026 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21027   (eval "$ac_compile") 2>conftest.er1
21028   ac_status=$?
21029   grep -v '^ *+' conftest.er1 >conftest.err
21030   rm -f conftest.er1
21031   cat conftest.err >&5
21032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21033   (exit $ac_status); } && {
21034          test -z "$ac_c_werror_flag" ||
21035          test ! -s conftest.err
21036        } && test -s conftest.$ac_objext; then
21037   ac_hi=-1 ac_mid=-1
21038   while :; do
21039     cat >conftest.$ac_ext <<_ACEOF
21040 /* confdefs.h.  */
21041 _ACEOF
21042 cat confdefs.h >>conftest.$ac_ext
21043 cat >>conftest.$ac_ext <<_ACEOF
21044 /* end confdefs.h.  */
21045 $ac_includes_default
21046 #ifndef offsetof
21047 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21048 #endif
21049 typedef struct { char x; short y; } ac__type_alignof_;
21050 int
21051 main ()
21052 {
21053 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
21054 test_array [0] = 0
21055
21056   ;
21057   return 0;
21058 }
21059 _ACEOF
21060 rm -f conftest.$ac_objext
21061 if { (ac_try="$ac_compile"
21062 case "(($ac_try" in
21063   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21064   *) ac_try_echo=$ac_try;;
21065 esac
21066 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21067   (eval "$ac_compile") 2>conftest.er1
21068   ac_status=$?
21069   grep -v '^ *+' conftest.er1 >conftest.err
21070   rm -f conftest.er1
21071   cat conftest.err >&5
21072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21073   (exit $ac_status); } && {
21074          test -z "$ac_c_werror_flag" ||
21075          test ! -s conftest.err
21076        } && test -s conftest.$ac_objext; then
21077   ac_lo=$ac_mid; break
21078 else
21079   echo "$as_me: failed program was:" >&5
21080 sed 's/^/| /' conftest.$ac_ext >&5
21081
21082         ac_hi=`expr '(' $ac_mid ')' - 1`
21083                         if test $ac_mid -le $ac_hi; then
21084                           ac_lo= ac_hi=
21085                           break
21086                         fi
21087                         ac_mid=`expr 2 '*' $ac_mid`
21088 fi
21089
21090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21091   done
21092 else
21093   echo "$as_me: failed program was:" >&5
21094 sed 's/^/| /' conftest.$ac_ext >&5
21095
21096         ac_lo= ac_hi=
21097 fi
21098
21099 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21100 fi
21101
21102 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21103 # Binary search between lo and hi bounds.
21104 while test "x$ac_lo" != "x$ac_hi"; do
21105   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
21106   cat >conftest.$ac_ext <<_ACEOF
21107 /* confdefs.h.  */
21108 _ACEOF
21109 cat confdefs.h >>conftest.$ac_ext
21110 cat >>conftest.$ac_ext <<_ACEOF
21111 /* end confdefs.h.  */
21112 $ac_includes_default
21113 #ifndef offsetof
21114 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21115 #endif
21116 typedef struct { char x; short y; } ac__type_alignof_;
21117 int
21118 main ()
21119 {
21120 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21121 test_array [0] = 0
21122
21123   ;
21124   return 0;
21125 }
21126 _ACEOF
21127 rm -f conftest.$ac_objext
21128 if { (ac_try="$ac_compile"
21129 case "(($ac_try" in
21130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21131   *) ac_try_echo=$ac_try;;
21132 esac
21133 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21134   (eval "$ac_compile") 2>conftest.er1
21135   ac_status=$?
21136   grep -v '^ *+' conftest.er1 >conftest.err
21137   rm -f conftest.er1
21138   cat conftest.err >&5
21139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21140   (exit $ac_status); } && {
21141          test -z "$ac_c_werror_flag" ||
21142          test ! -s conftest.err
21143        } && test -s conftest.$ac_objext; then
21144   ac_hi=$ac_mid
21145 else
21146   echo "$as_me: failed program was:" >&5
21147 sed 's/^/| /' conftest.$ac_ext >&5
21148
21149         ac_lo=`expr '(' $ac_mid ')' + 1`
21150 fi
21151
21152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21153 done
21154 case $ac_lo in
21155 ?*) ac_cv_alignof_short=$ac_lo;;
21156 '') if test "$ac_cv_type_short" = yes; then
21157      { { echo "$as_me:$LINENO: error: cannot compute alignment of short
21158 See \`config.log' for more details." >&5
21159 echo "$as_me: error: cannot compute alignment of short
21160 See \`config.log' for more details." >&2;}
21161    { (exit 77); exit 77; }; }
21162    else
21163      ac_cv_alignof_short=0
21164    fi ;;
21165 esac
21166 else
21167   cat >conftest.$ac_ext <<_ACEOF
21168 /* confdefs.h.  */
21169 _ACEOF
21170 cat confdefs.h >>conftest.$ac_ext
21171 cat >>conftest.$ac_ext <<_ACEOF
21172 /* end confdefs.h.  */
21173 $ac_includes_default
21174 #ifndef offsetof
21175 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21176 #endif
21177 typedef struct { char x; short y; } ac__type_alignof_;
21178 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
21179 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
21180 #include <stdio.h>
21181 #include <stdlib.h>
21182 int
21183 main ()
21184 {
21185
21186   FILE *f = fopen ("conftest.val", "w");
21187   if (! f)
21188     return 1;
21189   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
21190     {
21191       long int i = longval ();
21192       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21193         return 1;
21194       fprintf (f, "%ld\n", i);
21195     }
21196   else
21197     {
21198       unsigned long int i = ulongval ();
21199       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21200         return 1;
21201       fprintf (f, "%lu\n", i);
21202     }
21203   return ferror (f) || fclose (f) != 0;
21204
21205   ;
21206   return 0;
21207 }
21208 _ACEOF
21209 rm -f conftest$ac_exeext
21210 if { (ac_try="$ac_link"
21211 case "(($ac_try" in
21212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21213   *) ac_try_echo=$ac_try;;
21214 esac
21215 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21216   (eval "$ac_link") 2>&5
21217   ac_status=$?
21218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21219   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21220   { (case "(($ac_try" in
21221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21222   *) ac_try_echo=$ac_try;;
21223 esac
21224 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21225   (eval "$ac_try") 2>&5
21226   ac_status=$?
21227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21228   (exit $ac_status); }; }; then
21229   ac_cv_alignof_short=`cat conftest.val`
21230 else
21231   echo "$as_me: program exited with status $ac_status" >&5
21232 echo "$as_me: failed program was:" >&5
21233 sed 's/^/| /' conftest.$ac_ext >&5
21234
21235 ( exit $ac_status )
21236 if test "$ac_cv_type_short" = yes; then
21237      { { echo "$as_me:$LINENO: error: cannot compute alignment of short
21238 See \`config.log' for more details." >&5
21239 echo "$as_me: error: cannot compute alignment of short
21240 See \`config.log' for more details." >&2;}
21241    { (exit 77); exit 77; }; }
21242    else
21243      ac_cv_alignof_short=0
21244    fi
21245 fi
21246 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21247 fi
21248 rm -f conftest.val
21249 fi
21250 { echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
21251 echo "${ECHO_T}$ac_cv_alignof_short" >&6; }
21252
21253
21254
21255 cat >>confdefs.h <<_ACEOF
21256 #define ALIGNOF_SHORT $ac_cv_alignof_short
21257 _ACEOF
21258
21259
21260 { echo "$as_me:$LINENO: checking for int" >&5
21261 echo $ECHO_N "checking for int... $ECHO_C" >&6; }
21262 if test "${ac_cv_type_int+set}" = set; then
21263   echo $ECHO_N "(cached) $ECHO_C" >&6
21264 else
21265   cat >conftest.$ac_ext <<_ACEOF
21266 /* confdefs.h.  */
21267 _ACEOF
21268 cat confdefs.h >>conftest.$ac_ext
21269 cat >>conftest.$ac_ext <<_ACEOF
21270 /* end confdefs.h.  */
21271 $ac_includes_default
21272 typedef int ac__type_new_;
21273 int
21274 main ()
21275 {
21276 if ((ac__type_new_ *) 0)
21277   return 0;
21278 if (sizeof (ac__type_new_))
21279   return 0;
21280   ;
21281   return 0;
21282 }
21283 _ACEOF
21284 rm -f conftest.$ac_objext
21285 if { (ac_try="$ac_compile"
21286 case "(($ac_try" in
21287   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21288   *) ac_try_echo=$ac_try;;
21289 esac
21290 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21291   (eval "$ac_compile") 2>conftest.er1
21292   ac_status=$?
21293   grep -v '^ *+' conftest.er1 >conftest.err
21294   rm -f conftest.er1
21295   cat conftest.err >&5
21296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21297   (exit $ac_status); } && {
21298          test -z "$ac_c_werror_flag" ||
21299          test ! -s conftest.err
21300        } && test -s conftest.$ac_objext; then
21301   ac_cv_type_int=yes
21302 else
21303   echo "$as_me: failed program was:" >&5
21304 sed 's/^/| /' conftest.$ac_ext >&5
21305
21306         ac_cv_type_int=no
21307 fi
21308
21309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21310 fi
21311 { echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
21312 echo "${ECHO_T}$ac_cv_type_int" >&6; }
21313
21314 # The cast to long int works around a bug in the HP C Compiler,
21315 # see AC_CHECK_SIZEOF for more information.
21316 { echo "$as_me:$LINENO: checking alignment of int" >&5
21317 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6; }
21318 if test "${ac_cv_alignof_int+set}" = set; then
21319   echo $ECHO_N "(cached) $ECHO_C" >&6
21320 else
21321   if test "$cross_compiling" = yes; then
21322   # Depending upon the size, compute the lo and hi bounds.
21323 cat >conftest.$ac_ext <<_ACEOF
21324 /* confdefs.h.  */
21325 _ACEOF
21326 cat confdefs.h >>conftest.$ac_ext
21327 cat >>conftest.$ac_ext <<_ACEOF
21328 /* end confdefs.h.  */
21329 $ac_includes_default
21330 #ifndef offsetof
21331 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21332 #endif
21333 typedef struct { char x; int y; } ac__type_alignof_;
21334 int
21335 main ()
21336 {
21337 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
21338 test_array [0] = 0
21339
21340   ;
21341   return 0;
21342 }
21343 _ACEOF
21344 rm -f conftest.$ac_objext
21345 if { (ac_try="$ac_compile"
21346 case "(($ac_try" in
21347   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21348   *) ac_try_echo=$ac_try;;
21349 esac
21350 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21351   (eval "$ac_compile") 2>conftest.er1
21352   ac_status=$?
21353   grep -v '^ *+' conftest.er1 >conftest.err
21354   rm -f conftest.er1
21355   cat conftest.err >&5
21356   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21357   (exit $ac_status); } && {
21358          test -z "$ac_c_werror_flag" ||
21359          test ! -s conftest.err
21360        } && test -s conftest.$ac_objext; then
21361   ac_lo=0 ac_mid=0
21362   while :; do
21363     cat >conftest.$ac_ext <<_ACEOF
21364 /* confdefs.h.  */
21365 _ACEOF
21366 cat confdefs.h >>conftest.$ac_ext
21367 cat >>conftest.$ac_ext <<_ACEOF
21368 /* end confdefs.h.  */
21369 $ac_includes_default
21370 #ifndef offsetof
21371 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21372 #endif
21373 typedef struct { char x; int y; } ac__type_alignof_;
21374 int
21375 main ()
21376 {
21377 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21378 test_array [0] = 0
21379
21380   ;
21381   return 0;
21382 }
21383 _ACEOF
21384 rm -f conftest.$ac_objext
21385 if { (ac_try="$ac_compile"
21386 case "(($ac_try" in
21387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21388   *) ac_try_echo=$ac_try;;
21389 esac
21390 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21391   (eval "$ac_compile") 2>conftest.er1
21392   ac_status=$?
21393   grep -v '^ *+' conftest.er1 >conftest.err
21394   rm -f conftest.er1
21395   cat conftest.err >&5
21396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21397   (exit $ac_status); } && {
21398          test -z "$ac_c_werror_flag" ||
21399          test ! -s conftest.err
21400        } && test -s conftest.$ac_objext; then
21401   ac_hi=$ac_mid; break
21402 else
21403   echo "$as_me: failed program was:" >&5
21404 sed 's/^/| /' conftest.$ac_ext >&5
21405
21406         ac_lo=`expr $ac_mid + 1`
21407                         if test $ac_lo -le $ac_mid; then
21408                           ac_lo= ac_hi=
21409                           break
21410                         fi
21411                         ac_mid=`expr 2 '*' $ac_mid + 1`
21412 fi
21413
21414 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21415   done
21416 else
21417   echo "$as_me: failed program was:" >&5
21418 sed 's/^/| /' conftest.$ac_ext >&5
21419
21420         cat >conftest.$ac_ext <<_ACEOF
21421 /* confdefs.h.  */
21422 _ACEOF
21423 cat confdefs.h >>conftest.$ac_ext
21424 cat >>conftest.$ac_ext <<_ACEOF
21425 /* end confdefs.h.  */
21426 $ac_includes_default
21427 #ifndef offsetof
21428 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21429 #endif
21430 typedef struct { char x; int y; } ac__type_alignof_;
21431 int
21432 main ()
21433 {
21434 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
21435 test_array [0] = 0
21436
21437   ;
21438   return 0;
21439 }
21440 _ACEOF
21441 rm -f conftest.$ac_objext
21442 if { (ac_try="$ac_compile"
21443 case "(($ac_try" in
21444   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21445   *) ac_try_echo=$ac_try;;
21446 esac
21447 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21448   (eval "$ac_compile") 2>conftest.er1
21449   ac_status=$?
21450   grep -v '^ *+' conftest.er1 >conftest.err
21451   rm -f conftest.er1
21452   cat conftest.err >&5
21453   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21454   (exit $ac_status); } && {
21455          test -z "$ac_c_werror_flag" ||
21456          test ! -s conftest.err
21457        } && test -s conftest.$ac_objext; then
21458   ac_hi=-1 ac_mid=-1
21459   while :; do
21460     cat >conftest.$ac_ext <<_ACEOF
21461 /* confdefs.h.  */
21462 _ACEOF
21463 cat confdefs.h >>conftest.$ac_ext
21464 cat >>conftest.$ac_ext <<_ACEOF
21465 /* end confdefs.h.  */
21466 $ac_includes_default
21467 #ifndef offsetof
21468 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21469 #endif
21470 typedef struct { char x; int y; } ac__type_alignof_;
21471 int
21472 main ()
21473 {
21474 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
21475 test_array [0] = 0
21476
21477   ;
21478   return 0;
21479 }
21480 _ACEOF
21481 rm -f conftest.$ac_objext
21482 if { (ac_try="$ac_compile"
21483 case "(($ac_try" in
21484   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21485   *) ac_try_echo=$ac_try;;
21486 esac
21487 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21488   (eval "$ac_compile") 2>conftest.er1
21489   ac_status=$?
21490   grep -v '^ *+' conftest.er1 >conftest.err
21491   rm -f conftest.er1
21492   cat conftest.err >&5
21493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21494   (exit $ac_status); } && {
21495          test -z "$ac_c_werror_flag" ||
21496          test ! -s conftest.err
21497        } && test -s conftest.$ac_objext; then
21498   ac_lo=$ac_mid; break
21499 else
21500   echo "$as_me: failed program was:" >&5
21501 sed 's/^/| /' conftest.$ac_ext >&5
21502
21503         ac_hi=`expr '(' $ac_mid ')' - 1`
21504                         if test $ac_mid -le $ac_hi; then
21505                           ac_lo= ac_hi=
21506                           break
21507                         fi
21508                         ac_mid=`expr 2 '*' $ac_mid`
21509 fi
21510
21511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21512   done
21513 else
21514   echo "$as_me: failed program was:" >&5
21515 sed 's/^/| /' conftest.$ac_ext >&5
21516
21517         ac_lo= ac_hi=
21518 fi
21519
21520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21521 fi
21522
21523 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21524 # Binary search between lo and hi bounds.
21525 while test "x$ac_lo" != "x$ac_hi"; do
21526   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
21527   cat >conftest.$ac_ext <<_ACEOF
21528 /* confdefs.h.  */
21529 _ACEOF
21530 cat confdefs.h >>conftest.$ac_ext
21531 cat >>conftest.$ac_ext <<_ACEOF
21532 /* end confdefs.h.  */
21533 $ac_includes_default
21534 #ifndef offsetof
21535 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21536 #endif
21537 typedef struct { char x; int y; } ac__type_alignof_;
21538 int
21539 main ()
21540 {
21541 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21542 test_array [0] = 0
21543
21544   ;
21545   return 0;
21546 }
21547 _ACEOF
21548 rm -f conftest.$ac_objext
21549 if { (ac_try="$ac_compile"
21550 case "(($ac_try" in
21551   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21552   *) ac_try_echo=$ac_try;;
21553 esac
21554 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21555   (eval "$ac_compile") 2>conftest.er1
21556   ac_status=$?
21557   grep -v '^ *+' conftest.er1 >conftest.err
21558   rm -f conftest.er1
21559   cat conftest.err >&5
21560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21561   (exit $ac_status); } && {
21562          test -z "$ac_c_werror_flag" ||
21563          test ! -s conftest.err
21564        } && test -s conftest.$ac_objext; then
21565   ac_hi=$ac_mid
21566 else
21567   echo "$as_me: failed program was:" >&5
21568 sed 's/^/| /' conftest.$ac_ext >&5
21569
21570         ac_lo=`expr '(' $ac_mid ')' + 1`
21571 fi
21572
21573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21574 done
21575 case $ac_lo in
21576 ?*) ac_cv_alignof_int=$ac_lo;;
21577 '') if test "$ac_cv_type_int" = yes; then
21578      { { echo "$as_me:$LINENO: error: cannot compute alignment of int
21579 See \`config.log' for more details." >&5
21580 echo "$as_me: error: cannot compute alignment of int
21581 See \`config.log' for more details." >&2;}
21582    { (exit 77); exit 77; }; }
21583    else
21584      ac_cv_alignof_int=0
21585    fi ;;
21586 esac
21587 else
21588   cat >conftest.$ac_ext <<_ACEOF
21589 /* confdefs.h.  */
21590 _ACEOF
21591 cat confdefs.h >>conftest.$ac_ext
21592 cat >>conftest.$ac_ext <<_ACEOF
21593 /* end confdefs.h.  */
21594 $ac_includes_default
21595 #ifndef offsetof
21596 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21597 #endif
21598 typedef struct { char x; int y; } ac__type_alignof_;
21599 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
21600 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
21601 #include <stdio.h>
21602 #include <stdlib.h>
21603 int
21604 main ()
21605 {
21606
21607   FILE *f = fopen ("conftest.val", "w");
21608   if (! f)
21609     return 1;
21610   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
21611     {
21612       long int i = longval ();
21613       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21614         return 1;
21615       fprintf (f, "%ld\n", i);
21616     }
21617   else
21618     {
21619       unsigned long int i = ulongval ();
21620       if (i != ((long int) offsetof (ac__type_alignof_, y)))
21621         return 1;
21622       fprintf (f, "%lu\n", i);
21623     }
21624   return ferror (f) || fclose (f) != 0;
21625
21626   ;
21627   return 0;
21628 }
21629 _ACEOF
21630 rm -f conftest$ac_exeext
21631 if { (ac_try="$ac_link"
21632 case "(($ac_try" in
21633   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21634   *) ac_try_echo=$ac_try;;
21635 esac
21636 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21637   (eval "$ac_link") 2>&5
21638   ac_status=$?
21639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21640   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21641   { (case "(($ac_try" in
21642   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21643   *) ac_try_echo=$ac_try;;
21644 esac
21645 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21646   (eval "$ac_try") 2>&5
21647   ac_status=$?
21648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21649   (exit $ac_status); }; }; then
21650   ac_cv_alignof_int=`cat conftest.val`
21651 else
21652   echo "$as_me: program exited with status $ac_status" >&5
21653 echo "$as_me: failed program was:" >&5
21654 sed 's/^/| /' conftest.$ac_ext >&5
21655
21656 ( exit $ac_status )
21657 if test "$ac_cv_type_int" = yes; then
21658      { { echo "$as_me:$LINENO: error: cannot compute alignment of int
21659 See \`config.log' for more details." >&5
21660 echo "$as_me: error: cannot compute alignment of int
21661 See \`config.log' for more details." >&2;}
21662    { (exit 77); exit 77; }; }
21663    else
21664      ac_cv_alignof_int=0
21665    fi
21666 fi
21667 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21668 fi
21669 rm -f conftest.val
21670 fi
21671 { echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
21672 echo "${ECHO_T}$ac_cv_alignof_int" >&6; }
21673
21674
21675
21676 cat >>confdefs.h <<_ACEOF
21677 #define ALIGNOF_INT $ac_cv_alignof_int
21678 _ACEOF
21679
21680
21681 { echo "$as_me:$LINENO: checking for long" >&5
21682 echo $ECHO_N "checking for long... $ECHO_C" >&6; }
21683 if test "${ac_cv_type_long+set}" = set; then
21684   echo $ECHO_N "(cached) $ECHO_C" >&6
21685 else
21686   cat >conftest.$ac_ext <<_ACEOF
21687 /* confdefs.h.  */
21688 _ACEOF
21689 cat confdefs.h >>conftest.$ac_ext
21690 cat >>conftest.$ac_ext <<_ACEOF
21691 /* end confdefs.h.  */
21692 $ac_includes_default
21693 typedef long ac__type_new_;
21694 int
21695 main ()
21696 {
21697 if ((ac__type_new_ *) 0)
21698   return 0;
21699 if (sizeof (ac__type_new_))
21700   return 0;
21701   ;
21702   return 0;
21703 }
21704 _ACEOF
21705 rm -f conftest.$ac_objext
21706 if { (ac_try="$ac_compile"
21707 case "(($ac_try" in
21708   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21709   *) ac_try_echo=$ac_try;;
21710 esac
21711 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21712   (eval "$ac_compile") 2>conftest.er1
21713   ac_status=$?
21714   grep -v '^ *+' conftest.er1 >conftest.err
21715   rm -f conftest.er1
21716   cat conftest.err >&5
21717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21718   (exit $ac_status); } && {
21719          test -z "$ac_c_werror_flag" ||
21720          test ! -s conftest.err
21721        } && test -s conftest.$ac_objext; then
21722   ac_cv_type_long=yes
21723 else
21724   echo "$as_me: failed program was:" >&5
21725 sed 's/^/| /' conftest.$ac_ext >&5
21726
21727         ac_cv_type_long=no
21728 fi
21729
21730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21731 fi
21732 { echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
21733 echo "${ECHO_T}$ac_cv_type_long" >&6; }
21734
21735 # The cast to long int works around a bug in the HP C Compiler,
21736 # see AC_CHECK_SIZEOF for more information.
21737 { echo "$as_me:$LINENO: checking alignment of long" >&5
21738 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6; }
21739 if test "${ac_cv_alignof_long+set}" = set; then
21740   echo $ECHO_N "(cached) $ECHO_C" >&6
21741 else
21742   if test "$cross_compiling" = yes; then
21743   # Depending upon the size, compute the lo and hi bounds.
21744 cat >conftest.$ac_ext <<_ACEOF
21745 /* confdefs.h.  */
21746 _ACEOF
21747 cat confdefs.h >>conftest.$ac_ext
21748 cat >>conftest.$ac_ext <<_ACEOF
21749 /* end confdefs.h.  */
21750 $ac_includes_default
21751 #ifndef offsetof
21752 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21753 #endif
21754 typedef struct { char x; long y; } ac__type_alignof_;
21755 int
21756 main ()
21757 {
21758 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
21759 test_array [0] = 0
21760
21761   ;
21762   return 0;
21763 }
21764 _ACEOF
21765 rm -f conftest.$ac_objext
21766 if { (ac_try="$ac_compile"
21767 case "(($ac_try" in
21768   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21769   *) ac_try_echo=$ac_try;;
21770 esac
21771 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21772   (eval "$ac_compile") 2>conftest.er1
21773   ac_status=$?
21774   grep -v '^ *+' conftest.er1 >conftest.err
21775   rm -f conftest.er1
21776   cat conftest.err >&5
21777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21778   (exit $ac_status); } && {
21779          test -z "$ac_c_werror_flag" ||
21780          test ! -s conftest.err
21781        } && test -s conftest.$ac_objext; then
21782   ac_lo=0 ac_mid=0
21783   while :; do
21784     cat >conftest.$ac_ext <<_ACEOF
21785 /* confdefs.h.  */
21786 _ACEOF
21787 cat confdefs.h >>conftest.$ac_ext
21788 cat >>conftest.$ac_ext <<_ACEOF
21789 /* end confdefs.h.  */
21790 $ac_includes_default
21791 #ifndef offsetof
21792 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21793 #endif
21794 typedef struct { char x; long y; } ac__type_alignof_;
21795 int
21796 main ()
21797 {
21798 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21799 test_array [0] = 0
21800
21801   ;
21802   return 0;
21803 }
21804 _ACEOF
21805 rm -f conftest.$ac_objext
21806 if { (ac_try="$ac_compile"
21807 case "(($ac_try" in
21808   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21809   *) ac_try_echo=$ac_try;;
21810 esac
21811 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21812   (eval "$ac_compile") 2>conftest.er1
21813   ac_status=$?
21814   grep -v '^ *+' conftest.er1 >conftest.err
21815   rm -f conftest.er1
21816   cat conftest.err >&5
21817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21818   (exit $ac_status); } && {
21819          test -z "$ac_c_werror_flag" ||
21820          test ! -s conftest.err
21821        } && test -s conftest.$ac_objext; then
21822   ac_hi=$ac_mid; break
21823 else
21824   echo "$as_me: failed program was:" >&5
21825 sed 's/^/| /' conftest.$ac_ext >&5
21826
21827         ac_lo=`expr $ac_mid + 1`
21828                         if test $ac_lo -le $ac_mid; then
21829                           ac_lo= ac_hi=
21830                           break
21831                         fi
21832                         ac_mid=`expr 2 '*' $ac_mid + 1`
21833 fi
21834
21835 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21836   done
21837 else
21838   echo "$as_me: failed program was:" >&5
21839 sed 's/^/| /' conftest.$ac_ext >&5
21840
21841         cat >conftest.$ac_ext <<_ACEOF
21842 /* confdefs.h.  */
21843 _ACEOF
21844 cat confdefs.h >>conftest.$ac_ext
21845 cat >>conftest.$ac_ext <<_ACEOF
21846 /* end confdefs.h.  */
21847 $ac_includes_default
21848 #ifndef offsetof
21849 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21850 #endif
21851 typedef struct { char x; long y; } ac__type_alignof_;
21852 int
21853 main ()
21854 {
21855 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
21856 test_array [0] = 0
21857
21858   ;
21859   return 0;
21860 }
21861 _ACEOF
21862 rm -f conftest.$ac_objext
21863 if { (ac_try="$ac_compile"
21864 case "(($ac_try" in
21865   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21866   *) ac_try_echo=$ac_try;;
21867 esac
21868 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21869   (eval "$ac_compile") 2>conftest.er1
21870   ac_status=$?
21871   grep -v '^ *+' conftest.er1 >conftest.err
21872   rm -f conftest.er1
21873   cat conftest.err >&5
21874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21875   (exit $ac_status); } && {
21876          test -z "$ac_c_werror_flag" ||
21877          test ! -s conftest.err
21878        } && test -s conftest.$ac_objext; then
21879   ac_hi=-1 ac_mid=-1
21880   while :; do
21881     cat >conftest.$ac_ext <<_ACEOF
21882 /* confdefs.h.  */
21883 _ACEOF
21884 cat confdefs.h >>conftest.$ac_ext
21885 cat >>conftest.$ac_ext <<_ACEOF
21886 /* end confdefs.h.  */
21887 $ac_includes_default
21888 #ifndef offsetof
21889 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21890 #endif
21891 typedef struct { char x; long y; } ac__type_alignof_;
21892 int
21893 main ()
21894 {
21895 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
21896 test_array [0] = 0
21897
21898   ;
21899   return 0;
21900 }
21901 _ACEOF
21902 rm -f conftest.$ac_objext
21903 if { (ac_try="$ac_compile"
21904 case "(($ac_try" in
21905   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21906   *) ac_try_echo=$ac_try;;
21907 esac
21908 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21909   (eval "$ac_compile") 2>conftest.er1
21910   ac_status=$?
21911   grep -v '^ *+' conftest.er1 >conftest.err
21912   rm -f conftest.er1
21913   cat conftest.err >&5
21914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21915   (exit $ac_status); } && {
21916          test -z "$ac_c_werror_flag" ||
21917          test ! -s conftest.err
21918        } && test -s conftest.$ac_objext; then
21919   ac_lo=$ac_mid; break
21920 else
21921   echo "$as_me: failed program was:" >&5
21922 sed 's/^/| /' conftest.$ac_ext >&5
21923
21924         ac_hi=`expr '(' $ac_mid ')' - 1`
21925                         if test $ac_mid -le $ac_hi; then
21926                           ac_lo= ac_hi=
21927                           break
21928                         fi
21929                         ac_mid=`expr 2 '*' $ac_mid`
21930 fi
21931
21932 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21933   done
21934 else
21935   echo "$as_me: failed program was:" >&5
21936 sed 's/^/| /' conftest.$ac_ext >&5
21937
21938         ac_lo= ac_hi=
21939 fi
21940
21941 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21942 fi
21943
21944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21945 # Binary search between lo and hi bounds.
21946 while test "x$ac_lo" != "x$ac_hi"; do
21947   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
21948   cat >conftest.$ac_ext <<_ACEOF
21949 /* confdefs.h.  */
21950 _ACEOF
21951 cat confdefs.h >>conftest.$ac_ext
21952 cat >>conftest.$ac_ext <<_ACEOF
21953 /* end confdefs.h.  */
21954 $ac_includes_default
21955 #ifndef offsetof
21956 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
21957 #endif
21958 typedef struct { char x; long y; } ac__type_alignof_;
21959 int
21960 main ()
21961 {
21962 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
21963 test_array [0] = 0
21964
21965   ;
21966   return 0;
21967 }
21968 _ACEOF
21969 rm -f conftest.$ac_objext
21970 if { (ac_try="$ac_compile"
21971 case "(($ac_try" in
21972   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21973   *) ac_try_echo=$ac_try;;
21974 esac
21975 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21976   (eval "$ac_compile") 2>conftest.er1
21977   ac_status=$?
21978   grep -v '^ *+' conftest.er1 >conftest.err
21979   rm -f conftest.er1
21980   cat conftest.err >&5
21981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21982   (exit $ac_status); } && {
21983          test -z "$ac_c_werror_flag" ||
21984          test ! -s conftest.err
21985        } && test -s conftest.$ac_objext; then
21986   ac_hi=$ac_mid
21987 else
21988   echo "$as_me: failed program was:" >&5
21989 sed 's/^/| /' conftest.$ac_ext >&5
21990
21991         ac_lo=`expr '(' $ac_mid ')' + 1`
21992 fi
21993
21994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21995 done
21996 case $ac_lo in
21997 ?*) ac_cv_alignof_long=$ac_lo;;
21998 '') if test "$ac_cv_type_long" = yes; then
21999      { { echo "$as_me:$LINENO: error: cannot compute alignment of long
22000 See \`config.log' for more details." >&5
22001 echo "$as_me: error: cannot compute alignment of long
22002 See \`config.log' for more details." >&2;}
22003    { (exit 77); exit 77; }; }
22004    else
22005      ac_cv_alignof_long=0
22006    fi ;;
22007 esac
22008 else
22009   cat >conftest.$ac_ext <<_ACEOF
22010 /* confdefs.h.  */
22011 _ACEOF
22012 cat confdefs.h >>conftest.$ac_ext
22013 cat >>conftest.$ac_ext <<_ACEOF
22014 /* end confdefs.h.  */
22015 $ac_includes_default
22016 #ifndef offsetof
22017 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22018 #endif
22019 typedef struct { char x; long y; } ac__type_alignof_;
22020 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
22021 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
22022 #include <stdio.h>
22023 #include <stdlib.h>
22024 int
22025 main ()
22026 {
22027
22028   FILE *f = fopen ("conftest.val", "w");
22029   if (! f)
22030     return 1;
22031   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
22032     {
22033       long int i = longval ();
22034       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22035         return 1;
22036       fprintf (f, "%ld\n", i);
22037     }
22038   else
22039     {
22040       unsigned long int i = ulongval ();
22041       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22042         return 1;
22043       fprintf (f, "%lu\n", i);
22044     }
22045   return ferror (f) || fclose (f) != 0;
22046
22047   ;
22048   return 0;
22049 }
22050 _ACEOF
22051 rm -f conftest$ac_exeext
22052 if { (ac_try="$ac_link"
22053 case "(($ac_try" in
22054   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22055   *) ac_try_echo=$ac_try;;
22056 esac
22057 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22058   (eval "$ac_link") 2>&5
22059   ac_status=$?
22060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22061   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22062   { (case "(($ac_try" in
22063   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22064   *) ac_try_echo=$ac_try;;
22065 esac
22066 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22067   (eval "$ac_try") 2>&5
22068   ac_status=$?
22069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22070   (exit $ac_status); }; }; then
22071   ac_cv_alignof_long=`cat conftest.val`
22072 else
22073   echo "$as_me: program exited with status $ac_status" >&5
22074 echo "$as_me: failed program was:" >&5
22075 sed 's/^/| /' conftest.$ac_ext >&5
22076
22077 ( exit $ac_status )
22078 if test "$ac_cv_type_long" = yes; then
22079      { { echo "$as_me:$LINENO: error: cannot compute alignment of long
22080 See \`config.log' for more details." >&5
22081 echo "$as_me: error: cannot compute alignment of long
22082 See \`config.log' for more details." >&2;}
22083    { (exit 77); exit 77; }; }
22084    else
22085      ac_cv_alignof_long=0
22086    fi
22087 fi
22088 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22089 fi
22090 rm -f conftest.val
22091 fi
22092 { echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
22093 echo "${ECHO_T}$ac_cv_alignof_long" >&6; }
22094
22095
22096
22097 cat >>confdefs.h <<_ACEOF
22098 #define ALIGNOF_LONG $ac_cv_alignof_long
22099 _ACEOF
22100
22101
22102 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
22103   { echo "$as_me:$LINENO: checking for long long int" >&5
22104 echo $ECHO_N "checking for long long int... $ECHO_C" >&6; }
22105 if test "${ac_cv_type_long_long_int+set}" = set; then
22106   echo $ECHO_N "(cached) $ECHO_C" >&6
22107 else
22108   cat >conftest.$ac_ext <<_ACEOF
22109 /* confdefs.h.  */
22110 _ACEOF
22111 cat confdefs.h >>conftest.$ac_ext
22112 cat >>conftest.$ac_ext <<_ACEOF
22113 /* end confdefs.h.  */
22114 $ac_includes_default
22115 typedef long long int ac__type_new_;
22116 int
22117 main ()
22118 {
22119 if ((ac__type_new_ *) 0)
22120   return 0;
22121 if (sizeof (ac__type_new_))
22122   return 0;
22123   ;
22124   return 0;
22125 }
22126 _ACEOF
22127 rm -f conftest.$ac_objext
22128 if { (ac_try="$ac_compile"
22129 case "(($ac_try" in
22130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22131   *) ac_try_echo=$ac_try;;
22132 esac
22133 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22134   (eval "$ac_compile") 2>conftest.er1
22135   ac_status=$?
22136   grep -v '^ *+' conftest.er1 >conftest.err
22137   rm -f conftest.er1
22138   cat conftest.err >&5
22139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22140   (exit $ac_status); } && {
22141          test -z "$ac_c_werror_flag" ||
22142          test ! -s conftest.err
22143        } && test -s conftest.$ac_objext; then
22144   ac_cv_type_long_long_int=yes
22145 else
22146   echo "$as_me: failed program was:" >&5
22147 sed 's/^/| /' conftest.$ac_ext >&5
22148
22149         ac_cv_type_long_long_int=no
22150 fi
22151
22152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22153 fi
22154 { echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
22155 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6; }
22156
22157 # The cast to long int works around a bug in the HP C Compiler,
22158 # see AC_CHECK_SIZEOF for more information.
22159 { echo "$as_me:$LINENO: checking alignment of long long int" >&5
22160 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6; }
22161 if test "${ac_cv_alignof_long_long_int+set}" = set; then
22162   echo $ECHO_N "(cached) $ECHO_C" >&6
22163 else
22164   if test "$cross_compiling" = yes; then
22165   # Depending upon the size, compute the lo and hi bounds.
22166 cat >conftest.$ac_ext <<_ACEOF
22167 /* confdefs.h.  */
22168 _ACEOF
22169 cat confdefs.h >>conftest.$ac_ext
22170 cat >>conftest.$ac_ext <<_ACEOF
22171 /* end confdefs.h.  */
22172 $ac_includes_default
22173 #ifndef offsetof
22174 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22175 #endif
22176 typedef struct { char x; long long int y; } ac__type_alignof_;
22177 int
22178 main ()
22179 {
22180 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
22181 test_array [0] = 0
22182
22183   ;
22184   return 0;
22185 }
22186 _ACEOF
22187 rm -f conftest.$ac_objext
22188 if { (ac_try="$ac_compile"
22189 case "(($ac_try" in
22190   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22191   *) ac_try_echo=$ac_try;;
22192 esac
22193 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22194   (eval "$ac_compile") 2>conftest.er1
22195   ac_status=$?
22196   grep -v '^ *+' conftest.er1 >conftest.err
22197   rm -f conftest.er1
22198   cat conftest.err >&5
22199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22200   (exit $ac_status); } && {
22201          test -z "$ac_c_werror_flag" ||
22202          test ! -s conftest.err
22203        } && test -s conftest.$ac_objext; then
22204   ac_lo=0 ac_mid=0
22205   while :; do
22206     cat >conftest.$ac_ext <<_ACEOF
22207 /* confdefs.h.  */
22208 _ACEOF
22209 cat confdefs.h >>conftest.$ac_ext
22210 cat >>conftest.$ac_ext <<_ACEOF
22211 /* end confdefs.h.  */
22212 $ac_includes_default
22213 #ifndef offsetof
22214 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22215 #endif
22216 typedef struct { char x; long long int y; } ac__type_alignof_;
22217 int
22218 main ()
22219 {
22220 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22221 test_array [0] = 0
22222
22223   ;
22224   return 0;
22225 }
22226 _ACEOF
22227 rm -f conftest.$ac_objext
22228 if { (ac_try="$ac_compile"
22229 case "(($ac_try" in
22230   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22231   *) ac_try_echo=$ac_try;;
22232 esac
22233 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22234   (eval "$ac_compile") 2>conftest.er1
22235   ac_status=$?
22236   grep -v '^ *+' conftest.er1 >conftest.err
22237   rm -f conftest.er1
22238   cat conftest.err >&5
22239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22240   (exit $ac_status); } && {
22241          test -z "$ac_c_werror_flag" ||
22242          test ! -s conftest.err
22243        } && test -s conftest.$ac_objext; then
22244   ac_hi=$ac_mid; break
22245 else
22246   echo "$as_me: failed program was:" >&5
22247 sed 's/^/| /' conftest.$ac_ext >&5
22248
22249         ac_lo=`expr $ac_mid + 1`
22250                         if test $ac_lo -le $ac_mid; then
22251                           ac_lo= ac_hi=
22252                           break
22253                         fi
22254                         ac_mid=`expr 2 '*' $ac_mid + 1`
22255 fi
22256
22257 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22258   done
22259 else
22260   echo "$as_me: failed program was:" >&5
22261 sed 's/^/| /' conftest.$ac_ext >&5
22262
22263         cat >conftest.$ac_ext <<_ACEOF
22264 /* confdefs.h.  */
22265 _ACEOF
22266 cat confdefs.h >>conftest.$ac_ext
22267 cat >>conftest.$ac_ext <<_ACEOF
22268 /* end confdefs.h.  */
22269 $ac_includes_default
22270 #ifndef offsetof
22271 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22272 #endif
22273 typedef struct { char x; long long int y; } ac__type_alignof_;
22274 int
22275 main ()
22276 {
22277 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
22278 test_array [0] = 0
22279
22280   ;
22281   return 0;
22282 }
22283 _ACEOF
22284 rm -f conftest.$ac_objext
22285 if { (ac_try="$ac_compile"
22286 case "(($ac_try" in
22287   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22288   *) ac_try_echo=$ac_try;;
22289 esac
22290 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22291   (eval "$ac_compile") 2>conftest.er1
22292   ac_status=$?
22293   grep -v '^ *+' conftest.er1 >conftest.err
22294   rm -f conftest.er1
22295   cat conftest.err >&5
22296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22297   (exit $ac_status); } && {
22298          test -z "$ac_c_werror_flag" ||
22299          test ! -s conftest.err
22300        } && test -s conftest.$ac_objext; then
22301   ac_hi=-1 ac_mid=-1
22302   while :; do
22303     cat >conftest.$ac_ext <<_ACEOF
22304 /* confdefs.h.  */
22305 _ACEOF
22306 cat confdefs.h >>conftest.$ac_ext
22307 cat >>conftest.$ac_ext <<_ACEOF
22308 /* end confdefs.h.  */
22309 $ac_includes_default
22310 #ifndef offsetof
22311 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22312 #endif
22313 typedef struct { char x; long long int y; } ac__type_alignof_;
22314 int
22315 main ()
22316 {
22317 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
22318 test_array [0] = 0
22319
22320   ;
22321   return 0;
22322 }
22323 _ACEOF
22324 rm -f conftest.$ac_objext
22325 if { (ac_try="$ac_compile"
22326 case "(($ac_try" in
22327   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22328   *) ac_try_echo=$ac_try;;
22329 esac
22330 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22331   (eval "$ac_compile") 2>conftest.er1
22332   ac_status=$?
22333   grep -v '^ *+' conftest.er1 >conftest.err
22334   rm -f conftest.er1
22335   cat conftest.err >&5
22336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22337   (exit $ac_status); } && {
22338          test -z "$ac_c_werror_flag" ||
22339          test ! -s conftest.err
22340        } && test -s conftest.$ac_objext; then
22341   ac_lo=$ac_mid; break
22342 else
22343   echo "$as_me: failed program was:" >&5
22344 sed 's/^/| /' conftest.$ac_ext >&5
22345
22346         ac_hi=`expr '(' $ac_mid ')' - 1`
22347                         if test $ac_mid -le $ac_hi; then
22348                           ac_lo= ac_hi=
22349                           break
22350                         fi
22351                         ac_mid=`expr 2 '*' $ac_mid`
22352 fi
22353
22354 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22355   done
22356 else
22357   echo "$as_me: failed program was:" >&5
22358 sed 's/^/| /' conftest.$ac_ext >&5
22359
22360         ac_lo= ac_hi=
22361 fi
22362
22363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22364 fi
22365
22366 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22367 # Binary search between lo and hi bounds.
22368 while test "x$ac_lo" != "x$ac_hi"; do
22369   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
22370   cat >conftest.$ac_ext <<_ACEOF
22371 /* confdefs.h.  */
22372 _ACEOF
22373 cat confdefs.h >>conftest.$ac_ext
22374 cat >>conftest.$ac_ext <<_ACEOF
22375 /* end confdefs.h.  */
22376 $ac_includes_default
22377 #ifndef offsetof
22378 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22379 #endif
22380 typedef struct { char x; long long int y; } ac__type_alignof_;
22381 int
22382 main ()
22383 {
22384 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22385 test_array [0] = 0
22386
22387   ;
22388   return 0;
22389 }
22390 _ACEOF
22391 rm -f conftest.$ac_objext
22392 if { (ac_try="$ac_compile"
22393 case "(($ac_try" in
22394   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22395   *) ac_try_echo=$ac_try;;
22396 esac
22397 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22398   (eval "$ac_compile") 2>conftest.er1
22399   ac_status=$?
22400   grep -v '^ *+' conftest.er1 >conftest.err
22401   rm -f conftest.er1
22402   cat conftest.err >&5
22403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22404   (exit $ac_status); } && {
22405          test -z "$ac_c_werror_flag" ||
22406          test ! -s conftest.err
22407        } && test -s conftest.$ac_objext; then
22408   ac_hi=$ac_mid
22409 else
22410   echo "$as_me: failed program was:" >&5
22411 sed 's/^/| /' conftest.$ac_ext >&5
22412
22413         ac_lo=`expr '(' $ac_mid ')' + 1`
22414 fi
22415
22416 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22417 done
22418 case $ac_lo in
22419 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
22420 '') if test "$ac_cv_type_long_long_int" = yes; then
22421      { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int
22422 See \`config.log' for more details." >&5
22423 echo "$as_me: error: cannot compute alignment of long long int
22424 See \`config.log' for more details." >&2;}
22425    { (exit 77); exit 77; }; }
22426    else
22427      ac_cv_alignof_long_long_int=0
22428    fi ;;
22429 esac
22430 else
22431   cat >conftest.$ac_ext <<_ACEOF
22432 /* confdefs.h.  */
22433 _ACEOF
22434 cat confdefs.h >>conftest.$ac_ext
22435 cat >>conftest.$ac_ext <<_ACEOF
22436 /* end confdefs.h.  */
22437 $ac_includes_default
22438 #ifndef offsetof
22439 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22440 #endif
22441 typedef struct { char x; long long int y; } ac__type_alignof_;
22442 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
22443 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
22444 #include <stdio.h>
22445 #include <stdlib.h>
22446 int
22447 main ()
22448 {
22449
22450   FILE *f = fopen ("conftest.val", "w");
22451   if (! f)
22452     return 1;
22453   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
22454     {
22455       long int i = longval ();
22456       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22457         return 1;
22458       fprintf (f, "%ld\n", i);
22459     }
22460   else
22461     {
22462       unsigned long int i = ulongval ();
22463       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22464         return 1;
22465       fprintf (f, "%lu\n", i);
22466     }
22467   return ferror (f) || fclose (f) != 0;
22468
22469   ;
22470   return 0;
22471 }
22472 _ACEOF
22473 rm -f conftest$ac_exeext
22474 if { (ac_try="$ac_link"
22475 case "(($ac_try" in
22476   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22477   *) ac_try_echo=$ac_try;;
22478 esac
22479 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22480   (eval "$ac_link") 2>&5
22481   ac_status=$?
22482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22483   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22484   { (case "(($ac_try" in
22485   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22486   *) ac_try_echo=$ac_try;;
22487 esac
22488 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22489   (eval "$ac_try") 2>&5
22490   ac_status=$?
22491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22492   (exit $ac_status); }; }; then
22493   ac_cv_alignof_long_long_int=`cat conftest.val`
22494 else
22495   echo "$as_me: program exited with status $ac_status" >&5
22496 echo "$as_me: failed program was:" >&5
22497 sed 's/^/| /' conftest.$ac_ext >&5
22498
22499 ( exit $ac_status )
22500 if test "$ac_cv_type_long_long_int" = yes; then
22501      { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int
22502 See \`config.log' for more details." >&5
22503 echo "$as_me: error: cannot compute alignment of long long int
22504 See \`config.log' for more details." >&2;}
22505    { (exit 77); exit 77; }; }
22506    else
22507      ac_cv_alignof_long_long_int=0
22508    fi
22509 fi
22510 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22511 fi
22512 rm -f conftest.val
22513 fi
22514 { echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
22515 echo "${ECHO_T}$ac_cv_alignof_long_long_int" >&6; }
22516
22517
22518
22519 cat >>confdefs.h <<_ACEOF
22520 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
22521 _ACEOF
22522
22523
22524 fi
22525 { echo "$as_me:$LINENO: checking for double" >&5
22526 echo $ECHO_N "checking for double... $ECHO_C" >&6; }
22527 if test "${ac_cv_type_double+set}" = set; then
22528   echo $ECHO_N "(cached) $ECHO_C" >&6
22529 else
22530   cat >conftest.$ac_ext <<_ACEOF
22531 /* confdefs.h.  */
22532 _ACEOF
22533 cat confdefs.h >>conftest.$ac_ext
22534 cat >>conftest.$ac_ext <<_ACEOF
22535 /* end confdefs.h.  */
22536 $ac_includes_default
22537 typedef double ac__type_new_;
22538 int
22539 main ()
22540 {
22541 if ((ac__type_new_ *) 0)
22542   return 0;
22543 if (sizeof (ac__type_new_))
22544   return 0;
22545   ;
22546   return 0;
22547 }
22548 _ACEOF
22549 rm -f conftest.$ac_objext
22550 if { (ac_try="$ac_compile"
22551 case "(($ac_try" in
22552   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22553   *) ac_try_echo=$ac_try;;
22554 esac
22555 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22556   (eval "$ac_compile") 2>conftest.er1
22557   ac_status=$?
22558   grep -v '^ *+' conftest.er1 >conftest.err
22559   rm -f conftest.er1
22560   cat conftest.err >&5
22561   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22562   (exit $ac_status); } && {
22563          test -z "$ac_c_werror_flag" ||
22564          test ! -s conftest.err
22565        } && test -s conftest.$ac_objext; then
22566   ac_cv_type_double=yes
22567 else
22568   echo "$as_me: failed program was:" >&5
22569 sed 's/^/| /' conftest.$ac_ext >&5
22570
22571         ac_cv_type_double=no
22572 fi
22573
22574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22575 fi
22576 { echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
22577 echo "${ECHO_T}$ac_cv_type_double" >&6; }
22578
22579 # The cast to long int works around a bug in the HP C Compiler,
22580 # see AC_CHECK_SIZEOF for more information.
22581 { echo "$as_me:$LINENO: checking alignment of double" >&5
22582 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6; }
22583 if test "${ac_cv_alignof_double+set}" = set; then
22584   echo $ECHO_N "(cached) $ECHO_C" >&6
22585 else
22586   if test "$cross_compiling" = yes; then
22587   # Depending upon the size, compute the lo and hi bounds.
22588 cat >conftest.$ac_ext <<_ACEOF
22589 /* confdefs.h.  */
22590 _ACEOF
22591 cat confdefs.h >>conftest.$ac_ext
22592 cat >>conftest.$ac_ext <<_ACEOF
22593 /* end confdefs.h.  */
22594 $ac_includes_default
22595 #ifndef offsetof
22596 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22597 #endif
22598 typedef struct { char x; double y; } ac__type_alignof_;
22599 int
22600 main ()
22601 {
22602 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
22603 test_array [0] = 0
22604
22605   ;
22606   return 0;
22607 }
22608 _ACEOF
22609 rm -f conftest.$ac_objext
22610 if { (ac_try="$ac_compile"
22611 case "(($ac_try" in
22612   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22613   *) ac_try_echo=$ac_try;;
22614 esac
22615 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22616   (eval "$ac_compile") 2>conftest.er1
22617   ac_status=$?
22618   grep -v '^ *+' conftest.er1 >conftest.err
22619   rm -f conftest.er1
22620   cat conftest.err >&5
22621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22622   (exit $ac_status); } && {
22623          test -z "$ac_c_werror_flag" ||
22624          test ! -s conftest.err
22625        } && test -s conftest.$ac_objext; then
22626   ac_lo=0 ac_mid=0
22627   while :; do
22628     cat >conftest.$ac_ext <<_ACEOF
22629 /* confdefs.h.  */
22630 _ACEOF
22631 cat confdefs.h >>conftest.$ac_ext
22632 cat >>conftest.$ac_ext <<_ACEOF
22633 /* end confdefs.h.  */
22634 $ac_includes_default
22635 #ifndef offsetof
22636 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22637 #endif
22638 typedef struct { char x; double y; } ac__type_alignof_;
22639 int
22640 main ()
22641 {
22642 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22643 test_array [0] = 0
22644
22645   ;
22646   return 0;
22647 }
22648 _ACEOF
22649 rm -f conftest.$ac_objext
22650 if { (ac_try="$ac_compile"
22651 case "(($ac_try" in
22652   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22653   *) ac_try_echo=$ac_try;;
22654 esac
22655 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22656   (eval "$ac_compile") 2>conftest.er1
22657   ac_status=$?
22658   grep -v '^ *+' conftest.er1 >conftest.err
22659   rm -f conftest.er1
22660   cat conftest.err >&5
22661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22662   (exit $ac_status); } && {
22663          test -z "$ac_c_werror_flag" ||
22664          test ! -s conftest.err
22665        } && test -s conftest.$ac_objext; then
22666   ac_hi=$ac_mid; break
22667 else
22668   echo "$as_me: failed program was:" >&5
22669 sed 's/^/| /' conftest.$ac_ext >&5
22670
22671         ac_lo=`expr $ac_mid + 1`
22672                         if test $ac_lo -le $ac_mid; then
22673                           ac_lo= ac_hi=
22674                           break
22675                         fi
22676                         ac_mid=`expr 2 '*' $ac_mid + 1`
22677 fi
22678
22679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22680   done
22681 else
22682   echo "$as_me: failed program was:" >&5
22683 sed 's/^/| /' conftest.$ac_ext >&5
22684
22685         cat >conftest.$ac_ext <<_ACEOF
22686 /* confdefs.h.  */
22687 _ACEOF
22688 cat confdefs.h >>conftest.$ac_ext
22689 cat >>conftest.$ac_ext <<_ACEOF
22690 /* end confdefs.h.  */
22691 $ac_includes_default
22692 #ifndef offsetof
22693 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22694 #endif
22695 typedef struct { char x; double y; } ac__type_alignof_;
22696 int
22697 main ()
22698 {
22699 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
22700 test_array [0] = 0
22701
22702   ;
22703   return 0;
22704 }
22705 _ACEOF
22706 rm -f conftest.$ac_objext
22707 if { (ac_try="$ac_compile"
22708 case "(($ac_try" in
22709   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22710   *) ac_try_echo=$ac_try;;
22711 esac
22712 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22713   (eval "$ac_compile") 2>conftest.er1
22714   ac_status=$?
22715   grep -v '^ *+' conftest.er1 >conftest.err
22716   rm -f conftest.er1
22717   cat conftest.err >&5
22718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22719   (exit $ac_status); } && {
22720          test -z "$ac_c_werror_flag" ||
22721          test ! -s conftest.err
22722        } && test -s conftest.$ac_objext; then
22723   ac_hi=-1 ac_mid=-1
22724   while :; do
22725     cat >conftest.$ac_ext <<_ACEOF
22726 /* confdefs.h.  */
22727 _ACEOF
22728 cat confdefs.h >>conftest.$ac_ext
22729 cat >>conftest.$ac_ext <<_ACEOF
22730 /* end confdefs.h.  */
22731 $ac_includes_default
22732 #ifndef offsetof
22733 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22734 #endif
22735 typedef struct { char x; double y; } ac__type_alignof_;
22736 int
22737 main ()
22738 {
22739 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
22740 test_array [0] = 0
22741
22742   ;
22743   return 0;
22744 }
22745 _ACEOF
22746 rm -f conftest.$ac_objext
22747 if { (ac_try="$ac_compile"
22748 case "(($ac_try" in
22749   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22750   *) ac_try_echo=$ac_try;;
22751 esac
22752 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22753   (eval "$ac_compile") 2>conftest.er1
22754   ac_status=$?
22755   grep -v '^ *+' conftest.er1 >conftest.err
22756   rm -f conftest.er1
22757   cat conftest.err >&5
22758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22759   (exit $ac_status); } && {
22760          test -z "$ac_c_werror_flag" ||
22761          test ! -s conftest.err
22762        } && test -s conftest.$ac_objext; then
22763   ac_lo=$ac_mid; break
22764 else
22765   echo "$as_me: failed program was:" >&5
22766 sed 's/^/| /' conftest.$ac_ext >&5
22767
22768         ac_hi=`expr '(' $ac_mid ')' - 1`
22769                         if test $ac_mid -le $ac_hi; then
22770                           ac_lo= ac_hi=
22771                           break
22772                         fi
22773                         ac_mid=`expr 2 '*' $ac_mid`
22774 fi
22775
22776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22777   done
22778 else
22779   echo "$as_me: failed program was:" >&5
22780 sed 's/^/| /' conftest.$ac_ext >&5
22781
22782         ac_lo= ac_hi=
22783 fi
22784
22785 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22786 fi
22787
22788 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22789 # Binary search between lo and hi bounds.
22790 while test "x$ac_lo" != "x$ac_hi"; do
22791   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
22792   cat >conftest.$ac_ext <<_ACEOF
22793 /* confdefs.h.  */
22794 _ACEOF
22795 cat confdefs.h >>conftest.$ac_ext
22796 cat >>conftest.$ac_ext <<_ACEOF
22797 /* end confdefs.h.  */
22798 $ac_includes_default
22799 #ifndef offsetof
22800 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22801 #endif
22802 typedef struct { char x; double y; } ac__type_alignof_;
22803 int
22804 main ()
22805 {
22806 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
22807 test_array [0] = 0
22808
22809   ;
22810   return 0;
22811 }
22812 _ACEOF
22813 rm -f conftest.$ac_objext
22814 if { (ac_try="$ac_compile"
22815 case "(($ac_try" in
22816   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22817   *) ac_try_echo=$ac_try;;
22818 esac
22819 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22820   (eval "$ac_compile") 2>conftest.er1
22821   ac_status=$?
22822   grep -v '^ *+' conftest.er1 >conftest.err
22823   rm -f conftest.er1
22824   cat conftest.err >&5
22825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22826   (exit $ac_status); } && {
22827          test -z "$ac_c_werror_flag" ||
22828          test ! -s conftest.err
22829        } && test -s conftest.$ac_objext; then
22830   ac_hi=$ac_mid
22831 else
22832   echo "$as_me: failed program was:" >&5
22833 sed 's/^/| /' conftest.$ac_ext >&5
22834
22835         ac_lo=`expr '(' $ac_mid ')' + 1`
22836 fi
22837
22838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22839 done
22840 case $ac_lo in
22841 ?*) ac_cv_alignof_double=$ac_lo;;
22842 '') if test "$ac_cv_type_double" = yes; then
22843      { { echo "$as_me:$LINENO: error: cannot compute alignment of double
22844 See \`config.log' for more details." >&5
22845 echo "$as_me: error: cannot compute alignment of double
22846 See \`config.log' for more details." >&2;}
22847    { (exit 77); exit 77; }; }
22848    else
22849      ac_cv_alignof_double=0
22850    fi ;;
22851 esac
22852 else
22853   cat >conftest.$ac_ext <<_ACEOF
22854 /* confdefs.h.  */
22855 _ACEOF
22856 cat confdefs.h >>conftest.$ac_ext
22857 cat >>conftest.$ac_ext <<_ACEOF
22858 /* end confdefs.h.  */
22859 $ac_includes_default
22860 #ifndef offsetof
22861 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
22862 #endif
22863 typedef struct { char x; double y; } ac__type_alignof_;
22864 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
22865 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
22866 #include <stdio.h>
22867 #include <stdlib.h>
22868 int
22869 main ()
22870 {
22871
22872   FILE *f = fopen ("conftest.val", "w");
22873   if (! f)
22874     return 1;
22875   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
22876     {
22877       long int i = longval ();
22878       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22879         return 1;
22880       fprintf (f, "%ld\n", i);
22881     }
22882   else
22883     {
22884       unsigned long int i = ulongval ();
22885       if (i != ((long int) offsetof (ac__type_alignof_, y)))
22886         return 1;
22887       fprintf (f, "%lu\n", i);
22888     }
22889   return ferror (f) || fclose (f) != 0;
22890
22891   ;
22892   return 0;
22893 }
22894 _ACEOF
22895 rm -f conftest$ac_exeext
22896 if { (ac_try="$ac_link"
22897 case "(($ac_try" in
22898   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22899   *) ac_try_echo=$ac_try;;
22900 esac
22901 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22902   (eval "$ac_link") 2>&5
22903   ac_status=$?
22904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22905   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22906   { (case "(($ac_try" in
22907   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22908   *) ac_try_echo=$ac_try;;
22909 esac
22910 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22911   (eval "$ac_try") 2>&5
22912   ac_status=$?
22913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22914   (exit $ac_status); }; }; then
22915   ac_cv_alignof_double=`cat conftest.val`
22916 else
22917   echo "$as_me: program exited with status $ac_status" >&5
22918 echo "$as_me: failed program was:" >&5
22919 sed 's/^/| /' conftest.$ac_ext >&5
22920
22921 ( exit $ac_status )
22922 if test "$ac_cv_type_double" = yes; then
22923      { { echo "$as_me:$LINENO: error: cannot compute alignment of double
22924 See \`config.log' for more details." >&5
22925 echo "$as_me: error: cannot compute alignment of double
22926 See \`config.log' for more details." >&2;}
22927    { (exit 77); exit 77; }; }
22928    else
22929      ac_cv_alignof_double=0
22930    fi
22931 fi
22932 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22933 fi
22934 rm -f conftest.val
22935 fi
22936 { echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
22937 echo "${ECHO_T}$ac_cv_alignof_double" >&6; }
22938
22939
22940
22941 cat >>confdefs.h <<_ACEOF
22942 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
22943 _ACEOF
22944
22945
22946
22947 # Compute maximum alignment of any basic type.
22948 # We assume long's alignment is at least as strong as char, short, or int;
22949 # but we must check long long (if it exists) and double.
22950
22951 MAX_ALIGNOF=$ac_cv_alignof_long
22952 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
22953   MAX_ALIGNOF=$ac_cv_alignof_double
22954 fi
22955 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
22956   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
22957 fi
22958
22959 cat >>confdefs.h <<_ACEOF
22960 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
22961 _ACEOF
22962
22963
22964
22965 # Some platforms predefine the types int8, int16, etc.  Only check
22966 # a (hopefully) representative subset.
22967 { echo "$as_me:$LINENO: checking for int8" >&5
22968 echo $ECHO_N "checking for int8... $ECHO_C" >&6; }
22969 if test "${ac_cv_type_int8+set}" = set; then
22970   echo $ECHO_N "(cached) $ECHO_C" >&6
22971 else
22972   cat >conftest.$ac_ext <<_ACEOF
22973 /* confdefs.h.  */
22974 _ACEOF
22975 cat confdefs.h >>conftest.$ac_ext
22976 cat >>conftest.$ac_ext <<_ACEOF
22977 /* end confdefs.h.  */
22978 #include <stdio.h>
22979 #ifdef HAVE_SUPPORTDEFS_H
22980 #include <SupportDefs.h>
22981 #endif
22982
22983 typedef int8 ac__type_new_;
22984 int
22985 main ()
22986 {
22987 if ((ac__type_new_ *) 0)
22988   return 0;
22989 if (sizeof (ac__type_new_))
22990   return 0;
22991   ;
22992   return 0;
22993 }
22994 _ACEOF
22995 rm -f conftest.$ac_objext
22996 if { (ac_try="$ac_compile"
22997 case "(($ac_try" in
22998   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22999   *) ac_try_echo=$ac_try;;
23000 esac
23001 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23002   (eval "$ac_compile") 2>conftest.er1
23003   ac_status=$?
23004   grep -v '^ *+' conftest.er1 >conftest.err
23005   rm -f conftest.er1
23006   cat conftest.err >&5
23007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23008   (exit $ac_status); } && {
23009          test -z "$ac_c_werror_flag" ||
23010          test ! -s conftest.err
23011        } && test -s conftest.$ac_objext; then
23012   ac_cv_type_int8=yes
23013 else
23014   echo "$as_me: failed program was:" >&5
23015 sed 's/^/| /' conftest.$ac_ext >&5
23016
23017         ac_cv_type_int8=no
23018 fi
23019
23020 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23021 fi
23022 { echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
23023 echo "${ECHO_T}$ac_cv_type_int8" >&6; }
23024 if test $ac_cv_type_int8 = yes; then
23025
23026 cat >>confdefs.h <<_ACEOF
23027 #define HAVE_INT8 1
23028 _ACEOF
23029
23030
23031 fi
23032 { echo "$as_me:$LINENO: checking for uint8" >&5
23033 echo $ECHO_N "checking for uint8... $ECHO_C" >&6; }
23034 if test "${ac_cv_type_uint8+set}" = set; then
23035   echo $ECHO_N "(cached) $ECHO_C" >&6
23036 else
23037   cat >conftest.$ac_ext <<_ACEOF
23038 /* confdefs.h.  */
23039 _ACEOF
23040 cat confdefs.h >>conftest.$ac_ext
23041 cat >>conftest.$ac_ext <<_ACEOF
23042 /* end confdefs.h.  */
23043 #include <stdio.h>
23044 #ifdef HAVE_SUPPORTDEFS_H
23045 #include <SupportDefs.h>
23046 #endif
23047
23048 typedef uint8 ac__type_new_;
23049 int
23050 main ()
23051 {
23052 if ((ac__type_new_ *) 0)
23053   return 0;
23054 if (sizeof (ac__type_new_))
23055   return 0;
23056   ;
23057   return 0;
23058 }
23059 _ACEOF
23060 rm -f conftest.$ac_objext
23061 if { (ac_try="$ac_compile"
23062 case "(($ac_try" in
23063   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23064   *) ac_try_echo=$ac_try;;
23065 esac
23066 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23067   (eval "$ac_compile") 2>conftest.er1
23068   ac_status=$?
23069   grep -v '^ *+' conftest.er1 >conftest.err
23070   rm -f conftest.er1
23071   cat conftest.err >&5
23072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23073   (exit $ac_status); } && {
23074          test -z "$ac_c_werror_flag" ||
23075          test ! -s conftest.err
23076        } && test -s conftest.$ac_objext; then
23077   ac_cv_type_uint8=yes
23078 else
23079   echo "$as_me: failed program was:" >&5
23080 sed 's/^/| /' conftest.$ac_ext >&5
23081
23082         ac_cv_type_uint8=no
23083 fi
23084
23085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23086 fi
23087 { echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
23088 echo "${ECHO_T}$ac_cv_type_uint8" >&6; }
23089 if test $ac_cv_type_uint8 = yes; then
23090
23091 cat >>confdefs.h <<_ACEOF
23092 #define HAVE_UINT8 1
23093 _ACEOF
23094
23095
23096 fi
23097 { echo "$as_me:$LINENO: checking for int64" >&5
23098 echo $ECHO_N "checking for int64... $ECHO_C" >&6; }
23099 if test "${ac_cv_type_int64+set}" = set; then
23100   echo $ECHO_N "(cached) $ECHO_C" >&6
23101 else
23102   cat >conftest.$ac_ext <<_ACEOF
23103 /* confdefs.h.  */
23104 _ACEOF
23105 cat confdefs.h >>conftest.$ac_ext
23106 cat >>conftest.$ac_ext <<_ACEOF
23107 /* end confdefs.h.  */
23108 #include <stdio.h>
23109 #ifdef HAVE_SUPPORTDEFS_H
23110 #include <SupportDefs.h>
23111 #endif
23112
23113 typedef int64 ac__type_new_;
23114 int
23115 main ()
23116 {
23117 if ((ac__type_new_ *) 0)
23118   return 0;
23119 if (sizeof (ac__type_new_))
23120   return 0;
23121   ;
23122   return 0;
23123 }
23124 _ACEOF
23125 rm -f conftest.$ac_objext
23126 if { (ac_try="$ac_compile"
23127 case "(($ac_try" in
23128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23129   *) ac_try_echo=$ac_try;;
23130 esac
23131 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23132   (eval "$ac_compile") 2>conftest.er1
23133   ac_status=$?
23134   grep -v '^ *+' conftest.er1 >conftest.err
23135   rm -f conftest.er1
23136   cat conftest.err >&5
23137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23138   (exit $ac_status); } && {
23139          test -z "$ac_c_werror_flag" ||
23140          test ! -s conftest.err
23141        } && test -s conftest.$ac_objext; then
23142   ac_cv_type_int64=yes
23143 else
23144   echo "$as_me: failed program was:" >&5
23145 sed 's/^/| /' conftest.$ac_ext >&5
23146
23147         ac_cv_type_int64=no
23148 fi
23149
23150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23151 fi
23152 { echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
23153 echo "${ECHO_T}$ac_cv_type_int64" >&6; }
23154 if test $ac_cv_type_int64 = yes; then
23155
23156 cat >>confdefs.h <<_ACEOF
23157 #define HAVE_INT64 1
23158 _ACEOF
23159
23160
23161 fi
23162 { echo "$as_me:$LINENO: checking for uint64" >&5
23163 echo $ECHO_N "checking for uint64... $ECHO_C" >&6; }
23164 if test "${ac_cv_type_uint64+set}" = set; then
23165   echo $ECHO_N "(cached) $ECHO_C" >&6
23166 else
23167   cat >conftest.$ac_ext <<_ACEOF
23168 /* confdefs.h.  */
23169 _ACEOF
23170 cat confdefs.h >>conftest.$ac_ext
23171 cat >>conftest.$ac_ext <<_ACEOF
23172 /* end confdefs.h.  */
23173 #include <stdio.h>
23174 #ifdef HAVE_SUPPORTDEFS_H
23175 #include <SupportDefs.h>
23176 #endif
23177
23178 typedef uint64 ac__type_new_;
23179 int
23180 main ()
23181 {
23182 if ((ac__type_new_ *) 0)
23183   return 0;
23184 if (sizeof (ac__type_new_))
23185   return 0;
23186   ;
23187   return 0;
23188 }
23189 _ACEOF
23190 rm -f conftest.$ac_objext
23191 if { (ac_try="$ac_compile"
23192 case "(($ac_try" in
23193   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23194   *) ac_try_echo=$ac_try;;
23195 esac
23196 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23197   (eval "$ac_compile") 2>conftest.er1
23198   ac_status=$?
23199   grep -v '^ *+' conftest.er1 >conftest.err
23200   rm -f conftest.er1
23201   cat conftest.err >&5
23202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23203   (exit $ac_status); } && {
23204          test -z "$ac_c_werror_flag" ||
23205          test ! -s conftest.err
23206        } && test -s conftest.$ac_objext; then
23207   ac_cv_type_uint64=yes
23208 else
23209   echo "$as_me: failed program was:" >&5
23210 sed 's/^/| /' conftest.$ac_ext >&5
23211
23212         ac_cv_type_uint64=no
23213 fi
23214
23215 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23216 fi
23217 { echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
23218 echo "${ECHO_T}$ac_cv_type_uint64" >&6; }
23219 if test $ac_cv_type_uint64 = yes; then
23220
23221 cat >>confdefs.h <<_ACEOF
23222 #define HAVE_UINT64 1
23223 _ACEOF
23224
23225
23226 fi
23227
23228
23229 # We also check for sig_atomic_t, which *should* be defined per ANSI
23230 # C, but is missing on some old platforms.
23231 { echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
23232 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6; }
23233 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
23234   echo $ECHO_N "(cached) $ECHO_C" >&6
23235 else
23236   cat >conftest.$ac_ext <<_ACEOF
23237 /* confdefs.h.  */
23238 _ACEOF
23239 cat confdefs.h >>conftest.$ac_ext
23240 cat >>conftest.$ac_ext <<_ACEOF
23241 /* end confdefs.h.  */
23242 #include <signal.h>
23243
23244 typedef sig_atomic_t ac__type_new_;
23245 int
23246 main ()
23247 {
23248 if ((ac__type_new_ *) 0)
23249   return 0;
23250 if (sizeof (ac__type_new_))
23251   return 0;
23252   ;
23253   return 0;
23254 }
23255 _ACEOF
23256 rm -f conftest.$ac_objext
23257 if { (ac_try="$ac_compile"
23258 case "(($ac_try" in
23259   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23260   *) ac_try_echo=$ac_try;;
23261 esac
23262 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23263   (eval "$ac_compile") 2>conftest.er1
23264   ac_status=$?
23265   grep -v '^ *+' conftest.er1 >conftest.err
23266   rm -f conftest.er1
23267   cat conftest.err >&5
23268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23269   (exit $ac_status); } && {
23270          test -z "$ac_c_werror_flag" ||
23271          test ! -s conftest.err
23272        } && test -s conftest.$ac_objext; then
23273   ac_cv_type_sig_atomic_t=yes
23274 else
23275   echo "$as_me: failed program was:" >&5
23276 sed 's/^/| /' conftest.$ac_ext >&5
23277
23278         ac_cv_type_sig_atomic_t=no
23279 fi
23280
23281 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23282 fi
23283 { echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
23284 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6; }
23285 if test $ac_cv_type_sig_atomic_t = yes; then
23286
23287 cat >>confdefs.h <<_ACEOF
23288 #define HAVE_SIG_ATOMIC_T 1
23289 _ACEOF
23290
23291
23292 fi
23293
23294
23295
23296 if test "$PORTNAME" != "win32"
23297 then
23298 { echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
23299 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6; }
23300 if test "${pgac_cv_func_posix_signals+set}" = set; then
23301   echo $ECHO_N "(cached) $ECHO_C" >&6
23302 else
23303   cat >conftest.$ac_ext <<_ACEOF
23304 /* confdefs.h.  */
23305 _ACEOF
23306 cat confdefs.h >>conftest.$ac_ext
23307 cat >>conftest.$ac_ext <<_ACEOF
23308 /* end confdefs.h.  */
23309 #include <signal.h>
23310
23311 int
23312 main ()
23313 {
23314 struct sigaction act, oact;
23315 sigemptyset(&act.sa_mask);
23316 act.sa_flags = SA_RESTART;
23317 sigaction(0, &act, &oact);
23318   ;
23319   return 0;
23320 }
23321 _ACEOF
23322 rm -f conftest.$ac_objext conftest$ac_exeext
23323 if { (ac_try="$ac_link"
23324 case "(($ac_try" in
23325   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23326   *) ac_try_echo=$ac_try;;
23327 esac
23328 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23329   (eval "$ac_link") 2>conftest.er1
23330   ac_status=$?
23331   grep -v '^ *+' conftest.er1 >conftest.err
23332   rm -f conftest.er1
23333   cat conftest.err >&5
23334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23335   (exit $ac_status); } && {
23336          test -z "$ac_c_werror_flag" ||
23337          test ! -s conftest.err
23338        } && test -s conftest$ac_exeext &&
23339        $as_test_x conftest$ac_exeext; then
23340   pgac_cv_func_posix_signals=yes
23341 else
23342   echo "$as_me: failed program was:" >&5
23343 sed 's/^/| /' conftest.$ac_ext >&5
23344
23345         pgac_cv_func_posix_signals=no
23346 fi
23347
23348 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23349       conftest$ac_exeext conftest.$ac_ext
23350 fi
23351 { echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
23352 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6; }
23353 if test x"$pgac_cv_func_posix_signals" = xyes ; then
23354
23355 cat >>confdefs.h <<\_ACEOF
23356 #define HAVE_POSIX_SIGNALS
23357 _ACEOF
23358
23359 fi
23360 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
23361
23362 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
23363   { { echo "$as_me:$LINENO: error:
23364 Thread-safety requires POSIX signals, which are not supported by this
23365 operating system." >&5
23366 echo "$as_me: error:
23367 Thread-safety requires POSIX signals, which are not supported by this
23368 operating system." >&2;}
23369    { (exit 1); exit 1; }; }
23370 fi
23371 fi
23372
23373 if test $ac_cv_func_fseeko = yes; then
23374 # Check whether --enable-largefile was given.
23375 if test "${enable_largefile+set}" = set; then
23376   enableval=$enable_largefile;
23377 fi
23378
23379 if test "$enable_largefile" != no; then
23380
23381   { echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
23382 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6; }
23383 if test "${ac_cv_sys_largefile_CC+set}" = set; then
23384   echo $ECHO_N "(cached) $ECHO_C" >&6
23385 else
23386   ac_cv_sys_largefile_CC=no
23387      if test "$GCC" != yes; then
23388        ac_save_CC=$CC
23389        while :; do
23390          # IRIX 6.2 and later do not support large files by default,
23391          # so use the C compiler's -n32 option if that helps.
23392          cat >conftest.$ac_ext <<_ACEOF
23393 /* confdefs.h.  */
23394 _ACEOF
23395 cat confdefs.h >>conftest.$ac_ext
23396 cat >>conftest.$ac_ext <<_ACEOF
23397 /* end confdefs.h.  */
23398 #include <sys/types.h>
23399  /* Check that off_t can represent 2**63 - 1 correctly.
23400     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23401     since some C++ compilers masquerading as C compilers
23402     incorrectly reject 9223372036854775807.  */
23403 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23404   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23405                        && LARGE_OFF_T % 2147483647 == 1)
23406                       ? 1 : -1];
23407 int
23408 main ()
23409 {
23410
23411   ;
23412   return 0;
23413 }
23414 _ACEOF
23415          rm -f conftest.$ac_objext
23416 if { (ac_try="$ac_compile"
23417 case "(($ac_try" in
23418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23419   *) ac_try_echo=$ac_try;;
23420 esac
23421 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23422   (eval "$ac_compile") 2>conftest.er1
23423   ac_status=$?
23424   grep -v '^ *+' conftest.er1 >conftest.err
23425   rm -f conftest.er1
23426   cat conftest.err >&5
23427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23428   (exit $ac_status); } && {
23429          test -z "$ac_c_werror_flag" ||
23430          test ! -s conftest.err
23431        } && test -s conftest.$ac_objext; then
23432   break
23433 else
23434   echo "$as_me: failed program was:" >&5
23435 sed 's/^/| /' conftest.$ac_ext >&5
23436
23437
23438 fi
23439
23440 rm -f core conftest.err conftest.$ac_objext
23441          CC="$CC -n32"
23442          rm -f conftest.$ac_objext
23443 if { (ac_try="$ac_compile"
23444 case "(($ac_try" in
23445   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23446   *) ac_try_echo=$ac_try;;
23447 esac
23448 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23449   (eval "$ac_compile") 2>conftest.er1
23450   ac_status=$?
23451   grep -v '^ *+' conftest.er1 >conftest.err
23452   rm -f conftest.er1
23453   cat conftest.err >&5
23454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23455   (exit $ac_status); } && {
23456          test -z "$ac_c_werror_flag" ||
23457          test ! -s conftest.err
23458        } && test -s conftest.$ac_objext; then
23459   ac_cv_sys_largefile_CC=' -n32'; break
23460 else
23461   echo "$as_me: failed program was:" >&5
23462 sed 's/^/| /' conftest.$ac_ext >&5
23463
23464
23465 fi
23466
23467 rm -f core conftest.err conftest.$ac_objext
23468          break
23469        done
23470        CC=$ac_save_CC
23471        rm -f conftest.$ac_ext
23472     fi
23473 fi
23474 { echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
23475 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6; }
23476   if test "$ac_cv_sys_largefile_CC" != no; then
23477     CC=$CC$ac_cv_sys_largefile_CC
23478   fi
23479
23480   { echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
23481 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6; }
23482 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
23483   echo $ECHO_N "(cached) $ECHO_C" >&6
23484 else
23485   while :; do
23486   cat >conftest.$ac_ext <<_ACEOF
23487 /* confdefs.h.  */
23488 _ACEOF
23489 cat confdefs.h >>conftest.$ac_ext
23490 cat >>conftest.$ac_ext <<_ACEOF
23491 /* end confdefs.h.  */
23492 #include <sys/types.h>
23493  /* Check that off_t can represent 2**63 - 1 correctly.
23494     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23495     since some C++ compilers masquerading as C compilers
23496     incorrectly reject 9223372036854775807.  */
23497 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23498   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23499                        && LARGE_OFF_T % 2147483647 == 1)
23500                       ? 1 : -1];
23501 int
23502 main ()
23503 {
23504
23505   ;
23506   return 0;
23507 }
23508 _ACEOF
23509 rm -f conftest.$ac_objext
23510 if { (ac_try="$ac_compile"
23511 case "(($ac_try" in
23512   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23513   *) ac_try_echo=$ac_try;;
23514 esac
23515 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23516   (eval "$ac_compile") 2>conftest.er1
23517   ac_status=$?
23518   grep -v '^ *+' conftest.er1 >conftest.err
23519   rm -f conftest.er1
23520   cat conftest.err >&5
23521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23522   (exit $ac_status); } && {
23523          test -z "$ac_c_werror_flag" ||
23524          test ! -s conftest.err
23525        } && test -s conftest.$ac_objext; then
23526   ac_cv_sys_file_offset_bits=no; break
23527 else
23528   echo "$as_me: failed program was:" >&5
23529 sed 's/^/| /' conftest.$ac_ext >&5
23530
23531
23532 fi
23533
23534 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23535   cat >conftest.$ac_ext <<_ACEOF
23536 /* confdefs.h.  */
23537 _ACEOF
23538 cat confdefs.h >>conftest.$ac_ext
23539 cat >>conftest.$ac_ext <<_ACEOF
23540 /* end confdefs.h.  */
23541 #define _FILE_OFFSET_BITS 64
23542 #include <sys/types.h>
23543  /* Check that off_t can represent 2**63 - 1 correctly.
23544     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23545     since some C++ compilers masquerading as C compilers
23546     incorrectly reject 9223372036854775807.  */
23547 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23548   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23549                        && LARGE_OFF_T % 2147483647 == 1)
23550                       ? 1 : -1];
23551 int
23552 main ()
23553 {
23554
23555   ;
23556   return 0;
23557 }
23558 _ACEOF
23559 rm -f conftest.$ac_objext
23560 if { (ac_try="$ac_compile"
23561 case "(($ac_try" in
23562   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23563   *) ac_try_echo=$ac_try;;
23564 esac
23565 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23566   (eval "$ac_compile") 2>conftest.er1
23567   ac_status=$?
23568   grep -v '^ *+' conftest.er1 >conftest.err
23569   rm -f conftest.er1
23570   cat conftest.err >&5
23571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23572   (exit $ac_status); } && {
23573          test -z "$ac_c_werror_flag" ||
23574          test ! -s conftest.err
23575        } && test -s conftest.$ac_objext; then
23576   ac_cv_sys_file_offset_bits=64; break
23577 else
23578   echo "$as_me: failed program was:" >&5
23579 sed 's/^/| /' conftest.$ac_ext >&5
23580
23581
23582 fi
23583
23584 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23585   ac_cv_sys_file_offset_bits=unknown
23586   break
23587 done
23588 fi
23589 { echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
23590 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6; }
23591 case $ac_cv_sys_file_offset_bits in #(
23592   no | unknown) ;;
23593   *)
23594 cat >>confdefs.h <<_ACEOF
23595 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
23596 _ACEOF
23597 ;;
23598 esac
23599 rm -f conftest*
23600   if test $ac_cv_sys_file_offset_bits = unknown; then
23601     { echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
23602 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6; }
23603 if test "${ac_cv_sys_large_files+set}" = set; then
23604   echo $ECHO_N "(cached) $ECHO_C" >&6
23605 else
23606   while :; do
23607   cat >conftest.$ac_ext <<_ACEOF
23608 /* confdefs.h.  */
23609 _ACEOF
23610 cat confdefs.h >>conftest.$ac_ext
23611 cat >>conftest.$ac_ext <<_ACEOF
23612 /* end confdefs.h.  */
23613 #include <sys/types.h>
23614  /* Check that off_t can represent 2**63 - 1 correctly.
23615     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23616     since some C++ compilers masquerading as C compilers
23617     incorrectly reject 9223372036854775807.  */
23618 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23619   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23620                        && LARGE_OFF_T % 2147483647 == 1)
23621                       ? 1 : -1];
23622 int
23623 main ()
23624 {
23625
23626   ;
23627   return 0;
23628 }
23629 _ACEOF
23630 rm -f conftest.$ac_objext
23631 if { (ac_try="$ac_compile"
23632 case "(($ac_try" in
23633   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23634   *) ac_try_echo=$ac_try;;
23635 esac
23636 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23637   (eval "$ac_compile") 2>conftest.er1
23638   ac_status=$?
23639   grep -v '^ *+' conftest.er1 >conftest.err
23640   rm -f conftest.er1
23641   cat conftest.err >&5
23642   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23643   (exit $ac_status); } && {
23644          test -z "$ac_c_werror_flag" ||
23645          test ! -s conftest.err
23646        } && test -s conftest.$ac_objext; then
23647   ac_cv_sys_large_files=no; break
23648 else
23649   echo "$as_me: failed program was:" >&5
23650 sed 's/^/| /' conftest.$ac_ext >&5
23651
23652
23653 fi
23654
23655 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23656   cat >conftest.$ac_ext <<_ACEOF
23657 /* confdefs.h.  */
23658 _ACEOF
23659 cat confdefs.h >>conftest.$ac_ext
23660 cat >>conftest.$ac_ext <<_ACEOF
23661 /* end confdefs.h.  */
23662 #define _LARGE_FILES 1
23663 #include <sys/types.h>
23664  /* Check that off_t can represent 2**63 - 1 correctly.
23665     We can't simply define LARGE_OFF_T to be 9223372036854775807,
23666     since some C++ compilers masquerading as C compilers
23667     incorrectly reject 9223372036854775807.  */
23668 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
23669   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
23670                        && LARGE_OFF_T % 2147483647 == 1)
23671                       ? 1 : -1];
23672 int
23673 main ()
23674 {
23675
23676   ;
23677   return 0;
23678 }
23679 _ACEOF
23680 rm -f conftest.$ac_objext
23681 if { (ac_try="$ac_compile"
23682 case "(($ac_try" in
23683   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23684   *) ac_try_echo=$ac_try;;
23685 esac
23686 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23687   (eval "$ac_compile") 2>conftest.er1
23688   ac_status=$?
23689   grep -v '^ *+' conftest.er1 >conftest.err
23690   rm -f conftest.er1
23691   cat conftest.err >&5
23692   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23693   (exit $ac_status); } && {
23694          test -z "$ac_c_werror_flag" ||
23695          test ! -s conftest.err
23696        } && test -s conftest.$ac_objext; then
23697   ac_cv_sys_large_files=1; break
23698 else
23699   echo "$as_me: failed program was:" >&5
23700 sed 's/^/| /' conftest.$ac_ext >&5
23701
23702
23703 fi
23704
23705 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23706   ac_cv_sys_large_files=unknown
23707   break
23708 done
23709 fi
23710 { echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
23711 echo "${ECHO_T}$ac_cv_sys_large_files" >&6; }
23712 case $ac_cv_sys_large_files in #(
23713   no | unknown) ;;
23714   *)
23715 cat >>confdefs.h <<_ACEOF
23716 #define _LARGE_FILES $ac_cv_sys_large_files
23717 _ACEOF
23718 ;;
23719 esac
23720 rm -f conftest*
23721   fi
23722 fi
23723
23724 fi
23725
23726 # Check for largefile support (must be after AC_SYS_LARGEFILE)
23727 { echo "$as_me:$LINENO: checking for off_t" >&5
23728 echo $ECHO_N "checking for off_t... $ECHO_C" >&6; }
23729 if test "${ac_cv_type_off_t+set}" = set; then
23730   echo $ECHO_N "(cached) $ECHO_C" >&6
23731 else
23732   cat >conftest.$ac_ext <<_ACEOF
23733 /* confdefs.h.  */
23734 _ACEOF
23735 cat confdefs.h >>conftest.$ac_ext
23736 cat >>conftest.$ac_ext <<_ACEOF
23737 /* end confdefs.h.  */
23738 $ac_includes_default
23739 typedef off_t ac__type_new_;
23740 int
23741 main ()
23742 {
23743 if ((ac__type_new_ *) 0)
23744   return 0;
23745 if (sizeof (ac__type_new_))
23746   return 0;
23747   ;
23748   return 0;
23749 }
23750 _ACEOF
23751 rm -f conftest.$ac_objext
23752 if { (ac_try="$ac_compile"
23753 case "(($ac_try" in
23754   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23755   *) ac_try_echo=$ac_try;;
23756 esac
23757 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23758   (eval "$ac_compile") 2>conftest.er1
23759   ac_status=$?
23760   grep -v '^ *+' conftest.er1 >conftest.err
23761   rm -f conftest.er1
23762   cat conftest.err >&5
23763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23764   (exit $ac_status); } && {
23765          test -z "$ac_c_werror_flag" ||
23766          test ! -s conftest.err
23767        } && test -s conftest.$ac_objext; then
23768   ac_cv_type_off_t=yes
23769 else
23770   echo "$as_me: failed program was:" >&5
23771 sed 's/^/| /' conftest.$ac_ext >&5
23772
23773         ac_cv_type_off_t=no
23774 fi
23775
23776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23777 fi
23778 { echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
23779 echo "${ECHO_T}$ac_cv_type_off_t" >&6; }
23780
23781 # The cast to long int works around a bug in the HP C Compiler
23782 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23783 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23784 # This bug is HP SR number 8606223364.
23785 { echo "$as_me:$LINENO: checking size of off_t" >&5
23786 echo $ECHO_N "checking size of off_t... $ECHO_C" >&6; }
23787 if test "${ac_cv_sizeof_off_t+set}" = set; then
23788   echo $ECHO_N "(cached) $ECHO_C" >&6
23789 else
23790   if test "$cross_compiling" = yes; then
23791   # Depending upon the size, compute the lo and hi bounds.
23792 cat >conftest.$ac_ext <<_ACEOF
23793 /* confdefs.h.  */
23794 _ACEOF
23795 cat confdefs.h >>conftest.$ac_ext
23796 cat >>conftest.$ac_ext <<_ACEOF
23797 /* end confdefs.h.  */
23798 $ac_includes_default
23799    typedef off_t ac__type_sizeof_;
23800 int
23801 main ()
23802 {
23803 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
23804 test_array [0] = 0
23805
23806   ;
23807   return 0;
23808 }
23809 _ACEOF
23810 rm -f conftest.$ac_objext
23811 if { (ac_try="$ac_compile"
23812 case "(($ac_try" in
23813   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23814   *) ac_try_echo=$ac_try;;
23815 esac
23816 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23817   (eval "$ac_compile") 2>conftest.er1
23818   ac_status=$?
23819   grep -v '^ *+' conftest.er1 >conftest.err
23820   rm -f conftest.er1
23821   cat conftest.err >&5
23822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23823   (exit $ac_status); } && {
23824          test -z "$ac_c_werror_flag" ||
23825          test ! -s conftest.err
23826        } && test -s conftest.$ac_objext; then
23827   ac_lo=0 ac_mid=0
23828   while :; do
23829     cat >conftest.$ac_ext <<_ACEOF
23830 /* confdefs.h.  */
23831 _ACEOF
23832 cat confdefs.h >>conftest.$ac_ext
23833 cat >>conftest.$ac_ext <<_ACEOF
23834 /* end confdefs.h.  */
23835 $ac_includes_default
23836    typedef off_t ac__type_sizeof_;
23837 int
23838 main ()
23839 {
23840 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
23841 test_array [0] = 0
23842
23843   ;
23844   return 0;
23845 }
23846 _ACEOF
23847 rm -f conftest.$ac_objext
23848 if { (ac_try="$ac_compile"
23849 case "(($ac_try" in
23850   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23851   *) ac_try_echo=$ac_try;;
23852 esac
23853 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23854   (eval "$ac_compile") 2>conftest.er1
23855   ac_status=$?
23856   grep -v '^ *+' conftest.er1 >conftest.err
23857   rm -f conftest.er1
23858   cat conftest.err >&5
23859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23860   (exit $ac_status); } && {
23861          test -z "$ac_c_werror_flag" ||
23862          test ! -s conftest.err
23863        } && test -s conftest.$ac_objext; then
23864   ac_hi=$ac_mid; break
23865 else
23866   echo "$as_me: failed program was:" >&5
23867 sed 's/^/| /' conftest.$ac_ext >&5
23868
23869         ac_lo=`expr $ac_mid + 1`
23870                         if test $ac_lo -le $ac_mid; then
23871                           ac_lo= ac_hi=
23872                           break
23873                         fi
23874                         ac_mid=`expr 2 '*' $ac_mid + 1`
23875 fi
23876
23877 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23878   done
23879 else
23880   echo "$as_me: failed program was:" >&5
23881 sed 's/^/| /' conftest.$ac_ext >&5
23882
23883         cat >conftest.$ac_ext <<_ACEOF
23884 /* confdefs.h.  */
23885 _ACEOF
23886 cat confdefs.h >>conftest.$ac_ext
23887 cat >>conftest.$ac_ext <<_ACEOF
23888 /* end confdefs.h.  */
23889 $ac_includes_default
23890    typedef off_t ac__type_sizeof_;
23891 int
23892 main ()
23893 {
23894 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
23895 test_array [0] = 0
23896
23897   ;
23898   return 0;
23899 }
23900 _ACEOF
23901 rm -f conftest.$ac_objext
23902 if { (ac_try="$ac_compile"
23903 case "(($ac_try" in
23904   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23905   *) ac_try_echo=$ac_try;;
23906 esac
23907 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23908   (eval "$ac_compile") 2>conftest.er1
23909   ac_status=$?
23910   grep -v '^ *+' conftest.er1 >conftest.err
23911   rm -f conftest.er1
23912   cat conftest.err >&5
23913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23914   (exit $ac_status); } && {
23915          test -z "$ac_c_werror_flag" ||
23916          test ! -s conftest.err
23917        } && test -s conftest.$ac_objext; then
23918   ac_hi=-1 ac_mid=-1
23919   while :; do
23920     cat >conftest.$ac_ext <<_ACEOF
23921 /* confdefs.h.  */
23922 _ACEOF
23923 cat confdefs.h >>conftest.$ac_ext
23924 cat >>conftest.$ac_ext <<_ACEOF
23925 /* end confdefs.h.  */
23926 $ac_includes_default
23927    typedef off_t ac__type_sizeof_;
23928 int
23929 main ()
23930 {
23931 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
23932 test_array [0] = 0
23933
23934   ;
23935   return 0;
23936 }
23937 _ACEOF
23938 rm -f conftest.$ac_objext
23939 if { (ac_try="$ac_compile"
23940 case "(($ac_try" in
23941   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23942   *) ac_try_echo=$ac_try;;
23943 esac
23944 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23945   (eval "$ac_compile") 2>conftest.er1
23946   ac_status=$?
23947   grep -v '^ *+' conftest.er1 >conftest.err
23948   rm -f conftest.er1
23949   cat conftest.err >&5
23950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23951   (exit $ac_status); } && {
23952          test -z "$ac_c_werror_flag" ||
23953          test ! -s conftest.err
23954        } && test -s conftest.$ac_objext; then
23955   ac_lo=$ac_mid; break
23956 else
23957   echo "$as_me: failed program was:" >&5
23958 sed 's/^/| /' conftest.$ac_ext >&5
23959
23960         ac_hi=`expr '(' $ac_mid ')' - 1`
23961                         if test $ac_mid -le $ac_hi; then
23962                           ac_lo= ac_hi=
23963                           break
23964                         fi
23965                         ac_mid=`expr 2 '*' $ac_mid`
23966 fi
23967
23968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23969   done
23970 else
23971   echo "$as_me: failed program was:" >&5
23972 sed 's/^/| /' conftest.$ac_ext >&5
23973
23974         ac_lo= ac_hi=
23975 fi
23976
23977 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23978 fi
23979
23980 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23981 # Binary search between lo and hi bounds.
23982 while test "x$ac_lo" != "x$ac_hi"; do
23983   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
23984   cat >conftest.$ac_ext <<_ACEOF
23985 /* confdefs.h.  */
23986 _ACEOF
23987 cat confdefs.h >>conftest.$ac_ext
23988 cat >>conftest.$ac_ext <<_ACEOF
23989 /* end confdefs.h.  */
23990 $ac_includes_default
23991    typedef off_t ac__type_sizeof_;
23992 int
23993 main ()
23994 {
23995 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
23996 test_array [0] = 0
23997
23998   ;
23999   return 0;
24000 }
24001 _ACEOF
24002 rm -f conftest.$ac_objext
24003 if { (ac_try="$ac_compile"
24004 case "(($ac_try" in
24005   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24006   *) ac_try_echo=$ac_try;;
24007 esac
24008 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24009   (eval "$ac_compile") 2>conftest.er1
24010   ac_status=$?
24011   grep -v '^ *+' conftest.er1 >conftest.err
24012   rm -f conftest.er1
24013   cat conftest.err >&5
24014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24015   (exit $ac_status); } && {
24016          test -z "$ac_c_werror_flag" ||
24017          test ! -s conftest.err
24018        } && test -s conftest.$ac_objext; then
24019   ac_hi=$ac_mid
24020 else
24021   echo "$as_me: failed program was:" >&5
24022 sed 's/^/| /' conftest.$ac_ext >&5
24023
24024         ac_lo=`expr '(' $ac_mid ')' + 1`
24025 fi
24026
24027 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24028 done
24029 case $ac_lo in
24030 ?*) ac_cv_sizeof_off_t=$ac_lo;;
24031 '') if test "$ac_cv_type_off_t" = yes; then
24032      { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
24033 See \`config.log' for more details." >&5
24034 echo "$as_me: error: cannot compute sizeof (off_t)
24035 See \`config.log' for more details." >&2;}
24036    { (exit 77); exit 77; }; }
24037    else
24038      ac_cv_sizeof_off_t=0
24039    fi ;;
24040 esac
24041 else
24042   cat >conftest.$ac_ext <<_ACEOF
24043 /* confdefs.h.  */
24044 _ACEOF
24045 cat confdefs.h >>conftest.$ac_ext
24046 cat >>conftest.$ac_ext <<_ACEOF
24047 /* end confdefs.h.  */
24048 $ac_includes_default
24049    typedef off_t ac__type_sizeof_;
24050 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
24051 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
24052 #include <stdio.h>
24053 #include <stdlib.h>
24054 int
24055 main ()
24056 {
24057
24058   FILE *f = fopen ("conftest.val", "w");
24059   if (! f)
24060     return 1;
24061   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
24062     {
24063       long int i = longval ();
24064       if (i != ((long int) (sizeof (ac__type_sizeof_))))
24065         return 1;
24066       fprintf (f, "%ld\n", i);
24067     }
24068   else
24069     {
24070       unsigned long int i = ulongval ();
24071       if (i != ((long int) (sizeof (ac__type_sizeof_))))
24072         return 1;
24073       fprintf (f, "%lu\n", i);
24074     }
24075   return ferror (f) || fclose (f) != 0;
24076
24077   ;
24078   return 0;
24079 }
24080 _ACEOF
24081 rm -f conftest$ac_exeext
24082 if { (ac_try="$ac_link"
24083 case "(($ac_try" in
24084   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24085   *) ac_try_echo=$ac_try;;
24086 esac
24087 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24088   (eval "$ac_link") 2>&5
24089   ac_status=$?
24090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24091   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24092   { (case "(($ac_try" in
24093   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24094   *) ac_try_echo=$ac_try;;
24095 esac
24096 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24097   (eval "$ac_try") 2>&5
24098   ac_status=$?
24099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24100   (exit $ac_status); }; }; then
24101   ac_cv_sizeof_off_t=`cat conftest.val`
24102 else
24103   echo "$as_me: program exited with status $ac_status" >&5
24104 echo "$as_me: failed program was:" >&5
24105 sed 's/^/| /' conftest.$ac_ext >&5
24106
24107 ( exit $ac_status )
24108 if test "$ac_cv_type_off_t" = yes; then
24109      { { echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
24110 See \`config.log' for more details." >&5
24111 echo "$as_me: error: cannot compute sizeof (off_t)
24112 See \`config.log' for more details." >&2;}
24113    { (exit 77); exit 77; }; }
24114    else
24115      ac_cv_sizeof_off_t=0
24116    fi
24117 fi
24118 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24119 fi
24120 rm -f conftest.val
24121 fi
24122 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
24123 echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6; }
24124
24125
24126
24127 cat >>confdefs.h <<_ACEOF
24128 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
24129 _ACEOF
24130
24131
24132
24133 if test "$ac_cv_sizeof_off_t" -lt 8 -o "$enable_segmented_files" = "yes"; then
24134
24135 cat >>confdefs.h <<\_ACEOF
24136 #define USE_SEGMENTED_FILES 1
24137 _ACEOF
24138
24139 fi
24140
24141 # SunOS doesn't handle negative byte comparisons properly with +/- return
24142 { echo "$as_me:$LINENO: checking for working memcmp" >&5
24143 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6; }
24144 if test "${ac_cv_func_memcmp_working+set}" = set; then
24145   echo $ECHO_N "(cached) $ECHO_C" >&6
24146 else
24147   if test "$cross_compiling" = yes; then
24148   ac_cv_func_memcmp_working=no
24149 else
24150   cat >conftest.$ac_ext <<_ACEOF
24151 /* confdefs.h.  */
24152 _ACEOF
24153 cat confdefs.h >>conftest.$ac_ext
24154 cat >>conftest.$ac_ext <<_ACEOF
24155 /* end confdefs.h.  */
24156 $ac_includes_default
24157 int
24158 main ()
24159 {
24160
24161   /* Some versions of memcmp are not 8-bit clean.  */
24162   char c0 = '\100', c1 = '\200', c2 = '\201';
24163   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
24164     return 1;
24165
24166   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
24167      or more and with at least one buffer not starting on a 4-byte boundary.
24168      William Lewis provided this test program.   */
24169   {
24170     char foo[21];
24171     char bar[21];
24172     int i;
24173     for (i = 0; i < 4; i++)
24174       {
24175         char *a = foo + i;
24176         char *b = bar + i;
24177         strcpy (a, "--------01111111");
24178         strcpy (b, "--------10000000");
24179         if (memcmp (a, b, 16) >= 0)
24180           return 1;
24181       }
24182     return 0;
24183   }
24184
24185   ;
24186   return 0;
24187 }
24188 _ACEOF
24189 rm -f conftest$ac_exeext
24190 if { (ac_try="$ac_link"
24191 case "(($ac_try" in
24192   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24193   *) ac_try_echo=$ac_try;;
24194 esac
24195 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24196   (eval "$ac_link") 2>&5
24197   ac_status=$?
24198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24199   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24200   { (case "(($ac_try" in
24201   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24202   *) ac_try_echo=$ac_try;;
24203 esac
24204 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24205   (eval "$ac_try") 2>&5
24206   ac_status=$?
24207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24208   (exit $ac_status); }; }; then
24209   ac_cv_func_memcmp_working=yes
24210 else
24211   echo "$as_me: program exited with status $ac_status" >&5
24212 echo "$as_me: failed program was:" >&5
24213 sed 's/^/| /' conftest.$ac_ext >&5
24214
24215 ( exit $ac_status )
24216 ac_cv_func_memcmp_working=no
24217 fi
24218 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24219 fi
24220
24221
24222 fi
24223 { echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
24224 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6; }
24225 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
24226   *" memcmp.$ac_objext "* ) ;;
24227   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
24228  ;;
24229 esac
24230
24231
24232
24233
24234 # Select semaphore implementation type.
24235 if test "$PORTNAME" != "win32"; then
24236   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
24237
24238 cat >>confdefs.h <<\_ACEOF
24239 #define USE_NAMED_POSIX_SEMAPHORES 1
24240 _ACEOF
24241
24242     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
24243   else
24244     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
24245
24246 cat >>confdefs.h <<\_ACEOF
24247 #define USE_UNNAMED_POSIX_SEMAPHORES 1
24248 _ACEOF
24249
24250       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
24251     else
24252
24253 cat >>confdefs.h <<\_ACEOF
24254 #define USE_SYSV_SEMAPHORES 1
24255 _ACEOF
24256
24257       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
24258     fi
24259   fi
24260 else
24261
24262 cat >>confdefs.h <<\_ACEOF
24263 #define USE_WIN32_SEMAPHORES 1
24264 _ACEOF
24265
24266   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
24267 fi
24268
24269
24270 # Select shared-memory implementation type.
24271 if test "$PORTNAME" != "win32"; then
24272
24273 cat >>confdefs.h <<\_ACEOF
24274 #define USE_SYSV_SHARED_MEMORY 1
24275 _ACEOF
24276
24277   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
24278 else
24279
24280 cat >>confdefs.h <<\_ACEOF
24281 #define USE_WIN32_SHARED_MEMORY 1
24282 _ACEOF
24283
24284   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
24285 fi
24286
24287 # If not set in template file, set bytes to use libc memset()
24288 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
24289   MEMSET_LOOP_LIMIT=1024
24290 fi
24291
24292 cat >>confdefs.h <<_ACEOF
24293 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
24294 _ACEOF
24295
24296
24297
24298 if test "$enable_nls" = yes ; then
24299
24300   { echo "$as_me:$LINENO: checking for library containing gettext" >&5
24301 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6; }
24302 if test "${ac_cv_search_gettext+set}" = set; then
24303   echo $ECHO_N "(cached) $ECHO_C" >&6
24304 else
24305   ac_func_search_save_LIBS=$LIBS
24306 cat >conftest.$ac_ext <<_ACEOF
24307 /* confdefs.h.  */
24308 _ACEOF
24309 cat confdefs.h >>conftest.$ac_ext
24310 cat >>conftest.$ac_ext <<_ACEOF
24311 /* end confdefs.h.  */
24312
24313 /* Override any GCC internal prototype to avoid an error.
24314    Use char because int might match the return type of a GCC
24315    builtin and then its argument prototype would still apply.  */
24316 #ifdef __cplusplus
24317 extern "C"
24318 #endif
24319 char gettext ();
24320 int
24321 main ()
24322 {
24323 return gettext ();
24324   ;
24325   return 0;
24326 }
24327 _ACEOF
24328 for ac_lib in '' intl; do
24329   if test -z "$ac_lib"; then
24330     ac_res="none required"
24331   else
24332     ac_res=-l$ac_lib
24333     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24334   fi
24335   rm -f conftest.$ac_objext conftest$ac_exeext
24336 if { (ac_try="$ac_link"
24337 case "(($ac_try" in
24338   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24339   *) ac_try_echo=$ac_try;;
24340 esac
24341 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24342   (eval "$ac_link") 2>conftest.er1
24343   ac_status=$?
24344   grep -v '^ *+' conftest.er1 >conftest.err
24345   rm -f conftest.er1
24346   cat conftest.err >&5
24347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24348   (exit $ac_status); } && {
24349          test -z "$ac_c_werror_flag" ||
24350          test ! -s conftest.err
24351        } && test -s conftest$ac_exeext &&
24352        $as_test_x conftest$ac_exeext; then
24353   ac_cv_search_gettext=$ac_res
24354 else
24355   echo "$as_me: failed program was:" >&5
24356 sed 's/^/| /' conftest.$ac_ext >&5
24357
24358
24359 fi
24360
24361 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24362       conftest$ac_exeext
24363   if test "${ac_cv_search_gettext+set}" = set; then
24364   break
24365 fi
24366 done
24367 if test "${ac_cv_search_gettext+set}" = set; then
24368   :
24369 else
24370   ac_cv_search_gettext=no
24371 fi
24372 rm conftest.$ac_ext
24373 LIBS=$ac_func_search_save_LIBS
24374 fi
24375 { echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
24376 echo "${ECHO_T}$ac_cv_search_gettext" >&6; }
24377 ac_res=$ac_cv_search_gettext
24378 if test "$ac_res" != no; then
24379   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24380
24381 else
24382   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
24383 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
24384    { (exit 1); exit 1; }; }
24385 fi
24386
24387   if test "${ac_cv_header_libintl_h+set}" = set; then
24388   { echo "$as_me:$LINENO: checking for libintl.h" >&5
24389 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6; }
24390 if test "${ac_cv_header_libintl_h+set}" = set; then
24391   echo $ECHO_N "(cached) $ECHO_C" >&6
24392 fi
24393 { echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
24394 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6; }
24395 else
24396   # Is the header compilable?
24397 { echo "$as_me:$LINENO: checking libintl.h usability" >&5
24398 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6; }
24399 cat >conftest.$ac_ext <<_ACEOF
24400 /* confdefs.h.  */
24401 _ACEOF
24402 cat confdefs.h >>conftest.$ac_ext
24403 cat >>conftest.$ac_ext <<_ACEOF
24404 /* end confdefs.h.  */
24405 $ac_includes_default
24406 #include <libintl.h>
24407 _ACEOF
24408 rm -f conftest.$ac_objext
24409 if { (ac_try="$ac_compile"
24410 case "(($ac_try" in
24411   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24412   *) ac_try_echo=$ac_try;;
24413 esac
24414 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24415   (eval "$ac_compile") 2>conftest.er1
24416   ac_status=$?
24417   grep -v '^ *+' conftest.er1 >conftest.err
24418   rm -f conftest.er1
24419   cat conftest.err >&5
24420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24421   (exit $ac_status); } && {
24422          test -z "$ac_c_werror_flag" ||
24423          test ! -s conftest.err
24424        } && test -s conftest.$ac_objext; then
24425   ac_header_compiler=yes
24426 else
24427   echo "$as_me: failed program was:" >&5
24428 sed 's/^/| /' conftest.$ac_ext >&5
24429
24430         ac_header_compiler=no
24431 fi
24432
24433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24434 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24435 echo "${ECHO_T}$ac_header_compiler" >&6; }
24436
24437 # Is the header present?
24438 { echo "$as_me:$LINENO: checking libintl.h presence" >&5
24439 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6; }
24440 cat >conftest.$ac_ext <<_ACEOF
24441 /* confdefs.h.  */
24442 _ACEOF
24443 cat confdefs.h >>conftest.$ac_ext
24444 cat >>conftest.$ac_ext <<_ACEOF
24445 /* end confdefs.h.  */
24446 #include <libintl.h>
24447 _ACEOF
24448 if { (ac_try="$ac_cpp conftest.$ac_ext"
24449 case "(($ac_try" in
24450   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24451   *) ac_try_echo=$ac_try;;
24452 esac
24453 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24454   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
24455   ac_status=$?
24456   grep -v '^ *+' conftest.er1 >conftest.err
24457   rm -f conftest.er1
24458   cat conftest.err >&5
24459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24460   (exit $ac_status); } >/dev/null && {
24461          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
24462          test ! -s conftest.err
24463        }; then
24464   ac_header_preproc=yes
24465 else
24466   echo "$as_me: failed program was:" >&5
24467 sed 's/^/| /' conftest.$ac_ext >&5
24468
24469   ac_header_preproc=no
24470 fi
24471
24472 rm -f conftest.err conftest.$ac_ext
24473 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24474 echo "${ECHO_T}$ac_header_preproc" >&6; }
24475
24476 # So?  What about this header?
24477 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
24478   yes:no: )
24479     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
24480 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
24481     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
24482 echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
24483     ac_header_preproc=yes
24484     ;;
24485   no:yes:* )
24486     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
24487 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
24488     { echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
24489 echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
24490     { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
24491 echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
24492     { echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
24493 echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
24494     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
24495 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
24496     { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
24497 echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
24498     ( cat <<\_ASBOX
24499 ## ---------------------------------------- ##
24500 ## Report this to pgsql-bugs@postgresql.org ##
24501 ## ---------------------------------------- ##
24502 _ASBOX
24503      ) | sed "s/^/$as_me: WARNING:     /" >&2
24504     ;;
24505 esac
24506 { echo "$as_me:$LINENO: checking for libintl.h" >&5
24507 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6; }
24508 if test "${ac_cv_header_libintl_h+set}" = set; then
24509   echo $ECHO_N "(cached) $ECHO_C" >&6
24510 else
24511   ac_cv_header_libintl_h=$ac_header_preproc
24512 fi
24513 { echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
24514 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6; }
24515
24516 fi
24517 if test $ac_cv_header_libintl_h = yes; then
24518   :
24519 else
24520   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
24521 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
24522    { (exit 1); exit 1; }; }
24523 fi
24524
24525
24526   for ac_prog in msgfmt
24527 do
24528   # Extract the first word of "$ac_prog", so it can be a program name with args.
24529 set dummy $ac_prog; ac_word=$2
24530 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24531 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24532 if test "${ac_cv_prog_MSGFMT+set}" = set; then
24533   echo $ECHO_N "(cached) $ECHO_C" >&6
24534 else
24535   if test -n "$MSGFMT"; then
24536   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
24537 else
24538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24539 for as_dir in $PATH
24540 do
24541   IFS=$as_save_IFS
24542   test -z "$as_dir" && as_dir=.
24543   for ac_exec_ext in '' $ac_executable_extensions; do
24544   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24545     ac_cv_prog_MSGFMT="$ac_prog"
24546     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24547     break 2
24548   fi
24549 done
24550 done
24551 IFS=$as_save_IFS
24552
24553 fi
24554 fi
24555 MSGFMT=$ac_cv_prog_MSGFMT
24556 if test -n "$MSGFMT"; then
24557   { echo "$as_me:$LINENO: result: $MSGFMT" >&5
24558 echo "${ECHO_T}$MSGFMT" >&6; }
24559 else
24560   { echo "$as_me:$LINENO: result: no" >&5
24561 echo "${ECHO_T}no" >&6; }
24562 fi
24563
24564
24565   test -n "$MSGFMT" && break
24566 done
24567
24568   if test -z "$MSGFMT"; then
24569     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
24570 echo "$as_me: error: msgfmt is required for NLS" >&2;}
24571    { (exit 1); exit 1; }; }
24572   fi
24573   for ac_prog in msgmerge
24574 do
24575   # Extract the first word of "$ac_prog", so it can be a program name with args.
24576 set dummy $ac_prog; ac_word=$2
24577 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24578 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24579 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
24580   echo $ECHO_N "(cached) $ECHO_C" >&6
24581 else
24582   if test -n "$MSGMERGE"; then
24583   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
24584 else
24585 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24586 for as_dir in $PATH
24587 do
24588   IFS=$as_save_IFS
24589   test -z "$as_dir" && as_dir=.
24590   for ac_exec_ext in '' $ac_executable_extensions; do
24591   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24592     ac_cv_prog_MSGMERGE="$ac_prog"
24593     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24594     break 2
24595   fi
24596 done
24597 done
24598 IFS=$as_save_IFS
24599
24600 fi
24601 fi
24602 MSGMERGE=$ac_cv_prog_MSGMERGE
24603 if test -n "$MSGMERGE"; then
24604   { echo "$as_me:$LINENO: result: $MSGMERGE" >&5
24605 echo "${ECHO_T}$MSGMERGE" >&6; }
24606 else
24607   { echo "$as_me:$LINENO: result: no" >&5
24608 echo "${ECHO_T}no" >&6; }
24609 fi
24610
24611
24612   test -n "$MSGMERGE" && break
24613 done
24614
24615   for ac_prog in xgettext
24616 do
24617   # Extract the first word of "$ac_prog", so it can be a program name with args.
24618 set dummy $ac_prog; ac_word=$2
24619 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24620 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24621 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
24622   echo $ECHO_N "(cached) $ECHO_C" >&6
24623 else
24624   if test -n "$XGETTEXT"; then
24625   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
24626 else
24627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24628 for as_dir in $PATH
24629 do
24630   IFS=$as_save_IFS
24631   test -z "$as_dir" && as_dir=.
24632   for ac_exec_ext in '' $ac_executable_extensions; do
24633   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24634     ac_cv_prog_XGETTEXT="$ac_prog"
24635     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24636     break 2
24637   fi
24638 done
24639 done
24640 IFS=$as_save_IFS
24641
24642 fi
24643 fi
24644 XGETTEXT=$ac_cv_prog_XGETTEXT
24645 if test -n "$XGETTEXT"; then
24646   { echo "$as_me:$LINENO: result: $XGETTEXT" >&5
24647 echo "${ECHO_T}$XGETTEXT" >&6; }
24648 else
24649   { echo "$as_me:$LINENO: result: no" >&5
24650 echo "${ECHO_T}no" >&6; }
24651 fi
24652
24653
24654   test -n "$XGETTEXT" && break
24655 done
24656
24657
24658 fi
24659
24660 # Check for Tcl configuration script tclConfig.sh
24661 if test "$with_tcl" = yes; then
24662     for ac_prog in tclsh tcl
24663 do
24664   # Extract the first word of "$ac_prog", so it can be a program name with args.
24665 set dummy $ac_prog; ac_word=$2
24666 { echo "$as_me:$LINENO: checking for $ac_word" >&5
24667 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
24668 if test "${ac_cv_path_TCLSH+set}" = set; then
24669   echo $ECHO_N "(cached) $ECHO_C" >&6
24670 else
24671   case $TCLSH in
24672   [\\/]* | ?:[\\/]*)
24673   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
24674   ;;
24675   *)
24676   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24677 for as_dir in $PATH
24678 do
24679   IFS=$as_save_IFS
24680   test -z "$as_dir" && as_dir=.
24681   for ac_exec_ext in '' $ac_executable_extensions; do
24682   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24683     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
24684     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
24685     break 2
24686   fi
24687 done
24688 done
24689 IFS=$as_save_IFS
24690
24691   ;;
24692 esac
24693 fi
24694 TCLSH=$ac_cv_path_TCLSH
24695 if test -n "$TCLSH"; then
24696   { echo "$as_me:$LINENO: result: $TCLSH" >&5
24697 echo "${ECHO_T}$TCLSH" >&6; }
24698 else
24699   { echo "$as_me:$LINENO: result: no" >&5
24700 echo "${ECHO_T}no" >&6; }
24701 fi
24702
24703
24704   test -n "$TCLSH" && break
24705 done
24706
24707 { echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
24708 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6; }
24709 # Let user override test
24710 if test -z "$TCL_CONFIG_SH"; then
24711     pgac_test_dirs="$with_tclconfig"
24712
24713     set X $pgac_test_dirs; shift
24714     if test $# -eq 0; then
24715         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
24716 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
24717    { (exit 1); exit 1; }; }
24718         set X `echo 'puts $auto_path' | $TCLSH`; shift
24719     fi
24720
24721     for pgac_dir do
24722         if test -r "$pgac_dir/tclConfig.sh"; then
24723             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
24724             break
24725         fi
24726     done
24727 fi
24728
24729 if test -z "$TCL_CONFIG_SH"; then
24730     { echo "$as_me:$LINENO: result: no" >&5
24731 echo "${ECHO_T}no" >&6; }
24732     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
24733 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
24734    { (exit 1); exit 1; }; }
24735 else
24736     { echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
24737 echo "${ECHO_T}$TCL_CONFIG_SH" >&6; }
24738 fi
24739
24740
24741
24742     . "$TCL_CONFIG_SH"
24743 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
24744 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
24745 eval TCL_LIBS=\"$TCL_LIBS\"
24746 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
24747 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
24748
24749         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
24750     ac_save_CPPFLAGS=$CPPFLAGS
24751     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
24752     if test "${ac_cv_header_tcl_h+set}" = set; then
24753   { echo "$as_me:$LINENO: checking for tcl.h" >&5
24754 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6; }
24755 if test "${ac_cv_header_tcl_h+set}" = set; then
24756   echo $ECHO_N "(cached) $ECHO_C" >&6
24757 fi
24758 { echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
24759 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6; }
24760 else
24761   # Is the header compilable?
24762 { echo "$as_me:$LINENO: checking tcl.h usability" >&5
24763 echo $ECHO_N "checking tcl.h usability... $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 $ac_includes_default
24771 #include <tcl.h>
24772 _ACEOF
24773 rm -f conftest.$ac_objext
24774 if { (ac_try="$ac_compile"
24775 case "(($ac_try" in
24776   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24777   *) ac_try_echo=$ac_try;;
24778 esac
24779 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24780   (eval "$ac_compile") 2>conftest.er1
24781   ac_status=$?
24782   grep -v '^ *+' conftest.er1 >conftest.err
24783   rm -f conftest.er1
24784   cat conftest.err >&5
24785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24786   (exit $ac_status); } && {
24787          test -z "$ac_c_werror_flag" ||
24788          test ! -s conftest.err
24789        } && test -s conftest.$ac_objext; then
24790   ac_header_compiler=yes
24791 else
24792   echo "$as_me: failed program was:" >&5
24793 sed 's/^/| /' conftest.$ac_ext >&5
24794
24795         ac_header_compiler=no
24796 fi
24797
24798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24799 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
24800 echo "${ECHO_T}$ac_header_compiler" >&6; }
24801
24802 # Is the header present?
24803 { echo "$as_me:$LINENO: checking tcl.h presence" >&5
24804 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6; }
24805 cat >conftest.$ac_ext <<_ACEOF
24806 /* confdefs.h.  */
24807 _ACEOF
24808 cat confdefs.h >>conftest.$ac_ext
24809 cat >>conftest.$ac_ext <<_ACEOF
24810 /* end confdefs.h.  */
24811 #include <tcl.h>
24812 _ACEOF
24813 if { (ac_try="$ac_cpp conftest.$ac_ext"
24814 case "(($ac_try" in
24815   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24816   *) ac_try_echo=$ac_try;;
24817 esac
24818 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24819   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
24820   ac_status=$?
24821   grep -v '^ *+' conftest.er1 >conftest.err
24822   rm -f conftest.er1
24823   cat conftest.err >&5
24824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
24825   (exit $ac_status); } >/dev/null && {
24826          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
24827          test ! -s conftest.err
24828        }; then
24829   ac_header_preproc=yes
24830 else
24831   echo "$as_me: failed program was:" >&5
24832 sed 's/^/| /' conftest.$ac_ext >&5
24833
24834   ac_header_preproc=no
24835 fi
24836
24837 rm -f conftest.err conftest.$ac_ext
24838 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
24839 echo "${ECHO_T}$ac_header_preproc" >&6; }
24840
24841 # So?  What about this header?
24842 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
24843   yes:no: )
24844     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
24845 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
24846     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
24847 echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
24848     ac_header_preproc=yes
24849     ;;
24850   no:yes:* )
24851     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
24852 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
24853     { echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
24854 echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
24855     { echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
24856 echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
24857     { echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
24858 echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
24859     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
24860 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
24861     { echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
24862 echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
24863     ( cat <<\_ASBOX
24864 ## ---------------------------------------- ##
24865 ## Report this to pgsql-bugs@postgresql.org ##
24866 ## ---------------------------------------- ##
24867 _ASBOX
24868      ) | sed "s/^/$as_me: WARNING:     /" >&2
24869     ;;
24870 esac
24871 { echo "$as_me:$LINENO: checking for tcl.h" >&5
24872 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6; }
24873 if test "${ac_cv_header_tcl_h+set}" = set; then
24874   echo $ECHO_N "(cached) $ECHO_C" >&6
24875 else
24876   ac_cv_header_tcl_h=$ac_header_preproc
24877 fi
24878 { echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
24879 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6; }
24880
24881 fi
24882 if test $ac_cv_header_tcl_h = yes; then
24883   :
24884 else
24885   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
24886 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
24887    { (exit 1); exit 1; }; }
24888 fi
24889
24890
24891     CPPFLAGS=$ac_save_CPPFLAGS
24892 fi
24893
24894 #
24895 # Check for DocBook and tools
24896 #
24897 for ac_prog in onsgmls nsgmls
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_NSGMLS+set}" = set; then
24904   echo $ECHO_N "(cached) $ECHO_C" >&6
24905 else
24906   if test -n "$NSGMLS"; then
24907   ac_cv_prog_NSGMLS="$NSGMLS" # 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_NSGMLS="$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 NSGMLS=$ac_cv_prog_NSGMLS
24927 if test -n "$NSGMLS"; then
24928   { echo "$as_me:$LINENO: result: $NSGMLS" >&5
24929 echo "${ECHO_T}$NSGMLS" >&6; }
24930 else
24931   { echo "$as_me:$LINENO: result: no" >&5
24932 echo "${ECHO_T}no" >&6; }
24933 fi
24934
24935
24936   test -n "$NSGMLS" && break
24937 done
24938
24939 for ac_prog in openjade jade
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_JADE+set}" = set; then
24946   echo $ECHO_N "(cached) $ECHO_C" >&6
24947 else
24948   if test -n "$JADE"; then
24949   ac_cv_prog_JADE="$JADE" # 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_JADE="$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 JADE=$ac_cv_prog_JADE
24969 if test -n "$JADE"; then
24970   { echo "$as_me:$LINENO: result: $JADE" >&5
24971 echo "${ECHO_T}$JADE" >&6; }
24972 else
24973   { echo "$as_me:$LINENO: result: no" >&5
24974 echo "${ECHO_T}no" >&6; }
24975 fi
24976
24977
24978   test -n "$JADE" && break
24979 done
24980
24981
24982 { echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
24983 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6; }
24984 if test "${pgac_cv_check_docbook+set}" = set; then
24985   echo $ECHO_N "(cached) $ECHO_C" >&6
24986 else
24987   cat >conftest.sgml <<EOF
24988 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
24989 <book>
24990  <title>test</title>
24991  <chapter>
24992   <title>random</title>
24993    <sect1>
24994     <title>testsect</title>
24995     <para>text</para>
24996   </sect1>
24997  </chapter>
24998 </book>
24999 EOF
25000
25001 pgac_cv_check_docbook=no
25002
25003 if test -n "$NSGMLS"; then
25004   $NSGMLS -s conftest.sgml 1>&5 2>&1
25005   if test $? -eq 0; then
25006     pgac_cv_check_docbook=yes
25007   fi
25008 fi
25009 rm -f conftest.sgml
25010 fi
25011 { echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
25012 echo "${ECHO_T}$pgac_cv_check_docbook" >&6; }
25013
25014 have_docbook=$pgac_cv_check_docbook
25015
25016
25017 { echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
25018 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6; }
25019 if test "${pgac_cv_path_stylesheets+set}" = set; then
25020   echo $ECHO_N "(cached) $ECHO_C" >&6
25021 else
25022   if test -n "$DOCBOOKSTYLE"; then
25023   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
25024 else
25025   for pgac_prefix in /usr /usr/local /opt; do
25026     for pgac_infix in share lib; do
25027       for pgac_postfix in \
25028         sgml/stylesheets/nwalsh-modular \
25029         sgml/stylesheets/docbook \
25030         sgml/stylesheets/dsssl/docbook \
25031         sgml/docbook-dsssl \
25032         sgml/docbook/dsssl/modular \
25033         sgml/docbook/stylesheet/dsssl/modular \
25034         sgml/docbook/dsssl-stylesheets
25035       do
25036         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
25037         if test -r "$pgac_candidate/html/docbook.dsl" \
25038            && test -r "$pgac_candidate/print/docbook.dsl"
25039         then
25040           pgac_cv_path_stylesheets=$pgac_candidate
25041           break 3
25042         fi
25043       done
25044     done
25045   done
25046 fi
25047 fi
25048
25049 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
25050
25051 if test -n "$DOCBOOKSTYLE"; then
25052   { echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
25053 echo "${ECHO_T}$DOCBOOKSTYLE" >&6; }
25054 else
25055   { echo "$as_me:$LINENO: result: no" >&5
25056 echo "${ECHO_T}no" >&6; }
25057 fi
25058 if test -n "$DOCBOOKSTYLE"; then
25059   for ac_prog in collateindex.pl
25060 do
25061   # Extract the first word of "$ac_prog", so it can be a program name with args.
25062 set dummy $ac_prog; ac_word=$2
25063 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25064 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25065 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
25066   echo $ECHO_N "(cached) $ECHO_C" >&6
25067 else
25068   case $COLLATEINDEX in
25069   [\\/]* | ?:[\\/]*)
25070   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
25071   ;;
25072   *)
25073   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25074 for as_dir in $DOCBOOKSTYLE/bin $PATH
25075 do
25076   IFS=$as_save_IFS
25077   test -z "$as_dir" && as_dir=.
25078   for ac_exec_ext in '' $ac_executable_extensions; do
25079   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25080     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
25081     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25082     break 2
25083   fi
25084 done
25085 done
25086 IFS=$as_save_IFS
25087
25088   ;;
25089 esac
25090 fi
25091 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
25092 if test -n "$COLLATEINDEX"; then
25093   { echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
25094 echo "${ECHO_T}$COLLATEINDEX" >&6; }
25095 else
25096   { echo "$as_me:$LINENO: result: no" >&5
25097 echo "${ECHO_T}no" >&6; }
25098 fi
25099
25100
25101   test -n "$COLLATEINDEX" && break
25102 done
25103
25104 else
25105   for ac_prog in collateindex.pl
25106 do
25107   # Extract the first word of "$ac_prog", so it can be a program name with args.
25108 set dummy $ac_prog; ac_word=$2
25109 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25110 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25111 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
25112   echo $ECHO_N "(cached) $ECHO_C" >&6
25113 else
25114   case $COLLATEINDEX in
25115   [\\/]* | ?:[\\/]*)
25116   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
25117   ;;
25118   *)
25119   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25120 for as_dir in $PATH
25121 do
25122   IFS=$as_save_IFS
25123   test -z "$as_dir" && as_dir=.
25124   for ac_exec_ext in '' $ac_executable_extensions; do
25125   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25126     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
25127     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25128     break 2
25129   fi
25130 done
25131 done
25132 IFS=$as_save_IFS
25133
25134   ;;
25135 esac
25136 fi
25137 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
25138 if test -n "$COLLATEINDEX"; then
25139   { echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
25140 echo "${ECHO_T}$COLLATEINDEX" >&6; }
25141 else
25142   { echo "$as_me:$LINENO: result: no" >&5
25143 echo "${ECHO_T}no" >&6; }
25144 fi
25145
25146
25147   test -n "$COLLATEINDEX" && break
25148 done
25149
25150 fi
25151 for ac_prog in sgmlspl
25152 do
25153   # Extract the first word of "$ac_prog", so it can be a program name with args.
25154 set dummy $ac_prog; ac_word=$2
25155 { echo "$as_me:$LINENO: checking for $ac_word" >&5
25156 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
25157 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
25158   echo $ECHO_N "(cached) $ECHO_C" >&6
25159 else
25160   if test -n "$SGMLSPL"; then
25161   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
25162 else
25163 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25164 for as_dir in $PATH
25165 do
25166   IFS=$as_save_IFS
25167   test -z "$as_dir" && as_dir=.
25168   for ac_exec_ext in '' $ac_executable_extensions; do
25169   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
25170     ac_cv_prog_SGMLSPL="$ac_prog"
25171     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
25172     break 2
25173   fi
25174 done
25175 done
25176 IFS=$as_save_IFS
25177
25178 fi
25179 fi
25180 SGMLSPL=$ac_cv_prog_SGMLSPL
25181 if test -n "$SGMLSPL"; then
25182   { echo "$as_me:$LINENO: result: $SGMLSPL" >&5
25183 echo "${ECHO_T}$SGMLSPL" >&6; }
25184 else
25185   { echo "$as_me:$LINENO: result: no" >&5
25186 echo "${ECHO_T}no" >&6; }
25187 fi
25188
25189
25190   test -n "$SGMLSPL" && break
25191 done
25192
25193
25194 # Thread testing
25195
25196 # We have to run the thread test near the end so we have all our symbols
25197 # defined.  Cross compiling throws a warning.
25198 #
25199 if test "$enable_thread_safety_force" = yes; then
25200 if test "$PORTNAME" != "win32"
25201 then
25202   { echo "$as_me:$LINENO: WARNING:
25203 *** Skipping thread test program.  --enable-thread-safety-force was used.
25204 *** Run the program in src/test/thread on the your machine and add proper
25205 *** locking function calls to your applications to guarantee thread safety.
25206 " >&5
25207 echo "$as_me: WARNING:
25208 *** Skipping thread test program.  --enable-thread-safety-force was used.
25209 *** Run the program in src/test/thread on the your machine and add proper
25210 *** locking function calls to your applications to guarantee thread safety.
25211 " >&2;}
25212 else
25213 { echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
25214 echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
25215 fi
25216 elif test "$enable_thread_safety" = yes; then
25217 if test "$PORTNAME" != "win32"
25218 then
25219 { echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
25220 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6; }
25221
25222 _CFLAGS="$CFLAGS"
25223 _LIBS="$LIBS"
25224 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
25225 LIBS="$LIBS $PTHREAD_LIBS"
25226 if test "$cross_compiling" = yes; then
25227   { echo "$as_me:$LINENO: result: maybe" >&5
25228 echo "${ECHO_T}maybe" >&6; }
25229   { echo "$as_me:$LINENO: WARNING:
25230 *** Skipping thread test program because of cross-compile build.
25231 *** Run the program in src/test/thread on the target machine.
25232 " >&5
25233 echo "$as_me: WARNING:
25234 *** Skipping thread test program because of cross-compile build.
25235 *** Run the program in src/test/thread on the target machine.
25236 " >&2;}
25237 else
25238   cat >conftest.$ac_ext <<_ACEOF
25239 /* confdefs.h.  */
25240 _ACEOF
25241 cat confdefs.h >>conftest.$ac_ext
25242 cat >>conftest.$ac_ext <<_ACEOF
25243 /* end confdefs.h.  */
25244 #include "$srcdir/src/test/thread/thread_test.c"
25245 _ACEOF
25246 rm -f conftest$ac_exeext
25247 if { (ac_try="$ac_link"
25248 case "(($ac_try" in
25249   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25250   *) ac_try_echo=$ac_try;;
25251 esac
25252 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25253   (eval "$ac_link") 2>&5
25254   ac_status=$?
25255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25256   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25257   { (case "(($ac_try" in
25258   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25259   *) ac_try_echo=$ac_try;;
25260 esac
25261 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25262   (eval "$ac_try") 2>&5
25263   ac_status=$?
25264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25265   (exit $ac_status); }; }; then
25266   { echo "$as_me:$LINENO: result: yes" >&5
25267 echo "${ECHO_T}yes" >&6; }
25268 else
25269   echo "$as_me: program exited with status $ac_status" >&5
25270 echo "$as_me: failed program was:" >&5
25271 sed 's/^/| /' conftest.$ac_ext >&5
25272
25273 ( exit $ac_status )
25274 { echo "$as_me:$LINENO: result: no" >&5
25275 echo "${ECHO_T}no" >&6; }
25276   { { echo "$as_me:$LINENO: error: thread test program failed
25277 This platform is not thread-safe.  Check the file 'config.log'for the
25278 exact reason.
25279
25280 You can use the configure option --enable-thread-safety-force to force
25281 threads to be enabled.  But you must then run the program in
25282 src/test/thread and add locking function calls to your applications to
25283 guarantee thread safety." >&5
25284 echo "$as_me: error: thread test program failed
25285 This platform is not thread-safe.  Check the file 'config.log'for the
25286 exact reason.
25287
25288 You can use the configure option --enable-thread-safety-force to force
25289 threads to be enabled.  But you must then run the program in
25290 src/test/thread and add locking function calls to your applications to
25291 guarantee thread safety." >&2;}
25292    { (exit 1); exit 1; }; }
25293 fi
25294 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25295 fi
25296
25297
25298 CFLAGS="$_CFLAGS"
25299 LIBS="$_LIBS"
25300 else
25301 { echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
25302 echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
25303 fi
25304 fi
25305
25306 # prepare build tree if outside source tree
25307 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
25308 # Note 2: /bin/pwd might be better than shell's built-in at getting
25309 #         a symlink-free name.
25310 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
25311   vpath_build=no
25312 else
25313   vpath_build=yes
25314   if test "$no_create" != yes; then
25315     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
25316     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
25317     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
25318       || { { echo "$as_me:$LINENO: error: failed" >&5
25319 echo "$as_me: error: failed" >&2;}
25320    { (exit 1); exit 1; }; }
25321     { echo "$as_me:$LINENO: result: done" >&5
25322 echo "${ECHO_T}done" >&6; }
25323   fi
25324 fi
25325
25326
25327
25328 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
25329
25330
25331 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}"
25332
25333
25334 if test "$PORTNAME" = "win32"; then
25335 ac_config_commands="$ac_config_commands check_win32_symlinks"
25336
25337 fi
25338
25339 ac_config_headers="$ac_config_headers src/include/pg_config.h"
25340
25341
25342 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
25343
25344
25345 cat >confcache <<\_ACEOF
25346 # This file is a shell script that caches the results of configure
25347 # tests run on this system so they can be shared between configure
25348 # scripts and configure runs, see configure's option --config-cache.
25349 # It is not useful on other systems.  If it contains results you don't
25350 # want to keep, you may remove or edit it.
25351 #
25352 # config.status only pays attention to the cache file if you give it
25353 # the --recheck option to rerun configure.
25354 #
25355 # `ac_cv_env_foo' variables (set or unset) will be overridden when
25356 # loading this file, other *unset* `ac_cv_foo' will be assigned the
25357 # following values.
25358
25359 _ACEOF
25360
25361 # The following way of writing the cache mishandles newlines in values,
25362 # but we know of no workaround that is simple, portable, and efficient.
25363 # So, we kill variables containing newlines.
25364 # Ultrix sh set writes to stderr and can't be redirected directly,
25365 # and sets the high bit in the cache file unless we assign to the vars.
25366 (
25367   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
25368     eval ac_val=\$$ac_var
25369     case $ac_val in #(
25370     *${as_nl}*)
25371       case $ac_var in #(
25372       *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
25373 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
25374       esac
25375       case $ac_var in #(
25376       _ | IFS | as_nl) ;; #(
25377       *) $as_unset $ac_var ;;
25378       esac ;;
25379     esac
25380   done
25381
25382   (set) 2>&1 |
25383     case $as_nl`(ac_space=' '; set) 2>&1` in #(
25384     *${as_nl}ac_space=\ *)
25385       # `set' does not quote correctly, so add quotes (double-quote
25386       # substitution turns \\\\ into \\, and sed turns \\ into \).
25387       sed -n \
25388         "s/'/'\\\\''/g;
25389           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
25390       ;; #(
25391     *)
25392       # `set' quotes correctly as required by POSIX, so do not add quotes.
25393       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
25394       ;;
25395     esac |
25396     sort
25397 ) |
25398   sed '
25399      /^ac_cv_env_/b end
25400      t clear
25401      :clear
25402      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
25403      t end
25404      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
25405      :end' >>confcache
25406 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
25407   if test -w "$cache_file"; then
25408     test "x$cache_file" != "x/dev/null" &&
25409       { echo "$as_me:$LINENO: updating cache $cache_file" >&5
25410 echo "$as_me: updating cache $cache_file" >&6;}
25411     cat confcache >$cache_file
25412   else
25413     { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
25414 echo "$as_me: not updating unwritable cache $cache_file" >&6;}
25415   fi
25416 fi
25417 rm -f confcache
25418
25419 test "x$prefix" = xNONE && prefix=$ac_default_prefix
25420 # Let make expand exec_prefix.
25421 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
25422
25423 DEFS=-DHAVE_CONFIG_H
25424
25425 ac_libobjs=
25426 ac_ltlibobjs=
25427 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
25428   # 1. Remove the extension, and $U if already installed.
25429   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
25430   ac_i=`echo "$ac_i" | sed "$ac_script"`
25431   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
25432   #    will be set to the directory where LIBOBJS objects are built.
25433   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
25434   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
25435 done
25436 LIBOBJS=$ac_libobjs
25437
25438 LTLIBOBJS=$ac_ltlibobjs
25439
25440
25441
25442 : ${CONFIG_STATUS=./config.status}
25443 ac_clean_files_save=$ac_clean_files
25444 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
25445 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
25446 echo "$as_me: creating $CONFIG_STATUS" >&6;}
25447 cat >$CONFIG_STATUS <<_ACEOF
25448 #! $SHELL
25449 # Generated by $as_me.
25450 # Run this file to recreate the current configuration.
25451 # Compiler output produced by configure, useful for debugging
25452 # configure, is in config.log if it exists.
25453
25454 debug=false
25455 ac_cs_recheck=false
25456 ac_cs_silent=false
25457 SHELL=\${CONFIG_SHELL-$SHELL}
25458 _ACEOF
25459
25460 cat >>$CONFIG_STATUS <<\_ACEOF
25461 ## --------------------- ##
25462 ## M4sh Initialization.  ##
25463 ## --------------------- ##
25464
25465 # Be more Bourne compatible
25466 DUALCASE=1; export DUALCASE # for MKS sh
25467 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
25468   emulate sh
25469   NULLCMD=:
25470   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
25471   # is contrary to our usage.  Disable this feature.
25472   alias -g '${1+"$@"}'='"$@"'
25473   setopt NO_GLOB_SUBST
25474 else
25475   case `(set -o) 2>/dev/null` in
25476   *posix*) set -o posix ;;
25477 esac
25478
25479 fi
25480
25481
25482
25483
25484 # PATH needs CR
25485 # Avoid depending upon Character Ranges.
25486 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
25487 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
25488 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
25489 as_cr_digits='0123456789'
25490 as_cr_alnum=$as_cr_Letters$as_cr_digits
25491
25492 # The user is always right.
25493 if test "${PATH_SEPARATOR+set}" != set; then
25494   echo "#! /bin/sh" >conf$$.sh
25495   echo  "exit 0"   >>conf$$.sh
25496   chmod +x conf$$.sh
25497   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
25498     PATH_SEPARATOR=';'
25499   else
25500     PATH_SEPARATOR=:
25501   fi
25502   rm -f conf$$.sh
25503 fi
25504
25505 # Support unset when possible.
25506 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
25507   as_unset=unset
25508 else
25509   as_unset=false
25510 fi
25511
25512
25513 # IFS
25514 # We need space, tab and new line, in precisely that order.  Quoting is
25515 # there to prevent editors from complaining about space-tab.
25516 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
25517 # splitting by setting IFS to empty value.)
25518 as_nl='
25519 '
25520 IFS=" ""        $as_nl"
25521
25522 # Find who we are.  Look in the path if we contain no directory separator.
25523 case $0 in
25524   *[\\/]* ) as_myself=$0 ;;
25525   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25526 for as_dir in $PATH
25527 do
25528   IFS=$as_save_IFS
25529   test -z "$as_dir" && as_dir=.
25530   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
25531 done
25532 IFS=$as_save_IFS
25533
25534      ;;
25535 esac
25536 # We did not find ourselves, most probably we were run as `sh COMMAND'
25537 # in which case we are not to be found in the path.
25538 if test "x$as_myself" = x; then
25539   as_myself=$0
25540 fi
25541 if test ! -f "$as_myself"; then
25542   echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
25543   { (exit 1); exit 1; }
25544 fi
25545
25546 # Work around bugs in pre-3.0 UWIN ksh.
25547 for as_var in ENV MAIL MAILPATH
25548 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
25549 done
25550 PS1='$ '
25551 PS2='> '
25552 PS4='+ '
25553
25554 # NLS nuisances.
25555 for as_var in \
25556   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
25557   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
25558   LC_TELEPHONE LC_TIME
25559 do
25560   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
25561     eval $as_var=C; export $as_var
25562   else
25563     ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
25564   fi
25565 done
25566
25567 # Required to use basename.
25568 if expr a : '\(a\)' >/dev/null 2>&1 &&
25569    test "X`expr 00001 : '.*\(...\)'`" = X001; then
25570   as_expr=expr
25571 else
25572   as_expr=false
25573 fi
25574
25575 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
25576   as_basename=basename
25577 else
25578   as_basename=false
25579 fi
25580
25581
25582 # Name of the executable.
25583 as_me=`$as_basename -- "$0" ||
25584 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
25585          X"$0" : 'X\(//\)$' \| \
25586          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
25587 echo X/"$0" |
25588     sed '/^.*\/\([^/][^/]*\)\/*$/{
25589             s//\1/
25590             q
25591           }
25592           /^X\/\(\/\/\)$/{
25593             s//\1/
25594             q
25595           }
25596           /^X\/\(\/\).*/{
25597             s//\1/
25598             q
25599           }
25600           s/.*/./; q'`
25601
25602 # CDPATH.
25603 $as_unset CDPATH
25604
25605
25606
25607   as_lineno_1=$LINENO
25608   as_lineno_2=$LINENO
25609   test "x$as_lineno_1" != "x$as_lineno_2" &&
25610   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
25611
25612   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
25613   # uniformly replaced by the line number.  The first 'sed' inserts a
25614   # line-number line after each line using $LINENO; the second 'sed'
25615   # does the real work.  The second script uses 'N' to pair each
25616   # line-number line with the line containing $LINENO, and appends
25617   # trailing '-' during substitution so that $LINENO is not a special
25618   # case at line end.
25619   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
25620   # scripts with optimization help from Paolo Bonzini.  Blame Lee
25621   # E. McMahon (1931-1989) for sed's syntax.  :-)
25622   sed -n '
25623     p
25624     /[$]LINENO/=
25625   ' <$as_myself |
25626     sed '
25627       s/[$]LINENO.*/&-/
25628       t lineno
25629       b
25630       :lineno
25631       N
25632       :loop
25633       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
25634       t loop
25635       s/-\n.*//
25636     ' >$as_me.lineno &&
25637   chmod +x "$as_me.lineno" ||
25638     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
25639    { (exit 1); exit 1; }; }
25640
25641   # Don't try to exec as it changes $[0], causing all sort of problems
25642   # (the dirname of $[0] is not the place where we might find the
25643   # original and so on.  Autoconf is especially sensitive to this).
25644   . "./$as_me.lineno"
25645   # Exit status is that of the last command.
25646   exit
25647 }
25648
25649
25650 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
25651   as_dirname=dirname
25652 else
25653   as_dirname=false
25654 fi
25655
25656 ECHO_C= ECHO_N= ECHO_T=
25657 case `echo -n x` in
25658 -n*)
25659   case `echo 'x\c'` in
25660   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
25661   *)   ECHO_C='\c';;
25662   esac;;
25663 *)
25664   ECHO_N='-n';;
25665 esac
25666
25667 if expr a : '\(a\)' >/dev/null 2>&1 &&
25668    test "X`expr 00001 : '.*\(...\)'`" = X001; then
25669   as_expr=expr
25670 else
25671   as_expr=false
25672 fi
25673
25674 rm -f conf$$ conf$$.exe conf$$.file
25675 if test -d conf$$.dir; then
25676   rm -f conf$$.dir/conf$$.file
25677 else
25678   rm -f conf$$.dir
25679   mkdir conf$$.dir
25680 fi
25681 echo >conf$$.file
25682 if ln -s conf$$.file conf$$ 2>/dev/null; then
25683   as_ln_s='ln -s'
25684   # ... but there are two gotchas:
25685   # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
25686   # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
25687   # In both cases, we have to default to `cp -p'.
25688   ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
25689     as_ln_s='cp -p'
25690 elif ln conf$$.file conf$$ 2>/dev/null; then
25691   as_ln_s=ln
25692 else
25693   as_ln_s='cp -p'
25694 fi
25695 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
25696 rmdir conf$$.dir 2>/dev/null
25697
25698 if mkdir -p . 2>/dev/null; then
25699   as_mkdir_p=:
25700 else
25701   test -d ./-p && rmdir ./-p
25702   as_mkdir_p=false
25703 fi
25704
25705 if test -x / >/dev/null 2>&1; then
25706   as_test_x='test -x'
25707 else
25708   if ls -dL / >/dev/null 2>&1; then
25709     as_ls_L_option=L
25710   else
25711     as_ls_L_option=
25712   fi
25713   as_test_x='
25714     eval sh -c '\''
25715       if test -d "$1"; then
25716         test -d "$1/.";
25717       else
25718         case $1 in
25719         -*)set "./$1";;
25720         esac;
25721         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
25722         ???[sx]*):;;*)false;;esac;fi
25723     '\'' sh
25724   '
25725 fi
25726 as_executable_p=$as_test_x
25727
25728 # Sed expression to map a string onto a valid CPP name.
25729 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
25730
25731 # Sed expression to map a string onto a valid variable name.
25732 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
25733
25734
25735 exec 6>&1
25736
25737 # Save the log message, to keep $[0] and so on meaningful, and to
25738 # report actual input values of CONFIG_FILES etc. instead of their
25739 # values after options handling.
25740 ac_log="
25741 This file was extended by PostgreSQL $as_me 8.4devel, which was
25742 generated by GNU Autoconf 2.61.  Invocation command line was
25743
25744   CONFIG_FILES    = $CONFIG_FILES
25745   CONFIG_HEADERS  = $CONFIG_HEADERS
25746   CONFIG_LINKS    = $CONFIG_LINKS
25747   CONFIG_COMMANDS = $CONFIG_COMMANDS
25748   $ $0 $@
25749
25750 on `(hostname || uname -n) 2>/dev/null | sed 1q`
25751 "
25752
25753 _ACEOF
25754
25755 cat >>$CONFIG_STATUS <<_ACEOF
25756 # Files that config.status was made for.
25757 config_files="$ac_config_files"
25758 config_headers="$ac_config_headers"
25759 config_links="$ac_config_links"
25760 config_commands="$ac_config_commands"
25761
25762 _ACEOF
25763
25764 cat >>$CONFIG_STATUS <<\_ACEOF
25765 ac_cs_usage="\
25766 \`$as_me' instantiates files from templates according to the
25767 current configuration.
25768
25769 Usage: $0 [OPTIONS] [FILE]...
25770
25771   -h, --help       print this help, then exit
25772   -V, --version    print version number and configuration settings, then exit
25773   -q, --quiet      do not print progress messages
25774   -d, --debug      don't remove temporary files
25775       --recheck    update $as_me by reconfiguring in the same conditions
25776   --file=FILE[:TEMPLATE]
25777                    instantiate the configuration file FILE
25778   --header=FILE[:TEMPLATE]
25779                    instantiate the configuration header FILE
25780
25781 Configuration files:
25782 $config_files
25783
25784 Configuration headers:
25785 $config_headers
25786
25787 Configuration links:
25788 $config_links
25789
25790 Configuration commands:
25791 $config_commands
25792
25793 Report bugs to <bug-autoconf@gnu.org>."
25794
25795 _ACEOF
25796 cat >>$CONFIG_STATUS <<_ACEOF
25797 ac_cs_version="\\
25798 PostgreSQL config.status 8.4devel
25799 configured by $0, generated by GNU Autoconf 2.61,
25800   with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
25801
25802 Copyright (C) 2006 Free Software Foundation, Inc.
25803 This config.status script is free software; the Free Software Foundation
25804 gives unlimited permission to copy, distribute and modify it."
25805
25806 ac_pwd='$ac_pwd'
25807 srcdir='$srcdir'
25808 _ACEOF
25809
25810 cat >>$CONFIG_STATUS <<\_ACEOF
25811 # If no file are specified by the user, then we need to provide default
25812 # value.  By we need to know if files were specified by the user.
25813 ac_need_defaults=:
25814 while test $# != 0
25815 do
25816   case $1 in
25817   --*=*)
25818     ac_option=`expr "X$1" : 'X\([^=]*\)='`
25819     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
25820     ac_shift=:
25821     ;;
25822   *)
25823     ac_option=$1
25824     ac_optarg=$2
25825     ac_shift=shift
25826     ;;
25827   esac
25828
25829   case $ac_option in
25830   # Handling of the options.
25831   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25832     ac_cs_recheck=: ;;
25833   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
25834     echo "$ac_cs_version"; exit ;;
25835   --debug | --debu | --deb | --de | --d | -d )
25836     debug=: ;;
25837   --file | --fil | --fi | --f )
25838     $ac_shift
25839     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
25840     ac_need_defaults=false;;
25841   --header | --heade | --head | --hea )
25842     $ac_shift
25843     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
25844     ac_need_defaults=false;;
25845   --he | --h)
25846     # Conflict between --help and --header
25847     { echo "$as_me: error: ambiguous option: $1
25848 Try \`$0 --help' for more information." >&2
25849    { (exit 1); exit 1; }; };;
25850   --help | --hel | -h )
25851     echo "$ac_cs_usage"; exit ;;
25852   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25853   | -silent | --silent | --silen | --sile | --sil | --si | --s)
25854     ac_cs_silent=: ;;
25855
25856   # This is an error.
25857   -*) { echo "$as_me: error: unrecognized option: $1
25858 Try \`$0 --help' for more information." >&2
25859    { (exit 1); exit 1; }; } ;;
25860
25861   *) ac_config_targets="$ac_config_targets $1"
25862      ac_need_defaults=false ;;
25863
25864   esac
25865   shift
25866 done
25867
25868 ac_configure_extra_args=
25869
25870 if $ac_cs_silent; then
25871   exec 6>/dev/null
25872   ac_configure_extra_args="$ac_configure_extra_args --silent"
25873 fi
25874
25875 _ACEOF
25876 cat >>$CONFIG_STATUS <<_ACEOF
25877 if \$ac_cs_recheck; then
25878   echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
25879   CONFIG_SHELL=$SHELL
25880   export CONFIG_SHELL
25881   exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
25882 fi
25883
25884 _ACEOF
25885 cat >>$CONFIG_STATUS <<\_ACEOF
25886 exec 5>>config.log
25887 {
25888   echo
25889   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25890 ## Running $as_me. ##
25891 _ASBOX
25892   echo "$ac_log"
25893 } >&5
25894
25895 _ACEOF
25896 cat >>$CONFIG_STATUS <<_ACEOF
25897 _ACEOF
25898
25899 cat >>$CONFIG_STATUS <<\_ACEOF
25900
25901 # Handling of arguments.
25902 for ac_config_target in $ac_config_targets
25903 do
25904   case $ac_config_target in
25905     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
25906     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
25907     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
25908     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
25909     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
25910     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
25911     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
25912     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
25913     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
25914     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
25915     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
25916     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
25917
25918   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
25919 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
25920    { (exit 1); exit 1; }; };;
25921   esac
25922 done
25923
25924
25925 # If the user did not use the arguments to specify the items to instantiate,
25926 # then the envvar interface is used.  Set only those that are not.
25927 # We use the long form for the default assignment because of an extremely
25928 # bizarre bug on SunOS 4.1.3.
25929 if $ac_need_defaults; then
25930   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25931   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25932   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
25933   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25934 fi
25935
25936 # Have a temporary directory for convenience.  Make it in the build tree
25937 # simply because there is no reason against having it here, and in addition,
25938 # creating and moving files from /tmp can sometimes cause problems.
25939 # Hook for its removal unless debugging.
25940 # Note that there is a small window in which the directory will not be cleaned:
25941 # after its creation but before its name has been assigned to `$tmp'.
25942 $debug ||
25943 {
25944   tmp=
25945   trap 'exit_status=$?
25946   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25947 ' 0
25948   trap '{ (exit 1); exit 1; }' 1 2 13 15
25949 }
25950 # Create a (secure) tmp directory for tmp files.
25951
25952 {
25953   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25954   test -n "$tmp" && test -d "$tmp"
25955 }  ||
25956 {
25957   tmp=./conf$$-$RANDOM
25958   (umask 077 && mkdir "$tmp")
25959 } ||
25960 {
25961    echo "$me: cannot create a temporary directory in ." >&2
25962    { (exit 1); exit 1; }
25963 }
25964
25965 #
25966 # Set up the sed scripts for CONFIG_FILES section.
25967 #
25968
25969 # No need to generate the scripts if there are no CONFIG_FILES.
25970 # This happens for instance when ./config.status config.h
25971 if test -n "$CONFIG_FILES"; then
25972
25973 _ACEOF
25974
25975
25976
25977 ac_delim='%!_!# '
25978 for ac_last_try in false false false false false :; do
25979   cat >conf$$subs.sed <<_ACEOF
25980 SHELL!$SHELL$ac_delim
25981 PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
25982 PACKAGE_NAME!$PACKAGE_NAME$ac_delim
25983 PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
25984 PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
25985 PACKAGE_STRING!$PACKAGE_STRING$ac_delim
25986 PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
25987 exec_prefix!$exec_prefix$ac_delim
25988 prefix!$prefix$ac_delim
25989 program_transform_name!$program_transform_name$ac_delim
25990 bindir!$bindir$ac_delim
25991 sbindir!$sbindir$ac_delim
25992 libexecdir!$libexecdir$ac_delim
25993 datarootdir!$datarootdir$ac_delim
25994 datadir!$datadir$ac_delim
25995 sysconfdir!$sysconfdir$ac_delim
25996 sharedstatedir!$sharedstatedir$ac_delim
25997 localstatedir!$localstatedir$ac_delim
25998 includedir!$includedir$ac_delim
25999 oldincludedir!$oldincludedir$ac_delim
26000 docdir!$docdir$ac_delim
26001 infodir!$infodir$ac_delim
26002 htmldir!$htmldir$ac_delim
26003 dvidir!$dvidir$ac_delim
26004 pdfdir!$pdfdir$ac_delim
26005 psdir!$psdir$ac_delim
26006 libdir!$libdir$ac_delim
26007 localedir!$localedir$ac_delim
26008 mandir!$mandir$ac_delim
26009 DEFS!$DEFS$ac_delim
26010 ECHO_C!$ECHO_C$ac_delim
26011 ECHO_N!$ECHO_N$ac_delim
26012 ECHO_T!$ECHO_T$ac_delim
26013 LIBS!$LIBS$ac_delim
26014 build_alias!$build_alias$ac_delim
26015 host_alias!$host_alias$ac_delim
26016 target_alias!$target_alias$ac_delim
26017 configure_args!$configure_args$ac_delim
26018 build!$build$ac_delim
26019 build_cpu!$build_cpu$ac_delim
26020 build_vendor!$build_vendor$ac_delim
26021 build_os!$build_os$ac_delim
26022 host!$host$ac_delim
26023 host_cpu!$host_cpu$ac_delim
26024 host_vendor!$host_vendor$ac_delim
26025 host_os!$host_os$ac_delim
26026 PORTNAME!$PORTNAME$ac_delim
26027 enable_nls!$enable_nls$ac_delim
26028 WANTED_LANGUAGES!$WANTED_LANGUAGES$ac_delim
26029 default_port!$default_port$ac_delim
26030 enable_shared!$enable_shared$ac_delim
26031 enable_rpath!$enable_rpath$ac_delim
26032 enable_debug!$enable_debug$ac_delim
26033 enable_profiling!$enable_profiling$ac_delim
26034 DTRACE!$DTRACE$ac_delim
26035 DTRACEFLAGS!$DTRACEFLAGS$ac_delim
26036 enable_dtrace!$enable_dtrace$ac_delim
26037 CC!$CC$ac_delim
26038 CFLAGS!$CFLAGS$ac_delim
26039 LDFLAGS!$LDFLAGS$ac_delim
26040 CPPFLAGS!$CPPFLAGS$ac_delim
26041 ac_ct_CC!$ac_ct_CC$ac_delim
26042 EXEEXT!$EXEEXT$ac_delim
26043 OBJEXT!$OBJEXT$ac_delim
26044 CPP!$CPP$ac_delim
26045 GCC!$GCC$ac_delim
26046 TAS!$TAS$ac_delim
26047 autodepend!$autodepend$ac_delim
26048 INCLUDES!$INCLUDES$ac_delim
26049 enable_thread_safety!$enable_thread_safety$ac_delim
26050 with_tcl!$with_tcl$ac_delim
26051 with_perl!$with_perl$ac_delim
26052 with_python!$with_python$ac_delim
26053 with_gssapi!$with_gssapi$ac_delim
26054 with_krb5!$with_krb5$ac_delim
26055 krb_srvtab!$krb_srvtab$ac_delim
26056 with_pam!$with_pam$ac_delim
26057 with_ldap!$with_ldap$ac_delim
26058 with_bonjour!$with_bonjour$ac_delim
26059 with_openssl!$with_openssl$ac_delim
26060 with_ossp_uuid!$with_ossp_uuid$ac_delim
26061 XML2_CONFIG!$XML2_CONFIG$ac_delim
26062 with_libxml!$with_libxml$ac_delim
26063 with_libxslt!$with_libxslt$ac_delim
26064 with_system_tzdata!$with_system_tzdata$ac_delim
26065 with_zlib!$with_zlib$ac_delim
26066 GREP!$GREP$ac_delim
26067 EGREP!$EGREP$ac_delim
26068 ELF_SYS!$ELF_SYS$ac_delim
26069 LDFLAGS_SL!$LDFLAGS_SL$ac_delim
26070 LD!$LD$ac_delim
26071 with_gnu_ld!$with_gnu_ld$ac_delim
26072 ld_R_works!$ld_R_works$ac_delim
26073 RANLIB!$RANLIB$ac_delim
26074 STRIP!$STRIP$ac_delim
26075 STRIP_STATIC_LIB!$STRIP_STATIC_LIB$ac_delim
26076 STRIP_SHARED_LIB!$STRIP_SHARED_LIB$ac_delim
26077 _ACEOF
26078
26079   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
26080     break
26081   elif $ac_last_try; then
26082     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26083 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
26084    { (exit 1); exit 1; }; }
26085   else
26086     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26087   fi
26088 done
26089
26090 ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
26091 if test -n "$ac_eof"; then
26092   ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
26093   ac_eof=`expr $ac_eof + 1`
26094 fi
26095
26096 cat >>$CONFIG_STATUS <<_ACEOF
26097 cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
26098 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
26099 _ACEOF
26100 sed '
26101 s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
26102 s/^/s,@/; s/!/@,|#_!!_#|/
26103 :n
26104 t n
26105 s/'"$ac_delim"'$/,g/; t
26106 s/$/\\/; p
26107 N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
26108 ' >>$CONFIG_STATUS <conf$$subs.sed
26109 rm -f conf$$subs.sed
26110 cat >>$CONFIG_STATUS <<_ACEOF
26111 CEOF$ac_eof
26112 _ACEOF
26113
26114
26115 ac_delim='%!_!# '
26116 for ac_last_try in false false false false false :; do
26117   cat >conf$$subs.sed <<_ACEOF
26118 TAR!$TAR$ac_delim
26119 LN_S!$LN_S$ac_delim
26120 AWK!$AWK$ac_delim
26121 YACC!$YACC$ac_delim
26122 YFLAGS!$YFLAGS$ac_delim
26123 FLEX!$FLEX$ac_delim
26124 FLEXFLAGS!$FLEXFLAGS$ac_delim
26125 PERL!$PERL$ac_delim
26126 perl_archlibexp!$perl_archlibexp$ac_delim
26127 perl_privlibexp!$perl_privlibexp$ac_delim
26128 perl_useshrplib!$perl_useshrplib$ac_delim
26129 perl_embed_ldflags!$perl_embed_ldflags$ac_delim
26130 PYTHON!$PYTHON$ac_delim
26131 python_version!$python_version$ac_delim
26132 python_configdir!$python_configdir$ac_delim
26133 python_includespec!$python_includespec$ac_delim
26134 python_libdir!$python_libdir$ac_delim
26135 python_libspec!$python_libspec$ac_delim
26136 python_additional_libs!$python_additional_libs$ac_delim
26137 OSSP_UUID_LIBS!$OSSP_UUID_LIBS$ac_delim
26138 HAVE_IPV6!$HAVE_IPV6$ac_delim
26139 LIBOBJS!$LIBOBJS$ac_delim
26140 acx_pthread_config!$acx_pthread_config$ac_delim
26141 PTHREAD_CC!$PTHREAD_CC$ac_delim
26142 PTHREAD_LIBS!$PTHREAD_LIBS$ac_delim
26143 PTHREAD_CFLAGS!$PTHREAD_CFLAGS$ac_delim
26144 LDAP_LIBS_FE!$LDAP_LIBS_FE$ac_delim
26145 LDAP_LIBS_BE!$LDAP_LIBS_BE$ac_delim
26146 HAVE_POSIX_SIGNALS!$HAVE_POSIX_SIGNALS$ac_delim
26147 MSGFMT!$MSGFMT$ac_delim
26148 MSGMERGE!$MSGMERGE$ac_delim
26149 XGETTEXT!$XGETTEXT$ac_delim
26150 TCLSH!$TCLSH$ac_delim
26151 TCL_CONFIG_SH!$TCL_CONFIG_SH$ac_delim
26152 TCL_INCLUDE_SPEC!$TCL_INCLUDE_SPEC$ac_delim
26153 TCL_LIB_FILE!$TCL_LIB_FILE$ac_delim
26154 TCL_LIBS!$TCL_LIBS$ac_delim
26155 TCL_LIB_SPEC!$TCL_LIB_SPEC$ac_delim
26156 TCL_SHARED_BUILD!$TCL_SHARED_BUILD$ac_delim
26157 TCL_SHLIB_LD_LIBS!$TCL_SHLIB_LD_LIBS$ac_delim
26158 NSGMLS!$NSGMLS$ac_delim
26159 JADE!$JADE$ac_delim
26160 have_docbook!$have_docbook$ac_delim
26161 DOCBOOKSTYLE!$DOCBOOKSTYLE$ac_delim
26162 COLLATEINDEX!$COLLATEINDEX$ac_delim
26163 SGMLSPL!$SGMLSPL$ac_delim
26164 vpath_build!$vpath_build$ac_delim
26165 LTLIBOBJS!$LTLIBOBJS$ac_delim
26166 _ACEOF
26167
26168   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 48; then
26169     break
26170   elif $ac_last_try; then
26171     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26172 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
26173    { (exit 1); exit 1; }; }
26174   else
26175     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26176   fi
26177 done
26178
26179 ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
26180 if test -n "$ac_eof"; then
26181   ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
26182   ac_eof=`expr $ac_eof + 1`
26183 fi
26184
26185 cat >>$CONFIG_STATUS <<_ACEOF
26186 cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
26187 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
26188 _ACEOF
26189 sed '
26190 s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
26191 s/^/s,@/; s/!/@,|#_!!_#|/
26192 :n
26193 t n
26194 s/'"$ac_delim"'$/,g/; t
26195 s/$/\\/; p
26196 N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
26197 ' >>$CONFIG_STATUS <conf$$subs.sed
26198 rm -f conf$$subs.sed
26199 cat >>$CONFIG_STATUS <<_ACEOF
26200 :end
26201 s/|#_!!_#|//g
26202 CEOF$ac_eof
26203 _ACEOF
26204
26205
26206 # VPATH may cause trouble with some makes, so we remove $(srcdir),
26207 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
26208 # trailing colons and then remove the whole line if VPATH becomes empty
26209 # (actually we leave an empty line to preserve line numbers).
26210 if test "x$srcdir" = x.; then
26211   ac_vpsub='/^[  ]*VPATH[        ]*=/{
26212 s/:*\$(srcdir):*/:/
26213 s/:*\${srcdir}:*/:/
26214 s/:*@srcdir@:*/:/
26215 s/^\([^=]*=[     ]*\):*/\1/
26216 s/:*$//
26217 s/^[^=]*=[       ]*$//
26218 }'
26219 fi
26220
26221 cat >>$CONFIG_STATUS <<\_ACEOF
26222 fi # test -n "$CONFIG_FILES"
26223
26224
26225 for ac_tag in  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS
26226 do
26227   case $ac_tag in
26228   :[FHLC]) ac_mode=$ac_tag; continue;;
26229   esac
26230   case $ac_mode$ac_tag in
26231   :[FHL]*:*);;
26232   :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
26233 echo "$as_me: error: Invalid tag $ac_tag." >&2;}
26234    { (exit 1); exit 1; }; };;
26235   :[FH]-) ac_tag=-:-;;
26236   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
26237   esac
26238   ac_save_IFS=$IFS
26239   IFS=:
26240   set x $ac_tag
26241   IFS=$ac_save_IFS
26242   shift
26243   ac_file=$1
26244   shift
26245
26246   case $ac_mode in
26247   :L) ac_source=$1;;
26248   :[FH])
26249     ac_file_inputs=
26250     for ac_f
26251     do
26252       case $ac_f in
26253       -) ac_f="$tmp/stdin";;
26254       *) # Look for the file first in the build tree, then in the source tree
26255          # (if the path is not absolute).  The absolute path cannot be DOS-style,
26256          # because $ac_f cannot contain `:'.
26257          test -f "$ac_f" ||
26258            case $ac_f in
26259            [\\/$]*) false;;
26260            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
26261            esac ||
26262            { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
26263 echo "$as_me: error: cannot find input file: $ac_f" >&2;}
26264    { (exit 1); exit 1; }; };;
26265       esac
26266       ac_file_inputs="$ac_file_inputs $ac_f"
26267     done
26268
26269     # Let's still pretend it is `configure' which instantiates (i.e., don't
26270     # use $as_me), people would be surprised to read:
26271     #    /* config.h.  Generated by config.status.  */
26272     configure_input="Generated from "`IFS=:
26273           echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
26274     if test x"$ac_file" != x-; then
26275       configure_input="$ac_file.  $configure_input"
26276       { echo "$as_me:$LINENO: creating $ac_file" >&5
26277 echo "$as_me: creating $ac_file" >&6;}
26278     fi
26279
26280     case $ac_tag in
26281     *:-:* | *:-) cat >"$tmp/stdin";;
26282     esac
26283     ;;
26284   esac
26285
26286   ac_dir=`$as_dirname -- "$ac_file" ||
26287 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26288          X"$ac_file" : 'X\(//\)[^/]' \| \
26289          X"$ac_file" : 'X\(//\)$' \| \
26290          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
26291 echo X"$ac_file" |
26292     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26293             s//\1/
26294             q
26295           }
26296           /^X\(\/\/\)[^/].*/{
26297             s//\1/
26298             q
26299           }
26300           /^X\(\/\/\)$/{
26301             s//\1/
26302             q
26303           }
26304           /^X\(\/\).*/{
26305             s//\1/
26306             q
26307           }
26308           s/.*/./; q'`
26309   { as_dir="$ac_dir"
26310   case $as_dir in #(
26311   -*) as_dir=./$as_dir;;
26312   esac
26313   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
26314     as_dirs=
26315     while :; do
26316       case $as_dir in #(
26317       *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
26318       *) as_qdir=$as_dir;;
26319       esac
26320       as_dirs="'$as_qdir' $as_dirs"
26321       as_dir=`$as_dirname -- "$as_dir" ||
26322 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26323          X"$as_dir" : 'X\(//\)[^/]' \| \
26324          X"$as_dir" : 'X\(//\)$' \| \
26325          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
26326 echo X"$as_dir" |
26327     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26328             s//\1/
26329             q
26330           }
26331           /^X\(\/\/\)[^/].*/{
26332             s//\1/
26333             q
26334           }
26335           /^X\(\/\/\)$/{
26336             s//\1/
26337             q
26338           }
26339           /^X\(\/\).*/{
26340             s//\1/
26341             q
26342           }
26343           s/.*/./; q'`
26344       test -d "$as_dir" && break
26345     done
26346     test -z "$as_dirs" || eval "mkdir $as_dirs"
26347   } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
26348 echo "$as_me: error: cannot create directory $as_dir" >&2;}
26349    { (exit 1); exit 1; }; }; }
26350   ac_builddir=.
26351
26352 case "$ac_dir" in
26353 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
26354 *)
26355   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
26356   # A ".." for each directory in $ac_dir_suffix.
26357   ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
26358   case $ac_top_builddir_sub in
26359   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
26360   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
26361   esac ;;
26362 esac
26363 ac_abs_top_builddir=$ac_pwd
26364 ac_abs_builddir=$ac_pwd$ac_dir_suffix
26365 # for backward compatibility:
26366 ac_top_builddir=$ac_top_build_prefix
26367
26368 case $srcdir in
26369   .)  # We are building in place.
26370     ac_srcdir=.
26371     ac_top_srcdir=$ac_top_builddir_sub
26372     ac_abs_top_srcdir=$ac_pwd ;;
26373   [\\/]* | ?:[\\/]* )  # Absolute name.
26374     ac_srcdir=$srcdir$ac_dir_suffix;
26375     ac_top_srcdir=$srcdir
26376     ac_abs_top_srcdir=$srcdir ;;
26377   *) # Relative name.
26378     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
26379     ac_top_srcdir=$ac_top_build_prefix$srcdir
26380     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
26381 esac
26382 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
26383
26384
26385   case $ac_mode in
26386   :F)
26387   #
26388   # CONFIG_FILE
26389   #
26390
26391 _ACEOF
26392
26393 cat >>$CONFIG_STATUS <<\_ACEOF
26394 # If the template does not know about datarootdir, expand it.
26395 # FIXME: This hack should be removed a few years after 2.60.
26396 ac_datarootdir_hack=; ac_datarootdir_seen=
26397
26398 case `sed -n '/datarootdir/ {
26399   p
26400   q
26401 }
26402 /@datadir@/p
26403 /@docdir@/p
26404 /@infodir@/p
26405 /@localedir@/p
26406 /@mandir@/p
26407 ' $ac_file_inputs` in
26408 *datarootdir*) ac_datarootdir_seen=yes;;
26409 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
26410   { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
26411 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
26412 _ACEOF
26413 cat >>$CONFIG_STATUS <<_ACEOF
26414   ac_datarootdir_hack='
26415   s&@datadir@&$datadir&g
26416   s&@docdir@&$docdir&g
26417   s&@infodir@&$infodir&g
26418   s&@localedir@&$localedir&g
26419   s&@mandir@&$mandir&g
26420     s&\\\${datarootdir}&$datarootdir&g' ;;
26421 esac
26422 _ACEOF
26423
26424 # Neutralize VPATH when `$srcdir' = `.'.
26425 # Shell code in configure.ac might set extrasub.
26426 # FIXME: do we really want to maintain this feature?
26427 cat >>$CONFIG_STATUS <<_ACEOF
26428   sed "$ac_vpsub
26429 $extrasub
26430 _ACEOF
26431 cat >>$CONFIG_STATUS <<\_ACEOF
26432 :t
26433 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
26434 s&@configure_input@&$configure_input&;t t
26435 s&@top_builddir@&$ac_top_builddir_sub&;t t
26436 s&@srcdir@&$ac_srcdir&;t t
26437 s&@abs_srcdir@&$ac_abs_srcdir&;t t
26438 s&@top_srcdir@&$ac_top_srcdir&;t t
26439 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
26440 s&@builddir@&$ac_builddir&;t t
26441 s&@abs_builddir@&$ac_abs_builddir&;t t
26442 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
26443 $ac_datarootdir_hack
26444 " $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
26445
26446 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
26447   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
26448   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
26449   { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26450 which seems to be undefined.  Please make sure it is defined." >&5
26451 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26452 which seems to be undefined.  Please make sure it is defined." >&2;}
26453
26454   rm -f "$tmp/stdin"
26455   case $ac_file in
26456   -) cat "$tmp/out"; rm -f "$tmp/out";;
26457   *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
26458   esac
26459  ;;
26460   :H)
26461   #
26462   # CONFIG_HEADER
26463   #
26464 _ACEOF
26465
26466 # Transform confdefs.h into a sed script `conftest.defines', that
26467 # substitutes the proper values into config.h.in to produce config.h.
26468 rm -f conftest.defines conftest.tail
26469 # First, append a space to every undef/define line, to ease matching.
26470 echo 's/$/ /' >conftest.defines
26471 # Then, protect against being on the right side of a sed subst, or in
26472 # an unquoted here document, in config.status.  If some macros were
26473 # called several times there might be several #defines for the same
26474 # symbol, which is useless.  But do not sort them, since the last
26475 # AC_DEFINE must be honored.
26476 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
26477 # These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
26478 # NAME is the cpp macro being defined, VALUE is the value it is being given.
26479 # PARAMS is the parameter list in the macro definition--in most cases, it's
26480 # just an empty string.
26481 ac_dA='s,^\\([   #]*\\)[^        ]*\\([  ]*'
26482 ac_dB='\\)[      (].*,\\1define\\2'
26483 ac_dC=' '
26484 ac_dD=' ,'
26485
26486 uniq confdefs.h |
26487   sed -n '
26488         t rset
26489         :rset
26490         s/^[     ]*#[    ]*define[       ][      ]*//
26491         t ok
26492         d
26493         :ok
26494         s/[\\&,]/\\&/g
26495         s/^\('"$ac_word_re"'\)\(([^()]*)\)[      ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
26496         s/^\('"$ac_word_re"'\)[  ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
26497   ' >>conftest.defines
26498
26499 # Remove the space that was appended to ease matching.
26500 # Then replace #undef with comments.  This is necessary, for
26501 # example, in the case of _POSIX_SOURCE, which is predefined and required
26502 # on some systems where configure will not decide to define it.
26503 # (The regexp can be short, since the line contains either #define or #undef.)
26504 echo 's/ $//
26505 s,^[     #]*u.*,/* & */,' >>conftest.defines
26506
26507 # Break up conftest.defines:
26508 ac_max_sed_lines=50
26509
26510 # First sed command is:  sed -f defines.sed $ac_file_inputs >"$tmp/out1"
26511 # Second one is:         sed -f defines.sed "$tmp/out1" >"$tmp/out2"
26512 # Third one will be:     sed -f defines.sed "$tmp/out2" >"$tmp/out1"
26513 # et cetera.
26514 ac_in='$ac_file_inputs'
26515 ac_out='"$tmp/out1"'
26516 ac_nxt='"$tmp/out2"'
26517
26518 while :
26519 do
26520   # Write a here document:
26521     cat >>$CONFIG_STATUS <<_ACEOF
26522     # First, check the format of the line:
26523     cat >"\$tmp/defines.sed" <<\\CEOF
26524 /^[      ]*#[    ]*undef[        ][      ]*$ac_word_re[  ]*\$/b def
26525 /^[      ]*#[    ]*define[       ][      ]*$ac_word_re[(         ]/b def
26526 b
26527 :def
26528 _ACEOF
26529   sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
26530   echo 'CEOF
26531     sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
26532   ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
26533   sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
26534   grep . conftest.tail >/dev/null || break
26535   rm -f conftest.defines
26536   mv conftest.tail conftest.defines
26537 done
26538 rm -f conftest.defines conftest.tail
26539
26540 echo "ac_result=$ac_in" >>$CONFIG_STATUS
26541 cat >>$CONFIG_STATUS <<\_ACEOF
26542   if test x"$ac_file" != x-; then
26543     echo "/* $configure_input  */" >"$tmp/config.h"
26544     cat "$ac_result" >>"$tmp/config.h"
26545     if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
26546       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
26547 echo "$as_me: $ac_file is unchanged" >&6;}
26548     else
26549       rm -f $ac_file
26550       mv "$tmp/config.h" $ac_file
26551     fi
26552   else
26553     echo "/* $configure_input  */"
26554     cat "$ac_result"
26555   fi
26556   rm -f "$tmp/out12"
26557  ;;
26558   :L)
26559   #
26560   # CONFIG_LINK
26561   #
26562
26563   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_file" >&5
26564 echo "$as_me: linking $srcdir/$ac_source to $ac_file" >&6;}
26565
26566   if test ! -r "$srcdir/$ac_source"; then
26567     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
26568 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
26569    { (exit 1); exit 1; }; }
26570   fi
26571   rm -f "$ac_file"
26572
26573   # Try a relative symlink, then a hard link, then a copy.
26574   case $srcdir in
26575   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
26576       *) ac_rel_source=$ac_top_build_prefix$srcdir/$ac_source ;;
26577   esac
26578   ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
26579     ln "$srcdir/$ac_source" "$ac_file" 2>/dev/null ||
26580     cp -p "$srcdir/$ac_source" "$ac_file" ||
26581     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_file" >&5
26582 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_file" >&2;}
26583    { (exit 1); exit 1; }; }
26584  ;;
26585   :C)  { echo "$as_me:$LINENO: executing $ac_file commands" >&5
26586 echo "$as_me: executing $ac_file commands" >&6;}
26587  ;;
26588   esac
26589
26590
26591   case $ac_file$ac_mode in
26592     "check_win32_symlinks":C)
26593 # Links sometimes fail undetected on Mingw -
26594 # so here we detect it and warn the user
26595 for FILE in $CONFIG_LINKS
26596  do
26597         # test -e works for symlinks in the MinGW console
26598         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
26599 echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
26600  done
26601  ;;
26602     "src/include/pg_config.h":H)
26603 # Update timestamp for pg_config.h (see Makefile.global)
26604 echo >src/include/stamp-h
26605  ;;
26606
26607   esac
26608 done # for ac_tag
26609
26610
26611 { (exit 0); exit 0; }
26612 _ACEOF
26613 chmod +x $CONFIG_STATUS
26614 ac_clean_files=$ac_clean_files_save
26615
26616
26617 # configure is writing to config.log, and then calls config.status.
26618 # config.status does its own redirection, appending to config.log.
26619 # Unfortunately, on DOS this fails, as config.log is still kept open
26620 # by configure, so config.status won't be able to write to it; its
26621 # output is simply discarded.  So we exec the FD to /dev/null,
26622 # effectively closing config.log, so it can be properly (re)opened and
26623 # appended to by config.status.  When coming back to configure, we
26624 # need to make the FD available again.
26625 if test "$no_create" != yes; then
26626   ac_cs_success=:
26627   ac_config_status_args=
26628   test "$silent" = yes &&
26629     ac_config_status_args="$ac_config_status_args --quiet"
26630   exec 5>/dev/null
26631   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
26632   exec 5>>config.log
26633   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
26634   # would make configure fail if this is the last instruction.
26635   $ac_cs_success || { (exit 1); exit 1; }
26636 fi
26637
26638
26639 # Warn about unknown options
26640 for pgac_var in `set | sed 's/=.*//' | $EGREP 'with_|enable_'`; do
26641   for pgac_arg in $pgac_args with_gnu_ld; do
26642     if test "$pgac_var" = "$pgac_arg"; then
26643       continue 2
26644     fi
26645   done
26646   pgac_txt=`echo $pgac_var | sed 's/_/-/g'`
26647   { echo "$as_me:$LINENO: WARNING: option ignored: --$pgac_txt" >&5
26648 echo "$as_me: WARNING: option ignored: --$pgac_txt" >&2;}
26649 done