OSDN Git Service

You must hold a lock on the heap page when you call
[pg-rex/syncrep.git] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.63 for PostgreSQL 9.1devel.
4 #
5 # Report bugs to <pgsql-bugs@postgresql.org>.
6 #
7 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
8 # 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 #
12 # Copyright (c) 1996-2011, PostgreSQL Global Development Group
13 ## --------------------- ##
14 ## M4sh Initialization.  ##
15 ## --------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
20   emulate sh
21   NULLCMD=:
22   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23   # is contrary to our usage.  Disable this feature.
24   alias -g '${1+"$@"}'='"$@"'
25   setopt NO_GLOB_SUBST
26 else
27   case `(set -o) 2>/dev/null` in
28   *posix*) set -o posix ;;
29 esac
30
31 fi
32
33
34
35
36 # PATH needs CR
37 # Avoid depending upon Character Ranges.
38 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
39 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
40 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
41 as_cr_digits='0123456789'
42 as_cr_alnum=$as_cr_Letters$as_cr_digits
43
44 as_nl='
45 '
46 export as_nl
47 # Printing a long string crashes Solaris 7 /usr/bin/printf.
48 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
49 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
50 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
51 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
52   as_echo='printf %s\n'
53   as_echo_n='printf %s'
54 else
55   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57     as_echo_n='/usr/ucb/echo -n'
58   else
59     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
60     as_echo_n_body='eval
61       arg=$1;
62       case $arg in
63       *"$as_nl"*)
64         expr "X$arg" : "X\\(.*\\)$as_nl";
65         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
66       esac;
67       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
68     '
69     export as_echo_n_body
70     as_echo_n='sh -c $as_echo_n_body as_echo'
71   fi
72   export as_echo_body
73   as_echo='sh -c $as_echo_body as_echo'
74 fi
75
76 # The user is always right.
77 if test "${PATH_SEPARATOR+set}" != set; then
78   PATH_SEPARATOR=:
79   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
81       PATH_SEPARATOR=';'
82   }
83 fi
84
85 # Support unset when possible.
86 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
87   as_unset=unset
88 else
89   as_unset=false
90 fi
91
92
93 # IFS
94 # We need space, tab and new line, in precisely that order.  Quoting is
95 # there to prevent editors from complaining about space-tab.
96 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
97 # splitting by setting IFS to empty value.)
98 IFS=" ""        $as_nl"
99
100 # Find who we are.  Look in the path if we contain no directory separator.
101 case $0 in
102   *[\\/]* ) as_myself=$0 ;;
103   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
104 for as_dir in $PATH
105 do
106   IFS=$as_save_IFS
107   test -z "$as_dir" && as_dir=.
108   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
109 done
110 IFS=$as_save_IFS
111
112      ;;
113 esac
114 # We did not find ourselves, most probably we were run as `sh COMMAND'
115 # in which case we are not to be found in the path.
116 if test "x$as_myself" = x; then
117   as_myself=$0
118 fi
119 if test ! -f "$as_myself"; then
120   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
121   { (exit 1); exit 1; }
122 fi
123
124 # Work around bugs in pre-3.0 UWIN ksh.
125 for as_var in ENV MAIL MAILPATH
126 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
127 done
128 PS1='$ '
129 PS2='> '
130 PS4='+ '
131
132 # NLS nuisances.
133 LC_ALL=C
134 export LC_ALL
135 LANGUAGE=C
136 export LANGUAGE
137
138 # Required to use basename.
139 if expr a : '\(a\)' >/dev/null 2>&1 &&
140    test "X`expr 00001 : '.*\(...\)'`" = X001; then
141   as_expr=expr
142 else
143   as_expr=false
144 fi
145
146 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
147   as_basename=basename
148 else
149   as_basename=false
150 fi
151
152
153 # Name of the executable.
154 as_me=`$as_basename -- "$0" ||
155 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
156          X"$0" : 'X\(//\)$' \| \
157          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
158 $as_echo X/"$0" |
159     sed '/^.*\/\([^/][^/]*\)\/*$/{
160             s//\1/
161             q
162           }
163           /^X\/\(\/\/\)$/{
164             s//\1/
165             q
166           }
167           /^X\/\(\/\).*/{
168             s//\1/
169             q
170           }
171           s/.*/./; q'`
172
173 # CDPATH.
174 $as_unset CDPATH
175
176
177 if test "x$CONFIG_SHELL" = x; then
178   if (eval ":") 2>/dev/null; then
179   as_have_required=yes
180 else
181   as_have_required=no
182 fi
183
184   if test $as_have_required = yes &&     (eval ":
185 (as_func_return () {
186   (exit \$1)
187 }
188 as_func_success () {
189   as_func_return 0
190 }
191 as_func_failure () {
192   as_func_return 1
193 }
194 as_func_ret_success () {
195   return 0
196 }
197 as_func_ret_failure () {
198   return 1
199 }
200
201 exitcode=0
202 if as_func_success; then
203   :
204 else
205   exitcode=1
206   echo as_func_success failed.
207 fi
208
209 if as_func_failure; then
210   exitcode=1
211   echo as_func_failure succeeded.
212 fi
213
214 if as_func_ret_success; then
215   :
216 else
217   exitcode=1
218   echo as_func_ret_success failed.
219 fi
220
221 if as_func_ret_failure; then
222   exitcode=1
223   echo as_func_ret_failure succeeded.
224 fi
225
226 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
227   :
228 else
229   exitcode=1
230   echo positional parameters were not saved.
231 fi
232
233 test \$exitcode = 0) || { (exit 1); exit 1; }
234
235 (
236   as_lineno_1=\$LINENO
237   as_lineno_2=\$LINENO
238   test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
239   test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
240 ") 2> /dev/null; then
241   :
242 else
243   as_candidate_shells=
244     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
245 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
246 do
247   IFS=$as_save_IFS
248   test -z "$as_dir" && as_dir=.
249   case $as_dir in
250          /*)
251            for as_base in sh bash ksh sh5; do
252              as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
253            done;;
254        esac
255 done
256 IFS=$as_save_IFS
257
258
259       for as_shell in $as_candidate_shells $SHELL; do
260          # Try only shells that exist, to save several forks.
261          if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
262                 { ("$as_shell") 2> /dev/null <<\_ASEOF
263 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
264   emulate sh
265   NULLCMD=:
266   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
267   # is contrary to our usage.  Disable this feature.
268   alias -g '${1+"$@"}'='"$@"'
269   setopt NO_GLOB_SUBST
270 else
271   case `(set -o) 2>/dev/null` in
272   *posix*) set -o posix ;;
273 esac
274
275 fi
276
277
278 :
279 _ASEOF
280 }; then
281   CONFIG_SHELL=$as_shell
282                as_have_required=yes
283                if { "$as_shell" 2> /dev/null <<\_ASEOF
284 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
285   emulate sh
286   NULLCMD=:
287   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
288   # is contrary to our usage.  Disable this feature.
289   alias -g '${1+"$@"}'='"$@"'
290   setopt NO_GLOB_SUBST
291 else
292   case `(set -o) 2>/dev/null` in
293   *posix*) set -o posix ;;
294 esac
295
296 fi
297
298
299 :
300 (as_func_return () {
301   (exit $1)
302 }
303 as_func_success () {
304   as_func_return 0
305 }
306 as_func_failure () {
307   as_func_return 1
308 }
309 as_func_ret_success () {
310   return 0
311 }
312 as_func_ret_failure () {
313   return 1
314 }
315
316 exitcode=0
317 if as_func_success; then
318   :
319 else
320   exitcode=1
321   echo as_func_success failed.
322 fi
323
324 if as_func_failure; then
325   exitcode=1
326   echo as_func_failure succeeded.
327 fi
328
329 if as_func_ret_success; then
330   :
331 else
332   exitcode=1
333   echo as_func_ret_success failed.
334 fi
335
336 if as_func_ret_failure; then
337   exitcode=1
338   echo as_func_ret_failure succeeded.
339 fi
340
341 if ( set x; as_func_ret_success y && test x = "$1" ); then
342   :
343 else
344   exitcode=1
345   echo positional parameters were not saved.
346 fi
347
348 test $exitcode = 0) || { (exit 1); exit 1; }
349
350 (
351   as_lineno_1=$LINENO
352   as_lineno_2=$LINENO
353   test "x$as_lineno_1" != "x$as_lineno_2" &&
354   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
355
356 _ASEOF
357 }; then
358   break
359 fi
360
361 fi
362
363       done
364
365       if test "x$CONFIG_SHELL" != x; then
366   for as_var in BASH_ENV ENV
367         do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
368         done
369         export CONFIG_SHELL
370         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
371 fi
372
373
374     if test $as_have_required = no; then
375   echo This script requires a shell more modern than all the
376       echo shells that I found on your system.  Please install a
377       echo modern shell, or manually run the script under such a
378       echo shell if you do have one.
379       { (exit 1); exit 1; }
380 fi
381
382
383 fi
384
385 fi
386
387
388
389 (eval "as_func_return () {
390   (exit \$1)
391 }
392 as_func_success () {
393   as_func_return 0
394 }
395 as_func_failure () {
396   as_func_return 1
397 }
398 as_func_ret_success () {
399   return 0
400 }
401 as_func_ret_failure () {
402   return 1
403 }
404
405 exitcode=0
406 if as_func_success; then
407   :
408 else
409   exitcode=1
410   echo as_func_success failed.
411 fi
412
413 if as_func_failure; then
414   exitcode=1
415   echo as_func_failure succeeded.
416 fi
417
418 if as_func_ret_success; then
419   :
420 else
421   exitcode=1
422   echo as_func_ret_success failed.
423 fi
424
425 if as_func_ret_failure; then
426   exitcode=1
427   echo as_func_ret_failure succeeded.
428 fi
429
430 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
431   :
432 else
433   exitcode=1
434   echo positional parameters were not saved.
435 fi
436
437 test \$exitcode = 0") || {
438   echo No shell found that supports shell functions.
439   echo Please tell bug-autoconf@gnu.org about your system,
440   echo including any error possibly output before this message.
441   echo This can help us improve future autoconf versions.
442   echo Configuration will now proceed without shell functions.
443 }
444
445
446
447   as_lineno_1=$LINENO
448   as_lineno_2=$LINENO
449   test "x$as_lineno_1" != "x$as_lineno_2" &&
450   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
451
452   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
453   # uniformly replaced by the line number.  The first 'sed' inserts a
454   # line-number line after each line using $LINENO; the second 'sed'
455   # does the real work.  The second script uses 'N' to pair each
456   # line-number line with the line containing $LINENO, and appends
457   # trailing '-' during substitution so that $LINENO is not a special
458   # case at line end.
459   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
460   # scripts with optimization help from Paolo Bonzini.  Blame Lee
461   # E. McMahon (1931-1989) for sed's syntax.  :-)
462   sed -n '
463     p
464     /[$]LINENO/=
465   ' <$as_myself |
466     sed '
467       s/[$]LINENO.*/&-/
468       t lineno
469       b
470       :lineno
471       N
472       :loop
473       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
474       t loop
475       s/-\n.*//
476     ' >$as_me.lineno &&
477   chmod +x "$as_me.lineno" ||
478     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
479    { (exit 1); exit 1; }; }
480
481   # Don't try to exec as it changes $[0], causing all sort of problems
482   # (the dirname of $[0] is not the place where we might find the
483   # original and so on.  Autoconf is especially sensitive to this).
484   . "./$as_me.lineno"
485   # Exit status is that of the last command.
486   exit
487 }
488
489
490 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
491   as_dirname=dirname
492 else
493   as_dirname=false
494 fi
495
496 ECHO_C= ECHO_N= ECHO_T=
497 case `echo -n x` in
498 -n*)
499   case `echo 'x\c'` in
500   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
501   *)   ECHO_C='\c';;
502   esac;;
503 *)
504   ECHO_N='-n';;
505 esac
506 if expr a : '\(a\)' >/dev/null 2>&1 &&
507    test "X`expr 00001 : '.*\(...\)'`" = X001; then
508   as_expr=expr
509 else
510   as_expr=false
511 fi
512
513 rm -f conf$$ conf$$.exe conf$$.file
514 if test -d conf$$.dir; then
515   rm -f conf$$.dir/conf$$.file
516 else
517   rm -f conf$$.dir
518   mkdir conf$$.dir 2>/dev/null
519 fi
520 if (echo >conf$$.file) 2>/dev/null; then
521   if ln -s conf$$.file conf$$ 2>/dev/null; then
522     as_ln_s='ln -s'
523     # ... but there are two gotchas:
524     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526     # In both cases, we have to default to `cp -p'.
527     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528       as_ln_s='cp -p'
529   elif ln conf$$.file conf$$ 2>/dev/null; then
530     as_ln_s=ln
531   else
532     as_ln_s='cp -p'
533   fi
534 else
535   as_ln_s='cp -p'
536 fi
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
539
540 if mkdir -p . 2>/dev/null; then
541   as_mkdir_p=:
542 else
543   test -d ./-p && rmdir ./-p
544   as_mkdir_p=false
545 fi
546
547 if test -x / >/dev/null 2>&1; then
548   as_test_x='test -x'
549 else
550   if ls -dL / >/dev/null 2>&1; then
551     as_ls_L_option=L
552   else
553     as_ls_L_option=
554   fi
555   as_test_x='
556     eval sh -c '\''
557       if test -d "$1"; then
558         test -d "$1/.";
559       else
560         case $1 in
561         -*)set "./$1";;
562         esac;
563         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
564         ???[sx]*):;;*)false;;esac;fi
565     '\'' sh
566   '
567 fi
568 as_executable_p=$as_test_x
569
570 # Sed expression to map a string onto a valid CPP name.
571 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
572
573 # Sed expression to map a string onto a valid variable name.
574 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
575
576
577
578 exec 7<&0 </dev/null 6>&1
579
580 # Name of the host.
581 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
582 # so uname gets run too.
583 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
584
585 #
586 # Initializations.
587 #
588 ac_default_prefix=/usr/local
589 ac_clean_files=
590 ac_config_libobj_dir=.
591 LIBOBJS=
592 cross_compiling=no
593 subdirs=
594 MFLAGS=
595 MAKEFLAGS=
596 SHELL=${CONFIG_SHELL-/bin/sh}
597
598 # Identity of this package.
599 PACKAGE_NAME='PostgreSQL'
600 PACKAGE_TARNAME='postgresql'
601 PACKAGE_VERSION='9.1devel'
602 PACKAGE_STRING='PostgreSQL 9.1devel'
603 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
604
605 ac_unique_file="src/backend/access/common/heaptuple.c"
606 ac_default_prefix=/usr/local/pgsql
607 # Factoring default headers for most tests.
608 ac_includes_default="\
609 #include <stdio.h>
610 #ifdef HAVE_SYS_TYPES_H
611 # include <sys/types.h>
612 #endif
613 #ifdef HAVE_SYS_STAT_H
614 # include <sys/stat.h>
615 #endif
616 #ifdef STDC_HEADERS
617 # include <stdlib.h>
618 # include <stddef.h>
619 #else
620 # ifdef HAVE_STDLIB_H
621 #  include <stdlib.h>
622 # endif
623 #endif
624 #ifdef HAVE_STRING_H
625 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
626 #  include <memory.h>
627 # endif
628 # include <string.h>
629 #endif
630 #ifdef HAVE_STRINGS_H
631 # include <strings.h>
632 #endif
633 #ifdef HAVE_INTTYPES_H
634 # include <inttypes.h>
635 #endif
636 #ifdef HAVE_STDINT_H
637 # include <stdint.h>
638 #endif
639 #ifdef HAVE_UNISTD_H
640 # include <unistd.h>
641 #endif"
642
643 ac_subst_vars='LTLIBOBJS
644 vpath_build
645 OSX
646 XSLTPROC
647 COLLATEINDEX
648 DOCBOOKSTYLE
649 have_docbook
650 JADE
651 NSGMLS
652 TCL_SHLIB_LD_LIBS
653 TCL_SHARED_BUILD
654 TCL_LIB_SPEC
655 TCL_LIBS
656 TCL_LIB_FILE
657 TCL_INCLUDE_SPEC
658 TCL_CONFIG_SH
659 TCLSH
660 XGETTEXT
661 MSGMERGE
662 MSGFMT
663 HAVE_POSIX_SIGNALS
664 LDAP_LIBS_BE
665 LDAP_LIBS_FE
666 PTHREAD_CFLAGS
667 PTHREAD_LIBS
668 PTHREAD_CC
669 acx_pthread_config
670 have_win32_dbghelp
671 HAVE_IPV6
672 LIBOBJS
673 OSSP_UUID_LIBS
674 ZIC
675 python_additional_libs
676 python_libspec
677 python_libdir
678 python_includespec
679 python_configdir
680 python_version
681 python_majorversion
682 PYTHON
683 perl_embed_ldflags
684 perl_useshrplib
685 perl_privlibexp
686 perl_archlibexp
687 PERL
688 FLEXFLAGS
689 FLEX
690 BISONFLAGS
691 BISON
692 MKDIR_P
693 AWK
694 LN_S
695 TAR
696 WINDRES
697 DLLWRAP
698 DLLTOOL
699 AR
700 STRIP_SHARED_LIB
701 STRIP_STATIC_LIB
702 STRIP
703 RANLIB
704 ld_R_works
705 with_gnu_ld
706 LD
707 LDFLAGS_SL
708 LDFLAGS_EX
709 ELF_SYS
710 EGREP
711 GREP
712 with_zlib
713 with_system_tzdata
714 with_libxslt
715 with_libxml
716 XML2_CONFIG
717 with_ossp_uuid
718 with_selinux
719 with_openssl
720 with_bonjour
721 with_ldap
722 with_pam
723 krb_srvtab
724 with_krb5
725 with_gssapi
726 with_python
727 with_perl
728 with_tcl
729 enable_thread_safety
730 INCLUDES
731 autodepend
732 TAS
733 GCC
734 CPP
735 SUN_STUDIO_CC
736 OBJEXT
737 EXEEXT
738 ac_ct_CC
739 CPPFLAGS
740 LDFLAGS
741 CFLAGS
742 CC
743 enable_dtrace
744 DTRACEFLAGS
745 DTRACE
746 enable_coverage
747 GENHTML
748 LCOV
749 GCOV
750 enable_profiling
751 enable_debug
752 enable_rpath
753 enable_shared
754 default_port
755 WANTED_LANGUAGES
756 enable_nls
757 PORTNAME
758 host_os
759 host_vendor
760 host_cpu
761 host
762 build_os
763 build_vendor
764 build_cpu
765 build
766 PG_MAJORVERSION
767 configure_args
768 target_alias
769 host_alias
770 build_alias
771 LIBS
772 ECHO_T
773 ECHO_N
774 ECHO_C
775 DEFS
776 mandir
777 localedir
778 libdir
779 psdir
780 pdfdir
781 dvidir
782 htmldir
783 infodir
784 docdir
785 oldincludedir
786 includedir
787 localstatedir
788 sharedstatedir
789 sysconfdir
790 datadir
791 datarootdir
792 libexecdir
793 sbindir
794 bindir
795 program_transform_name
796 prefix
797 exec_prefix
798 PACKAGE_BUGREPORT
799 PACKAGE_STRING
800 PACKAGE_VERSION
801 PACKAGE_TARNAME
802 PACKAGE_NAME
803 PATH_SEPARATOR
804 SHELL'
805 ac_subst_files=''
806 ac_user_opts='
807 enable_option_checking
808 with_template
809 with_includes
810 with_libraries
811 with_libs
812 enable_integer_datetimes
813 enable_nls
814 with_pgport
815 enable_shared
816 enable_rpath
817 enable_spinlocks
818 enable_debug
819 enable_profiling
820 enable_coverage
821 enable_dtrace
822 with_blocksize
823 with_segsize
824 with_wal_blocksize
825 with_wal_segsize
826 with_CC
827 enable_depend
828 enable_cassert
829 enable_thread_safety
830 with_tcl
831 with_tclconfig
832 with_perl
833 with_python
834 with_gssapi
835 with_krb5
836 with_krb_srvnam
837 with_pam
838 with_ldap
839 with_bonjour
840 with_openssl
841 with_selinux
842 with_readline
843 with_libedit_preferred
844 with_ossp_uuid
845 with_libxml
846 with_libxslt
847 with_system_tzdata
848 with_zlib
849 with_gnu_ld
850 enable_largefile
851 enable_float4_byval
852 enable_float8_byval
853 '
854       ac_precious_vars='build_alias
855 host_alias
856 target_alias
857 CC
858 CFLAGS
859 LDFLAGS
860 LIBS
861 CPPFLAGS
862 CPP
863 LDFLAGS_EX
864 LDFLAGS_SL
865 DOCBOOKSTYLE'
866
867
868 # Initialize some variables set by options.
869 ac_init_help=
870 ac_init_version=false
871 ac_unrecognized_opts=
872 ac_unrecognized_sep=
873 # The variables have the same names as the options, with
874 # dashes changed to underlines.
875 cache_file=/dev/null
876 exec_prefix=NONE
877 no_create=
878 no_recursion=
879 prefix=NONE
880 program_prefix=NONE
881 program_suffix=NONE
882 program_transform_name=s,x,x,
883 silent=
884 site=
885 srcdir=
886 verbose=
887 x_includes=NONE
888 x_libraries=NONE
889
890 # Installation directory options.
891 # These are left unexpanded so users can "make install exec_prefix=/foo"
892 # and all the variables that are supposed to be based on exec_prefix
893 # by default will actually change.
894 # Use braces instead of parens because sh, perl, etc. also accept them.
895 # (The list follows the same order as the GNU Coding Standards.)
896 bindir='${exec_prefix}/bin'
897 sbindir='${exec_prefix}/sbin'
898 libexecdir='${exec_prefix}/libexec'
899 datarootdir='${prefix}/share'
900 datadir='${datarootdir}'
901 sysconfdir='${prefix}/etc'
902 sharedstatedir='${prefix}/com'
903 localstatedir='${prefix}/var'
904 includedir='${prefix}/include'
905 oldincludedir='/usr/include'
906 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
907 infodir='${datarootdir}/info'
908 htmldir='${docdir}'
909 dvidir='${docdir}'
910 pdfdir='${docdir}'
911 psdir='${docdir}'
912 libdir='${exec_prefix}/lib'
913 localedir='${datarootdir}/locale'
914 mandir='${datarootdir}/man'
915
916 ac_prev=
917 ac_dashdash=
918 for ac_option
919 do
920   # If the previous option needs an argument, assign it.
921   if test -n "$ac_prev"; then
922     eval $ac_prev=\$ac_option
923     ac_prev=
924     continue
925   fi
926
927   case $ac_option in
928   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
929   *)    ac_optarg=yes ;;
930   esac
931
932   # Accept the important Cygnus configure options, so we can diagnose typos.
933
934   case $ac_dashdash$ac_option in
935   --)
936     ac_dashdash=yes ;;
937
938   -bindir | --bindir | --bindi | --bind | --bin | --bi)
939     ac_prev=bindir ;;
940   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
941     bindir=$ac_optarg ;;
942
943   -build | --build | --buil | --bui | --bu)
944     ac_prev=build_alias ;;
945   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
946     build_alias=$ac_optarg ;;
947
948   -cache-file | --cache-file | --cache-fil | --cache-fi \
949   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
950     ac_prev=cache_file ;;
951   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
952   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
953     cache_file=$ac_optarg ;;
954
955   --config-cache | -C)
956     cache_file=config.cache ;;
957
958   -datadir | --datadir | --datadi | --datad)
959     ac_prev=datadir ;;
960   -datadir=* | --datadir=* | --datadi=* | --datad=*)
961     datadir=$ac_optarg ;;
962
963   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
964   | --dataroo | --dataro | --datar)
965     ac_prev=datarootdir ;;
966   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
967   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
968     datarootdir=$ac_optarg ;;
969
970   -disable-* | --disable-*)
971     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
972     # Reject names that are not valid shell variable names.
973     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
974       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
975    { (exit 1); exit 1; }; }
976     ac_useropt_orig=$ac_useropt
977     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
978     case $ac_user_opts in
979       *"
980 "enable_$ac_useropt"
981 "*) ;;
982       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
983          ac_unrecognized_sep=', ';;
984     esac
985     eval enable_$ac_useropt=no ;;
986
987   -docdir | --docdir | --docdi | --doc | --do)
988     ac_prev=docdir ;;
989   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
990     docdir=$ac_optarg ;;
991
992   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
993     ac_prev=dvidir ;;
994   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
995     dvidir=$ac_optarg ;;
996
997   -enable-* | --enable-*)
998     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
999     # Reject names that are not valid shell variable names.
1000     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1001       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1002    { (exit 1); exit 1; }; }
1003     ac_useropt_orig=$ac_useropt
1004     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1005     case $ac_user_opts in
1006       *"
1007 "enable_$ac_useropt"
1008 "*) ;;
1009       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1010          ac_unrecognized_sep=', ';;
1011     esac
1012     eval enable_$ac_useropt=\$ac_optarg ;;
1013
1014   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1015   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1016   | --exec | --exe | --ex)
1017     ac_prev=exec_prefix ;;
1018   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1019   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1020   | --exec=* | --exe=* | --ex=*)
1021     exec_prefix=$ac_optarg ;;
1022
1023   -gas | --gas | --ga | --g)
1024     # Obsolete; use --with-gas.
1025     with_gas=yes ;;
1026
1027   -help | --help | --hel | --he | -h)
1028     ac_init_help=long ;;
1029   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1030     ac_init_help=recursive ;;
1031   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1032     ac_init_help=short ;;
1033
1034   -host | --host | --hos | --ho)
1035     ac_prev=host_alias ;;
1036   -host=* | --host=* | --hos=* | --ho=*)
1037     host_alias=$ac_optarg ;;
1038
1039   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1040     ac_prev=htmldir ;;
1041   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1042   | --ht=*)
1043     htmldir=$ac_optarg ;;
1044
1045   -includedir | --includedir | --includedi | --included | --include \
1046   | --includ | --inclu | --incl | --inc)
1047     ac_prev=includedir ;;
1048   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1049   | --includ=* | --inclu=* | --incl=* | --inc=*)
1050     includedir=$ac_optarg ;;
1051
1052   -infodir | --infodir | --infodi | --infod | --info | --inf)
1053     ac_prev=infodir ;;
1054   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1055     infodir=$ac_optarg ;;
1056
1057   -libdir | --libdir | --libdi | --libd)
1058     ac_prev=libdir ;;
1059   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1060     libdir=$ac_optarg ;;
1061
1062   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1063   | --libexe | --libex | --libe)
1064     ac_prev=libexecdir ;;
1065   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1066   | --libexe=* | --libex=* | --libe=*)
1067     libexecdir=$ac_optarg ;;
1068
1069   -localedir | --localedir | --localedi | --localed | --locale)
1070     ac_prev=localedir ;;
1071   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1072     localedir=$ac_optarg ;;
1073
1074   -localstatedir | --localstatedir | --localstatedi | --localstated \
1075   | --localstate | --localstat | --localsta | --localst | --locals)
1076     ac_prev=localstatedir ;;
1077   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1078   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1079     localstatedir=$ac_optarg ;;
1080
1081   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1082     ac_prev=mandir ;;
1083   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1084     mandir=$ac_optarg ;;
1085
1086   -nfp | --nfp | --nf)
1087     # Obsolete; use --without-fp.
1088     with_fp=no ;;
1089
1090   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1091   | --no-cr | --no-c | -n)
1092     no_create=yes ;;
1093
1094   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1095   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1096     no_recursion=yes ;;
1097
1098   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1099   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1100   | --oldin | --oldi | --old | --ol | --o)
1101     ac_prev=oldincludedir ;;
1102   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1103   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1104   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1105     oldincludedir=$ac_optarg ;;
1106
1107   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1108     ac_prev=prefix ;;
1109   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1110     prefix=$ac_optarg ;;
1111
1112   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1113   | --program-pre | --program-pr | --program-p)
1114     ac_prev=program_prefix ;;
1115   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1116   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1117     program_prefix=$ac_optarg ;;
1118
1119   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1120   | --program-suf | --program-su | --program-s)
1121     ac_prev=program_suffix ;;
1122   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1123   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1124     program_suffix=$ac_optarg ;;
1125
1126   -program-transform-name | --program-transform-name \
1127   | --program-transform-nam | --program-transform-na \
1128   | --program-transform-n | --program-transform- \
1129   | --program-transform | --program-transfor \
1130   | --program-transfo | --program-transf \
1131   | --program-trans | --program-tran \
1132   | --progr-tra | --program-tr | --program-t)
1133     ac_prev=program_transform_name ;;
1134   -program-transform-name=* | --program-transform-name=* \
1135   | --program-transform-nam=* | --program-transform-na=* \
1136   | --program-transform-n=* | --program-transform-=* \
1137   | --program-transform=* | --program-transfor=* \
1138   | --program-transfo=* | --program-transf=* \
1139   | --program-trans=* | --program-tran=* \
1140   | --progr-tra=* | --program-tr=* | --program-t=*)
1141     program_transform_name=$ac_optarg ;;
1142
1143   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1144     ac_prev=pdfdir ;;
1145   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1146     pdfdir=$ac_optarg ;;
1147
1148   -psdir | --psdir | --psdi | --psd | --ps)
1149     ac_prev=psdir ;;
1150   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1151     psdir=$ac_optarg ;;
1152
1153   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1154   | -silent | --silent | --silen | --sile | --sil)
1155     silent=yes ;;
1156
1157   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1158     ac_prev=sbindir ;;
1159   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1160   | --sbi=* | --sb=*)
1161     sbindir=$ac_optarg ;;
1162
1163   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1164   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1165   | --sharedst | --shareds | --shared | --share | --shar \
1166   | --sha | --sh)
1167     ac_prev=sharedstatedir ;;
1168   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1169   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1170   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1171   | --sha=* | --sh=*)
1172     sharedstatedir=$ac_optarg ;;
1173
1174   -site | --site | --sit)
1175     ac_prev=site ;;
1176   -site=* | --site=* | --sit=*)
1177     site=$ac_optarg ;;
1178
1179   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1180     ac_prev=srcdir ;;
1181   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1182     srcdir=$ac_optarg ;;
1183
1184   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1185   | --syscon | --sysco | --sysc | --sys | --sy)
1186     ac_prev=sysconfdir ;;
1187   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1188   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1189     sysconfdir=$ac_optarg ;;
1190
1191   -target | --target | --targe | --targ | --tar | --ta | --t)
1192     ac_prev=target_alias ;;
1193   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1194     target_alias=$ac_optarg ;;
1195
1196   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1197     verbose=yes ;;
1198
1199   -version | --version | --versio | --versi | --vers | -V)
1200     ac_init_version=: ;;
1201
1202   -with-* | --with-*)
1203     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1204     # Reject names that are not valid shell variable names.
1205     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1206       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1207    { (exit 1); exit 1; }; }
1208     ac_useropt_orig=$ac_useropt
1209     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1210     case $ac_user_opts in
1211       *"
1212 "with_$ac_useropt"
1213 "*) ;;
1214       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1215          ac_unrecognized_sep=', ';;
1216     esac
1217     eval with_$ac_useropt=\$ac_optarg ;;
1218
1219   -without-* | --without-*)
1220     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1221     # Reject names that are not valid shell variable names.
1222     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1223       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1224    { (exit 1); exit 1; }; }
1225     ac_useropt_orig=$ac_useropt
1226     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1227     case $ac_user_opts in
1228       *"
1229 "with_$ac_useropt"
1230 "*) ;;
1231       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1232          ac_unrecognized_sep=', ';;
1233     esac
1234     eval with_$ac_useropt=no ;;
1235
1236   --x)
1237     # Obsolete; use --with-x.
1238     with_x=yes ;;
1239
1240   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1241   | --x-incl | --x-inc | --x-in | --x-i)
1242     ac_prev=x_includes ;;
1243   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1244   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1245     x_includes=$ac_optarg ;;
1246
1247   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1248   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1249     ac_prev=x_libraries ;;
1250   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1251   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1252     x_libraries=$ac_optarg ;;
1253
1254   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1255 Try \`$0 --help' for more information." >&2
1256    { (exit 1); exit 1; }; }
1257     ;;
1258
1259   *=*)
1260     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1261     # Reject names that are not valid shell variable names.
1262     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1263       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1264    { (exit 1); exit 1; }; }
1265     eval $ac_envvar=\$ac_optarg
1266     export $ac_envvar ;;
1267
1268   *)
1269     # FIXME: should be removed in autoconf 3.0.
1270     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1271     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1272       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1273     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1274     ;;
1275
1276   esac
1277 done
1278
1279 if test -n "$ac_prev"; then
1280   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1281   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1282    { (exit 1); exit 1; }; }
1283 fi
1284
1285 if test -n "$ac_unrecognized_opts"; then
1286   case $enable_option_checking in
1287     no) ;;
1288     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1289    { (exit 1); exit 1; }; } ;;
1290     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1291   esac
1292 fi
1293
1294 # Check all directory arguments for consistency.
1295 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1296                 datadir sysconfdir sharedstatedir localstatedir includedir \
1297                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1298                 libdir localedir mandir
1299 do
1300   eval ac_val=\$$ac_var
1301   # Remove trailing slashes.
1302   case $ac_val in
1303     */ )
1304       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1305       eval $ac_var=\$ac_val;;
1306   esac
1307   # Be sure to have absolute directory names.
1308   case $ac_val in
1309     [\\/$]* | ?:[\\/]* )  continue;;
1310     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1311   esac
1312   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1313    { (exit 1); exit 1; }; }
1314 done
1315
1316 # There might be people who depend on the old broken behavior: `$host'
1317 # used to hold the argument of --host etc.
1318 # FIXME: To remove some day.
1319 build=$build_alias
1320 host=$host_alias
1321 target=$target_alias
1322
1323 # FIXME: To remove some day.
1324 if test "x$host_alias" != x; then
1325   if test "x$build_alias" = x; then
1326     cross_compiling=maybe
1327     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1328     If a cross compiler is detected then cross compile mode will be used." >&2
1329   elif test "x$build_alias" != "x$host_alias"; then
1330     cross_compiling=yes
1331   fi
1332 fi
1333
1334 ac_tool_prefix=
1335 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1336
1337 test "$silent" = yes && exec 6>/dev/null
1338
1339
1340 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1341 ac_ls_di=`ls -di .` &&
1342 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1343   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1344    { (exit 1); exit 1; }; }
1345 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1346   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1347    { (exit 1); exit 1; }; }
1348
1349
1350 # Find the source files, if location was not specified.
1351 if test -z "$srcdir"; then
1352   ac_srcdir_defaulted=yes
1353   # Try the directory containing this script, then the parent directory.
1354   ac_confdir=`$as_dirname -- "$as_myself" ||
1355 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1356          X"$as_myself" : 'X\(//\)[^/]' \| \
1357          X"$as_myself" : 'X\(//\)$' \| \
1358          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1359 $as_echo X"$as_myself" |
1360     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1361             s//\1/
1362             q
1363           }
1364           /^X\(\/\/\)[^/].*/{
1365             s//\1/
1366             q
1367           }
1368           /^X\(\/\/\)$/{
1369             s//\1/
1370             q
1371           }
1372           /^X\(\/\).*/{
1373             s//\1/
1374             q
1375           }
1376           s/.*/./; q'`
1377   srcdir=$ac_confdir
1378   if test ! -r "$srcdir/$ac_unique_file"; then
1379     srcdir=..
1380   fi
1381 else
1382   ac_srcdir_defaulted=no
1383 fi
1384 if test ! -r "$srcdir/$ac_unique_file"; then
1385   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1386   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1387    { (exit 1); exit 1; }; }
1388 fi
1389 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1390 ac_abs_confdir=`(
1391         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1392    { (exit 1); exit 1; }; }
1393         pwd)`
1394 # When building in place, set srcdir=.
1395 if test "$ac_abs_confdir" = "$ac_pwd"; then
1396   srcdir=.
1397 fi
1398 # Remove unnecessary trailing slashes from srcdir.
1399 # Double slashes in file names in object file debugging info
1400 # mess up M-x gdb in Emacs.
1401 case $srcdir in
1402 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1403 esac
1404 for ac_var in $ac_precious_vars; do
1405   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1406   eval ac_env_${ac_var}_value=\$${ac_var}
1407   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1408   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1409 done
1410
1411 #
1412 # Report the --help message.
1413 #
1414 if test "$ac_init_help" = "long"; then
1415   # Omit some internal or obsolete options to make the list less imposing.
1416   # This message is too long to be a string in the A/UX 3.1 sh.
1417   cat <<_ACEOF
1418 \`configure' configures PostgreSQL 9.1devel to adapt to many kinds of systems.
1419
1420 Usage: $0 [OPTION]... [VAR=VALUE]...
1421
1422 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1423 VAR=VALUE.  See below for descriptions of some of the useful variables.
1424
1425 Defaults for the options are specified in brackets.
1426
1427 Configuration:
1428   -h, --help              display this help and exit
1429       --help=short        display options specific to this package
1430       --help=recursive    display the short help of all the included packages
1431   -V, --version           display version information and exit
1432   -q, --quiet, --silent   do not print \`checking...' messages
1433       --cache-file=FILE   cache test results in FILE [disabled]
1434   -C, --config-cache      alias for \`--cache-file=config.cache'
1435   -n, --no-create         do not create output files
1436       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1437
1438 Installation directories:
1439   --prefix=PREFIX         install architecture-independent files in PREFIX
1440                           [$ac_default_prefix]
1441   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1442                           [PREFIX]
1443
1444 By default, \`make install' will install all the files in
1445 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1446 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1447 for instance \`--prefix=\$HOME'.
1448
1449 For better control, use the options below.
1450
1451 Fine tuning of the installation directories:
1452   --bindir=DIR            user executables [EPREFIX/bin]
1453   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1454   --libexecdir=DIR        program executables [EPREFIX/libexec]
1455   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1456   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1457   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1458   --libdir=DIR            object code libraries [EPREFIX/lib]
1459   --includedir=DIR        C header files [PREFIX/include]
1460   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1461   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1462   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1463   --infodir=DIR           info documentation [DATAROOTDIR/info]
1464   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1465   --mandir=DIR            man documentation [DATAROOTDIR/man]
1466   --docdir=DIR            documentation root [DATAROOTDIR/doc/postgresql]
1467   --htmldir=DIR           html documentation [DOCDIR]
1468   --dvidir=DIR            dvi documentation [DOCDIR]
1469   --pdfdir=DIR            pdf documentation [DOCDIR]
1470   --psdir=DIR             ps documentation [DOCDIR]
1471 _ACEOF
1472
1473   cat <<\_ACEOF
1474
1475 System types:
1476   --build=BUILD     configure for building on BUILD [guessed]
1477   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1478 _ACEOF
1479 fi
1480
1481 if test -n "$ac_init_help"; then
1482   case $ac_init_help in
1483      short | recursive ) echo "Configuration of PostgreSQL 9.1devel:";;
1484    esac
1485   cat <<\_ACEOF
1486
1487 Optional Features:
1488   --disable-option-checking  ignore unrecognized --enable/--with options
1489   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1490   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1491   --disable-integer-datetimes
1492                           disable 64-bit integer date/time support
1493   --enable-nls[=LANGUAGES]
1494                           enable Native Language Support
1495   --disable-shared        do not build shared libraries
1496   --disable-rpath         do not embed shared library search path in
1497                           executables
1498   --disable-spinlocks     do not use spinlocks
1499   --enable-debug          build with debugging symbols (-g)
1500   --enable-profiling      build with profiling enabled
1501   --enable-coverage       build with coverage testing instrumentation
1502   --enable-dtrace         build with DTrace support
1503   --enable-depend         turn on automatic dependency tracking
1504   --enable-cassert        enable assertion checks (for debugging)
1505   --disable-thread-safety disable thread-safety in client libraries
1506   --disable-largefile     omit support for large files
1507   --disable-float4-byval  disable float4 passed by value
1508   --disable-float8-byval  disable float8 passed by value
1509
1510 Optional Packages:
1511   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1512   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1513   --with-template=NAME    override operating system template
1514   --with-includes=DIRS    look for additional header files in DIRS
1515   --with-libraries=DIRS   look for additional libraries in DIRS
1516   --with-libs=DIRS        alternative spelling of --with-libraries
1517   --with-pgport=PORTNUM   set default port number [5432]
1518   --with-blocksize=BLOCKSIZE
1519                           set table block size in kB [8]
1520   --with-segsize=SEGSIZE  set table segment size in GB [1]
1521   --with-wal-blocksize=BLOCKSIZE
1522                           set WAL block size in kB [8]
1523   --with-wal-segsize=SEGSIZE
1524                           set WAL segment size in MB [16]
1525   --with-CC=CMD           set compiler (deprecated)
1526   --with-tcl              build Tcl modules (PL/Tcl)
1527   --with-tclconfig=DIR    tclConfig.sh is in DIR
1528   --with-perl             build Perl modules (PL/Perl)
1529   --with-python           build Python modules (PL/Python)
1530   --with-gssapi           build with GSSAPI support
1531   --with-krb5             build with Kerberos 5 support
1532   --with-krb-srvnam=NAME  default service principal name in Kerberos
1533                           [postgres]
1534   --with-pam              build with PAM support
1535   --with-ldap             build with LDAP support
1536   --with-bonjour          build with Bonjour support
1537   --with-openssl          build with OpenSSL support
1538   --with-selinux          build with SELinux support
1539   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1540   --with-libedit-preferred
1541                           prefer BSD Libedit over GNU Readline
1542   --with-ossp-uuid        use OSSP UUID library when building
1543                           contrib/uuid-ossp
1544   --with-libxml           build with XML support
1545   --with-libxslt          use XSLT support when building contrib/xml2
1546   --with-system-tzdata=DIR
1547                           use system time zone data in DIR
1548   --without-zlib          do not use Zlib
1549   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1550
1551 Some influential environment variables:
1552   CC          C compiler command
1553   CFLAGS      C compiler flags
1554   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1555               nonstandard directory <lib dir>
1556   LIBS        libraries to pass to the linker, e.g. -l<library>
1557   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1558               you have headers in a nonstandard directory <include dir>
1559   CPP         C preprocessor
1560   LDFLAGS_EX  extra linker flags for linking executables only
1561   LDFLAGS_SL  extra linker flags for linking shared libraries only
1562   DOCBOOKSTYLE
1563               location of DocBook stylesheets
1564
1565 Use these variables to override the choices made by `configure' or to help
1566 it to find libraries and programs with nonstandard names/locations.
1567
1568 Report bugs to <pgsql-bugs@postgresql.org>.
1569 _ACEOF
1570 ac_status=$?
1571 fi
1572
1573 if test "$ac_init_help" = "recursive"; then
1574   # If there are subdirs, report their specific --help.
1575   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1576     test -d "$ac_dir" ||
1577       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1578       continue
1579     ac_builddir=.
1580
1581 case "$ac_dir" in
1582 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1583 *)
1584   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1585   # A ".." for each directory in $ac_dir_suffix.
1586   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1587   case $ac_top_builddir_sub in
1588   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1589   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1590   esac ;;
1591 esac
1592 ac_abs_top_builddir=$ac_pwd
1593 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1594 # for backward compatibility:
1595 ac_top_builddir=$ac_top_build_prefix
1596
1597 case $srcdir in
1598   .)  # We are building in place.
1599     ac_srcdir=.
1600     ac_top_srcdir=$ac_top_builddir_sub
1601     ac_abs_top_srcdir=$ac_pwd ;;
1602   [\\/]* | ?:[\\/]* )  # Absolute name.
1603     ac_srcdir=$srcdir$ac_dir_suffix;
1604     ac_top_srcdir=$srcdir
1605     ac_abs_top_srcdir=$srcdir ;;
1606   *) # Relative name.
1607     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1608     ac_top_srcdir=$ac_top_build_prefix$srcdir
1609     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1610 esac
1611 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1612
1613     cd "$ac_dir" || { ac_status=$?; continue; }
1614     # Check for guested configure.
1615     if test -f "$ac_srcdir/configure.gnu"; then
1616       echo &&
1617       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1618     elif test -f "$ac_srcdir/configure"; then
1619       echo &&
1620       $SHELL "$ac_srcdir/configure" --help=recursive
1621     else
1622       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1623     fi || ac_status=$?
1624     cd "$ac_pwd" || { ac_status=$?; break; }
1625   done
1626 fi
1627
1628 test -n "$ac_init_help" && exit $ac_status
1629 if $ac_init_version; then
1630   cat <<\_ACEOF
1631 PostgreSQL configure 9.1devel
1632 generated by GNU Autoconf 2.63
1633
1634 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1635 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1636 This configure script is free software; the Free Software Foundation
1637 gives unlimited permission to copy, distribute and modify it.
1638
1639 Copyright (c) 1996-2011, PostgreSQL Global Development Group
1640 _ACEOF
1641   exit
1642 fi
1643 cat >config.log <<_ACEOF
1644 This file contains any messages produced by compilers while
1645 running configure, to aid debugging if configure makes a mistake.
1646
1647 It was created by PostgreSQL $as_me 9.1devel, which was
1648 generated by GNU Autoconf 2.63.  Invocation command line was
1649
1650   $ $0 $@
1651
1652 _ACEOF
1653 exec 5>>config.log
1654 {
1655 cat <<_ASUNAME
1656 ## --------- ##
1657 ## Platform. ##
1658 ## --------- ##
1659
1660 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1661 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1662 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1663 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1664 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1665
1666 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1667 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1668
1669 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1670 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1671 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1672 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1673 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1674 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1675 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1676
1677 _ASUNAME
1678
1679 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1680 for as_dir in $PATH
1681 do
1682   IFS=$as_save_IFS
1683   test -z "$as_dir" && as_dir=.
1684   $as_echo "PATH: $as_dir"
1685 done
1686 IFS=$as_save_IFS
1687
1688 } >&5
1689
1690 cat >&5 <<_ACEOF
1691
1692
1693 ## ----------- ##
1694 ## Core tests. ##
1695 ## ----------- ##
1696
1697 _ACEOF
1698
1699
1700 # Keep a trace of the command line.
1701 # Strip out --no-create and --no-recursion so they do not pile up.
1702 # Strip out --silent because we don't want to record it for future runs.
1703 # Also quote any args containing shell meta-characters.
1704 # Make two passes to allow for proper duplicate-argument suppression.
1705 ac_configure_args=
1706 ac_configure_args0=
1707 ac_configure_args1=
1708 ac_must_keep_next=false
1709 for ac_pass in 1 2
1710 do
1711   for ac_arg
1712   do
1713     case $ac_arg in
1714     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1715     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1716     | -silent | --silent | --silen | --sile | --sil)
1717       continue ;;
1718     *\'*)
1719       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1720     esac
1721     case $ac_pass in
1722     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1723     2)
1724       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1725       if test $ac_must_keep_next = true; then
1726         ac_must_keep_next=false # Got value, back to normal.
1727       else
1728         case $ac_arg in
1729           *=* | --config-cache | -C | -disable-* | --disable-* \
1730           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1731           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1732           | -with-* | --with-* | -without-* | --without-* | --x)
1733             case "$ac_configure_args0 " in
1734               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1735             esac
1736             ;;
1737           -* ) ac_must_keep_next=true ;;
1738         esac
1739       fi
1740       ac_configure_args="$ac_configure_args '$ac_arg'"
1741       ;;
1742     esac
1743   done
1744 done
1745 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1746 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1747
1748 # When interrupted or exit'd, cleanup temporary files, and complete
1749 # config.log.  We remove comments because anyway the quotes in there
1750 # would cause problems or look ugly.
1751 # WARNING: Use '\'' to represent an apostrophe within the trap.
1752 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1753 trap 'exit_status=$?
1754   # Save into config.log some information that might help in debugging.
1755   {
1756     echo
1757
1758     cat <<\_ASBOX
1759 ## ---------------- ##
1760 ## Cache variables. ##
1761 ## ---------------- ##
1762 _ASBOX
1763     echo
1764     # The following way of writing the cache mishandles newlines in values,
1765 (
1766   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1767     eval ac_val=\$$ac_var
1768     case $ac_val in #(
1769     *${as_nl}*)
1770       case $ac_var in #(
1771       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1772 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1773       esac
1774       case $ac_var in #(
1775       _ | IFS | as_nl) ;; #(
1776       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1777       *) $as_unset $ac_var ;;
1778       esac ;;
1779     esac
1780   done
1781   (set) 2>&1 |
1782     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1783     *${as_nl}ac_space=\ *)
1784       sed -n \
1785         "s/'\''/'\''\\\\'\'''\''/g;
1786           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1787       ;; #(
1788     *)
1789       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1790       ;;
1791     esac |
1792     sort
1793 )
1794     echo
1795
1796     cat <<\_ASBOX
1797 ## ----------------- ##
1798 ## Output variables. ##
1799 ## ----------------- ##
1800 _ASBOX
1801     echo
1802     for ac_var in $ac_subst_vars
1803     do
1804       eval ac_val=\$$ac_var
1805       case $ac_val in
1806       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1807       esac
1808       $as_echo "$ac_var='\''$ac_val'\''"
1809     done | sort
1810     echo
1811
1812     if test -n "$ac_subst_files"; then
1813       cat <<\_ASBOX
1814 ## ------------------- ##
1815 ## File substitutions. ##
1816 ## ------------------- ##
1817 _ASBOX
1818       echo
1819       for ac_var in $ac_subst_files
1820       do
1821         eval ac_val=\$$ac_var
1822         case $ac_val in
1823         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1824         esac
1825         $as_echo "$ac_var='\''$ac_val'\''"
1826       done | sort
1827       echo
1828     fi
1829
1830     if test -s confdefs.h; then
1831       cat <<\_ASBOX
1832 ## ----------- ##
1833 ## confdefs.h. ##
1834 ## ----------- ##
1835 _ASBOX
1836       echo
1837       cat confdefs.h
1838       echo
1839     fi
1840     test "$ac_signal" != 0 &&
1841       $as_echo "$as_me: caught signal $ac_signal"
1842     $as_echo "$as_me: exit $exit_status"
1843   } >&5
1844   rm -f core *.core core.conftest.* &&
1845     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1846     exit $exit_status
1847 ' 0
1848 for ac_signal in 1 2 13 15; do
1849   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1850 done
1851 ac_signal=0
1852
1853 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1854 rm -f -r conftest* confdefs.h
1855
1856 # Predefined preprocessor variables.
1857
1858 cat >>confdefs.h <<_ACEOF
1859 #define PACKAGE_NAME "$PACKAGE_NAME"
1860 _ACEOF
1861
1862
1863 cat >>confdefs.h <<_ACEOF
1864 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1865 _ACEOF
1866
1867
1868 cat >>confdefs.h <<_ACEOF
1869 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1870 _ACEOF
1871
1872
1873 cat >>confdefs.h <<_ACEOF
1874 #define PACKAGE_STRING "$PACKAGE_STRING"
1875 _ACEOF
1876
1877
1878 cat >>confdefs.h <<_ACEOF
1879 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1880 _ACEOF
1881
1882
1883 # Let the site file select an alternate cache file if it wants to.
1884 # Prefer an explicitly selected file to automatically selected ones.
1885 ac_site_file1=NONE
1886 ac_site_file2=NONE
1887 if test -n "$CONFIG_SITE"; then
1888   ac_site_file1=$CONFIG_SITE
1889 elif test "x$prefix" != xNONE; then
1890   ac_site_file1=$prefix/share/config.site
1891   ac_site_file2=$prefix/etc/config.site
1892 else
1893   ac_site_file1=$ac_default_prefix/share/config.site
1894   ac_site_file2=$ac_default_prefix/etc/config.site
1895 fi
1896 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1897 do
1898   test "x$ac_site_file" = xNONE && continue
1899   if test -r "$ac_site_file"; then
1900     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1901 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1902     sed 's/^/| /' "$ac_site_file" >&5
1903     . "$ac_site_file"
1904   fi
1905 done
1906
1907 if test -r "$cache_file"; then
1908   # Some versions of bash will fail to source /dev/null (special
1909   # files actually), so we avoid doing that.
1910   if test -f "$cache_file"; then
1911     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1912 $as_echo "$as_me: loading cache $cache_file" >&6;}
1913     case $cache_file in
1914       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1915       *)                      . "./$cache_file";;
1916     esac
1917   fi
1918 else
1919   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1920 $as_echo "$as_me: creating cache $cache_file" >&6;}
1921   >$cache_file
1922 fi
1923
1924 # Check that the precious variables saved in the cache have kept the same
1925 # value.
1926 ac_cache_corrupted=false
1927 for ac_var in $ac_precious_vars; do
1928   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1929   eval ac_new_set=\$ac_env_${ac_var}_set
1930   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1931   eval ac_new_val=\$ac_env_${ac_var}_value
1932   case $ac_old_set,$ac_new_set in
1933     set,)
1934       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1935 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1936       ac_cache_corrupted=: ;;
1937     ,set)
1938       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1939 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1940       ac_cache_corrupted=: ;;
1941     ,);;
1942     *)
1943       if test "x$ac_old_val" != "x$ac_new_val"; then
1944         # differences in whitespace do not lead to failure.
1945         ac_old_val_w=`echo x $ac_old_val`
1946         ac_new_val_w=`echo x $ac_new_val`
1947         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1948           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1949 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1950           ac_cache_corrupted=:
1951         else
1952           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1953 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1954           eval $ac_var=\$ac_old_val
1955         fi
1956         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1957 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1958         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1959 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1960       fi;;
1961   esac
1962   # Pass precious variables to config.status.
1963   if test "$ac_new_set" = set; then
1964     case $ac_new_val in
1965     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1966     *) ac_arg=$ac_var=$ac_new_val ;;
1967     esac
1968     case " $ac_configure_args " in
1969       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1970       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1971     esac
1972   fi
1973 done
1974 if $ac_cache_corrupted; then
1975   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1976 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1977   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1978 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1979   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1980 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1981    { (exit 1); exit 1; }; }
1982 fi
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008 ac_ext=c
2009 ac_cpp='$CPP $CPPFLAGS'
2010 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2011 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2012 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2013
2014
2015
2016
2017
2018
2019 ac_aux_dir=
2020 for ac_dir in config "$srcdir"/config; do
2021   if test -f "$ac_dir/install-sh"; then
2022     ac_aux_dir=$ac_dir
2023     ac_install_sh="$ac_aux_dir/install-sh -c"
2024     break
2025   elif test -f "$ac_dir/install.sh"; then
2026     ac_aux_dir=$ac_dir
2027     ac_install_sh="$ac_aux_dir/install.sh -c"
2028     break
2029   elif test -f "$ac_dir/shtool"; then
2030     ac_aux_dir=$ac_dir
2031     ac_install_sh="$ac_aux_dir/shtool install -c"
2032     break
2033   fi
2034 done
2035 if test -z "$ac_aux_dir"; then
2036   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2037 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2038    { (exit 1); exit 1; }; }
2039 fi
2040
2041 # These three variables are undocumented and unsupported,
2042 # and are intended to be withdrawn in a future Autoconf release.
2043 # They can cause serious problems if a builder's source tree is in a directory
2044 # whose full name contains unusual characters.
2045 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2046 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2047 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2048
2049
2050
2051 configure_args=$ac_configure_args
2052
2053
2054
2055 cat >>confdefs.h <<_ACEOF
2056 #define PG_VERSION "$PACKAGE_VERSION"
2057 _ACEOF
2058
2059 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2060
2061
2062 cat >>confdefs.h <<_ACEOF
2063 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2064 _ACEOF
2065
2066
2067 # Make sure we can run config.sub.
2068 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2069   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2070 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2071    { (exit 1); exit 1; }; }
2072
2073 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2074 $as_echo_n "checking build system type... " >&6; }
2075 if test "${ac_cv_build+set}" = set; then
2076   $as_echo_n "(cached) " >&6
2077 else
2078   ac_build_alias=$build_alias
2079 test "x$ac_build_alias" = x &&
2080   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2081 test "x$ac_build_alias" = x &&
2082   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2083 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2084    { (exit 1); exit 1; }; }
2085 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2086   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2087 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2088    { (exit 1); exit 1; }; }
2089
2090 fi
2091 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2092 $as_echo "$ac_cv_build" >&6; }
2093 case $ac_cv_build in
2094 *-*-*) ;;
2095 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2096 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2097    { (exit 1); exit 1; }; };;
2098 esac
2099 build=$ac_cv_build
2100 ac_save_IFS=$IFS; IFS='-'
2101 set x $ac_cv_build
2102 shift
2103 build_cpu=$1
2104 build_vendor=$2
2105 shift; shift
2106 # Remember, the first character of IFS is used to create $*,
2107 # except with old shells:
2108 build_os=$*
2109 IFS=$ac_save_IFS
2110 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2111
2112
2113 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2114 $as_echo_n "checking host system type... " >&6; }
2115 if test "${ac_cv_host+set}" = set; then
2116   $as_echo_n "(cached) " >&6
2117 else
2118   if test "x$host_alias" = x; then
2119   ac_cv_host=$ac_cv_build
2120 else
2121   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2122     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2123 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2124    { (exit 1); exit 1; }; }
2125 fi
2126
2127 fi
2128 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2129 $as_echo "$ac_cv_host" >&6; }
2130 case $ac_cv_host in
2131 *-*-*) ;;
2132 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2133 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2134    { (exit 1); exit 1; }; };;
2135 esac
2136 host=$ac_cv_host
2137 ac_save_IFS=$IFS; IFS='-'
2138 set x $ac_cv_host
2139 shift
2140 host_cpu=$1
2141 host_vendor=$2
2142 shift; shift
2143 # Remember, the first character of IFS is used to create $*,
2144 # except with old shells:
2145 host_os=$*
2146 IFS=$ac_save_IFS
2147 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2148
2149
2150
2151 template=
2152 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2153 $as_echo_n "checking which template to use... " >&6; }
2154
2155
2156
2157
2158 # Check whether --with-template was given.
2159 if test "${with_template+set}" = set; then
2160   withval=$with_template;
2161   case $withval in
2162     yes)
2163       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2164 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2165    { (exit 1); exit 1; }; }
2166       ;;
2167     no)
2168       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2169 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2170    { (exit 1); exit 1; }; }
2171       ;;
2172     *)
2173
2174   case $withval in
2175     list)   echo; ls "$srcdir/src/template"; exit;;
2176     *)      if test -f "$srcdir/src/template/$with_template" ; then
2177               template=$withval
2178             else
2179               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2180 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2181    { (exit 1); exit 1; }; }
2182             fi;;
2183   esac
2184
2185       ;;
2186   esac
2187
2188 else
2189
2190 # --with-template not given
2191
2192 case $host_os in
2193      aix*) template=aix ;;
2194     bsdi*) template=bsdi ;;
2195   cygwin*) template=cygwin ;;
2196   darwin*) template=darwin ;;
2197 dragonfly*) template=netbsd ;;
2198     dgux*) template=dgux ;;
2199  freebsd*) template=freebsd ;;
2200     hpux*) template=hpux ;;
2201     irix*) template=irix ;;
2202  linux*|gnu*|k*bsd*-gnu)
2203            template=linux ;;
2204    mingw*) template=win32 ;;
2205   netbsd*) template=netbsd ;;
2206 nextstep*) template=nextstep ;;
2207  openbsd*) template=openbsd ;;
2208      osf*) template=osf ;;
2209      sco*) template=sco ;;
2210  solaris*) template=solaris ;;
2211    sunos*) template=sunos4 ;;
2212  sysv4.2*)
2213         case $host_vendor in
2214           univel) template=univel ;;
2215         esac ;;
2216    sysv4*) template=svr4 ;;
2217    sysv5*) template=unixware ;;
2218   ultrix*) template=ultrix4 ;;
2219 esac
2220
2221   if test x"$template" = x"" ; then
2222     { { $as_echo "$as_me:$LINENO: error:
2223 *******************************************************************
2224 PostgreSQL has apparently not been ported to your platform yet.
2225 To try a manual configuration, look into the src/template directory
2226 for a similar platform and use the '--with-template=' option.
2227
2228 Please also contact <pgsql-bugs@postgresql.org> to see about
2229 rectifying this.  Include the above 'checking host system type...'
2230 line.
2231 *******************************************************************
2232 " >&5
2233 $as_echo "$as_me: error:
2234 *******************************************************************
2235 PostgreSQL has apparently not been ported to your platform yet.
2236 To try a manual configuration, look into the src/template directory
2237 for a similar platform and use the '--with-template=' option.
2238
2239 Please also contact <pgsql-bugs@postgresql.org> to see about
2240 rectifying this.  Include the above 'checking host system type...'
2241 line.
2242 *******************************************************************
2243 " >&2;}
2244    { (exit 1); exit 1; }; }
2245   fi
2246
2247
2248 fi
2249
2250
2251
2252 { $as_echo "$as_me:$LINENO: result: $template" >&5
2253 $as_echo "$template" >&6; }
2254
2255 PORTNAME=$template
2256
2257
2258 # Initialize default assumption that we do not need separate assembly code
2259 # for TAS (test-and-set).  This can be overridden by the template file
2260 # when it's executed.
2261 need_tas=no
2262 tas_file=dummy.s
2263
2264
2265
2266 ##
2267 ## Command line options
2268 ##
2269
2270 #
2271 # Add non-standard directories to the include path
2272 #
2273
2274
2275
2276 # Check whether --with-includes was given.
2277 if test "${with_includes+set}" = set; then
2278   withval=$with_includes;
2279   case $withval in
2280     yes)
2281       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2282 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2283    { (exit 1); exit 1; }; }
2284       ;;
2285     no)
2286       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2287 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2288    { (exit 1); exit 1; }; }
2289       ;;
2290     *)
2291
2292       ;;
2293   esac
2294
2295 fi
2296
2297
2298
2299
2300 #
2301 # Add non-standard directories to the library search path
2302 #
2303
2304
2305
2306 # Check whether --with-libraries was given.
2307 if test "${with_libraries+set}" = set; then
2308   withval=$with_libraries;
2309   case $withval in
2310     yes)
2311       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2312 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2313    { (exit 1); exit 1; }; }
2314       ;;
2315     no)
2316       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2317 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2318    { (exit 1); exit 1; }; }
2319       ;;
2320     *)
2321       LIBRARY_DIRS=$withval
2322       ;;
2323   esac
2324
2325 fi
2326
2327
2328
2329
2330
2331
2332 # Check whether --with-libs was given.
2333 if test "${with_libs+set}" = set; then
2334   withval=$with_libs;
2335   case $withval in
2336     yes)
2337       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2338 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2339    { (exit 1); exit 1; }; }
2340       ;;
2341     no)
2342       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2343 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2344    { (exit 1); exit 1; }; }
2345       ;;
2346     *)
2347       LIBRARY_DIRS=$withval
2348       ;;
2349   esac
2350
2351 fi
2352
2353
2354
2355
2356 #
2357 # 64-bit integer date/time storage: enabled by default.
2358 #
2359 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2360 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2361
2362
2363 # Check whether --enable-integer-datetimes was given.
2364 if test "${enable_integer_datetimes+set}" = set; then
2365   enableval=$enable_integer_datetimes;
2366   case $enableval in
2367     yes)
2368
2369 cat >>confdefs.h <<\_ACEOF
2370 #define USE_INTEGER_DATETIMES 1
2371 _ACEOF
2372
2373       ;;
2374     no)
2375       :
2376       ;;
2377     *)
2378       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2379 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2380    { (exit 1); exit 1; }; }
2381       ;;
2382   esac
2383
2384 else
2385   enable_integer_datetimes=yes
2386
2387 cat >>confdefs.h <<\_ACEOF
2388 #define USE_INTEGER_DATETIMES 1
2389 _ACEOF
2390
2391 fi
2392
2393
2394 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2395 $as_echo "$enable_integer_datetimes" >&6; }
2396
2397
2398 #
2399 # NLS
2400 #
2401 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2402 $as_echo_n "checking whether NLS is wanted... " >&6; }
2403
2404
2405 # Check whether --enable-nls was given.
2406 if test "${enable_nls+set}" = set; then
2407   enableval=$enable_nls;
2408   case $enableval in
2409     yes)
2410       :
2411       ;;
2412     no)
2413       :
2414       ;;
2415     *)
2416       enable_nls=yes
2417 WANTED_LANGUAGES=$enableval
2418       ;;
2419   esac
2420
2421 else
2422   enable_nls=no
2423 fi
2424
2425
2426
2427 if test "$enable_nls" = yes; then
2428
2429 cat >>confdefs.h <<\_ACEOF
2430 #define ENABLE_NLS 1
2431 _ACEOF
2432
2433 fi
2434
2435 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2436 $as_echo "$enable_nls" >&6; }
2437
2438
2439
2440 #
2441 # Default port number (--with-pgport), default 5432
2442 #
2443 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2444 $as_echo_n "checking for default port number... " >&6; }
2445
2446
2447
2448 # Check whether --with-pgport was given.
2449 if test "${with_pgport+set}" = set; then
2450   withval=$with_pgport;
2451   case $withval in
2452     yes)
2453       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2454 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2455    { (exit 1); exit 1; }; }
2456       ;;
2457     no)
2458       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2459 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2460    { (exit 1); exit 1; }; }
2461       ;;
2462     *)
2463       default_port=$withval
2464       ;;
2465   esac
2466
2467 else
2468   default_port=5432
2469 fi
2470
2471
2472 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2473 $as_echo "$default_port" >&6; }
2474 # Need both of these because some places want an integer and some a string
2475
2476 cat >>confdefs.h <<_ACEOF
2477 #define DEF_PGPORT ${default_port}
2478 _ACEOF
2479
2480
2481 cat >>confdefs.h <<_ACEOF
2482 #define DEF_PGPORT_STR "${default_port}"
2483 _ACEOF
2484
2485
2486
2487 #
2488 # Option to disable shared libraries
2489 #
2490
2491
2492 # Check whether --enable-shared was given.
2493 if test "${enable_shared+set}" = set; then
2494   enableval=$enable_shared;
2495   case $enableval in
2496     yes)
2497       :
2498       ;;
2499     no)
2500       :
2501       ;;
2502     *)
2503       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2504 $as_echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2505    { (exit 1); exit 1; }; }
2506       ;;
2507   esac
2508
2509 else
2510   enable_shared=yes
2511
2512 fi
2513
2514
2515
2516
2517 #
2518 # '-rpath'-like feature can be disabled
2519 #
2520
2521
2522 # Check whether --enable-rpath was given.
2523 if test "${enable_rpath+set}" = set; then
2524   enableval=$enable_rpath;
2525   case $enableval in
2526     yes)
2527       :
2528       ;;
2529     no)
2530       :
2531       ;;
2532     *)
2533       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2534 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2535    { (exit 1); exit 1; }; }
2536       ;;
2537   esac
2538
2539 else
2540   enable_rpath=yes
2541
2542 fi
2543
2544
2545
2546
2547 #
2548 # Spinlocks
2549 #
2550
2551
2552 # Check whether --enable-spinlocks was given.
2553 if test "${enable_spinlocks+set}" = set; then
2554   enableval=$enable_spinlocks;
2555   case $enableval in
2556     yes)
2557       :
2558       ;;
2559     no)
2560       :
2561       ;;
2562     *)
2563       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2564 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2565    { (exit 1); exit 1; }; }
2566       ;;
2567   esac
2568
2569 else
2570   enable_spinlocks=yes
2571
2572 fi
2573
2574
2575
2576 #
2577 # --enable-debug adds -g to compiler flags
2578 #
2579
2580
2581 # Check whether --enable-debug was given.
2582 if test "${enable_debug+set}" = set; then
2583   enableval=$enable_debug;
2584   case $enableval in
2585     yes)
2586       :
2587       ;;
2588     no)
2589       :
2590       ;;
2591     *)
2592       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2593 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2594    { (exit 1); exit 1; }; }
2595       ;;
2596   esac
2597
2598 else
2599   enable_debug=no
2600
2601 fi
2602
2603
2604
2605
2606 #
2607 # --enable-profiling enables gcc profiling
2608 #
2609
2610
2611 # Check whether --enable-profiling was given.
2612 if test "${enable_profiling+set}" = set; then
2613   enableval=$enable_profiling;
2614   case $enableval in
2615     yes)
2616       :
2617       ;;
2618     no)
2619       :
2620       ;;
2621     *)
2622       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2623 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2624    { (exit 1); exit 1; }; }
2625       ;;
2626   esac
2627
2628 else
2629   enable_profiling=no
2630
2631 fi
2632
2633
2634
2635
2636 #
2637 # --enable-coverage enables generation of code coverage metrics with gcov
2638 #
2639
2640
2641 # Check whether --enable-coverage was given.
2642 if test "${enable_coverage+set}" = set; then
2643   enableval=$enable_coverage;
2644   case $enableval in
2645     yes)
2646       for ac_prog in gcov
2647 do
2648   # Extract the first word of "$ac_prog", so it can be a program name with args.
2649 set dummy $ac_prog; ac_word=$2
2650 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2651 $as_echo_n "checking for $ac_word... " >&6; }
2652 if test "${ac_cv_prog_GCOV+set}" = set; then
2653   $as_echo_n "(cached) " >&6
2654 else
2655   if test -n "$GCOV"; then
2656   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2657 else
2658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2659 for as_dir in $PATH
2660 do
2661   IFS=$as_save_IFS
2662   test -z "$as_dir" && as_dir=.
2663   for ac_exec_ext in '' $ac_executable_extensions; do
2664   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2665     ac_cv_prog_GCOV="$ac_prog"
2666     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2667     break 2
2668   fi
2669 done
2670 done
2671 IFS=$as_save_IFS
2672
2673 fi
2674 fi
2675 GCOV=$ac_cv_prog_GCOV
2676 if test -n "$GCOV"; then
2677   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2678 $as_echo "$GCOV" >&6; }
2679 else
2680   { $as_echo "$as_me:$LINENO: result: no" >&5
2681 $as_echo "no" >&6; }
2682 fi
2683
2684
2685   test -n "$GCOV" && break
2686 done
2687
2688 if test -z "$GCOV"; then
2689   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2690 $as_echo "$as_me: error: gcov not found" >&2;}
2691    { (exit 1); exit 1; }; }
2692 fi
2693 for ac_prog in lcov
2694 do
2695   # Extract the first word of "$ac_prog", so it can be a program name with args.
2696 set dummy $ac_prog; ac_word=$2
2697 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2698 $as_echo_n "checking for $ac_word... " >&6; }
2699 if test "${ac_cv_prog_LCOV+set}" = set; then
2700   $as_echo_n "(cached) " >&6
2701 else
2702   if test -n "$LCOV"; then
2703   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2704 else
2705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2706 for as_dir in $PATH
2707 do
2708   IFS=$as_save_IFS
2709   test -z "$as_dir" && as_dir=.
2710   for ac_exec_ext in '' $ac_executable_extensions; do
2711   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2712     ac_cv_prog_LCOV="$ac_prog"
2713     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2714     break 2
2715   fi
2716 done
2717 done
2718 IFS=$as_save_IFS
2719
2720 fi
2721 fi
2722 LCOV=$ac_cv_prog_LCOV
2723 if test -n "$LCOV"; then
2724   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2725 $as_echo "$LCOV" >&6; }
2726 else
2727   { $as_echo "$as_me:$LINENO: result: no" >&5
2728 $as_echo "no" >&6; }
2729 fi
2730
2731
2732   test -n "$LCOV" && break
2733 done
2734
2735 if test -z "$LCOV"; then
2736   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2737 $as_echo "$as_me: error: lcov not found" >&2;}
2738    { (exit 1); exit 1; }; }
2739 fi
2740 for ac_prog in genhtml
2741 do
2742   # Extract the first word of "$ac_prog", so it can be a program name with args.
2743 set dummy $ac_prog; ac_word=$2
2744 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2745 $as_echo_n "checking for $ac_word... " >&6; }
2746 if test "${ac_cv_prog_GENHTML+set}" = set; then
2747   $as_echo_n "(cached) " >&6
2748 else
2749   if test -n "$GENHTML"; then
2750   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2751 else
2752 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2753 for as_dir in $PATH
2754 do
2755   IFS=$as_save_IFS
2756   test -z "$as_dir" && as_dir=.
2757   for ac_exec_ext in '' $ac_executable_extensions; do
2758   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2759     ac_cv_prog_GENHTML="$ac_prog"
2760     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2761     break 2
2762   fi
2763 done
2764 done
2765 IFS=$as_save_IFS
2766
2767 fi
2768 fi
2769 GENHTML=$ac_cv_prog_GENHTML
2770 if test -n "$GENHTML"; then
2771   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2772 $as_echo "$GENHTML" >&6; }
2773 else
2774   { $as_echo "$as_me:$LINENO: result: no" >&5
2775 $as_echo "no" >&6; }
2776 fi
2777
2778
2779   test -n "$GENHTML" && break
2780 done
2781
2782 if test -z "$GENHTML"; then
2783   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2784 $as_echo "$as_me: error: genhtml not found" >&2;}
2785    { (exit 1); exit 1; }; }
2786 fi
2787       ;;
2788     no)
2789       :
2790       ;;
2791     *)
2792       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2793 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2794    { (exit 1); exit 1; }; }
2795       ;;
2796   esac
2797
2798 else
2799   enable_coverage=no
2800
2801 fi
2802
2803
2804
2805
2806 #
2807 # DTrace
2808 #
2809
2810
2811 # Check whether --enable-dtrace was given.
2812 if test "${enable_dtrace+set}" = set; then
2813   enableval=$enable_dtrace;
2814   case $enableval in
2815     yes)
2816
2817 cat >>confdefs.h <<\_ACEOF
2818 #define ENABLE_DTRACE 1
2819 _ACEOF
2820
2821 for ac_prog in dtrace
2822 do
2823   # Extract the first word of "$ac_prog", so it can be a program name with args.
2824 set dummy $ac_prog; ac_word=$2
2825 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2826 $as_echo_n "checking for $ac_word... " >&6; }
2827 if test "${ac_cv_prog_DTRACE+set}" = set; then
2828   $as_echo_n "(cached) " >&6
2829 else
2830   if test -n "$DTRACE"; then
2831   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2832 else
2833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2834 for as_dir in $PATH
2835 do
2836   IFS=$as_save_IFS
2837   test -z "$as_dir" && as_dir=.
2838   for ac_exec_ext in '' $ac_executable_extensions; do
2839   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2840     ac_cv_prog_DTRACE="$ac_prog"
2841     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2842     break 2
2843   fi
2844 done
2845 done
2846 IFS=$as_save_IFS
2847
2848 fi
2849 fi
2850 DTRACE=$ac_cv_prog_DTRACE
2851 if test -n "$DTRACE"; then
2852   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2853 $as_echo "$DTRACE" >&6; }
2854 else
2855   { $as_echo "$as_me:$LINENO: result: no" >&5
2856 $as_echo "no" >&6; }
2857 fi
2858
2859
2860   test -n "$DTRACE" && break
2861 done
2862
2863 if test -z "$DTRACE"; then
2864   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2865 $as_echo "$as_me: error: dtrace not found" >&2;}
2866    { (exit 1); exit 1; }; }
2867 fi
2868
2869       ;;
2870     no)
2871       :
2872       ;;
2873     *)
2874       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2875 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2876    { (exit 1); exit 1; }; }
2877       ;;
2878   esac
2879
2880 else
2881   enable_dtrace=no
2882
2883 fi
2884
2885
2886
2887
2888 #
2889 # Block size
2890 #
2891 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2892 $as_echo_n "checking for block size... " >&6; }
2893
2894
2895
2896 # Check whether --with-blocksize was given.
2897 if test "${with_blocksize+set}" = set; then
2898   withval=$with_blocksize;
2899   case $withval in
2900     yes)
2901       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2902 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2903    { (exit 1); exit 1; }; }
2904       ;;
2905     no)
2906       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2907 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2908    { (exit 1); exit 1; }; }
2909       ;;
2910     *)
2911       blocksize=$withval
2912       ;;
2913   esac
2914
2915 else
2916   blocksize=8
2917 fi
2918
2919
2920 case ${blocksize} in
2921   1) BLCKSZ=1024;;
2922   2) BLCKSZ=2048;;
2923   4) BLCKSZ=4096;;
2924   8) BLCKSZ=8192;;
2925  16) BLCKSZ=16384;;
2926  32) BLCKSZ=32768;;
2927   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2928 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2929    { (exit 1); exit 1; }; }
2930 esac
2931 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2932 $as_echo "${blocksize}kB" >&6; }
2933
2934
2935 cat >>confdefs.h <<_ACEOF
2936 #define BLCKSZ ${BLCKSZ}
2937 _ACEOF
2938
2939
2940 #
2941 # Relation segment size
2942 #
2943 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2944 $as_echo_n "checking for segment size... " >&6; }
2945
2946
2947
2948 # Check whether --with-segsize was given.
2949 if test "${with_segsize+set}" = set; then
2950   withval=$with_segsize;
2951   case $withval in
2952     yes)
2953       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2954 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2955    { (exit 1); exit 1; }; }
2956       ;;
2957     no)
2958       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2959 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2960    { (exit 1); exit 1; }; }
2961       ;;
2962     *)
2963       segsize=$withval
2964       ;;
2965   esac
2966
2967 else
2968   segsize=1
2969 fi
2970
2971
2972 # this expression is set up to avoid unnecessary integer overflow
2973 # blocksize is already guaranteed to be a factor of 1024
2974 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2975 test $? -eq 0 || exit 1
2976 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2977 $as_echo "${segsize}GB" >&6; }
2978
2979
2980 cat >>confdefs.h <<_ACEOF
2981 #define RELSEG_SIZE ${RELSEG_SIZE}
2982 _ACEOF
2983
2984
2985 #
2986 # WAL block size
2987 #
2988 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2989 $as_echo_n "checking for WAL block size... " >&6; }
2990
2991
2992
2993 # Check whether --with-wal-blocksize was given.
2994 if test "${with_wal_blocksize+set}" = set; then
2995   withval=$with_wal_blocksize;
2996   case $withval in
2997     yes)
2998       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2999 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
3000    { (exit 1); exit 1; }; }
3001       ;;
3002     no)
3003       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
3004 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
3005    { (exit 1); exit 1; }; }
3006       ;;
3007     *)
3008       wal_blocksize=$withval
3009       ;;
3010   esac
3011
3012 else
3013   wal_blocksize=8
3014 fi
3015
3016
3017 case ${wal_blocksize} in
3018   1) XLOG_BLCKSZ=1024;;
3019   2) XLOG_BLCKSZ=2048;;
3020   4) XLOG_BLCKSZ=4096;;
3021   8) XLOG_BLCKSZ=8192;;
3022  16) XLOG_BLCKSZ=16384;;
3023  32) XLOG_BLCKSZ=32768;;
3024  64) XLOG_BLCKSZ=65536;;
3025   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
3026 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3027    { (exit 1); exit 1; }; }
3028 esac
3029 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
3030 $as_echo "${wal_blocksize}kB" >&6; }
3031
3032
3033 cat >>confdefs.h <<_ACEOF
3034 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3035 _ACEOF
3036
3037
3038 #
3039 # WAL segment size
3040 #
3041 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
3042 $as_echo_n "checking for WAL segment size... " >&6; }
3043
3044
3045
3046 # Check whether --with-wal-segsize was given.
3047 if test "${with_wal_segsize+set}" = set; then
3048   withval=$with_wal_segsize;
3049   case $withval in
3050     yes)
3051       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3052 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3053    { (exit 1); exit 1; }; }
3054       ;;
3055     no)
3056       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3057 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3058    { (exit 1); exit 1; }; }
3059       ;;
3060     *)
3061       wal_segsize=$withval
3062       ;;
3063   esac
3064
3065 else
3066   wal_segsize=16
3067 fi
3068
3069
3070 case ${wal_segsize} in
3071   1) ;;
3072   2) ;;
3073   4) ;;
3074   8) ;;
3075  16) ;;
3076  32) ;;
3077  64) ;;
3078   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3079 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3080    { (exit 1); exit 1; }; }
3081 esac
3082 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3083 $as_echo "${wal_segsize}MB" >&6; }
3084
3085
3086 cat >>confdefs.h <<_ACEOF
3087 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3088 _ACEOF
3089
3090
3091 #
3092 # C compiler
3093 #
3094
3095 # For historical reasons you can also use --with-CC to specify the C compiler
3096 # to use, although the standard way to do this is to set the CC environment
3097 # variable.
3098
3099
3100
3101 # Check whether --with-CC was given.
3102 if test "${with_CC+set}" = set; then
3103   withval=$with_CC;
3104   case $withval in
3105     yes)
3106       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3107 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3108    { (exit 1); exit 1; }; }
3109       ;;
3110     no)
3111       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3112 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3113    { (exit 1); exit 1; }; }
3114       ;;
3115     *)
3116       CC=$with_CC
3117       ;;
3118   esac
3119
3120 fi
3121
3122
3123
3124 case $template in
3125   aix) pgac_cc_list="gcc xlc";;
3126  irix) pgac_cc_list="cc";; # no gcc
3127     *) pgac_cc_list="gcc cc";;
3128 esac
3129
3130 ac_ext=c
3131 ac_cpp='$CPP $CPPFLAGS'
3132 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3133 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3134 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3135 if test -n "$ac_tool_prefix"; then
3136   for ac_prog in $pgac_cc_list
3137   do
3138     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3139 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3140 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3141 $as_echo_n "checking for $ac_word... " >&6; }
3142 if test "${ac_cv_prog_CC+set}" = set; then
3143   $as_echo_n "(cached) " >&6
3144 else
3145   if test -n "$CC"; then
3146   ac_cv_prog_CC="$CC" # Let the user override the test.
3147 else
3148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3149 for as_dir in $PATH
3150 do
3151   IFS=$as_save_IFS
3152   test -z "$as_dir" && as_dir=.
3153   for ac_exec_ext in '' $ac_executable_extensions; do
3154   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3155     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3156     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3157     break 2
3158   fi
3159 done
3160 done
3161 IFS=$as_save_IFS
3162
3163 fi
3164 fi
3165 CC=$ac_cv_prog_CC
3166 if test -n "$CC"; then
3167   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3168 $as_echo "$CC" >&6; }
3169 else
3170   { $as_echo "$as_me:$LINENO: result: no" >&5
3171 $as_echo "no" >&6; }
3172 fi
3173
3174
3175     test -n "$CC" && break
3176   done
3177 fi
3178 if test -z "$CC"; then
3179   ac_ct_CC=$CC
3180   for ac_prog in $pgac_cc_list
3181 do
3182   # Extract the first word of "$ac_prog", so it can be a program name with args.
3183 set dummy $ac_prog; ac_word=$2
3184 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3185 $as_echo_n "checking for $ac_word... " >&6; }
3186 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3187   $as_echo_n "(cached) " >&6
3188 else
3189   if test -n "$ac_ct_CC"; then
3190   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3191 else
3192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3193 for as_dir in $PATH
3194 do
3195   IFS=$as_save_IFS
3196   test -z "$as_dir" && as_dir=.
3197   for ac_exec_ext in '' $ac_executable_extensions; do
3198   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3199     ac_cv_prog_ac_ct_CC="$ac_prog"
3200     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3201     break 2
3202   fi
3203 done
3204 done
3205 IFS=$as_save_IFS
3206
3207 fi
3208 fi
3209 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3210 if test -n "$ac_ct_CC"; then
3211   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3212 $as_echo "$ac_ct_CC" >&6; }
3213 else
3214   { $as_echo "$as_me:$LINENO: result: no" >&5
3215 $as_echo "no" >&6; }
3216 fi
3217
3218
3219   test -n "$ac_ct_CC" && break
3220 done
3221
3222   if test "x$ac_ct_CC" = x; then
3223     CC=""
3224   else
3225     case $cross_compiling:$ac_tool_warned in
3226 yes:)
3227 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3228 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3229 ac_tool_warned=yes ;;
3230 esac
3231     CC=$ac_ct_CC
3232   fi
3233 fi
3234
3235
3236 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3237 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3238 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3239 See \`config.log' for more details." >&5
3240 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3241 See \`config.log' for more details." >&2;}
3242    { (exit 1); exit 1; }; }; }
3243
3244 # Provide some information about the compiler.
3245 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3246 set X $ac_compile
3247 ac_compiler=$2
3248 { (ac_try="$ac_compiler --version >&5"
3249 case "(($ac_try" in
3250   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3251   *) ac_try_echo=$ac_try;;
3252 esac
3253 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3254 $as_echo "$ac_try_echo") >&5
3255   (eval "$ac_compiler --version >&5") 2>&5
3256   ac_status=$?
3257   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3258   (exit $ac_status); }
3259 { (ac_try="$ac_compiler -v >&5"
3260 case "(($ac_try" in
3261   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3262   *) ac_try_echo=$ac_try;;
3263 esac
3264 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3265 $as_echo "$ac_try_echo") >&5
3266   (eval "$ac_compiler -v >&5") 2>&5
3267   ac_status=$?
3268   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3269   (exit $ac_status); }
3270 { (ac_try="$ac_compiler -V >&5"
3271 case "(($ac_try" in
3272   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3273   *) ac_try_echo=$ac_try;;
3274 esac
3275 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3276 $as_echo "$ac_try_echo") >&5
3277   (eval "$ac_compiler -V >&5") 2>&5
3278   ac_status=$?
3279   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3280   (exit $ac_status); }
3281
3282 cat >conftest.$ac_ext <<_ACEOF
3283 /* confdefs.h.  */
3284 _ACEOF
3285 cat confdefs.h >>conftest.$ac_ext
3286 cat >>conftest.$ac_ext <<_ACEOF
3287 /* end confdefs.h.  */
3288
3289 int
3290 main ()
3291 {
3292
3293   ;
3294   return 0;
3295 }
3296 _ACEOF
3297 ac_clean_files_save=$ac_clean_files
3298 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3299 # Try to create an executable without -o first, disregard a.out.
3300 # It will help us diagnose broken compilers, and finding out an intuition
3301 # of exeext.
3302 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3303 $as_echo_n "checking for C compiler default output file name... " >&6; }
3304 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3305
3306 # The possible output files:
3307 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3308
3309 ac_rmfiles=
3310 for ac_file in $ac_files
3311 do
3312   case $ac_file in
3313     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3314     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3315   esac
3316 done
3317 rm -f $ac_rmfiles
3318
3319 if { (ac_try="$ac_link_default"
3320 case "(($ac_try" in
3321   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3322   *) ac_try_echo=$ac_try;;
3323 esac
3324 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3325 $as_echo "$ac_try_echo") >&5
3326   (eval "$ac_link_default") 2>&5
3327   ac_status=$?
3328   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3329   (exit $ac_status); }; then
3330   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3331 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3332 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3333 # so that the user can short-circuit this test for compilers unknown to
3334 # Autoconf.
3335 for ac_file in $ac_files ''
3336 do
3337   test -f "$ac_file" || continue
3338   case $ac_file in
3339     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3340         ;;
3341     [ab].out )
3342         # We found the default executable, but exeext='' is most
3343         # certainly right.
3344         break;;
3345     *.* )
3346         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3347         then :; else
3348            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3349         fi
3350         # We set ac_cv_exeext here because the later test for it is not
3351         # safe: cross compilers may not add the suffix if given an `-o'
3352         # argument, so we may need to know it at that point already.
3353         # Even if this section looks crufty: it has the advantage of
3354         # actually working.
3355         break;;
3356     * )
3357         break;;
3358   esac
3359 done
3360 test "$ac_cv_exeext" = no && ac_cv_exeext=
3361
3362 else
3363   ac_file=''
3364 fi
3365
3366 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3367 $as_echo "$ac_file" >&6; }
3368 if test -z "$ac_file"; then
3369   $as_echo "$as_me: failed program was:" >&5
3370 sed 's/^/| /' conftest.$ac_ext >&5
3371
3372 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3373 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3374 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3375 See \`config.log' for more details." >&5
3376 $as_echo "$as_me: error: C compiler cannot create executables
3377 See \`config.log' for more details." >&2;}
3378    { (exit 77); exit 77; }; }; }
3379 fi
3380
3381 ac_exeext=$ac_cv_exeext
3382
3383 # Check that the compiler produces executables we can run.  If not, either
3384 # the compiler is broken, or we cross compile.
3385 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3386 $as_echo_n "checking whether the C compiler works... " >&6; }
3387 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3388 # If not cross compiling, check that we can run a simple program.
3389 if test "$cross_compiling" != yes; then
3390   if { ac_try='./$ac_file'
3391   { (case "(($ac_try" in
3392   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3393   *) ac_try_echo=$ac_try;;
3394 esac
3395 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3396 $as_echo "$ac_try_echo") >&5
3397   (eval "$ac_try") 2>&5
3398   ac_status=$?
3399   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3400   (exit $ac_status); }; }; then
3401     cross_compiling=no
3402   else
3403     if test "$cross_compiling" = maybe; then
3404         cross_compiling=yes
3405     else
3406         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3407 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3408 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3409 If you meant to cross compile, use \`--host'.
3410 See \`config.log' for more details." >&5
3411 $as_echo "$as_me: error: cannot run C compiled programs.
3412 If you meant to cross compile, use \`--host'.
3413 See \`config.log' for more details." >&2;}
3414    { (exit 1); exit 1; }; }; }
3415     fi
3416   fi
3417 fi
3418 { $as_echo "$as_me:$LINENO: result: yes" >&5
3419 $as_echo "yes" >&6; }
3420
3421 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3422 ac_clean_files=$ac_clean_files_save
3423 # Check that the compiler produces executables we can run.  If not, either
3424 # the compiler is broken, or we cross compile.
3425 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3426 $as_echo_n "checking whether we are cross compiling... " >&6; }
3427 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3428 $as_echo "$cross_compiling" >&6; }
3429
3430 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3431 $as_echo_n "checking for suffix of executables... " >&6; }
3432 if { (ac_try="$ac_link"
3433 case "(($ac_try" in
3434   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3435   *) ac_try_echo=$ac_try;;
3436 esac
3437 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3438 $as_echo "$ac_try_echo") >&5
3439   (eval "$ac_link") 2>&5
3440   ac_status=$?
3441   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3442   (exit $ac_status); }; then
3443   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3444 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3445 # work properly (i.e., refer to `conftest.exe'), while it won't with
3446 # `rm'.
3447 for ac_file in conftest.exe conftest conftest.*; do
3448   test -f "$ac_file" || continue
3449   case $ac_file in
3450     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3451     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3452           break;;
3453     * ) break;;
3454   esac
3455 done
3456 else
3457   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3458 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3459 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3460 See \`config.log' for more details." >&5
3461 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3462 See \`config.log' for more details." >&2;}
3463    { (exit 1); exit 1; }; }; }
3464 fi
3465
3466 rm -f conftest$ac_cv_exeext
3467 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3468 $as_echo "$ac_cv_exeext" >&6; }
3469
3470 rm -f conftest.$ac_ext
3471 EXEEXT=$ac_cv_exeext
3472 ac_exeext=$EXEEXT
3473 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3474 $as_echo_n "checking for suffix of object files... " >&6; }
3475 if test "${ac_cv_objext+set}" = set; then
3476   $as_echo_n "(cached) " >&6
3477 else
3478   cat >conftest.$ac_ext <<_ACEOF
3479 /* confdefs.h.  */
3480 _ACEOF
3481 cat confdefs.h >>conftest.$ac_ext
3482 cat >>conftest.$ac_ext <<_ACEOF
3483 /* end confdefs.h.  */
3484
3485 int
3486 main ()
3487 {
3488
3489   ;
3490   return 0;
3491 }
3492 _ACEOF
3493 rm -f conftest.o conftest.obj
3494 if { (ac_try="$ac_compile"
3495 case "(($ac_try" in
3496   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3497   *) ac_try_echo=$ac_try;;
3498 esac
3499 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3500 $as_echo "$ac_try_echo") >&5
3501   (eval "$ac_compile") 2>&5
3502   ac_status=$?
3503   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3504   (exit $ac_status); }; then
3505   for ac_file in conftest.o conftest.obj conftest.*; do
3506   test -f "$ac_file" || continue;
3507   case $ac_file in
3508     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3509     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3510        break;;
3511   esac
3512 done
3513 else
3514   $as_echo "$as_me: failed program was:" >&5
3515 sed 's/^/| /' conftest.$ac_ext >&5
3516
3517 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3518 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3519 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3520 See \`config.log' for more details." >&5
3521 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3522 See \`config.log' for more details." >&2;}
3523    { (exit 1); exit 1; }; }; }
3524 fi
3525
3526 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3527 fi
3528 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3529 $as_echo "$ac_cv_objext" >&6; }
3530 OBJEXT=$ac_cv_objext
3531 ac_objext=$OBJEXT
3532 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3533 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3534 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3535   $as_echo_n "(cached) " >&6
3536 else
3537   cat >conftest.$ac_ext <<_ACEOF
3538 /* confdefs.h.  */
3539 _ACEOF
3540 cat confdefs.h >>conftest.$ac_ext
3541 cat >>conftest.$ac_ext <<_ACEOF
3542 /* end confdefs.h.  */
3543
3544 int
3545 main ()
3546 {
3547 #ifndef __GNUC__
3548        choke me
3549 #endif
3550
3551   ;
3552   return 0;
3553 }
3554 _ACEOF
3555 rm -f conftest.$ac_objext
3556 if { (ac_try="$ac_compile"
3557 case "(($ac_try" in
3558   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3559   *) ac_try_echo=$ac_try;;
3560 esac
3561 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3562 $as_echo "$ac_try_echo") >&5
3563   (eval "$ac_compile") 2>conftest.er1
3564   ac_status=$?
3565   grep -v '^ *+' conftest.er1 >conftest.err
3566   rm -f conftest.er1
3567   cat conftest.err >&5
3568   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3569   (exit $ac_status); } && {
3570          test -z "$ac_c_werror_flag" ||
3571          test ! -s conftest.err
3572        } && test -s conftest.$ac_objext; then
3573   ac_compiler_gnu=yes
3574 else
3575   $as_echo "$as_me: failed program was:" >&5
3576 sed 's/^/| /' conftest.$ac_ext >&5
3577
3578         ac_compiler_gnu=no
3579 fi
3580
3581 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3582 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3583
3584 fi
3585 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3586 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3587 if test $ac_compiler_gnu = yes; then
3588   GCC=yes
3589 else
3590   GCC=
3591 fi
3592 ac_test_CFLAGS=${CFLAGS+set}
3593 ac_save_CFLAGS=$CFLAGS
3594 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3595 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3596 if test "${ac_cv_prog_cc_g+set}" = set; then
3597   $as_echo_n "(cached) " >&6
3598 else
3599   ac_save_c_werror_flag=$ac_c_werror_flag
3600    ac_c_werror_flag=yes
3601    ac_cv_prog_cc_g=no
3602    CFLAGS="-g"
3603    cat >conftest.$ac_ext <<_ACEOF
3604 /* confdefs.h.  */
3605 _ACEOF
3606 cat confdefs.h >>conftest.$ac_ext
3607 cat >>conftest.$ac_ext <<_ACEOF
3608 /* end confdefs.h.  */
3609
3610 int
3611 main ()
3612 {
3613
3614   ;
3615   return 0;
3616 }
3617 _ACEOF
3618 rm -f conftest.$ac_objext
3619 if { (ac_try="$ac_compile"
3620 case "(($ac_try" in
3621   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3622   *) ac_try_echo=$ac_try;;
3623 esac
3624 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3625 $as_echo "$ac_try_echo") >&5
3626   (eval "$ac_compile") 2>conftest.er1
3627   ac_status=$?
3628   grep -v '^ *+' conftest.er1 >conftest.err
3629   rm -f conftest.er1
3630   cat conftest.err >&5
3631   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3632   (exit $ac_status); } && {
3633          test -z "$ac_c_werror_flag" ||
3634          test ! -s conftest.err
3635        } && test -s conftest.$ac_objext; then
3636   ac_cv_prog_cc_g=yes
3637 else
3638   $as_echo "$as_me: failed program was:" >&5
3639 sed 's/^/| /' conftest.$ac_ext >&5
3640
3641         CFLAGS=""
3642       cat >conftest.$ac_ext <<_ACEOF
3643 /* confdefs.h.  */
3644 _ACEOF
3645 cat confdefs.h >>conftest.$ac_ext
3646 cat >>conftest.$ac_ext <<_ACEOF
3647 /* end confdefs.h.  */
3648
3649 int
3650 main ()
3651 {
3652
3653   ;
3654   return 0;
3655 }
3656 _ACEOF
3657 rm -f conftest.$ac_objext
3658 if { (ac_try="$ac_compile"
3659 case "(($ac_try" in
3660   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3661   *) ac_try_echo=$ac_try;;
3662 esac
3663 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3664 $as_echo "$ac_try_echo") >&5
3665   (eval "$ac_compile") 2>conftest.er1
3666   ac_status=$?
3667   grep -v '^ *+' conftest.er1 >conftest.err
3668   rm -f conftest.er1
3669   cat conftest.err >&5
3670   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3671   (exit $ac_status); } && {
3672          test -z "$ac_c_werror_flag" ||
3673          test ! -s conftest.err
3674        } && test -s conftest.$ac_objext; then
3675   :
3676 else
3677   $as_echo "$as_me: failed program was:" >&5
3678 sed 's/^/| /' conftest.$ac_ext >&5
3679
3680         ac_c_werror_flag=$ac_save_c_werror_flag
3681          CFLAGS="-g"
3682          cat >conftest.$ac_ext <<_ACEOF
3683 /* confdefs.h.  */
3684 _ACEOF
3685 cat confdefs.h >>conftest.$ac_ext
3686 cat >>conftest.$ac_ext <<_ACEOF
3687 /* end confdefs.h.  */
3688
3689 int
3690 main ()
3691 {
3692
3693   ;
3694   return 0;
3695 }
3696 _ACEOF
3697 rm -f conftest.$ac_objext
3698 if { (ac_try="$ac_compile"
3699 case "(($ac_try" in
3700   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3701   *) ac_try_echo=$ac_try;;
3702 esac
3703 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3704 $as_echo "$ac_try_echo") >&5
3705   (eval "$ac_compile") 2>conftest.er1
3706   ac_status=$?
3707   grep -v '^ *+' conftest.er1 >conftest.err
3708   rm -f conftest.er1
3709   cat conftest.err >&5
3710   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3711   (exit $ac_status); } && {
3712          test -z "$ac_c_werror_flag" ||
3713          test ! -s conftest.err
3714        } && test -s conftest.$ac_objext; then
3715   ac_cv_prog_cc_g=yes
3716 else
3717   $as_echo "$as_me: failed program was:" >&5
3718 sed 's/^/| /' conftest.$ac_ext >&5
3719
3720
3721 fi
3722
3723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3724 fi
3725
3726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3727 fi
3728
3729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3730    ac_c_werror_flag=$ac_save_c_werror_flag
3731 fi
3732 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3733 $as_echo "$ac_cv_prog_cc_g" >&6; }
3734 if test "$ac_test_CFLAGS" = set; then
3735   CFLAGS=$ac_save_CFLAGS
3736 elif test $ac_cv_prog_cc_g = yes; then
3737   if test "$GCC" = yes; then
3738     CFLAGS="-g -O2"
3739   else
3740     CFLAGS="-g"
3741   fi
3742 else
3743   if test "$GCC" = yes; then
3744     CFLAGS="-O2"
3745   else
3746     CFLAGS=
3747   fi
3748 fi
3749 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3750 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3751 if test "${ac_cv_prog_cc_c89+set}" = set; then
3752   $as_echo_n "(cached) " >&6
3753 else
3754   ac_cv_prog_cc_c89=no
3755 ac_save_CC=$CC
3756 cat >conftest.$ac_ext <<_ACEOF
3757 /* confdefs.h.  */
3758 _ACEOF
3759 cat confdefs.h >>conftest.$ac_ext
3760 cat >>conftest.$ac_ext <<_ACEOF
3761 /* end confdefs.h.  */
3762 #include <stdarg.h>
3763 #include <stdio.h>
3764 #include <sys/types.h>
3765 #include <sys/stat.h>
3766 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3767 struct buf { int x; };
3768 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3769 static char *e (p, i)
3770      char **p;
3771      int i;
3772 {
3773   return p[i];
3774 }
3775 static char *f (char * (*g) (char **, int), char **p, ...)
3776 {
3777   char *s;
3778   va_list v;
3779   va_start (v,p);
3780   s = g (p, va_arg (v,int));
3781   va_end (v);
3782   return s;
3783 }
3784
3785 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3786    function prototypes and stuff, but not '\xHH' hex character constants.
3787    These don't provoke an error unfortunately, instead are silently treated
3788    as 'x'.  The following induces an error, until -std is added to get
3789    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3790    array size at least.  It's necessary to write '\x00'==0 to get something
3791    that's true only with -std.  */
3792 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3793
3794 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3795    inside strings and character constants.  */
3796 #define FOO(x) 'x'
3797 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3798
3799 int test (int i, double x);
3800 struct s1 {int (*f) (int a);};
3801 struct s2 {int (*f) (double a);};
3802 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3803 int argc;
3804 char **argv;
3805 int
3806 main ()
3807 {
3808 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3809   ;
3810   return 0;
3811 }
3812 _ACEOF
3813 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3814         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3815 do
3816   CC="$ac_save_CC $ac_arg"
3817   rm -f conftest.$ac_objext
3818 if { (ac_try="$ac_compile"
3819 case "(($ac_try" in
3820   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3821   *) ac_try_echo=$ac_try;;
3822 esac
3823 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3824 $as_echo "$ac_try_echo") >&5
3825   (eval "$ac_compile") 2>conftest.er1
3826   ac_status=$?
3827   grep -v '^ *+' conftest.er1 >conftest.err
3828   rm -f conftest.er1
3829   cat conftest.err >&5
3830   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3831   (exit $ac_status); } && {
3832          test -z "$ac_c_werror_flag" ||
3833          test ! -s conftest.err
3834        } && test -s conftest.$ac_objext; then
3835   ac_cv_prog_cc_c89=$ac_arg
3836 else
3837   $as_echo "$as_me: failed program was:" >&5
3838 sed 's/^/| /' conftest.$ac_ext >&5
3839
3840
3841 fi
3842
3843 rm -f core conftest.err conftest.$ac_objext
3844   test "x$ac_cv_prog_cc_c89" != "xno" && break
3845 done
3846 rm -f conftest.$ac_ext
3847 CC=$ac_save_CC
3848
3849 fi
3850 # AC_CACHE_VAL
3851 case "x$ac_cv_prog_cc_c89" in
3852   x)
3853     { $as_echo "$as_me:$LINENO: result: none needed" >&5
3854 $as_echo "none needed" >&6; } ;;
3855   xno)
3856     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3857 $as_echo "unsupported" >&6; } ;;
3858   *)
3859     CC="$CC $ac_cv_prog_cc_c89"
3860     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3861 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3862 esac
3863
3864
3865 ac_ext=c
3866 ac_cpp='$CPP $CPPFLAGS'
3867 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3868 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3869 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3870
3871
3872 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3873 # but has idiosyncrasies of its own.  We assume icc will define
3874 # __INTEL_COMPILER regardless of CFLAGS.
3875
3876 cat >conftest.$ac_ext <<_ACEOF
3877 /* confdefs.h.  */
3878 _ACEOF
3879 cat confdefs.h >>conftest.$ac_ext
3880 cat >>conftest.$ac_ext <<_ACEOF
3881 /* end confdefs.h.  */
3882
3883 int
3884 main ()
3885 {
3886 #ifndef __INTEL_COMPILER
3887 choke me
3888 #endif
3889   ;
3890   return 0;
3891 }
3892 _ACEOF
3893 rm -f conftest.$ac_objext
3894 if { (ac_try="$ac_compile"
3895 case "(($ac_try" in
3896   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3897   *) ac_try_echo=$ac_try;;
3898 esac
3899 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3900 $as_echo "$ac_try_echo") >&5
3901   (eval "$ac_compile") 2>conftest.er1
3902   ac_status=$?
3903   grep -v '^ *+' conftest.er1 >conftest.err
3904   rm -f conftest.er1
3905   cat conftest.err >&5
3906   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3907   (exit $ac_status); } && {
3908          test -z "$ac_c_werror_flag" ||
3909          test ! -s conftest.err
3910        } && test -s conftest.$ac_objext; then
3911   ICC=yes
3912 else
3913   $as_echo "$as_me: failed program was:" >&5
3914 sed 's/^/| /' conftest.$ac_ext >&5
3915
3916         ICC=no
3917 fi
3918
3919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3920
3921 # Check if it's Sun Studio compiler. We assume that
3922 # __SUNPRO_C will be defined for Sun Studio compilers
3923 cat >conftest.$ac_ext <<_ACEOF
3924 /* confdefs.h.  */
3925 _ACEOF
3926 cat confdefs.h >>conftest.$ac_ext
3927 cat >>conftest.$ac_ext <<_ACEOF
3928 /* end confdefs.h.  */
3929
3930 int
3931 main ()
3932 {
3933 #ifndef __SUNPRO_C
3934 choke me
3935 #endif
3936   ;
3937   return 0;
3938 }
3939 _ACEOF
3940 rm -f conftest.$ac_objext
3941 if { (ac_try="$ac_compile"
3942 case "(($ac_try" in
3943   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3944   *) ac_try_echo=$ac_try;;
3945 esac
3946 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3947 $as_echo "$ac_try_echo") >&5
3948   (eval "$ac_compile") 2>conftest.er1
3949   ac_status=$?
3950   grep -v '^ *+' conftest.er1 >conftest.err
3951   rm -f conftest.er1
3952   cat conftest.err >&5
3953   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3954   (exit $ac_status); } && {
3955          test -z "$ac_c_werror_flag" ||
3956          test ! -s conftest.err
3957        } && test -s conftest.$ac_objext; then
3958   SUN_STUDIO_CC=yes
3959 else
3960   $as_echo "$as_me: failed program was:" >&5
3961 sed 's/^/| /' conftest.$ac_ext >&5
3962
3963         SUN_STUDIO_CC=no
3964 fi
3965
3966 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3967
3968
3969
3970 unset CFLAGS
3971
3972 #
3973 # Read the template
3974 #
3975 . "$srcdir/src/template/$template" || exit
3976
3977 # CFLAGS are selected so:
3978 # If the user specifies something in the environment, that is used.
3979 # else:  If the template file set something, that is used.
3980 # else:  If coverage was enabled, don't set anything.
3981 # else:  If the compiler is GCC, then we use -O2.
3982 # else:  If the compiler is something else, then we use -O, unless debugging.
3983
3984 if test "$ac_env_CFLAGS_set" = set; then
3985   CFLAGS=$ac_env_CFLAGS_value
3986 elif test "${CFLAGS+set}" = set; then
3987   : # (keep what template set)
3988 elif test "$enable_coverage" = yes; then
3989   : # no optimization by default
3990 elif test "$GCC" = yes; then
3991   CFLAGS="-O2"
3992 else
3993   # if the user selected debug mode, don't use -O
3994   if test "$enable_debug" != yes; then
3995     CFLAGS="-O"
3996   fi
3997 fi
3998
3999 # Some versions of GCC support some additional useful warning flags.
4000 # Check whether they are supported, and add them to CFLAGS if so.
4001 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
4002 # but has its own.  Also check other compiler-specific flags here.
4003
4004 if test "$GCC" = yes -a "$ICC" = no; then
4005   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
4006   # These work in some but not all gcc versions
4007   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wdeclaration-after-statement" >&5
4008 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
4009 if test "${pgac_cv_prog_cc_cflags__Wdeclaration_after_statement+set}" = set; then
4010   $as_echo_n "(cached) " >&6
4011 else
4012   pgac_save_CFLAGS=$CFLAGS
4013 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
4014 cat >conftest.$ac_ext <<_ACEOF
4015 /* confdefs.h.  */
4016 _ACEOF
4017 cat confdefs.h >>conftest.$ac_ext
4018 cat >>conftest.$ac_ext <<_ACEOF
4019 /* end confdefs.h.  */
4020
4021 int
4022 main ()
4023 {
4024
4025   ;
4026   return 0;
4027 }
4028 _ACEOF
4029 rm -f conftest.$ac_objext
4030 if { (ac_try="$ac_compile"
4031 case "(($ac_try" in
4032   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4033   *) ac_try_echo=$ac_try;;
4034 esac
4035 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4036 $as_echo "$ac_try_echo") >&5
4037   (eval "$ac_compile") 2>conftest.er1
4038   ac_status=$?
4039   grep -v '^ *+' conftest.er1 >conftest.err
4040   rm -f conftest.er1
4041   cat conftest.err >&5
4042   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4043   (exit $ac_status); } && {
4044          test -z "$ac_c_werror_flag" ||
4045          test ! -s conftest.err
4046        } && test -s conftest.$ac_objext; then
4047   pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=yes
4048 else
4049   $as_echo "$as_me: failed program was:" >&5
4050 sed 's/^/| /' conftest.$ac_ext >&5
4051
4052         pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=no
4053 fi
4054
4055 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4056 CFLAGS="$pgac_save_CFLAGS"
4057 fi
4058 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&5
4059 $as_echo "$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&6; }
4060 if test x"$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" = x"yes"; then
4061   CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4062 fi
4063
4064   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wendif-labels" >&5
4065 $as_echo_n "checking whether $CC supports -Wendif-labels... " >&6; }
4066 if test "${pgac_cv_prog_cc_cflags__Wendif_labels+set}" = set; then
4067   $as_echo_n "(cached) " >&6
4068 else
4069   pgac_save_CFLAGS=$CFLAGS
4070 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4071 cat >conftest.$ac_ext <<_ACEOF
4072 /* confdefs.h.  */
4073 _ACEOF
4074 cat confdefs.h >>conftest.$ac_ext
4075 cat >>conftest.$ac_ext <<_ACEOF
4076 /* end confdefs.h.  */
4077
4078 int
4079 main ()
4080 {
4081
4082   ;
4083   return 0;
4084 }
4085 _ACEOF
4086 rm -f conftest.$ac_objext
4087 if { (ac_try="$ac_compile"
4088 case "(($ac_try" in
4089   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4090   *) ac_try_echo=$ac_try;;
4091 esac
4092 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4093 $as_echo "$ac_try_echo") >&5
4094   (eval "$ac_compile") 2>conftest.er1
4095   ac_status=$?
4096   grep -v '^ *+' conftest.er1 >conftest.err
4097   rm -f conftest.er1
4098   cat conftest.err >&5
4099   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4100   (exit $ac_status); } && {
4101          test -z "$ac_c_werror_flag" ||
4102          test ! -s conftest.err
4103        } && test -s conftest.$ac_objext; then
4104   pgac_cv_prog_cc_cflags__Wendif_labels=yes
4105 else
4106   $as_echo "$as_me: failed program was:" >&5
4107 sed 's/^/| /' conftest.$ac_ext >&5
4108
4109         pgac_cv_prog_cc_cflags__Wendif_labels=no
4110 fi
4111
4112 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4113 CFLAGS="$pgac_save_CFLAGS"
4114 fi
4115 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wendif_labels" >&5
4116 $as_echo "$pgac_cv_prog_cc_cflags__Wendif_labels" >&6; }
4117 if test x"$pgac_cv_prog_cc_cflags__Wendif_labels" = x"yes"; then
4118   CFLAGS="$CFLAGS -Wendif-labels"
4119 fi
4120
4121   # This was included in -Wall/-Wformat in older GCC versions
4122   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wformat-security" >&5
4123 $as_echo_n "checking whether $CC supports -Wformat-security... " >&6; }
4124 if test "${pgac_cv_prog_cc_cflags__Wformat_security+set}" = set; then
4125   $as_echo_n "(cached) " >&6
4126 else
4127   pgac_save_CFLAGS=$CFLAGS
4128 CFLAGS="$pgac_save_CFLAGS -Wformat-security"
4129 cat >conftest.$ac_ext <<_ACEOF
4130 /* confdefs.h.  */
4131 _ACEOF
4132 cat confdefs.h >>conftest.$ac_ext
4133 cat >>conftest.$ac_ext <<_ACEOF
4134 /* end confdefs.h.  */
4135
4136 int
4137 main ()
4138 {
4139
4140   ;
4141   return 0;
4142 }
4143 _ACEOF
4144 rm -f conftest.$ac_objext
4145 if { (ac_try="$ac_compile"
4146 case "(($ac_try" in
4147   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4148   *) ac_try_echo=$ac_try;;
4149 esac
4150 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4151 $as_echo "$ac_try_echo") >&5
4152   (eval "$ac_compile") 2>conftest.er1
4153   ac_status=$?
4154   grep -v '^ *+' conftest.er1 >conftest.err
4155   rm -f conftest.er1
4156   cat conftest.err >&5
4157   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4158   (exit $ac_status); } && {
4159          test -z "$ac_c_werror_flag" ||
4160          test ! -s conftest.err
4161        } && test -s conftest.$ac_objext; then
4162   pgac_cv_prog_cc_cflags__Wformat_security=yes
4163 else
4164   $as_echo "$as_me: failed program was:" >&5
4165 sed 's/^/| /' conftest.$ac_ext >&5
4166
4167         pgac_cv_prog_cc_cflags__Wformat_security=no
4168 fi
4169
4170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4171 CFLAGS="$pgac_save_CFLAGS"
4172 fi
4173 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wformat_security" >&5
4174 $as_echo "$pgac_cv_prog_cc_cflags__Wformat_security" >&6; }
4175 if test x"$pgac_cv_prog_cc_cflags__Wformat_security" = x"yes"; then
4176   CFLAGS="$CFLAGS -Wformat-security"
4177 fi
4178
4179   # Disable strict-aliasing rules; needed for gcc 3.3+
4180   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4181 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4182 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4183   $as_echo_n "(cached) " >&6
4184 else
4185   pgac_save_CFLAGS=$CFLAGS
4186 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4187 cat >conftest.$ac_ext <<_ACEOF
4188 /* confdefs.h.  */
4189 _ACEOF
4190 cat confdefs.h >>conftest.$ac_ext
4191 cat >>conftest.$ac_ext <<_ACEOF
4192 /* end confdefs.h.  */
4193
4194 int
4195 main ()
4196 {
4197
4198   ;
4199   return 0;
4200 }
4201 _ACEOF
4202 rm -f conftest.$ac_objext
4203 if { (ac_try="$ac_compile"
4204 case "(($ac_try" in
4205   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4206   *) ac_try_echo=$ac_try;;
4207 esac
4208 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4209 $as_echo "$ac_try_echo") >&5
4210   (eval "$ac_compile") 2>conftest.er1
4211   ac_status=$?
4212   grep -v '^ *+' conftest.er1 >conftest.err
4213   rm -f conftest.er1
4214   cat conftest.err >&5
4215   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4216   (exit $ac_status); } && {
4217          test -z "$ac_c_werror_flag" ||
4218          test ! -s conftest.err
4219        } && test -s conftest.$ac_objext; then
4220   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4221 else
4222   $as_echo "$as_me: failed program was:" >&5
4223 sed 's/^/| /' conftest.$ac_ext >&5
4224
4225         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4226 fi
4227
4228 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4229 CFLAGS="$pgac_save_CFLAGS"
4230 fi
4231 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4232 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4233 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4234   CFLAGS="$CFLAGS -fno-strict-aliasing"
4235 fi
4236
4237   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4238   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fwrapv" >&5
4239 $as_echo_n "checking whether $CC supports -fwrapv... " >&6; }
4240 if test "${pgac_cv_prog_cc_cflags__fwrapv+set}" = set; then
4241   $as_echo_n "(cached) " >&6
4242 else
4243   pgac_save_CFLAGS=$CFLAGS
4244 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4245 cat >conftest.$ac_ext <<_ACEOF
4246 /* confdefs.h.  */
4247 _ACEOF
4248 cat confdefs.h >>conftest.$ac_ext
4249 cat >>conftest.$ac_ext <<_ACEOF
4250 /* end confdefs.h.  */
4251
4252 int
4253 main ()
4254 {
4255
4256   ;
4257   return 0;
4258 }
4259 _ACEOF
4260 rm -f conftest.$ac_objext
4261 if { (ac_try="$ac_compile"
4262 case "(($ac_try" in
4263   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4264   *) ac_try_echo=$ac_try;;
4265 esac
4266 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4267 $as_echo "$ac_try_echo") >&5
4268   (eval "$ac_compile") 2>conftest.er1
4269   ac_status=$?
4270   grep -v '^ *+' conftest.er1 >conftest.err
4271   rm -f conftest.er1
4272   cat conftest.err >&5
4273   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4274   (exit $ac_status); } && {
4275          test -z "$ac_c_werror_flag" ||
4276          test ! -s conftest.err
4277        } && test -s conftest.$ac_objext; then
4278   pgac_cv_prog_cc_cflags__fwrapv=yes
4279 else
4280   $as_echo "$as_me: failed program was:" >&5
4281 sed 's/^/| /' conftest.$ac_ext >&5
4282
4283         pgac_cv_prog_cc_cflags__fwrapv=no
4284 fi
4285
4286 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4287 CFLAGS="$pgac_save_CFLAGS"
4288 fi
4289 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fwrapv" >&5
4290 $as_echo "$pgac_cv_prog_cc_cflags__fwrapv" >&6; }
4291 if test x"$pgac_cv_prog_cc_cflags__fwrapv" = x"yes"; then
4292   CFLAGS="$CFLAGS -fwrapv"
4293 fi
4294
4295 elif test "$ICC" = yes; then
4296   # Intel's compiler has a bug/misoptimization in checking for
4297   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4298   { $as_echo "$as_me:$LINENO: checking whether $CC supports -mp1" >&5
4299 $as_echo_n "checking whether $CC supports -mp1... " >&6; }
4300 if test "${pgac_cv_prog_cc_cflags__mp1+set}" = set; then
4301   $as_echo_n "(cached) " >&6
4302 else
4303   pgac_save_CFLAGS=$CFLAGS
4304 CFLAGS="$pgac_save_CFLAGS -mp1"
4305 cat >conftest.$ac_ext <<_ACEOF
4306 /* confdefs.h.  */
4307 _ACEOF
4308 cat confdefs.h >>conftest.$ac_ext
4309 cat >>conftest.$ac_ext <<_ACEOF
4310 /* end confdefs.h.  */
4311
4312 int
4313 main ()
4314 {
4315
4316   ;
4317   return 0;
4318 }
4319 _ACEOF
4320 rm -f conftest.$ac_objext
4321 if { (ac_try="$ac_compile"
4322 case "(($ac_try" in
4323   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4324   *) ac_try_echo=$ac_try;;
4325 esac
4326 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4327 $as_echo "$ac_try_echo") >&5
4328   (eval "$ac_compile") 2>conftest.er1
4329   ac_status=$?
4330   grep -v '^ *+' conftest.er1 >conftest.err
4331   rm -f conftest.er1
4332   cat conftest.err >&5
4333   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4334   (exit $ac_status); } && {
4335          test -z "$ac_c_werror_flag" ||
4336          test ! -s conftest.err
4337        } && test -s conftest.$ac_objext; then
4338   pgac_cv_prog_cc_cflags__mp1=yes
4339 else
4340   $as_echo "$as_me: failed program was:" >&5
4341 sed 's/^/| /' conftest.$ac_ext >&5
4342
4343         pgac_cv_prog_cc_cflags__mp1=no
4344 fi
4345
4346 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4347 CFLAGS="$pgac_save_CFLAGS"
4348 fi
4349 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__mp1" >&5
4350 $as_echo "$pgac_cv_prog_cc_cflags__mp1" >&6; }
4351 if test x"$pgac_cv_prog_cc_cflags__mp1" = x"yes"; then
4352   CFLAGS="$CFLAGS -mp1"
4353 fi
4354
4355   # Make sure strict aliasing is off (though this is said to be the default)
4356   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4357 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4358 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4359   $as_echo_n "(cached) " >&6
4360 else
4361   pgac_save_CFLAGS=$CFLAGS
4362 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4363 cat >conftest.$ac_ext <<_ACEOF
4364 /* confdefs.h.  */
4365 _ACEOF
4366 cat confdefs.h >>conftest.$ac_ext
4367 cat >>conftest.$ac_ext <<_ACEOF
4368 /* end confdefs.h.  */
4369
4370 int
4371 main ()
4372 {
4373
4374   ;
4375   return 0;
4376 }
4377 _ACEOF
4378 rm -f conftest.$ac_objext
4379 if { (ac_try="$ac_compile"
4380 case "(($ac_try" in
4381   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4382   *) ac_try_echo=$ac_try;;
4383 esac
4384 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4385 $as_echo "$ac_try_echo") >&5
4386   (eval "$ac_compile") 2>conftest.er1
4387   ac_status=$?
4388   grep -v '^ *+' conftest.er1 >conftest.err
4389   rm -f conftest.er1
4390   cat conftest.err >&5
4391   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4392   (exit $ac_status); } && {
4393          test -z "$ac_c_werror_flag" ||
4394          test ! -s conftest.err
4395        } && test -s conftest.$ac_objext; then
4396   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4397 else
4398   $as_echo "$as_me: failed program was:" >&5
4399 sed 's/^/| /' conftest.$ac_ext >&5
4400
4401         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4402 fi
4403
4404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4405 CFLAGS="$pgac_save_CFLAGS"
4406 fi
4407 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4408 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4409 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4410   CFLAGS="$CFLAGS -fno-strict-aliasing"
4411 fi
4412
4413 elif test "$PORTNAME" = "aix"; then
4414   # AIX's xlc has to have strict aliasing turned off too
4415   { $as_echo "$as_me:$LINENO: checking whether $CC supports -qnoansialias" >&5
4416 $as_echo_n "checking whether $CC supports -qnoansialias... " >&6; }
4417 if test "${pgac_cv_prog_cc_cflags__qnoansialias+set}" = set; then
4418   $as_echo_n "(cached) " >&6
4419 else
4420   pgac_save_CFLAGS=$CFLAGS
4421 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4422 cat >conftest.$ac_ext <<_ACEOF
4423 /* confdefs.h.  */
4424 _ACEOF
4425 cat confdefs.h >>conftest.$ac_ext
4426 cat >>conftest.$ac_ext <<_ACEOF
4427 /* end confdefs.h.  */
4428
4429 int
4430 main ()
4431 {
4432
4433   ;
4434   return 0;
4435 }
4436 _ACEOF
4437 rm -f conftest.$ac_objext
4438 if { (ac_try="$ac_compile"
4439 case "(($ac_try" in
4440   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4441   *) ac_try_echo=$ac_try;;
4442 esac
4443 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4444 $as_echo "$ac_try_echo") >&5
4445   (eval "$ac_compile") 2>conftest.er1
4446   ac_status=$?
4447   grep -v '^ *+' conftest.er1 >conftest.err
4448   rm -f conftest.er1
4449   cat conftest.err >&5
4450   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4451   (exit $ac_status); } && {
4452          test -z "$ac_c_werror_flag" ||
4453          test ! -s conftest.err
4454        } && test -s conftest.$ac_objext; then
4455   pgac_cv_prog_cc_cflags__qnoansialias=yes
4456 else
4457   $as_echo "$as_me: failed program was:" >&5
4458 sed 's/^/| /' conftest.$ac_ext >&5
4459
4460         pgac_cv_prog_cc_cflags__qnoansialias=no
4461 fi
4462
4463 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4464 CFLAGS="$pgac_save_CFLAGS"
4465 fi
4466 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__qnoansialias" >&5
4467 $as_echo "$pgac_cv_prog_cc_cflags__qnoansialias" >&6; }
4468 if test x"$pgac_cv_prog_cc_cflags__qnoansialias" = x"yes"; then
4469   CFLAGS="$CFLAGS -qnoansialias"
4470 fi
4471
4472 fi
4473
4474 # supply -g if --enable-debug
4475 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4476   CFLAGS="$CFLAGS -g"
4477 fi
4478
4479 # enable code coverage if --enable-coverage
4480 if test "$enable_coverage" = yes; then
4481   if test "$GCC" = yes; then
4482     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4483   else
4484     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4485 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4486    { (exit 1); exit 1; }; }
4487   fi
4488 fi
4489
4490 # enable profiling if --enable-profiling
4491 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4492   if test "$GCC" = yes; then
4493
4494 cat >>confdefs.h <<\_ACEOF
4495 #define PROFILE_PID_DIR 1
4496 _ACEOF
4497
4498     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4499   else
4500     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4501 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4502    { (exit 1); exit 1; }; }
4503   fi
4504 fi
4505
4506 # We already have this in Makefile.win32, but configure needs it too
4507 if test "$PORTNAME" = "win32"; then
4508   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4509 fi
4510
4511 # Check if the compiler still works with the template settings
4512 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4513 $as_echo_n "checking whether the C compiler still works... " >&6; }
4514 cat >conftest.$ac_ext <<_ACEOF
4515 /* confdefs.h.  */
4516 _ACEOF
4517 cat confdefs.h >>conftest.$ac_ext
4518 cat >>conftest.$ac_ext <<_ACEOF
4519 /* end confdefs.h.  */
4520
4521 int
4522 main ()
4523 {
4524 return 0;
4525   ;
4526   return 0;
4527 }
4528 _ACEOF
4529 rm -f conftest.$ac_objext conftest$ac_exeext
4530 if { (ac_try="$ac_link"
4531 case "(($ac_try" in
4532   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4533   *) ac_try_echo=$ac_try;;
4534 esac
4535 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4536 $as_echo "$ac_try_echo") >&5
4537   (eval "$ac_link") 2>conftest.er1
4538   ac_status=$?
4539   grep -v '^ *+' conftest.er1 >conftest.err
4540   rm -f conftest.er1
4541   cat conftest.err >&5
4542   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4543   (exit $ac_status); } && {
4544          test -z "$ac_c_werror_flag" ||
4545          test ! -s conftest.err
4546        } && test -s conftest$ac_exeext && {
4547          test "$cross_compiling" = yes ||
4548          $as_test_x conftest$ac_exeext
4549        }; then
4550   { $as_echo "$as_me:$LINENO: result: yes" >&5
4551 $as_echo "yes" >&6; }
4552 else
4553   $as_echo "$as_me: failed program was:" >&5
4554 sed 's/^/| /' conftest.$ac_ext >&5
4555
4556         { $as_echo "$as_me:$LINENO: result: no" >&5
4557 $as_echo "no" >&6; }
4558    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4559 $as_echo "$as_me: error: cannot proceed" >&2;}
4560    { (exit 1); exit 1; }; }
4561 fi
4562
4563 rm -rf conftest.dSYM
4564 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4565       conftest$ac_exeext conftest.$ac_ext
4566
4567 # Defend against gcc -ffast-math
4568 if test "$GCC" = yes; then
4569 cat >conftest.$ac_ext <<_ACEOF
4570 /* confdefs.h.  */
4571 _ACEOF
4572 cat confdefs.h >>conftest.$ac_ext
4573 cat >>conftest.$ac_ext <<_ACEOF
4574 /* end confdefs.h.  */
4575
4576 int
4577 main ()
4578 {
4579 #ifdef __FAST_MATH__
4580 choke me
4581 #endif
4582   ;
4583   return 0;
4584 }
4585 _ACEOF
4586 rm -f conftest.$ac_objext
4587 if { (ac_try="$ac_compile"
4588 case "(($ac_try" in
4589   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4590   *) ac_try_echo=$ac_try;;
4591 esac
4592 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4593 $as_echo "$ac_try_echo") >&5
4594   (eval "$ac_compile") 2>conftest.er1
4595   ac_status=$?
4596   grep -v '^ *+' conftest.er1 >conftest.err
4597   rm -f conftest.er1
4598   cat conftest.err >&5
4599   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4600   (exit $ac_status); } && {
4601          test -z "$ac_c_werror_flag" ||
4602          test ! -s conftest.err
4603        } && test -s conftest.$ac_objext; then
4604   :
4605 else
4606   $as_echo "$as_me: failed program was:" >&5
4607 sed 's/^/| /' conftest.$ac_ext >&5
4608
4609         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4610 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4611    { (exit 1); exit 1; }; }
4612 fi
4613
4614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4615 fi
4616
4617 ac_ext=c
4618 ac_cpp='$CPP $CPPFLAGS'
4619 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4620 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4621 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4622 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4623 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4624 # On Suns, sometimes $CPP names a directory.
4625 if test -n "$CPP" && test -d "$CPP"; then
4626   CPP=
4627 fi
4628 if test -z "$CPP"; then
4629   if test "${ac_cv_prog_CPP+set}" = set; then
4630   $as_echo_n "(cached) " >&6
4631 else
4632       # Double quotes because CPP needs to be expanded
4633     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4634     do
4635       ac_preproc_ok=false
4636 for ac_c_preproc_warn_flag in '' yes
4637 do
4638   # Use a header file that comes with gcc, so configuring glibc
4639   # with a fresh cross-compiler works.
4640   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4641   # <limits.h> exists even on freestanding compilers.
4642   # On the NeXT, cc -E runs the code through the compiler's parser,
4643   # not just through cpp. "Syntax error" is here to catch this case.
4644   cat >conftest.$ac_ext <<_ACEOF
4645 /* confdefs.h.  */
4646 _ACEOF
4647 cat confdefs.h >>conftest.$ac_ext
4648 cat >>conftest.$ac_ext <<_ACEOF
4649 /* end confdefs.h.  */
4650 #ifdef __STDC__
4651 # include <limits.h>
4652 #else
4653 # include <assert.h>
4654 #endif
4655                      Syntax error
4656 _ACEOF
4657 if { (ac_try="$ac_cpp conftest.$ac_ext"
4658 case "(($ac_try" in
4659   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4660   *) ac_try_echo=$ac_try;;
4661 esac
4662 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4663 $as_echo "$ac_try_echo") >&5
4664   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4665   ac_status=$?
4666   grep -v '^ *+' conftest.er1 >conftest.err
4667   rm -f conftest.er1
4668   cat conftest.err >&5
4669   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4670   (exit $ac_status); } >/dev/null && {
4671          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4672          test ! -s conftest.err
4673        }; then
4674   :
4675 else
4676   $as_echo "$as_me: failed program was:" >&5
4677 sed 's/^/| /' conftest.$ac_ext >&5
4678
4679   # Broken: fails on valid input.
4680 continue
4681 fi
4682
4683 rm -f conftest.err conftest.$ac_ext
4684
4685   # OK, works on sane cases.  Now check whether nonexistent headers
4686   # can be detected and how.
4687   cat >conftest.$ac_ext <<_ACEOF
4688 /* confdefs.h.  */
4689 _ACEOF
4690 cat confdefs.h >>conftest.$ac_ext
4691 cat >>conftest.$ac_ext <<_ACEOF
4692 /* end confdefs.h.  */
4693 #include <ac_nonexistent.h>
4694 _ACEOF
4695 if { (ac_try="$ac_cpp conftest.$ac_ext"
4696 case "(($ac_try" in
4697   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4698   *) ac_try_echo=$ac_try;;
4699 esac
4700 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4701 $as_echo "$ac_try_echo") >&5
4702   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4703   ac_status=$?
4704   grep -v '^ *+' conftest.er1 >conftest.err
4705   rm -f conftest.er1
4706   cat conftest.err >&5
4707   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4708   (exit $ac_status); } >/dev/null && {
4709          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4710          test ! -s conftest.err
4711        }; then
4712   # Broken: success on invalid input.
4713 continue
4714 else
4715   $as_echo "$as_me: failed program was:" >&5
4716 sed 's/^/| /' conftest.$ac_ext >&5
4717
4718   # Passes both tests.
4719 ac_preproc_ok=:
4720 break
4721 fi
4722
4723 rm -f conftest.err conftest.$ac_ext
4724
4725 done
4726 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4727 rm -f conftest.err conftest.$ac_ext
4728 if $ac_preproc_ok; then
4729   break
4730 fi
4731
4732     done
4733     ac_cv_prog_CPP=$CPP
4734
4735 fi
4736   CPP=$ac_cv_prog_CPP
4737 else
4738   ac_cv_prog_CPP=$CPP
4739 fi
4740 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
4741 $as_echo "$CPP" >&6; }
4742 ac_preproc_ok=false
4743 for ac_c_preproc_warn_flag in '' yes
4744 do
4745   # Use a header file that comes with gcc, so configuring glibc
4746   # with a fresh cross-compiler works.
4747   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4748   # <limits.h> exists even on freestanding compilers.
4749   # On the NeXT, cc -E runs the code through the compiler's parser,
4750   # not just through cpp. "Syntax error" is here to catch this case.
4751   cat >conftest.$ac_ext <<_ACEOF
4752 /* confdefs.h.  */
4753 _ACEOF
4754 cat confdefs.h >>conftest.$ac_ext
4755 cat >>conftest.$ac_ext <<_ACEOF
4756 /* end confdefs.h.  */
4757 #ifdef __STDC__
4758 # include <limits.h>
4759 #else
4760 # include <assert.h>
4761 #endif
4762                      Syntax error
4763 _ACEOF
4764 if { (ac_try="$ac_cpp conftest.$ac_ext"
4765 case "(($ac_try" in
4766   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4767   *) ac_try_echo=$ac_try;;
4768 esac
4769 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4770 $as_echo "$ac_try_echo") >&5
4771   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4772   ac_status=$?
4773   grep -v '^ *+' conftest.er1 >conftest.err
4774   rm -f conftest.er1
4775   cat conftest.err >&5
4776   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4777   (exit $ac_status); } >/dev/null && {
4778          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4779          test ! -s conftest.err
4780        }; then
4781   :
4782 else
4783   $as_echo "$as_me: failed program was:" >&5
4784 sed 's/^/| /' conftest.$ac_ext >&5
4785
4786   # Broken: fails on valid input.
4787 continue
4788 fi
4789
4790 rm -f conftest.err conftest.$ac_ext
4791
4792   # OK, works on sane cases.  Now check whether nonexistent headers
4793   # can be detected and how.
4794   cat >conftest.$ac_ext <<_ACEOF
4795 /* confdefs.h.  */
4796 _ACEOF
4797 cat confdefs.h >>conftest.$ac_ext
4798 cat >>conftest.$ac_ext <<_ACEOF
4799 /* end confdefs.h.  */
4800 #include <ac_nonexistent.h>
4801 _ACEOF
4802 if { (ac_try="$ac_cpp conftest.$ac_ext"
4803 case "(($ac_try" in
4804   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4805   *) ac_try_echo=$ac_try;;
4806 esac
4807 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4808 $as_echo "$ac_try_echo") >&5
4809   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4810   ac_status=$?
4811   grep -v '^ *+' conftest.er1 >conftest.err
4812   rm -f conftest.er1
4813   cat conftest.err >&5
4814   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4815   (exit $ac_status); } >/dev/null && {
4816          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4817          test ! -s conftest.err
4818        }; then
4819   # Broken: success on invalid input.
4820 continue
4821 else
4822   $as_echo "$as_me: failed program was:" >&5
4823 sed 's/^/| /' conftest.$ac_ext >&5
4824
4825   # Passes both tests.
4826 ac_preproc_ok=:
4827 break
4828 fi
4829
4830 rm -f conftest.err conftest.$ac_ext
4831
4832 done
4833 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4834 rm -f conftest.err conftest.$ac_ext
4835 if $ac_preproc_ok; then
4836   :
4837 else
4838   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4839 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4840 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4841 See \`config.log' for more details." >&5
4842 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4843 See \`config.log' for more details." >&2;}
4844    { (exit 1); exit 1; }; }; }
4845 fi
4846
4847 ac_ext=c
4848 ac_cpp='$CPP $CPPFLAGS'
4849 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4850 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4851 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4852
4853
4854
4855
4856 #
4857 # Set up TAS assembly code if needed; the template file has now had its
4858 # chance to request this.
4859 #
4860 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4861
4862
4863 if test "$need_tas" = yes ; then
4864   TAS=tas.o
4865 else
4866   TAS=""
4867 fi
4868
4869
4870
4871 #
4872 # Automatic dependency tracking
4873 #
4874
4875
4876 # Check whether --enable-depend was given.
4877 if test "${enable_depend+set}" = set; then
4878   enableval=$enable_depend;
4879   case $enableval in
4880     yes)
4881       autodepend=yes
4882       ;;
4883     no)
4884       :
4885       ;;
4886     *)
4887       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4888 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4889    { (exit 1); exit 1; }; }
4890       ;;
4891   esac
4892
4893 else
4894   enable_depend=no
4895
4896 fi
4897
4898
4899
4900
4901
4902 #
4903 # Enable assert checks
4904 #
4905
4906
4907 # Check whether --enable-cassert was given.
4908 if test "${enable_cassert+set}" = set; then
4909   enableval=$enable_cassert;
4910   case $enableval in
4911     yes)
4912
4913 cat >>confdefs.h <<\_ACEOF
4914 #define USE_ASSERT_CHECKING 1
4915 _ACEOF
4916
4917       ;;
4918     no)
4919       :
4920       ;;
4921     *)
4922       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4923 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4924    { (exit 1); exit 1; }; }
4925       ;;
4926   esac
4927
4928 else
4929   enable_cassert=no
4930
4931 fi
4932
4933
4934
4935
4936 #
4937 # Include directories
4938 #
4939 ac_save_IFS=$IFS
4940 IFS="${IFS}${PATH_SEPARATOR}"
4941 # SRCH_INC comes from the template file
4942 for dir in $with_includes $SRCH_INC; do
4943   if test -d "$dir"; then
4944     INCLUDES="$INCLUDES -I$dir"
4945   else
4946     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4947 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4948   fi
4949 done
4950 IFS=$ac_save_IFS
4951
4952
4953
4954 #
4955 # Library directories
4956 #
4957 ac_save_IFS=$IFS
4958 IFS="${IFS}${PATH_SEPARATOR}"
4959 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4960 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4961   if test -d "$dir"; then
4962     LIBDIRS="$LIBDIRS -L$dir"
4963   else
4964     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4965 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4966   fi
4967 done
4968 IFS=$ac_save_IFS
4969
4970 #
4971 # Enable thread-safe client libraries
4972 #
4973 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4974 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
4975
4976
4977 # Check whether --enable-thread-safety was given.
4978 if test "${enable_thread_safety+set}" = set; then
4979   enableval=$enable_thread_safety;
4980   case $enableval in
4981     yes)
4982       :
4983       ;;
4984     no)
4985       :
4986       ;;
4987     *)
4988       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4989 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4990    { (exit 1); exit 1; }; }
4991       ;;
4992   esac
4993
4994 else
4995   enable_thread_safety=yes
4996
4997 fi
4998
4999
5000 if test "$enable_thread_safety" = yes; then
5001
5002 cat >>confdefs.h <<\_ACEOF
5003 #define ENABLE_THREAD_SAFETY 1
5004 _ACEOF
5005
5006 fi
5007 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
5008 $as_echo "$enable_thread_safety" >&6; }
5009
5010
5011 #
5012 # Optionally build Tcl modules (PL/Tcl)
5013 #
5014 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
5015 $as_echo_n "checking whether to build with Tcl... " >&6; }
5016
5017
5018
5019 # Check whether --with-tcl was given.
5020 if test "${with_tcl+set}" = set; then
5021   withval=$with_tcl;
5022   case $withval in
5023     yes)
5024       :
5025       ;;
5026     no)
5027       :
5028       ;;
5029     *)
5030       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
5031 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
5032    { (exit 1); exit 1; }; }
5033       ;;
5034   esac
5035
5036 else
5037   with_tcl=no
5038
5039 fi
5040
5041
5042 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
5043 $as_echo "$with_tcl" >&6; }
5044
5045
5046 # We see if the path to the Tcl/Tk configuration scripts is specified.
5047 # This will override the use of tclsh to find the paths to search.
5048
5049
5050
5051
5052 # Check whether --with-tclconfig was given.
5053 if test "${with_tclconfig+set}" = set; then
5054   withval=$with_tclconfig;
5055   case $withval in
5056     yes)
5057       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5058 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5059    { (exit 1); exit 1; }; }
5060       ;;
5061     no)
5062       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5063 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5064    { (exit 1); exit 1; }; }
5065       ;;
5066     *)
5067
5068       ;;
5069   esac
5070
5071 fi
5072
5073
5074
5075 #
5076 # Optionally build Perl modules (PL/Perl)
5077 #
5078 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
5079 $as_echo_n "checking whether to build Perl modules... " >&6; }
5080
5081
5082
5083 # Check whether --with-perl was given.
5084 if test "${with_perl+set}" = set; then
5085   withval=$with_perl;
5086   case $withval in
5087     yes)
5088       :
5089       ;;
5090     no)
5091       :
5092       ;;
5093     *)
5094       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
5095 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
5096    { (exit 1); exit 1; }; }
5097       ;;
5098   esac
5099
5100 else
5101   with_perl=no
5102
5103 fi
5104
5105
5106 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
5107 $as_echo "$with_perl" >&6; }
5108
5109
5110 #
5111 # Optionally build Python modules (PL/Python)
5112 #
5113 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
5114 $as_echo_n "checking whether to build Python modules... " >&6; }
5115
5116
5117
5118 # Check whether --with-python was given.
5119 if test "${with_python+set}" = set; then
5120   withval=$with_python;
5121   case $withval in
5122     yes)
5123       :
5124       ;;
5125     no)
5126       :
5127       ;;
5128     *)
5129       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5130 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5131    { (exit 1); exit 1; }; }
5132       ;;
5133   esac
5134
5135 else
5136   with_python=no
5137
5138 fi
5139
5140
5141 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5142 $as_echo "$with_python" >&6; }
5143
5144
5145 #
5146 # GSSAPI
5147 #
5148 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5149 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5150
5151
5152
5153 # Check whether --with-gssapi was given.
5154 if test "${with_gssapi+set}" = set; then
5155   withval=$with_gssapi;
5156   case $withval in
5157     yes)
5158
5159
5160 cat >>confdefs.h <<\_ACEOF
5161 #define ENABLE_GSS 1
5162 _ACEOF
5163
5164   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5165
5166       ;;
5167     no)
5168       :
5169       ;;
5170     *)
5171       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5172 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5173    { (exit 1); exit 1; }; }
5174       ;;
5175   esac
5176
5177 else
5178   with_gssapi=no
5179
5180 fi
5181
5182
5183 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5184 $as_echo "$with_gssapi" >&6; }
5185
5186
5187 #
5188 # Kerberos 5
5189 #
5190 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5191 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5192
5193
5194
5195 # Check whether --with-krb5 was given.
5196 if test "${with_krb5+set}" = set; then
5197   withval=$with_krb5;
5198   case $withval in
5199     yes)
5200
5201
5202 cat >>confdefs.h <<\_ACEOF
5203 #define KRB5 1
5204 _ACEOF
5205
5206   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5207
5208       ;;
5209     no)
5210       :
5211       ;;
5212     *)
5213       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5214 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5215    { (exit 1); exit 1; }; }
5216       ;;
5217   esac
5218
5219 else
5220   with_krb5=no
5221
5222 fi
5223
5224
5225 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5226 $as_echo "$with_krb5" >&6; }
5227
5228
5229
5230
5231
5232
5233 #
5234 # Kerberos configuration parameters
5235 #
5236
5237
5238
5239 # Check whether --with-krb-srvnam was given.
5240 if test "${with_krb_srvnam+set}" = set; then
5241   withval=$with_krb_srvnam;
5242   case $withval in
5243     yes)
5244       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5245 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5246    { (exit 1); exit 1; }; }
5247       ;;
5248     no)
5249       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5250 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5251    { (exit 1); exit 1; }; }
5252       ;;
5253     *)
5254
5255       ;;
5256   esac
5257
5258 else
5259   with_krb_srvnam="postgres"
5260 fi
5261
5262
5263
5264 cat >>confdefs.h <<_ACEOF
5265 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5266 _ACEOF
5267
5268
5269
5270 #
5271 # PAM
5272 #
5273 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5274 $as_echo_n "checking whether to build with PAM support... " >&6; }
5275
5276
5277
5278 # Check whether --with-pam was given.
5279 if test "${with_pam+set}" = set; then
5280   withval=$with_pam;
5281   case $withval in
5282     yes)
5283
5284 cat >>confdefs.h <<\_ACEOF
5285 #define USE_PAM 1
5286 _ACEOF
5287
5288       ;;
5289     no)
5290       :
5291       ;;
5292     *)
5293       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5294 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5295    { (exit 1); exit 1; }; }
5296       ;;
5297   esac
5298
5299 else
5300   with_pam=no
5301
5302 fi
5303
5304
5305 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5306 $as_echo "$with_pam" >&6; }
5307
5308
5309
5310 #
5311 # LDAP
5312 #
5313 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5314 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5315
5316
5317
5318 # Check whether --with-ldap was given.
5319 if test "${with_ldap+set}" = set; then
5320   withval=$with_ldap;
5321   case $withval in
5322     yes)
5323
5324 cat >>confdefs.h <<\_ACEOF
5325 #define USE_LDAP 1
5326 _ACEOF
5327
5328       ;;
5329     no)
5330       :
5331       ;;
5332     *)
5333       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5334 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5335    { (exit 1); exit 1; }; }
5336       ;;
5337   esac
5338
5339 else
5340   with_ldap=no
5341
5342 fi
5343
5344
5345 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5346 $as_echo "$with_ldap" >&6; }
5347
5348
5349
5350 #
5351 # Bonjour
5352 #
5353 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5354 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5355
5356
5357
5358 # Check whether --with-bonjour was given.
5359 if test "${with_bonjour+set}" = set; then
5360   withval=$with_bonjour;
5361   case $withval in
5362     yes)
5363
5364 cat >>confdefs.h <<\_ACEOF
5365 #define USE_BONJOUR 1
5366 _ACEOF
5367
5368       ;;
5369     no)
5370       :
5371       ;;
5372     *)
5373       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5374 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5375    { (exit 1); exit 1; }; }
5376       ;;
5377   esac
5378
5379 else
5380   with_bonjour=no
5381
5382 fi
5383
5384
5385 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5386 $as_echo "$with_bonjour" >&6; }
5387
5388
5389
5390 #
5391 # OpenSSL
5392 #
5393 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5394 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5395
5396
5397
5398 # Check whether --with-openssl was given.
5399 if test "${with_openssl+set}" = set; then
5400   withval=$with_openssl;
5401   case $withval in
5402     yes)
5403
5404 cat >>confdefs.h <<\_ACEOF
5405 #define USE_SSL 1
5406 _ACEOF
5407
5408       ;;
5409     no)
5410       :
5411       ;;
5412     *)
5413       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5414 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5415    { (exit 1); exit 1; }; }
5416       ;;
5417   esac
5418
5419 else
5420   with_openssl=no
5421
5422 fi
5423
5424
5425 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5426 $as_echo "$with_openssl" >&6; }
5427
5428
5429 #
5430 # SELinux
5431 #
5432 { $as_echo "$as_me:$LINENO: checking whether to build with SELinux support" >&5
5433 $as_echo_n "checking whether to build with SELinux support... " >&6; }
5434
5435
5436
5437 # Check whether --with-selinux was given.
5438 if test "${with_selinux+set}" = set; then
5439   withval=$with_selinux;
5440   case $withval in
5441     yes)
5442       :
5443       ;;
5444     no)
5445       :
5446       ;;
5447     *)
5448       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-selinux option" >&5
5449 $as_echo "$as_me: error: no argument expected for --with-selinux option" >&2;}
5450    { (exit 1); exit 1; }; }
5451       ;;
5452   esac
5453
5454 else
5455   with_selinux=no
5456
5457 fi
5458
5459
5460
5461 { $as_echo "$as_me:$LINENO: result: $with_selinux" >&5
5462 $as_echo "$with_selinux" >&6; }
5463
5464 #
5465 # Readline
5466 #
5467
5468
5469
5470 # Check whether --with-readline was given.
5471 if test "${with_readline+set}" = set; then
5472   withval=$with_readline;
5473   case $withval in
5474     yes)
5475       :
5476       ;;
5477     no)
5478       :
5479       ;;
5480     *)
5481       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5482 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5483    { (exit 1); exit 1; }; }
5484       ;;
5485   esac
5486
5487 else
5488   with_readline=yes
5489
5490 fi
5491
5492
5493 # readline on MinGW has problems with backslashes in psql and other bugs.
5494 # This is particularly a problem with non-US code pages.
5495 # Therefore disable its use until we understand the cause. 2004-07-20
5496 if test "$PORTNAME" = "win32"; then
5497   if test "$with_readline" = yes; then
5498     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5499 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5500     with_readline=no
5501   fi
5502 fi
5503
5504
5505 #
5506 # Prefer libedit
5507 #
5508
5509
5510
5511 # Check whether --with-libedit-preferred was given.
5512 if test "${with_libedit_preferred+set}" = set; then
5513   withval=$with_libedit_preferred;
5514   case $withval in
5515     yes)
5516       :
5517       ;;
5518     no)
5519       :
5520       ;;
5521     *)
5522       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5523 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5524    { (exit 1); exit 1; }; }
5525       ;;
5526   esac
5527
5528 else
5529   with_libedit_preferred=no
5530
5531 fi
5532
5533
5534
5535
5536 #
5537 # OSSP UUID library
5538 #
5539
5540
5541
5542 # Check whether --with-ossp-uuid was given.
5543 if test "${with_ossp_uuid+set}" = set; then
5544   withval=$with_ossp_uuid;
5545   case $withval in
5546     yes)
5547       :
5548       ;;
5549     no)
5550       :
5551       ;;
5552     *)
5553       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5554 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5555    { (exit 1); exit 1; }; }
5556       ;;
5557   esac
5558
5559 else
5560   with_ossp_uuid=no
5561
5562 fi
5563
5564
5565
5566
5567
5568 #
5569 # XML
5570 #
5571
5572
5573
5574 # Check whether --with-libxml was given.
5575 if test "${with_libxml+set}" = set; then
5576   withval=$with_libxml;
5577   case $withval in
5578     yes)
5579
5580 cat >>confdefs.h <<\_ACEOF
5581 #define USE_LIBXML 1
5582 _ACEOF
5583
5584       ;;
5585     no)
5586       :
5587       ;;
5588     *)
5589       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5590 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5591    { (exit 1); exit 1; }; }
5592       ;;
5593   esac
5594
5595 else
5596   with_libxml=no
5597
5598 fi
5599
5600
5601
5602 if test "$with_libxml" = yes ; then
5603   for ac_prog in xml2-config
5604 do
5605   # Extract the first word of "$ac_prog", so it can be a program name with args.
5606 set dummy $ac_prog; ac_word=$2
5607 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5608 $as_echo_n "checking for $ac_word... " >&6; }
5609 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5610   $as_echo_n "(cached) " >&6
5611 else
5612   if test -n "$XML2_CONFIG"; then
5613   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5614 else
5615 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5616 for as_dir in $PATH
5617 do
5618   IFS=$as_save_IFS
5619   test -z "$as_dir" && as_dir=.
5620   for ac_exec_ext in '' $ac_executable_extensions; do
5621   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5622     ac_cv_prog_XML2_CONFIG="$ac_prog"
5623     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5624     break 2
5625   fi
5626 done
5627 done
5628 IFS=$as_save_IFS
5629
5630 fi
5631 fi
5632 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5633 if test -n "$XML2_CONFIG"; then
5634   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5635 $as_echo "$XML2_CONFIG" >&6; }
5636 else
5637   { $as_echo "$as_me:$LINENO: result: no" >&5
5638 $as_echo "no" >&6; }
5639 fi
5640
5641
5642   test -n "$XML2_CONFIG" && break
5643 done
5644
5645   if test -n "$XML2_CONFIG"; then
5646     for pgac_option in `$XML2_CONFIG --cflags`; do
5647       case $pgac_option in
5648         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5649       esac
5650     done
5651     for pgac_option in `$XML2_CONFIG --libs`; do
5652       case $pgac_option in
5653         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5654       esac
5655     done
5656   fi
5657 fi
5658
5659
5660
5661 #
5662 # XSLT
5663 #
5664
5665
5666
5667 # Check whether --with-libxslt was given.
5668 if test "${with_libxslt+set}" = set; then
5669   withval=$with_libxslt;
5670   case $withval in
5671     yes)
5672
5673 cat >>confdefs.h <<\_ACEOF
5674 #define USE_LIBXSLT 1
5675 _ACEOF
5676
5677       ;;
5678     no)
5679       :
5680       ;;
5681     *)
5682       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5683 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5684    { (exit 1); exit 1; }; }
5685       ;;
5686   esac
5687
5688 else
5689   with_libxslt=no
5690
5691 fi
5692
5693
5694
5695
5696
5697
5698 #
5699 # tzdata
5700 #
5701
5702
5703
5704 # Check whether --with-system-tzdata was given.
5705 if test "${with_system_tzdata+set}" = set; then
5706   withval=$with_system_tzdata;
5707   case $withval in
5708     yes)
5709       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5710 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5711    { (exit 1); exit 1; }; }
5712       ;;
5713     no)
5714       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5715 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5716    { (exit 1); exit 1; }; }
5717       ;;
5718     *)
5719
5720       ;;
5721   esac
5722
5723 fi
5724
5725
5726
5727
5728 #
5729 # Zlib
5730 #
5731
5732
5733
5734 # Check whether --with-zlib was given.
5735 if test "${with_zlib+set}" = set; then
5736   withval=$with_zlib;
5737   case $withval in
5738     yes)
5739       :
5740       ;;
5741     no)
5742       :
5743       ;;
5744     *)
5745       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5746 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5747    { (exit 1); exit 1; }; }
5748       ;;
5749   esac
5750
5751 else
5752   with_zlib=yes
5753
5754 fi
5755
5756
5757
5758
5759 #
5760 # Elf
5761 #
5762
5763 # Assume system is ELF if it predefines __ELF__ as 1,
5764 # otherwise believe host_os based default.
5765 case $host_os in
5766     freebsd1*|freebsd2*) elf=no;;
5767     freebsd3*|freebsd4*) elf=yes;;
5768 esac
5769
5770
5771 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5772 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5773 if test "${ac_cv_path_GREP+set}" = set; then
5774   $as_echo_n "(cached) " >&6
5775 else
5776   if test -z "$GREP"; then
5777   ac_path_GREP_found=false
5778   # Loop through the user's path and test for each of PROGNAME-LIST
5779   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5780 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5781 do
5782   IFS=$as_save_IFS
5783   test -z "$as_dir" && as_dir=.
5784   for ac_prog in grep ggrep; do
5785     for ac_exec_ext in '' $ac_executable_extensions; do
5786       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5787       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5788 # Check for GNU ac_path_GREP and select it if it is found.
5789   # Check for GNU $ac_path_GREP
5790 case `"$ac_path_GREP" --version 2>&1` in
5791 *GNU*)
5792   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5793 *)
5794   ac_count=0
5795   $as_echo_n 0123456789 >"conftest.in"
5796   while :
5797   do
5798     cat "conftest.in" "conftest.in" >"conftest.tmp"
5799     mv "conftest.tmp" "conftest.in"
5800     cp "conftest.in" "conftest.nl"
5801     $as_echo 'GREP' >> "conftest.nl"
5802     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5803     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5804     ac_count=`expr $ac_count + 1`
5805     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5806       # Best one so far, save it but keep looking for a better one
5807       ac_cv_path_GREP="$ac_path_GREP"
5808       ac_path_GREP_max=$ac_count
5809     fi
5810     # 10*(2^10) chars as input seems more than enough
5811     test $ac_count -gt 10 && break
5812   done
5813   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5814 esac
5815
5816       $ac_path_GREP_found && break 3
5817     done
5818   done
5819 done
5820 IFS=$as_save_IFS
5821   if test -z "$ac_cv_path_GREP"; then
5822     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5823 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5824    { (exit 1); exit 1; }; }
5825   fi
5826 else
5827   ac_cv_path_GREP=$GREP
5828 fi
5829
5830 fi
5831 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5832 $as_echo "$ac_cv_path_GREP" >&6; }
5833  GREP="$ac_cv_path_GREP"
5834
5835
5836 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
5837 $as_echo_n "checking for egrep... " >&6; }
5838 if test "${ac_cv_path_EGREP+set}" = set; then
5839   $as_echo_n "(cached) " >&6
5840 else
5841   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5842    then ac_cv_path_EGREP="$GREP -E"
5843    else
5844      if test -z "$EGREP"; then
5845   ac_path_EGREP_found=false
5846   # Loop through the user's path and test for each of PROGNAME-LIST
5847   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5848 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5849 do
5850   IFS=$as_save_IFS
5851   test -z "$as_dir" && as_dir=.
5852   for ac_prog in egrep; do
5853     for ac_exec_ext in '' $ac_executable_extensions; do
5854       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5855       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5856 # Check for GNU ac_path_EGREP and select it if it is found.
5857   # Check for GNU $ac_path_EGREP
5858 case `"$ac_path_EGREP" --version 2>&1` in
5859 *GNU*)
5860   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5861 *)
5862   ac_count=0
5863   $as_echo_n 0123456789 >"conftest.in"
5864   while :
5865   do
5866     cat "conftest.in" "conftest.in" >"conftest.tmp"
5867     mv "conftest.tmp" "conftest.in"
5868     cp "conftest.in" "conftest.nl"
5869     $as_echo 'EGREP' >> "conftest.nl"
5870     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5871     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5872     ac_count=`expr $ac_count + 1`
5873     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5874       # Best one so far, save it but keep looking for a better one
5875       ac_cv_path_EGREP="$ac_path_EGREP"
5876       ac_path_EGREP_max=$ac_count
5877     fi
5878     # 10*(2^10) chars as input seems more than enough
5879     test $ac_count -gt 10 && break
5880   done
5881   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5882 esac
5883
5884       $ac_path_EGREP_found && break 3
5885     done
5886   done
5887 done
5888 IFS=$as_save_IFS
5889   if test -z "$ac_cv_path_EGREP"; then
5890     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5891 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5892    { (exit 1); exit 1; }; }
5893   fi
5894 else
5895   ac_cv_path_EGREP=$EGREP
5896 fi
5897
5898    fi
5899 fi
5900 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5901 $as_echo "$ac_cv_path_EGREP" >&6; }
5902  EGREP="$ac_cv_path_EGREP"
5903
5904
5905 cat >conftest.$ac_ext <<_ACEOF
5906 /* confdefs.h.  */
5907 _ACEOF
5908 cat confdefs.h >>conftest.$ac_ext
5909 cat >>conftest.$ac_ext <<_ACEOF
5910 /* end confdefs.h.  */
5911 #if __ELF__
5912   yes
5913 #endif
5914
5915 _ACEOF
5916 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5917   $EGREP "yes" >/dev/null 2>&1; then
5918   ELF_SYS=true
5919 else
5920   if test "X$elf" = "Xyes" ; then
5921   ELF_SYS=true
5922 else
5923   ELF_SYS=
5924 fi
5925 fi
5926 rm -f conftest*
5927
5928
5929
5930 #
5931 # Assignments
5932 #
5933
5934 CPPFLAGS="$CPPFLAGS $INCLUDES"
5935 LDFLAGS="$LDFLAGS $LIBDIRS"
5936
5937
5938
5939
5940
5941 # Check whether --with-gnu-ld was given.
5942 if test "${with_gnu_ld+set}" = set; then
5943   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5944 else
5945   with_gnu_ld=no
5946 fi
5947
5948 ac_prog=ld
5949 if test "$GCC" = yes; then
5950   # Check if gcc -print-prog-name=ld gives a path.
5951   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5952 $as_echo_n "checking for ld used by GCC... " >&6; }
5953   case $host in
5954   *-*-mingw*)
5955     # gcc leaves a trailing carriage return which upsets mingw
5956     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5957   *)
5958     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5959   esac
5960   case "$ac_prog" in
5961     # Accept absolute paths.
5962     [\\/]* | [A-Za-z]:[\\/]*)
5963       re_direlt='/[^/][^/]*/\.\./'
5964       # Canonicalize the path of ld
5965       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5966       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5967         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5968       done
5969       test -z "$LD" && LD="$ac_prog"
5970       ;;
5971   "")
5972     # If it fails, then pretend we aren't using GCC.
5973     ac_prog=ld
5974     ;;
5975   *)
5976     # If it is relative, then search for the first ld in PATH.
5977     with_gnu_ld=unknown
5978     ;;
5979   esac
5980 elif test "$with_gnu_ld" = yes; then
5981   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
5982 $as_echo_n "checking for GNU ld... " >&6; }
5983 else
5984   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5985 $as_echo_n "checking for non-GNU ld... " >&6; }
5986 fi
5987 if test "${ac_cv_path_LD+set}" = set; then
5988   $as_echo_n "(cached) " >&6
5989 else
5990   if test -z "$LD"; then
5991   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5992   for ac_dir in $PATH; do
5993     test -z "$ac_dir" && ac_dir=.
5994     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5995       ac_cv_path_LD="$ac_dir/$ac_prog"
5996       # Check to see if the program is GNU ld.  I'd rather use --version,
5997       # but apparently some GNU ld's only accept -v.
5998       # Break only if it was the GNU/non-GNU ld that we prefer.
5999       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
6000         test "$with_gnu_ld" != no && break
6001       else
6002         test "$with_gnu_ld" != yes && break
6003       fi
6004     fi
6005   done
6006   IFS="$ac_save_ifs"
6007 else
6008   ac_cv_path_LD="$LD" # Let the user override the test with a path.
6009 fi
6010 fi
6011
6012 LD="$ac_cv_path_LD"
6013 if test -n "$LD"; then
6014   { $as_echo "$as_me:$LINENO: result: $LD" >&5
6015 $as_echo "$LD" >&6; }
6016 else
6017   { $as_echo "$as_me:$LINENO: result: no" >&5
6018 $as_echo "no" >&6; }
6019 fi
6020 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
6021 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
6022    { (exit 1); exit 1; }; }
6023 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
6024 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
6025 if test "${ac_cv_prog_gnu_ld+set}" = set; then
6026   $as_echo_n "(cached) " >&6
6027 else
6028   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
6029 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
6030   ac_cv_prog_gnu_ld=yes
6031 else
6032   ac_cv_prog_gnu_ld=no
6033 fi
6034 fi
6035 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
6036 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
6037 with_gnu_ld=$ac_cv_prog_gnu_ld
6038
6039
6040
6041
6042 case $host_os in sysv5*)
6043   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
6044 $as_echo_n "checking whether ld -R works... " >&6; }
6045 if test "${pgac_cv_prog_ld_R+set}" = set; then
6046   $as_echo_n "(cached) " >&6
6047 else
6048
6049     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
6050     cat >conftest.$ac_ext <<_ACEOF
6051 /* confdefs.h.  */
6052 _ACEOF
6053 cat confdefs.h >>conftest.$ac_ext
6054 cat >>conftest.$ac_ext <<_ACEOF
6055 /* end confdefs.h.  */
6056
6057 int
6058 main ()
6059 {
6060
6061   ;
6062   return 0;
6063 }
6064 _ACEOF
6065 rm -f conftest.$ac_objext conftest$ac_exeext
6066 if { (ac_try="$ac_link"
6067 case "(($ac_try" in
6068   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6069   *) ac_try_echo=$ac_try;;
6070 esac
6071 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6072 $as_echo "$ac_try_echo") >&5
6073   (eval "$ac_link") 2>conftest.er1
6074   ac_status=$?
6075   grep -v '^ *+' conftest.er1 >conftest.err
6076   rm -f conftest.er1
6077   cat conftest.err >&5
6078   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6079   (exit $ac_status); } && {
6080          test -z "$ac_c_werror_flag" ||
6081          test ! -s conftest.err
6082        } && test -s conftest$ac_exeext && {
6083          test "$cross_compiling" = yes ||
6084          $as_test_x conftest$ac_exeext
6085        }; then
6086   pgac_cv_prog_ld_R=yes
6087 else
6088   $as_echo "$as_me: failed program was:" >&5
6089 sed 's/^/| /' conftest.$ac_ext >&5
6090
6091         pgac_cv_prog_ld_R=no
6092 fi
6093
6094 rm -rf conftest.dSYM
6095 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6096       conftest$ac_exeext conftest.$ac_ext
6097     LDFLAGS=$pgac_save_LDFLAGS
6098
6099 fi
6100 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
6101 $as_echo "$pgac_cv_prog_ld_R" >&6; }
6102   ld_R_works=$pgac_cv_prog_ld_R
6103
6104 esac
6105 if test -n "$ac_tool_prefix"; then
6106   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6107 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6108 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6109 $as_echo_n "checking for $ac_word... " >&6; }
6110 if test "${ac_cv_prog_RANLIB+set}" = set; then
6111   $as_echo_n "(cached) " >&6
6112 else
6113   if test -n "$RANLIB"; then
6114   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6115 else
6116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6117 for as_dir in $PATH
6118 do
6119   IFS=$as_save_IFS
6120   test -z "$as_dir" && as_dir=.
6121   for ac_exec_ext in '' $ac_executable_extensions; do
6122   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6123     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6124     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6125     break 2
6126   fi
6127 done
6128 done
6129 IFS=$as_save_IFS
6130
6131 fi
6132 fi
6133 RANLIB=$ac_cv_prog_RANLIB
6134 if test -n "$RANLIB"; then
6135   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
6136 $as_echo "$RANLIB" >&6; }
6137 else
6138   { $as_echo "$as_me:$LINENO: result: no" >&5
6139 $as_echo "no" >&6; }
6140 fi
6141
6142
6143 fi
6144 if test -z "$ac_cv_prog_RANLIB"; then
6145   ac_ct_RANLIB=$RANLIB
6146   # Extract the first word of "ranlib", so it can be a program name with args.
6147 set dummy ranlib; ac_word=$2
6148 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6149 $as_echo_n "checking for $ac_word... " >&6; }
6150 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6151   $as_echo_n "(cached) " >&6
6152 else
6153   if test -n "$ac_ct_RANLIB"; then
6154   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6155 else
6156 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6157 for as_dir in $PATH
6158 do
6159   IFS=$as_save_IFS
6160   test -z "$as_dir" && as_dir=.
6161   for ac_exec_ext in '' $ac_executable_extensions; do
6162   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6163     ac_cv_prog_ac_ct_RANLIB="ranlib"
6164     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6165     break 2
6166   fi
6167 done
6168 done
6169 IFS=$as_save_IFS
6170
6171 fi
6172 fi
6173 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6174 if test -n "$ac_ct_RANLIB"; then
6175   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6176 $as_echo "$ac_ct_RANLIB" >&6; }
6177 else
6178   { $as_echo "$as_me:$LINENO: result: no" >&5
6179 $as_echo "no" >&6; }
6180 fi
6181
6182   if test "x$ac_ct_RANLIB" = x; then
6183     RANLIB=":"
6184   else
6185     case $cross_compiling:$ac_tool_warned in
6186 yes:)
6187 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6188 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6189 ac_tool_warned=yes ;;
6190 esac
6191     RANLIB=$ac_ct_RANLIB
6192   fi
6193 else
6194   RANLIB="$ac_cv_prog_RANLIB"
6195 fi
6196
6197
6198   if test -n "$ac_tool_prefix"; then
6199   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6200 set dummy ${ac_tool_prefix}strip; ac_word=$2
6201 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6202 $as_echo_n "checking for $ac_word... " >&6; }
6203 if test "${ac_cv_prog_STRIP+set}" = set; then
6204   $as_echo_n "(cached) " >&6
6205 else
6206   if test -n "$STRIP"; then
6207   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6208 else
6209 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6210 for as_dir in $PATH
6211 do
6212   IFS=$as_save_IFS
6213   test -z "$as_dir" && as_dir=.
6214   for ac_exec_ext in '' $ac_executable_extensions; do
6215   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6216     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6217     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6218     break 2
6219   fi
6220 done
6221 done
6222 IFS=$as_save_IFS
6223
6224 fi
6225 fi
6226 STRIP=$ac_cv_prog_STRIP
6227 if test -n "$STRIP"; then
6228   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6229 $as_echo "$STRIP" >&6; }
6230 else
6231   { $as_echo "$as_me:$LINENO: result: no" >&5
6232 $as_echo "no" >&6; }
6233 fi
6234
6235
6236 fi
6237 if test -z "$ac_cv_prog_STRIP"; then
6238   ac_ct_STRIP=$STRIP
6239   # Extract the first word of "strip", so it can be a program name with args.
6240 set dummy strip; ac_word=$2
6241 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6242 $as_echo_n "checking for $ac_word... " >&6; }
6243 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6244   $as_echo_n "(cached) " >&6
6245 else
6246   if test -n "$ac_ct_STRIP"; then
6247   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6248 else
6249 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6250 for as_dir in $PATH
6251 do
6252   IFS=$as_save_IFS
6253   test -z "$as_dir" && as_dir=.
6254   for ac_exec_ext in '' $ac_executable_extensions; do
6255   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6256     ac_cv_prog_ac_ct_STRIP="strip"
6257     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6258     break 2
6259   fi
6260 done
6261 done
6262 IFS=$as_save_IFS
6263
6264 fi
6265 fi
6266 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6267 if test -n "$ac_ct_STRIP"; then
6268   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6269 $as_echo "$ac_ct_STRIP" >&6; }
6270 else
6271   { $as_echo "$as_me:$LINENO: result: no" >&5
6272 $as_echo "no" >&6; }
6273 fi
6274
6275   if test "x$ac_ct_STRIP" = x; then
6276     STRIP=":"
6277   else
6278     case $cross_compiling:$ac_tool_warned in
6279 yes:)
6280 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6281 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6282 ac_tool_warned=yes ;;
6283 esac
6284     STRIP=$ac_ct_STRIP
6285   fi
6286 else
6287   STRIP="$ac_cv_prog_STRIP"
6288 fi
6289
6290
6291   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6292 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6293   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6294     STRIP_STATIC_LIB="$STRIP -x"
6295     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6296     { $as_echo "$as_me:$LINENO: result: yes" >&5
6297 $as_echo "yes" >&6; }
6298   else
6299     STRIP_STATIC_LIB=:
6300     STRIP_SHARED_LIB=:
6301     { $as_echo "$as_me:$LINENO: result: no" >&5
6302 $as_echo "no" >&6; }
6303   fi
6304
6305
6306
6307 if test -n "$ac_tool_prefix"; then
6308   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6309 set dummy ${ac_tool_prefix}ar; ac_word=$2
6310 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6311 $as_echo_n "checking for $ac_word... " >&6; }
6312 if test "${ac_cv_prog_AR+set}" = set; then
6313   $as_echo_n "(cached) " >&6
6314 else
6315   if test -n "$AR"; then
6316   ac_cv_prog_AR="$AR" # Let the user override the test.
6317 else
6318 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6319 for as_dir in $PATH
6320 do
6321   IFS=$as_save_IFS
6322   test -z "$as_dir" && as_dir=.
6323   for ac_exec_ext in '' $ac_executable_extensions; do
6324   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6325     ac_cv_prog_AR="${ac_tool_prefix}ar"
6326     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6327     break 2
6328   fi
6329 done
6330 done
6331 IFS=$as_save_IFS
6332
6333 fi
6334 fi
6335 AR=$ac_cv_prog_AR
6336 if test -n "$AR"; then
6337   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6338 $as_echo "$AR" >&6; }
6339 else
6340   { $as_echo "$as_me:$LINENO: result: no" >&5
6341 $as_echo "no" >&6; }
6342 fi
6343
6344
6345 fi
6346 if test -z "$ac_cv_prog_AR"; then
6347   ac_ct_AR=$AR
6348   # Extract the first word of "ar", so it can be a program name with args.
6349 set dummy ar; ac_word=$2
6350 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6351 $as_echo_n "checking for $ac_word... " >&6; }
6352 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6353   $as_echo_n "(cached) " >&6
6354 else
6355   if test -n "$ac_ct_AR"; then
6356   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6357 else
6358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6359 for as_dir in $PATH
6360 do
6361   IFS=$as_save_IFS
6362   test -z "$as_dir" && as_dir=.
6363   for ac_exec_ext in '' $ac_executable_extensions; do
6364   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6365     ac_cv_prog_ac_ct_AR="ar"
6366     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6367     break 2
6368   fi
6369 done
6370 done
6371 IFS=$as_save_IFS
6372
6373 fi
6374 fi
6375 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6376 if test -n "$ac_ct_AR"; then
6377   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6378 $as_echo "$ac_ct_AR" >&6; }
6379 else
6380   { $as_echo "$as_me:$LINENO: result: no" >&5
6381 $as_echo "no" >&6; }
6382 fi
6383
6384   if test "x$ac_ct_AR" = x; then
6385     AR="ar"
6386   else
6387     case $cross_compiling:$ac_tool_warned in
6388 yes:)
6389 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6390 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6391 ac_tool_warned=yes ;;
6392 esac
6393     AR=$ac_ct_AR
6394   fi
6395 else
6396   AR="$ac_cv_prog_AR"
6397 fi
6398
6399 if test "$PORTNAME" = "win32"; then
6400   if test -n "$ac_tool_prefix"; then
6401   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6402 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6403 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6404 $as_echo_n "checking for $ac_word... " >&6; }
6405 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6406   $as_echo_n "(cached) " >&6
6407 else
6408   if test -n "$DLLTOOL"; then
6409   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6410 else
6411 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6412 for as_dir in $PATH
6413 do
6414   IFS=$as_save_IFS
6415   test -z "$as_dir" && as_dir=.
6416   for ac_exec_ext in '' $ac_executable_extensions; do
6417   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6418     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6419     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6420     break 2
6421   fi
6422 done
6423 done
6424 IFS=$as_save_IFS
6425
6426 fi
6427 fi
6428 DLLTOOL=$ac_cv_prog_DLLTOOL
6429 if test -n "$DLLTOOL"; then
6430   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6431 $as_echo "$DLLTOOL" >&6; }
6432 else
6433   { $as_echo "$as_me:$LINENO: result: no" >&5
6434 $as_echo "no" >&6; }
6435 fi
6436
6437
6438 fi
6439 if test -z "$ac_cv_prog_DLLTOOL"; then
6440   ac_ct_DLLTOOL=$DLLTOOL
6441   # Extract the first word of "dlltool", so it can be a program name with args.
6442 set dummy dlltool; ac_word=$2
6443 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6444 $as_echo_n "checking for $ac_word... " >&6; }
6445 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6446   $as_echo_n "(cached) " >&6
6447 else
6448   if test -n "$ac_ct_DLLTOOL"; then
6449   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6450 else
6451 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6452 for as_dir in $PATH
6453 do
6454   IFS=$as_save_IFS
6455   test -z "$as_dir" && as_dir=.
6456   for ac_exec_ext in '' $ac_executable_extensions; do
6457   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6458     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6459     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6460     break 2
6461   fi
6462 done
6463 done
6464 IFS=$as_save_IFS
6465
6466 fi
6467 fi
6468 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6469 if test -n "$ac_ct_DLLTOOL"; then
6470   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6471 $as_echo "$ac_ct_DLLTOOL" >&6; }
6472 else
6473   { $as_echo "$as_me:$LINENO: result: no" >&5
6474 $as_echo "no" >&6; }
6475 fi
6476
6477   if test "x$ac_ct_DLLTOOL" = x; then
6478     DLLTOOL="dlltool"
6479   else
6480     case $cross_compiling:$ac_tool_warned in
6481 yes:)
6482 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6483 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6484 ac_tool_warned=yes ;;
6485 esac
6486     DLLTOOL=$ac_ct_DLLTOOL
6487   fi
6488 else
6489   DLLTOOL="$ac_cv_prog_DLLTOOL"
6490 fi
6491
6492   if test -n "$ac_tool_prefix"; then
6493   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6494 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6495 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6496 $as_echo_n "checking for $ac_word... " >&6; }
6497 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6498   $as_echo_n "(cached) " >&6
6499 else
6500   if test -n "$DLLWRAP"; then
6501   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6502 else
6503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6504 for as_dir in $PATH
6505 do
6506   IFS=$as_save_IFS
6507   test -z "$as_dir" && as_dir=.
6508   for ac_exec_ext in '' $ac_executable_extensions; do
6509   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6510     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6511     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6512     break 2
6513   fi
6514 done
6515 done
6516 IFS=$as_save_IFS
6517
6518 fi
6519 fi
6520 DLLWRAP=$ac_cv_prog_DLLWRAP
6521 if test -n "$DLLWRAP"; then
6522   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6523 $as_echo "$DLLWRAP" >&6; }
6524 else
6525   { $as_echo "$as_me:$LINENO: result: no" >&5
6526 $as_echo "no" >&6; }
6527 fi
6528
6529
6530 fi
6531 if test -z "$ac_cv_prog_DLLWRAP"; then
6532   ac_ct_DLLWRAP=$DLLWRAP
6533   # Extract the first word of "dllwrap", so it can be a program name with args.
6534 set dummy dllwrap; ac_word=$2
6535 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6536 $as_echo_n "checking for $ac_word... " >&6; }
6537 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6538   $as_echo_n "(cached) " >&6
6539 else
6540   if test -n "$ac_ct_DLLWRAP"; then
6541   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6542 else
6543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6544 for as_dir in $PATH
6545 do
6546   IFS=$as_save_IFS
6547   test -z "$as_dir" && as_dir=.
6548   for ac_exec_ext in '' $ac_executable_extensions; do
6549   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6550     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6551     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6552     break 2
6553   fi
6554 done
6555 done
6556 IFS=$as_save_IFS
6557
6558 fi
6559 fi
6560 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6561 if test -n "$ac_ct_DLLWRAP"; then
6562   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6563 $as_echo "$ac_ct_DLLWRAP" >&6; }
6564 else
6565   { $as_echo "$as_me:$LINENO: result: no" >&5
6566 $as_echo "no" >&6; }
6567 fi
6568
6569   if test "x$ac_ct_DLLWRAP" = x; then
6570     DLLWRAP="dllwrap"
6571   else
6572     case $cross_compiling:$ac_tool_warned in
6573 yes:)
6574 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6575 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6576 ac_tool_warned=yes ;;
6577 esac
6578     DLLWRAP=$ac_ct_DLLWRAP
6579   fi
6580 else
6581   DLLWRAP="$ac_cv_prog_DLLWRAP"
6582 fi
6583
6584   if test -n "$ac_tool_prefix"; then
6585   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6586 set dummy ${ac_tool_prefix}windres; ac_word=$2
6587 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6588 $as_echo_n "checking for $ac_word... " >&6; }
6589 if test "${ac_cv_prog_WINDRES+set}" = set; then
6590   $as_echo_n "(cached) " >&6
6591 else
6592   if test -n "$WINDRES"; then
6593   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6594 else
6595 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6596 for as_dir in $PATH
6597 do
6598   IFS=$as_save_IFS
6599   test -z "$as_dir" && as_dir=.
6600   for ac_exec_ext in '' $ac_executable_extensions; do
6601   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6602     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6603     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6604     break 2
6605   fi
6606 done
6607 done
6608 IFS=$as_save_IFS
6609
6610 fi
6611 fi
6612 WINDRES=$ac_cv_prog_WINDRES
6613 if test -n "$WINDRES"; then
6614   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6615 $as_echo "$WINDRES" >&6; }
6616 else
6617   { $as_echo "$as_me:$LINENO: result: no" >&5
6618 $as_echo "no" >&6; }
6619 fi
6620
6621
6622 fi
6623 if test -z "$ac_cv_prog_WINDRES"; then
6624   ac_ct_WINDRES=$WINDRES
6625   # Extract the first word of "windres", so it can be a program name with args.
6626 set dummy windres; ac_word=$2
6627 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6628 $as_echo_n "checking for $ac_word... " >&6; }
6629 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6630   $as_echo_n "(cached) " >&6
6631 else
6632   if test -n "$ac_ct_WINDRES"; then
6633   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6634 else
6635 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6636 for as_dir in $PATH
6637 do
6638   IFS=$as_save_IFS
6639   test -z "$as_dir" && as_dir=.
6640   for ac_exec_ext in '' $ac_executable_extensions; do
6641   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6642     ac_cv_prog_ac_ct_WINDRES="windres"
6643     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6644     break 2
6645   fi
6646 done
6647 done
6648 IFS=$as_save_IFS
6649
6650 fi
6651 fi
6652 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6653 if test -n "$ac_ct_WINDRES"; then
6654   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6655 $as_echo "$ac_ct_WINDRES" >&6; }
6656 else
6657   { $as_echo "$as_me:$LINENO: result: no" >&5
6658 $as_echo "no" >&6; }
6659 fi
6660
6661   if test "x$ac_ct_WINDRES" = x; then
6662     WINDRES="windres"
6663   else
6664     case $cross_compiling:$ac_tool_warned in
6665 yes:)
6666 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6667 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6668 ac_tool_warned=yes ;;
6669 esac
6670     WINDRES=$ac_ct_WINDRES
6671   fi
6672 else
6673   WINDRES="$ac_cv_prog_WINDRES"
6674 fi
6675
6676 fi
6677
6678 # Extract the first word of "tar", so it can be a program name with args.
6679 set dummy tar; ac_word=$2
6680 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6681 $as_echo_n "checking for $ac_word... " >&6; }
6682 if test "${ac_cv_path_TAR+set}" = set; then
6683   $as_echo_n "(cached) " >&6
6684 else
6685   case $TAR in
6686   [\\/]* | ?:[\\/]*)
6687   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
6688   ;;
6689   *)
6690   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6691 for as_dir in $PATH
6692 do
6693   IFS=$as_save_IFS
6694   test -z "$as_dir" && as_dir=.
6695   for ac_exec_ext in '' $ac_executable_extensions; do
6696   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6697     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
6698     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6699     break 2
6700   fi
6701 done
6702 done
6703 IFS=$as_save_IFS
6704
6705   ;;
6706 esac
6707 fi
6708 TAR=$ac_cv_path_TAR
6709 if test -n "$TAR"; then
6710   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
6711 $as_echo "$TAR" >&6; }
6712 else
6713   { $as_echo "$as_me:$LINENO: result: no" >&5
6714 $as_echo "no" >&6; }
6715 fi
6716
6717
6718 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
6719 $as_echo_n "checking whether ln -s works... " >&6; }
6720 LN_S=$as_ln_s
6721 if test "$LN_S" = "ln -s"; then
6722   { $as_echo "$as_me:$LINENO: result: yes" >&5
6723 $as_echo "yes" >&6; }
6724 else
6725   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6726 $as_echo "no, using $LN_S" >&6; }
6727 fi
6728
6729 for ac_prog in gawk mawk nawk awk
6730 do
6731   # Extract the first word of "$ac_prog", so it can be a program name with args.
6732 set dummy $ac_prog; ac_word=$2
6733 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6734 $as_echo_n "checking for $ac_word... " >&6; }
6735 if test "${ac_cv_prog_AWK+set}" = set; then
6736   $as_echo_n "(cached) " >&6
6737 else
6738   if test -n "$AWK"; then
6739   ac_cv_prog_AWK="$AWK" # Let the user override the test.
6740 else
6741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6742 for as_dir in $PATH
6743 do
6744   IFS=$as_save_IFS
6745   test -z "$as_dir" && as_dir=.
6746   for ac_exec_ext in '' $ac_executable_extensions; do
6747   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6748     ac_cv_prog_AWK="$ac_prog"
6749     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6750     break 2
6751   fi
6752 done
6753 done
6754 IFS=$as_save_IFS
6755
6756 fi
6757 fi
6758 AWK=$ac_cv_prog_AWK
6759 if test -n "$AWK"; then
6760   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
6761 $as_echo "$AWK" >&6; }
6762 else
6763   { $as_echo "$as_me:$LINENO: result: no" >&5
6764 $as_echo "no" >&6; }
6765 fi
6766
6767
6768   test -n "$AWK" && break
6769 done
6770
6771 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
6772 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
6773 if test -z "$MKDIR_P"; then
6774   if test "${ac_cv_path_mkdir+set}" = set; then
6775   $as_echo_n "(cached) " >&6
6776 else
6777   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6778 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6779 do
6780   IFS=$as_save_IFS
6781   test -z "$as_dir" && as_dir=.
6782   for ac_prog in mkdir gmkdir; do
6783          for ac_exec_ext in '' $ac_executable_extensions; do
6784            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
6785            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
6786              'mkdir (GNU coreutils) '* | \
6787              'mkdir (coreutils) '* | \
6788              'mkdir (fileutils) '4.1*)
6789                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
6790                break 3;;
6791            esac
6792          done
6793        done
6794 done
6795 IFS=$as_save_IFS
6796
6797 fi
6798
6799   if test "${ac_cv_path_mkdir+set}" = set; then
6800     MKDIR_P="$ac_cv_path_mkdir -p"
6801   else
6802     # As a last resort, use the slow shell script.  Don't cache a
6803     # value for MKDIR_P within a source directory, because that will
6804     # break other packages using the cache if that directory is
6805     # removed, or if the value is a relative name.
6806     test -d ./--version && rmdir ./--version
6807     MKDIR_P="$ac_install_sh -d"
6808   fi
6809 fi
6810 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
6811 $as_echo "$MKDIR_P" >&6; }
6812
6813 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
6814 # a relative path to it in each makefile where it subsitutes it. This clashes
6815 # with our Makefile.global concept. This workaround helps.
6816 case $MKDIR_P in
6817   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
6818 esac
6819
6820 # Let the user override the search
6821 if test -z "$BISON"; then
6822   for ac_prog in bison
6823 do
6824   # Extract the first word of "$ac_prog", so it can be a program name with args.
6825 set dummy $ac_prog; ac_word=$2
6826 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6827 $as_echo_n "checking for $ac_word... " >&6; }
6828 if test "${ac_cv_path_BISON+set}" = set; then
6829   $as_echo_n "(cached) " >&6
6830 else
6831   case $BISON in
6832   [\\/]* | ?:[\\/]*)
6833   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
6834   ;;
6835   *)
6836   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6837 for as_dir in $PATH
6838 do
6839   IFS=$as_save_IFS
6840   test -z "$as_dir" && as_dir=.
6841   for ac_exec_ext in '' $ac_executable_extensions; do
6842   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6843     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
6844     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6845     break 2
6846   fi
6847 done
6848 done
6849 IFS=$as_save_IFS
6850
6851   ;;
6852 esac
6853 fi
6854 BISON=$ac_cv_path_BISON
6855 if test -n "$BISON"; then
6856   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
6857 $as_echo "$BISON" >&6; }
6858 else
6859   { $as_echo "$as_me:$LINENO: result: no" >&5
6860 $as_echo "no" >&6; }
6861 fi
6862
6863
6864   test -n "$BISON" && break
6865 done
6866
6867 fi
6868
6869 if test "$BISON"; then
6870   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
6871   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
6872 $as_echo "$as_me: using $pgac_bison_version" >&6;}
6873   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
6874   then
6875     { $as_echo "$as_me:$LINENO: WARNING:
6876 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6877 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
6878 $as_echo "$as_me: WARNING:
6879 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6880 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
6881     BISON=""
6882   fi
6883 fi
6884
6885 if test -z "$BISON"; then
6886   { $as_echo "$as_me:$LINENO: WARNING:
6887 *** Without Bison you will not be able to build PostgreSQL from Git nor
6888 *** change any of the parser definition files.  You can obtain Bison from
6889 *** a GNU mirror site.  (If you are using the official distribution of
6890 *** PostgreSQL then you do not need to worry about this, because the Bison
6891 *** output is pre-generated.)" >&5
6892 $as_echo "$as_me: WARNING:
6893 *** Without Bison you will not be able to build PostgreSQL from Git nor
6894 *** change any of the parser definition files.  You can obtain Bison from
6895 *** a GNU mirror site.  (If you are using the official distribution of
6896 *** PostgreSQL then you do not need to worry about this, because the Bison
6897 *** output is pre-generated.)" >&2;}
6898 fi
6899 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
6900
6901
6902 { $as_echo "$as_me:$LINENO: checking for flex" >&5
6903 $as_echo_n "checking for flex... " >&6; }
6904 if test "${pgac_cv_path_flex+set}" = set; then
6905   $as_echo_n "(cached) " >&6
6906 else
6907   # Let the user override the test
6908 if test -n "$FLEX"; then
6909   pgac_cv_path_flex=$FLEX
6910 else
6911   pgac_save_IFS=$IFS
6912   IFS=$PATH_SEPARATOR
6913   for pgac_dir in $PATH; do
6914     IFS=$pgac_save_IFS
6915     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
6916       pgac_dir=`pwd`
6917     fi
6918     for pgac_prog in flex lex; do
6919       pgac_candidate="$pgac_dir/$pgac_prog"
6920       if test -f "$pgac_candidate" \
6921         && $pgac_candidate --version </dev/null >/dev/null 2>&1
6922       then
6923         echo '%%'  > conftest.l
6924         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
6925           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
6926           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
6927           then
6928             pgac_cv_path_flex=$pgac_candidate
6929             break 2
6930           else
6931             { $as_echo "$as_me:$LINENO: WARNING:
6932 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6933 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
6934 $as_echo "$as_me: WARNING:
6935 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6936 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
6937           fi
6938         fi
6939       fi
6940     done
6941   done
6942   rm -f conftest.l lex.yy.c
6943   : ${pgac_cv_path_flex=no}
6944 fi
6945
6946 fi
6947 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
6948 $as_echo "$pgac_cv_path_flex" >&6; }
6949 if test x"$pgac_cv_path_flex" = x"no"; then
6950   { $as_echo "$as_me:$LINENO: WARNING:
6951 *** Without Flex you will not be able to build PostgreSQL from Git nor
6952 *** change any of the scanner definition files.  You can obtain Flex from
6953 *** a GNU mirror site.  (If you are using the official distribution of
6954 *** PostgreSQL then you do not need to worry about this because the Flex
6955 *** output is pre-generated.)" >&5
6956 $as_echo "$as_me: WARNING:
6957 *** Without Flex you will not be able to build PostgreSQL from Git nor
6958 *** change any of the scanner definition files.  You can obtain Flex from
6959 *** a GNU mirror site.  (If you are using the official distribution of
6960 *** PostgreSQL then you do not need to worry about this because the Flex
6961 *** output is pre-generated.)" >&2;}
6962
6963   FLEX=
6964 else
6965   FLEX=$pgac_cv_path_flex
6966   pgac_flex_version=`$FLEX --version 2>/dev/null`
6967   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
6968 $as_echo "$as_me: using $pgac_flex_version" >&6;}
6969 fi
6970
6971
6972
6973
6974
6975 # Let the user override the search
6976 if test -z "$PERL"; then
6977   # Extract the first word of "perl", so it can be a program name with args.
6978 set dummy perl; ac_word=$2
6979 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6980 $as_echo_n "checking for $ac_word... " >&6; }
6981 if test "${ac_cv_path_PERL+set}" = set; then
6982   $as_echo_n "(cached) " >&6
6983 else
6984   case $PERL in
6985   [\\/]* | ?:[\\/]*)
6986   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
6987   ;;
6988   *)
6989   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6990 for as_dir in $PATH
6991 do
6992   IFS=$as_save_IFS
6993   test -z "$as_dir" && as_dir=.
6994   for ac_exec_ext in '' $ac_executable_extensions; do
6995   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6996     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
6997     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6998     break 2
6999   fi
7000 done
7001 done
7002 IFS=$as_save_IFS
7003
7004   ;;
7005 esac
7006 fi
7007 PERL=$ac_cv_path_PERL
7008 if test -n "$PERL"; then
7009   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
7010 $as_echo "$PERL" >&6; }
7011 else
7012   { $as_echo "$as_me:$LINENO: result: no" >&5
7013 $as_echo "no" >&6; }
7014 fi
7015
7016
7017 fi
7018
7019 if test "$PERL"; then
7020   pgac_perl_version=`$PERL -v 2>/dev/null | sed -n 's/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p'`
7021   { $as_echo "$as_me:$LINENO: using perl $pgac_perl_version" >&5
7022 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
7023   if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
7024     $AWK '{ if ($1 = 5 && $2 >= 8) exit 1; else exit 0;}'
7025   then
7026     { $as_echo "$as_me:$LINENO: WARNING:
7027 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
7028 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
7029 $as_echo "$as_me: WARNING:
7030 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
7031 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
7032     PERL=""
7033   fi
7034 fi
7035
7036 if test -z "$PERL"; then
7037   { $as_echo "$as_me:$LINENO: WARNING:
7038 *** Without Perl you will not be able to build PostgreSQL from Git.
7039 *** You can obtain Perl from any CPAN mirror site.
7040 *** (If you are using the official distribution of PostgreSQL then you do not
7041 *** need to worry about this, because the Perl output is pre-generated.)" >&5
7042 $as_echo "$as_me: WARNING:
7043 *** Without Perl you will not be able to build PostgreSQL from Git.
7044 *** You can obtain Perl from any CPAN mirror site.
7045 *** (If you are using the official distribution of PostgreSQL then you do not
7046 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
7047 fi
7048
7049 if test "$with_perl" = yes; then
7050   if test -z "$PERL"; then
7051     { { $as_echo "$as_me:$LINENO: error: Perl not found" >&5
7052 $as_echo "$as_me: error: Perl not found" >&2;}
7053    { (exit 1); exit 1; }; }
7054   fi
7055
7056 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
7057 $as_echo_n "checking for Perl archlibexp... " >&6; }
7058 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
7059 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
7060 $as_echo "$perl_archlibexp" >&6; }
7061 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
7062 $as_echo_n "checking for Perl privlibexp... " >&6; }
7063 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
7064 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
7065 $as_echo "$perl_privlibexp" >&6; }
7066 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
7067 $as_echo_n "checking for Perl useshrplib... " >&6; }
7068 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
7069 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
7070 $as_echo "$perl_useshrplib" >&6; }
7071
7072 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
7073 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
7074 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
7075 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
7076 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
7077 if test -z "$perl_embed_ldflags" ; then
7078         { $as_echo "$as_me:$LINENO: result: no" >&5
7079 $as_echo "no" >&6; }
7080         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
7081 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7082 installed." >&5
7083 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
7084 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7085 installed." >&2;}
7086    { (exit 1); exit 1; }; }
7087 else
7088         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
7089 $as_echo "$perl_embed_ldflags" >&6; }
7090 fi
7091
7092 fi
7093
7094 if test "$with_python" = yes; then
7095   # Extract the first word of "python", so it can be a program name with args.
7096 set dummy python; ac_word=$2
7097 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7098 $as_echo_n "checking for $ac_word... " >&6; }
7099 if test "${ac_cv_path_PYTHON+set}" = set; then
7100   $as_echo_n "(cached) " >&6
7101 else
7102   case $PYTHON in
7103   [\\/]* | ?:[\\/]*)
7104   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
7105   ;;
7106   *)
7107   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7108 for as_dir in $PATH
7109 do
7110   IFS=$as_save_IFS
7111   test -z "$as_dir" && as_dir=.
7112   for ac_exec_ext in '' $ac_executable_extensions; do
7113   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7114     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
7115     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7116     break 2
7117   fi
7118 done
7119 done
7120 IFS=$as_save_IFS
7121
7122   ;;
7123 esac
7124 fi
7125 PYTHON=$ac_cv_path_PYTHON
7126 if test -n "$PYTHON"; then
7127   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
7128 $as_echo "$PYTHON" >&6; }
7129 else
7130   { $as_echo "$as_me:$LINENO: result: no" >&5
7131 $as_echo "no" >&6; }
7132 fi
7133
7134
7135 if test x"$PYTHON" = x""; then
7136   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
7137 $as_echo "$as_me: error: Python not found" >&2;}
7138    { (exit 1); exit 1; }; }
7139 fi
7140
7141
7142 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
7143 $as_echo_n "checking for Python distutils module... " >&6; }
7144 if "${PYTHON}" -c 'import distutils' 2>&5
7145 then
7146     { $as_echo "$as_me:$LINENO: result: yes" >&5
7147 $as_echo "yes" >&6; }
7148 else
7149     { $as_echo "$as_me:$LINENO: result: no" >&5
7150 $as_echo "no" >&6; }
7151     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
7152 $as_echo "$as_me: error: distutils module not found" >&2;}
7153    { (exit 1); exit 1; }; }
7154 fi
7155 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
7156 $as_echo_n "checking Python configuration directory... " >&6; }
7157 python_majorversion=`${PYTHON} -c "import sys; print(sys.version[0])"`
7158 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
7159 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'))"`
7160 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print('-I'+distutils.sysconfig.get_python_inc())"`
7161
7162 # This should be enough of a message.
7163 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
7164 $as_echo "$python_configdir" >&6; }
7165
7166
7167 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
7168 $as_echo_n "checking how to link an embedded Python application... " >&6; }
7169
7170 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
7171 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
7172 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
7173 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
7174
7175 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
7176 then
7177         # New way: use the official shared library
7178         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
7179         python_libspec="-L${python_libdir} -l${ldlibrary}"
7180 else
7181         # Old way: use libpython from python_configdir
7182         python_libdir="${python_configdir}"
7183         python_libspec="-L${python_libdir} -lpython${python_version}"
7184 fi
7185
7186 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
7187
7188 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
7189 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
7190
7191
7192 # threaded python is not supported on bsd's
7193 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7194 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7195 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7196 if test "$pythreads" = "1"; then
7197   { $as_echo "$as_me:$LINENO: result: yes" >&5
7198 $as_echo "yes" >&6; }
7199   case $host_os in
7200   openbsd*|freebsd*)
7201     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7202 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7203    { (exit 1); exit 1; }; }
7204     ;;
7205   esac
7206 else
7207   { $as_echo "$as_me:$LINENO: result: no" >&5
7208 $as_echo "no" >&6; }
7209 fi
7210
7211
7212 fi
7213
7214 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7215   # Extract the first word of "zic", so it can be a program name with args.
7216 set dummy zic; ac_word=$2
7217 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7218 $as_echo_n "checking for $ac_word... " >&6; }
7219 if test "${ac_cv_path_ZIC+set}" = set; then
7220   $as_echo_n "(cached) " >&6
7221 else
7222   case $ZIC in
7223   [\\/]* | ?:[\\/]*)
7224   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7225   ;;
7226   *)
7227   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7228 for as_dir in $PATH
7229 do
7230   IFS=$as_save_IFS
7231   test -z "$as_dir" && as_dir=.
7232   for ac_exec_ext in '' $ac_executable_extensions; do
7233   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7234     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7235     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7236     break 2
7237   fi
7238 done
7239 done
7240 IFS=$as_save_IFS
7241
7242   ;;
7243 esac
7244 fi
7245 ZIC=$ac_cv_path_ZIC
7246 if test -n "$ZIC"; then
7247   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7248 $as_echo "$ZIC" >&6; }
7249 else
7250   { $as_echo "$as_me:$LINENO: result: no" >&5
7251 $as_echo "no" >&6; }
7252 fi
7253
7254
7255   if test -z "$ZIC"; then
7256     { { $as_echo "$as_me:$LINENO: error:
7257 When cross-compiling, either use the option --with-system-tzdata to use
7258 existing time-zone data, or set the environment variable ZIC to a zic
7259 program to use during the build." >&5
7260 $as_echo "$as_me: error:
7261 When cross-compiling, either use the option --with-system-tzdata to use
7262 existing time-zone data, or set the environment variable ZIC to a zic
7263 program to use during the build." >&2;}
7264    { (exit 1); exit 1; }; }
7265   fi
7266 fi
7267
7268
7269 ##
7270 ## Libraries
7271 ##
7272 ## Most libraries are included only if they demonstrably provide a function
7273 ## we need, but libm is an exception: always include it, because there are
7274 ## too many compilers that play cute optimization games that will break
7275 ## probes for standard functions such as pow().
7276 ##
7277
7278
7279 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7280 $as_echo_n "checking for main in -lm... " >&6; }
7281 if test "${ac_cv_lib_m_main+set}" = set; then
7282   $as_echo_n "(cached) " >&6
7283 else
7284   ac_check_lib_save_LIBS=$LIBS
7285 LIBS="-lm  $LIBS"
7286 cat >conftest.$ac_ext <<_ACEOF
7287 /* confdefs.h.  */
7288 _ACEOF
7289 cat confdefs.h >>conftest.$ac_ext
7290 cat >>conftest.$ac_ext <<_ACEOF
7291 /* end confdefs.h.  */
7292
7293
7294 int
7295 main ()
7296 {
7297 return main ();
7298   ;
7299   return 0;
7300 }
7301 _ACEOF
7302 rm -f conftest.$ac_objext conftest$ac_exeext
7303 if { (ac_try="$ac_link"
7304 case "(($ac_try" in
7305   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7306   *) ac_try_echo=$ac_try;;
7307 esac
7308 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7309 $as_echo "$ac_try_echo") >&5
7310   (eval "$ac_link") 2>conftest.er1
7311   ac_status=$?
7312   grep -v '^ *+' conftest.er1 >conftest.err
7313   rm -f conftest.er1
7314   cat conftest.err >&5
7315   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7316   (exit $ac_status); } && {
7317          test -z "$ac_c_werror_flag" ||
7318          test ! -s conftest.err
7319        } && test -s conftest$ac_exeext && {
7320          test "$cross_compiling" = yes ||
7321          $as_test_x conftest$ac_exeext
7322        }; then
7323   ac_cv_lib_m_main=yes
7324 else
7325   $as_echo "$as_me: failed program was:" >&5
7326 sed 's/^/| /' conftest.$ac_ext >&5
7327
7328         ac_cv_lib_m_main=no
7329 fi
7330
7331 rm -rf conftest.dSYM
7332 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7333       conftest$ac_exeext conftest.$ac_ext
7334 LIBS=$ac_check_lib_save_LIBS
7335 fi
7336 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7337 $as_echo "$ac_cv_lib_m_main" >&6; }
7338 if test "x$ac_cv_lib_m_main" = x""yes; then
7339   cat >>confdefs.h <<_ACEOF
7340 #define HAVE_LIBM 1
7341 _ACEOF
7342
7343   LIBS="-lm $LIBS"
7344
7345 fi
7346
7347 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7348 $as_echo_n "checking for library containing setproctitle... " >&6; }
7349 if test "${ac_cv_search_setproctitle+set}" = set; then
7350   $as_echo_n "(cached) " >&6
7351 else
7352   ac_func_search_save_LIBS=$LIBS
7353 cat >conftest.$ac_ext <<_ACEOF
7354 /* confdefs.h.  */
7355 _ACEOF
7356 cat confdefs.h >>conftest.$ac_ext
7357 cat >>conftest.$ac_ext <<_ACEOF
7358 /* end confdefs.h.  */
7359
7360 /* Override any GCC internal prototype to avoid an error.
7361    Use char because int might match the return type of a GCC
7362    builtin and then its argument prototype would still apply.  */
7363 #ifdef __cplusplus
7364 extern "C"
7365 #endif
7366 char setproctitle ();
7367 int
7368 main ()
7369 {
7370 return setproctitle ();
7371   ;
7372   return 0;
7373 }
7374 _ACEOF
7375 for ac_lib in '' util; do
7376   if test -z "$ac_lib"; then
7377     ac_res="none required"
7378   else
7379     ac_res=-l$ac_lib
7380     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7381   fi
7382   rm -f conftest.$ac_objext conftest$ac_exeext
7383 if { (ac_try="$ac_link"
7384 case "(($ac_try" in
7385   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7386   *) ac_try_echo=$ac_try;;
7387 esac
7388 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7389 $as_echo "$ac_try_echo") >&5
7390   (eval "$ac_link") 2>conftest.er1
7391   ac_status=$?
7392   grep -v '^ *+' conftest.er1 >conftest.err
7393   rm -f conftest.er1
7394   cat conftest.err >&5
7395   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7396   (exit $ac_status); } && {
7397          test -z "$ac_c_werror_flag" ||
7398          test ! -s conftest.err
7399        } && test -s conftest$ac_exeext && {
7400          test "$cross_compiling" = yes ||
7401          $as_test_x conftest$ac_exeext
7402        }; then
7403   ac_cv_search_setproctitle=$ac_res
7404 else
7405   $as_echo "$as_me: failed program was:" >&5
7406 sed 's/^/| /' conftest.$ac_ext >&5
7407
7408
7409 fi
7410
7411 rm -rf conftest.dSYM
7412 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7413       conftest$ac_exeext
7414   if test "${ac_cv_search_setproctitle+set}" = set; then
7415   break
7416 fi
7417 done
7418 if test "${ac_cv_search_setproctitle+set}" = set; then
7419   :
7420 else
7421   ac_cv_search_setproctitle=no
7422 fi
7423 rm conftest.$ac_ext
7424 LIBS=$ac_func_search_save_LIBS
7425 fi
7426 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7427 $as_echo "$ac_cv_search_setproctitle" >&6; }
7428 ac_res=$ac_cv_search_setproctitle
7429 if test "$ac_res" != no; then
7430   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7431
7432 fi
7433
7434 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7435 $as_echo_n "checking for library containing dlopen... " >&6; }
7436 if test "${ac_cv_search_dlopen+set}" = set; then
7437   $as_echo_n "(cached) " >&6
7438 else
7439   ac_func_search_save_LIBS=$LIBS
7440 cat >conftest.$ac_ext <<_ACEOF
7441 /* confdefs.h.  */
7442 _ACEOF
7443 cat confdefs.h >>conftest.$ac_ext
7444 cat >>conftest.$ac_ext <<_ACEOF
7445 /* end confdefs.h.  */
7446
7447 /* Override any GCC internal prototype to avoid an error.
7448    Use char because int might match the return type of a GCC
7449    builtin and then its argument prototype would still apply.  */
7450 #ifdef __cplusplus
7451 extern "C"
7452 #endif
7453 char dlopen ();
7454 int
7455 main ()
7456 {
7457 return dlopen ();
7458   ;
7459   return 0;
7460 }
7461 _ACEOF
7462 for ac_lib in '' dl; do
7463   if test -z "$ac_lib"; then
7464     ac_res="none required"
7465   else
7466     ac_res=-l$ac_lib
7467     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7468   fi
7469   rm -f conftest.$ac_objext conftest$ac_exeext
7470 if { (ac_try="$ac_link"
7471 case "(($ac_try" in
7472   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7473   *) ac_try_echo=$ac_try;;
7474 esac
7475 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7476 $as_echo "$ac_try_echo") >&5
7477   (eval "$ac_link") 2>conftest.er1
7478   ac_status=$?
7479   grep -v '^ *+' conftest.er1 >conftest.err
7480   rm -f conftest.er1
7481   cat conftest.err >&5
7482   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7483   (exit $ac_status); } && {
7484          test -z "$ac_c_werror_flag" ||
7485          test ! -s conftest.err
7486        } && test -s conftest$ac_exeext && {
7487          test "$cross_compiling" = yes ||
7488          $as_test_x conftest$ac_exeext
7489        }; then
7490   ac_cv_search_dlopen=$ac_res
7491 else
7492   $as_echo "$as_me: failed program was:" >&5
7493 sed 's/^/| /' conftest.$ac_ext >&5
7494
7495
7496 fi
7497
7498 rm -rf conftest.dSYM
7499 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7500       conftest$ac_exeext
7501   if test "${ac_cv_search_dlopen+set}" = set; then
7502   break
7503 fi
7504 done
7505 if test "${ac_cv_search_dlopen+set}" = set; then
7506   :
7507 else
7508   ac_cv_search_dlopen=no
7509 fi
7510 rm conftest.$ac_ext
7511 LIBS=$ac_func_search_save_LIBS
7512 fi
7513 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7514 $as_echo "$ac_cv_search_dlopen" >&6; }
7515 ac_res=$ac_cv_search_dlopen
7516 if test "$ac_res" != no; then
7517   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7518
7519 fi
7520
7521 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7522 $as_echo_n "checking for library containing socket... " >&6; }
7523 if test "${ac_cv_search_socket+set}" = set; then
7524   $as_echo_n "(cached) " >&6
7525 else
7526   ac_func_search_save_LIBS=$LIBS
7527 cat >conftest.$ac_ext <<_ACEOF
7528 /* confdefs.h.  */
7529 _ACEOF
7530 cat confdefs.h >>conftest.$ac_ext
7531 cat >>conftest.$ac_ext <<_ACEOF
7532 /* end confdefs.h.  */
7533
7534 /* Override any GCC internal prototype to avoid an error.
7535    Use char because int might match the return type of a GCC
7536    builtin and then its argument prototype would still apply.  */
7537 #ifdef __cplusplus
7538 extern "C"
7539 #endif
7540 char socket ();
7541 int
7542 main ()
7543 {
7544 return socket ();
7545   ;
7546   return 0;
7547 }
7548 _ACEOF
7549 for ac_lib in '' socket wsock32; do
7550   if test -z "$ac_lib"; then
7551     ac_res="none required"
7552   else
7553     ac_res=-l$ac_lib
7554     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7555   fi
7556   rm -f conftest.$ac_objext conftest$ac_exeext
7557 if { (ac_try="$ac_link"
7558 case "(($ac_try" in
7559   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7560   *) ac_try_echo=$ac_try;;
7561 esac
7562 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7563 $as_echo "$ac_try_echo") >&5
7564   (eval "$ac_link") 2>conftest.er1
7565   ac_status=$?
7566   grep -v '^ *+' conftest.er1 >conftest.err
7567   rm -f conftest.er1
7568   cat conftest.err >&5
7569   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7570   (exit $ac_status); } && {
7571          test -z "$ac_c_werror_flag" ||
7572          test ! -s conftest.err
7573        } && test -s conftest$ac_exeext && {
7574          test "$cross_compiling" = yes ||
7575          $as_test_x conftest$ac_exeext
7576        }; then
7577   ac_cv_search_socket=$ac_res
7578 else
7579   $as_echo "$as_me: failed program was:" >&5
7580 sed 's/^/| /' conftest.$ac_ext >&5
7581
7582
7583 fi
7584
7585 rm -rf conftest.dSYM
7586 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7587       conftest$ac_exeext
7588   if test "${ac_cv_search_socket+set}" = set; then
7589   break
7590 fi
7591 done
7592 if test "${ac_cv_search_socket+set}" = set; then
7593   :
7594 else
7595   ac_cv_search_socket=no
7596 fi
7597 rm conftest.$ac_ext
7598 LIBS=$ac_func_search_save_LIBS
7599 fi
7600 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
7601 $as_echo "$ac_cv_search_socket" >&6; }
7602 ac_res=$ac_cv_search_socket
7603 if test "$ac_res" != no; then
7604   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7605
7606 fi
7607
7608 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
7609 $as_echo_n "checking for library containing shl_load... " >&6; }
7610 if test "${ac_cv_search_shl_load+set}" = set; then
7611   $as_echo_n "(cached) " >&6
7612 else
7613   ac_func_search_save_LIBS=$LIBS
7614 cat >conftest.$ac_ext <<_ACEOF
7615 /* confdefs.h.  */
7616 _ACEOF
7617 cat confdefs.h >>conftest.$ac_ext
7618 cat >>conftest.$ac_ext <<_ACEOF
7619 /* end confdefs.h.  */
7620
7621 /* Override any GCC internal prototype to avoid an error.
7622    Use char because int might match the return type of a GCC
7623    builtin and then its argument prototype would still apply.  */
7624 #ifdef __cplusplus
7625 extern "C"
7626 #endif
7627 char shl_load ();
7628 int
7629 main ()
7630 {
7631 return shl_load ();
7632   ;
7633   return 0;
7634 }
7635 _ACEOF
7636 for ac_lib in '' dld; do
7637   if test -z "$ac_lib"; then
7638     ac_res="none required"
7639   else
7640     ac_res=-l$ac_lib
7641     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7642   fi
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 ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7650 $as_echo "$ac_try_echo") >&5
7651   (eval "$ac_link") 2>conftest.er1
7652   ac_status=$?
7653   grep -v '^ *+' conftest.er1 >conftest.err
7654   rm -f conftest.er1
7655   cat conftest.err >&5
7656   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7657   (exit $ac_status); } && {
7658          test -z "$ac_c_werror_flag" ||
7659          test ! -s conftest.err
7660        } && test -s conftest$ac_exeext && {
7661          test "$cross_compiling" = yes ||
7662          $as_test_x conftest$ac_exeext
7663        }; then
7664   ac_cv_search_shl_load=$ac_res
7665 else
7666   $as_echo "$as_me: failed program was:" >&5
7667 sed 's/^/| /' conftest.$ac_ext >&5
7668
7669
7670 fi
7671
7672 rm -rf conftest.dSYM
7673 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7674       conftest$ac_exeext
7675   if test "${ac_cv_search_shl_load+set}" = set; then
7676   break
7677 fi
7678 done
7679 if test "${ac_cv_search_shl_load+set}" = set; then
7680   :
7681 else
7682   ac_cv_search_shl_load=no
7683 fi
7684 rm conftest.$ac_ext
7685 LIBS=$ac_func_search_save_LIBS
7686 fi
7687 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
7688 $as_echo "$ac_cv_search_shl_load" >&6; }
7689 ac_res=$ac_cv_search_shl_load
7690 if test "$ac_res" != no; then
7691   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7692
7693 fi
7694
7695 # We only use libld in port/dynloader/aix.c
7696 case $host_os in
7697      aix*)
7698         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
7699 $as_echo_n "checking for library containing ldopen... " >&6; }
7700 if test "${ac_cv_search_ldopen+set}" = set; then
7701   $as_echo_n "(cached) " >&6
7702 else
7703   ac_func_search_save_LIBS=$LIBS
7704 cat >conftest.$ac_ext <<_ACEOF
7705 /* confdefs.h.  */
7706 _ACEOF
7707 cat confdefs.h >>conftest.$ac_ext
7708 cat >>conftest.$ac_ext <<_ACEOF
7709 /* end confdefs.h.  */
7710
7711 /* Override any GCC internal prototype to avoid an error.
7712    Use char because int might match the return type of a GCC
7713    builtin and then its argument prototype would still apply.  */
7714 #ifdef __cplusplus
7715 extern "C"
7716 #endif
7717 char ldopen ();
7718 int
7719 main ()
7720 {
7721 return ldopen ();
7722   ;
7723   return 0;
7724 }
7725 _ACEOF
7726 for ac_lib in '' ld; do
7727   if test -z "$ac_lib"; then
7728     ac_res="none required"
7729   else
7730     ac_res=-l$ac_lib
7731     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7732   fi
7733   rm -f conftest.$ac_objext conftest$ac_exeext
7734 if { (ac_try="$ac_link"
7735 case "(($ac_try" in
7736   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7737   *) ac_try_echo=$ac_try;;
7738 esac
7739 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7740 $as_echo "$ac_try_echo") >&5
7741   (eval "$ac_link") 2>conftest.er1
7742   ac_status=$?
7743   grep -v '^ *+' conftest.er1 >conftest.err
7744   rm -f conftest.er1
7745   cat conftest.err >&5
7746   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7747   (exit $ac_status); } && {
7748          test -z "$ac_c_werror_flag" ||
7749          test ! -s conftest.err
7750        } && test -s conftest$ac_exeext && {
7751          test "$cross_compiling" = yes ||
7752          $as_test_x conftest$ac_exeext
7753        }; then
7754   ac_cv_search_ldopen=$ac_res
7755 else
7756   $as_echo "$as_me: failed program was:" >&5
7757 sed 's/^/| /' conftest.$ac_ext >&5
7758
7759
7760 fi
7761
7762 rm -rf conftest.dSYM
7763 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7764       conftest$ac_exeext
7765   if test "${ac_cv_search_ldopen+set}" = set; then
7766   break
7767 fi
7768 done
7769 if test "${ac_cv_search_ldopen+set}" = set; then
7770   :
7771 else
7772   ac_cv_search_ldopen=no
7773 fi
7774 rm conftest.$ac_ext
7775 LIBS=$ac_func_search_save_LIBS
7776 fi
7777 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
7778 $as_echo "$ac_cv_search_ldopen" >&6; }
7779 ac_res=$ac_cv_search_ldopen
7780 if test "$ac_res" != no; then
7781   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7782
7783 fi
7784
7785         ;;
7786 esac
7787 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
7788 $as_echo_n "checking for library containing getopt_long... " >&6; }
7789 if test "${ac_cv_search_getopt_long+set}" = set; then
7790   $as_echo_n "(cached) " >&6
7791 else
7792   ac_func_search_save_LIBS=$LIBS
7793 cat >conftest.$ac_ext <<_ACEOF
7794 /* confdefs.h.  */
7795 _ACEOF
7796 cat confdefs.h >>conftest.$ac_ext
7797 cat >>conftest.$ac_ext <<_ACEOF
7798 /* end confdefs.h.  */
7799
7800 /* Override any GCC internal prototype to avoid an error.
7801    Use char because int might match the return type of a GCC
7802    builtin and then its argument prototype would still apply.  */
7803 #ifdef __cplusplus
7804 extern "C"
7805 #endif
7806 char getopt_long ();
7807 int
7808 main ()
7809 {
7810 return getopt_long ();
7811   ;
7812   return 0;
7813 }
7814 _ACEOF
7815 for ac_lib in '' getopt gnugetopt; do
7816   if test -z "$ac_lib"; then
7817     ac_res="none required"
7818   else
7819     ac_res=-l$ac_lib
7820     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7821   fi
7822   rm -f conftest.$ac_objext conftest$ac_exeext
7823 if { (ac_try="$ac_link"
7824 case "(($ac_try" in
7825   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7826   *) ac_try_echo=$ac_try;;
7827 esac
7828 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7829 $as_echo "$ac_try_echo") >&5
7830   (eval "$ac_link") 2>conftest.er1
7831   ac_status=$?
7832   grep -v '^ *+' conftest.er1 >conftest.err
7833   rm -f conftest.er1
7834   cat conftest.err >&5
7835   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7836   (exit $ac_status); } && {
7837          test -z "$ac_c_werror_flag" ||
7838          test ! -s conftest.err
7839        } && test -s conftest$ac_exeext && {
7840          test "$cross_compiling" = yes ||
7841          $as_test_x conftest$ac_exeext
7842        }; then
7843   ac_cv_search_getopt_long=$ac_res
7844 else
7845   $as_echo "$as_me: failed program was:" >&5
7846 sed 's/^/| /' conftest.$ac_ext >&5
7847
7848
7849 fi
7850
7851 rm -rf conftest.dSYM
7852 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7853       conftest$ac_exeext
7854   if test "${ac_cv_search_getopt_long+set}" = set; then
7855   break
7856 fi
7857 done
7858 if test "${ac_cv_search_getopt_long+set}" = set; then
7859   :
7860 else
7861   ac_cv_search_getopt_long=no
7862 fi
7863 rm conftest.$ac_ext
7864 LIBS=$ac_func_search_save_LIBS
7865 fi
7866 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
7867 $as_echo "$ac_cv_search_getopt_long" >&6; }
7868 ac_res=$ac_cv_search_getopt_long
7869 if test "$ac_res" != no; then
7870   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7871
7872 fi
7873
7874 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
7875 $as_echo_n "checking for library containing crypt... " >&6; }
7876 if test "${ac_cv_search_crypt+set}" = set; then
7877   $as_echo_n "(cached) " >&6
7878 else
7879   ac_func_search_save_LIBS=$LIBS
7880 cat >conftest.$ac_ext <<_ACEOF
7881 /* confdefs.h.  */
7882 _ACEOF
7883 cat confdefs.h >>conftest.$ac_ext
7884 cat >>conftest.$ac_ext <<_ACEOF
7885 /* end confdefs.h.  */
7886
7887 /* Override any GCC internal prototype to avoid an error.
7888    Use char because int might match the return type of a GCC
7889    builtin and then its argument prototype would still apply.  */
7890 #ifdef __cplusplus
7891 extern "C"
7892 #endif
7893 char crypt ();
7894 int
7895 main ()
7896 {
7897 return crypt ();
7898   ;
7899   return 0;
7900 }
7901 _ACEOF
7902 for ac_lib in '' crypt; do
7903   if test -z "$ac_lib"; then
7904     ac_res="none required"
7905   else
7906     ac_res=-l$ac_lib
7907     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7908   fi
7909   rm -f conftest.$ac_objext conftest$ac_exeext
7910 if { (ac_try="$ac_link"
7911 case "(($ac_try" in
7912   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7913   *) ac_try_echo=$ac_try;;
7914 esac
7915 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7916 $as_echo "$ac_try_echo") >&5
7917   (eval "$ac_link") 2>conftest.er1
7918   ac_status=$?
7919   grep -v '^ *+' conftest.er1 >conftest.err
7920   rm -f conftest.er1
7921   cat conftest.err >&5
7922   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7923   (exit $ac_status); } && {
7924          test -z "$ac_c_werror_flag" ||
7925          test ! -s conftest.err
7926        } && test -s conftest$ac_exeext && {
7927          test "$cross_compiling" = yes ||
7928          $as_test_x conftest$ac_exeext
7929        }; then
7930   ac_cv_search_crypt=$ac_res
7931 else
7932   $as_echo "$as_me: failed program was:" >&5
7933 sed 's/^/| /' conftest.$ac_ext >&5
7934
7935
7936 fi
7937
7938 rm -rf conftest.dSYM
7939 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7940       conftest$ac_exeext
7941   if test "${ac_cv_search_crypt+set}" = set; then
7942   break
7943 fi
7944 done
7945 if test "${ac_cv_search_crypt+set}" = set; then
7946   :
7947 else
7948   ac_cv_search_crypt=no
7949 fi
7950 rm conftest.$ac_ext
7951 LIBS=$ac_func_search_save_LIBS
7952 fi
7953 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
7954 $as_echo "$ac_cv_search_crypt" >&6; }
7955 ac_res=$ac_cv_search_crypt
7956 if test "$ac_res" != no; then
7957   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7958
7959 fi
7960
7961 # Solaris:
7962 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
7963 $as_echo_n "checking for library containing fdatasync... " >&6; }
7964 if test "${ac_cv_search_fdatasync+set}" = set; then
7965   $as_echo_n "(cached) " >&6
7966 else
7967   ac_func_search_save_LIBS=$LIBS
7968 cat >conftest.$ac_ext <<_ACEOF
7969 /* confdefs.h.  */
7970 _ACEOF
7971 cat confdefs.h >>conftest.$ac_ext
7972 cat >>conftest.$ac_ext <<_ACEOF
7973 /* end confdefs.h.  */
7974
7975 /* Override any GCC internal prototype to avoid an error.
7976    Use char because int might match the return type of a GCC
7977    builtin and then its argument prototype would still apply.  */
7978 #ifdef __cplusplus
7979 extern "C"
7980 #endif
7981 char fdatasync ();
7982 int
7983 main ()
7984 {
7985 return fdatasync ();
7986   ;
7987   return 0;
7988 }
7989 _ACEOF
7990 for ac_lib in '' rt posix4; do
7991   if test -z "$ac_lib"; then
7992     ac_res="none required"
7993   else
7994     ac_res=-l$ac_lib
7995     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7996   fi
7997   rm -f conftest.$ac_objext conftest$ac_exeext
7998 if { (ac_try="$ac_link"
7999 case "(($ac_try" in
8000   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8001   *) ac_try_echo=$ac_try;;
8002 esac
8003 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8004 $as_echo "$ac_try_echo") >&5
8005   (eval "$ac_link") 2>conftest.er1
8006   ac_status=$?
8007   grep -v '^ *+' conftest.er1 >conftest.err
8008   rm -f conftest.er1
8009   cat conftest.err >&5
8010   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8011   (exit $ac_status); } && {
8012          test -z "$ac_c_werror_flag" ||
8013          test ! -s conftest.err
8014        } && test -s conftest$ac_exeext && {
8015          test "$cross_compiling" = yes ||
8016          $as_test_x conftest$ac_exeext
8017        }; then
8018   ac_cv_search_fdatasync=$ac_res
8019 else
8020   $as_echo "$as_me: failed program was:" >&5
8021 sed 's/^/| /' conftest.$ac_ext >&5
8022
8023
8024 fi
8025
8026 rm -rf conftest.dSYM
8027 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8028       conftest$ac_exeext
8029   if test "${ac_cv_search_fdatasync+set}" = set; then
8030   break
8031 fi
8032 done
8033 if test "${ac_cv_search_fdatasync+set}" = set; then
8034   :
8035 else
8036   ac_cv_search_fdatasync=no
8037 fi
8038 rm conftest.$ac_ext
8039 LIBS=$ac_func_search_save_LIBS
8040 fi
8041 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
8042 $as_echo "$ac_cv_search_fdatasync" >&6; }
8043 ac_res=$ac_cv_search_fdatasync
8044 if test "$ac_res" != no; then
8045   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8046
8047 fi
8048
8049 # Required for thread_test.c on Solaris 2.5:
8050 # Other ports use it too (HP-UX) so test unconditionally
8051 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
8052 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
8053 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8054   $as_echo_n "(cached) " >&6
8055 else
8056   ac_func_search_save_LIBS=$LIBS
8057 cat >conftest.$ac_ext <<_ACEOF
8058 /* confdefs.h.  */
8059 _ACEOF
8060 cat confdefs.h >>conftest.$ac_ext
8061 cat >>conftest.$ac_ext <<_ACEOF
8062 /* end confdefs.h.  */
8063
8064 /* Override any GCC internal prototype to avoid an error.
8065    Use char because int might match the return type of a GCC
8066    builtin and then its argument prototype would still apply.  */
8067 #ifdef __cplusplus
8068 extern "C"
8069 #endif
8070 char gethostbyname_r ();
8071 int
8072 main ()
8073 {
8074 return gethostbyname_r ();
8075   ;
8076   return 0;
8077 }
8078 _ACEOF
8079 for ac_lib in '' nsl; do
8080   if test -z "$ac_lib"; then
8081     ac_res="none required"
8082   else
8083     ac_res=-l$ac_lib
8084     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8085   fi
8086   rm -f conftest.$ac_objext conftest$ac_exeext
8087 if { (ac_try="$ac_link"
8088 case "(($ac_try" in
8089   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8090   *) ac_try_echo=$ac_try;;
8091 esac
8092 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8093 $as_echo "$ac_try_echo") >&5
8094   (eval "$ac_link") 2>conftest.er1
8095   ac_status=$?
8096   grep -v '^ *+' conftest.er1 >conftest.err
8097   rm -f conftest.er1
8098   cat conftest.err >&5
8099   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8100   (exit $ac_status); } && {
8101          test -z "$ac_c_werror_flag" ||
8102          test ! -s conftest.err
8103        } && test -s conftest$ac_exeext && {
8104          test "$cross_compiling" = yes ||
8105          $as_test_x conftest$ac_exeext
8106        }; then
8107   ac_cv_search_gethostbyname_r=$ac_res
8108 else
8109   $as_echo "$as_me: failed program was:" >&5
8110 sed 's/^/| /' conftest.$ac_ext >&5
8111
8112
8113 fi
8114
8115 rm -rf conftest.dSYM
8116 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8117       conftest$ac_exeext
8118   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8119   break
8120 fi
8121 done
8122 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8123   :
8124 else
8125   ac_cv_search_gethostbyname_r=no
8126 fi
8127 rm conftest.$ac_ext
8128 LIBS=$ac_func_search_save_LIBS
8129 fi
8130 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
8131 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
8132 ac_res=$ac_cv_search_gethostbyname_r
8133 if test "$ac_res" != no; then
8134   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8135
8136 fi
8137
8138 # Cygwin:
8139 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
8140 $as_echo_n "checking for library containing shmget... " >&6; }
8141 if test "${ac_cv_search_shmget+set}" = set; then
8142   $as_echo_n "(cached) " >&6
8143 else
8144   ac_func_search_save_LIBS=$LIBS
8145 cat >conftest.$ac_ext <<_ACEOF
8146 /* confdefs.h.  */
8147 _ACEOF
8148 cat confdefs.h >>conftest.$ac_ext
8149 cat >>conftest.$ac_ext <<_ACEOF
8150 /* end confdefs.h.  */
8151
8152 /* Override any GCC internal prototype to avoid an error.
8153    Use char because int might match the return type of a GCC
8154    builtin and then its argument prototype would still apply.  */
8155 #ifdef __cplusplus
8156 extern "C"
8157 #endif
8158 char shmget ();
8159 int
8160 main ()
8161 {
8162 return shmget ();
8163   ;
8164   return 0;
8165 }
8166 _ACEOF
8167 for ac_lib in '' cygipc; do
8168   if test -z "$ac_lib"; then
8169     ac_res="none required"
8170   else
8171     ac_res=-l$ac_lib
8172     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8173   fi
8174   rm -f conftest.$ac_objext conftest$ac_exeext
8175 if { (ac_try="$ac_link"
8176 case "(($ac_try" in
8177   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8178   *) ac_try_echo=$ac_try;;
8179 esac
8180 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8181 $as_echo "$ac_try_echo") >&5
8182   (eval "$ac_link") 2>conftest.er1
8183   ac_status=$?
8184   grep -v '^ *+' conftest.er1 >conftest.err
8185   rm -f conftest.er1
8186   cat conftest.err >&5
8187   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8188   (exit $ac_status); } && {
8189          test -z "$ac_c_werror_flag" ||
8190          test ! -s conftest.err
8191        } && test -s conftest$ac_exeext && {
8192          test "$cross_compiling" = yes ||
8193          $as_test_x conftest$ac_exeext
8194        }; then
8195   ac_cv_search_shmget=$ac_res
8196 else
8197   $as_echo "$as_me: failed program was:" >&5
8198 sed 's/^/| /' conftest.$ac_ext >&5
8199
8200
8201 fi
8202
8203 rm -rf conftest.dSYM
8204 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8205       conftest$ac_exeext
8206   if test "${ac_cv_search_shmget+set}" = set; then
8207   break
8208 fi
8209 done
8210 if test "${ac_cv_search_shmget+set}" = set; then
8211   :
8212 else
8213   ac_cv_search_shmget=no
8214 fi
8215 rm conftest.$ac_ext
8216 LIBS=$ac_func_search_save_LIBS
8217 fi
8218 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8219 $as_echo "$ac_cv_search_shmget" >&6; }
8220 ac_res=$ac_cv_search_shmget
8221 if test "$ac_res" != no; then
8222   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8223
8224 fi
8225
8226
8227 if test "$with_readline" = yes; then
8228
8229
8230 { $as_echo "$as_me:$LINENO: checking for library containing readline" >&5
8231 $as_echo_n "checking for library containing readline... " >&6; }
8232 if test "${pgac_cv_check_readline+set}" = set; then
8233   $as_echo_n "(cached) " >&6
8234 else
8235   pgac_cv_check_readline=no
8236 pgac_save_LIBS=$LIBS
8237 if test x"$with_libedit_preferred" != x"yes"
8238 then    READLINE_ORDER="-lreadline -ledit"
8239 else    READLINE_ORDER="-ledit -lreadline"
8240 fi
8241 for pgac_rllib in $READLINE_ORDER ; do
8242   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8243     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8244     cat >conftest.$ac_ext <<_ACEOF
8245 /* confdefs.h.  */
8246 _ACEOF
8247 cat confdefs.h >>conftest.$ac_ext
8248 cat >>conftest.$ac_ext <<_ACEOF
8249 /* end confdefs.h.  */
8250
8251 /* Override any GCC internal prototype to avoid an error.
8252    Use char because int might match the return type of a GCC
8253    builtin and then its argument prototype would still apply.  */
8254 #ifdef __cplusplus
8255 extern "C"
8256 #endif
8257 char readline ();
8258 int
8259 main ()
8260 {
8261 return readline ();
8262   ;
8263   return 0;
8264 }
8265 _ACEOF
8266 rm -f conftest.$ac_objext conftest$ac_exeext
8267 if { (ac_try="$ac_link"
8268 case "(($ac_try" in
8269   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8270   *) ac_try_echo=$ac_try;;
8271 esac
8272 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8273 $as_echo "$ac_try_echo") >&5
8274   (eval "$ac_link") 2>conftest.er1
8275   ac_status=$?
8276   grep -v '^ *+' conftest.er1 >conftest.err
8277   rm -f conftest.er1
8278   cat conftest.err >&5
8279   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8280   (exit $ac_status); } && {
8281          test -z "$ac_c_werror_flag" ||
8282          test ! -s conftest.err
8283        } && test -s conftest$ac_exeext && {
8284          test "$cross_compiling" = yes ||
8285          $as_test_x conftest$ac_exeext
8286        }; then
8287
8288       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8289       # recognize dependent libraries; assume curses is needed if we didn't
8290       # find any dependency.
8291       case $host_os in
8292         netbsd* | openbsd* | irix*)
8293           if test x"$pgac_lib" = x"" ; then
8294             pgac_lib=" -lcurses"
8295           fi ;;
8296       esac
8297
8298       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8299       break
8300
8301 else
8302   $as_echo "$as_me: failed program was:" >&5
8303 sed 's/^/| /' conftest.$ac_ext >&5
8304
8305
8306 fi
8307
8308 rm -rf conftest.dSYM
8309 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8310       conftest$ac_exeext conftest.$ac_ext
8311   done
8312   if test "$pgac_cv_check_readline" != no ; then
8313     break
8314   fi
8315 done
8316 LIBS=$pgac_save_LIBS
8317
8318 fi
8319 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_readline" >&5
8320 $as_echo "$pgac_cv_check_readline" >&6; }
8321 if test "$pgac_cv_check_readline" != no ; then
8322   LIBS="$pgac_cv_check_readline $LIBS"
8323
8324 cat >>confdefs.h <<\_ACEOF
8325 #define HAVE_LIBREADLINE 1
8326 _ACEOF
8327
8328 fi
8329
8330
8331   if test x"$pgac_cv_check_readline" = x"no"; then
8332     { { $as_echo "$as_me:$LINENO: error: readline library not found
8333 If you have readline already installed, see config.log for details on the
8334 failure.  It is possible the compiler isn't looking in the proper directory.
8335 Use --without-readline to disable readline support." >&5
8336 $as_echo "$as_me: error: readline library not found
8337 If you have readline already installed, see config.log for details on the
8338 failure.  It is possible the compiler isn't looking in the proper directory.
8339 Use --without-readline to disable readline support." >&2;}
8340    { (exit 1); exit 1; }; }
8341   fi
8342 fi
8343
8344 if test "$with_zlib" = yes; then
8345
8346 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8347 $as_echo_n "checking for inflate in -lz... " >&6; }
8348 if test "${ac_cv_lib_z_inflate+set}" = set; then
8349   $as_echo_n "(cached) " >&6
8350 else
8351   ac_check_lib_save_LIBS=$LIBS
8352 LIBS="-lz  $LIBS"
8353 cat >conftest.$ac_ext <<_ACEOF
8354 /* confdefs.h.  */
8355 _ACEOF
8356 cat confdefs.h >>conftest.$ac_ext
8357 cat >>conftest.$ac_ext <<_ACEOF
8358 /* end confdefs.h.  */
8359
8360 /* Override any GCC internal prototype to avoid an error.
8361    Use char because int might match the return type of a GCC
8362    builtin and then its argument prototype would still apply.  */
8363 #ifdef __cplusplus
8364 extern "C"
8365 #endif
8366 char inflate ();
8367 int
8368 main ()
8369 {
8370 return inflate ();
8371   ;
8372   return 0;
8373 }
8374 _ACEOF
8375 rm -f conftest.$ac_objext conftest$ac_exeext
8376 if { (ac_try="$ac_link"
8377 case "(($ac_try" in
8378   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8379   *) ac_try_echo=$ac_try;;
8380 esac
8381 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8382 $as_echo "$ac_try_echo") >&5
8383   (eval "$ac_link") 2>conftest.er1
8384   ac_status=$?
8385   grep -v '^ *+' conftest.er1 >conftest.err
8386   rm -f conftest.er1
8387   cat conftest.err >&5
8388   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8389   (exit $ac_status); } && {
8390          test -z "$ac_c_werror_flag" ||
8391          test ! -s conftest.err
8392        } && test -s conftest$ac_exeext && {
8393          test "$cross_compiling" = yes ||
8394          $as_test_x conftest$ac_exeext
8395        }; then
8396   ac_cv_lib_z_inflate=yes
8397 else
8398   $as_echo "$as_me: failed program was:" >&5
8399 sed 's/^/| /' conftest.$ac_ext >&5
8400
8401         ac_cv_lib_z_inflate=no
8402 fi
8403
8404 rm -rf conftest.dSYM
8405 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8406       conftest$ac_exeext conftest.$ac_ext
8407 LIBS=$ac_check_lib_save_LIBS
8408 fi
8409 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
8410 $as_echo "$ac_cv_lib_z_inflate" >&6; }
8411 if test "x$ac_cv_lib_z_inflate" = x""yes; then
8412   cat >>confdefs.h <<_ACEOF
8413 #define HAVE_LIBZ 1
8414 _ACEOF
8415
8416   LIBS="-lz $LIBS"
8417
8418 else
8419   { { $as_echo "$as_me:$LINENO: error: zlib library not found
8420 If you have zlib already installed, see config.log for details on the
8421 failure.  It is possible the compiler isn't looking in the proper directory.
8422 Use --without-zlib to disable zlib support." >&5
8423 $as_echo "$as_me: error: zlib library not found
8424 If you have zlib already installed, see config.log for details on the
8425 failure.  It is possible the compiler isn't looking in the proper directory.
8426 Use --without-zlib to disable zlib support." >&2;}
8427    { (exit 1); exit 1; }; }
8428 fi
8429
8430 fi
8431
8432 if test "$enable_spinlocks" = yes; then
8433
8434 cat >>confdefs.h <<\_ACEOF
8435 #define HAVE_SPINLOCKS 1
8436 _ACEOF
8437
8438 else
8439   { $as_echo "$as_me:$LINENO: WARNING:
8440 *** Not using spinlocks will cause poor performance." >&5
8441 $as_echo "$as_me: WARNING:
8442 *** Not using spinlocks will cause poor performance." >&2;}
8443 fi
8444
8445 if test "$with_gssapi" = yes ; then
8446   if test "$PORTNAME" != "win32"; then
8447     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
8448 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
8449 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8450   $as_echo_n "(cached) " >&6
8451 else
8452   ac_func_search_save_LIBS=$LIBS
8453 cat >conftest.$ac_ext <<_ACEOF
8454 /* confdefs.h.  */
8455 _ACEOF
8456 cat confdefs.h >>conftest.$ac_ext
8457 cat >>conftest.$ac_ext <<_ACEOF
8458 /* end confdefs.h.  */
8459
8460 /* Override any GCC internal prototype to avoid an error.
8461    Use char because int might match the return type of a GCC
8462    builtin and then its argument prototype would still apply.  */
8463 #ifdef __cplusplus
8464 extern "C"
8465 #endif
8466 char gss_init_sec_context ();
8467 int
8468 main ()
8469 {
8470 return gss_init_sec_context ();
8471   ;
8472   return 0;
8473 }
8474 _ACEOF
8475 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
8476   if test -z "$ac_lib"; then
8477     ac_res="none required"
8478   else
8479     ac_res=-l$ac_lib
8480     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8481   fi
8482   rm -f conftest.$ac_objext conftest$ac_exeext
8483 if { (ac_try="$ac_link"
8484 case "(($ac_try" in
8485   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8486   *) ac_try_echo=$ac_try;;
8487 esac
8488 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8489 $as_echo "$ac_try_echo") >&5
8490   (eval "$ac_link") 2>conftest.er1
8491   ac_status=$?
8492   grep -v '^ *+' conftest.er1 >conftest.err
8493   rm -f conftest.er1
8494   cat conftest.err >&5
8495   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8496   (exit $ac_status); } && {
8497          test -z "$ac_c_werror_flag" ||
8498          test ! -s conftest.err
8499        } && test -s conftest$ac_exeext && {
8500          test "$cross_compiling" = yes ||
8501          $as_test_x conftest$ac_exeext
8502        }; then
8503   ac_cv_search_gss_init_sec_context=$ac_res
8504 else
8505   $as_echo "$as_me: failed program was:" >&5
8506 sed 's/^/| /' conftest.$ac_ext >&5
8507
8508
8509 fi
8510
8511 rm -rf conftest.dSYM
8512 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8513       conftest$ac_exeext
8514   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8515   break
8516 fi
8517 done
8518 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8519   :
8520 else
8521   ac_cv_search_gss_init_sec_context=no
8522 fi
8523 rm conftest.$ac_ext
8524 LIBS=$ac_func_search_save_LIBS
8525 fi
8526 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
8527 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
8528 ac_res=$ac_cv_search_gss_init_sec_context
8529 if test "$ac_res" != no; then
8530   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8531
8532 else
8533   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
8534 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
8535    { (exit 1); exit 1; }; }
8536 fi
8537
8538   else
8539     LIBS="$LIBS -lgssapi32"
8540   fi
8541 fi
8542
8543 if test "$with_krb5" = yes ; then
8544   if test "$PORTNAME" != "win32"; then
8545      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8546 $as_echo_n "checking for library containing com_err... " >&6; }
8547 if test "${ac_cv_search_com_err+set}" = set; then
8548   $as_echo_n "(cached) " >&6
8549 else
8550   ac_func_search_save_LIBS=$LIBS
8551 cat >conftest.$ac_ext <<_ACEOF
8552 /* confdefs.h.  */
8553 _ACEOF
8554 cat confdefs.h >>conftest.$ac_ext
8555 cat >>conftest.$ac_ext <<_ACEOF
8556 /* end confdefs.h.  */
8557
8558 /* Override any GCC internal prototype to avoid an error.
8559    Use char because int might match the return type of a GCC
8560    builtin and then its argument prototype would still apply.  */
8561 #ifdef __cplusplus
8562 extern "C"
8563 #endif
8564 char com_err ();
8565 int
8566 main ()
8567 {
8568 return com_err ();
8569   ;
8570   return 0;
8571 }
8572 _ACEOF
8573 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
8574   if test -z "$ac_lib"; then
8575     ac_res="none required"
8576   else
8577     ac_res=-l$ac_lib
8578     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8579   fi
8580   rm -f conftest.$ac_objext conftest$ac_exeext
8581 if { (ac_try="$ac_link"
8582 case "(($ac_try" in
8583   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8584   *) ac_try_echo=$ac_try;;
8585 esac
8586 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8587 $as_echo "$ac_try_echo") >&5
8588   (eval "$ac_link") 2>conftest.er1
8589   ac_status=$?
8590   grep -v '^ *+' conftest.er1 >conftest.err
8591   rm -f conftest.er1
8592   cat conftest.err >&5
8593   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8594   (exit $ac_status); } && {
8595          test -z "$ac_c_werror_flag" ||
8596          test ! -s conftest.err
8597        } && test -s conftest$ac_exeext && {
8598          test "$cross_compiling" = yes ||
8599          $as_test_x conftest$ac_exeext
8600        }; then
8601   ac_cv_search_com_err=$ac_res
8602 else
8603   $as_echo "$as_me: failed program was:" >&5
8604 sed 's/^/| /' conftest.$ac_ext >&5
8605
8606
8607 fi
8608
8609 rm -rf conftest.dSYM
8610 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8611       conftest$ac_exeext
8612   if test "${ac_cv_search_com_err+set}" = set; then
8613   break
8614 fi
8615 done
8616 if test "${ac_cv_search_com_err+set}" = set; then
8617   :
8618 else
8619   ac_cv_search_com_err=no
8620 fi
8621 rm conftest.$ac_ext
8622 LIBS=$ac_func_search_save_LIBS
8623 fi
8624 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8625 $as_echo "$ac_cv_search_com_err" >&6; }
8626 ac_res=$ac_cv_search_com_err
8627 if test "$ac_res" != no; then
8628   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8629
8630 else
8631   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8632 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8633    { (exit 1); exit 1; }; }
8634 fi
8635
8636      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
8637 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
8638 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8639   $as_echo_n "(cached) " >&6
8640 else
8641   ac_func_search_save_LIBS=$LIBS
8642 cat >conftest.$ac_ext <<_ACEOF
8643 /* confdefs.h.  */
8644 _ACEOF
8645 cat confdefs.h >>conftest.$ac_ext
8646 cat >>conftest.$ac_ext <<_ACEOF
8647 /* end confdefs.h.  */
8648
8649 /* Override any GCC internal prototype to avoid an error.
8650    Use char because int might match the return type of a GCC
8651    builtin and then its argument prototype would still apply.  */
8652 #ifdef __cplusplus
8653 extern "C"
8654 #endif
8655 char krb5_sendauth ();
8656 int
8657 main ()
8658 {
8659 return krb5_sendauth ();
8660   ;
8661   return 0;
8662 }
8663 _ACEOF
8664 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
8665   if test -z "$ac_lib"; then
8666     ac_res="none required"
8667   else
8668     ac_res=-l$ac_lib
8669     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8670   fi
8671   rm -f conftest.$ac_objext conftest$ac_exeext
8672 if { (ac_try="$ac_link"
8673 case "(($ac_try" in
8674   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8675   *) ac_try_echo=$ac_try;;
8676 esac
8677 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8678 $as_echo "$ac_try_echo") >&5
8679   (eval "$ac_link") 2>conftest.er1
8680   ac_status=$?
8681   grep -v '^ *+' conftest.er1 >conftest.err
8682   rm -f conftest.er1
8683   cat conftest.err >&5
8684   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8685   (exit $ac_status); } && {
8686          test -z "$ac_c_werror_flag" ||
8687          test ! -s conftest.err
8688        } && test -s conftest$ac_exeext && {
8689          test "$cross_compiling" = yes ||
8690          $as_test_x conftest$ac_exeext
8691        }; then
8692   ac_cv_search_krb5_sendauth=$ac_res
8693 else
8694   $as_echo "$as_me: failed program was:" >&5
8695 sed 's/^/| /' conftest.$ac_ext >&5
8696
8697
8698 fi
8699
8700 rm -rf conftest.dSYM
8701 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8702       conftest$ac_exeext
8703   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8704   break
8705 fi
8706 done
8707 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8708   :
8709 else
8710   ac_cv_search_krb5_sendauth=no
8711 fi
8712 rm conftest.$ac_ext
8713 LIBS=$ac_func_search_save_LIBS
8714 fi
8715 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
8716 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
8717 ac_res=$ac_cv_search_krb5_sendauth
8718 if test "$ac_res" != no; then
8719   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8720
8721 else
8722   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
8723 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
8724    { (exit 1); exit 1; }; }
8725 fi
8726
8727   else
8728      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8729 $as_echo_n "checking for library containing com_err... " >&6; }
8730 if test "${ac_cv_search_com_err+set}" = set; then
8731   $as_echo_n "(cached) " >&6
8732 else
8733   ac_func_search_save_LIBS=$LIBS
8734 cat >conftest.$ac_ext <<_ACEOF
8735 /* confdefs.h.  */
8736 _ACEOF
8737 cat confdefs.h >>conftest.$ac_ext
8738 cat >>conftest.$ac_ext <<_ACEOF
8739 /* end confdefs.h.  */
8740
8741 /* Override any GCC internal prototype to avoid an error.
8742    Use char because int might match the return type of a GCC
8743    builtin and then its argument prototype would still apply.  */
8744 #ifdef __cplusplus
8745 extern "C"
8746 #endif
8747 char com_err ();
8748 int
8749 main ()
8750 {
8751 return com_err ();
8752   ;
8753   return 0;
8754 }
8755 _ACEOF
8756 for ac_lib in '' 'comerr32 -lkrb5_32'; do
8757   if test -z "$ac_lib"; then
8758     ac_res="none required"
8759   else
8760     ac_res=-l$ac_lib
8761     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8762   fi
8763   rm -f conftest.$ac_objext conftest$ac_exeext
8764 if { (ac_try="$ac_link"
8765 case "(($ac_try" in
8766   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8767   *) ac_try_echo=$ac_try;;
8768 esac
8769 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8770 $as_echo "$ac_try_echo") >&5
8771   (eval "$ac_link") 2>conftest.er1
8772   ac_status=$?
8773   grep -v '^ *+' conftest.er1 >conftest.err
8774   rm -f conftest.er1
8775   cat conftest.err >&5
8776   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8777   (exit $ac_status); } && {
8778          test -z "$ac_c_werror_flag" ||
8779          test ! -s conftest.err
8780        } && test -s conftest$ac_exeext && {
8781          test "$cross_compiling" = yes ||
8782          $as_test_x conftest$ac_exeext
8783        }; then
8784   ac_cv_search_com_err=$ac_res
8785 else
8786   $as_echo "$as_me: failed program was:" >&5
8787 sed 's/^/| /' conftest.$ac_ext >&5
8788
8789
8790 fi
8791
8792 rm -rf conftest.dSYM
8793 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8794       conftest$ac_exeext
8795   if test "${ac_cv_search_com_err+set}" = set; then
8796   break
8797 fi
8798 done
8799 if test "${ac_cv_search_com_err+set}" = set; then
8800   :
8801 else
8802   ac_cv_search_com_err=no
8803 fi
8804 rm conftest.$ac_ext
8805 LIBS=$ac_func_search_save_LIBS
8806 fi
8807 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8808 $as_echo "$ac_cv_search_com_err" >&6; }
8809 ac_res=$ac_cv_search_com_err
8810 if test "$ac_res" != no; then
8811   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8812
8813 else
8814   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8815 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8816    { (exit 1); exit 1; }; }
8817 fi
8818
8819   fi
8820 fi
8821
8822 if test "$with_openssl" = yes ; then
8823     if test "$PORTNAME" != "win32"; then
8824
8825 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
8826 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
8827 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
8828   $as_echo_n "(cached) " >&6
8829 else
8830   ac_check_lib_save_LIBS=$LIBS
8831 LIBS="-lcrypto  $LIBS"
8832 cat >conftest.$ac_ext <<_ACEOF
8833 /* confdefs.h.  */
8834 _ACEOF
8835 cat confdefs.h >>conftest.$ac_ext
8836 cat >>conftest.$ac_ext <<_ACEOF
8837 /* end confdefs.h.  */
8838
8839 /* Override any GCC internal prototype to avoid an error.
8840    Use char because int might match the return type of a GCC
8841    builtin and then its argument prototype would still apply.  */
8842 #ifdef __cplusplus
8843 extern "C"
8844 #endif
8845 char CRYPTO_new_ex_data ();
8846 int
8847 main ()
8848 {
8849 return CRYPTO_new_ex_data ();
8850   ;
8851   return 0;
8852 }
8853 _ACEOF
8854 rm -f conftest.$ac_objext conftest$ac_exeext
8855 if { (ac_try="$ac_link"
8856 case "(($ac_try" in
8857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8858   *) ac_try_echo=$ac_try;;
8859 esac
8860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8861 $as_echo "$ac_try_echo") >&5
8862   (eval "$ac_link") 2>conftest.er1
8863   ac_status=$?
8864   grep -v '^ *+' conftest.er1 >conftest.err
8865   rm -f conftest.er1
8866   cat conftest.err >&5
8867   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8868   (exit $ac_status); } && {
8869          test -z "$ac_c_werror_flag" ||
8870          test ! -s conftest.err
8871        } && test -s conftest$ac_exeext && {
8872          test "$cross_compiling" = yes ||
8873          $as_test_x conftest$ac_exeext
8874        }; then
8875   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
8876 else
8877   $as_echo "$as_me: failed program was:" >&5
8878 sed 's/^/| /' conftest.$ac_ext >&5
8879
8880         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
8881 fi
8882
8883 rm -rf conftest.dSYM
8884 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8885       conftest$ac_exeext conftest.$ac_ext
8886 LIBS=$ac_check_lib_save_LIBS
8887 fi
8888 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
8889 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
8890 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
8891   cat >>confdefs.h <<_ACEOF
8892 #define HAVE_LIBCRYPTO 1
8893 _ACEOF
8894
8895   LIBS="-lcrypto $LIBS"
8896
8897 else
8898   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
8899 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
8900    { (exit 1); exit 1; }; }
8901 fi
8902
8903
8904 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
8905 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
8906 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
8907   $as_echo_n "(cached) " >&6
8908 else
8909   ac_check_lib_save_LIBS=$LIBS
8910 LIBS="-lssl  $LIBS"
8911 cat >conftest.$ac_ext <<_ACEOF
8912 /* confdefs.h.  */
8913 _ACEOF
8914 cat confdefs.h >>conftest.$ac_ext
8915 cat >>conftest.$ac_ext <<_ACEOF
8916 /* end confdefs.h.  */
8917
8918 /* Override any GCC internal prototype to avoid an error.
8919    Use char because int might match the return type of a GCC
8920    builtin and then its argument prototype would still apply.  */
8921 #ifdef __cplusplus
8922 extern "C"
8923 #endif
8924 char SSL_library_init ();
8925 int
8926 main ()
8927 {
8928 return SSL_library_init ();
8929   ;
8930   return 0;
8931 }
8932 _ACEOF
8933 rm -f conftest.$ac_objext conftest$ac_exeext
8934 if { (ac_try="$ac_link"
8935 case "(($ac_try" in
8936   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8937   *) ac_try_echo=$ac_try;;
8938 esac
8939 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8940 $as_echo "$ac_try_echo") >&5
8941   (eval "$ac_link") 2>conftest.er1
8942   ac_status=$?
8943   grep -v '^ *+' conftest.er1 >conftest.err
8944   rm -f conftest.er1
8945   cat conftest.err >&5
8946   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8947   (exit $ac_status); } && {
8948          test -z "$ac_c_werror_flag" ||
8949          test ! -s conftest.err
8950        } && test -s conftest$ac_exeext && {
8951          test "$cross_compiling" = yes ||
8952          $as_test_x conftest$ac_exeext
8953        }; then
8954   ac_cv_lib_ssl_SSL_library_init=yes
8955 else
8956   $as_echo "$as_me: failed program was:" >&5
8957 sed 's/^/| /' conftest.$ac_ext >&5
8958
8959         ac_cv_lib_ssl_SSL_library_init=no
8960 fi
8961
8962 rm -rf conftest.dSYM
8963 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8964       conftest$ac_exeext conftest.$ac_ext
8965 LIBS=$ac_check_lib_save_LIBS
8966 fi
8967 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
8968 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
8969 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
8970   cat >>confdefs.h <<_ACEOF
8971 #define HAVE_LIBSSL 1
8972 _ACEOF
8973
8974   LIBS="-lssl $LIBS"
8975
8976 else
8977   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
8978 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
8979    { (exit 1); exit 1; }; }
8980 fi
8981
8982   else
8983
8984 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
8985 $as_echo_n "checking for CRYPTO_new_ex_data in -leay32... " >&6; }
8986 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
8987   $as_echo_n "(cached) " >&6
8988 else
8989   ac_check_lib_save_LIBS=$LIBS
8990 LIBS="-leay32  $LIBS"
8991 cat >conftest.$ac_ext <<_ACEOF
8992 /* confdefs.h.  */
8993 _ACEOF
8994 cat confdefs.h >>conftest.$ac_ext
8995 cat >>conftest.$ac_ext <<_ACEOF
8996 /* end confdefs.h.  */
8997
8998 /* Override any GCC internal prototype to avoid an error.
8999    Use char because int might match the return type of a GCC
9000    builtin and then its argument prototype would still apply.  */
9001 #ifdef __cplusplus
9002 extern "C"
9003 #endif
9004 char CRYPTO_new_ex_data ();
9005 int
9006 main ()
9007 {
9008 return CRYPTO_new_ex_data ();
9009   ;
9010   return 0;
9011 }
9012 _ACEOF
9013 rm -f conftest.$ac_objext conftest$ac_exeext
9014 if { (ac_try="$ac_link"
9015 case "(($ac_try" in
9016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9017   *) ac_try_echo=$ac_try;;
9018 esac
9019 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9020 $as_echo "$ac_try_echo") >&5
9021   (eval "$ac_link") 2>conftest.er1
9022   ac_status=$?
9023   grep -v '^ *+' conftest.er1 >conftest.err
9024   rm -f conftest.er1
9025   cat conftest.err >&5
9026   $as_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_exeext && {
9031          test "$cross_compiling" = yes ||
9032          $as_test_x conftest$ac_exeext
9033        }; then
9034   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
9035 else
9036   $as_echo "$as_me: failed program was:" >&5
9037 sed 's/^/| /' conftest.$ac_ext >&5
9038
9039         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
9040 fi
9041
9042 rm -rf conftest.dSYM
9043 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9044       conftest$ac_exeext conftest.$ac_ext
9045 LIBS=$ac_check_lib_save_LIBS
9046 fi
9047 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
9048 $as_echo "$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
9049 if test "x$ac_cv_lib_eay32_CRYPTO_new_ex_data" = x""yes; then
9050   cat >>confdefs.h <<_ACEOF
9051 #define HAVE_LIBEAY32 1
9052 _ACEOF
9053
9054   LIBS="-leay32 $LIBS"
9055
9056 else
9057   { { $as_echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
9058 $as_echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
9059    { (exit 1); exit 1; }; }
9060 fi
9061
9062
9063 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
9064 $as_echo_n "checking for SSL_library_init in -lssleay32... " >&6; }
9065 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
9066   $as_echo_n "(cached) " >&6
9067 else
9068   ac_check_lib_save_LIBS=$LIBS
9069 LIBS="-lssleay32  $LIBS"
9070 cat >conftest.$ac_ext <<_ACEOF
9071 /* confdefs.h.  */
9072 _ACEOF
9073 cat confdefs.h >>conftest.$ac_ext
9074 cat >>conftest.$ac_ext <<_ACEOF
9075 /* end confdefs.h.  */
9076
9077 /* Override any GCC internal prototype to avoid an error.
9078    Use char because int might match the return type of a GCC
9079    builtin and then its argument prototype would still apply.  */
9080 #ifdef __cplusplus
9081 extern "C"
9082 #endif
9083 char SSL_library_init ();
9084 int
9085 main ()
9086 {
9087 return SSL_library_init ();
9088   ;
9089   return 0;
9090 }
9091 _ACEOF
9092 rm -f conftest.$ac_objext conftest$ac_exeext
9093 if { (ac_try="$ac_link"
9094 case "(($ac_try" in
9095   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9096   *) ac_try_echo=$ac_try;;
9097 esac
9098 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9099 $as_echo "$ac_try_echo") >&5
9100   (eval "$ac_link") 2>conftest.er1
9101   ac_status=$?
9102   grep -v '^ *+' conftest.er1 >conftest.err
9103   rm -f conftest.er1
9104   cat conftest.err >&5
9105   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9106   (exit $ac_status); } && {
9107          test -z "$ac_c_werror_flag" ||
9108          test ! -s conftest.err
9109        } && test -s conftest$ac_exeext && {
9110          test "$cross_compiling" = yes ||
9111          $as_test_x conftest$ac_exeext
9112        }; then
9113   ac_cv_lib_ssleay32_SSL_library_init=yes
9114 else
9115   $as_echo "$as_me: failed program was:" >&5
9116 sed 's/^/| /' conftest.$ac_ext >&5
9117
9118         ac_cv_lib_ssleay32_SSL_library_init=no
9119 fi
9120
9121 rm -rf conftest.dSYM
9122 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9123       conftest$ac_exeext conftest.$ac_ext
9124 LIBS=$ac_check_lib_save_LIBS
9125 fi
9126 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
9127 $as_echo "$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
9128 if test "x$ac_cv_lib_ssleay32_SSL_library_init" = x""yes; then
9129   cat >>confdefs.h <<_ACEOF
9130 #define HAVE_LIBSSLEAY32 1
9131 _ACEOF
9132
9133   LIBS="-lssleay32 $LIBS"
9134
9135 else
9136   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
9137 $as_echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
9138    { (exit 1); exit 1; }; }
9139 fi
9140
9141   fi
9142 fi
9143
9144 if test "$with_pam" = yes ; then
9145
9146 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
9147 $as_echo_n "checking for pam_start in -lpam... " >&6; }
9148 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
9149   $as_echo_n "(cached) " >&6
9150 else
9151   ac_check_lib_save_LIBS=$LIBS
9152 LIBS="-lpam  $LIBS"
9153 cat >conftest.$ac_ext <<_ACEOF
9154 /* confdefs.h.  */
9155 _ACEOF
9156 cat confdefs.h >>conftest.$ac_ext
9157 cat >>conftest.$ac_ext <<_ACEOF
9158 /* end confdefs.h.  */
9159
9160 /* Override any GCC internal prototype to avoid an error.
9161    Use char because int might match the return type of a GCC
9162    builtin and then its argument prototype would still apply.  */
9163 #ifdef __cplusplus
9164 extern "C"
9165 #endif
9166 char pam_start ();
9167 int
9168 main ()
9169 {
9170 return pam_start ();
9171   ;
9172   return 0;
9173 }
9174 _ACEOF
9175 rm -f conftest.$ac_objext conftest$ac_exeext
9176 if { (ac_try="$ac_link"
9177 case "(($ac_try" in
9178   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9179   *) ac_try_echo=$ac_try;;
9180 esac
9181 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9182 $as_echo "$ac_try_echo") >&5
9183   (eval "$ac_link") 2>conftest.er1
9184   ac_status=$?
9185   grep -v '^ *+' conftest.er1 >conftest.err
9186   rm -f conftest.er1
9187   cat conftest.err >&5
9188   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9189   (exit $ac_status); } && {
9190          test -z "$ac_c_werror_flag" ||
9191          test ! -s conftest.err
9192        } && test -s conftest$ac_exeext && {
9193          test "$cross_compiling" = yes ||
9194          $as_test_x conftest$ac_exeext
9195        }; then
9196   ac_cv_lib_pam_pam_start=yes
9197 else
9198   $as_echo "$as_me: failed program was:" >&5
9199 sed 's/^/| /' conftest.$ac_ext >&5
9200
9201         ac_cv_lib_pam_pam_start=no
9202 fi
9203
9204 rm -rf conftest.dSYM
9205 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9206       conftest$ac_exeext conftest.$ac_ext
9207 LIBS=$ac_check_lib_save_LIBS
9208 fi
9209 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9210 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9211 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9212   cat >>confdefs.h <<_ACEOF
9213 #define HAVE_LIBPAM 1
9214 _ACEOF
9215
9216   LIBS="-lpam $LIBS"
9217
9218 else
9219   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9220 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9221    { (exit 1); exit 1; }; }
9222 fi
9223
9224 fi
9225
9226 if test "$with_libxml" = yes ; then
9227
9228 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9229 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9230 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9231   $as_echo_n "(cached) " >&6
9232 else
9233   ac_check_lib_save_LIBS=$LIBS
9234 LIBS="-lxml2  $LIBS"
9235 cat >conftest.$ac_ext <<_ACEOF
9236 /* confdefs.h.  */
9237 _ACEOF
9238 cat confdefs.h >>conftest.$ac_ext
9239 cat >>conftest.$ac_ext <<_ACEOF
9240 /* end confdefs.h.  */
9241
9242 /* Override any GCC internal prototype to avoid an error.
9243    Use char because int might match the return type of a GCC
9244    builtin and then its argument prototype would still apply.  */
9245 #ifdef __cplusplus
9246 extern "C"
9247 #endif
9248 char xmlSaveToBuffer ();
9249 int
9250 main ()
9251 {
9252 return xmlSaveToBuffer ();
9253   ;
9254   return 0;
9255 }
9256 _ACEOF
9257 rm -f conftest.$ac_objext conftest$ac_exeext
9258 if { (ac_try="$ac_link"
9259 case "(($ac_try" in
9260   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9261   *) ac_try_echo=$ac_try;;
9262 esac
9263 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9264 $as_echo "$ac_try_echo") >&5
9265   (eval "$ac_link") 2>conftest.er1
9266   ac_status=$?
9267   grep -v '^ *+' conftest.er1 >conftest.err
9268   rm -f conftest.er1
9269   cat conftest.err >&5
9270   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9271   (exit $ac_status); } && {
9272          test -z "$ac_c_werror_flag" ||
9273          test ! -s conftest.err
9274        } && test -s conftest$ac_exeext && {
9275          test "$cross_compiling" = yes ||
9276          $as_test_x conftest$ac_exeext
9277        }; then
9278   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9279 else
9280   $as_echo "$as_me: failed program was:" >&5
9281 sed 's/^/| /' conftest.$ac_ext >&5
9282
9283         ac_cv_lib_xml2_xmlSaveToBuffer=no
9284 fi
9285
9286 rm -rf conftest.dSYM
9287 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9288       conftest$ac_exeext conftest.$ac_ext
9289 LIBS=$ac_check_lib_save_LIBS
9290 fi
9291 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9292 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9293 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9294   cat >>confdefs.h <<_ACEOF
9295 #define HAVE_LIBXML2 1
9296 _ACEOF
9297
9298   LIBS="-lxml2 $LIBS"
9299
9300 else
9301   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9302 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9303    { (exit 1); exit 1; }; }
9304 fi
9305
9306 fi
9307
9308 if test "$with_libxslt" = yes ; then
9309
9310 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9311 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9312 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9313   $as_echo_n "(cached) " >&6
9314 else
9315   ac_check_lib_save_LIBS=$LIBS
9316 LIBS="-lxslt  $LIBS"
9317 cat >conftest.$ac_ext <<_ACEOF
9318 /* confdefs.h.  */
9319 _ACEOF
9320 cat confdefs.h >>conftest.$ac_ext
9321 cat >>conftest.$ac_ext <<_ACEOF
9322 /* end confdefs.h.  */
9323
9324 /* Override any GCC internal prototype to avoid an error.
9325    Use char because int might match the return type of a GCC
9326    builtin and then its argument prototype would still apply.  */
9327 #ifdef __cplusplus
9328 extern "C"
9329 #endif
9330 char xsltCleanupGlobals ();
9331 int
9332 main ()
9333 {
9334 return xsltCleanupGlobals ();
9335   ;
9336   return 0;
9337 }
9338 _ACEOF
9339 rm -f conftest.$ac_objext conftest$ac_exeext
9340 if { (ac_try="$ac_link"
9341 case "(($ac_try" in
9342   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9343   *) ac_try_echo=$ac_try;;
9344 esac
9345 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9346 $as_echo "$ac_try_echo") >&5
9347   (eval "$ac_link") 2>conftest.er1
9348   ac_status=$?
9349   grep -v '^ *+' conftest.er1 >conftest.err
9350   rm -f conftest.er1
9351   cat conftest.err >&5
9352   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9353   (exit $ac_status); } && {
9354          test -z "$ac_c_werror_flag" ||
9355          test ! -s conftest.err
9356        } && test -s conftest$ac_exeext && {
9357          test "$cross_compiling" = yes ||
9358          $as_test_x conftest$ac_exeext
9359        }; then
9360   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9361 else
9362   $as_echo "$as_me: failed program was:" >&5
9363 sed 's/^/| /' conftest.$ac_ext >&5
9364
9365         ac_cv_lib_xslt_xsltCleanupGlobals=no
9366 fi
9367
9368 rm -rf conftest.dSYM
9369 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9370       conftest$ac_exeext conftest.$ac_ext
9371 LIBS=$ac_check_lib_save_LIBS
9372 fi
9373 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9374 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9375 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9376   cat >>confdefs.h <<_ACEOF
9377 #define HAVE_LIBXSLT 1
9378 _ACEOF
9379
9380   LIBS="-lxslt $LIBS"
9381
9382 else
9383   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
9384 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
9385    { (exit 1); exit 1; }; }
9386 fi
9387
9388 fi
9389
9390 # for contrib/sepgsql
9391 if test "$with_selinux" = yes; then
9392
9393 { $as_echo "$as_me:$LINENO: checking for getpeercon_raw in -lselinux" >&5
9394 $as_echo_n "checking for getpeercon_raw in -lselinux... " >&6; }
9395 if test "${ac_cv_lib_selinux_getpeercon_raw+set}" = set; then
9396   $as_echo_n "(cached) " >&6
9397 else
9398   ac_check_lib_save_LIBS=$LIBS
9399 LIBS="-lselinux  $LIBS"
9400 cat >conftest.$ac_ext <<_ACEOF
9401 /* confdefs.h.  */
9402 _ACEOF
9403 cat confdefs.h >>conftest.$ac_ext
9404 cat >>conftest.$ac_ext <<_ACEOF
9405 /* end confdefs.h.  */
9406
9407 /* Override any GCC internal prototype to avoid an error.
9408    Use char because int might match the return type of a GCC
9409    builtin and then its argument prototype would still apply.  */
9410 #ifdef __cplusplus
9411 extern "C"
9412 #endif
9413 char getpeercon_raw ();
9414 int
9415 main ()
9416 {
9417 return getpeercon_raw ();
9418   ;
9419   return 0;
9420 }
9421 _ACEOF
9422 rm -f conftest.$ac_objext conftest$ac_exeext
9423 if { (ac_try="$ac_link"
9424 case "(($ac_try" in
9425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9426   *) ac_try_echo=$ac_try;;
9427 esac
9428 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9429 $as_echo "$ac_try_echo") >&5
9430   (eval "$ac_link") 2>conftest.er1
9431   ac_status=$?
9432   grep -v '^ *+' conftest.er1 >conftest.err
9433   rm -f conftest.er1
9434   cat conftest.err >&5
9435   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9436   (exit $ac_status); } && {
9437          test -z "$ac_c_werror_flag" ||
9438          test ! -s conftest.err
9439        } && test -s conftest$ac_exeext && {
9440          test "$cross_compiling" = yes ||
9441          $as_test_x conftest$ac_exeext
9442        }; then
9443   ac_cv_lib_selinux_getpeercon_raw=yes
9444 else
9445   $as_echo "$as_me: failed program was:" >&5
9446 sed 's/^/| /' conftest.$ac_ext >&5
9447
9448         ac_cv_lib_selinux_getpeercon_raw=no
9449 fi
9450
9451 rm -rf conftest.dSYM
9452 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9453       conftest$ac_exeext conftest.$ac_ext
9454 LIBS=$ac_check_lib_save_LIBS
9455 fi
9456 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_getpeercon_raw" >&5
9457 $as_echo "$ac_cv_lib_selinux_getpeercon_raw" >&6; }
9458 if test "x$ac_cv_lib_selinux_getpeercon_raw" = x""yes; then
9459   cat >>confdefs.h <<_ACEOF
9460 #define HAVE_LIBSELINUX 1
9461 _ACEOF
9462
9463   LIBS="-lselinux $LIBS"
9464
9465 else
9466   { { $as_echo "$as_me:$LINENO: error: library 'libselinux' is required for SELinux support" >&5
9467 $as_echo "$as_me: error: library 'libselinux' is required for SELinux support" >&2;}
9468    { (exit 1); exit 1; }; }
9469 fi
9470
9471 fi
9472
9473 # for contrib/uuid-ossp
9474 if test "$with_ossp_uuid" = yes ; then
9475   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
9476 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
9477 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
9478   $as_echo_n "(cached) " >&6
9479 else
9480   ac_check_lib_save_LIBS=$LIBS
9481 LIBS="-lossp-uuid  $LIBS"
9482 cat >conftest.$ac_ext <<_ACEOF
9483 /* confdefs.h.  */
9484 _ACEOF
9485 cat confdefs.h >>conftest.$ac_ext
9486 cat >>conftest.$ac_ext <<_ACEOF
9487 /* end confdefs.h.  */
9488
9489 /* Override any GCC internal prototype to avoid an error.
9490    Use char because int might match the return type of a GCC
9491    builtin and then its argument prototype would still apply.  */
9492 #ifdef __cplusplus
9493 extern "C"
9494 #endif
9495 char uuid_export ();
9496 int
9497 main ()
9498 {
9499 return uuid_export ();
9500   ;
9501   return 0;
9502 }
9503 _ACEOF
9504 rm -f conftest.$ac_objext conftest$ac_exeext
9505 if { (ac_try="$ac_link"
9506 case "(($ac_try" in
9507   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9508   *) ac_try_echo=$ac_try;;
9509 esac
9510 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9511 $as_echo "$ac_try_echo") >&5
9512   (eval "$ac_link") 2>conftest.er1
9513   ac_status=$?
9514   grep -v '^ *+' conftest.er1 >conftest.err
9515   rm -f conftest.er1
9516   cat conftest.err >&5
9517   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9518   (exit $ac_status); } && {
9519          test -z "$ac_c_werror_flag" ||
9520          test ! -s conftest.err
9521        } && test -s conftest$ac_exeext && {
9522          test "$cross_compiling" = yes ||
9523          $as_test_x conftest$ac_exeext
9524        }; then
9525   ac_cv_lib_ossp_uuid_uuid_export=yes
9526 else
9527   $as_echo "$as_me: failed program was:" >&5
9528 sed 's/^/| /' conftest.$ac_ext >&5
9529
9530         ac_cv_lib_ossp_uuid_uuid_export=no
9531 fi
9532
9533 rm -rf conftest.dSYM
9534 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9535       conftest$ac_exeext conftest.$ac_ext
9536 LIBS=$ac_check_lib_save_LIBS
9537 fi
9538 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
9539 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
9540 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
9541   OSSP_UUID_LIBS="-lossp-uuid"
9542 else
9543   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
9544 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
9545 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
9546   $as_echo_n "(cached) " >&6
9547 else
9548   ac_check_lib_save_LIBS=$LIBS
9549 LIBS="-luuid  $LIBS"
9550 cat >conftest.$ac_ext <<_ACEOF
9551 /* confdefs.h.  */
9552 _ACEOF
9553 cat confdefs.h >>conftest.$ac_ext
9554 cat >>conftest.$ac_ext <<_ACEOF
9555 /* end confdefs.h.  */
9556
9557 /* Override any GCC internal prototype to avoid an error.
9558    Use char because int might match the return type of a GCC
9559    builtin and then its argument prototype would still apply.  */
9560 #ifdef __cplusplus
9561 extern "C"
9562 #endif
9563 char uuid_export ();
9564 int
9565 main ()
9566 {
9567 return uuid_export ();
9568   ;
9569   return 0;
9570 }
9571 _ACEOF
9572 rm -f conftest.$ac_objext conftest$ac_exeext
9573 if { (ac_try="$ac_link"
9574 case "(($ac_try" in
9575   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9576   *) ac_try_echo=$ac_try;;
9577 esac
9578 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9579 $as_echo "$ac_try_echo") >&5
9580   (eval "$ac_link") 2>conftest.er1
9581   ac_status=$?
9582   grep -v '^ *+' conftest.er1 >conftest.err
9583   rm -f conftest.er1
9584   cat conftest.err >&5
9585   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9586   (exit $ac_status); } && {
9587          test -z "$ac_c_werror_flag" ||
9588          test ! -s conftest.err
9589        } && test -s conftest$ac_exeext && {
9590          test "$cross_compiling" = yes ||
9591          $as_test_x conftest$ac_exeext
9592        }; then
9593   ac_cv_lib_uuid_uuid_export=yes
9594 else
9595   $as_echo "$as_me: failed program was:" >&5
9596 sed 's/^/| /' conftest.$ac_ext >&5
9597
9598         ac_cv_lib_uuid_uuid_export=no
9599 fi
9600
9601 rm -rf conftest.dSYM
9602 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9603       conftest$ac_exeext conftest.$ac_ext
9604 LIBS=$ac_check_lib_save_LIBS
9605 fi
9606 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
9607 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
9608 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
9609   OSSP_UUID_LIBS="-luuid"
9610 else
9611   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
9612 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
9613    { (exit 1); exit 1; }; }
9614 fi
9615
9616 fi
9617
9618 fi
9619
9620
9621
9622 ##
9623 ## Header files
9624 ##
9625
9626 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
9627 $as_echo_n "checking for ANSI C header files... " >&6; }
9628 if test "${ac_cv_header_stdc+set}" = set; then
9629   $as_echo_n "(cached) " >&6
9630 else
9631   cat >conftest.$ac_ext <<_ACEOF
9632 /* confdefs.h.  */
9633 _ACEOF
9634 cat confdefs.h >>conftest.$ac_ext
9635 cat >>conftest.$ac_ext <<_ACEOF
9636 /* end confdefs.h.  */
9637 #include <stdlib.h>
9638 #include <stdarg.h>
9639 #include <string.h>
9640 #include <float.h>
9641
9642 int
9643 main ()
9644 {
9645
9646   ;
9647   return 0;
9648 }
9649 _ACEOF
9650 rm -f conftest.$ac_objext
9651 if { (ac_try="$ac_compile"
9652 case "(($ac_try" in
9653   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9654   *) ac_try_echo=$ac_try;;
9655 esac
9656 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9657 $as_echo "$ac_try_echo") >&5
9658   (eval "$ac_compile") 2>conftest.er1
9659   ac_status=$?
9660   grep -v '^ *+' conftest.er1 >conftest.err
9661   rm -f conftest.er1
9662   cat conftest.err >&5
9663   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9664   (exit $ac_status); } && {
9665          test -z "$ac_c_werror_flag" ||
9666          test ! -s conftest.err
9667        } && test -s conftest.$ac_objext; then
9668   ac_cv_header_stdc=yes
9669 else
9670   $as_echo "$as_me: failed program was:" >&5
9671 sed 's/^/| /' conftest.$ac_ext >&5
9672
9673         ac_cv_header_stdc=no
9674 fi
9675
9676 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9677
9678 if test $ac_cv_header_stdc = yes; then
9679   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9680   cat >conftest.$ac_ext <<_ACEOF
9681 /* confdefs.h.  */
9682 _ACEOF
9683 cat confdefs.h >>conftest.$ac_ext
9684 cat >>conftest.$ac_ext <<_ACEOF
9685 /* end confdefs.h.  */
9686 #include <string.h>
9687
9688 _ACEOF
9689 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9690   $EGREP "memchr" >/dev/null 2>&1; then
9691   :
9692 else
9693   ac_cv_header_stdc=no
9694 fi
9695 rm -f conftest*
9696
9697 fi
9698
9699 if test $ac_cv_header_stdc = yes; then
9700   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9701   cat >conftest.$ac_ext <<_ACEOF
9702 /* confdefs.h.  */
9703 _ACEOF
9704 cat confdefs.h >>conftest.$ac_ext
9705 cat >>conftest.$ac_ext <<_ACEOF
9706 /* end confdefs.h.  */
9707 #include <stdlib.h>
9708
9709 _ACEOF
9710 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9711   $EGREP "free" >/dev/null 2>&1; then
9712   :
9713 else
9714   ac_cv_header_stdc=no
9715 fi
9716 rm -f conftest*
9717
9718 fi
9719
9720 if test $ac_cv_header_stdc = yes; then
9721   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9722   if test "$cross_compiling" = yes; then
9723   :
9724 else
9725   cat >conftest.$ac_ext <<_ACEOF
9726 /* confdefs.h.  */
9727 _ACEOF
9728 cat confdefs.h >>conftest.$ac_ext
9729 cat >>conftest.$ac_ext <<_ACEOF
9730 /* end confdefs.h.  */
9731 #include <ctype.h>
9732 #include <stdlib.h>
9733 #if ((' ' & 0x0FF) == 0x020)
9734 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
9735 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
9736 #else
9737 # define ISLOWER(c) \
9738                    (('a' <= (c) && (c) <= 'i') \
9739                      || ('j' <= (c) && (c) <= 'r') \
9740                      || ('s' <= (c) && (c) <= 'z'))
9741 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
9742 #endif
9743
9744 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
9745 int
9746 main ()
9747 {
9748   int i;
9749   for (i = 0; i < 256; i++)
9750     if (XOR (islower (i), ISLOWER (i))
9751         || toupper (i) != TOUPPER (i))
9752       return 2;
9753   return 0;
9754 }
9755 _ACEOF
9756 rm -f conftest$ac_exeext
9757 if { (ac_try="$ac_link"
9758 case "(($ac_try" in
9759   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9760   *) ac_try_echo=$ac_try;;
9761 esac
9762 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9763 $as_echo "$ac_try_echo") >&5
9764   (eval "$ac_link") 2>&5
9765   ac_status=$?
9766   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9767   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9768   { (case "(($ac_try" in
9769   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9770   *) ac_try_echo=$ac_try;;
9771 esac
9772 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9773 $as_echo "$ac_try_echo") >&5
9774   (eval "$ac_try") 2>&5
9775   ac_status=$?
9776   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9777   (exit $ac_status); }; }; then
9778   :
9779 else
9780   $as_echo "$as_me: program exited with status $ac_status" >&5
9781 $as_echo "$as_me: failed program was:" >&5
9782 sed 's/^/| /' conftest.$ac_ext >&5
9783
9784 ( exit $ac_status )
9785 ac_cv_header_stdc=no
9786 fi
9787 rm -rf conftest.dSYM
9788 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9789 fi
9790
9791
9792 fi
9793 fi
9794 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
9795 $as_echo "$ac_cv_header_stdc" >&6; }
9796 if test $ac_cv_header_stdc = yes; then
9797
9798 cat >>confdefs.h <<\_ACEOF
9799 #define STDC_HEADERS 1
9800 _ACEOF
9801
9802 fi
9803
9804 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
9805
9806
9807
9808
9809
9810
9811
9812
9813
9814 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
9815                   inttypes.h stdint.h unistd.h
9816 do
9817 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9818 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9819 $as_echo_n "checking for $ac_header... " >&6; }
9820 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9821   $as_echo_n "(cached) " >&6
9822 else
9823   cat >conftest.$ac_ext <<_ACEOF
9824 /* confdefs.h.  */
9825 _ACEOF
9826 cat confdefs.h >>conftest.$ac_ext
9827 cat >>conftest.$ac_ext <<_ACEOF
9828 /* end confdefs.h.  */
9829 $ac_includes_default
9830
9831 #include <$ac_header>
9832 _ACEOF
9833 rm -f conftest.$ac_objext
9834 if { (ac_try="$ac_compile"
9835 case "(($ac_try" in
9836   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9837   *) ac_try_echo=$ac_try;;
9838 esac
9839 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9840 $as_echo "$ac_try_echo") >&5
9841   (eval "$ac_compile") 2>conftest.er1
9842   ac_status=$?
9843   grep -v '^ *+' conftest.er1 >conftest.err
9844   rm -f conftest.er1
9845   cat conftest.err >&5
9846   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9847   (exit $ac_status); } && {
9848          test -z "$ac_c_werror_flag" ||
9849          test ! -s conftest.err
9850        } && test -s conftest.$ac_objext; then
9851   eval "$as_ac_Header=yes"
9852 else
9853   $as_echo "$as_me: failed program was:" >&5
9854 sed 's/^/| /' conftest.$ac_ext >&5
9855
9856         eval "$as_ac_Header=no"
9857 fi
9858
9859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9860 fi
9861 ac_res=`eval 'as_val=${'$as_ac_Header'}
9862                  $as_echo "$as_val"'`
9863                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9864 $as_echo "$ac_res" >&6; }
9865 as_val=`eval 'as_val=${'$as_ac_Header'}
9866                  $as_echo "$as_val"'`
9867    if test "x$as_val" = x""yes; then
9868   cat >>confdefs.h <<_ACEOF
9869 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9870 _ACEOF
9871
9872 fi
9873
9874 done
9875
9876
9877
9878
9879
9880
9881
9882
9883
9884
9885
9886
9887
9888
9889
9890
9891
9892
9893
9894
9895
9896
9897
9898
9899
9900
9901
9902
9903
9904
9905
9906
9907 for ac_header in crypt.h dld.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h poll.h pwd.h sys/ioctl.h sys/ipc.h sys/poll.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/shm.h sys/socket.h sys/sockio.h sys/tas.h sys/time.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h
9908 do
9909 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9910 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9911   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9912 $as_echo_n "checking for $ac_header... " >&6; }
9913 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9914   $as_echo_n "(cached) " >&6
9915 fi
9916 ac_res=`eval 'as_val=${'$as_ac_Header'}
9917                  $as_echo "$as_val"'`
9918                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9919 $as_echo "$ac_res" >&6; }
9920 else
9921   # Is the header compilable?
9922 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9923 $as_echo_n "checking $ac_header usability... " >&6; }
9924 cat >conftest.$ac_ext <<_ACEOF
9925 /* confdefs.h.  */
9926 _ACEOF
9927 cat confdefs.h >>conftest.$ac_ext
9928 cat >>conftest.$ac_ext <<_ACEOF
9929 /* end confdefs.h.  */
9930 $ac_includes_default
9931 #include <$ac_header>
9932 _ACEOF
9933 rm -f conftest.$ac_objext
9934 if { (ac_try="$ac_compile"
9935 case "(($ac_try" in
9936   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9937   *) ac_try_echo=$ac_try;;
9938 esac
9939 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9940 $as_echo "$ac_try_echo") >&5
9941   (eval "$ac_compile") 2>conftest.er1
9942   ac_status=$?
9943   grep -v '^ *+' conftest.er1 >conftest.err
9944   rm -f conftest.er1
9945   cat conftest.err >&5
9946   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9947   (exit $ac_status); } && {
9948          test -z "$ac_c_werror_flag" ||
9949          test ! -s conftest.err
9950        } && test -s conftest.$ac_objext; then
9951   ac_header_compiler=yes
9952 else
9953   $as_echo "$as_me: failed program was:" >&5
9954 sed 's/^/| /' conftest.$ac_ext >&5
9955
9956         ac_header_compiler=no
9957 fi
9958
9959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9960 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9961 $as_echo "$ac_header_compiler" >&6; }
9962
9963 # Is the header present?
9964 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9965 $as_echo_n "checking $ac_header presence... " >&6; }
9966 cat >conftest.$ac_ext <<_ACEOF
9967 /* confdefs.h.  */
9968 _ACEOF
9969 cat confdefs.h >>conftest.$ac_ext
9970 cat >>conftest.$ac_ext <<_ACEOF
9971 /* end confdefs.h.  */
9972 #include <$ac_header>
9973 _ACEOF
9974 if { (ac_try="$ac_cpp conftest.$ac_ext"
9975 case "(($ac_try" in
9976   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9977   *) ac_try_echo=$ac_try;;
9978 esac
9979 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9980 $as_echo "$ac_try_echo") >&5
9981   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9982   ac_status=$?
9983   grep -v '^ *+' conftest.er1 >conftest.err
9984   rm -f conftest.er1
9985   cat conftest.err >&5
9986   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9987   (exit $ac_status); } >/dev/null && {
9988          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9989          test ! -s conftest.err
9990        }; then
9991   ac_header_preproc=yes
9992 else
9993   $as_echo "$as_me: failed program was:" >&5
9994 sed 's/^/| /' conftest.$ac_ext >&5
9995
9996   ac_header_preproc=no
9997 fi
9998
9999 rm -f conftest.err conftest.$ac_ext
10000 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10001 $as_echo "$ac_header_preproc" >&6; }
10002
10003 # So?  What about this header?
10004 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10005   yes:no: )
10006     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10007 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10008     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10009 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10010     ac_header_preproc=yes
10011     ;;
10012   no:yes:* )
10013     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10014 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10015     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10016 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10017     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10018 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10019     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10020 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10021     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10022 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10023     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10024 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10025     ( cat <<\_ASBOX
10026 ## ---------------------------------------- ##
10027 ## Report this to pgsql-bugs@postgresql.org ##
10028 ## ---------------------------------------- ##
10029 _ASBOX
10030      ) | sed "s/^/$as_me: WARNING:     /" >&2
10031     ;;
10032 esac
10033 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10034 $as_echo_n "checking for $ac_header... " >&6; }
10035 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10036   $as_echo_n "(cached) " >&6
10037 else
10038   eval "$as_ac_Header=\$ac_header_preproc"
10039 fi
10040 ac_res=`eval 'as_val=${'$as_ac_Header'}
10041                  $as_echo "$as_val"'`
10042                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10043 $as_echo "$ac_res" >&6; }
10044
10045 fi
10046 as_val=`eval 'as_val=${'$as_ac_Header'}
10047                  $as_echo "$as_val"'`
10048    if test "x$as_val" = x""yes; then
10049   cat >>confdefs.h <<_ACEOF
10050 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10051 _ACEOF
10052
10053 fi
10054
10055 done
10056
10057
10058 # On BSD, cpp test for net/if.h will fail unless sys/socket.h
10059 # is included first.
10060
10061 for ac_header in net/if.h
10062 do
10063 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10064 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10065 $as_echo_n "checking for $ac_header... " >&6; }
10066 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10067   $as_echo_n "(cached) " >&6
10068 else
10069   cat >conftest.$ac_ext <<_ACEOF
10070 /* confdefs.h.  */
10071 _ACEOF
10072 cat confdefs.h >>conftest.$ac_ext
10073 cat >>conftest.$ac_ext <<_ACEOF
10074 /* end confdefs.h.  */
10075 $ac_includes_default
10076 #ifdef HAVE_SYS_SOCKET_H
10077 #include <sys/socket.h>
10078 #endif
10079
10080
10081 #include <$ac_header>
10082 _ACEOF
10083 rm -f conftest.$ac_objext
10084 if { (ac_try="$ac_compile"
10085 case "(($ac_try" in
10086   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10087   *) ac_try_echo=$ac_try;;
10088 esac
10089 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10090 $as_echo "$ac_try_echo") >&5
10091   (eval "$ac_compile") 2>conftest.er1
10092   ac_status=$?
10093   grep -v '^ *+' conftest.er1 >conftest.err
10094   rm -f conftest.er1
10095   cat conftest.err >&5
10096   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10097   (exit $ac_status); } && {
10098          test -z "$ac_c_werror_flag" ||
10099          test ! -s conftest.err
10100        } && test -s conftest.$ac_objext; then
10101   eval "$as_ac_Header=yes"
10102 else
10103   $as_echo "$as_me: failed program was:" >&5
10104 sed 's/^/| /' conftest.$ac_ext >&5
10105
10106         eval "$as_ac_Header=no"
10107 fi
10108
10109 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10110 fi
10111 ac_res=`eval 'as_val=${'$as_ac_Header'}
10112                  $as_echo "$as_val"'`
10113                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10114 $as_echo "$ac_res" >&6; }
10115 as_val=`eval 'as_val=${'$as_ac_Header'}
10116                  $as_echo "$as_val"'`
10117    if test "x$as_val" = x""yes; then
10118   cat >>confdefs.h <<_ACEOF
10119 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10120 _ACEOF
10121
10122 fi
10123
10124 done
10125
10126
10127 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
10128 # netinet/in.h is included first.
10129
10130 for ac_header in netinet/in.h
10131 do
10132 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10133 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10134   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10135 $as_echo_n "checking for $ac_header... " >&6; }
10136 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10137   $as_echo_n "(cached) " >&6
10138 fi
10139 ac_res=`eval 'as_val=${'$as_ac_Header'}
10140                  $as_echo "$as_val"'`
10141                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10142 $as_echo "$ac_res" >&6; }
10143 else
10144   # Is the header compilable?
10145 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10146 $as_echo_n "checking $ac_header usability... " >&6; }
10147 cat >conftest.$ac_ext <<_ACEOF
10148 /* confdefs.h.  */
10149 _ACEOF
10150 cat confdefs.h >>conftest.$ac_ext
10151 cat >>conftest.$ac_ext <<_ACEOF
10152 /* end confdefs.h.  */
10153 $ac_includes_default
10154 #include <$ac_header>
10155 _ACEOF
10156 rm -f conftest.$ac_objext
10157 if { (ac_try="$ac_compile"
10158 case "(($ac_try" in
10159   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10160   *) ac_try_echo=$ac_try;;
10161 esac
10162 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10163 $as_echo "$ac_try_echo") >&5
10164   (eval "$ac_compile") 2>conftest.er1
10165   ac_status=$?
10166   grep -v '^ *+' conftest.er1 >conftest.err
10167   rm -f conftest.er1
10168   cat conftest.err >&5
10169   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10170   (exit $ac_status); } && {
10171          test -z "$ac_c_werror_flag" ||
10172          test ! -s conftest.err
10173        } && test -s conftest.$ac_objext; then
10174   ac_header_compiler=yes
10175 else
10176   $as_echo "$as_me: failed program was:" >&5
10177 sed 's/^/| /' conftest.$ac_ext >&5
10178
10179         ac_header_compiler=no
10180 fi
10181
10182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10183 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10184 $as_echo "$ac_header_compiler" >&6; }
10185
10186 # Is the header present?
10187 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10188 $as_echo_n "checking $ac_header presence... " >&6; }
10189 cat >conftest.$ac_ext <<_ACEOF
10190 /* confdefs.h.  */
10191 _ACEOF
10192 cat confdefs.h >>conftest.$ac_ext
10193 cat >>conftest.$ac_ext <<_ACEOF
10194 /* end confdefs.h.  */
10195 #include <$ac_header>
10196 _ACEOF
10197 if { (ac_try="$ac_cpp conftest.$ac_ext"
10198 case "(($ac_try" in
10199   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10200   *) ac_try_echo=$ac_try;;
10201 esac
10202 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10203 $as_echo "$ac_try_echo") >&5
10204   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10205   ac_status=$?
10206   grep -v '^ *+' conftest.er1 >conftest.err
10207   rm -f conftest.er1
10208   cat conftest.err >&5
10209   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10210   (exit $ac_status); } >/dev/null && {
10211          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10212          test ! -s conftest.err
10213        }; then
10214   ac_header_preproc=yes
10215 else
10216   $as_echo "$as_me: failed program was:" >&5
10217 sed 's/^/| /' conftest.$ac_ext >&5
10218
10219   ac_header_preproc=no
10220 fi
10221
10222 rm -f conftest.err conftest.$ac_ext
10223 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10224 $as_echo "$ac_header_preproc" >&6; }
10225
10226 # So?  What about this header?
10227 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10228   yes:no: )
10229     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10230 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10231     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10232 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10233     ac_header_preproc=yes
10234     ;;
10235   no:yes:* )
10236     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10237 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10238     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10239 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10240     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10241 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10242     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10243 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10244     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10245 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10246     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10247 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10248     ( cat <<\_ASBOX
10249 ## ---------------------------------------- ##
10250 ## Report this to pgsql-bugs@postgresql.org ##
10251 ## ---------------------------------------- ##
10252 _ASBOX
10253      ) | sed "s/^/$as_me: WARNING:     /" >&2
10254     ;;
10255 esac
10256 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10257 $as_echo_n "checking for $ac_header... " >&6; }
10258 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10259   $as_echo_n "(cached) " >&6
10260 else
10261   eval "$as_ac_Header=\$ac_header_preproc"
10262 fi
10263 ac_res=`eval 'as_val=${'$as_ac_Header'}
10264                  $as_echo "$as_val"'`
10265                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10266 $as_echo "$ac_res" >&6; }
10267
10268 fi
10269 as_val=`eval 'as_val=${'$as_ac_Header'}
10270                  $as_echo "$as_val"'`
10271    if test "x$as_val" = x""yes; then
10272   cat >>confdefs.h <<_ACEOF
10273 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10274 _ACEOF
10275
10276 fi
10277
10278 done
10279
10280
10281 for ac_header in netinet/tcp.h
10282 do
10283 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10284 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10285 $as_echo_n "checking for $ac_header... " >&6; }
10286 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10287   $as_echo_n "(cached) " >&6
10288 else
10289   cat >conftest.$ac_ext <<_ACEOF
10290 /* confdefs.h.  */
10291 _ACEOF
10292 cat confdefs.h >>conftest.$ac_ext
10293 cat >>conftest.$ac_ext <<_ACEOF
10294 /* end confdefs.h.  */
10295 $ac_includes_default
10296 #ifdef HAVE_NETINET_IN_H
10297 #include <netinet/in.h>
10298 #endif
10299
10300
10301 #include <$ac_header>
10302 _ACEOF
10303 rm -f conftest.$ac_objext
10304 if { (ac_try="$ac_compile"
10305 case "(($ac_try" in
10306   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10307   *) ac_try_echo=$ac_try;;
10308 esac
10309 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10310 $as_echo "$ac_try_echo") >&5
10311   (eval "$ac_compile") 2>conftest.er1
10312   ac_status=$?
10313   grep -v '^ *+' conftest.er1 >conftest.err
10314   rm -f conftest.er1
10315   cat conftest.err >&5
10316   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10317   (exit $ac_status); } && {
10318          test -z "$ac_c_werror_flag" ||
10319          test ! -s conftest.err
10320        } && test -s conftest.$ac_objext; then
10321   eval "$as_ac_Header=yes"
10322 else
10323   $as_echo "$as_me: failed program was:" >&5
10324 sed 's/^/| /' conftest.$ac_ext >&5
10325
10326         eval "$as_ac_Header=no"
10327 fi
10328
10329 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10330 fi
10331 ac_res=`eval 'as_val=${'$as_ac_Header'}
10332                  $as_echo "$as_val"'`
10333                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10334 $as_echo "$ac_res" >&6; }
10335 as_val=`eval 'as_val=${'$as_ac_Header'}
10336                  $as_echo "$as_val"'`
10337    if test "x$as_val" = x""yes; then
10338   cat >>confdefs.h <<_ACEOF
10339 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10340 _ACEOF
10341
10342 fi
10343
10344 done
10345
10346
10347 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
10348
10349 for ac_header in readline/readline.h
10350 do
10351 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10352 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10353   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10354 $as_echo_n "checking for $ac_header... " >&6; }
10355 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10356   $as_echo_n "(cached) " >&6
10357 fi
10358 ac_res=`eval 'as_val=${'$as_ac_Header'}
10359                  $as_echo "$as_val"'`
10360                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10361 $as_echo "$ac_res" >&6; }
10362 else
10363   # Is the header compilable?
10364 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10365 $as_echo_n "checking $ac_header usability... " >&6; }
10366 cat >conftest.$ac_ext <<_ACEOF
10367 /* confdefs.h.  */
10368 _ACEOF
10369 cat confdefs.h >>conftest.$ac_ext
10370 cat >>conftest.$ac_ext <<_ACEOF
10371 /* end confdefs.h.  */
10372 $ac_includes_default
10373 #include <$ac_header>
10374 _ACEOF
10375 rm -f conftest.$ac_objext
10376 if { (ac_try="$ac_compile"
10377 case "(($ac_try" in
10378   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10379   *) ac_try_echo=$ac_try;;
10380 esac
10381 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10382 $as_echo "$ac_try_echo") >&5
10383   (eval "$ac_compile") 2>conftest.er1
10384   ac_status=$?
10385   grep -v '^ *+' conftest.er1 >conftest.err
10386   rm -f conftest.er1
10387   cat conftest.err >&5
10388   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10389   (exit $ac_status); } && {
10390          test -z "$ac_c_werror_flag" ||
10391          test ! -s conftest.err
10392        } && test -s conftest.$ac_objext; then
10393   ac_header_compiler=yes
10394 else
10395   $as_echo "$as_me: failed program was:" >&5
10396 sed 's/^/| /' conftest.$ac_ext >&5
10397
10398         ac_header_compiler=no
10399 fi
10400
10401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10402 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10403 $as_echo "$ac_header_compiler" >&6; }
10404
10405 # Is the header present?
10406 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10407 $as_echo_n "checking $ac_header presence... " >&6; }
10408 cat >conftest.$ac_ext <<_ACEOF
10409 /* confdefs.h.  */
10410 _ACEOF
10411 cat confdefs.h >>conftest.$ac_ext
10412 cat >>conftest.$ac_ext <<_ACEOF
10413 /* end confdefs.h.  */
10414 #include <$ac_header>
10415 _ACEOF
10416 if { (ac_try="$ac_cpp conftest.$ac_ext"
10417 case "(($ac_try" in
10418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10419   *) ac_try_echo=$ac_try;;
10420 esac
10421 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10422 $as_echo "$ac_try_echo") >&5
10423   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10424   ac_status=$?
10425   grep -v '^ *+' conftest.er1 >conftest.err
10426   rm -f conftest.er1
10427   cat conftest.err >&5
10428   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10429   (exit $ac_status); } >/dev/null && {
10430          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10431          test ! -s conftest.err
10432        }; then
10433   ac_header_preproc=yes
10434 else
10435   $as_echo "$as_me: failed program was:" >&5
10436 sed 's/^/| /' conftest.$ac_ext >&5
10437
10438   ac_header_preproc=no
10439 fi
10440
10441 rm -f conftest.err conftest.$ac_ext
10442 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10443 $as_echo "$ac_header_preproc" >&6; }
10444
10445 # So?  What about this header?
10446 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10447   yes:no: )
10448     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10449 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10450     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10451 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10452     ac_header_preproc=yes
10453     ;;
10454   no:yes:* )
10455     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10456 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10457     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10458 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10459     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10460 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10461     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10462 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10463     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10464 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10465     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10466 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10467     ( cat <<\_ASBOX
10468 ## ---------------------------------------- ##
10469 ## Report this to pgsql-bugs@postgresql.org ##
10470 ## ---------------------------------------- ##
10471 _ASBOX
10472      ) | sed "s/^/$as_me: WARNING:     /" >&2
10473     ;;
10474 esac
10475 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10476 $as_echo_n "checking for $ac_header... " >&6; }
10477 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10478   $as_echo_n "(cached) " >&6
10479 else
10480   eval "$as_ac_Header=\$ac_header_preproc"
10481 fi
10482 ac_res=`eval 'as_val=${'$as_ac_Header'}
10483                  $as_echo "$as_val"'`
10484                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10485 $as_echo "$ac_res" >&6; }
10486
10487 fi
10488 as_val=`eval 'as_val=${'$as_ac_Header'}
10489                  $as_echo "$as_val"'`
10490    if test "x$as_val" = x""yes; then
10491   cat >>confdefs.h <<_ACEOF
10492 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10493 _ACEOF
10494
10495 else
10496
10497 for ac_header in readline.h
10498 do
10499 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10500 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10501   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10502 $as_echo_n "checking for $ac_header... " >&6; }
10503 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10504   $as_echo_n "(cached) " >&6
10505 fi
10506 ac_res=`eval 'as_val=${'$as_ac_Header'}
10507                  $as_echo "$as_val"'`
10508                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10509 $as_echo "$ac_res" >&6; }
10510 else
10511   # Is the header compilable?
10512 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10513 $as_echo_n "checking $ac_header usability... " >&6; }
10514 cat >conftest.$ac_ext <<_ACEOF
10515 /* confdefs.h.  */
10516 _ACEOF
10517 cat confdefs.h >>conftest.$ac_ext
10518 cat >>conftest.$ac_ext <<_ACEOF
10519 /* end confdefs.h.  */
10520 $ac_includes_default
10521 #include <$ac_header>
10522 _ACEOF
10523 rm -f conftest.$ac_objext
10524 if { (ac_try="$ac_compile"
10525 case "(($ac_try" in
10526   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10527   *) ac_try_echo=$ac_try;;
10528 esac
10529 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10530 $as_echo "$ac_try_echo") >&5
10531   (eval "$ac_compile") 2>conftest.er1
10532   ac_status=$?
10533   grep -v '^ *+' conftest.er1 >conftest.err
10534   rm -f conftest.er1
10535   cat conftest.err >&5
10536   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10537   (exit $ac_status); } && {
10538          test -z "$ac_c_werror_flag" ||
10539          test ! -s conftest.err
10540        } && test -s conftest.$ac_objext; then
10541   ac_header_compiler=yes
10542 else
10543   $as_echo "$as_me: failed program was:" >&5
10544 sed 's/^/| /' conftest.$ac_ext >&5
10545
10546         ac_header_compiler=no
10547 fi
10548
10549 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10550 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10551 $as_echo "$ac_header_compiler" >&6; }
10552
10553 # Is the header present?
10554 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10555 $as_echo_n "checking $ac_header presence... " >&6; }
10556 cat >conftest.$ac_ext <<_ACEOF
10557 /* confdefs.h.  */
10558 _ACEOF
10559 cat confdefs.h >>conftest.$ac_ext
10560 cat >>conftest.$ac_ext <<_ACEOF
10561 /* end confdefs.h.  */
10562 #include <$ac_header>
10563 _ACEOF
10564 if { (ac_try="$ac_cpp conftest.$ac_ext"
10565 case "(($ac_try" in
10566   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10567   *) ac_try_echo=$ac_try;;
10568 esac
10569 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10570 $as_echo "$ac_try_echo") >&5
10571   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10572   ac_status=$?
10573   grep -v '^ *+' conftest.er1 >conftest.err
10574   rm -f conftest.er1
10575   cat conftest.err >&5
10576   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10577   (exit $ac_status); } >/dev/null && {
10578          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10579          test ! -s conftest.err
10580        }; then
10581   ac_header_preproc=yes
10582 else
10583   $as_echo "$as_me: failed program was:" >&5
10584 sed 's/^/| /' conftest.$ac_ext >&5
10585
10586   ac_header_preproc=no
10587 fi
10588
10589 rm -f conftest.err conftest.$ac_ext
10590 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10591 $as_echo "$ac_header_preproc" >&6; }
10592
10593 # So?  What about this header?
10594 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10595   yes:no: )
10596     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10597 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10598     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10599 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10600     ac_header_preproc=yes
10601     ;;
10602   no:yes:* )
10603     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10604 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10605     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10606 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10607     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10608 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10609     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10610 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10611     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10612 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10613     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10614 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10615     ( cat <<\_ASBOX
10616 ## ---------------------------------------- ##
10617 ## Report this to pgsql-bugs@postgresql.org ##
10618 ## ---------------------------------------- ##
10619 _ASBOX
10620      ) | sed "s/^/$as_me: WARNING:     /" >&2
10621     ;;
10622 esac
10623 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10624 $as_echo_n "checking for $ac_header... " >&6; }
10625 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10626   $as_echo_n "(cached) " >&6
10627 else
10628   eval "$as_ac_Header=\$ac_header_preproc"
10629 fi
10630 ac_res=`eval 'as_val=${'$as_ac_Header'}
10631                  $as_echo "$as_val"'`
10632                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10633 $as_echo "$ac_res" >&6; }
10634
10635 fi
10636 as_val=`eval 'as_val=${'$as_ac_Header'}
10637                  $as_echo "$as_val"'`
10638    if test "x$as_val" = x""yes; then
10639   cat >>confdefs.h <<_ACEOF
10640 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10641 _ACEOF
10642
10643 else
10644   { { $as_echo "$as_me:$LINENO: error: readline header not found
10645 If you have readline already installed, see config.log for details on the
10646 failure.  It is possible the compiler isn't looking in the proper directory.
10647 Use --without-readline to disable readline support." >&5
10648 $as_echo "$as_me: error: readline header not found
10649 If you have readline already installed, see config.log for details on the
10650 failure.  It is possible the compiler isn't looking in the proper directory.
10651 Use --without-readline to disable readline support." >&2;}
10652    { (exit 1); exit 1; }; }
10653 fi
10654
10655 done
10656
10657 fi
10658
10659 done
10660
10661
10662 for ac_header in readline/history.h
10663 do
10664 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10665 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10666   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10667 $as_echo_n "checking for $ac_header... " >&6; }
10668 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10669   $as_echo_n "(cached) " >&6
10670 fi
10671 ac_res=`eval 'as_val=${'$as_ac_Header'}
10672                  $as_echo "$as_val"'`
10673                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10674 $as_echo "$ac_res" >&6; }
10675 else
10676   # Is the header compilable?
10677 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10678 $as_echo_n "checking $ac_header usability... " >&6; }
10679 cat >conftest.$ac_ext <<_ACEOF
10680 /* confdefs.h.  */
10681 _ACEOF
10682 cat confdefs.h >>conftest.$ac_ext
10683 cat >>conftest.$ac_ext <<_ACEOF
10684 /* end confdefs.h.  */
10685 $ac_includes_default
10686 #include <$ac_header>
10687 _ACEOF
10688 rm -f conftest.$ac_objext
10689 if { (ac_try="$ac_compile"
10690 case "(($ac_try" in
10691   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10692   *) ac_try_echo=$ac_try;;
10693 esac
10694 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10695 $as_echo "$ac_try_echo") >&5
10696   (eval "$ac_compile") 2>conftest.er1
10697   ac_status=$?
10698   grep -v '^ *+' conftest.er1 >conftest.err
10699   rm -f conftest.er1
10700   cat conftest.err >&5
10701   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10702   (exit $ac_status); } && {
10703          test -z "$ac_c_werror_flag" ||
10704          test ! -s conftest.err
10705        } && test -s conftest.$ac_objext; then
10706   ac_header_compiler=yes
10707 else
10708   $as_echo "$as_me: failed program was:" >&5
10709 sed 's/^/| /' conftest.$ac_ext >&5
10710
10711         ac_header_compiler=no
10712 fi
10713
10714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10715 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10716 $as_echo "$ac_header_compiler" >&6; }
10717
10718 # Is the header present?
10719 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10720 $as_echo_n "checking $ac_header presence... " >&6; }
10721 cat >conftest.$ac_ext <<_ACEOF
10722 /* confdefs.h.  */
10723 _ACEOF
10724 cat confdefs.h >>conftest.$ac_ext
10725 cat >>conftest.$ac_ext <<_ACEOF
10726 /* end confdefs.h.  */
10727 #include <$ac_header>
10728 _ACEOF
10729 if { (ac_try="$ac_cpp conftest.$ac_ext"
10730 case "(($ac_try" in
10731   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10732   *) ac_try_echo=$ac_try;;
10733 esac
10734 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10735 $as_echo "$ac_try_echo") >&5
10736   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10737   ac_status=$?
10738   grep -v '^ *+' conftest.er1 >conftest.err
10739   rm -f conftest.er1
10740   cat conftest.err >&5
10741   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10742   (exit $ac_status); } >/dev/null && {
10743          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10744          test ! -s conftest.err
10745        }; then
10746   ac_header_preproc=yes
10747 else
10748   $as_echo "$as_me: failed program was:" >&5
10749 sed 's/^/| /' conftest.$ac_ext >&5
10750
10751   ac_header_preproc=no
10752 fi
10753
10754 rm -f conftest.err conftest.$ac_ext
10755 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10756 $as_echo "$ac_header_preproc" >&6; }
10757
10758 # So?  What about this header?
10759 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10760   yes:no: )
10761     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10762 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10763     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10764 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10765     ac_header_preproc=yes
10766     ;;
10767   no:yes:* )
10768     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10769 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10770     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10771 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10772     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10773 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10774     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10775 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10776     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10777 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10778     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10779 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10780     ( cat <<\_ASBOX
10781 ## ---------------------------------------- ##
10782 ## Report this to pgsql-bugs@postgresql.org ##
10783 ## ---------------------------------------- ##
10784 _ASBOX
10785      ) | sed "s/^/$as_me: WARNING:     /" >&2
10786     ;;
10787 esac
10788 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10789 $as_echo_n "checking for $ac_header... " >&6; }
10790 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10791   $as_echo_n "(cached) " >&6
10792 else
10793   eval "$as_ac_Header=\$ac_header_preproc"
10794 fi
10795 ac_res=`eval 'as_val=${'$as_ac_Header'}
10796                  $as_echo "$as_val"'`
10797                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10798 $as_echo "$ac_res" >&6; }
10799
10800 fi
10801 as_val=`eval 'as_val=${'$as_ac_Header'}
10802                  $as_echo "$as_val"'`
10803    if test "x$as_val" = x""yes; then
10804   cat >>confdefs.h <<_ACEOF
10805 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10806 _ACEOF
10807
10808 else
10809
10810 for ac_header in history.h
10811 do
10812 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10813 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10814   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10815 $as_echo_n "checking for $ac_header... " >&6; }
10816 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10817   $as_echo_n "(cached) " >&6
10818 fi
10819 ac_res=`eval 'as_val=${'$as_ac_Header'}
10820                  $as_echo "$as_val"'`
10821                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10822 $as_echo "$ac_res" >&6; }
10823 else
10824   # Is the header compilable?
10825 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10826 $as_echo_n "checking $ac_header usability... " >&6; }
10827 cat >conftest.$ac_ext <<_ACEOF
10828 /* confdefs.h.  */
10829 _ACEOF
10830 cat confdefs.h >>conftest.$ac_ext
10831 cat >>conftest.$ac_ext <<_ACEOF
10832 /* end confdefs.h.  */
10833 $ac_includes_default
10834 #include <$ac_header>
10835 _ACEOF
10836 rm -f conftest.$ac_objext
10837 if { (ac_try="$ac_compile"
10838 case "(($ac_try" in
10839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10840   *) ac_try_echo=$ac_try;;
10841 esac
10842 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10843 $as_echo "$ac_try_echo") >&5
10844   (eval "$ac_compile") 2>conftest.er1
10845   ac_status=$?
10846   grep -v '^ *+' conftest.er1 >conftest.err
10847   rm -f conftest.er1
10848   cat conftest.err >&5
10849   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10850   (exit $ac_status); } && {
10851          test -z "$ac_c_werror_flag" ||
10852          test ! -s conftest.err
10853        } && test -s conftest.$ac_objext; then
10854   ac_header_compiler=yes
10855 else
10856   $as_echo "$as_me: failed program was:" >&5
10857 sed 's/^/| /' conftest.$ac_ext >&5
10858
10859         ac_header_compiler=no
10860 fi
10861
10862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10863 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10864 $as_echo "$ac_header_compiler" >&6; }
10865
10866 # Is the header present?
10867 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10868 $as_echo_n "checking $ac_header presence... " >&6; }
10869 cat >conftest.$ac_ext <<_ACEOF
10870 /* confdefs.h.  */
10871 _ACEOF
10872 cat confdefs.h >>conftest.$ac_ext
10873 cat >>conftest.$ac_ext <<_ACEOF
10874 /* end confdefs.h.  */
10875 #include <$ac_header>
10876 _ACEOF
10877 if { (ac_try="$ac_cpp conftest.$ac_ext"
10878 case "(($ac_try" in
10879   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10880   *) ac_try_echo=$ac_try;;
10881 esac
10882 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10883 $as_echo "$ac_try_echo") >&5
10884   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10885   ac_status=$?
10886   grep -v '^ *+' conftest.er1 >conftest.err
10887   rm -f conftest.er1
10888   cat conftest.err >&5
10889   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10890   (exit $ac_status); } >/dev/null && {
10891          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10892          test ! -s conftest.err
10893        }; then
10894   ac_header_preproc=yes
10895 else
10896   $as_echo "$as_me: failed program was:" >&5
10897 sed 's/^/| /' conftest.$ac_ext >&5
10898
10899   ac_header_preproc=no
10900 fi
10901
10902 rm -f conftest.err conftest.$ac_ext
10903 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10904 $as_echo "$ac_header_preproc" >&6; }
10905
10906 # So?  What about this header?
10907 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10908   yes:no: )
10909     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10910 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10911     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10912 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10913     ac_header_preproc=yes
10914     ;;
10915   no:yes:* )
10916     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10917 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10918     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10919 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10920     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10921 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10922     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10923 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10924     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10925 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10926     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10927 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10928     ( cat <<\_ASBOX
10929 ## ---------------------------------------- ##
10930 ## Report this to pgsql-bugs@postgresql.org ##
10931 ## ---------------------------------------- ##
10932 _ASBOX
10933      ) | sed "s/^/$as_me: WARNING:     /" >&2
10934     ;;
10935 esac
10936 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10937 $as_echo_n "checking for $ac_header... " >&6; }
10938 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10939   $as_echo_n "(cached) " >&6
10940 else
10941   eval "$as_ac_Header=\$ac_header_preproc"
10942 fi
10943 ac_res=`eval 'as_val=${'$as_ac_Header'}
10944                  $as_echo "$as_val"'`
10945                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10946 $as_echo "$ac_res" >&6; }
10947
10948 fi
10949 as_val=`eval 'as_val=${'$as_ac_Header'}
10950                  $as_echo "$as_val"'`
10951    if test "x$as_val" = x""yes; then
10952   cat >>confdefs.h <<_ACEOF
10953 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10954 _ACEOF
10955
10956 else
10957   { { $as_echo "$as_me:$LINENO: error: history header not found
10958 If you have readline already installed, see config.log for details on the
10959 failure.  It is possible the compiler isn't looking in the proper directory.
10960 Use --without-readline to disable readline support." >&5
10961 $as_echo "$as_me: error: history header not found
10962 If you have readline already installed, see config.log for details on the
10963 failure.  It is possible the compiler isn't looking in the proper directory.
10964 Use --without-readline to disable readline support." >&2;}
10965    { (exit 1); exit 1; }; }
10966 fi
10967
10968 done
10969
10970 fi
10971
10972 done
10973
10974 fi
10975
10976 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
10977 # Some installations of libedit usurp /usr/include/readline/, which seems
10978 # bad practice, since in combined installations readline will have its headers
10979 # there.  We might have to resort to AC_EGREP checks to make sure we found
10980 # the proper header...
10981
10982 for ac_header in editline/readline.h
10983 do
10984 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10985 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10986   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10987 $as_echo_n "checking for $ac_header... " >&6; }
10988 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10989   $as_echo_n "(cached) " >&6
10990 fi
10991 ac_res=`eval 'as_val=${'$as_ac_Header'}
10992                  $as_echo "$as_val"'`
10993                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10994 $as_echo "$ac_res" >&6; }
10995 else
10996   # Is the header compilable?
10997 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10998 $as_echo_n "checking $ac_header usability... " >&6; }
10999 cat >conftest.$ac_ext <<_ACEOF
11000 /* confdefs.h.  */
11001 _ACEOF
11002 cat confdefs.h >>conftest.$ac_ext
11003 cat >>conftest.$ac_ext <<_ACEOF
11004 /* end confdefs.h.  */
11005 $ac_includes_default
11006 #include <$ac_header>
11007 _ACEOF
11008 rm -f conftest.$ac_objext
11009 if { (ac_try="$ac_compile"
11010 case "(($ac_try" in
11011   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11012   *) ac_try_echo=$ac_try;;
11013 esac
11014 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11015 $as_echo "$ac_try_echo") >&5
11016   (eval "$ac_compile") 2>conftest.er1
11017   ac_status=$?
11018   grep -v '^ *+' conftest.er1 >conftest.err
11019   rm -f conftest.er1
11020   cat conftest.err >&5
11021   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11022   (exit $ac_status); } && {
11023          test -z "$ac_c_werror_flag" ||
11024          test ! -s conftest.err
11025        } && test -s conftest.$ac_objext; then
11026   ac_header_compiler=yes
11027 else
11028   $as_echo "$as_me: failed program was:" >&5
11029 sed 's/^/| /' conftest.$ac_ext >&5
11030
11031         ac_header_compiler=no
11032 fi
11033
11034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11035 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11036 $as_echo "$ac_header_compiler" >&6; }
11037
11038 # Is the header present?
11039 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11040 $as_echo_n "checking $ac_header presence... " >&6; }
11041 cat >conftest.$ac_ext <<_ACEOF
11042 /* confdefs.h.  */
11043 _ACEOF
11044 cat confdefs.h >>conftest.$ac_ext
11045 cat >>conftest.$ac_ext <<_ACEOF
11046 /* end confdefs.h.  */
11047 #include <$ac_header>
11048 _ACEOF
11049 if { (ac_try="$ac_cpp conftest.$ac_ext"
11050 case "(($ac_try" in
11051   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11052   *) ac_try_echo=$ac_try;;
11053 esac
11054 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11055 $as_echo "$ac_try_echo") >&5
11056   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11057   ac_status=$?
11058   grep -v '^ *+' conftest.er1 >conftest.err
11059   rm -f conftest.er1
11060   cat conftest.err >&5
11061   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11062   (exit $ac_status); } >/dev/null && {
11063          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11064          test ! -s conftest.err
11065        }; then
11066   ac_header_preproc=yes
11067 else
11068   $as_echo "$as_me: failed program was:" >&5
11069 sed 's/^/| /' conftest.$ac_ext >&5
11070
11071   ac_header_preproc=no
11072 fi
11073
11074 rm -f conftest.err conftest.$ac_ext
11075 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11076 $as_echo "$ac_header_preproc" >&6; }
11077
11078 # So?  What about this header?
11079 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11080   yes:no: )
11081     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11082 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11083     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11084 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11085     ac_header_preproc=yes
11086     ;;
11087   no:yes:* )
11088     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11089 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11090     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11091 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11092     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11093 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11094     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11095 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11096     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11097 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11098     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11099 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11100     ( cat <<\_ASBOX
11101 ## ---------------------------------------- ##
11102 ## Report this to pgsql-bugs@postgresql.org ##
11103 ## ---------------------------------------- ##
11104 _ASBOX
11105      ) | sed "s/^/$as_me: WARNING:     /" >&2
11106     ;;
11107 esac
11108 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11109 $as_echo_n "checking for $ac_header... " >&6; }
11110 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11111   $as_echo_n "(cached) " >&6
11112 else
11113   eval "$as_ac_Header=\$ac_header_preproc"
11114 fi
11115 ac_res=`eval 'as_val=${'$as_ac_Header'}
11116                  $as_echo "$as_val"'`
11117                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11118 $as_echo "$ac_res" >&6; }
11119
11120 fi
11121 as_val=`eval 'as_val=${'$as_ac_Header'}
11122                  $as_echo "$as_val"'`
11123    if test "x$as_val" = x""yes; then
11124   cat >>confdefs.h <<_ACEOF
11125 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11126 _ACEOF
11127
11128 else
11129
11130 for ac_header in readline.h
11131 do
11132 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11133 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11134   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11135 $as_echo_n "checking for $ac_header... " >&6; }
11136 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11137   $as_echo_n "(cached) " >&6
11138 fi
11139 ac_res=`eval 'as_val=${'$as_ac_Header'}
11140                  $as_echo "$as_val"'`
11141                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11142 $as_echo "$ac_res" >&6; }
11143 else
11144   # Is the header compilable?
11145 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11146 $as_echo_n "checking $ac_header usability... " >&6; }
11147 cat >conftest.$ac_ext <<_ACEOF
11148 /* confdefs.h.  */
11149 _ACEOF
11150 cat confdefs.h >>conftest.$ac_ext
11151 cat >>conftest.$ac_ext <<_ACEOF
11152 /* end confdefs.h.  */
11153 $ac_includes_default
11154 #include <$ac_header>
11155 _ACEOF
11156 rm -f conftest.$ac_objext
11157 if { (ac_try="$ac_compile"
11158 case "(($ac_try" in
11159   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11160   *) ac_try_echo=$ac_try;;
11161 esac
11162 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11163 $as_echo "$ac_try_echo") >&5
11164   (eval "$ac_compile") 2>conftest.er1
11165   ac_status=$?
11166   grep -v '^ *+' conftest.er1 >conftest.err
11167   rm -f conftest.er1
11168   cat conftest.err >&5
11169   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11170   (exit $ac_status); } && {
11171          test -z "$ac_c_werror_flag" ||
11172          test ! -s conftest.err
11173        } && test -s conftest.$ac_objext; then
11174   ac_header_compiler=yes
11175 else
11176   $as_echo "$as_me: failed program was:" >&5
11177 sed 's/^/| /' conftest.$ac_ext >&5
11178
11179         ac_header_compiler=no
11180 fi
11181
11182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11183 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11184 $as_echo "$ac_header_compiler" >&6; }
11185
11186 # Is the header present?
11187 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11188 $as_echo_n "checking $ac_header presence... " >&6; }
11189 cat >conftest.$ac_ext <<_ACEOF
11190 /* confdefs.h.  */
11191 _ACEOF
11192 cat confdefs.h >>conftest.$ac_ext
11193 cat >>conftest.$ac_ext <<_ACEOF
11194 /* end confdefs.h.  */
11195 #include <$ac_header>
11196 _ACEOF
11197 if { (ac_try="$ac_cpp conftest.$ac_ext"
11198 case "(($ac_try" in
11199   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11200   *) ac_try_echo=$ac_try;;
11201 esac
11202 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11203 $as_echo "$ac_try_echo") >&5
11204   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11205   ac_status=$?
11206   grep -v '^ *+' conftest.er1 >conftest.err
11207   rm -f conftest.er1
11208   cat conftest.err >&5
11209   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11210   (exit $ac_status); } >/dev/null && {
11211          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11212          test ! -s conftest.err
11213        }; then
11214   ac_header_preproc=yes
11215 else
11216   $as_echo "$as_me: failed program was:" >&5
11217 sed 's/^/| /' conftest.$ac_ext >&5
11218
11219   ac_header_preproc=no
11220 fi
11221
11222 rm -f conftest.err conftest.$ac_ext
11223 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11224 $as_echo "$ac_header_preproc" >&6; }
11225
11226 # So?  What about this header?
11227 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11228   yes:no: )
11229     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11230 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11231     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11232 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11233     ac_header_preproc=yes
11234     ;;
11235   no:yes:* )
11236     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11237 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11238     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11239 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11240     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11241 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11242     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11243 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11244     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11245 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11246     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11247 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11248     ( cat <<\_ASBOX
11249 ## ---------------------------------------- ##
11250 ## Report this to pgsql-bugs@postgresql.org ##
11251 ## ---------------------------------------- ##
11252 _ASBOX
11253      ) | sed "s/^/$as_me: WARNING:     /" >&2
11254     ;;
11255 esac
11256 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11257 $as_echo_n "checking for $ac_header... " >&6; }
11258 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11259   $as_echo_n "(cached) " >&6
11260 else
11261   eval "$as_ac_Header=\$ac_header_preproc"
11262 fi
11263 ac_res=`eval 'as_val=${'$as_ac_Header'}
11264                  $as_echo "$as_val"'`
11265                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11266 $as_echo "$ac_res" >&6; }
11267
11268 fi
11269 as_val=`eval 'as_val=${'$as_ac_Header'}
11270                  $as_echo "$as_val"'`
11271    if test "x$as_val" = x""yes; then
11272   cat >>confdefs.h <<_ACEOF
11273 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11274 _ACEOF
11275
11276 else
11277
11278 for ac_header in readline/readline.h
11279 do
11280 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11281 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11282   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11283 $as_echo_n "checking for $ac_header... " >&6; }
11284 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11285   $as_echo_n "(cached) " >&6
11286 fi
11287 ac_res=`eval 'as_val=${'$as_ac_Header'}
11288                  $as_echo "$as_val"'`
11289                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11290 $as_echo "$ac_res" >&6; }
11291 else
11292   # Is the header compilable?
11293 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11294 $as_echo_n "checking $ac_header usability... " >&6; }
11295 cat >conftest.$ac_ext <<_ACEOF
11296 /* confdefs.h.  */
11297 _ACEOF
11298 cat confdefs.h >>conftest.$ac_ext
11299 cat >>conftest.$ac_ext <<_ACEOF
11300 /* end confdefs.h.  */
11301 $ac_includes_default
11302 #include <$ac_header>
11303 _ACEOF
11304 rm -f conftest.$ac_objext
11305 if { (ac_try="$ac_compile"
11306 case "(($ac_try" in
11307   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11308   *) ac_try_echo=$ac_try;;
11309 esac
11310 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11311 $as_echo "$ac_try_echo") >&5
11312   (eval "$ac_compile") 2>conftest.er1
11313   ac_status=$?
11314   grep -v '^ *+' conftest.er1 >conftest.err
11315   rm -f conftest.er1
11316   cat conftest.err >&5
11317   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11318   (exit $ac_status); } && {
11319          test -z "$ac_c_werror_flag" ||
11320          test ! -s conftest.err
11321        } && test -s conftest.$ac_objext; then
11322   ac_header_compiler=yes
11323 else
11324   $as_echo "$as_me: failed program was:" >&5
11325 sed 's/^/| /' conftest.$ac_ext >&5
11326
11327         ac_header_compiler=no
11328 fi
11329
11330 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11331 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11332 $as_echo "$ac_header_compiler" >&6; }
11333
11334 # Is the header present?
11335 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11336 $as_echo_n "checking $ac_header presence... " >&6; }
11337 cat >conftest.$ac_ext <<_ACEOF
11338 /* confdefs.h.  */
11339 _ACEOF
11340 cat confdefs.h >>conftest.$ac_ext
11341 cat >>conftest.$ac_ext <<_ACEOF
11342 /* end confdefs.h.  */
11343 #include <$ac_header>
11344 _ACEOF
11345 if { (ac_try="$ac_cpp conftest.$ac_ext"
11346 case "(($ac_try" in
11347   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11348   *) ac_try_echo=$ac_try;;
11349 esac
11350 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11351 $as_echo "$ac_try_echo") >&5
11352   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11353   ac_status=$?
11354   grep -v '^ *+' conftest.er1 >conftest.err
11355   rm -f conftest.er1
11356   cat conftest.err >&5
11357   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11358   (exit $ac_status); } >/dev/null && {
11359          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11360          test ! -s conftest.err
11361        }; then
11362   ac_header_preproc=yes
11363 else
11364   $as_echo "$as_me: failed program was:" >&5
11365 sed 's/^/| /' conftest.$ac_ext >&5
11366
11367   ac_header_preproc=no
11368 fi
11369
11370 rm -f conftest.err conftest.$ac_ext
11371 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11372 $as_echo "$ac_header_preproc" >&6; }
11373
11374 # So?  What about this header?
11375 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11376   yes:no: )
11377     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11378 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11379     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11380 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11381     ac_header_preproc=yes
11382     ;;
11383   no:yes:* )
11384     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11385 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11386     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11387 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11388     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11389 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11390     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11391 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11392     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11393 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11394     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11395 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11396     ( cat <<\_ASBOX
11397 ## ---------------------------------------- ##
11398 ## Report this to pgsql-bugs@postgresql.org ##
11399 ## ---------------------------------------- ##
11400 _ASBOX
11401      ) | sed "s/^/$as_me: WARNING:     /" >&2
11402     ;;
11403 esac
11404 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11405 $as_echo_n "checking for $ac_header... " >&6; }
11406 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11407   $as_echo_n "(cached) " >&6
11408 else
11409   eval "$as_ac_Header=\$ac_header_preproc"
11410 fi
11411 ac_res=`eval 'as_val=${'$as_ac_Header'}
11412                  $as_echo "$as_val"'`
11413                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11414 $as_echo "$ac_res" >&6; }
11415
11416 fi
11417 as_val=`eval 'as_val=${'$as_ac_Header'}
11418                  $as_echo "$as_val"'`
11419    if test "x$as_val" = x""yes; then
11420   cat >>confdefs.h <<_ACEOF
11421 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11422 _ACEOF
11423
11424 else
11425   { { $as_echo "$as_me:$LINENO: error: readline header not found
11426 If you have libedit already installed, see config.log for details on the
11427 failure.  It is possible the compiler isn't looking in the proper directory.
11428 Use --without-readline to disable libedit support." >&5
11429 $as_echo "$as_me: error: readline header not found
11430 If you have libedit already installed, see config.log for details on the
11431 failure.  It is possible the compiler isn't looking in the proper directory.
11432 Use --without-readline to disable libedit support." >&2;}
11433    { (exit 1); exit 1; }; }
11434 fi
11435
11436 done
11437
11438 fi
11439
11440 done
11441
11442 fi
11443
11444 done
11445
11446 # Note: in a libedit installation, history.h is sometimes a dummy, and may
11447 # not be there at all.  Hence, don't complain if not found.  We must check
11448 # though, since in yet other versions it is an independent header.
11449
11450 for ac_header in editline/history.h
11451 do
11452 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11453 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11454   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11455 $as_echo_n "checking for $ac_header... " >&6; }
11456 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11457   $as_echo_n "(cached) " >&6
11458 fi
11459 ac_res=`eval 'as_val=${'$as_ac_Header'}
11460                  $as_echo "$as_val"'`
11461                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11462 $as_echo "$ac_res" >&6; }
11463 else
11464   # Is the header compilable?
11465 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11466 $as_echo_n "checking $ac_header usability... " >&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 ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11483 $as_echo "$ac_try_echo") >&5
11484   (eval "$ac_compile") 2>conftest.er1
11485   ac_status=$?
11486   grep -v '^ *+' conftest.er1 >conftest.err
11487   rm -f conftest.er1
11488   cat conftest.err >&5
11489   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11490   (exit $ac_status); } && {
11491          test -z "$ac_c_werror_flag" ||
11492          test ! -s conftest.err
11493        } && test -s conftest.$ac_objext; then
11494   ac_header_compiler=yes
11495 else
11496   $as_echo "$as_me: failed program was:" >&5
11497 sed 's/^/| /' conftest.$ac_ext >&5
11498
11499         ac_header_compiler=no
11500 fi
11501
11502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11503 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11504 $as_echo "$ac_header_compiler" >&6; }
11505
11506 # Is the header present?
11507 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11508 $as_echo_n "checking $ac_header presence... " >&6; }
11509 cat >conftest.$ac_ext <<_ACEOF
11510 /* confdefs.h.  */
11511 _ACEOF
11512 cat confdefs.h >>conftest.$ac_ext
11513 cat >>conftest.$ac_ext <<_ACEOF
11514 /* end confdefs.h.  */
11515 #include <$ac_header>
11516 _ACEOF
11517 if { (ac_try="$ac_cpp conftest.$ac_ext"
11518 case "(($ac_try" in
11519   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11520   *) ac_try_echo=$ac_try;;
11521 esac
11522 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11523 $as_echo "$ac_try_echo") >&5
11524   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11525   ac_status=$?
11526   grep -v '^ *+' conftest.er1 >conftest.err
11527   rm -f conftest.er1
11528   cat conftest.err >&5
11529   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11530   (exit $ac_status); } >/dev/null && {
11531          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11532          test ! -s conftest.err
11533        }; then
11534   ac_header_preproc=yes
11535 else
11536   $as_echo "$as_me: failed program was:" >&5
11537 sed 's/^/| /' conftest.$ac_ext >&5
11538
11539   ac_header_preproc=no
11540 fi
11541
11542 rm -f conftest.err conftest.$ac_ext
11543 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11544 $as_echo "$ac_header_preproc" >&6; }
11545
11546 # So?  What about this header?
11547 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11548   yes:no: )
11549     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11550 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11551     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11552 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11553     ac_header_preproc=yes
11554     ;;
11555   no:yes:* )
11556     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11557 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11558     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11559 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11560     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11561 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11562     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11563 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11564     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11565 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11566     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11567 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11568     ( cat <<\_ASBOX
11569 ## ---------------------------------------- ##
11570 ## Report this to pgsql-bugs@postgresql.org ##
11571 ## ---------------------------------------- ##
11572 _ASBOX
11573      ) | sed "s/^/$as_me: WARNING:     /" >&2
11574     ;;
11575 esac
11576 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11577 $as_echo_n "checking for $ac_header... " >&6; }
11578 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11579   $as_echo_n "(cached) " >&6
11580 else
11581   eval "$as_ac_Header=\$ac_header_preproc"
11582 fi
11583 ac_res=`eval 'as_val=${'$as_ac_Header'}
11584                  $as_echo "$as_val"'`
11585                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11586 $as_echo "$ac_res" >&6; }
11587
11588 fi
11589 as_val=`eval 'as_val=${'$as_ac_Header'}
11590                  $as_echo "$as_val"'`
11591    if test "x$as_val" = x""yes; then
11592   cat >>confdefs.h <<_ACEOF
11593 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11594 _ACEOF
11595
11596 else
11597
11598 for ac_header in history.h
11599 do
11600 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11601 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11602   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11603 $as_echo_n "checking for $ac_header... " >&6; }
11604 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11605   $as_echo_n "(cached) " >&6
11606 fi
11607 ac_res=`eval 'as_val=${'$as_ac_Header'}
11608                  $as_echo "$as_val"'`
11609                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11610 $as_echo "$ac_res" >&6; }
11611 else
11612   # Is the header compilable?
11613 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11614 $as_echo_n "checking $ac_header usability... " >&6; }
11615 cat >conftest.$ac_ext <<_ACEOF
11616 /* confdefs.h.  */
11617 _ACEOF
11618 cat confdefs.h >>conftest.$ac_ext
11619 cat >>conftest.$ac_ext <<_ACEOF
11620 /* end confdefs.h.  */
11621 $ac_includes_default
11622 #include <$ac_header>
11623 _ACEOF
11624 rm -f conftest.$ac_objext
11625 if { (ac_try="$ac_compile"
11626 case "(($ac_try" in
11627   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11628   *) ac_try_echo=$ac_try;;
11629 esac
11630 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11631 $as_echo "$ac_try_echo") >&5
11632   (eval "$ac_compile") 2>conftest.er1
11633   ac_status=$?
11634   grep -v '^ *+' conftest.er1 >conftest.err
11635   rm -f conftest.er1
11636   cat conftest.err >&5
11637   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11638   (exit $ac_status); } && {
11639          test -z "$ac_c_werror_flag" ||
11640          test ! -s conftest.err
11641        } && test -s conftest.$ac_objext; then
11642   ac_header_compiler=yes
11643 else
11644   $as_echo "$as_me: failed program was:" >&5
11645 sed 's/^/| /' conftest.$ac_ext >&5
11646
11647         ac_header_compiler=no
11648 fi
11649
11650 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11651 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11652 $as_echo "$ac_header_compiler" >&6; }
11653
11654 # Is the header present?
11655 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11656 $as_echo_n "checking $ac_header presence... " >&6; }
11657 cat >conftest.$ac_ext <<_ACEOF
11658 /* confdefs.h.  */
11659 _ACEOF
11660 cat confdefs.h >>conftest.$ac_ext
11661 cat >>conftest.$ac_ext <<_ACEOF
11662 /* end confdefs.h.  */
11663 #include <$ac_header>
11664 _ACEOF
11665 if { (ac_try="$ac_cpp conftest.$ac_ext"
11666 case "(($ac_try" in
11667   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11668   *) ac_try_echo=$ac_try;;
11669 esac
11670 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11671 $as_echo "$ac_try_echo") >&5
11672   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11673   ac_status=$?
11674   grep -v '^ *+' conftest.er1 >conftest.err
11675   rm -f conftest.er1
11676   cat conftest.err >&5
11677   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11678   (exit $ac_status); } >/dev/null && {
11679          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11680          test ! -s conftest.err
11681        }; then
11682   ac_header_preproc=yes
11683 else
11684   $as_echo "$as_me: failed program was:" >&5
11685 sed 's/^/| /' conftest.$ac_ext >&5
11686
11687   ac_header_preproc=no
11688 fi
11689
11690 rm -f conftest.err conftest.$ac_ext
11691 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11692 $as_echo "$ac_header_preproc" >&6; }
11693
11694 # So?  What about this header?
11695 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11696   yes:no: )
11697     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11698 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11699     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11700 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11701     ac_header_preproc=yes
11702     ;;
11703   no:yes:* )
11704     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11705 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11706     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11707 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11708     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11709 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11710     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11711 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11712     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11713 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11714     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11715 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11716     ( cat <<\_ASBOX
11717 ## ---------------------------------------- ##
11718 ## Report this to pgsql-bugs@postgresql.org ##
11719 ## ---------------------------------------- ##
11720 _ASBOX
11721      ) | sed "s/^/$as_me: WARNING:     /" >&2
11722     ;;
11723 esac
11724 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11725 $as_echo_n "checking for $ac_header... " >&6; }
11726 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11727   $as_echo_n "(cached) " >&6
11728 else
11729   eval "$as_ac_Header=\$ac_header_preproc"
11730 fi
11731 ac_res=`eval 'as_val=${'$as_ac_Header'}
11732                  $as_echo "$as_val"'`
11733                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11734 $as_echo "$ac_res" >&6; }
11735
11736 fi
11737 as_val=`eval 'as_val=${'$as_ac_Header'}
11738                  $as_echo "$as_val"'`
11739    if test "x$as_val" = x""yes; then
11740   cat >>confdefs.h <<_ACEOF
11741 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11742 _ACEOF
11743
11744 else
11745
11746 for ac_header in readline/history.h
11747 do
11748 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11749 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11750   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11751 $as_echo_n "checking for $ac_header... " >&6; }
11752 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11753   $as_echo_n "(cached) " >&6
11754 fi
11755 ac_res=`eval 'as_val=${'$as_ac_Header'}
11756                  $as_echo "$as_val"'`
11757                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11758 $as_echo "$ac_res" >&6; }
11759 else
11760   # Is the header compilable?
11761 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11762 $as_echo_n "checking $ac_header usability... " >&6; }
11763 cat >conftest.$ac_ext <<_ACEOF
11764 /* confdefs.h.  */
11765 _ACEOF
11766 cat confdefs.h >>conftest.$ac_ext
11767 cat >>conftest.$ac_ext <<_ACEOF
11768 /* end confdefs.h.  */
11769 $ac_includes_default
11770 #include <$ac_header>
11771 _ACEOF
11772 rm -f conftest.$ac_objext
11773 if { (ac_try="$ac_compile"
11774 case "(($ac_try" in
11775   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11776   *) ac_try_echo=$ac_try;;
11777 esac
11778 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11779 $as_echo "$ac_try_echo") >&5
11780   (eval "$ac_compile") 2>conftest.er1
11781   ac_status=$?
11782   grep -v '^ *+' conftest.er1 >conftest.err
11783   rm -f conftest.er1
11784   cat conftest.err >&5
11785   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11786   (exit $ac_status); } && {
11787          test -z "$ac_c_werror_flag" ||
11788          test ! -s conftest.err
11789        } && test -s conftest.$ac_objext; then
11790   ac_header_compiler=yes
11791 else
11792   $as_echo "$as_me: failed program was:" >&5
11793 sed 's/^/| /' conftest.$ac_ext >&5
11794
11795         ac_header_compiler=no
11796 fi
11797
11798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11799 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11800 $as_echo "$ac_header_compiler" >&6; }
11801
11802 # Is the header present?
11803 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11804 $as_echo_n "checking $ac_header presence... " >&6; }
11805 cat >conftest.$ac_ext <<_ACEOF
11806 /* confdefs.h.  */
11807 _ACEOF
11808 cat confdefs.h >>conftest.$ac_ext
11809 cat >>conftest.$ac_ext <<_ACEOF
11810 /* end confdefs.h.  */
11811 #include <$ac_header>
11812 _ACEOF
11813 if { (ac_try="$ac_cpp conftest.$ac_ext"
11814 case "(($ac_try" in
11815   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11816   *) ac_try_echo=$ac_try;;
11817 esac
11818 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11819 $as_echo "$ac_try_echo") >&5
11820   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11821   ac_status=$?
11822   grep -v '^ *+' conftest.er1 >conftest.err
11823   rm -f conftest.er1
11824   cat conftest.err >&5
11825   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11826   (exit $ac_status); } >/dev/null && {
11827          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11828          test ! -s conftest.err
11829        }; then
11830   ac_header_preproc=yes
11831 else
11832   $as_echo "$as_me: failed program was:" >&5
11833 sed 's/^/| /' conftest.$ac_ext >&5
11834
11835   ac_header_preproc=no
11836 fi
11837
11838 rm -f conftest.err conftest.$ac_ext
11839 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11840 $as_echo "$ac_header_preproc" >&6; }
11841
11842 # So?  What about this header?
11843 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11844   yes:no: )
11845     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11846 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11847     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11848 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11849     ac_header_preproc=yes
11850     ;;
11851   no:yes:* )
11852     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11853 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11854     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11855 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11856     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11857 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11858     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11859 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11860     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11861 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11862     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11863 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11864     ( cat <<\_ASBOX
11865 ## ---------------------------------------- ##
11866 ## Report this to pgsql-bugs@postgresql.org ##
11867 ## ---------------------------------------- ##
11868 _ASBOX
11869      ) | sed "s/^/$as_me: WARNING:     /" >&2
11870     ;;
11871 esac
11872 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11873 $as_echo_n "checking for $ac_header... " >&6; }
11874 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11875   $as_echo_n "(cached) " >&6
11876 else
11877   eval "$as_ac_Header=\$ac_header_preproc"
11878 fi
11879 ac_res=`eval 'as_val=${'$as_ac_Header'}
11880                  $as_echo "$as_val"'`
11881                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11882 $as_echo "$ac_res" >&6; }
11883
11884 fi
11885 as_val=`eval 'as_val=${'$as_ac_Header'}
11886                  $as_echo "$as_val"'`
11887    if test "x$as_val" = x""yes; then
11888   cat >>confdefs.h <<_ACEOF
11889 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11890 _ACEOF
11891
11892 fi
11893
11894 done
11895
11896 fi
11897
11898 done
11899
11900 fi
11901
11902 done
11903
11904 fi
11905
11906 if test "$with_zlib" = yes; then
11907   if test "${ac_cv_header_zlib_h+set}" = set; then
11908   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11909 $as_echo_n "checking for zlib.h... " >&6; }
11910 if test "${ac_cv_header_zlib_h+set}" = set; then
11911   $as_echo_n "(cached) " >&6
11912 fi
11913 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11914 $as_echo "$ac_cv_header_zlib_h" >&6; }
11915 else
11916   # Is the header compilable?
11917 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
11918 $as_echo_n "checking zlib.h usability... " >&6; }
11919 cat >conftest.$ac_ext <<_ACEOF
11920 /* confdefs.h.  */
11921 _ACEOF
11922 cat confdefs.h >>conftest.$ac_ext
11923 cat >>conftest.$ac_ext <<_ACEOF
11924 /* end confdefs.h.  */
11925 $ac_includes_default
11926 #include <zlib.h>
11927 _ACEOF
11928 rm -f conftest.$ac_objext
11929 if { (ac_try="$ac_compile"
11930 case "(($ac_try" in
11931   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11932   *) ac_try_echo=$ac_try;;
11933 esac
11934 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11935 $as_echo "$ac_try_echo") >&5
11936   (eval "$ac_compile") 2>conftest.er1
11937   ac_status=$?
11938   grep -v '^ *+' conftest.er1 >conftest.err
11939   rm -f conftest.er1
11940   cat conftest.err >&5
11941   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11942   (exit $ac_status); } && {
11943          test -z "$ac_c_werror_flag" ||
11944          test ! -s conftest.err
11945        } && test -s conftest.$ac_objext; then
11946   ac_header_compiler=yes
11947 else
11948   $as_echo "$as_me: failed program was:" >&5
11949 sed 's/^/| /' conftest.$ac_ext >&5
11950
11951         ac_header_compiler=no
11952 fi
11953
11954 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11955 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11956 $as_echo "$ac_header_compiler" >&6; }
11957
11958 # Is the header present?
11959 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
11960 $as_echo_n "checking zlib.h presence... " >&6; }
11961 cat >conftest.$ac_ext <<_ACEOF
11962 /* confdefs.h.  */
11963 _ACEOF
11964 cat confdefs.h >>conftest.$ac_ext
11965 cat >>conftest.$ac_ext <<_ACEOF
11966 /* end confdefs.h.  */
11967 #include <zlib.h>
11968 _ACEOF
11969 if { (ac_try="$ac_cpp conftest.$ac_ext"
11970 case "(($ac_try" in
11971   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11972   *) ac_try_echo=$ac_try;;
11973 esac
11974 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11975 $as_echo "$ac_try_echo") >&5
11976   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11977   ac_status=$?
11978   grep -v '^ *+' conftest.er1 >conftest.err
11979   rm -f conftest.er1
11980   cat conftest.err >&5
11981   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11982   (exit $ac_status); } >/dev/null && {
11983          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11984          test ! -s conftest.err
11985        }; then
11986   ac_header_preproc=yes
11987 else
11988   $as_echo "$as_me: failed program was:" >&5
11989 sed 's/^/| /' conftest.$ac_ext >&5
11990
11991   ac_header_preproc=no
11992 fi
11993
11994 rm -f conftest.err conftest.$ac_ext
11995 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11996 $as_echo "$ac_header_preproc" >&6; }
11997
11998 # So?  What about this header?
11999 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12000   yes:no: )
12001     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12002 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12003     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
12004 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
12005     ac_header_preproc=yes
12006     ;;
12007   no:yes:* )
12008     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
12009 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
12010     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
12011 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
12012     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
12013 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
12014     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
12015 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12016     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
12017 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
12018     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
12019 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
12020     ( cat <<\_ASBOX
12021 ## ---------------------------------------- ##
12022 ## Report this to pgsql-bugs@postgresql.org ##
12023 ## ---------------------------------------- ##
12024 _ASBOX
12025      ) | sed "s/^/$as_me: WARNING:     /" >&2
12026     ;;
12027 esac
12028 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
12029 $as_echo_n "checking for zlib.h... " >&6; }
12030 if test "${ac_cv_header_zlib_h+set}" = set; then
12031   $as_echo_n "(cached) " >&6
12032 else
12033   ac_cv_header_zlib_h=$ac_header_preproc
12034 fi
12035 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
12036 $as_echo "$ac_cv_header_zlib_h" >&6; }
12037
12038 fi
12039 if test "x$ac_cv_header_zlib_h" = x""yes; then
12040   :
12041 else
12042   { { $as_echo "$as_me:$LINENO: error: zlib header not found
12043 If you have zlib already installed, see config.log for details on the
12044 failure.  It is possible the compiler isn't looking in the proper directory.
12045 Use --without-zlib to disable zlib support." >&5
12046 $as_echo "$as_me: error: zlib header not found
12047 If you have zlib already installed, see config.log for details on the
12048 failure.  It is possible the compiler isn't looking in the proper directory.
12049 Use --without-zlib to disable zlib support." >&2;}
12050    { (exit 1); exit 1; }; }
12051 fi
12052
12053
12054 fi
12055
12056 if test "$with_gssapi" = yes ; then
12057
12058 for ac_header in gssapi/gssapi.h
12059 do
12060 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12061 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12062   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12063 $as_echo_n "checking for $ac_header... " >&6; }
12064 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12065   $as_echo_n "(cached) " >&6
12066 fi
12067 ac_res=`eval 'as_val=${'$as_ac_Header'}
12068                  $as_echo "$as_val"'`
12069                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12070 $as_echo "$ac_res" >&6; }
12071 else
12072   # Is the header compilable?
12073 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12074 $as_echo_n "checking $ac_header usability... " >&6; }
12075 cat >conftest.$ac_ext <<_ACEOF
12076 /* confdefs.h.  */
12077 _ACEOF
12078 cat confdefs.h >>conftest.$ac_ext
12079 cat >>conftest.$ac_ext <<_ACEOF
12080 /* end confdefs.h.  */
12081 $ac_includes_default
12082 #include <$ac_header>
12083 _ACEOF
12084 rm -f conftest.$ac_objext
12085 if { (ac_try="$ac_compile"
12086 case "(($ac_try" in
12087   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12088   *) ac_try_echo=$ac_try;;
12089 esac
12090 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12091 $as_echo "$ac_try_echo") >&5
12092   (eval "$ac_compile") 2>conftest.er1
12093   ac_status=$?
12094   grep -v '^ *+' conftest.er1 >conftest.err
12095   rm -f conftest.er1
12096   cat conftest.err >&5
12097   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12098   (exit $ac_status); } && {
12099          test -z "$ac_c_werror_flag" ||
12100          test ! -s conftest.err
12101        } && test -s conftest.$ac_objext; then
12102   ac_header_compiler=yes
12103 else
12104   $as_echo "$as_me: failed program was:" >&5
12105 sed 's/^/| /' conftest.$ac_ext >&5
12106
12107         ac_header_compiler=no
12108 fi
12109
12110 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12111 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12112 $as_echo "$ac_header_compiler" >&6; }
12113
12114 # Is the header present?
12115 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12116 $as_echo_n "checking $ac_header presence... " >&6; }
12117 cat >conftest.$ac_ext <<_ACEOF
12118 /* confdefs.h.  */
12119 _ACEOF
12120 cat confdefs.h >>conftest.$ac_ext
12121 cat >>conftest.$ac_ext <<_ACEOF
12122 /* end confdefs.h.  */
12123 #include <$ac_header>
12124 _ACEOF
12125 if { (ac_try="$ac_cpp conftest.$ac_ext"
12126 case "(($ac_try" in
12127   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12128   *) ac_try_echo=$ac_try;;
12129 esac
12130 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12131 $as_echo "$ac_try_echo") >&5
12132   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12133   ac_status=$?
12134   grep -v '^ *+' conftest.er1 >conftest.err
12135   rm -f conftest.er1
12136   cat conftest.err >&5
12137   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12138   (exit $ac_status); } >/dev/null && {
12139          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12140          test ! -s conftest.err
12141        }; then
12142   ac_header_preproc=yes
12143 else
12144   $as_echo "$as_me: failed program was:" >&5
12145 sed 's/^/| /' conftest.$ac_ext >&5
12146
12147   ac_header_preproc=no
12148 fi
12149
12150 rm -f conftest.err conftest.$ac_ext
12151 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12152 $as_echo "$ac_header_preproc" >&6; }
12153
12154 # So?  What about this header?
12155 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12156   yes:no: )
12157     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12158 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12159     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12160 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12161     ac_header_preproc=yes
12162     ;;
12163   no:yes:* )
12164     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12165 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12166     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12167 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12168     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12169 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12170     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12171 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12172     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12173 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12174     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12175 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12176     ( cat <<\_ASBOX
12177 ## ---------------------------------------- ##
12178 ## Report this to pgsql-bugs@postgresql.org ##
12179 ## ---------------------------------------- ##
12180 _ASBOX
12181      ) | sed "s/^/$as_me: WARNING:     /" >&2
12182     ;;
12183 esac
12184 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12185 $as_echo_n "checking for $ac_header... " >&6; }
12186 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12187   $as_echo_n "(cached) " >&6
12188 else
12189   eval "$as_ac_Header=\$ac_header_preproc"
12190 fi
12191 ac_res=`eval 'as_val=${'$as_ac_Header'}
12192                  $as_echo "$as_val"'`
12193                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12194 $as_echo "$ac_res" >&6; }
12195
12196 fi
12197 as_val=`eval 'as_val=${'$as_ac_Header'}
12198                  $as_echo "$as_val"'`
12199    if test "x$as_val" = x""yes; then
12200   cat >>confdefs.h <<_ACEOF
12201 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12202 _ACEOF
12203
12204 else
12205
12206 for ac_header in gssapi.h
12207 do
12208 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12209 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12210   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12211 $as_echo_n "checking for $ac_header... " >&6; }
12212 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12213   $as_echo_n "(cached) " >&6
12214 fi
12215 ac_res=`eval 'as_val=${'$as_ac_Header'}
12216                  $as_echo "$as_val"'`
12217                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12218 $as_echo "$ac_res" >&6; }
12219 else
12220   # Is the header compilable?
12221 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12222 $as_echo_n "checking $ac_header usability... " >&6; }
12223 cat >conftest.$ac_ext <<_ACEOF
12224 /* confdefs.h.  */
12225 _ACEOF
12226 cat confdefs.h >>conftest.$ac_ext
12227 cat >>conftest.$ac_ext <<_ACEOF
12228 /* end confdefs.h.  */
12229 $ac_includes_default
12230 #include <$ac_header>
12231 _ACEOF
12232 rm -f conftest.$ac_objext
12233 if { (ac_try="$ac_compile"
12234 case "(($ac_try" in
12235   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12236   *) ac_try_echo=$ac_try;;
12237 esac
12238 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12239 $as_echo "$ac_try_echo") >&5
12240   (eval "$ac_compile") 2>conftest.er1
12241   ac_status=$?
12242   grep -v '^ *+' conftest.er1 >conftest.err
12243   rm -f conftest.er1
12244   cat conftest.err >&5
12245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12246   (exit $ac_status); } && {
12247          test -z "$ac_c_werror_flag" ||
12248          test ! -s conftest.err
12249        } && test -s conftest.$ac_objext; then
12250   ac_header_compiler=yes
12251 else
12252   $as_echo "$as_me: failed program was:" >&5
12253 sed 's/^/| /' conftest.$ac_ext >&5
12254
12255         ac_header_compiler=no
12256 fi
12257
12258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12259 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12260 $as_echo "$ac_header_compiler" >&6; }
12261
12262 # Is the header present?
12263 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12264 $as_echo_n "checking $ac_header presence... " >&6; }
12265 cat >conftest.$ac_ext <<_ACEOF
12266 /* confdefs.h.  */
12267 _ACEOF
12268 cat confdefs.h >>conftest.$ac_ext
12269 cat >>conftest.$ac_ext <<_ACEOF
12270 /* end confdefs.h.  */
12271 #include <$ac_header>
12272 _ACEOF
12273 if { (ac_try="$ac_cpp conftest.$ac_ext"
12274 case "(($ac_try" in
12275   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12276   *) ac_try_echo=$ac_try;;
12277 esac
12278 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12279 $as_echo "$ac_try_echo") >&5
12280   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12281   ac_status=$?
12282   grep -v '^ *+' conftest.er1 >conftest.err
12283   rm -f conftest.er1
12284   cat conftest.err >&5
12285   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12286   (exit $ac_status); } >/dev/null && {
12287          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12288          test ! -s conftest.err
12289        }; then
12290   ac_header_preproc=yes
12291 else
12292   $as_echo "$as_me: failed program was:" >&5
12293 sed 's/^/| /' conftest.$ac_ext >&5
12294
12295   ac_header_preproc=no
12296 fi
12297
12298 rm -f conftest.err conftest.$ac_ext
12299 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12300 $as_echo "$ac_header_preproc" >&6; }
12301
12302 # So?  What about this header?
12303 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12304   yes:no: )
12305     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12306 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12307     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12308 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12309     ac_header_preproc=yes
12310     ;;
12311   no:yes:* )
12312     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12313 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12314     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12315 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12316     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12317 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12318     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12319 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12320     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12321 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12322     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12323 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12324     ( cat <<\_ASBOX
12325 ## ---------------------------------------- ##
12326 ## Report this to pgsql-bugs@postgresql.org ##
12327 ## ---------------------------------------- ##
12328 _ASBOX
12329      ) | sed "s/^/$as_me: WARNING:     /" >&2
12330     ;;
12331 esac
12332 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12333 $as_echo_n "checking for $ac_header... " >&6; }
12334 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12335   $as_echo_n "(cached) " >&6
12336 else
12337   eval "$as_ac_Header=\$ac_header_preproc"
12338 fi
12339 ac_res=`eval 'as_val=${'$as_ac_Header'}
12340                  $as_echo "$as_val"'`
12341                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12342 $as_echo "$ac_res" >&6; }
12343
12344 fi
12345 as_val=`eval 'as_val=${'$as_ac_Header'}
12346                  $as_echo "$as_val"'`
12347    if test "x$as_val" = x""yes; then
12348   cat >>confdefs.h <<_ACEOF
12349 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12350 _ACEOF
12351
12352 else
12353   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
12354 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
12355    { (exit 1); exit 1; }; }
12356 fi
12357
12358 done
12359
12360 fi
12361
12362 done
12363
12364 fi
12365
12366 if test "$with_krb5" = yes ; then
12367   if test "${ac_cv_header_krb5_h+set}" = set; then
12368   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12369 $as_echo_n "checking for krb5.h... " >&6; }
12370 if test "${ac_cv_header_krb5_h+set}" = set; then
12371   $as_echo_n "(cached) " >&6
12372 fi
12373 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12374 $as_echo "$ac_cv_header_krb5_h" >&6; }
12375 else
12376   # Is the header compilable?
12377 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
12378 $as_echo_n "checking krb5.h usability... " >&6; }
12379 cat >conftest.$ac_ext <<_ACEOF
12380 /* confdefs.h.  */
12381 _ACEOF
12382 cat confdefs.h >>conftest.$ac_ext
12383 cat >>conftest.$ac_ext <<_ACEOF
12384 /* end confdefs.h.  */
12385 $ac_includes_default
12386 #include <krb5.h>
12387 _ACEOF
12388 rm -f conftest.$ac_objext
12389 if { (ac_try="$ac_compile"
12390 case "(($ac_try" in
12391   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12392   *) ac_try_echo=$ac_try;;
12393 esac
12394 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12395 $as_echo "$ac_try_echo") >&5
12396   (eval "$ac_compile") 2>conftest.er1
12397   ac_status=$?
12398   grep -v '^ *+' conftest.er1 >conftest.err
12399   rm -f conftest.er1
12400   cat conftest.err >&5
12401   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12402   (exit $ac_status); } && {
12403          test -z "$ac_c_werror_flag" ||
12404          test ! -s conftest.err
12405        } && test -s conftest.$ac_objext; then
12406   ac_header_compiler=yes
12407 else
12408   $as_echo "$as_me: failed program was:" >&5
12409 sed 's/^/| /' conftest.$ac_ext >&5
12410
12411         ac_header_compiler=no
12412 fi
12413
12414 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12415 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12416 $as_echo "$ac_header_compiler" >&6; }
12417
12418 # Is the header present?
12419 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
12420 $as_echo_n "checking krb5.h presence... " >&6; }
12421 cat >conftest.$ac_ext <<_ACEOF
12422 /* confdefs.h.  */
12423 _ACEOF
12424 cat confdefs.h >>conftest.$ac_ext
12425 cat >>conftest.$ac_ext <<_ACEOF
12426 /* end confdefs.h.  */
12427 #include <krb5.h>
12428 _ACEOF
12429 if { (ac_try="$ac_cpp conftest.$ac_ext"
12430 case "(($ac_try" in
12431   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12432   *) ac_try_echo=$ac_try;;
12433 esac
12434 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12435 $as_echo "$ac_try_echo") >&5
12436   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12437   ac_status=$?
12438   grep -v '^ *+' conftest.er1 >conftest.err
12439   rm -f conftest.er1
12440   cat conftest.err >&5
12441   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12442   (exit $ac_status); } >/dev/null && {
12443          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12444          test ! -s conftest.err
12445        }; then
12446   ac_header_preproc=yes
12447 else
12448   $as_echo "$as_me: failed program was:" >&5
12449 sed 's/^/| /' conftest.$ac_ext >&5
12450
12451   ac_header_preproc=no
12452 fi
12453
12454 rm -f conftest.err conftest.$ac_ext
12455 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12456 $as_echo "$ac_header_preproc" >&6; }
12457
12458 # So?  What about this header?
12459 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12460   yes:no: )
12461     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
12462 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12463     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
12464 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
12465     ac_header_preproc=yes
12466     ;;
12467   no:yes:* )
12468     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
12469 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
12470     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
12471 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
12472     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
12473 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
12474     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
12475 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12476     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
12477 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
12478     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
12479 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
12480     ( cat <<\_ASBOX
12481 ## ---------------------------------------- ##
12482 ## Report this to pgsql-bugs@postgresql.org ##
12483 ## ---------------------------------------- ##
12484 _ASBOX
12485      ) | sed "s/^/$as_me: WARNING:     /" >&2
12486     ;;
12487 esac
12488 { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12489 $as_echo_n "checking for krb5.h... " >&6; }
12490 if test "${ac_cv_header_krb5_h+set}" = set; then
12491   $as_echo_n "(cached) " >&6
12492 else
12493   ac_cv_header_krb5_h=$ac_header_preproc
12494 fi
12495 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12496 $as_echo "$ac_cv_header_krb5_h" >&6; }
12497
12498 fi
12499 if test "x$ac_cv_header_krb5_h" = x""yes; then
12500   :
12501 else
12502   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
12503 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
12504    { (exit 1); exit 1; }; }
12505 fi
12506
12507
12508 fi
12509
12510 if test "$with_openssl" = yes ; then
12511   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12512   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12513 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12514 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12515   $as_echo_n "(cached) " >&6
12516 fi
12517 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12518 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12519 else
12520   # Is the header compilable?
12521 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
12522 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
12523 cat >conftest.$ac_ext <<_ACEOF
12524 /* confdefs.h.  */
12525 _ACEOF
12526 cat confdefs.h >>conftest.$ac_ext
12527 cat >>conftest.$ac_ext <<_ACEOF
12528 /* end confdefs.h.  */
12529 $ac_includes_default
12530 #include <openssl/ssl.h>
12531 _ACEOF
12532 rm -f conftest.$ac_objext
12533 if { (ac_try="$ac_compile"
12534 case "(($ac_try" in
12535   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12536   *) ac_try_echo=$ac_try;;
12537 esac
12538 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12539 $as_echo "$ac_try_echo") >&5
12540   (eval "$ac_compile") 2>conftest.er1
12541   ac_status=$?
12542   grep -v '^ *+' conftest.er1 >conftest.err
12543   rm -f conftest.er1
12544   cat conftest.err >&5
12545   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12546   (exit $ac_status); } && {
12547          test -z "$ac_c_werror_flag" ||
12548          test ! -s conftest.err
12549        } && test -s conftest.$ac_objext; then
12550   ac_header_compiler=yes
12551 else
12552   $as_echo "$as_me: failed program was:" >&5
12553 sed 's/^/| /' conftest.$ac_ext >&5
12554
12555         ac_header_compiler=no
12556 fi
12557
12558 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12559 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12560 $as_echo "$ac_header_compiler" >&6; }
12561
12562 # Is the header present?
12563 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
12564 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
12565 cat >conftest.$ac_ext <<_ACEOF
12566 /* confdefs.h.  */
12567 _ACEOF
12568 cat confdefs.h >>conftest.$ac_ext
12569 cat >>conftest.$ac_ext <<_ACEOF
12570 /* end confdefs.h.  */
12571 #include <openssl/ssl.h>
12572 _ACEOF
12573 if { (ac_try="$ac_cpp conftest.$ac_ext"
12574 case "(($ac_try" in
12575   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12576   *) ac_try_echo=$ac_try;;
12577 esac
12578 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12579 $as_echo "$ac_try_echo") >&5
12580   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12581   ac_status=$?
12582   grep -v '^ *+' conftest.er1 >conftest.err
12583   rm -f conftest.er1
12584   cat conftest.err >&5
12585   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12586   (exit $ac_status); } >/dev/null && {
12587          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12588          test ! -s conftest.err
12589        }; then
12590   ac_header_preproc=yes
12591 else
12592   $as_echo "$as_me: failed program was:" >&5
12593 sed 's/^/| /' conftest.$ac_ext >&5
12594
12595   ac_header_preproc=no
12596 fi
12597
12598 rm -f conftest.err conftest.$ac_ext
12599 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12600 $as_echo "$ac_header_preproc" >&6; }
12601
12602 # So?  What about this header?
12603 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12604   yes:no: )
12605     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
12606 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12607     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
12608 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
12609     ac_header_preproc=yes
12610     ;;
12611   no:yes:* )
12612     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
12613 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
12614     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
12615 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
12616     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
12617 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
12618     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
12619 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12620     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
12621 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
12622     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
12623 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
12624     ( cat <<\_ASBOX
12625 ## ---------------------------------------- ##
12626 ## Report this to pgsql-bugs@postgresql.org ##
12627 ## ---------------------------------------- ##
12628 _ASBOX
12629      ) | sed "s/^/$as_me: WARNING:     /" >&2
12630     ;;
12631 esac
12632 { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12633 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12634 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12635   $as_echo_n "(cached) " >&6
12636 else
12637   ac_cv_header_openssl_ssl_h=$ac_header_preproc
12638 fi
12639 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12640 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12641
12642 fi
12643 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
12644   :
12645 else
12646   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
12647 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
12648    { (exit 1); exit 1; }; }
12649 fi
12650
12651
12652   if test "${ac_cv_header_openssl_err_h+set}" = set; then
12653   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12654 $as_echo_n "checking for openssl/err.h... " >&6; }
12655 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12656   $as_echo_n "(cached) " >&6
12657 fi
12658 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12659 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12660 else
12661   # Is the header compilable?
12662 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
12663 $as_echo_n "checking openssl/err.h usability... " >&6; }
12664 cat >conftest.$ac_ext <<_ACEOF
12665 /* confdefs.h.  */
12666 _ACEOF
12667 cat confdefs.h >>conftest.$ac_ext
12668 cat >>conftest.$ac_ext <<_ACEOF
12669 /* end confdefs.h.  */
12670 $ac_includes_default
12671 #include <openssl/err.h>
12672 _ACEOF
12673 rm -f conftest.$ac_objext
12674 if { (ac_try="$ac_compile"
12675 case "(($ac_try" in
12676   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12677   *) ac_try_echo=$ac_try;;
12678 esac
12679 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12680 $as_echo "$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   $as_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   ac_header_compiler=yes
12692 else
12693   $as_echo "$as_me: failed program was:" >&5
12694 sed 's/^/| /' conftest.$ac_ext >&5
12695
12696         ac_header_compiler=no
12697 fi
12698
12699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12700 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12701 $as_echo "$ac_header_compiler" >&6; }
12702
12703 # Is the header present?
12704 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
12705 $as_echo_n "checking openssl/err.h presence... " >&6; }
12706 cat >conftest.$ac_ext <<_ACEOF
12707 /* confdefs.h.  */
12708 _ACEOF
12709 cat confdefs.h >>conftest.$ac_ext
12710 cat >>conftest.$ac_ext <<_ACEOF
12711 /* end confdefs.h.  */
12712 #include <openssl/err.h>
12713 _ACEOF
12714 if { (ac_try="$ac_cpp conftest.$ac_ext"
12715 case "(($ac_try" in
12716   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12717   *) ac_try_echo=$ac_try;;
12718 esac
12719 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12720 $as_echo "$ac_try_echo") >&5
12721   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12722   ac_status=$?
12723   grep -v '^ *+' conftest.er1 >conftest.err
12724   rm -f conftest.er1
12725   cat conftest.err >&5
12726   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12727   (exit $ac_status); } >/dev/null && {
12728          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12729          test ! -s conftest.err
12730        }; then
12731   ac_header_preproc=yes
12732 else
12733   $as_echo "$as_me: failed program was:" >&5
12734 sed 's/^/| /' conftest.$ac_ext >&5
12735
12736   ac_header_preproc=no
12737 fi
12738
12739 rm -f conftest.err conftest.$ac_ext
12740 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12741 $as_echo "$ac_header_preproc" >&6; }
12742
12743 # So?  What about this header?
12744 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12745   yes:no: )
12746     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
12747 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12748     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
12749 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
12750     ac_header_preproc=yes
12751     ;;
12752   no:yes:* )
12753     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
12754 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
12755     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
12756 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
12757     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
12758 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
12759     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
12760 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12761     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
12762 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
12763     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
12764 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
12765     ( cat <<\_ASBOX
12766 ## ---------------------------------------- ##
12767 ## Report this to pgsql-bugs@postgresql.org ##
12768 ## ---------------------------------------- ##
12769 _ASBOX
12770      ) | sed "s/^/$as_me: WARNING:     /" >&2
12771     ;;
12772 esac
12773 { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12774 $as_echo_n "checking for openssl/err.h... " >&6; }
12775 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12776   $as_echo_n "(cached) " >&6
12777 else
12778   ac_cv_header_openssl_err_h=$ac_header_preproc
12779 fi
12780 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12781 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12782
12783 fi
12784 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
12785   :
12786 else
12787   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
12788 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
12789    { (exit 1); exit 1; }; }
12790 fi
12791
12792
12793
12794 for ac_func in ERR_set_mark
12795 do
12796 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12797 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
12798 $as_echo_n "checking for $ac_func... " >&6; }
12799 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
12800   $as_echo_n "(cached) " >&6
12801 else
12802   cat >conftest.$ac_ext <<_ACEOF
12803 /* confdefs.h.  */
12804 _ACEOF
12805 cat confdefs.h >>conftest.$ac_ext
12806 cat >>conftest.$ac_ext <<_ACEOF
12807 /* end confdefs.h.  */
12808 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12809    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12810 #define $ac_func innocuous_$ac_func
12811
12812 /* System header to define __stub macros and hopefully few prototypes,
12813     which can conflict with char $ac_func (); below.
12814     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12815     <limits.h> exists even on freestanding compilers.  */
12816
12817 #ifdef __STDC__
12818 # include <limits.h>
12819 #else
12820 # include <assert.h>
12821 #endif
12822
12823 #undef $ac_func
12824
12825 /* Override any GCC internal prototype to avoid an error.
12826    Use char because int might match the return type of a GCC
12827    builtin and then its argument prototype would still apply.  */
12828 #ifdef __cplusplus
12829 extern "C"
12830 #endif
12831 char $ac_func ();
12832 /* The GNU C library defines this for functions which it implements
12833     to always fail with ENOSYS.  Some functions are actually named
12834     something starting with __ and the normal name is an alias.  */
12835 #if defined __stub_$ac_func || defined __stub___$ac_func
12836 choke me
12837 #endif
12838
12839 int
12840 main ()
12841 {
12842 return $ac_func ();
12843   ;
12844   return 0;
12845 }
12846 _ACEOF
12847 rm -f conftest.$ac_objext conftest$ac_exeext
12848 if { (ac_try="$ac_link"
12849 case "(($ac_try" in
12850   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12851   *) ac_try_echo=$ac_try;;
12852 esac
12853 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12854 $as_echo "$ac_try_echo") >&5
12855   (eval "$ac_link") 2>conftest.er1
12856   ac_status=$?
12857   grep -v '^ *+' conftest.er1 >conftest.err
12858   rm -f conftest.er1
12859   cat conftest.err >&5
12860   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12861   (exit $ac_status); } && {
12862          test -z "$ac_c_werror_flag" ||
12863          test ! -s conftest.err
12864        } && test -s conftest$ac_exeext && {
12865          test "$cross_compiling" = yes ||
12866          $as_test_x conftest$ac_exeext
12867        }; then
12868   eval "$as_ac_var=yes"
12869 else
12870   $as_echo "$as_me: failed program was:" >&5
12871 sed 's/^/| /' conftest.$ac_ext >&5
12872
12873         eval "$as_ac_var=no"
12874 fi
12875
12876 rm -rf conftest.dSYM
12877 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12878       conftest$ac_exeext conftest.$ac_ext
12879 fi
12880 ac_res=`eval 'as_val=${'$as_ac_var'}
12881                  $as_echo "$as_val"'`
12882                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12883 $as_echo "$ac_res" >&6; }
12884 as_val=`eval 'as_val=${'$as_ac_var'}
12885                  $as_echo "$as_val"'`
12886    if test "x$as_val" = x""yes; then
12887   cat >>confdefs.h <<_ACEOF
12888 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12889 _ACEOF
12890
12891 fi
12892 done
12893
12894 fi
12895
12896 if test "$with_pam" = yes ; then
12897
12898 for ac_header in security/pam_appl.h
12899 do
12900 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12901 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12902   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12903 $as_echo_n "checking for $ac_header... " >&6; }
12904 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12905   $as_echo_n "(cached) " >&6
12906 fi
12907 ac_res=`eval 'as_val=${'$as_ac_Header'}
12908                  $as_echo "$as_val"'`
12909                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12910 $as_echo "$ac_res" >&6; }
12911 else
12912   # Is the header compilable?
12913 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12914 $as_echo_n "checking $ac_header usability... " >&6; }
12915 cat >conftest.$ac_ext <<_ACEOF
12916 /* confdefs.h.  */
12917 _ACEOF
12918 cat confdefs.h >>conftest.$ac_ext
12919 cat >>conftest.$ac_ext <<_ACEOF
12920 /* end confdefs.h.  */
12921 $ac_includes_default
12922 #include <$ac_header>
12923 _ACEOF
12924 rm -f conftest.$ac_objext
12925 if { (ac_try="$ac_compile"
12926 case "(($ac_try" in
12927   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12928   *) ac_try_echo=$ac_try;;
12929 esac
12930 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12931 $as_echo "$ac_try_echo") >&5
12932   (eval "$ac_compile") 2>conftest.er1
12933   ac_status=$?
12934   grep -v '^ *+' conftest.er1 >conftest.err
12935   rm -f conftest.er1
12936   cat conftest.err >&5
12937   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12938   (exit $ac_status); } && {
12939          test -z "$ac_c_werror_flag" ||
12940          test ! -s conftest.err
12941        } && test -s conftest.$ac_objext; then
12942   ac_header_compiler=yes
12943 else
12944   $as_echo "$as_me: failed program was:" >&5
12945 sed 's/^/| /' conftest.$ac_ext >&5
12946
12947         ac_header_compiler=no
12948 fi
12949
12950 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12951 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12952 $as_echo "$ac_header_compiler" >&6; }
12953
12954 # Is the header present?
12955 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12956 $as_echo_n "checking $ac_header presence... " >&6; }
12957 cat >conftest.$ac_ext <<_ACEOF
12958 /* confdefs.h.  */
12959 _ACEOF
12960 cat confdefs.h >>conftest.$ac_ext
12961 cat >>conftest.$ac_ext <<_ACEOF
12962 /* end confdefs.h.  */
12963 #include <$ac_header>
12964 _ACEOF
12965 if { (ac_try="$ac_cpp conftest.$ac_ext"
12966 case "(($ac_try" in
12967   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12968   *) ac_try_echo=$ac_try;;
12969 esac
12970 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12971 $as_echo "$ac_try_echo") >&5
12972   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12973   ac_status=$?
12974   grep -v '^ *+' conftest.er1 >conftest.err
12975   rm -f conftest.er1
12976   cat conftest.err >&5
12977   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12978   (exit $ac_status); } >/dev/null && {
12979          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12980          test ! -s conftest.err
12981        }; then
12982   ac_header_preproc=yes
12983 else
12984   $as_echo "$as_me: failed program was:" >&5
12985 sed 's/^/| /' conftest.$ac_ext >&5
12986
12987   ac_header_preproc=no
12988 fi
12989
12990 rm -f conftest.err conftest.$ac_ext
12991 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12992 $as_echo "$ac_header_preproc" >&6; }
12993
12994 # So?  What about this header?
12995 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12996   yes:no: )
12997     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12998 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12999     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13000 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13001     ac_header_preproc=yes
13002     ;;
13003   no:yes:* )
13004     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13005 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13006     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13007 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13008     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13009 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13010     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13011 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13012     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13013 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13014     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13015 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13016     ( cat <<\_ASBOX
13017 ## ---------------------------------------- ##
13018 ## Report this to pgsql-bugs@postgresql.org ##
13019 ## ---------------------------------------- ##
13020 _ASBOX
13021      ) | sed "s/^/$as_me: WARNING:     /" >&2
13022     ;;
13023 esac
13024 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13025 $as_echo_n "checking for $ac_header... " >&6; }
13026 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13027   $as_echo_n "(cached) " >&6
13028 else
13029   eval "$as_ac_Header=\$ac_header_preproc"
13030 fi
13031 ac_res=`eval 'as_val=${'$as_ac_Header'}
13032                  $as_echo "$as_val"'`
13033                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13034 $as_echo "$ac_res" >&6; }
13035
13036 fi
13037 as_val=`eval 'as_val=${'$as_ac_Header'}
13038                  $as_echo "$as_val"'`
13039    if test "x$as_val" = x""yes; then
13040   cat >>confdefs.h <<_ACEOF
13041 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13042 _ACEOF
13043
13044 else
13045
13046 for ac_header in pam/pam_appl.h
13047 do
13048 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13049 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13050   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13051 $as_echo_n "checking for $ac_header... " >&6; }
13052 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13053   $as_echo_n "(cached) " >&6
13054 fi
13055 ac_res=`eval 'as_val=${'$as_ac_Header'}
13056                  $as_echo "$as_val"'`
13057                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13058 $as_echo "$ac_res" >&6; }
13059 else
13060   # Is the header compilable?
13061 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13062 $as_echo_n "checking $ac_header usability... " >&6; }
13063 cat >conftest.$ac_ext <<_ACEOF
13064 /* confdefs.h.  */
13065 _ACEOF
13066 cat confdefs.h >>conftest.$ac_ext
13067 cat >>conftest.$ac_ext <<_ACEOF
13068 /* end confdefs.h.  */
13069 $ac_includes_default
13070 #include <$ac_header>
13071 _ACEOF
13072 rm -f conftest.$ac_objext
13073 if { (ac_try="$ac_compile"
13074 case "(($ac_try" in
13075   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13076   *) ac_try_echo=$ac_try;;
13077 esac
13078 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13079 $as_echo "$ac_try_echo") >&5
13080   (eval "$ac_compile") 2>conftest.er1
13081   ac_status=$?
13082   grep -v '^ *+' conftest.er1 >conftest.err
13083   rm -f conftest.er1
13084   cat conftest.err >&5
13085   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13086   (exit $ac_status); } && {
13087          test -z "$ac_c_werror_flag" ||
13088          test ! -s conftest.err
13089        } && test -s conftest.$ac_objext; then
13090   ac_header_compiler=yes
13091 else
13092   $as_echo "$as_me: failed program was:" >&5
13093 sed 's/^/| /' conftest.$ac_ext >&5
13094
13095         ac_header_compiler=no
13096 fi
13097
13098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13099 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13100 $as_echo "$ac_header_compiler" >&6; }
13101
13102 # Is the header present?
13103 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13104 $as_echo_n "checking $ac_header presence... " >&6; }
13105 cat >conftest.$ac_ext <<_ACEOF
13106 /* confdefs.h.  */
13107 _ACEOF
13108 cat confdefs.h >>conftest.$ac_ext
13109 cat >>conftest.$ac_ext <<_ACEOF
13110 /* end confdefs.h.  */
13111 #include <$ac_header>
13112 _ACEOF
13113 if { (ac_try="$ac_cpp conftest.$ac_ext"
13114 case "(($ac_try" in
13115   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13116   *) ac_try_echo=$ac_try;;
13117 esac
13118 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13119 $as_echo "$ac_try_echo") >&5
13120   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13121   ac_status=$?
13122   grep -v '^ *+' conftest.er1 >conftest.err
13123   rm -f conftest.er1
13124   cat conftest.err >&5
13125   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13126   (exit $ac_status); } >/dev/null && {
13127          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13128          test ! -s conftest.err
13129        }; then
13130   ac_header_preproc=yes
13131 else
13132   $as_echo "$as_me: failed program was:" >&5
13133 sed 's/^/| /' conftest.$ac_ext >&5
13134
13135   ac_header_preproc=no
13136 fi
13137
13138 rm -f conftest.err conftest.$ac_ext
13139 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13140 $as_echo "$ac_header_preproc" >&6; }
13141
13142 # So?  What about this header?
13143 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13144   yes:no: )
13145     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13146 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13147     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13148 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13149     ac_header_preproc=yes
13150     ;;
13151   no:yes:* )
13152     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13153 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13154     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13155 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13156     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13157 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13158     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13159 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13160     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13161 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13162     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13163 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13164     ( cat <<\_ASBOX
13165 ## ---------------------------------------- ##
13166 ## Report this to pgsql-bugs@postgresql.org ##
13167 ## ---------------------------------------- ##
13168 _ASBOX
13169      ) | sed "s/^/$as_me: WARNING:     /" >&2
13170     ;;
13171 esac
13172 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13173 $as_echo_n "checking for $ac_header... " >&6; }
13174 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13175   $as_echo_n "(cached) " >&6
13176 else
13177   eval "$as_ac_Header=\$ac_header_preproc"
13178 fi
13179 ac_res=`eval 'as_val=${'$as_ac_Header'}
13180                  $as_echo "$as_val"'`
13181                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13182 $as_echo "$ac_res" >&6; }
13183
13184 fi
13185 as_val=`eval 'as_val=${'$as_ac_Header'}
13186                  $as_echo "$as_val"'`
13187    if test "x$as_val" = x""yes; then
13188   cat >>confdefs.h <<_ACEOF
13189 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13190 _ACEOF
13191
13192 else
13193   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
13194 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
13195    { (exit 1); exit 1; }; }
13196 fi
13197
13198 done
13199
13200 fi
13201
13202 done
13203
13204 fi
13205
13206 if test "$with_libxml" = yes ; then
13207   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13208   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13209 $as_echo_n "checking for libxml/parser.h... " >&6; }
13210 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13211   $as_echo_n "(cached) " >&6
13212 fi
13213 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13214 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13215 else
13216   # Is the header compilable?
13217 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
13218 $as_echo_n "checking libxml/parser.h usability... " >&6; }
13219 cat >conftest.$ac_ext <<_ACEOF
13220 /* confdefs.h.  */
13221 _ACEOF
13222 cat confdefs.h >>conftest.$ac_ext
13223 cat >>conftest.$ac_ext <<_ACEOF
13224 /* end confdefs.h.  */
13225 $ac_includes_default
13226 #include <libxml/parser.h>
13227 _ACEOF
13228 rm -f conftest.$ac_objext
13229 if { (ac_try="$ac_compile"
13230 case "(($ac_try" in
13231   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13232   *) ac_try_echo=$ac_try;;
13233 esac
13234 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13235 $as_echo "$ac_try_echo") >&5
13236   (eval "$ac_compile") 2>conftest.er1
13237   ac_status=$?
13238   grep -v '^ *+' conftest.er1 >conftest.err
13239   rm -f conftest.er1
13240   cat conftest.err >&5
13241   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13242   (exit $ac_status); } && {
13243          test -z "$ac_c_werror_flag" ||
13244          test ! -s conftest.err
13245        } && test -s conftest.$ac_objext; then
13246   ac_header_compiler=yes
13247 else
13248   $as_echo "$as_me: failed program was:" >&5
13249 sed 's/^/| /' conftest.$ac_ext >&5
13250
13251         ac_header_compiler=no
13252 fi
13253
13254 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13255 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13256 $as_echo "$ac_header_compiler" >&6; }
13257
13258 # Is the header present?
13259 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
13260 $as_echo_n "checking libxml/parser.h presence... " >&6; }
13261 cat >conftest.$ac_ext <<_ACEOF
13262 /* confdefs.h.  */
13263 _ACEOF
13264 cat confdefs.h >>conftest.$ac_ext
13265 cat >>conftest.$ac_ext <<_ACEOF
13266 /* end confdefs.h.  */
13267 #include <libxml/parser.h>
13268 _ACEOF
13269 if { (ac_try="$ac_cpp conftest.$ac_ext"
13270 case "(($ac_try" in
13271   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13272   *) ac_try_echo=$ac_try;;
13273 esac
13274 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13275 $as_echo "$ac_try_echo") >&5
13276   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13277   ac_status=$?
13278   grep -v '^ *+' conftest.er1 >conftest.err
13279   rm -f conftest.er1
13280   cat conftest.err >&5
13281   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13282   (exit $ac_status); } >/dev/null && {
13283          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13284          test ! -s conftest.err
13285        }; then
13286   ac_header_preproc=yes
13287 else
13288   $as_echo "$as_me: failed program was:" >&5
13289 sed 's/^/| /' conftest.$ac_ext >&5
13290
13291   ac_header_preproc=no
13292 fi
13293
13294 rm -f conftest.err conftest.$ac_ext
13295 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13296 $as_echo "$ac_header_preproc" >&6; }
13297
13298 # So?  What about this header?
13299 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13300   yes:no: )
13301     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13302 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13303     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13304 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13305     ac_header_preproc=yes
13306     ;;
13307   no:yes:* )
13308     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13309 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13310     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13311 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13312     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13313 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13314     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13315 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13316     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13317 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13318     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13319 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13320     ( cat <<\_ASBOX
13321 ## ---------------------------------------- ##
13322 ## Report this to pgsql-bugs@postgresql.org ##
13323 ## ---------------------------------------- ##
13324 _ASBOX
13325      ) | sed "s/^/$as_me: WARNING:     /" >&2
13326     ;;
13327 esac
13328 { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13329 $as_echo_n "checking for libxml/parser.h... " >&6; }
13330 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13331   $as_echo_n "(cached) " >&6
13332 else
13333   ac_cv_header_libxml_parser_h=$ac_header_preproc
13334 fi
13335 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13336 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13337
13338 fi
13339 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13340   :
13341 else
13342   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13343 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13344    { (exit 1); exit 1; }; }
13345 fi
13346
13347
13348 fi
13349
13350 if test "$with_libxslt" = yes ; then
13351   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13352   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13353 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13354 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13355   $as_echo_n "(cached) " >&6
13356 fi
13357 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13358 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13359 else
13360   # Is the header compilable?
13361 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13362 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13363 cat >conftest.$ac_ext <<_ACEOF
13364 /* confdefs.h.  */
13365 _ACEOF
13366 cat confdefs.h >>conftest.$ac_ext
13367 cat >>conftest.$ac_ext <<_ACEOF
13368 /* end confdefs.h.  */
13369 $ac_includes_default
13370 #include <libxslt/xslt.h>
13371 _ACEOF
13372 rm -f conftest.$ac_objext
13373 if { (ac_try="$ac_compile"
13374 case "(($ac_try" in
13375   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13376   *) ac_try_echo=$ac_try;;
13377 esac
13378 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13379 $as_echo "$ac_try_echo") >&5
13380   (eval "$ac_compile") 2>conftest.er1
13381   ac_status=$?
13382   grep -v '^ *+' conftest.er1 >conftest.err
13383   rm -f conftest.er1
13384   cat conftest.err >&5
13385   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13386   (exit $ac_status); } && {
13387          test -z "$ac_c_werror_flag" ||
13388          test ! -s conftest.err
13389        } && test -s conftest.$ac_objext; then
13390   ac_header_compiler=yes
13391 else
13392   $as_echo "$as_me: failed program was:" >&5
13393 sed 's/^/| /' conftest.$ac_ext >&5
13394
13395         ac_header_compiler=no
13396 fi
13397
13398 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13399 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13400 $as_echo "$ac_header_compiler" >&6; }
13401
13402 # Is the header present?
13403 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13404 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13405 cat >conftest.$ac_ext <<_ACEOF
13406 /* confdefs.h.  */
13407 _ACEOF
13408 cat confdefs.h >>conftest.$ac_ext
13409 cat >>conftest.$ac_ext <<_ACEOF
13410 /* end confdefs.h.  */
13411 #include <libxslt/xslt.h>
13412 _ACEOF
13413 if { (ac_try="$ac_cpp conftest.$ac_ext"
13414 case "(($ac_try" in
13415   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13416   *) ac_try_echo=$ac_try;;
13417 esac
13418 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13419 $as_echo "$ac_try_echo") >&5
13420   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13421   ac_status=$?
13422   grep -v '^ *+' conftest.er1 >conftest.err
13423   rm -f conftest.er1
13424   cat conftest.err >&5
13425   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13426   (exit $ac_status); } >/dev/null && {
13427          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13428          test ! -s conftest.err
13429        }; then
13430   ac_header_preproc=yes
13431 else
13432   $as_echo "$as_me: failed program was:" >&5
13433 sed 's/^/| /' conftest.$ac_ext >&5
13434
13435   ac_header_preproc=no
13436 fi
13437
13438 rm -f conftest.err conftest.$ac_ext
13439 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13440 $as_echo "$ac_header_preproc" >&6; }
13441
13442 # So?  What about this header?
13443 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13444   yes:no: )
13445     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
13446 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13447     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
13448 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
13449     ac_header_preproc=yes
13450     ;;
13451   no:yes:* )
13452     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
13453 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
13454     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
13455 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
13456     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
13457 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
13458     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
13459 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13460     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
13461 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
13462     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
13463 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
13464     ( cat <<\_ASBOX
13465 ## ---------------------------------------- ##
13466 ## Report this to pgsql-bugs@postgresql.org ##
13467 ## ---------------------------------------- ##
13468 _ASBOX
13469      ) | sed "s/^/$as_me: WARNING:     /" >&2
13470     ;;
13471 esac
13472 { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13473 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13474 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13475   $as_echo_n "(cached) " >&6
13476 else
13477   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
13478 fi
13479 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13480 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13481
13482 fi
13483 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
13484   :
13485 else
13486   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
13487 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
13488    { (exit 1); exit 1; }; }
13489 fi
13490
13491
13492 fi
13493
13494 if test "$with_ldap" = yes ; then
13495   if test "$PORTNAME" != "win32"; then
13496
13497 for ac_header in ldap.h
13498 do
13499 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13500 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13501   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13502 $as_echo_n "checking for $ac_header... " >&6; }
13503 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13504   $as_echo_n "(cached) " >&6
13505 fi
13506 ac_res=`eval 'as_val=${'$as_ac_Header'}
13507                  $as_echo "$as_val"'`
13508                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13509 $as_echo "$ac_res" >&6; }
13510 else
13511   # Is the header compilable?
13512 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13513 $as_echo_n "checking $ac_header usability... " >&6; }
13514 cat >conftest.$ac_ext <<_ACEOF
13515 /* confdefs.h.  */
13516 _ACEOF
13517 cat confdefs.h >>conftest.$ac_ext
13518 cat >>conftest.$ac_ext <<_ACEOF
13519 /* end confdefs.h.  */
13520 $ac_includes_default
13521 #include <$ac_header>
13522 _ACEOF
13523 rm -f conftest.$ac_objext
13524 if { (ac_try="$ac_compile"
13525 case "(($ac_try" in
13526   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13527   *) ac_try_echo=$ac_try;;
13528 esac
13529 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13530 $as_echo "$ac_try_echo") >&5
13531   (eval "$ac_compile") 2>conftest.er1
13532   ac_status=$?
13533   grep -v '^ *+' conftest.er1 >conftest.err
13534   rm -f conftest.er1
13535   cat conftest.err >&5
13536   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13537   (exit $ac_status); } && {
13538          test -z "$ac_c_werror_flag" ||
13539          test ! -s conftest.err
13540        } && test -s conftest.$ac_objext; then
13541   ac_header_compiler=yes
13542 else
13543   $as_echo "$as_me: failed program was:" >&5
13544 sed 's/^/| /' conftest.$ac_ext >&5
13545
13546         ac_header_compiler=no
13547 fi
13548
13549 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13550 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13551 $as_echo "$ac_header_compiler" >&6; }
13552
13553 # Is the header present?
13554 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13555 $as_echo_n "checking $ac_header presence... " >&6; }
13556 cat >conftest.$ac_ext <<_ACEOF
13557 /* confdefs.h.  */
13558 _ACEOF
13559 cat confdefs.h >>conftest.$ac_ext
13560 cat >>conftest.$ac_ext <<_ACEOF
13561 /* end confdefs.h.  */
13562 #include <$ac_header>
13563 _ACEOF
13564 if { (ac_try="$ac_cpp conftest.$ac_ext"
13565 case "(($ac_try" in
13566   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13567   *) ac_try_echo=$ac_try;;
13568 esac
13569 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13570 $as_echo "$ac_try_echo") >&5
13571   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13572   ac_status=$?
13573   grep -v '^ *+' conftest.er1 >conftest.err
13574   rm -f conftest.er1
13575   cat conftest.err >&5
13576   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13577   (exit $ac_status); } >/dev/null && {
13578          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13579          test ! -s conftest.err
13580        }; then
13581   ac_header_preproc=yes
13582 else
13583   $as_echo "$as_me: failed program was:" >&5
13584 sed 's/^/| /' conftest.$ac_ext >&5
13585
13586   ac_header_preproc=no
13587 fi
13588
13589 rm -f conftest.err conftest.$ac_ext
13590 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13591 $as_echo "$ac_header_preproc" >&6; }
13592
13593 # So?  What about this header?
13594 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13595   yes:no: )
13596     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13597 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13598     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13599 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13600     ac_header_preproc=yes
13601     ;;
13602   no:yes:* )
13603     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13604 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13605     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13606 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13607     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13608 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13609     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13610 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13611     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13612 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13613     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13614 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13615     ( cat <<\_ASBOX
13616 ## ---------------------------------------- ##
13617 ## Report this to pgsql-bugs@postgresql.org ##
13618 ## ---------------------------------------- ##
13619 _ASBOX
13620      ) | sed "s/^/$as_me: WARNING:     /" >&2
13621     ;;
13622 esac
13623 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13624 $as_echo_n "checking for $ac_header... " >&6; }
13625 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13626   $as_echo_n "(cached) " >&6
13627 else
13628   eval "$as_ac_Header=\$ac_header_preproc"
13629 fi
13630 ac_res=`eval 'as_val=${'$as_ac_Header'}
13631                  $as_echo "$as_val"'`
13632                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13633 $as_echo "$ac_res" >&6; }
13634
13635 fi
13636 as_val=`eval 'as_val=${'$as_ac_Header'}
13637                  $as_echo "$as_val"'`
13638    if test "x$as_val" = x""yes; then
13639   cat >>confdefs.h <<_ACEOF
13640 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13641 _ACEOF
13642
13643 else
13644   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
13645 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
13646    { (exit 1); exit 1; }; }
13647 fi
13648
13649 done
13650
13651   else
13652
13653 for ac_header in winldap.h
13654 do
13655 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13656 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13657 $as_echo_n "checking for $ac_header... " >&6; }
13658 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13659   $as_echo_n "(cached) " >&6
13660 else
13661   cat >conftest.$ac_ext <<_ACEOF
13662 /* confdefs.h.  */
13663 _ACEOF
13664 cat confdefs.h >>conftest.$ac_ext
13665 cat >>conftest.$ac_ext <<_ACEOF
13666 /* end confdefs.h.  */
13667 $ac_includes_default
13668 #include <windows.h>
13669
13670
13671 #include <$ac_header>
13672 _ACEOF
13673 rm -f conftest.$ac_objext
13674 if { (ac_try="$ac_compile"
13675 case "(($ac_try" in
13676   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13677   *) ac_try_echo=$ac_try;;
13678 esac
13679 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13680 $as_echo "$ac_try_echo") >&5
13681   (eval "$ac_compile") 2>conftest.er1
13682   ac_status=$?
13683   grep -v '^ *+' conftest.er1 >conftest.err
13684   rm -f conftest.er1
13685   cat conftest.err >&5
13686   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13687   (exit $ac_status); } && {
13688          test -z "$ac_c_werror_flag" ||
13689          test ! -s conftest.err
13690        } && test -s conftest.$ac_objext; then
13691   eval "$as_ac_Header=yes"
13692 else
13693   $as_echo "$as_me: failed program was:" >&5
13694 sed 's/^/| /' conftest.$ac_ext >&5
13695
13696         eval "$as_ac_Header=no"
13697 fi
13698
13699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13700 fi
13701 ac_res=`eval 'as_val=${'$as_ac_Header'}
13702                  $as_echo "$as_val"'`
13703                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13704 $as_echo "$ac_res" >&6; }
13705 as_val=`eval 'as_val=${'$as_ac_Header'}
13706                  $as_echo "$as_val"'`
13707    if test "x$as_val" = x""yes; then
13708   cat >>confdefs.h <<_ACEOF
13709 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13710 _ACEOF
13711
13712 else
13713   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
13714 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
13715    { (exit 1); exit 1; }; }
13716 fi
13717
13718 done
13719
13720   fi
13721 fi
13722
13723 if test "$with_bonjour" = yes ; then
13724   if test "${ac_cv_header_dns_sd_h+set}" = set; then
13725   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13726 $as_echo_n "checking for dns_sd.h... " >&6; }
13727 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13728   $as_echo_n "(cached) " >&6
13729 fi
13730 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13731 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13732 else
13733   # Is the header compilable?
13734 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
13735 $as_echo_n "checking dns_sd.h usability... " >&6; }
13736 cat >conftest.$ac_ext <<_ACEOF
13737 /* confdefs.h.  */
13738 _ACEOF
13739 cat confdefs.h >>conftest.$ac_ext
13740 cat >>conftest.$ac_ext <<_ACEOF
13741 /* end confdefs.h.  */
13742 $ac_includes_default
13743 #include <dns_sd.h>
13744 _ACEOF
13745 rm -f conftest.$ac_objext
13746 if { (ac_try="$ac_compile"
13747 case "(($ac_try" in
13748   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13749   *) ac_try_echo=$ac_try;;
13750 esac
13751 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13752 $as_echo "$ac_try_echo") >&5
13753   (eval "$ac_compile") 2>conftest.er1
13754   ac_status=$?
13755   grep -v '^ *+' conftest.er1 >conftest.err
13756   rm -f conftest.er1
13757   cat conftest.err >&5
13758   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13759   (exit $ac_status); } && {
13760          test -z "$ac_c_werror_flag" ||
13761          test ! -s conftest.err
13762        } && test -s conftest.$ac_objext; then
13763   ac_header_compiler=yes
13764 else
13765   $as_echo "$as_me: failed program was:" >&5
13766 sed 's/^/| /' conftest.$ac_ext >&5
13767
13768         ac_header_compiler=no
13769 fi
13770
13771 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13772 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13773 $as_echo "$ac_header_compiler" >&6; }
13774
13775 # Is the header present?
13776 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
13777 $as_echo_n "checking dns_sd.h presence... " >&6; }
13778 cat >conftest.$ac_ext <<_ACEOF
13779 /* confdefs.h.  */
13780 _ACEOF
13781 cat confdefs.h >>conftest.$ac_ext
13782 cat >>conftest.$ac_ext <<_ACEOF
13783 /* end confdefs.h.  */
13784 #include <dns_sd.h>
13785 _ACEOF
13786 if { (ac_try="$ac_cpp conftest.$ac_ext"
13787 case "(($ac_try" in
13788   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13789   *) ac_try_echo=$ac_try;;
13790 esac
13791 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13792 $as_echo "$ac_try_echo") >&5
13793   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13794   ac_status=$?
13795   grep -v '^ *+' conftest.er1 >conftest.err
13796   rm -f conftest.er1
13797   cat conftest.err >&5
13798   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13799   (exit $ac_status); } >/dev/null && {
13800          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13801          test ! -s conftest.err
13802        }; then
13803   ac_header_preproc=yes
13804 else
13805   $as_echo "$as_me: failed program was:" >&5
13806 sed 's/^/| /' conftest.$ac_ext >&5
13807
13808   ac_header_preproc=no
13809 fi
13810
13811 rm -f conftest.err conftest.$ac_ext
13812 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13813 $as_echo "$ac_header_preproc" >&6; }
13814
13815 # So?  What about this header?
13816 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13817   yes:no: )
13818     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
13819 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13820     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
13821 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
13822     ac_header_preproc=yes
13823     ;;
13824   no:yes:* )
13825     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
13826 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
13827     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
13828 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
13829     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
13830 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
13831     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
13832 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13833     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
13834 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
13835     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
13836 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
13837     ( cat <<\_ASBOX
13838 ## ---------------------------------------- ##
13839 ## Report this to pgsql-bugs@postgresql.org ##
13840 ## ---------------------------------------- ##
13841 _ASBOX
13842      ) | sed "s/^/$as_me: WARNING:     /" >&2
13843     ;;
13844 esac
13845 { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13846 $as_echo_n "checking for dns_sd.h... " >&6; }
13847 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13848   $as_echo_n "(cached) " >&6
13849 else
13850   ac_cv_header_dns_sd_h=$ac_header_preproc
13851 fi
13852 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13853 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13854
13855 fi
13856 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
13857   :
13858 else
13859   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
13860 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
13861    { (exit 1); exit 1; }; }
13862 fi
13863
13864
13865 fi
13866
13867 # for contrib/uuid-ossp
13868 if test "$with_ossp_uuid" = yes ; then
13869
13870 for ac_header in ossp/uuid.h
13871 do
13872 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13873 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13874   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13875 $as_echo_n "checking for $ac_header... " >&6; }
13876 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13877   $as_echo_n "(cached) " >&6
13878 fi
13879 ac_res=`eval 'as_val=${'$as_ac_Header'}
13880                  $as_echo "$as_val"'`
13881                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13882 $as_echo "$ac_res" >&6; }
13883 else
13884   # Is the header compilable?
13885 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13886 $as_echo_n "checking $ac_header usability... " >&6; }
13887 cat >conftest.$ac_ext <<_ACEOF
13888 /* confdefs.h.  */
13889 _ACEOF
13890 cat confdefs.h >>conftest.$ac_ext
13891 cat >>conftest.$ac_ext <<_ACEOF
13892 /* end confdefs.h.  */
13893 $ac_includes_default
13894 #include <$ac_header>
13895 _ACEOF
13896 rm -f conftest.$ac_objext
13897 if { (ac_try="$ac_compile"
13898 case "(($ac_try" in
13899   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13900   *) ac_try_echo=$ac_try;;
13901 esac
13902 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13903 $as_echo "$ac_try_echo") >&5
13904   (eval "$ac_compile") 2>conftest.er1
13905   ac_status=$?
13906   grep -v '^ *+' conftest.er1 >conftest.err
13907   rm -f conftest.er1
13908   cat conftest.err >&5
13909   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13910   (exit $ac_status); } && {
13911          test -z "$ac_c_werror_flag" ||
13912          test ! -s conftest.err
13913        } && test -s conftest.$ac_objext; then
13914   ac_header_compiler=yes
13915 else
13916   $as_echo "$as_me: failed program was:" >&5
13917 sed 's/^/| /' conftest.$ac_ext >&5
13918
13919         ac_header_compiler=no
13920 fi
13921
13922 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13923 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13924 $as_echo "$ac_header_compiler" >&6; }
13925
13926 # Is the header present?
13927 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13928 $as_echo_n "checking $ac_header presence... " >&6; }
13929 cat >conftest.$ac_ext <<_ACEOF
13930 /* confdefs.h.  */
13931 _ACEOF
13932 cat confdefs.h >>conftest.$ac_ext
13933 cat >>conftest.$ac_ext <<_ACEOF
13934 /* end confdefs.h.  */
13935 #include <$ac_header>
13936 _ACEOF
13937 if { (ac_try="$ac_cpp conftest.$ac_ext"
13938 case "(($ac_try" in
13939   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13940   *) ac_try_echo=$ac_try;;
13941 esac
13942 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13943 $as_echo "$ac_try_echo") >&5
13944   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13945   ac_status=$?
13946   grep -v '^ *+' conftest.er1 >conftest.err
13947   rm -f conftest.er1
13948   cat conftest.err >&5
13949   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13950   (exit $ac_status); } >/dev/null && {
13951          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13952          test ! -s conftest.err
13953        }; then
13954   ac_header_preproc=yes
13955 else
13956   $as_echo "$as_me: failed program was:" >&5
13957 sed 's/^/| /' conftest.$ac_ext >&5
13958
13959   ac_header_preproc=no
13960 fi
13961
13962 rm -f conftest.err conftest.$ac_ext
13963 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13964 $as_echo "$ac_header_preproc" >&6; }
13965
13966 # So?  What about this header?
13967 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13968   yes:no: )
13969     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13970 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13971     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13972 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13973     ac_header_preproc=yes
13974     ;;
13975   no:yes:* )
13976     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13977 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13978     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13979 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13980     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13981 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13982     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13983 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13984     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13985 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13986     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13987 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13988     ( cat <<\_ASBOX
13989 ## ---------------------------------------- ##
13990 ## Report this to pgsql-bugs@postgresql.org ##
13991 ## ---------------------------------------- ##
13992 _ASBOX
13993      ) | sed "s/^/$as_me: WARNING:     /" >&2
13994     ;;
13995 esac
13996 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13997 $as_echo_n "checking for $ac_header... " >&6; }
13998 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13999   $as_echo_n "(cached) " >&6
14000 else
14001   eval "$as_ac_Header=\$ac_header_preproc"
14002 fi
14003 ac_res=`eval 'as_val=${'$as_ac_Header'}
14004                  $as_echo "$as_val"'`
14005                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14006 $as_echo "$ac_res" >&6; }
14007
14008 fi
14009 as_val=`eval 'as_val=${'$as_ac_Header'}
14010                  $as_echo "$as_val"'`
14011    if test "x$as_val" = x""yes; then
14012   cat >>confdefs.h <<_ACEOF
14013 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14014 _ACEOF
14015
14016 else
14017
14018
14019 for ac_header in uuid.h
14020 do
14021 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14022 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14023   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14024 $as_echo_n "checking for $ac_header... " >&6; }
14025 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14026   $as_echo_n "(cached) " >&6
14027 fi
14028 ac_res=`eval 'as_val=${'$as_ac_Header'}
14029                  $as_echo "$as_val"'`
14030                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14031 $as_echo "$ac_res" >&6; }
14032 else
14033   # Is the header compilable?
14034 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
14035 $as_echo_n "checking $ac_header usability... " >&6; }
14036 cat >conftest.$ac_ext <<_ACEOF
14037 /* confdefs.h.  */
14038 _ACEOF
14039 cat confdefs.h >>conftest.$ac_ext
14040 cat >>conftest.$ac_ext <<_ACEOF
14041 /* end confdefs.h.  */
14042 $ac_includes_default
14043 #include <$ac_header>
14044 _ACEOF
14045 rm -f conftest.$ac_objext
14046 if { (ac_try="$ac_compile"
14047 case "(($ac_try" in
14048   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14049   *) ac_try_echo=$ac_try;;
14050 esac
14051 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14052 $as_echo "$ac_try_echo") >&5
14053   (eval "$ac_compile") 2>conftest.er1
14054   ac_status=$?
14055   grep -v '^ *+' conftest.er1 >conftest.err
14056   rm -f conftest.er1
14057   cat conftest.err >&5
14058   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14059   (exit $ac_status); } && {
14060          test -z "$ac_c_werror_flag" ||
14061          test ! -s conftest.err
14062        } && test -s conftest.$ac_objext; then
14063   ac_header_compiler=yes
14064 else
14065   $as_echo "$as_me: failed program was:" >&5
14066 sed 's/^/| /' conftest.$ac_ext >&5
14067
14068         ac_header_compiler=no
14069 fi
14070
14071 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14072 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14073 $as_echo "$ac_header_compiler" >&6; }
14074
14075 # Is the header present?
14076 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14077 $as_echo_n "checking $ac_header presence... " >&6; }
14078 cat >conftest.$ac_ext <<_ACEOF
14079 /* confdefs.h.  */
14080 _ACEOF
14081 cat confdefs.h >>conftest.$ac_ext
14082 cat >>conftest.$ac_ext <<_ACEOF
14083 /* end confdefs.h.  */
14084 #include <$ac_header>
14085 _ACEOF
14086 if { (ac_try="$ac_cpp conftest.$ac_ext"
14087 case "(($ac_try" in
14088   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14089   *) ac_try_echo=$ac_try;;
14090 esac
14091 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14092 $as_echo "$ac_try_echo") >&5
14093   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14094   ac_status=$?
14095   grep -v '^ *+' conftest.er1 >conftest.err
14096   rm -f conftest.er1
14097   cat conftest.err >&5
14098   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14099   (exit $ac_status); } >/dev/null && {
14100          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14101          test ! -s conftest.err
14102        }; then
14103   ac_header_preproc=yes
14104 else
14105   $as_echo "$as_me: failed program was:" >&5
14106 sed 's/^/| /' conftest.$ac_ext >&5
14107
14108   ac_header_preproc=no
14109 fi
14110
14111 rm -f conftest.err conftest.$ac_ext
14112 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14113 $as_echo "$ac_header_preproc" >&6; }
14114
14115 # So?  What about this header?
14116 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14117   yes:no: )
14118     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14119 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14120     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14121 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14122     ac_header_preproc=yes
14123     ;;
14124   no:yes:* )
14125     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14126 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14127     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14128 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14129     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14130 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14131     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14132 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14133     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14134 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14135     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14136 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14137     ( cat <<\_ASBOX
14138 ## ---------------------------------------- ##
14139 ## Report this to pgsql-bugs@postgresql.org ##
14140 ## ---------------------------------------- ##
14141 _ASBOX
14142      ) | sed "s/^/$as_me: WARNING:     /" >&2
14143     ;;
14144 esac
14145 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14146 $as_echo_n "checking for $ac_header... " >&6; }
14147 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14148   $as_echo_n "(cached) " >&6
14149 else
14150   eval "$as_ac_Header=\$ac_header_preproc"
14151 fi
14152 ac_res=`eval 'as_val=${'$as_ac_Header'}
14153                  $as_echo "$as_val"'`
14154                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14155 $as_echo "$ac_res" >&6; }
14156
14157 fi
14158 as_val=`eval 'as_val=${'$as_ac_Header'}
14159                  $as_echo "$as_val"'`
14160    if test "x$as_val" = x""yes; then
14161   cat >>confdefs.h <<_ACEOF
14162 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14163 _ACEOF
14164
14165 else
14166   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
14167 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
14168    { (exit 1); exit 1; }; }
14169 fi
14170
14171 done
14172
14173 fi
14174
14175 done
14176
14177 fi
14178
14179
14180 ##
14181 ## Types, structures, compiler characteristics
14182 ##
14183
14184
14185  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
14186 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
14187 if test "${ac_cv_c_bigendian+set}" = set; then
14188   $as_echo_n "(cached) " >&6
14189 else
14190   ac_cv_c_bigendian=unknown
14191     # See if we're dealing with a universal compiler.
14192     cat >conftest.$ac_ext <<_ACEOF
14193 /* confdefs.h.  */
14194 _ACEOF
14195 cat confdefs.h >>conftest.$ac_ext
14196 cat >>conftest.$ac_ext <<_ACEOF
14197 /* end confdefs.h.  */
14198 #ifndef __APPLE_CC__
14199                not a universal capable compiler
14200              #endif
14201              typedef int dummy;
14202
14203 _ACEOF
14204 rm -f conftest.$ac_objext
14205 if { (ac_try="$ac_compile"
14206 case "(($ac_try" in
14207   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14208   *) ac_try_echo=$ac_try;;
14209 esac
14210 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14211 $as_echo "$ac_try_echo") >&5
14212   (eval "$ac_compile") 2>conftest.er1
14213   ac_status=$?
14214   grep -v '^ *+' conftest.er1 >conftest.err
14215   rm -f conftest.er1
14216   cat conftest.err >&5
14217   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14218   (exit $ac_status); } && {
14219          test -z "$ac_c_werror_flag" ||
14220          test ! -s conftest.err
14221        } && test -s conftest.$ac_objext; then
14222
14223         # Check for potential -arch flags.  It is not universal unless
14224         # there are some -arch flags.  Note that *ppc* also matches
14225         # ppc64.  This check is also rather less than ideal.
14226         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
14227           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
14228         esac
14229 else
14230   $as_echo "$as_me: failed program was:" >&5
14231 sed 's/^/| /' conftest.$ac_ext >&5
14232
14233
14234 fi
14235
14236 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14237     if test $ac_cv_c_bigendian = unknown; then
14238       # See if sys/param.h defines the BYTE_ORDER macro.
14239       cat >conftest.$ac_ext <<_ACEOF
14240 /* confdefs.h.  */
14241 _ACEOF
14242 cat confdefs.h >>conftest.$ac_ext
14243 cat >>conftest.$ac_ext <<_ACEOF
14244 /* end confdefs.h.  */
14245 #include <sys/types.h>
14246              #include <sys/param.h>
14247
14248 int
14249 main ()
14250 {
14251 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14252                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14253                      && LITTLE_ENDIAN)
14254               bogus endian macros
14255              #endif
14256
14257   ;
14258   return 0;
14259 }
14260 _ACEOF
14261 rm -f conftest.$ac_objext
14262 if { (ac_try="$ac_compile"
14263 case "(($ac_try" in
14264   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14265   *) ac_try_echo=$ac_try;;
14266 esac
14267 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14268 $as_echo "$ac_try_echo") >&5
14269   (eval "$ac_compile") 2>conftest.er1
14270   ac_status=$?
14271   grep -v '^ *+' conftest.er1 >conftest.err
14272   rm -f conftest.er1
14273   cat conftest.err >&5
14274   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14275   (exit $ac_status); } && {
14276          test -z "$ac_c_werror_flag" ||
14277          test ! -s conftest.err
14278        } && test -s conftest.$ac_objext; then
14279   # It does; now see whether it defined to BIG_ENDIAN or not.
14280          cat >conftest.$ac_ext <<_ACEOF
14281 /* confdefs.h.  */
14282 _ACEOF
14283 cat confdefs.h >>conftest.$ac_ext
14284 cat >>conftest.$ac_ext <<_ACEOF
14285 /* end confdefs.h.  */
14286 #include <sys/types.h>
14287                 #include <sys/param.h>
14288
14289 int
14290 main ()
14291 {
14292 #if BYTE_ORDER != BIG_ENDIAN
14293                  not big endian
14294                 #endif
14295
14296   ;
14297   return 0;
14298 }
14299 _ACEOF
14300 rm -f conftest.$ac_objext
14301 if { (ac_try="$ac_compile"
14302 case "(($ac_try" in
14303   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14304   *) ac_try_echo=$ac_try;;
14305 esac
14306 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14307 $as_echo "$ac_try_echo") >&5
14308   (eval "$ac_compile") 2>conftest.er1
14309   ac_status=$?
14310   grep -v '^ *+' conftest.er1 >conftest.err
14311   rm -f conftest.er1
14312   cat conftest.err >&5
14313   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14314   (exit $ac_status); } && {
14315          test -z "$ac_c_werror_flag" ||
14316          test ! -s conftest.err
14317        } && test -s conftest.$ac_objext; then
14318   ac_cv_c_bigendian=yes
14319 else
14320   $as_echo "$as_me: failed program was:" >&5
14321 sed 's/^/| /' conftest.$ac_ext >&5
14322
14323         ac_cv_c_bigendian=no
14324 fi
14325
14326 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14327 else
14328   $as_echo "$as_me: failed program was:" >&5
14329 sed 's/^/| /' conftest.$ac_ext >&5
14330
14331
14332 fi
14333
14334 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14335     fi
14336     if test $ac_cv_c_bigendian = unknown; then
14337       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14338       cat >conftest.$ac_ext <<_ACEOF
14339 /* confdefs.h.  */
14340 _ACEOF
14341 cat confdefs.h >>conftest.$ac_ext
14342 cat >>conftest.$ac_ext <<_ACEOF
14343 /* end confdefs.h.  */
14344 #include <limits.h>
14345
14346 int
14347 main ()
14348 {
14349 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14350               bogus endian macros
14351              #endif
14352
14353   ;
14354   return 0;
14355 }
14356 _ACEOF
14357 rm -f conftest.$ac_objext
14358 if { (ac_try="$ac_compile"
14359 case "(($ac_try" in
14360   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14361   *) ac_try_echo=$ac_try;;
14362 esac
14363 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14364 $as_echo "$ac_try_echo") >&5
14365   (eval "$ac_compile") 2>conftest.er1
14366   ac_status=$?
14367   grep -v '^ *+' conftest.er1 >conftest.err
14368   rm -f conftest.er1
14369   cat conftest.err >&5
14370   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14371   (exit $ac_status); } && {
14372          test -z "$ac_c_werror_flag" ||
14373          test ! -s conftest.err
14374        } && test -s conftest.$ac_objext; then
14375   # It does; now see whether it defined to _BIG_ENDIAN or not.
14376          cat >conftest.$ac_ext <<_ACEOF
14377 /* confdefs.h.  */
14378 _ACEOF
14379 cat confdefs.h >>conftest.$ac_ext
14380 cat >>conftest.$ac_ext <<_ACEOF
14381 /* end confdefs.h.  */
14382 #include <limits.h>
14383
14384 int
14385 main ()
14386 {
14387 #ifndef _BIG_ENDIAN
14388                  not big endian
14389                 #endif
14390
14391   ;
14392   return 0;
14393 }
14394 _ACEOF
14395 rm -f conftest.$ac_objext
14396 if { (ac_try="$ac_compile"
14397 case "(($ac_try" in
14398   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14399   *) ac_try_echo=$ac_try;;
14400 esac
14401 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14402 $as_echo "$ac_try_echo") >&5
14403   (eval "$ac_compile") 2>conftest.er1
14404   ac_status=$?
14405   grep -v '^ *+' conftest.er1 >conftest.err
14406   rm -f conftest.er1
14407   cat conftest.err >&5
14408   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14409   (exit $ac_status); } && {
14410          test -z "$ac_c_werror_flag" ||
14411          test ! -s conftest.err
14412        } && test -s conftest.$ac_objext; then
14413   ac_cv_c_bigendian=yes
14414 else
14415   $as_echo "$as_me: failed program was:" >&5
14416 sed 's/^/| /' conftest.$ac_ext >&5
14417
14418         ac_cv_c_bigendian=no
14419 fi
14420
14421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14422 else
14423   $as_echo "$as_me: failed program was:" >&5
14424 sed 's/^/| /' conftest.$ac_ext >&5
14425
14426
14427 fi
14428
14429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14430     fi
14431     if test $ac_cv_c_bigendian = unknown; then
14432       # Compile a test program.
14433       if test "$cross_compiling" = yes; then
14434   # Try to guess by grepping values from an object file.
14435          cat >conftest.$ac_ext <<_ACEOF
14436 /* confdefs.h.  */
14437 _ACEOF
14438 cat confdefs.h >>conftest.$ac_ext
14439 cat >>conftest.$ac_ext <<_ACEOF
14440 /* end confdefs.h.  */
14441 short int ascii_mm[] =
14442                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14443                 short int ascii_ii[] =
14444                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14445                 int use_ascii (int i) {
14446                   return ascii_mm[i] + ascii_ii[i];
14447                 }
14448                 short int ebcdic_ii[] =
14449                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14450                 short int ebcdic_mm[] =
14451                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14452                 int use_ebcdic (int i) {
14453                   return ebcdic_mm[i] + ebcdic_ii[i];
14454                 }
14455                 extern int foo;
14456
14457 int
14458 main ()
14459 {
14460 return use_ascii (foo) == use_ebcdic (foo);
14461   ;
14462   return 0;
14463 }
14464 _ACEOF
14465 rm -f conftest.$ac_objext
14466 if { (ac_try="$ac_compile"
14467 case "(($ac_try" in
14468   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14469   *) ac_try_echo=$ac_try;;
14470 esac
14471 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14472 $as_echo "$ac_try_echo") >&5
14473   (eval "$ac_compile") 2>conftest.er1
14474   ac_status=$?
14475   grep -v '^ *+' conftest.er1 >conftest.err
14476   rm -f conftest.er1
14477   cat conftest.err >&5
14478   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14479   (exit $ac_status); } && {
14480          test -z "$ac_c_werror_flag" ||
14481          test ! -s conftest.err
14482        } && test -s conftest.$ac_objext; then
14483   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14484               ac_cv_c_bigendian=yes
14485             fi
14486             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14487               if test "$ac_cv_c_bigendian" = unknown; then
14488                 ac_cv_c_bigendian=no
14489               else
14490                 # finding both strings is unlikely to happen, but who knows?
14491                 ac_cv_c_bigendian=unknown
14492               fi
14493             fi
14494 else
14495   $as_echo "$as_me: failed program was:" >&5
14496 sed 's/^/| /' conftest.$ac_ext >&5
14497
14498
14499 fi
14500
14501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14502 else
14503   cat >conftest.$ac_ext <<_ACEOF
14504 /* confdefs.h.  */
14505 _ACEOF
14506 cat confdefs.h >>conftest.$ac_ext
14507 cat >>conftest.$ac_ext <<_ACEOF
14508 /* end confdefs.h.  */
14509 $ac_includes_default
14510 int
14511 main ()
14512 {
14513
14514              /* Are we little or big endian?  From Harbison&Steele.  */
14515              union
14516              {
14517                long int l;
14518                char c[sizeof (long int)];
14519              } u;
14520              u.l = 1;
14521              return u.c[sizeof (long int) - 1] == 1;
14522
14523   ;
14524   return 0;
14525 }
14526 _ACEOF
14527 rm -f conftest$ac_exeext
14528 if { (ac_try="$ac_link"
14529 case "(($ac_try" in
14530   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14531   *) ac_try_echo=$ac_try;;
14532 esac
14533 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14534 $as_echo "$ac_try_echo") >&5
14535   (eval "$ac_link") 2>&5
14536   ac_status=$?
14537   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14538   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14539   { (case "(($ac_try" in
14540   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14541   *) ac_try_echo=$ac_try;;
14542 esac
14543 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14544 $as_echo "$ac_try_echo") >&5
14545   (eval "$ac_try") 2>&5
14546   ac_status=$?
14547   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14548   (exit $ac_status); }; }; then
14549   ac_cv_c_bigendian=no
14550 else
14551   $as_echo "$as_me: program exited with status $ac_status" >&5
14552 $as_echo "$as_me: failed program was:" >&5
14553 sed 's/^/| /' conftest.$ac_ext >&5
14554
14555 ( exit $ac_status )
14556 ac_cv_c_bigendian=yes
14557 fi
14558 rm -rf conftest.dSYM
14559 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14560 fi
14561
14562
14563     fi
14564 fi
14565 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14566 $as_echo "$ac_cv_c_bigendian" >&6; }
14567  case $ac_cv_c_bigendian in #(
14568    yes)
14569      cat >>confdefs.h <<\_ACEOF
14570 #define WORDS_BIGENDIAN 1
14571 _ACEOF
14572 ;; #(
14573    no)
14574       ;; #(
14575    universal)
14576
14577 cat >>confdefs.h <<\_ACEOF
14578 #define AC_APPLE_UNIVERSAL_BUILD 1
14579 _ACEOF
14580
14581      ;; #(
14582    *)
14583      { { $as_echo "$as_me:$LINENO: error: unknown endianness
14584  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14585 $as_echo "$as_me: error: unknown endianness
14586  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14587    { (exit 1); exit 1; }; } ;;
14588  esac
14589
14590 { $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14591 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14592 if test "${ac_cv_c_const+set}" = set; then
14593   $as_echo_n "(cached) " >&6
14594 else
14595   cat >conftest.$ac_ext <<_ACEOF
14596 /* confdefs.h.  */
14597 _ACEOF
14598 cat confdefs.h >>conftest.$ac_ext
14599 cat >>conftest.$ac_ext <<_ACEOF
14600 /* end confdefs.h.  */
14601
14602 int
14603 main ()
14604 {
14605 /* FIXME: Include the comments suggested by Paul. */
14606 #ifndef __cplusplus
14607   /* Ultrix mips cc rejects this.  */
14608   typedef int charset[2];
14609   const charset cs;
14610   /* SunOS 4.1.1 cc rejects this.  */
14611   char const *const *pcpcc;
14612   char **ppc;
14613   /* NEC SVR4.0.2 mips cc rejects this.  */
14614   struct point {int x, y;};
14615   static struct point const zero = {0,0};
14616   /* AIX XL C 1.02.0.0 rejects this.
14617      It does not let you subtract one const X* pointer from another in
14618      an arm of an if-expression whose if-part is not a constant
14619      expression */
14620   const char *g = "string";
14621   pcpcc = &g + (g ? g-g : 0);
14622   /* HPUX 7.0 cc rejects these. */
14623   ++pcpcc;
14624   ppc = (char**) pcpcc;
14625   pcpcc = (char const *const *) ppc;
14626   { /* SCO 3.2v4 cc rejects this.  */
14627     char *t;
14628     char const *s = 0 ? (char *) 0 : (char const *) 0;
14629
14630     *t++ = 0;
14631     if (s) return 0;
14632   }
14633   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14634     int x[] = {25, 17};
14635     const int *foo = &x[0];
14636     ++foo;
14637   }
14638   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14639     typedef const int *iptr;
14640     iptr p = 0;
14641     ++p;
14642   }
14643   { /* AIX XL C 1.02.0.0 rejects this saying
14644        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14645     struct s { int j; const int *ap[3]; };
14646     struct s *b; b->j = 5;
14647   }
14648   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14649     const int foo = 10;
14650     if (!foo) return 0;
14651   }
14652   return !cs[0] && !zero.x;
14653 #endif
14654
14655   ;
14656   return 0;
14657 }
14658 _ACEOF
14659 rm -f conftest.$ac_objext
14660 if { (ac_try="$ac_compile"
14661 case "(($ac_try" in
14662   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14663   *) ac_try_echo=$ac_try;;
14664 esac
14665 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14666 $as_echo "$ac_try_echo") >&5
14667   (eval "$ac_compile") 2>conftest.er1
14668   ac_status=$?
14669   grep -v '^ *+' conftest.er1 >conftest.err
14670   rm -f conftest.er1
14671   cat conftest.err >&5
14672   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14673   (exit $ac_status); } && {
14674          test -z "$ac_c_werror_flag" ||
14675          test ! -s conftest.err
14676        } && test -s conftest.$ac_objext; then
14677   ac_cv_c_const=yes
14678 else
14679   $as_echo "$as_me: failed program was:" >&5
14680 sed 's/^/| /' conftest.$ac_ext >&5
14681
14682         ac_cv_c_const=no
14683 fi
14684
14685 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14686 fi
14687 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14688 $as_echo "$ac_cv_c_const" >&6; }
14689 if test $ac_cv_c_const = no; then
14690
14691 cat >>confdefs.h <<\_ACEOF
14692 #define const /**/
14693 _ACEOF
14694
14695 fi
14696
14697 { $as_echo "$as_me:$LINENO: checking for inline" >&5
14698 $as_echo_n "checking for inline... " >&6; }
14699 if test "${ac_cv_c_inline+set}" = set; then
14700   $as_echo_n "(cached) " >&6
14701 else
14702   ac_cv_c_inline=no
14703 for ac_kw in inline __inline__ __inline; do
14704   cat >conftest.$ac_ext <<_ACEOF
14705 /* confdefs.h.  */
14706 _ACEOF
14707 cat confdefs.h >>conftest.$ac_ext
14708 cat >>conftest.$ac_ext <<_ACEOF
14709 /* end confdefs.h.  */
14710 #ifndef __cplusplus
14711 typedef int foo_t;
14712 static $ac_kw foo_t static_foo () {return 0; }
14713 $ac_kw foo_t foo () {return 0; }
14714 #endif
14715
14716 _ACEOF
14717 rm -f conftest.$ac_objext
14718 if { (ac_try="$ac_compile"
14719 case "(($ac_try" in
14720   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14721   *) ac_try_echo=$ac_try;;
14722 esac
14723 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14724 $as_echo "$ac_try_echo") >&5
14725   (eval "$ac_compile") 2>conftest.er1
14726   ac_status=$?
14727   grep -v '^ *+' conftest.er1 >conftest.err
14728   rm -f conftest.er1
14729   cat conftest.err >&5
14730   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14731   (exit $ac_status); } && {
14732          test -z "$ac_c_werror_flag" ||
14733          test ! -s conftest.err
14734        } && test -s conftest.$ac_objext; then
14735   ac_cv_c_inline=$ac_kw
14736 else
14737   $as_echo "$as_me: failed program was:" >&5
14738 sed 's/^/| /' conftest.$ac_ext >&5
14739
14740
14741 fi
14742
14743 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14744   test "$ac_cv_c_inline" != no && break
14745 done
14746
14747 fi
14748 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
14749 $as_echo "$ac_cv_c_inline" >&6; }
14750
14751
14752 case $ac_cv_c_inline in
14753   inline | yes) ;;
14754   *)
14755     case $ac_cv_c_inline in
14756       no) ac_val=;;
14757       *) ac_val=$ac_cv_c_inline;;
14758     esac
14759     cat >>confdefs.h <<_ACEOF
14760 #ifndef __cplusplus
14761 #define inline $ac_val
14762 #endif
14763 _ACEOF
14764     ;;
14765 esac
14766
14767 { $as_echo "$as_me:$LINENO: checking for quiet inline (no complaint if unreferenced)" >&5
14768 $as_echo_n "checking for quiet inline (no complaint if unreferenced)... " >&6; }
14769 if test "${pgac_cv_c_inline_quietly+set}" = set; then
14770   $as_echo_n "(cached) " >&6
14771 else
14772   pgac_cv_c_inline_quietly=no
14773   if test "$ac_cv_c_inline" != no; then
14774     pgac_c_inline_save_werror=$ac_c_werror_flag
14775     ac_c_werror_flag=yes
14776     cat >conftest.$ac_ext <<_ACEOF
14777 /* confdefs.h.  */
14778 _ACEOF
14779 cat confdefs.h >>conftest.$ac_ext
14780 cat >>conftest.$ac_ext <<_ACEOF
14781 /* end confdefs.h.  */
14782 static inline int fun () {return 0;}
14783 int
14784 main ()
14785 {
14786
14787   ;
14788   return 0;
14789 }
14790 _ACEOF
14791 rm -f conftest.$ac_objext conftest$ac_exeext
14792 if { (ac_try="$ac_link"
14793 case "(($ac_try" in
14794   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14795   *) ac_try_echo=$ac_try;;
14796 esac
14797 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14798 $as_echo "$ac_try_echo") >&5
14799   (eval "$ac_link") 2>conftest.er1
14800   ac_status=$?
14801   grep -v '^ *+' conftest.er1 >conftest.err
14802   rm -f conftest.er1
14803   cat conftest.err >&5
14804   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14805   (exit $ac_status); } && {
14806          test -z "$ac_c_werror_flag" ||
14807          test ! -s conftest.err
14808        } && test -s conftest$ac_exeext && {
14809          test "$cross_compiling" = yes ||
14810          $as_test_x conftest$ac_exeext
14811        }; then
14812   pgac_cv_c_inline_quietly=yes
14813 else
14814   $as_echo "$as_me: failed program was:" >&5
14815 sed 's/^/| /' conftest.$ac_ext >&5
14816
14817
14818 fi
14819
14820 rm -rf conftest.dSYM
14821 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14822       conftest$ac_exeext conftest.$ac_ext
14823     ac_c_werror_flag=$pgac_c_inline_save_werror
14824   fi
14825 fi
14826 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_inline_quietly" >&5
14827 $as_echo "$pgac_cv_c_inline_quietly" >&6; }
14828 if test "$pgac_cv_c_inline_quietly" != no; then
14829
14830 cat >>confdefs.h <<_ACEOF
14831 #define USE_INLINE 1
14832 _ACEOF
14833
14834 fi
14835
14836 { $as_echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
14837 $as_echo_n "checking for preprocessor stringizing operator... " >&6; }
14838 if test "${ac_cv_c_stringize+set}" = set; then
14839   $as_echo_n "(cached) " >&6
14840 else
14841   cat >conftest.$ac_ext <<_ACEOF
14842 /* confdefs.h.  */
14843 _ACEOF
14844 cat confdefs.h >>conftest.$ac_ext
14845 cat >>conftest.$ac_ext <<_ACEOF
14846 /* end confdefs.h.  */
14847 #define x(y) #y
14848
14849 char *s = x(teststring);
14850 _ACEOF
14851 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14852   $EGREP "#teststring" >/dev/null 2>&1; then
14853   ac_cv_c_stringize=no
14854 else
14855   ac_cv_c_stringize=yes
14856 fi
14857 rm -f conftest*
14858
14859 fi
14860 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
14861 $as_echo "$ac_cv_c_stringize" >&6; }
14862 if test $ac_cv_c_stringize = yes; then
14863
14864 cat >>confdefs.h <<\_ACEOF
14865 #define HAVE_STRINGIZE 1
14866 _ACEOF
14867
14868 fi
14869
14870 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
14871 $as_echo_n "checking for signed types... " >&6; }
14872 if test "${pgac_cv_c_signed+set}" = set; then
14873   $as_echo_n "(cached) " >&6
14874 else
14875   cat >conftest.$ac_ext <<_ACEOF
14876 /* confdefs.h.  */
14877 _ACEOF
14878 cat confdefs.h >>conftest.$ac_ext
14879 cat >>conftest.$ac_ext <<_ACEOF
14880 /* end confdefs.h.  */
14881
14882 int
14883 main ()
14884 {
14885 signed char c; signed short s; signed int i;
14886   ;
14887   return 0;
14888 }
14889 _ACEOF
14890 rm -f conftest.$ac_objext
14891 if { (ac_try="$ac_compile"
14892 case "(($ac_try" in
14893   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14894   *) ac_try_echo=$ac_try;;
14895 esac
14896 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14897 $as_echo "$ac_try_echo") >&5
14898   (eval "$ac_compile") 2>conftest.er1
14899   ac_status=$?
14900   grep -v '^ *+' conftest.er1 >conftest.err
14901   rm -f conftest.er1
14902   cat conftest.err >&5
14903   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14904   (exit $ac_status); } && {
14905          test -z "$ac_c_werror_flag" ||
14906          test ! -s conftest.err
14907        } && test -s conftest.$ac_objext; then
14908   pgac_cv_c_signed=yes
14909 else
14910   $as_echo "$as_me: failed program was:" >&5
14911 sed 's/^/| /' conftest.$ac_ext >&5
14912
14913         pgac_cv_c_signed=no
14914 fi
14915
14916 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14917 fi
14918 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
14919 $as_echo "$pgac_cv_c_signed" >&6; }
14920 if test x"$pgac_cv_c_signed" = xno ; then
14921
14922 cat >>confdefs.h <<\_ACEOF
14923 #define signed /**/
14924 _ACEOF
14925
14926 fi
14927 { $as_echo "$as_me:$LINENO: checking for working volatile" >&5
14928 $as_echo_n "checking for working volatile... " >&6; }
14929 if test "${ac_cv_c_volatile+set}" = set; then
14930   $as_echo_n "(cached) " >&6
14931 else
14932   cat >conftest.$ac_ext <<_ACEOF
14933 /* confdefs.h.  */
14934 _ACEOF
14935 cat confdefs.h >>conftest.$ac_ext
14936 cat >>conftest.$ac_ext <<_ACEOF
14937 /* end confdefs.h.  */
14938
14939 int
14940 main ()
14941 {
14942
14943 volatile int x;
14944 int * volatile y = (int *) 0;
14945 return !x && !y;
14946   ;
14947   return 0;
14948 }
14949 _ACEOF
14950 rm -f conftest.$ac_objext
14951 if { (ac_try="$ac_compile"
14952 case "(($ac_try" in
14953   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14954   *) ac_try_echo=$ac_try;;
14955 esac
14956 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14957 $as_echo "$ac_try_echo") >&5
14958   (eval "$ac_compile") 2>conftest.er1
14959   ac_status=$?
14960   grep -v '^ *+' conftest.er1 >conftest.err
14961   rm -f conftest.er1
14962   cat conftest.err >&5
14963   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14964   (exit $ac_status); } && {
14965          test -z "$ac_c_werror_flag" ||
14966          test ! -s conftest.err
14967        } && test -s conftest.$ac_objext; then
14968   ac_cv_c_volatile=yes
14969 else
14970   $as_echo "$as_me: failed program was:" >&5
14971 sed 's/^/| /' conftest.$ac_ext >&5
14972
14973         ac_cv_c_volatile=no
14974 fi
14975
14976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14977 fi
14978 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
14979 $as_echo "$ac_cv_c_volatile" >&6; }
14980 if test $ac_cv_c_volatile = no; then
14981
14982 cat >>confdefs.h <<\_ACEOF
14983 #define volatile /**/
14984 _ACEOF
14985
14986 fi
14987
14988 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
14989 $as_echo_n "checking for __func__... " >&6; }
14990 if test "${pgac_cv_funcname_func_support+set}" = set; then
14991   $as_echo_n "(cached) " >&6
14992 else
14993   cat >conftest.$ac_ext <<_ACEOF
14994 /* confdefs.h.  */
14995 _ACEOF
14996 cat confdefs.h >>conftest.$ac_ext
14997 cat >>conftest.$ac_ext <<_ACEOF
14998 /* end confdefs.h.  */
14999 #include <stdio.h>
15000 int
15001 main ()
15002 {
15003 printf("%s\n", __func__);
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 ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15015 $as_echo "$ac_try_echo") >&5
15016   (eval "$ac_compile") 2>conftest.er1
15017   ac_status=$?
15018   grep -v '^ *+' conftest.er1 >conftest.err
15019   rm -f conftest.er1
15020   cat conftest.err >&5
15021   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15022   (exit $ac_status); } && {
15023          test -z "$ac_c_werror_flag" ||
15024          test ! -s conftest.err
15025        } && test -s conftest.$ac_objext; then
15026   pgac_cv_funcname_func_support=yes
15027 else
15028   $as_echo "$as_me: failed program was:" >&5
15029 sed 's/^/| /' conftest.$ac_ext >&5
15030
15031         pgac_cv_funcname_func_support=no
15032 fi
15033
15034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15035 fi
15036 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
15037 $as_echo "$pgac_cv_funcname_func_support" >&6; }
15038 if test x"$pgac_cv_funcname_func_support" = xyes ; then
15039
15040 cat >>confdefs.h <<\_ACEOF
15041 #define HAVE_FUNCNAME__FUNC 1
15042 _ACEOF
15043
15044 else
15045 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
15046 $as_echo_n "checking for __FUNCTION__... " >&6; }
15047 if test "${pgac_cv_funcname_function_support+set}" = set; then
15048   $as_echo_n "(cached) " >&6
15049 else
15050   cat >conftest.$ac_ext <<_ACEOF
15051 /* confdefs.h.  */
15052 _ACEOF
15053 cat confdefs.h >>conftest.$ac_ext
15054 cat >>conftest.$ac_ext <<_ACEOF
15055 /* end confdefs.h.  */
15056 #include <stdio.h>
15057 int
15058 main ()
15059 {
15060 printf("%s\n", __FUNCTION__);
15061   ;
15062   return 0;
15063 }
15064 _ACEOF
15065 rm -f conftest.$ac_objext
15066 if { (ac_try="$ac_compile"
15067 case "(($ac_try" in
15068   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15069   *) ac_try_echo=$ac_try;;
15070 esac
15071 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15072 $as_echo "$ac_try_echo") >&5
15073   (eval "$ac_compile") 2>conftest.er1
15074   ac_status=$?
15075   grep -v '^ *+' conftest.er1 >conftest.err
15076   rm -f conftest.er1
15077   cat conftest.err >&5
15078   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15079   (exit $ac_status); } && {
15080          test -z "$ac_c_werror_flag" ||
15081          test ! -s conftest.err
15082        } && test -s conftest.$ac_objext; then
15083   pgac_cv_funcname_function_support=yes
15084 else
15085   $as_echo "$as_me: failed program was:" >&5
15086 sed 's/^/| /' conftest.$ac_ext >&5
15087
15088         pgac_cv_funcname_function_support=no
15089 fi
15090
15091 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15092 fi
15093 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
15094 $as_echo "$pgac_cv_funcname_function_support" >&6; }
15095 if test x"$pgac_cv_funcname_function_support" = xyes ; then
15096
15097 cat >>confdefs.h <<\_ACEOF
15098 #define HAVE_FUNCNAME__FUNCTION 1
15099 _ACEOF
15100
15101 fi
15102 fi
15103 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
15104 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
15105 if test "${ac_cv_struct_tm+set}" = set; then
15106   $as_echo_n "(cached) " >&6
15107 else
15108   cat >conftest.$ac_ext <<_ACEOF
15109 /* confdefs.h.  */
15110 _ACEOF
15111 cat confdefs.h >>conftest.$ac_ext
15112 cat >>conftest.$ac_ext <<_ACEOF
15113 /* end confdefs.h.  */
15114 #include <sys/types.h>
15115 #include <time.h>
15116
15117 int
15118 main ()
15119 {
15120 struct tm tm;
15121                                      int *p = &tm.tm_sec;
15122                                      return !p;
15123   ;
15124   return 0;
15125 }
15126 _ACEOF
15127 rm -f conftest.$ac_objext
15128 if { (ac_try="$ac_compile"
15129 case "(($ac_try" in
15130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15131   *) ac_try_echo=$ac_try;;
15132 esac
15133 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15134 $as_echo "$ac_try_echo") >&5
15135   (eval "$ac_compile") 2>conftest.er1
15136   ac_status=$?
15137   grep -v '^ *+' conftest.er1 >conftest.err
15138   rm -f conftest.er1
15139   cat conftest.err >&5
15140   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15141   (exit $ac_status); } && {
15142          test -z "$ac_c_werror_flag" ||
15143          test ! -s conftest.err
15144        } && test -s conftest.$ac_objext; then
15145   ac_cv_struct_tm=time.h
15146 else
15147   $as_echo "$as_me: failed program was:" >&5
15148 sed 's/^/| /' conftest.$ac_ext >&5
15149
15150         ac_cv_struct_tm=sys/time.h
15151 fi
15152
15153 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15154 fi
15155 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
15156 $as_echo "$ac_cv_struct_tm" >&6; }
15157 if test $ac_cv_struct_tm = sys/time.h; then
15158
15159 cat >>confdefs.h <<\_ACEOF
15160 #define TM_IN_SYS_TIME 1
15161 _ACEOF
15162
15163 fi
15164
15165 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
15166 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
15167 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
15168   $as_echo_n "(cached) " >&6
15169 else
15170   cat >conftest.$ac_ext <<_ACEOF
15171 /* confdefs.h.  */
15172 _ACEOF
15173 cat confdefs.h >>conftest.$ac_ext
15174 cat >>conftest.$ac_ext <<_ACEOF
15175 /* end confdefs.h.  */
15176 #include <sys/types.h>
15177 #include <$ac_cv_struct_tm>
15178
15179
15180 int
15181 main ()
15182 {
15183 static struct tm ac_aggr;
15184 if (ac_aggr.tm_zone)
15185 return 0;
15186   ;
15187   return 0;
15188 }
15189 _ACEOF
15190 rm -f conftest.$ac_objext
15191 if { (ac_try="$ac_compile"
15192 case "(($ac_try" in
15193   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15194   *) ac_try_echo=$ac_try;;
15195 esac
15196 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15197 $as_echo "$ac_try_echo") >&5
15198   (eval "$ac_compile") 2>conftest.er1
15199   ac_status=$?
15200   grep -v '^ *+' conftest.er1 >conftest.err
15201   rm -f conftest.er1
15202   cat conftest.err >&5
15203   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15204   (exit $ac_status); } && {
15205          test -z "$ac_c_werror_flag" ||
15206          test ! -s conftest.err
15207        } && test -s conftest.$ac_objext; then
15208   ac_cv_member_struct_tm_tm_zone=yes
15209 else
15210   $as_echo "$as_me: failed program was:" >&5
15211 sed 's/^/| /' conftest.$ac_ext >&5
15212
15213         cat >conftest.$ac_ext <<_ACEOF
15214 /* confdefs.h.  */
15215 _ACEOF
15216 cat confdefs.h >>conftest.$ac_ext
15217 cat >>conftest.$ac_ext <<_ACEOF
15218 /* end confdefs.h.  */
15219 #include <sys/types.h>
15220 #include <$ac_cv_struct_tm>
15221
15222
15223 int
15224 main ()
15225 {
15226 static struct tm ac_aggr;
15227 if (sizeof ac_aggr.tm_zone)
15228 return 0;
15229   ;
15230   return 0;
15231 }
15232 _ACEOF
15233 rm -f conftest.$ac_objext
15234 if { (ac_try="$ac_compile"
15235 case "(($ac_try" in
15236   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15237   *) ac_try_echo=$ac_try;;
15238 esac
15239 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15240 $as_echo "$ac_try_echo") >&5
15241   (eval "$ac_compile") 2>conftest.er1
15242   ac_status=$?
15243   grep -v '^ *+' conftest.er1 >conftest.err
15244   rm -f conftest.er1
15245   cat conftest.err >&5
15246   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15247   (exit $ac_status); } && {
15248          test -z "$ac_c_werror_flag" ||
15249          test ! -s conftest.err
15250        } && test -s conftest.$ac_objext; then
15251   ac_cv_member_struct_tm_tm_zone=yes
15252 else
15253   $as_echo "$as_me: failed program was:" >&5
15254 sed 's/^/| /' conftest.$ac_ext >&5
15255
15256         ac_cv_member_struct_tm_tm_zone=no
15257 fi
15258
15259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15260 fi
15261
15262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15263 fi
15264 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
15265 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
15266 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
15267
15268 cat >>confdefs.h <<_ACEOF
15269 #define HAVE_STRUCT_TM_TM_ZONE 1
15270 _ACEOF
15271
15272
15273 fi
15274
15275 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15276
15277 cat >>confdefs.h <<\_ACEOF
15278 #define HAVE_TM_ZONE 1
15279 _ACEOF
15280
15281 fi
15282 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
15283 $as_echo_n "checking for tzname... " >&6; }
15284 if test "${ac_cv_var_tzname+set}" = set; then
15285   $as_echo_n "(cached) " >&6
15286 else
15287   cat >conftest.$ac_ext <<_ACEOF
15288 /* confdefs.h.  */
15289 _ACEOF
15290 cat confdefs.h >>conftest.$ac_ext
15291 cat >>conftest.$ac_ext <<_ACEOF
15292 /* end confdefs.h.  */
15293 #include <time.h>
15294 #ifndef tzname /* For SGI.  */
15295 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
15296 #endif
15297
15298 int
15299 main ()
15300 {
15301 atoi(*tzname);
15302   ;
15303   return 0;
15304 }
15305 _ACEOF
15306 rm -f conftest.$ac_objext conftest$ac_exeext
15307 if { (ac_try="$ac_link"
15308 case "(($ac_try" in
15309   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15310   *) ac_try_echo=$ac_try;;
15311 esac
15312 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15313 $as_echo "$ac_try_echo") >&5
15314   (eval "$ac_link") 2>conftest.er1
15315   ac_status=$?
15316   grep -v '^ *+' conftest.er1 >conftest.err
15317   rm -f conftest.er1
15318   cat conftest.err >&5
15319   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15320   (exit $ac_status); } && {
15321          test -z "$ac_c_werror_flag" ||
15322          test ! -s conftest.err
15323        } && test -s conftest$ac_exeext && {
15324          test "$cross_compiling" = yes ||
15325          $as_test_x conftest$ac_exeext
15326        }; then
15327   ac_cv_var_tzname=yes
15328 else
15329   $as_echo "$as_me: failed program was:" >&5
15330 sed 's/^/| /' conftest.$ac_ext >&5
15331
15332         ac_cv_var_tzname=no
15333 fi
15334
15335 rm -rf conftest.dSYM
15336 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15337       conftest$ac_exeext conftest.$ac_ext
15338 fi
15339 { $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
15340 $as_echo "$ac_cv_var_tzname" >&6; }
15341 if test $ac_cv_var_tzname = yes; then
15342
15343 cat >>confdefs.h <<\_ACEOF
15344 #define HAVE_TZNAME 1
15345 _ACEOF
15346
15347 fi
15348
15349 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
15350 $as_echo_n "checking for union semun... " >&6; }
15351 if test "${ac_cv_type_union_semun+set}" = set; then
15352   $as_echo_n "(cached) " >&6
15353 else
15354   ac_cv_type_union_semun=no
15355 cat >conftest.$ac_ext <<_ACEOF
15356 /* confdefs.h.  */
15357 _ACEOF
15358 cat confdefs.h >>conftest.$ac_ext
15359 cat >>conftest.$ac_ext <<_ACEOF
15360 /* end confdefs.h.  */
15361 #include <sys/types.h>
15362 #include <sys/ipc.h>
15363 #include <sys/sem.h>
15364
15365 int
15366 main ()
15367 {
15368 if (sizeof (union semun))
15369        return 0;
15370   ;
15371   return 0;
15372 }
15373 _ACEOF
15374 rm -f conftest.$ac_objext
15375 if { (ac_try="$ac_compile"
15376 case "(($ac_try" in
15377   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15378   *) ac_try_echo=$ac_try;;
15379 esac
15380 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15381 $as_echo "$ac_try_echo") >&5
15382   (eval "$ac_compile") 2>conftest.er1
15383   ac_status=$?
15384   grep -v '^ *+' conftest.er1 >conftest.err
15385   rm -f conftest.er1
15386   cat conftest.err >&5
15387   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15388   (exit $ac_status); } && {
15389          test -z "$ac_c_werror_flag" ||
15390          test ! -s conftest.err
15391        } && test -s conftest.$ac_objext; then
15392   cat >conftest.$ac_ext <<_ACEOF
15393 /* confdefs.h.  */
15394 _ACEOF
15395 cat confdefs.h >>conftest.$ac_ext
15396 cat >>conftest.$ac_ext <<_ACEOF
15397 /* end confdefs.h.  */
15398 #include <sys/types.h>
15399 #include <sys/ipc.h>
15400 #include <sys/sem.h>
15401
15402 int
15403 main ()
15404 {
15405 if (sizeof ((union semun)))
15406           return 0;
15407   ;
15408   return 0;
15409 }
15410 _ACEOF
15411 rm -f conftest.$ac_objext
15412 if { (ac_try="$ac_compile"
15413 case "(($ac_try" in
15414   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15415   *) ac_try_echo=$ac_try;;
15416 esac
15417 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15418 $as_echo "$ac_try_echo") >&5
15419   (eval "$ac_compile") 2>conftest.er1
15420   ac_status=$?
15421   grep -v '^ *+' conftest.er1 >conftest.err
15422   rm -f conftest.er1
15423   cat conftest.err >&5
15424   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15425   (exit $ac_status); } && {
15426          test -z "$ac_c_werror_flag" ||
15427          test ! -s conftest.err
15428        } && test -s conftest.$ac_objext; then
15429   :
15430 else
15431   $as_echo "$as_me: failed program was:" >&5
15432 sed 's/^/| /' conftest.$ac_ext >&5
15433
15434         ac_cv_type_union_semun=yes
15435 fi
15436
15437 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15438 else
15439   $as_echo "$as_me: failed program was:" >&5
15440 sed 's/^/| /' conftest.$ac_ext >&5
15441
15442
15443 fi
15444
15445 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15446 fi
15447 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
15448 $as_echo "$ac_cv_type_union_semun" >&6; }
15449 if test "x$ac_cv_type_union_semun" = x""yes; then
15450
15451 cat >>confdefs.h <<_ACEOF
15452 #define HAVE_UNION_SEMUN 1
15453 _ACEOF
15454
15455
15456 fi
15457
15458 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
15459 $as_echo_n "checking for struct sockaddr_un... " >&6; }
15460 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
15461   $as_echo_n "(cached) " >&6
15462 else
15463   ac_cv_type_struct_sockaddr_un=no
15464 cat >conftest.$ac_ext <<_ACEOF
15465 /* confdefs.h.  */
15466 _ACEOF
15467 cat confdefs.h >>conftest.$ac_ext
15468 cat >>conftest.$ac_ext <<_ACEOF
15469 /* end confdefs.h.  */
15470 #include <sys/types.h>
15471 #ifdef HAVE_SYS_UN_H
15472 #include <sys/un.h>
15473 #endif
15474
15475
15476 int
15477 main ()
15478 {
15479 if (sizeof (struct sockaddr_un))
15480        return 0;
15481   ;
15482   return 0;
15483 }
15484 _ACEOF
15485 rm -f conftest.$ac_objext
15486 if { (ac_try="$ac_compile"
15487 case "(($ac_try" in
15488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15489   *) ac_try_echo=$ac_try;;
15490 esac
15491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15492 $as_echo "$ac_try_echo") >&5
15493   (eval "$ac_compile") 2>conftest.er1
15494   ac_status=$?
15495   grep -v '^ *+' conftest.er1 >conftest.err
15496   rm -f conftest.er1
15497   cat conftest.err >&5
15498   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15499   (exit $ac_status); } && {
15500          test -z "$ac_c_werror_flag" ||
15501          test ! -s conftest.err
15502        } && test -s conftest.$ac_objext; then
15503   cat >conftest.$ac_ext <<_ACEOF
15504 /* confdefs.h.  */
15505 _ACEOF
15506 cat confdefs.h >>conftest.$ac_ext
15507 cat >>conftest.$ac_ext <<_ACEOF
15508 /* end confdefs.h.  */
15509 #include <sys/types.h>
15510 #ifdef HAVE_SYS_UN_H
15511 #include <sys/un.h>
15512 #endif
15513
15514
15515 int
15516 main ()
15517 {
15518 if (sizeof ((struct sockaddr_un)))
15519           return 0;
15520   ;
15521   return 0;
15522 }
15523 _ACEOF
15524 rm -f conftest.$ac_objext
15525 if { (ac_try="$ac_compile"
15526 case "(($ac_try" in
15527   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15528   *) ac_try_echo=$ac_try;;
15529 esac
15530 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15531 $as_echo "$ac_try_echo") >&5
15532   (eval "$ac_compile") 2>conftest.er1
15533   ac_status=$?
15534   grep -v '^ *+' conftest.er1 >conftest.err
15535   rm -f conftest.er1
15536   cat conftest.err >&5
15537   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15538   (exit $ac_status); } && {
15539          test -z "$ac_c_werror_flag" ||
15540          test ! -s conftest.err
15541        } && test -s conftest.$ac_objext; then
15542   :
15543 else
15544   $as_echo "$as_me: failed program was:" >&5
15545 sed 's/^/| /' conftest.$ac_ext >&5
15546
15547         ac_cv_type_struct_sockaddr_un=yes
15548 fi
15549
15550 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15551 else
15552   $as_echo "$as_me: failed program was:" >&5
15553 sed 's/^/| /' conftest.$ac_ext >&5
15554
15555
15556 fi
15557
15558 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15559 fi
15560 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
15561 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
15562 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
15563
15564 cat >>confdefs.h <<_ACEOF
15565 #define HAVE_STRUCT_SOCKADDR_UN 1
15566 _ACEOF
15567
15568
15569 cat >>confdefs.h <<\_ACEOF
15570 #define HAVE_UNIX_SOCKETS 1
15571 _ACEOF
15572
15573 fi
15574
15575 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
15576 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
15577 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
15578   $as_echo_n "(cached) " >&6
15579 else
15580   ac_cv_type_struct_sockaddr_storage=no
15581 cat >conftest.$ac_ext <<_ACEOF
15582 /* confdefs.h.  */
15583 _ACEOF
15584 cat confdefs.h >>conftest.$ac_ext
15585 cat >>conftest.$ac_ext <<_ACEOF
15586 /* end confdefs.h.  */
15587 #include <sys/types.h>
15588 #ifdef HAVE_SYS_SOCKET_H
15589 #include <sys/socket.h>
15590 #endif
15591
15592
15593 int
15594 main ()
15595 {
15596 if (sizeof (struct sockaddr_storage))
15597        return 0;
15598   ;
15599   return 0;
15600 }
15601 _ACEOF
15602 rm -f conftest.$ac_objext
15603 if { (ac_try="$ac_compile"
15604 case "(($ac_try" in
15605   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15606   *) ac_try_echo=$ac_try;;
15607 esac
15608 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15609 $as_echo "$ac_try_echo") >&5
15610   (eval "$ac_compile") 2>conftest.er1
15611   ac_status=$?
15612   grep -v '^ *+' conftest.er1 >conftest.err
15613   rm -f conftest.er1
15614   cat conftest.err >&5
15615   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15616   (exit $ac_status); } && {
15617          test -z "$ac_c_werror_flag" ||
15618          test ! -s conftest.err
15619        } && test -s conftest.$ac_objext; then
15620   cat >conftest.$ac_ext <<_ACEOF
15621 /* confdefs.h.  */
15622 _ACEOF
15623 cat confdefs.h >>conftest.$ac_ext
15624 cat >>conftest.$ac_ext <<_ACEOF
15625 /* end confdefs.h.  */
15626 #include <sys/types.h>
15627 #ifdef HAVE_SYS_SOCKET_H
15628 #include <sys/socket.h>
15629 #endif
15630
15631
15632 int
15633 main ()
15634 {
15635 if (sizeof ((struct sockaddr_storage)))
15636           return 0;
15637   ;
15638   return 0;
15639 }
15640 _ACEOF
15641 rm -f conftest.$ac_objext
15642 if { (ac_try="$ac_compile"
15643 case "(($ac_try" in
15644   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15645   *) ac_try_echo=$ac_try;;
15646 esac
15647 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15648 $as_echo "$ac_try_echo") >&5
15649   (eval "$ac_compile") 2>conftest.er1
15650   ac_status=$?
15651   grep -v '^ *+' conftest.er1 >conftest.err
15652   rm -f conftest.er1
15653   cat conftest.err >&5
15654   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15655   (exit $ac_status); } && {
15656          test -z "$ac_c_werror_flag" ||
15657          test ! -s conftest.err
15658        } && test -s conftest.$ac_objext; then
15659   :
15660 else
15661   $as_echo "$as_me: failed program was:" >&5
15662 sed 's/^/| /' conftest.$ac_ext >&5
15663
15664         ac_cv_type_struct_sockaddr_storage=yes
15665 fi
15666
15667 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15668 else
15669   $as_echo "$as_me: failed program was:" >&5
15670 sed 's/^/| /' conftest.$ac_ext >&5
15671
15672
15673 fi
15674
15675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15676 fi
15677 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
15678 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
15679 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
15680
15681 cat >>confdefs.h <<_ACEOF
15682 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
15683 _ACEOF
15684
15685
15686 fi
15687
15688 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
15689 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
15690 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
15691   $as_echo_n "(cached) " >&6
15692 else
15693   cat >conftest.$ac_ext <<_ACEOF
15694 /* confdefs.h.  */
15695 _ACEOF
15696 cat confdefs.h >>conftest.$ac_ext
15697 cat >>conftest.$ac_ext <<_ACEOF
15698 /* end confdefs.h.  */
15699 #include <sys/types.h>
15700 #ifdef HAVE_SYS_SOCKET_H
15701 #include <sys/socket.h>
15702 #endif
15703
15704
15705 int
15706 main ()
15707 {
15708 static struct sockaddr_storage ac_aggr;
15709 if (ac_aggr.ss_family)
15710 return 0;
15711   ;
15712   return 0;
15713 }
15714 _ACEOF
15715 rm -f conftest.$ac_objext
15716 if { (ac_try="$ac_compile"
15717 case "(($ac_try" in
15718   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15719   *) ac_try_echo=$ac_try;;
15720 esac
15721 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15722 $as_echo "$ac_try_echo") >&5
15723   (eval "$ac_compile") 2>conftest.er1
15724   ac_status=$?
15725   grep -v '^ *+' conftest.er1 >conftest.err
15726   rm -f conftest.er1
15727   cat conftest.err >&5
15728   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15729   (exit $ac_status); } && {
15730          test -z "$ac_c_werror_flag" ||
15731          test ! -s conftest.err
15732        } && test -s conftest.$ac_objext; then
15733   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15734 else
15735   $as_echo "$as_me: failed program was:" >&5
15736 sed 's/^/| /' conftest.$ac_ext >&5
15737
15738         cat >conftest.$ac_ext <<_ACEOF
15739 /* confdefs.h.  */
15740 _ACEOF
15741 cat confdefs.h >>conftest.$ac_ext
15742 cat >>conftest.$ac_ext <<_ACEOF
15743 /* end confdefs.h.  */
15744 #include <sys/types.h>
15745 #ifdef HAVE_SYS_SOCKET_H
15746 #include <sys/socket.h>
15747 #endif
15748
15749
15750 int
15751 main ()
15752 {
15753 static struct sockaddr_storage ac_aggr;
15754 if (sizeof ac_aggr.ss_family)
15755 return 0;
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 ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15767 $as_echo "$ac_try_echo") >&5
15768   (eval "$ac_compile") 2>conftest.er1
15769   ac_status=$?
15770   grep -v '^ *+' conftest.er1 >conftest.err
15771   rm -f conftest.er1
15772   cat conftest.err >&5
15773   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15774   (exit $ac_status); } && {
15775          test -z "$ac_c_werror_flag" ||
15776          test ! -s conftest.err
15777        } && test -s conftest.$ac_objext; then
15778   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15779 else
15780   $as_echo "$as_me: failed program was:" >&5
15781 sed 's/^/| /' conftest.$ac_ext >&5
15782
15783         ac_cv_member_struct_sockaddr_storage_ss_family=no
15784 fi
15785
15786 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15787 fi
15788
15789 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15790 fi
15791 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
15792 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
15793 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
15794
15795 cat >>confdefs.h <<_ACEOF
15796 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
15797 _ACEOF
15798
15799
15800 fi
15801 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
15802 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
15803 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
15804   $as_echo_n "(cached) " >&6
15805 else
15806   cat >conftest.$ac_ext <<_ACEOF
15807 /* confdefs.h.  */
15808 _ACEOF
15809 cat confdefs.h >>conftest.$ac_ext
15810 cat >>conftest.$ac_ext <<_ACEOF
15811 /* end confdefs.h.  */
15812 #include <sys/types.h>
15813 #ifdef HAVE_SYS_SOCKET_H
15814 #include <sys/socket.h>
15815 #endif
15816
15817
15818 int
15819 main ()
15820 {
15821 static struct sockaddr_storage ac_aggr;
15822 if (ac_aggr.__ss_family)
15823 return 0;
15824   ;
15825   return 0;
15826 }
15827 _ACEOF
15828 rm -f conftest.$ac_objext
15829 if { (ac_try="$ac_compile"
15830 case "(($ac_try" in
15831   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15832   *) ac_try_echo=$ac_try;;
15833 esac
15834 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15835 $as_echo "$ac_try_echo") >&5
15836   (eval "$ac_compile") 2>conftest.er1
15837   ac_status=$?
15838   grep -v '^ *+' conftest.er1 >conftest.err
15839   rm -f conftest.er1
15840   cat conftest.err >&5
15841   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15842   (exit $ac_status); } && {
15843          test -z "$ac_c_werror_flag" ||
15844          test ! -s conftest.err
15845        } && test -s conftest.$ac_objext; then
15846   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15847 else
15848   $as_echo "$as_me: failed program was:" >&5
15849 sed 's/^/| /' conftest.$ac_ext >&5
15850
15851         cat >conftest.$ac_ext <<_ACEOF
15852 /* confdefs.h.  */
15853 _ACEOF
15854 cat confdefs.h >>conftest.$ac_ext
15855 cat >>conftest.$ac_ext <<_ACEOF
15856 /* end confdefs.h.  */
15857 #include <sys/types.h>
15858 #ifdef HAVE_SYS_SOCKET_H
15859 #include <sys/socket.h>
15860 #endif
15861
15862
15863 int
15864 main ()
15865 {
15866 static struct sockaddr_storage ac_aggr;
15867 if (sizeof ac_aggr.__ss_family)
15868 return 0;
15869   ;
15870   return 0;
15871 }
15872 _ACEOF
15873 rm -f conftest.$ac_objext
15874 if { (ac_try="$ac_compile"
15875 case "(($ac_try" in
15876   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15877   *) ac_try_echo=$ac_try;;
15878 esac
15879 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15880 $as_echo "$ac_try_echo") >&5
15881   (eval "$ac_compile") 2>conftest.er1
15882   ac_status=$?
15883   grep -v '^ *+' conftest.er1 >conftest.err
15884   rm -f conftest.er1
15885   cat conftest.err >&5
15886   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15887   (exit $ac_status); } && {
15888          test -z "$ac_c_werror_flag" ||
15889          test ! -s conftest.err
15890        } && test -s conftest.$ac_objext; then
15891   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15892 else
15893   $as_echo "$as_me: failed program was:" >&5
15894 sed 's/^/| /' conftest.$ac_ext >&5
15895
15896         ac_cv_member_struct_sockaddr_storage___ss_family=no
15897 fi
15898
15899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15900 fi
15901
15902 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15903 fi
15904 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
15905 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
15906 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
15907
15908 cat >>confdefs.h <<_ACEOF
15909 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
15910 _ACEOF
15911
15912
15913 fi
15914 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
15915 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
15916 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
15917   $as_echo_n "(cached) " >&6
15918 else
15919   cat >conftest.$ac_ext <<_ACEOF
15920 /* confdefs.h.  */
15921 _ACEOF
15922 cat confdefs.h >>conftest.$ac_ext
15923 cat >>conftest.$ac_ext <<_ACEOF
15924 /* end confdefs.h.  */
15925 #include <sys/types.h>
15926 #ifdef HAVE_SYS_SOCKET_H
15927 #include <sys/socket.h>
15928 #endif
15929
15930
15931 int
15932 main ()
15933 {
15934 static struct sockaddr_storage ac_aggr;
15935 if (ac_aggr.ss_len)
15936 return 0;
15937   ;
15938   return 0;
15939 }
15940 _ACEOF
15941 rm -f conftest.$ac_objext
15942 if { (ac_try="$ac_compile"
15943 case "(($ac_try" in
15944   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15945   *) ac_try_echo=$ac_try;;
15946 esac
15947 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15948 $as_echo "$ac_try_echo") >&5
15949   (eval "$ac_compile") 2>conftest.er1
15950   ac_status=$?
15951   grep -v '^ *+' conftest.er1 >conftest.err
15952   rm -f conftest.er1
15953   cat conftest.err >&5
15954   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15955   (exit $ac_status); } && {
15956          test -z "$ac_c_werror_flag" ||
15957          test ! -s conftest.err
15958        } && test -s conftest.$ac_objext; then
15959   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15960 else
15961   $as_echo "$as_me: failed program was:" >&5
15962 sed 's/^/| /' conftest.$ac_ext >&5
15963
15964         cat >conftest.$ac_ext <<_ACEOF
15965 /* confdefs.h.  */
15966 _ACEOF
15967 cat confdefs.h >>conftest.$ac_ext
15968 cat >>conftest.$ac_ext <<_ACEOF
15969 /* end confdefs.h.  */
15970 #include <sys/types.h>
15971 #ifdef HAVE_SYS_SOCKET_H
15972 #include <sys/socket.h>
15973 #endif
15974
15975
15976 int
15977 main ()
15978 {
15979 static struct sockaddr_storage ac_aggr;
15980 if (sizeof ac_aggr.ss_len)
15981 return 0;
15982   ;
15983   return 0;
15984 }
15985 _ACEOF
15986 rm -f conftest.$ac_objext
15987 if { (ac_try="$ac_compile"
15988 case "(($ac_try" in
15989   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15990   *) ac_try_echo=$ac_try;;
15991 esac
15992 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15993 $as_echo "$ac_try_echo") >&5
15994   (eval "$ac_compile") 2>conftest.er1
15995   ac_status=$?
15996   grep -v '^ *+' conftest.er1 >conftest.err
15997   rm -f conftest.er1
15998   cat conftest.err >&5
15999   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16000   (exit $ac_status); } && {
16001          test -z "$ac_c_werror_flag" ||
16002          test ! -s conftest.err
16003        } && test -s conftest.$ac_objext; then
16004   ac_cv_member_struct_sockaddr_storage_ss_len=yes
16005 else
16006   $as_echo "$as_me: failed program was:" >&5
16007 sed 's/^/| /' conftest.$ac_ext >&5
16008
16009         ac_cv_member_struct_sockaddr_storage_ss_len=no
16010 fi
16011
16012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16013 fi
16014
16015 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16016 fi
16017 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
16018 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
16019 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
16020
16021 cat >>confdefs.h <<_ACEOF
16022 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
16023 _ACEOF
16024
16025
16026 fi
16027 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
16028 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
16029 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
16030   $as_echo_n "(cached) " >&6
16031 else
16032   cat >conftest.$ac_ext <<_ACEOF
16033 /* confdefs.h.  */
16034 _ACEOF
16035 cat confdefs.h >>conftest.$ac_ext
16036 cat >>conftest.$ac_ext <<_ACEOF
16037 /* end confdefs.h.  */
16038 #include <sys/types.h>
16039 #ifdef HAVE_SYS_SOCKET_H
16040 #include <sys/socket.h>
16041 #endif
16042
16043
16044 int
16045 main ()
16046 {
16047 static struct sockaddr_storage ac_aggr;
16048 if (ac_aggr.__ss_len)
16049 return 0;
16050   ;
16051   return 0;
16052 }
16053 _ACEOF
16054 rm -f conftest.$ac_objext
16055 if { (ac_try="$ac_compile"
16056 case "(($ac_try" in
16057   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16058   *) ac_try_echo=$ac_try;;
16059 esac
16060 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16061 $as_echo "$ac_try_echo") >&5
16062   (eval "$ac_compile") 2>conftest.er1
16063   ac_status=$?
16064   grep -v '^ *+' conftest.er1 >conftest.err
16065   rm -f conftest.er1
16066   cat conftest.err >&5
16067   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16068   (exit $ac_status); } && {
16069          test -z "$ac_c_werror_flag" ||
16070          test ! -s conftest.err
16071        } && test -s conftest.$ac_objext; then
16072   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16073 else
16074   $as_echo "$as_me: failed program was:" >&5
16075 sed 's/^/| /' conftest.$ac_ext >&5
16076
16077         cat >conftest.$ac_ext <<_ACEOF
16078 /* confdefs.h.  */
16079 _ACEOF
16080 cat confdefs.h >>conftest.$ac_ext
16081 cat >>conftest.$ac_ext <<_ACEOF
16082 /* end confdefs.h.  */
16083 #include <sys/types.h>
16084 #ifdef HAVE_SYS_SOCKET_H
16085 #include <sys/socket.h>
16086 #endif
16087
16088
16089 int
16090 main ()
16091 {
16092 static struct sockaddr_storage ac_aggr;
16093 if (sizeof ac_aggr.__ss_len)
16094 return 0;
16095   ;
16096   return 0;
16097 }
16098 _ACEOF
16099 rm -f conftest.$ac_objext
16100 if { (ac_try="$ac_compile"
16101 case "(($ac_try" in
16102   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16103   *) ac_try_echo=$ac_try;;
16104 esac
16105 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16106 $as_echo "$ac_try_echo") >&5
16107   (eval "$ac_compile") 2>conftest.er1
16108   ac_status=$?
16109   grep -v '^ *+' conftest.er1 >conftest.err
16110   rm -f conftest.er1
16111   cat conftest.err >&5
16112   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16113   (exit $ac_status); } && {
16114          test -z "$ac_c_werror_flag" ||
16115          test ! -s conftest.err
16116        } && test -s conftest.$ac_objext; then
16117   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16118 else
16119   $as_echo "$as_me: failed program was:" >&5
16120 sed 's/^/| /' conftest.$ac_ext >&5
16121
16122         ac_cv_member_struct_sockaddr_storage___ss_len=no
16123 fi
16124
16125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16126 fi
16127
16128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16129 fi
16130 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
16131 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
16132 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
16133
16134 cat >>confdefs.h <<_ACEOF
16135 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
16136 _ACEOF
16137
16138
16139 fi
16140 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
16141 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
16142 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
16143   $as_echo_n "(cached) " >&6
16144 else
16145   cat >conftest.$ac_ext <<_ACEOF
16146 /* confdefs.h.  */
16147 _ACEOF
16148 cat confdefs.h >>conftest.$ac_ext
16149 cat >>conftest.$ac_ext <<_ACEOF
16150 /* end confdefs.h.  */
16151 #include <sys/types.h>
16152 #ifdef HAVE_SYS_SOCKET_H
16153 #include <sys/socket.h>
16154 #endif
16155
16156
16157 int
16158 main ()
16159 {
16160 static struct sockaddr ac_aggr;
16161 if (ac_aggr.sa_len)
16162 return 0;
16163   ;
16164   return 0;
16165 }
16166 _ACEOF
16167 rm -f conftest.$ac_objext
16168 if { (ac_try="$ac_compile"
16169 case "(($ac_try" in
16170   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16171   *) ac_try_echo=$ac_try;;
16172 esac
16173 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16174 $as_echo "$ac_try_echo") >&5
16175   (eval "$ac_compile") 2>conftest.er1
16176   ac_status=$?
16177   grep -v '^ *+' conftest.er1 >conftest.err
16178   rm -f conftest.er1
16179   cat conftest.err >&5
16180   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16181   (exit $ac_status); } && {
16182          test -z "$ac_c_werror_flag" ||
16183          test ! -s conftest.err
16184        } && test -s conftest.$ac_objext; then
16185   ac_cv_member_struct_sockaddr_sa_len=yes
16186 else
16187   $as_echo "$as_me: failed program was:" >&5
16188 sed 's/^/| /' conftest.$ac_ext >&5
16189
16190         cat >conftest.$ac_ext <<_ACEOF
16191 /* confdefs.h.  */
16192 _ACEOF
16193 cat confdefs.h >>conftest.$ac_ext
16194 cat >>conftest.$ac_ext <<_ACEOF
16195 /* end confdefs.h.  */
16196 #include <sys/types.h>
16197 #ifdef HAVE_SYS_SOCKET_H
16198 #include <sys/socket.h>
16199 #endif
16200
16201
16202 int
16203 main ()
16204 {
16205 static struct sockaddr ac_aggr;
16206 if (sizeof ac_aggr.sa_len)
16207 return 0;
16208   ;
16209   return 0;
16210 }
16211 _ACEOF
16212 rm -f conftest.$ac_objext
16213 if { (ac_try="$ac_compile"
16214 case "(($ac_try" in
16215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16216   *) ac_try_echo=$ac_try;;
16217 esac
16218 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16219 $as_echo "$ac_try_echo") >&5
16220   (eval "$ac_compile") 2>conftest.er1
16221   ac_status=$?
16222   grep -v '^ *+' conftest.er1 >conftest.err
16223   rm -f conftest.er1
16224   cat conftest.err >&5
16225   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16226   (exit $ac_status); } && {
16227          test -z "$ac_c_werror_flag" ||
16228          test ! -s conftest.err
16229        } && test -s conftest.$ac_objext; then
16230   ac_cv_member_struct_sockaddr_sa_len=yes
16231 else
16232   $as_echo "$as_me: failed program was:" >&5
16233 sed 's/^/| /' conftest.$ac_ext >&5
16234
16235         ac_cv_member_struct_sockaddr_sa_len=no
16236 fi
16237
16238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16239 fi
16240
16241 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16242 fi
16243 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
16244 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
16245 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
16246
16247 cat >>confdefs.h <<_ACEOF
16248 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
16249 _ACEOF
16250
16251
16252 fi
16253
16254 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
16255 $as_echo_n "checking for struct addrinfo... " >&6; }
16256 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
16257   $as_echo_n "(cached) " >&6
16258 else
16259   ac_cv_type_struct_addrinfo=no
16260 cat >conftest.$ac_ext <<_ACEOF
16261 /* confdefs.h.  */
16262 _ACEOF
16263 cat confdefs.h >>conftest.$ac_ext
16264 cat >>conftest.$ac_ext <<_ACEOF
16265 /* end confdefs.h.  */
16266 #include <sys/types.h>
16267 #include <sys/socket.h>
16268 #include <netdb.h>
16269
16270
16271 int
16272 main ()
16273 {
16274 if (sizeof (struct addrinfo))
16275        return 0;
16276   ;
16277   return 0;
16278 }
16279 _ACEOF
16280 rm -f conftest.$ac_objext
16281 if { (ac_try="$ac_compile"
16282 case "(($ac_try" in
16283   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16284   *) ac_try_echo=$ac_try;;
16285 esac
16286 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16287 $as_echo "$ac_try_echo") >&5
16288   (eval "$ac_compile") 2>conftest.er1
16289   ac_status=$?
16290   grep -v '^ *+' conftest.er1 >conftest.err
16291   rm -f conftest.er1
16292   cat conftest.err >&5
16293   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16294   (exit $ac_status); } && {
16295          test -z "$ac_c_werror_flag" ||
16296          test ! -s conftest.err
16297        } && test -s conftest.$ac_objext; then
16298   cat >conftest.$ac_ext <<_ACEOF
16299 /* confdefs.h.  */
16300 _ACEOF
16301 cat confdefs.h >>conftest.$ac_ext
16302 cat >>conftest.$ac_ext <<_ACEOF
16303 /* end confdefs.h.  */
16304 #include <sys/types.h>
16305 #include <sys/socket.h>
16306 #include <netdb.h>
16307
16308
16309 int
16310 main ()
16311 {
16312 if (sizeof ((struct addrinfo)))
16313           return 0;
16314   ;
16315   return 0;
16316 }
16317 _ACEOF
16318 rm -f conftest.$ac_objext
16319 if { (ac_try="$ac_compile"
16320 case "(($ac_try" in
16321   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16322   *) ac_try_echo=$ac_try;;
16323 esac
16324 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16325 $as_echo "$ac_try_echo") >&5
16326   (eval "$ac_compile") 2>conftest.er1
16327   ac_status=$?
16328   grep -v '^ *+' conftest.er1 >conftest.err
16329   rm -f conftest.er1
16330   cat conftest.err >&5
16331   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16332   (exit $ac_status); } && {
16333          test -z "$ac_c_werror_flag" ||
16334          test ! -s conftest.err
16335        } && test -s conftest.$ac_objext; then
16336   :
16337 else
16338   $as_echo "$as_me: failed program was:" >&5
16339 sed 's/^/| /' conftest.$ac_ext >&5
16340
16341         ac_cv_type_struct_addrinfo=yes
16342 fi
16343
16344 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16345 else
16346   $as_echo "$as_me: failed program was:" >&5
16347 sed 's/^/| /' conftest.$ac_ext >&5
16348
16349
16350 fi
16351
16352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16353 fi
16354 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
16355 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
16356 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
16357
16358 cat >>confdefs.h <<_ACEOF
16359 #define HAVE_STRUCT_ADDRINFO 1
16360 _ACEOF
16361
16362
16363 fi
16364
16365
16366   { $as_echo "$as_me:$LINENO: checking for intptr_t" >&5
16367 $as_echo_n "checking for intptr_t... " >&6; }
16368 if test "${ac_cv_type_intptr_t+set}" = set; then
16369   $as_echo_n "(cached) " >&6
16370 else
16371   ac_cv_type_intptr_t=no
16372 cat >conftest.$ac_ext <<_ACEOF
16373 /* confdefs.h.  */
16374 _ACEOF
16375 cat confdefs.h >>conftest.$ac_ext
16376 cat >>conftest.$ac_ext <<_ACEOF
16377 /* end confdefs.h.  */
16378 $ac_includes_default
16379 int
16380 main ()
16381 {
16382 if (sizeof (intptr_t))
16383        return 0;
16384   ;
16385   return 0;
16386 }
16387 _ACEOF
16388 rm -f conftest.$ac_objext
16389 if { (ac_try="$ac_compile"
16390 case "(($ac_try" in
16391   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16392   *) ac_try_echo=$ac_try;;
16393 esac
16394 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16395 $as_echo "$ac_try_echo") >&5
16396   (eval "$ac_compile") 2>conftest.er1
16397   ac_status=$?
16398   grep -v '^ *+' conftest.er1 >conftest.err
16399   rm -f conftest.er1
16400   cat conftest.err >&5
16401   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16402   (exit $ac_status); } && {
16403          test -z "$ac_c_werror_flag" ||
16404          test ! -s conftest.err
16405        } && test -s conftest.$ac_objext; then
16406   cat >conftest.$ac_ext <<_ACEOF
16407 /* confdefs.h.  */
16408 _ACEOF
16409 cat confdefs.h >>conftest.$ac_ext
16410 cat >>conftest.$ac_ext <<_ACEOF
16411 /* end confdefs.h.  */
16412 $ac_includes_default
16413 int
16414 main ()
16415 {
16416 if (sizeof ((intptr_t)))
16417           return 0;
16418   ;
16419   return 0;
16420 }
16421 _ACEOF
16422 rm -f conftest.$ac_objext
16423 if { (ac_try="$ac_compile"
16424 case "(($ac_try" in
16425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16426   *) ac_try_echo=$ac_try;;
16427 esac
16428 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16429 $as_echo "$ac_try_echo") >&5
16430   (eval "$ac_compile") 2>conftest.er1
16431   ac_status=$?
16432   grep -v '^ *+' conftest.er1 >conftest.err
16433   rm -f conftest.er1
16434   cat conftest.err >&5
16435   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16436   (exit $ac_status); } && {
16437          test -z "$ac_c_werror_flag" ||
16438          test ! -s conftest.err
16439        } && test -s conftest.$ac_objext; then
16440   :
16441 else
16442   $as_echo "$as_me: failed program was:" >&5
16443 sed 's/^/| /' conftest.$ac_ext >&5
16444
16445         ac_cv_type_intptr_t=yes
16446 fi
16447
16448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16449 else
16450   $as_echo "$as_me: failed program was:" >&5
16451 sed 's/^/| /' conftest.$ac_ext >&5
16452
16453
16454 fi
16455
16456 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16457 fi
16458 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
16459 $as_echo "$ac_cv_type_intptr_t" >&6; }
16460 if test "x$ac_cv_type_intptr_t" = x""yes; then
16461
16462 cat >>confdefs.h <<\_ACEOF
16463 #define HAVE_INTPTR_T 1
16464 _ACEOF
16465
16466 else
16467   for ac_type in 'int' 'long int' 'long long int'; do
16468        cat >conftest.$ac_ext <<_ACEOF
16469 /* confdefs.h.  */
16470 _ACEOF
16471 cat confdefs.h >>conftest.$ac_ext
16472 cat >>conftest.$ac_ext <<_ACEOF
16473 /* end confdefs.h.  */
16474 $ac_includes_default
16475 int
16476 main ()
16477 {
16478 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16479 test_array [0] = 0
16480
16481   ;
16482   return 0;
16483 }
16484 _ACEOF
16485 rm -f conftest.$ac_objext
16486 if { (ac_try="$ac_compile"
16487 case "(($ac_try" in
16488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16489   *) ac_try_echo=$ac_try;;
16490 esac
16491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16492 $as_echo "$ac_try_echo") >&5
16493   (eval "$ac_compile") 2>conftest.er1
16494   ac_status=$?
16495   grep -v '^ *+' conftest.er1 >conftest.err
16496   rm -f conftest.er1
16497   cat conftest.err >&5
16498   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16499   (exit $ac_status); } && {
16500          test -z "$ac_c_werror_flag" ||
16501          test ! -s conftest.err
16502        } && test -s conftest.$ac_objext; then
16503
16504 cat >>confdefs.h <<_ACEOF
16505 #define intptr_t $ac_type
16506 _ACEOF
16507
16508           ac_type=
16509 else
16510   $as_echo "$as_me: failed program was:" >&5
16511 sed 's/^/| /' conftest.$ac_ext >&5
16512
16513
16514 fi
16515
16516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16517        test -z "$ac_type" && break
16518      done
16519 fi
16520
16521
16522
16523   { $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
16524 $as_echo_n "checking for uintptr_t... " >&6; }
16525 if test "${ac_cv_type_uintptr_t+set}" = set; then
16526   $as_echo_n "(cached) " >&6
16527 else
16528   ac_cv_type_uintptr_t=no
16529 cat >conftest.$ac_ext <<_ACEOF
16530 /* confdefs.h.  */
16531 _ACEOF
16532 cat confdefs.h >>conftest.$ac_ext
16533 cat >>conftest.$ac_ext <<_ACEOF
16534 /* end confdefs.h.  */
16535 $ac_includes_default
16536 int
16537 main ()
16538 {
16539 if (sizeof (uintptr_t))
16540        return 0;
16541   ;
16542   return 0;
16543 }
16544 _ACEOF
16545 rm -f conftest.$ac_objext
16546 if { (ac_try="$ac_compile"
16547 case "(($ac_try" in
16548   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16549   *) ac_try_echo=$ac_try;;
16550 esac
16551 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16552 $as_echo "$ac_try_echo") >&5
16553   (eval "$ac_compile") 2>conftest.er1
16554   ac_status=$?
16555   grep -v '^ *+' conftest.er1 >conftest.err
16556   rm -f conftest.er1
16557   cat conftest.err >&5
16558   $as_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_objext; then
16563   cat >conftest.$ac_ext <<_ACEOF
16564 /* confdefs.h.  */
16565 _ACEOF
16566 cat confdefs.h >>conftest.$ac_ext
16567 cat >>conftest.$ac_ext <<_ACEOF
16568 /* end confdefs.h.  */
16569 $ac_includes_default
16570 int
16571 main ()
16572 {
16573 if (sizeof ((uintptr_t)))
16574           return 0;
16575   ;
16576   return 0;
16577 }
16578 _ACEOF
16579 rm -f conftest.$ac_objext
16580 if { (ac_try="$ac_compile"
16581 case "(($ac_try" in
16582   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16583   *) ac_try_echo=$ac_try;;
16584 esac
16585 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16586 $as_echo "$ac_try_echo") >&5
16587   (eval "$ac_compile") 2>conftest.er1
16588   ac_status=$?
16589   grep -v '^ *+' conftest.er1 >conftest.err
16590   rm -f conftest.er1
16591   cat conftest.err >&5
16592   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16593   (exit $ac_status); } && {
16594          test -z "$ac_c_werror_flag" ||
16595          test ! -s conftest.err
16596        } && test -s conftest.$ac_objext; then
16597   :
16598 else
16599   $as_echo "$as_me: failed program was:" >&5
16600 sed 's/^/| /' conftest.$ac_ext >&5
16601
16602         ac_cv_type_uintptr_t=yes
16603 fi
16604
16605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16606 else
16607   $as_echo "$as_me: failed program was:" >&5
16608 sed 's/^/| /' conftest.$ac_ext >&5
16609
16610
16611 fi
16612
16613 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16614 fi
16615 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
16616 $as_echo "$ac_cv_type_uintptr_t" >&6; }
16617 if test "x$ac_cv_type_uintptr_t" = x""yes; then
16618
16619 cat >>confdefs.h <<\_ACEOF
16620 #define HAVE_UINTPTR_T 1
16621 _ACEOF
16622
16623 else
16624   for ac_type in 'unsigned int' 'unsigned long int' \
16625         'unsigned long long int'; do
16626        cat >conftest.$ac_ext <<_ACEOF
16627 /* confdefs.h.  */
16628 _ACEOF
16629 cat confdefs.h >>conftest.$ac_ext
16630 cat >>conftest.$ac_ext <<_ACEOF
16631 /* end confdefs.h.  */
16632 $ac_includes_default
16633 int
16634 main ()
16635 {
16636 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16637 test_array [0] = 0
16638
16639   ;
16640   return 0;
16641 }
16642 _ACEOF
16643 rm -f conftest.$ac_objext
16644 if { (ac_try="$ac_compile"
16645 case "(($ac_try" in
16646   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16647   *) ac_try_echo=$ac_try;;
16648 esac
16649 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16650 $as_echo "$ac_try_echo") >&5
16651   (eval "$ac_compile") 2>conftest.er1
16652   ac_status=$?
16653   grep -v '^ *+' conftest.er1 >conftest.err
16654   rm -f conftest.er1
16655   cat conftest.err >&5
16656   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16657   (exit $ac_status); } && {
16658          test -z "$ac_c_werror_flag" ||
16659          test ! -s conftest.err
16660        } && test -s conftest.$ac_objext; then
16661
16662 cat >>confdefs.h <<_ACEOF
16663 #define uintptr_t $ac_type
16664 _ACEOF
16665
16666           ac_type=
16667 else
16668   $as_echo "$as_me: failed program was:" >&5
16669 sed 's/^/| /' conftest.$ac_ext >&5
16670
16671
16672 fi
16673
16674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16675        test -z "$ac_type" && break
16676      done
16677 fi
16678
16679
16680
16681   { $as_echo "$as_me:$LINENO: checking for long long int" >&5
16682 $as_echo_n "checking for long long int... " >&6; }
16683 if test "${ac_cv_type_long_long_int+set}" = set; then
16684   $as_echo_n "(cached) " >&6
16685 else
16686   cat >conftest.$ac_ext <<_ACEOF
16687
16688   /* confdefs.h.  */
16689 _ACEOF
16690 cat confdefs.h >>conftest.$ac_ext
16691 cat >>conftest.$ac_ext <<_ACEOF
16692 /* end confdefs.h.  */
16693 /* For now, do not test the preprocessor; as of 2007 there are too many
16694          implementations with broken preprocessors.  Perhaps this can
16695          be revisited in 2012.  In the meantime, code should not expect
16696          #if to work with literals wider than 32 bits.  */
16697       /* Test literals.  */
16698       long long int ll = 9223372036854775807ll;
16699       long long int nll = -9223372036854775807LL;
16700       unsigned long long int ull = 18446744073709551615ULL;
16701       /* Test constant expressions.   */
16702       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
16703                      ? 1 : -1)];
16704       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
16705                      ? 1 : -1)];
16706       int i = 63;
16707 int
16708 main ()
16709 {
16710 /* Test availability of runtime routines for shift and division.  */
16711       long long int llmax = 9223372036854775807ll;
16712       unsigned long long int ullmax = 18446744073709551615ull;
16713       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
16714               | (llmax / ll) | (llmax % ll)
16715               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
16716               | (ullmax / ull) | (ullmax % ull));
16717   ;
16718   return 0;
16719 }
16720
16721 _ACEOF
16722 rm -f conftest.$ac_objext conftest$ac_exeext
16723 if { (ac_try="$ac_link"
16724 case "(($ac_try" in
16725   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16726   *) ac_try_echo=$ac_try;;
16727 esac
16728 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16729 $as_echo "$ac_try_echo") >&5
16730   (eval "$ac_link") 2>conftest.er1
16731   ac_status=$?
16732   grep -v '^ *+' conftest.er1 >conftest.err
16733   rm -f conftest.er1
16734   cat conftest.err >&5
16735   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16736   (exit $ac_status); } && {
16737          test -z "$ac_c_werror_flag" ||
16738          test ! -s conftest.err
16739        } && test -s conftest$ac_exeext && {
16740          test "$cross_compiling" = yes ||
16741          $as_test_x conftest$ac_exeext
16742        }; then
16743                         if test "$cross_compiling" = yes; then
16744   ac_cv_type_long_long_int=yes
16745 else
16746   cat >conftest.$ac_ext <<_ACEOF
16747 /* confdefs.h.  */
16748 _ACEOF
16749 cat confdefs.h >>conftest.$ac_ext
16750 cat >>conftest.$ac_ext <<_ACEOF
16751 /* end confdefs.h.  */
16752 #include <limits.h>
16753                #ifndef LLONG_MAX
16754                # define HALF \
16755                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
16756                # define LLONG_MAX (HALF - 1 + HALF)
16757                #endif
16758 int
16759 main ()
16760 {
16761 long long int n = 1;
16762                int i;
16763                for (i = 0; ; i++)
16764                  {
16765                    long long int m = n << i;
16766                    if (m >> i != n)
16767                      return 1;
16768                    if (LLONG_MAX / 2 < m)
16769                      break;
16770                  }
16771                return 0;
16772   ;
16773   return 0;
16774 }
16775 _ACEOF
16776 rm -f conftest$ac_exeext
16777 if { (ac_try="$ac_link"
16778 case "(($ac_try" in
16779   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16780   *) ac_try_echo=$ac_try;;
16781 esac
16782 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16783 $as_echo "$ac_try_echo") >&5
16784   (eval "$ac_link") 2>&5
16785   ac_status=$?
16786   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16787   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16788   { (case "(($ac_try" in
16789   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16790   *) ac_try_echo=$ac_try;;
16791 esac
16792 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16793 $as_echo "$ac_try_echo") >&5
16794   (eval "$ac_try") 2>&5
16795   ac_status=$?
16796   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16797   (exit $ac_status); }; }; then
16798   ac_cv_type_long_long_int=yes
16799 else
16800   $as_echo "$as_me: program exited with status $ac_status" >&5
16801 $as_echo "$as_me: failed program was:" >&5
16802 sed 's/^/| /' conftest.$ac_ext >&5
16803
16804 ( exit $ac_status )
16805 ac_cv_type_long_long_int=no
16806 fi
16807 rm -rf conftest.dSYM
16808 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16809 fi
16810
16811
16812 else
16813   $as_echo "$as_me: failed program was:" >&5
16814 sed 's/^/| /' conftest.$ac_ext >&5
16815
16816         ac_cv_type_long_long_int=no
16817 fi
16818
16819 rm -rf conftest.dSYM
16820 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16821       conftest$ac_exeext conftest.$ac_ext
16822 fi
16823 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
16824 $as_echo "$ac_cv_type_long_long_int" >&6; }
16825   if test $ac_cv_type_long_long_int = yes; then
16826
16827 cat >>confdefs.h <<\_ACEOF
16828 #define HAVE_LONG_LONG_INT 1
16829 _ACEOF
16830
16831   fi
16832
16833
16834 { $as_echo "$as_me:$LINENO: checking for locale_t" >&5
16835 $as_echo_n "checking for locale_t... " >&6; }
16836 if test "${pgac_cv_type_locale_t+set}" = set; then
16837   $as_echo_n "(cached) " >&6
16838 else
16839   cat >conftest.$ac_ext <<_ACEOF
16840 /* confdefs.h.  */
16841 _ACEOF
16842 cat confdefs.h >>conftest.$ac_ext
16843 cat >>conftest.$ac_ext <<_ACEOF
16844 /* end confdefs.h.  */
16845 #include <locale.h>
16846 locale_t x;
16847 int
16848 main ()
16849 {
16850
16851   ;
16852   return 0;
16853 }
16854 _ACEOF
16855 rm -f conftest.$ac_objext
16856 if { (ac_try="$ac_compile"
16857 case "(($ac_try" in
16858   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16859   *) ac_try_echo=$ac_try;;
16860 esac
16861 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16862 $as_echo "$ac_try_echo") >&5
16863   (eval "$ac_compile") 2>conftest.er1
16864   ac_status=$?
16865   grep -v '^ *+' conftest.er1 >conftest.err
16866   rm -f conftest.er1
16867   cat conftest.err >&5
16868   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16869   (exit $ac_status); } && {
16870          test -z "$ac_c_werror_flag" ||
16871          test ! -s conftest.err
16872        } && test -s conftest.$ac_objext; then
16873   pgac_cv_type_locale_t=yes
16874 else
16875   $as_echo "$as_me: failed program was:" >&5
16876 sed 's/^/| /' conftest.$ac_ext >&5
16877
16878         cat >conftest.$ac_ext <<_ACEOF
16879 /* confdefs.h.  */
16880 _ACEOF
16881 cat confdefs.h >>conftest.$ac_ext
16882 cat >>conftest.$ac_ext <<_ACEOF
16883 /* end confdefs.h.  */
16884 #include <xlocale.h>
16885 locale_t x;
16886 int
16887 main ()
16888 {
16889
16890   ;
16891   return 0;
16892 }
16893 _ACEOF
16894 rm -f conftest.$ac_objext
16895 if { (ac_try="$ac_compile"
16896 case "(($ac_try" in
16897   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16898   *) ac_try_echo=$ac_try;;
16899 esac
16900 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16901 $as_echo "$ac_try_echo") >&5
16902   (eval "$ac_compile") 2>conftest.er1
16903   ac_status=$?
16904   grep -v '^ *+' conftest.er1 >conftest.err
16905   rm -f conftest.er1
16906   cat conftest.err >&5
16907   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16908   (exit $ac_status); } && {
16909          test -z "$ac_c_werror_flag" ||
16910          test ! -s conftest.err
16911        } && test -s conftest.$ac_objext; then
16912   pgac_cv_type_locale_t='yes (in xlocale.h)'
16913 else
16914   $as_echo "$as_me: failed program was:" >&5
16915 sed 's/^/| /' conftest.$ac_ext >&5
16916
16917         pgac_cv_type_locale_t=no
16918 fi
16919
16920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16921 fi
16922
16923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16924 fi
16925 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_locale_t" >&5
16926 $as_echo "$pgac_cv_type_locale_t" >&6; }
16927 if test "$pgac_cv_type_locale_t" != no; then
16928
16929 cat >>confdefs.h <<\_ACEOF
16930 #define HAVE_LOCALE_T 1
16931 _ACEOF
16932
16933 fi
16934 if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then
16935
16936 cat >>confdefs.h <<\_ACEOF
16937 #define LOCALE_T_IN_XLOCALE 1
16938 _ACEOF
16939
16940 fi
16941
16942 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
16943 $as_echo_n "checking for struct cmsgcred... " >&6; }
16944 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
16945   $as_echo_n "(cached) " >&6
16946 else
16947   ac_cv_type_struct_cmsgcred=no
16948 cat >conftest.$ac_ext <<_ACEOF
16949 /* confdefs.h.  */
16950 _ACEOF
16951 cat confdefs.h >>conftest.$ac_ext
16952 cat >>conftest.$ac_ext <<_ACEOF
16953 /* end confdefs.h.  */
16954 #include <sys/param.h>
16955 #include <sys/types.h>
16956 #include <sys/socket.h>
16957 #include <sys/ucred.h>
16958
16959 int
16960 main ()
16961 {
16962 if (sizeof (struct cmsgcred))
16963        return 0;
16964   ;
16965   return 0;
16966 }
16967 _ACEOF
16968 rm -f conftest.$ac_objext
16969 if { (ac_try="$ac_compile"
16970 case "(($ac_try" in
16971   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16972   *) ac_try_echo=$ac_try;;
16973 esac
16974 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16975 $as_echo "$ac_try_echo") >&5
16976   (eval "$ac_compile") 2>conftest.er1
16977   ac_status=$?
16978   grep -v '^ *+' conftest.er1 >conftest.err
16979   rm -f conftest.er1
16980   cat conftest.err >&5
16981   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16982   (exit $ac_status); } && {
16983          test -z "$ac_c_werror_flag" ||
16984          test ! -s conftest.err
16985        } && test -s conftest.$ac_objext; then
16986   cat >conftest.$ac_ext <<_ACEOF
16987 /* confdefs.h.  */
16988 _ACEOF
16989 cat confdefs.h >>conftest.$ac_ext
16990 cat >>conftest.$ac_ext <<_ACEOF
16991 /* end confdefs.h.  */
16992 #include <sys/param.h>
16993 #include <sys/types.h>
16994 #include <sys/socket.h>
16995 #include <sys/ucred.h>
16996
16997 int
16998 main ()
16999 {
17000 if (sizeof ((struct cmsgcred)))
17001           return 0;
17002   ;
17003   return 0;
17004 }
17005 _ACEOF
17006 rm -f conftest.$ac_objext
17007 if { (ac_try="$ac_compile"
17008 case "(($ac_try" in
17009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17010   *) ac_try_echo=$ac_try;;
17011 esac
17012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17013 $as_echo "$ac_try_echo") >&5
17014   (eval "$ac_compile") 2>conftest.er1
17015   ac_status=$?
17016   grep -v '^ *+' conftest.er1 >conftest.err
17017   rm -f conftest.er1
17018   cat conftest.err >&5
17019   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17020   (exit $ac_status); } && {
17021          test -z "$ac_c_werror_flag" ||
17022          test ! -s conftest.err
17023        } && test -s conftest.$ac_objext; then
17024   :
17025 else
17026   $as_echo "$as_me: failed program was:" >&5
17027 sed 's/^/| /' conftest.$ac_ext >&5
17028
17029         ac_cv_type_struct_cmsgcred=yes
17030 fi
17031
17032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17033 else
17034   $as_echo "$as_me: failed program was:" >&5
17035 sed 's/^/| /' conftest.$ac_ext >&5
17036
17037
17038 fi
17039
17040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17041 fi
17042 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
17043 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
17044 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
17045
17046 cat >>confdefs.h <<_ACEOF
17047 #define HAVE_STRUCT_CMSGCRED 1
17048 _ACEOF
17049
17050
17051 fi
17052 { $as_echo "$as_me:$LINENO: checking for struct fcred" >&5
17053 $as_echo_n "checking for struct fcred... " >&6; }
17054 if test "${ac_cv_type_struct_fcred+set}" = set; then
17055   $as_echo_n "(cached) " >&6
17056 else
17057   ac_cv_type_struct_fcred=no
17058 cat >conftest.$ac_ext <<_ACEOF
17059 /* confdefs.h.  */
17060 _ACEOF
17061 cat confdefs.h >>conftest.$ac_ext
17062 cat >>conftest.$ac_ext <<_ACEOF
17063 /* end confdefs.h.  */
17064 #include <sys/param.h>
17065 #include <sys/types.h>
17066 #include <sys/socket.h>
17067 #include <sys/ucred.h>
17068
17069 int
17070 main ()
17071 {
17072 if (sizeof (struct fcred))
17073        return 0;
17074   ;
17075   return 0;
17076 }
17077 _ACEOF
17078 rm -f conftest.$ac_objext
17079 if { (ac_try="$ac_compile"
17080 case "(($ac_try" in
17081   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17082   *) ac_try_echo=$ac_try;;
17083 esac
17084 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17085 $as_echo "$ac_try_echo") >&5
17086   (eval "$ac_compile") 2>conftest.er1
17087   ac_status=$?
17088   grep -v '^ *+' conftest.er1 >conftest.err
17089   rm -f conftest.er1
17090   cat conftest.err >&5
17091   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17092   (exit $ac_status); } && {
17093          test -z "$ac_c_werror_flag" ||
17094          test ! -s conftest.err
17095        } && test -s conftest.$ac_objext; then
17096   cat >conftest.$ac_ext <<_ACEOF
17097 /* confdefs.h.  */
17098 _ACEOF
17099 cat confdefs.h >>conftest.$ac_ext
17100 cat >>conftest.$ac_ext <<_ACEOF
17101 /* end confdefs.h.  */
17102 #include <sys/param.h>
17103 #include <sys/types.h>
17104 #include <sys/socket.h>
17105 #include <sys/ucred.h>
17106
17107 int
17108 main ()
17109 {
17110 if (sizeof ((struct fcred)))
17111           return 0;
17112   ;
17113   return 0;
17114 }
17115 _ACEOF
17116 rm -f conftest.$ac_objext
17117 if { (ac_try="$ac_compile"
17118 case "(($ac_try" in
17119   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17120   *) ac_try_echo=$ac_try;;
17121 esac
17122 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17123 $as_echo "$ac_try_echo") >&5
17124   (eval "$ac_compile") 2>conftest.er1
17125   ac_status=$?
17126   grep -v '^ *+' conftest.er1 >conftest.err
17127   rm -f conftest.er1
17128   cat conftest.err >&5
17129   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17130   (exit $ac_status); } && {
17131          test -z "$ac_c_werror_flag" ||
17132          test ! -s conftest.err
17133        } && test -s conftest.$ac_objext; then
17134   :
17135 else
17136   $as_echo "$as_me: failed program was:" >&5
17137 sed 's/^/| /' conftest.$ac_ext >&5
17138
17139         ac_cv_type_struct_fcred=yes
17140 fi
17141
17142 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17143 else
17144   $as_echo "$as_me: failed program was:" >&5
17145 sed 's/^/| /' conftest.$ac_ext >&5
17146
17147
17148 fi
17149
17150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17151 fi
17152 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
17153 $as_echo "$ac_cv_type_struct_fcred" >&6; }
17154 if test "x$ac_cv_type_struct_fcred" = x""yes; then
17155
17156 cat >>confdefs.h <<_ACEOF
17157 #define HAVE_STRUCT_FCRED 1
17158 _ACEOF
17159
17160
17161 fi
17162 { $as_echo "$as_me:$LINENO: checking for struct sockcred" >&5
17163 $as_echo_n "checking for struct sockcred... " >&6; }
17164 if test "${ac_cv_type_struct_sockcred+set}" = set; then
17165   $as_echo_n "(cached) " >&6
17166 else
17167   ac_cv_type_struct_sockcred=no
17168 cat >conftest.$ac_ext <<_ACEOF
17169 /* confdefs.h.  */
17170 _ACEOF
17171 cat confdefs.h >>conftest.$ac_ext
17172 cat >>conftest.$ac_ext <<_ACEOF
17173 /* end confdefs.h.  */
17174 #include <sys/param.h>
17175 #include <sys/types.h>
17176 #include <sys/socket.h>
17177 #include <sys/ucred.h>
17178
17179 int
17180 main ()
17181 {
17182 if (sizeof (struct sockcred))
17183        return 0;
17184   ;
17185   return 0;
17186 }
17187 _ACEOF
17188 rm -f conftest.$ac_objext
17189 if { (ac_try="$ac_compile"
17190 case "(($ac_try" in
17191   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17192   *) ac_try_echo=$ac_try;;
17193 esac
17194 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17195 $as_echo "$ac_try_echo") >&5
17196   (eval "$ac_compile") 2>conftest.er1
17197   ac_status=$?
17198   grep -v '^ *+' conftest.er1 >conftest.err
17199   rm -f conftest.er1
17200   cat conftest.err >&5
17201   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17202   (exit $ac_status); } && {
17203          test -z "$ac_c_werror_flag" ||
17204          test ! -s conftest.err
17205        } && test -s conftest.$ac_objext; then
17206   cat >conftest.$ac_ext <<_ACEOF
17207 /* confdefs.h.  */
17208 _ACEOF
17209 cat confdefs.h >>conftest.$ac_ext
17210 cat >>conftest.$ac_ext <<_ACEOF
17211 /* end confdefs.h.  */
17212 #include <sys/param.h>
17213 #include <sys/types.h>
17214 #include <sys/socket.h>
17215 #include <sys/ucred.h>
17216
17217 int
17218 main ()
17219 {
17220 if (sizeof ((struct sockcred)))
17221           return 0;
17222   ;
17223   return 0;
17224 }
17225 _ACEOF
17226 rm -f conftest.$ac_objext
17227 if { (ac_try="$ac_compile"
17228 case "(($ac_try" in
17229   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17230   *) ac_try_echo=$ac_try;;
17231 esac
17232 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17233 $as_echo "$ac_try_echo") >&5
17234   (eval "$ac_compile") 2>conftest.er1
17235   ac_status=$?
17236   grep -v '^ *+' conftest.er1 >conftest.err
17237   rm -f conftest.er1
17238   cat conftest.err >&5
17239   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17240   (exit $ac_status); } && {
17241          test -z "$ac_c_werror_flag" ||
17242          test ! -s conftest.err
17243        } && test -s conftest.$ac_objext; then
17244   :
17245 else
17246   $as_echo "$as_me: failed program was:" >&5
17247 sed 's/^/| /' conftest.$ac_ext >&5
17248
17249         ac_cv_type_struct_sockcred=yes
17250 fi
17251
17252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17253 else
17254   $as_echo "$as_me: failed program was:" >&5
17255 sed 's/^/| /' conftest.$ac_ext >&5
17256
17257
17258 fi
17259
17260 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17261 fi
17262 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
17263 $as_echo "$ac_cv_type_struct_sockcred" >&6; }
17264 if test "x$ac_cv_type_struct_sockcred" = x""yes; then
17265
17266 cat >>confdefs.h <<_ACEOF
17267 #define HAVE_STRUCT_SOCKCRED 1
17268 _ACEOF
17269
17270
17271 fi
17272
17273
17274 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
17275 $as_echo_n "checking for struct option... " >&6; }
17276 if test "${ac_cv_type_struct_option+set}" = set; then
17277   $as_echo_n "(cached) " >&6
17278 else
17279   ac_cv_type_struct_option=no
17280 cat >conftest.$ac_ext <<_ACEOF
17281 /* confdefs.h.  */
17282 _ACEOF
17283 cat confdefs.h >>conftest.$ac_ext
17284 cat >>conftest.$ac_ext <<_ACEOF
17285 /* end confdefs.h.  */
17286 #ifdef HAVE_GETOPT_H
17287 #include <getopt.h>
17288 #endif
17289
17290 int
17291 main ()
17292 {
17293 if (sizeof (struct option))
17294        return 0;
17295   ;
17296   return 0;
17297 }
17298 _ACEOF
17299 rm -f conftest.$ac_objext
17300 if { (ac_try="$ac_compile"
17301 case "(($ac_try" in
17302   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17303   *) ac_try_echo=$ac_try;;
17304 esac
17305 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17306 $as_echo "$ac_try_echo") >&5
17307   (eval "$ac_compile") 2>conftest.er1
17308   ac_status=$?
17309   grep -v '^ *+' conftest.er1 >conftest.err
17310   rm -f conftest.er1
17311   cat conftest.err >&5
17312   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17313   (exit $ac_status); } && {
17314          test -z "$ac_c_werror_flag" ||
17315          test ! -s conftest.err
17316        } && test -s conftest.$ac_objext; then
17317   cat >conftest.$ac_ext <<_ACEOF
17318 /* confdefs.h.  */
17319 _ACEOF
17320 cat confdefs.h >>conftest.$ac_ext
17321 cat >>conftest.$ac_ext <<_ACEOF
17322 /* end confdefs.h.  */
17323 #ifdef HAVE_GETOPT_H
17324 #include <getopt.h>
17325 #endif
17326
17327 int
17328 main ()
17329 {
17330 if (sizeof ((struct option)))
17331           return 0;
17332   ;
17333   return 0;
17334 }
17335 _ACEOF
17336 rm -f conftest.$ac_objext
17337 if { (ac_try="$ac_compile"
17338 case "(($ac_try" in
17339   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17340   *) ac_try_echo=$ac_try;;
17341 esac
17342 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17343 $as_echo "$ac_try_echo") >&5
17344   (eval "$ac_compile") 2>conftest.er1
17345   ac_status=$?
17346   grep -v '^ *+' conftest.er1 >conftest.err
17347   rm -f conftest.er1
17348   cat conftest.err >&5
17349   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17350   (exit $ac_status); } && {
17351          test -z "$ac_c_werror_flag" ||
17352          test ! -s conftest.err
17353        } && test -s conftest.$ac_objext; then
17354   :
17355 else
17356   $as_echo "$as_me: failed program was:" >&5
17357 sed 's/^/| /' conftest.$ac_ext >&5
17358
17359         ac_cv_type_struct_option=yes
17360 fi
17361
17362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17363 else
17364   $as_echo "$as_me: failed program was:" >&5
17365 sed 's/^/| /' conftest.$ac_ext >&5
17366
17367
17368 fi
17369
17370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17371 fi
17372 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
17373 $as_echo "$ac_cv_type_struct_option" >&6; }
17374 if test "x$ac_cv_type_struct_option" = x""yes; then
17375
17376 cat >>confdefs.h <<_ACEOF
17377 #define HAVE_STRUCT_OPTION 1
17378 _ACEOF
17379
17380
17381 fi
17382
17383
17384 if test "$with_zlib" = yes; then
17385   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
17386   # did not).  While we could work around the lack of z_streamp, it
17387   # seems unwise to encourage people to use such old zlib versions...
17388   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
17389 $as_echo_n "checking for z_streamp... " >&6; }
17390 if test "${ac_cv_type_z_streamp+set}" = set; then
17391   $as_echo_n "(cached) " >&6
17392 else
17393   ac_cv_type_z_streamp=no
17394 cat >conftest.$ac_ext <<_ACEOF
17395 /* confdefs.h.  */
17396 _ACEOF
17397 cat confdefs.h >>conftest.$ac_ext
17398 cat >>conftest.$ac_ext <<_ACEOF
17399 /* end confdefs.h.  */
17400 #include <zlib.h>
17401
17402 int
17403 main ()
17404 {
17405 if (sizeof (z_streamp))
17406        return 0;
17407   ;
17408   return 0;
17409 }
17410 _ACEOF
17411 rm -f conftest.$ac_objext
17412 if { (ac_try="$ac_compile"
17413 case "(($ac_try" in
17414   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17415   *) ac_try_echo=$ac_try;;
17416 esac
17417 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17418 $as_echo "$ac_try_echo") >&5
17419   (eval "$ac_compile") 2>conftest.er1
17420   ac_status=$?
17421   grep -v '^ *+' conftest.er1 >conftest.err
17422   rm -f conftest.er1
17423   cat conftest.err >&5
17424   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17425   (exit $ac_status); } && {
17426          test -z "$ac_c_werror_flag" ||
17427          test ! -s conftest.err
17428        } && test -s conftest.$ac_objext; then
17429   cat >conftest.$ac_ext <<_ACEOF
17430 /* confdefs.h.  */
17431 _ACEOF
17432 cat confdefs.h >>conftest.$ac_ext
17433 cat >>conftest.$ac_ext <<_ACEOF
17434 /* end confdefs.h.  */
17435 #include <zlib.h>
17436
17437 int
17438 main ()
17439 {
17440 if (sizeof ((z_streamp)))
17441           return 0;
17442   ;
17443   return 0;
17444 }
17445 _ACEOF
17446 rm -f conftest.$ac_objext
17447 if { (ac_try="$ac_compile"
17448 case "(($ac_try" in
17449   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17450   *) ac_try_echo=$ac_try;;
17451 esac
17452 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17453 $as_echo "$ac_try_echo") >&5
17454   (eval "$ac_compile") 2>conftest.er1
17455   ac_status=$?
17456   grep -v '^ *+' conftest.er1 >conftest.err
17457   rm -f conftest.er1
17458   cat conftest.err >&5
17459   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17460   (exit $ac_status); } && {
17461          test -z "$ac_c_werror_flag" ||
17462          test ! -s conftest.err
17463        } && test -s conftest.$ac_objext; then
17464   :
17465 else
17466   $as_echo "$as_me: failed program was:" >&5
17467 sed 's/^/| /' conftest.$ac_ext >&5
17468
17469         ac_cv_type_z_streamp=yes
17470 fi
17471
17472 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17473 else
17474   $as_echo "$as_me: failed program was:" >&5
17475 sed 's/^/| /' conftest.$ac_ext >&5
17476
17477
17478 fi
17479
17480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17481 fi
17482 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
17483 $as_echo "$ac_cv_type_z_streamp" >&6; }
17484 if test "x$ac_cv_type_z_streamp" = x""yes; then
17485   :
17486 else
17487   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
17488 Use --without-zlib to disable zlib support." >&5
17489 $as_echo "$as_me: error: zlib version is too old
17490 Use --without-zlib to disable zlib support." >&2;}
17491    { (exit 1); exit 1; }; }
17492 fi
17493
17494 fi
17495
17496 if test "$with_krb5" = yes; then
17497 # Check for differences between MIT and Heimdal (KTH) releases
17498   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
17499 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
17500 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
17501   $as_echo_n "(cached) " >&6
17502 else
17503   cat >conftest.$ac_ext <<_ACEOF
17504 /* confdefs.h.  */
17505 _ACEOF
17506 cat confdefs.h >>conftest.$ac_ext
17507 cat >>conftest.$ac_ext <<_ACEOF
17508 /* end confdefs.h.  */
17509 #include <krb5.h>
17510
17511 int
17512 main ()
17513 {
17514 static krb5_ticket ac_aggr;
17515 if (ac_aggr.enc_part2)
17516 return 0;
17517   ;
17518   return 0;
17519 }
17520 _ACEOF
17521 rm -f conftest.$ac_objext
17522 if { (ac_try="$ac_compile"
17523 case "(($ac_try" in
17524   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17525   *) ac_try_echo=$ac_try;;
17526 esac
17527 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17528 $as_echo "$ac_try_echo") >&5
17529   (eval "$ac_compile") 2>conftest.er1
17530   ac_status=$?
17531   grep -v '^ *+' conftest.er1 >conftest.err
17532   rm -f conftest.er1
17533   cat conftest.err >&5
17534   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17535   (exit $ac_status); } && {
17536          test -z "$ac_c_werror_flag" ||
17537          test ! -s conftest.err
17538        } && test -s conftest.$ac_objext; then
17539   ac_cv_member_krb5_ticket_enc_part2=yes
17540 else
17541   $as_echo "$as_me: failed program was:" >&5
17542 sed 's/^/| /' conftest.$ac_ext >&5
17543
17544         cat >conftest.$ac_ext <<_ACEOF
17545 /* confdefs.h.  */
17546 _ACEOF
17547 cat confdefs.h >>conftest.$ac_ext
17548 cat >>conftest.$ac_ext <<_ACEOF
17549 /* end confdefs.h.  */
17550 #include <krb5.h>
17551
17552 int
17553 main ()
17554 {
17555 static krb5_ticket ac_aggr;
17556 if (sizeof ac_aggr.enc_part2)
17557 return 0;
17558   ;
17559   return 0;
17560 }
17561 _ACEOF
17562 rm -f conftest.$ac_objext
17563 if { (ac_try="$ac_compile"
17564 case "(($ac_try" in
17565   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17566   *) ac_try_echo=$ac_try;;
17567 esac
17568 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17569 $as_echo "$ac_try_echo") >&5
17570   (eval "$ac_compile") 2>conftest.er1
17571   ac_status=$?
17572   grep -v '^ *+' conftest.er1 >conftest.err
17573   rm -f conftest.er1
17574   cat conftest.err >&5
17575   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17576   (exit $ac_status); } && {
17577          test -z "$ac_c_werror_flag" ||
17578          test ! -s conftest.err
17579        } && test -s conftest.$ac_objext; then
17580   ac_cv_member_krb5_ticket_enc_part2=yes
17581 else
17582   $as_echo "$as_me: failed program was:" >&5
17583 sed 's/^/| /' conftest.$ac_ext >&5
17584
17585         ac_cv_member_krb5_ticket_enc_part2=no
17586 fi
17587
17588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17589 fi
17590
17591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17592 fi
17593 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
17594 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
17595 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
17596
17597 cat >>confdefs.h <<_ACEOF
17598 #define HAVE_KRB5_TICKET_ENC_PART2 1
17599 _ACEOF
17600
17601
17602 else
17603   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
17604 $as_echo_n "checking for krb5_ticket.client... " >&6; }
17605 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
17606   $as_echo_n "(cached) " >&6
17607 else
17608   cat >conftest.$ac_ext <<_ACEOF
17609 /* confdefs.h.  */
17610 _ACEOF
17611 cat confdefs.h >>conftest.$ac_ext
17612 cat >>conftest.$ac_ext <<_ACEOF
17613 /* end confdefs.h.  */
17614 #include <krb5.h>
17615
17616 int
17617 main ()
17618 {
17619 static krb5_ticket ac_aggr;
17620 if (ac_aggr.client)
17621 return 0;
17622   ;
17623   return 0;
17624 }
17625 _ACEOF
17626 rm -f conftest.$ac_objext
17627 if { (ac_try="$ac_compile"
17628 case "(($ac_try" in
17629   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17630   *) ac_try_echo=$ac_try;;
17631 esac
17632 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17633 $as_echo "$ac_try_echo") >&5
17634   (eval "$ac_compile") 2>conftest.er1
17635   ac_status=$?
17636   grep -v '^ *+' conftest.er1 >conftest.err
17637   rm -f conftest.er1
17638   cat conftest.err >&5
17639   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17640   (exit $ac_status); } && {
17641          test -z "$ac_c_werror_flag" ||
17642          test ! -s conftest.err
17643        } && test -s conftest.$ac_objext; then
17644   ac_cv_member_krb5_ticket_client=yes
17645 else
17646   $as_echo "$as_me: failed program was:" >&5
17647 sed 's/^/| /' conftest.$ac_ext >&5
17648
17649         cat >conftest.$ac_ext <<_ACEOF
17650 /* confdefs.h.  */
17651 _ACEOF
17652 cat confdefs.h >>conftest.$ac_ext
17653 cat >>conftest.$ac_ext <<_ACEOF
17654 /* end confdefs.h.  */
17655 #include <krb5.h>
17656
17657 int
17658 main ()
17659 {
17660 static krb5_ticket ac_aggr;
17661 if (sizeof ac_aggr.client)
17662 return 0;
17663   ;
17664   return 0;
17665 }
17666 _ACEOF
17667 rm -f conftest.$ac_objext
17668 if { (ac_try="$ac_compile"
17669 case "(($ac_try" in
17670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17671   *) ac_try_echo=$ac_try;;
17672 esac
17673 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17674 $as_echo "$ac_try_echo") >&5
17675   (eval "$ac_compile") 2>conftest.er1
17676   ac_status=$?
17677   grep -v '^ *+' conftest.er1 >conftest.err
17678   rm -f conftest.er1
17679   cat conftest.err >&5
17680   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17681   (exit $ac_status); } && {
17682          test -z "$ac_c_werror_flag" ||
17683          test ! -s conftest.err
17684        } && test -s conftest.$ac_objext; then
17685   ac_cv_member_krb5_ticket_client=yes
17686 else
17687   $as_echo "$as_me: failed program was:" >&5
17688 sed 's/^/| /' conftest.$ac_ext >&5
17689
17690         ac_cv_member_krb5_ticket_client=no
17691 fi
17692
17693 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17694 fi
17695
17696 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17697 fi
17698 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
17699 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
17700 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
17701
17702 cat >>confdefs.h <<_ACEOF
17703 #define HAVE_KRB5_TICKET_CLIENT 1
17704 _ACEOF
17705
17706
17707 else
17708   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
17709 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
17710    { (exit 1); exit 1; }; }
17711 fi
17712
17713 fi
17714
17715   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
17716 $as_echo_n "checking for krb5_error.text.data... " >&6; }
17717 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
17718   $as_echo_n "(cached) " >&6
17719 else
17720   cat >conftest.$ac_ext <<_ACEOF
17721 /* confdefs.h.  */
17722 _ACEOF
17723 cat confdefs.h >>conftest.$ac_ext
17724 cat >>conftest.$ac_ext <<_ACEOF
17725 /* end confdefs.h.  */
17726 #include <krb5.h>
17727
17728 int
17729 main ()
17730 {
17731 static krb5_error ac_aggr;
17732 if (ac_aggr.text.data)
17733 return 0;
17734   ;
17735   return 0;
17736 }
17737 _ACEOF
17738 rm -f conftest.$ac_objext
17739 if { (ac_try="$ac_compile"
17740 case "(($ac_try" in
17741   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17742   *) ac_try_echo=$ac_try;;
17743 esac
17744 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17745 $as_echo "$ac_try_echo") >&5
17746   (eval "$ac_compile") 2>conftest.er1
17747   ac_status=$?
17748   grep -v '^ *+' conftest.er1 >conftest.err
17749   rm -f conftest.er1
17750   cat conftest.err >&5
17751   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17752   (exit $ac_status); } && {
17753          test -z "$ac_c_werror_flag" ||
17754          test ! -s conftest.err
17755        } && test -s conftest.$ac_objext; then
17756   ac_cv_member_krb5_error_text_data=yes
17757 else
17758   $as_echo "$as_me: failed program was:" >&5
17759 sed 's/^/| /' conftest.$ac_ext >&5
17760
17761         cat >conftest.$ac_ext <<_ACEOF
17762 /* confdefs.h.  */
17763 _ACEOF
17764 cat confdefs.h >>conftest.$ac_ext
17765 cat >>conftest.$ac_ext <<_ACEOF
17766 /* end confdefs.h.  */
17767 #include <krb5.h>
17768
17769 int
17770 main ()
17771 {
17772 static krb5_error ac_aggr;
17773 if (sizeof ac_aggr.text.data)
17774 return 0;
17775   ;
17776   return 0;
17777 }
17778 _ACEOF
17779 rm -f conftest.$ac_objext
17780 if { (ac_try="$ac_compile"
17781 case "(($ac_try" in
17782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17783   *) ac_try_echo=$ac_try;;
17784 esac
17785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17786 $as_echo "$ac_try_echo") >&5
17787   (eval "$ac_compile") 2>conftest.er1
17788   ac_status=$?
17789   grep -v '^ *+' conftest.er1 >conftest.err
17790   rm -f conftest.er1
17791   cat conftest.err >&5
17792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17793   (exit $ac_status); } && {
17794          test -z "$ac_c_werror_flag" ||
17795          test ! -s conftest.err
17796        } && test -s conftest.$ac_objext; then
17797   ac_cv_member_krb5_error_text_data=yes
17798 else
17799   $as_echo "$as_me: failed program was:" >&5
17800 sed 's/^/| /' conftest.$ac_ext >&5
17801
17802         ac_cv_member_krb5_error_text_data=no
17803 fi
17804
17805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17806 fi
17807
17808 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17809 fi
17810 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
17811 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
17812 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
17813
17814 cat >>confdefs.h <<_ACEOF
17815 #define HAVE_KRB5_ERROR_TEXT_DATA 1
17816 _ACEOF
17817
17818
17819 else
17820   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
17821 $as_echo_n "checking for krb5_error.e_data... " >&6; }
17822 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
17823   $as_echo_n "(cached) " >&6
17824 else
17825   cat >conftest.$ac_ext <<_ACEOF
17826 /* confdefs.h.  */
17827 _ACEOF
17828 cat confdefs.h >>conftest.$ac_ext
17829 cat >>conftest.$ac_ext <<_ACEOF
17830 /* end confdefs.h.  */
17831 #include <krb5.h>
17832
17833 int
17834 main ()
17835 {
17836 static krb5_error ac_aggr;
17837 if (ac_aggr.e_data)
17838 return 0;
17839   ;
17840   return 0;
17841 }
17842 _ACEOF
17843 rm -f conftest.$ac_objext
17844 if { (ac_try="$ac_compile"
17845 case "(($ac_try" in
17846   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17847   *) ac_try_echo=$ac_try;;
17848 esac
17849 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17850 $as_echo "$ac_try_echo") >&5
17851   (eval "$ac_compile") 2>conftest.er1
17852   ac_status=$?
17853   grep -v '^ *+' conftest.er1 >conftest.err
17854   rm -f conftest.er1
17855   cat conftest.err >&5
17856   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17857   (exit $ac_status); } && {
17858          test -z "$ac_c_werror_flag" ||
17859          test ! -s conftest.err
17860        } && test -s conftest.$ac_objext; then
17861   ac_cv_member_krb5_error_e_data=yes
17862 else
17863   $as_echo "$as_me: failed program was:" >&5
17864 sed 's/^/| /' conftest.$ac_ext >&5
17865
17866         cat >conftest.$ac_ext <<_ACEOF
17867 /* confdefs.h.  */
17868 _ACEOF
17869 cat confdefs.h >>conftest.$ac_ext
17870 cat >>conftest.$ac_ext <<_ACEOF
17871 /* end confdefs.h.  */
17872 #include <krb5.h>
17873
17874 int
17875 main ()
17876 {
17877 static krb5_error ac_aggr;
17878 if (sizeof ac_aggr.e_data)
17879 return 0;
17880   ;
17881   return 0;
17882 }
17883 _ACEOF
17884 rm -f conftest.$ac_objext
17885 if { (ac_try="$ac_compile"
17886 case "(($ac_try" in
17887   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17888   *) ac_try_echo=$ac_try;;
17889 esac
17890 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17891 $as_echo "$ac_try_echo") >&5
17892   (eval "$ac_compile") 2>conftest.er1
17893   ac_status=$?
17894   grep -v '^ *+' conftest.er1 >conftest.err
17895   rm -f conftest.er1
17896   cat conftest.err >&5
17897   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17898   (exit $ac_status); } && {
17899          test -z "$ac_c_werror_flag" ||
17900          test ! -s conftest.err
17901        } && test -s conftest.$ac_objext; then
17902   ac_cv_member_krb5_error_e_data=yes
17903 else
17904   $as_echo "$as_me: failed program was:" >&5
17905 sed 's/^/| /' conftest.$ac_ext >&5
17906
17907         ac_cv_member_krb5_error_e_data=no
17908 fi
17909
17910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17911 fi
17912
17913 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17914 fi
17915 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
17916 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
17917 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
17918
17919 cat >>confdefs.h <<_ACEOF
17920 #define HAVE_KRB5_ERROR_E_DATA 1
17921 _ACEOF
17922
17923
17924 else
17925   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
17926 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
17927    { (exit 1); exit 1; }; }
17928 fi
17929
17930 fi
17931
17932
17933 # Win32 requires headers to be loaded for __stdcall, so can't use
17934 # AC_CHECK_FUNCS here.
17935   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
17936 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
17937   cat >conftest.$ac_ext <<_ACEOF
17938 /* confdefs.h.  */
17939 _ACEOF
17940 cat confdefs.h >>conftest.$ac_ext
17941 cat >>conftest.$ac_ext <<_ACEOF
17942 /* end confdefs.h.  */
17943 #include <krb5.h>
17944 int
17945 main ()
17946 {
17947 krb5_free_unparsed_name(NULL,NULL);
17948   ;
17949   return 0;
17950 }
17951 _ACEOF
17952 rm -f conftest.$ac_objext conftest$ac_exeext
17953 if { (ac_try="$ac_link"
17954 case "(($ac_try" in
17955   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17956   *) ac_try_echo=$ac_try;;
17957 esac
17958 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17959 $as_echo "$ac_try_echo") >&5
17960   (eval "$ac_link") 2>conftest.er1
17961   ac_status=$?
17962   grep -v '^ *+' conftest.er1 >conftest.err
17963   rm -f conftest.er1
17964   cat conftest.err >&5
17965   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17966   (exit $ac_status); } && {
17967          test -z "$ac_c_werror_flag" ||
17968          test ! -s conftest.err
17969        } && test -s conftest$ac_exeext && {
17970          test "$cross_compiling" = yes ||
17971          $as_test_x conftest$ac_exeext
17972        }; then
17973
17974 cat >>confdefs.h <<\_ACEOF
17975 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
17976 _ACEOF
17977
17978 { $as_echo "$as_me:$LINENO: result: yes" >&5
17979 $as_echo "yes" >&6; }
17980 else
17981   $as_echo "$as_me: failed program was:" >&5
17982 sed 's/^/| /' conftest.$ac_ext >&5
17983
17984         { $as_echo "$as_me:$LINENO: result: no" >&5
17985 $as_echo "no" >&6; }
17986 fi
17987
17988 rm -rf conftest.dSYM
17989 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17990       conftest$ac_exeext conftest.$ac_ext
17991 fi
17992
17993 # Check largefile support.  You might think this is a system service not a
17994 # compiler characteristic, but you'd be wrong.  We must check this before
17995 # probing existence of related functions such as fseeko, since the largefile
17996 # defines can affect what is generated for that.
17997 # Check whether --enable-largefile was given.
17998 if test "${enable_largefile+set}" = set; then
17999   enableval=$enable_largefile;
18000 fi
18001
18002 if test "$enable_largefile" != no; then
18003
18004   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
18005 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
18006 if test "${ac_cv_sys_largefile_CC+set}" = set; then
18007   $as_echo_n "(cached) " >&6
18008 else
18009   ac_cv_sys_largefile_CC=no
18010      if test "$GCC" != yes; then
18011        ac_save_CC=$CC
18012        while :; do
18013          # IRIX 6.2 and later do not support large files by default,
18014          # so use the C compiler's -n32 option if that helps.
18015          cat >conftest.$ac_ext <<_ACEOF
18016 /* confdefs.h.  */
18017 _ACEOF
18018 cat confdefs.h >>conftest.$ac_ext
18019 cat >>conftest.$ac_ext <<_ACEOF
18020 /* end confdefs.h.  */
18021 #include <sys/types.h>
18022  /* Check that off_t can represent 2**63 - 1 correctly.
18023     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18024     since some C++ compilers masquerading as C compilers
18025     incorrectly reject 9223372036854775807.  */
18026 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18027   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18028                        && LARGE_OFF_T % 2147483647 == 1)
18029                       ? 1 : -1];
18030 int
18031 main ()
18032 {
18033
18034   ;
18035   return 0;
18036 }
18037 _ACEOF
18038          rm -f conftest.$ac_objext
18039 if { (ac_try="$ac_compile"
18040 case "(($ac_try" in
18041   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18042   *) ac_try_echo=$ac_try;;
18043 esac
18044 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18045 $as_echo "$ac_try_echo") >&5
18046   (eval "$ac_compile") 2>conftest.er1
18047   ac_status=$?
18048   grep -v '^ *+' conftest.er1 >conftest.err
18049   rm -f conftest.er1
18050   cat conftest.err >&5
18051   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18052   (exit $ac_status); } && {
18053          test -z "$ac_c_werror_flag" ||
18054          test ! -s conftest.err
18055        } && test -s conftest.$ac_objext; then
18056   break
18057 else
18058   $as_echo "$as_me: failed program was:" >&5
18059 sed 's/^/| /' conftest.$ac_ext >&5
18060
18061
18062 fi
18063
18064 rm -f core conftest.err conftest.$ac_objext
18065          CC="$CC -n32"
18066          rm -f conftest.$ac_objext
18067 if { (ac_try="$ac_compile"
18068 case "(($ac_try" in
18069   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18070   *) ac_try_echo=$ac_try;;
18071 esac
18072 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18073 $as_echo "$ac_try_echo") >&5
18074   (eval "$ac_compile") 2>conftest.er1
18075   ac_status=$?
18076   grep -v '^ *+' conftest.er1 >conftest.err
18077   rm -f conftest.er1
18078   cat conftest.err >&5
18079   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18080   (exit $ac_status); } && {
18081          test -z "$ac_c_werror_flag" ||
18082          test ! -s conftest.err
18083        } && test -s conftest.$ac_objext; then
18084   ac_cv_sys_largefile_CC=' -n32'; break
18085 else
18086   $as_echo "$as_me: failed program was:" >&5
18087 sed 's/^/| /' conftest.$ac_ext >&5
18088
18089
18090 fi
18091
18092 rm -f core conftest.err conftest.$ac_objext
18093          break
18094        done
18095        CC=$ac_save_CC
18096        rm -f conftest.$ac_ext
18097     fi
18098 fi
18099 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
18100 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
18101   if test "$ac_cv_sys_largefile_CC" != no; then
18102     CC=$CC$ac_cv_sys_largefile_CC
18103   fi
18104
18105   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
18106 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
18107 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
18108   $as_echo_n "(cached) " >&6
18109 else
18110   while :; do
18111   cat >conftest.$ac_ext <<_ACEOF
18112 /* confdefs.h.  */
18113 _ACEOF
18114 cat confdefs.h >>conftest.$ac_ext
18115 cat >>conftest.$ac_ext <<_ACEOF
18116 /* end confdefs.h.  */
18117 #include <sys/types.h>
18118  /* Check that off_t can represent 2**63 - 1 correctly.
18119     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18120     since some C++ compilers masquerading as C compilers
18121     incorrectly reject 9223372036854775807.  */
18122 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18123   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18124                        && LARGE_OFF_T % 2147483647 == 1)
18125                       ? 1 : -1];
18126 int
18127 main ()
18128 {
18129
18130   ;
18131   return 0;
18132 }
18133 _ACEOF
18134 rm -f conftest.$ac_objext
18135 if { (ac_try="$ac_compile"
18136 case "(($ac_try" in
18137   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18138   *) ac_try_echo=$ac_try;;
18139 esac
18140 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18141 $as_echo "$ac_try_echo") >&5
18142   (eval "$ac_compile") 2>conftest.er1
18143   ac_status=$?
18144   grep -v '^ *+' conftest.er1 >conftest.err
18145   rm -f conftest.er1
18146   cat conftest.err >&5
18147   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18148   (exit $ac_status); } && {
18149          test -z "$ac_c_werror_flag" ||
18150          test ! -s conftest.err
18151        } && test -s conftest.$ac_objext; then
18152   ac_cv_sys_file_offset_bits=no; break
18153 else
18154   $as_echo "$as_me: failed program was:" >&5
18155 sed 's/^/| /' conftest.$ac_ext >&5
18156
18157
18158 fi
18159
18160 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18161   cat >conftest.$ac_ext <<_ACEOF
18162 /* confdefs.h.  */
18163 _ACEOF
18164 cat confdefs.h >>conftest.$ac_ext
18165 cat >>conftest.$ac_ext <<_ACEOF
18166 /* end confdefs.h.  */
18167 #define _FILE_OFFSET_BITS 64
18168 #include <sys/types.h>
18169  /* Check that off_t can represent 2**63 - 1 correctly.
18170     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18171     since some C++ compilers masquerading as C compilers
18172     incorrectly reject 9223372036854775807.  */
18173 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18174   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18175                        && LARGE_OFF_T % 2147483647 == 1)
18176                       ? 1 : -1];
18177 int
18178 main ()
18179 {
18180
18181   ;
18182   return 0;
18183 }
18184 _ACEOF
18185 rm -f conftest.$ac_objext
18186 if { (ac_try="$ac_compile"
18187 case "(($ac_try" in
18188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18189   *) ac_try_echo=$ac_try;;
18190 esac
18191 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18192 $as_echo "$ac_try_echo") >&5
18193   (eval "$ac_compile") 2>conftest.er1
18194   ac_status=$?
18195   grep -v '^ *+' conftest.er1 >conftest.err
18196   rm -f conftest.er1
18197   cat conftest.err >&5
18198   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18199   (exit $ac_status); } && {
18200          test -z "$ac_c_werror_flag" ||
18201          test ! -s conftest.err
18202        } && test -s conftest.$ac_objext; then
18203   ac_cv_sys_file_offset_bits=64; break
18204 else
18205   $as_echo "$as_me: failed program was:" >&5
18206 sed 's/^/| /' conftest.$ac_ext >&5
18207
18208
18209 fi
18210
18211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18212   ac_cv_sys_file_offset_bits=unknown
18213   break
18214 done
18215 fi
18216 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
18217 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
18218 case $ac_cv_sys_file_offset_bits in #(
18219   no | unknown) ;;
18220   *)
18221 cat >>confdefs.h <<_ACEOF
18222 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
18223 _ACEOF
18224 ;;
18225 esac
18226 rm -rf conftest*
18227   if test $ac_cv_sys_file_offset_bits = unknown; then
18228     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
18229 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
18230 if test "${ac_cv_sys_large_files+set}" = set; then
18231   $as_echo_n "(cached) " >&6
18232 else
18233   while :; do
18234   cat >conftest.$ac_ext <<_ACEOF
18235 /* confdefs.h.  */
18236 _ACEOF
18237 cat confdefs.h >>conftest.$ac_ext
18238 cat >>conftest.$ac_ext <<_ACEOF
18239 /* end confdefs.h.  */
18240 #include <sys/types.h>
18241  /* Check that off_t can represent 2**63 - 1 correctly.
18242     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18243     since some C++ compilers masquerading as C compilers
18244     incorrectly reject 9223372036854775807.  */
18245 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18246   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18247                        && LARGE_OFF_T % 2147483647 == 1)
18248                       ? 1 : -1];
18249 int
18250 main ()
18251 {
18252
18253   ;
18254   return 0;
18255 }
18256 _ACEOF
18257 rm -f conftest.$ac_objext
18258 if { (ac_try="$ac_compile"
18259 case "(($ac_try" in
18260   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18261   *) ac_try_echo=$ac_try;;
18262 esac
18263 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18264 $as_echo "$ac_try_echo") >&5
18265   (eval "$ac_compile") 2>conftest.er1
18266   ac_status=$?
18267   grep -v '^ *+' conftest.er1 >conftest.err
18268   rm -f conftest.er1
18269   cat conftest.err >&5
18270   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18271   (exit $ac_status); } && {
18272          test -z "$ac_c_werror_flag" ||
18273          test ! -s conftest.err
18274        } && test -s conftest.$ac_objext; then
18275   ac_cv_sys_large_files=no; break
18276 else
18277   $as_echo "$as_me: failed program was:" >&5
18278 sed 's/^/| /' conftest.$ac_ext >&5
18279
18280
18281 fi
18282
18283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18284   cat >conftest.$ac_ext <<_ACEOF
18285 /* confdefs.h.  */
18286 _ACEOF
18287 cat confdefs.h >>conftest.$ac_ext
18288 cat >>conftest.$ac_ext <<_ACEOF
18289 /* end confdefs.h.  */
18290 #define _LARGE_FILES 1
18291 #include <sys/types.h>
18292  /* Check that off_t can represent 2**63 - 1 correctly.
18293     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18294     since some C++ compilers masquerading as C compilers
18295     incorrectly reject 9223372036854775807.  */
18296 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18297   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18298                        && LARGE_OFF_T % 2147483647 == 1)
18299                       ? 1 : -1];
18300 int
18301 main ()
18302 {
18303
18304   ;
18305   return 0;
18306 }
18307 _ACEOF
18308 rm -f conftest.$ac_objext
18309 if { (ac_try="$ac_compile"
18310 case "(($ac_try" in
18311   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18312   *) ac_try_echo=$ac_try;;
18313 esac
18314 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18315 $as_echo "$ac_try_echo") >&5
18316   (eval "$ac_compile") 2>conftest.er1
18317   ac_status=$?
18318   grep -v '^ *+' conftest.er1 >conftest.err
18319   rm -f conftest.er1
18320   cat conftest.err >&5
18321   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18322   (exit $ac_status); } && {
18323          test -z "$ac_c_werror_flag" ||
18324          test ! -s conftest.err
18325        } && test -s conftest.$ac_objext; then
18326   ac_cv_sys_large_files=1; break
18327 else
18328   $as_echo "$as_me: failed program was:" >&5
18329 sed 's/^/| /' conftest.$ac_ext >&5
18330
18331
18332 fi
18333
18334 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18335   ac_cv_sys_large_files=unknown
18336   break
18337 done
18338 fi
18339 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
18340 $as_echo "$ac_cv_sys_large_files" >&6; }
18341 case $ac_cv_sys_large_files in #(
18342   no | unknown) ;;
18343   *)
18344 cat >>confdefs.h <<_ACEOF
18345 #define _LARGE_FILES $ac_cv_sys_large_files
18346 _ACEOF
18347 ;;
18348 esac
18349 rm -rf conftest*
18350   fi
18351 fi
18352
18353
18354 # Check for largefile support (must be after AC_SYS_LARGEFILE)
18355 # The cast to long int works around a bug in the HP C Compiler
18356 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18357 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18358 # This bug is HP SR number 8606223364.
18359 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
18360 $as_echo_n "checking size of off_t... " >&6; }
18361 if test "${ac_cv_sizeof_off_t+set}" = set; then
18362   $as_echo_n "(cached) " >&6
18363 else
18364   if test "$cross_compiling" = yes; then
18365   # Depending upon the size, compute the lo and hi bounds.
18366 cat >conftest.$ac_ext <<_ACEOF
18367 /* confdefs.h.  */
18368 _ACEOF
18369 cat confdefs.h >>conftest.$ac_ext
18370 cat >>conftest.$ac_ext <<_ACEOF
18371 /* end confdefs.h.  */
18372 $ac_includes_default
18373 int
18374 main ()
18375 {
18376 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
18377 test_array [0] = 0
18378
18379   ;
18380   return 0;
18381 }
18382 _ACEOF
18383 rm -f conftest.$ac_objext
18384 if { (ac_try="$ac_compile"
18385 case "(($ac_try" in
18386   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18387   *) ac_try_echo=$ac_try;;
18388 esac
18389 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18390 $as_echo "$ac_try_echo") >&5
18391   (eval "$ac_compile") 2>conftest.er1
18392   ac_status=$?
18393   grep -v '^ *+' conftest.er1 >conftest.err
18394   rm -f conftest.er1
18395   cat conftest.err >&5
18396   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18397   (exit $ac_status); } && {
18398          test -z "$ac_c_werror_flag" ||
18399          test ! -s conftest.err
18400        } && test -s conftest.$ac_objext; then
18401   ac_lo=0 ac_mid=0
18402   while :; do
18403     cat >conftest.$ac_ext <<_ACEOF
18404 /* confdefs.h.  */
18405 _ACEOF
18406 cat confdefs.h >>conftest.$ac_ext
18407 cat >>conftest.$ac_ext <<_ACEOF
18408 /* end confdefs.h.  */
18409 $ac_includes_default
18410 int
18411 main ()
18412 {
18413 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18414 test_array [0] = 0
18415
18416   ;
18417   return 0;
18418 }
18419 _ACEOF
18420 rm -f conftest.$ac_objext
18421 if { (ac_try="$ac_compile"
18422 case "(($ac_try" in
18423   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18424   *) ac_try_echo=$ac_try;;
18425 esac
18426 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18427 $as_echo "$ac_try_echo") >&5
18428   (eval "$ac_compile") 2>conftest.er1
18429   ac_status=$?
18430   grep -v '^ *+' conftest.er1 >conftest.err
18431   rm -f conftest.er1
18432   cat conftest.err >&5
18433   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18434   (exit $ac_status); } && {
18435          test -z "$ac_c_werror_flag" ||
18436          test ! -s conftest.err
18437        } && test -s conftest.$ac_objext; then
18438   ac_hi=$ac_mid; break
18439 else
18440   $as_echo "$as_me: failed program was:" >&5
18441 sed 's/^/| /' conftest.$ac_ext >&5
18442
18443         ac_lo=`expr $ac_mid + 1`
18444                         if test $ac_lo -le $ac_mid; then
18445                           ac_lo= ac_hi=
18446                           break
18447                         fi
18448                         ac_mid=`expr 2 '*' $ac_mid + 1`
18449 fi
18450
18451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18452   done
18453 else
18454   $as_echo "$as_me: failed program was:" >&5
18455 sed 's/^/| /' conftest.$ac_ext >&5
18456
18457         cat >conftest.$ac_ext <<_ACEOF
18458 /* confdefs.h.  */
18459 _ACEOF
18460 cat confdefs.h >>conftest.$ac_ext
18461 cat >>conftest.$ac_ext <<_ACEOF
18462 /* end confdefs.h.  */
18463 $ac_includes_default
18464 int
18465 main ()
18466 {
18467 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
18468 test_array [0] = 0
18469
18470   ;
18471   return 0;
18472 }
18473 _ACEOF
18474 rm -f conftest.$ac_objext
18475 if { (ac_try="$ac_compile"
18476 case "(($ac_try" in
18477   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18478   *) ac_try_echo=$ac_try;;
18479 esac
18480 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18481 $as_echo "$ac_try_echo") >&5
18482   (eval "$ac_compile") 2>conftest.er1
18483   ac_status=$?
18484   grep -v '^ *+' conftest.er1 >conftest.err
18485   rm -f conftest.er1
18486   cat conftest.err >&5
18487   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18488   (exit $ac_status); } && {
18489          test -z "$ac_c_werror_flag" ||
18490          test ! -s conftest.err
18491        } && test -s conftest.$ac_objext; then
18492   ac_hi=-1 ac_mid=-1
18493   while :; do
18494     cat >conftest.$ac_ext <<_ACEOF
18495 /* confdefs.h.  */
18496 _ACEOF
18497 cat confdefs.h >>conftest.$ac_ext
18498 cat >>conftest.$ac_ext <<_ACEOF
18499 /* end confdefs.h.  */
18500 $ac_includes_default
18501 int
18502 main ()
18503 {
18504 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
18505 test_array [0] = 0
18506
18507   ;
18508   return 0;
18509 }
18510 _ACEOF
18511 rm -f conftest.$ac_objext
18512 if { (ac_try="$ac_compile"
18513 case "(($ac_try" in
18514   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18515   *) ac_try_echo=$ac_try;;
18516 esac
18517 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18518 $as_echo "$ac_try_echo") >&5
18519   (eval "$ac_compile") 2>conftest.er1
18520   ac_status=$?
18521   grep -v '^ *+' conftest.er1 >conftest.err
18522   rm -f conftest.er1
18523   cat conftest.err >&5
18524   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18525   (exit $ac_status); } && {
18526          test -z "$ac_c_werror_flag" ||
18527          test ! -s conftest.err
18528        } && test -s conftest.$ac_objext; then
18529   ac_lo=$ac_mid; break
18530 else
18531   $as_echo "$as_me: failed program was:" >&5
18532 sed 's/^/| /' conftest.$ac_ext >&5
18533
18534         ac_hi=`expr '(' $ac_mid ')' - 1`
18535                         if test $ac_mid -le $ac_hi; then
18536                           ac_lo= ac_hi=
18537                           break
18538                         fi
18539                         ac_mid=`expr 2 '*' $ac_mid`
18540 fi
18541
18542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18543   done
18544 else
18545   $as_echo "$as_me: failed program was:" >&5
18546 sed 's/^/| /' conftest.$ac_ext >&5
18547
18548         ac_lo= ac_hi=
18549 fi
18550
18551 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18552 fi
18553
18554 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18555 # Binary search between lo and hi bounds.
18556 while test "x$ac_lo" != "x$ac_hi"; do
18557   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18558   cat >conftest.$ac_ext <<_ACEOF
18559 /* confdefs.h.  */
18560 _ACEOF
18561 cat confdefs.h >>conftest.$ac_ext
18562 cat >>conftest.$ac_ext <<_ACEOF
18563 /* end confdefs.h.  */
18564 $ac_includes_default
18565 int
18566 main ()
18567 {
18568 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18569 test_array [0] = 0
18570
18571   ;
18572   return 0;
18573 }
18574 _ACEOF
18575 rm -f conftest.$ac_objext
18576 if { (ac_try="$ac_compile"
18577 case "(($ac_try" in
18578   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18579   *) ac_try_echo=$ac_try;;
18580 esac
18581 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18582 $as_echo "$ac_try_echo") >&5
18583   (eval "$ac_compile") 2>conftest.er1
18584   ac_status=$?
18585   grep -v '^ *+' conftest.er1 >conftest.err
18586   rm -f conftest.er1
18587   cat conftest.err >&5
18588   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18589   (exit $ac_status); } && {
18590          test -z "$ac_c_werror_flag" ||
18591          test ! -s conftest.err
18592        } && test -s conftest.$ac_objext; then
18593   ac_hi=$ac_mid
18594 else
18595   $as_echo "$as_me: failed program was:" >&5
18596 sed 's/^/| /' conftest.$ac_ext >&5
18597
18598         ac_lo=`expr '(' $ac_mid ')' + 1`
18599 fi
18600
18601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18602 done
18603 case $ac_lo in
18604 ?*) ac_cv_sizeof_off_t=$ac_lo;;
18605 '') if test "$ac_cv_type_off_t" = yes; then
18606      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18607 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18608 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18609 See \`config.log' for more details." >&5
18610 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18611 See \`config.log' for more details." >&2;}
18612    { (exit 77); exit 77; }; }; }
18613    else
18614      ac_cv_sizeof_off_t=0
18615    fi ;;
18616 esac
18617 else
18618   cat >conftest.$ac_ext <<_ACEOF
18619 /* confdefs.h.  */
18620 _ACEOF
18621 cat confdefs.h >>conftest.$ac_ext
18622 cat >>conftest.$ac_ext <<_ACEOF
18623 /* end confdefs.h.  */
18624 $ac_includes_default
18625 static long int longval () { return (long int) (sizeof (off_t)); }
18626 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
18627 #include <stdio.h>
18628 #include <stdlib.h>
18629 int
18630 main ()
18631 {
18632
18633   FILE *f = fopen ("conftest.val", "w");
18634   if (! f)
18635     return 1;
18636   if (((long int) (sizeof (off_t))) < 0)
18637     {
18638       long int i = longval ();
18639       if (i != ((long int) (sizeof (off_t))))
18640         return 1;
18641       fprintf (f, "%ld", i);
18642     }
18643   else
18644     {
18645       unsigned long int i = ulongval ();
18646       if (i != ((long int) (sizeof (off_t))))
18647         return 1;
18648       fprintf (f, "%lu", i);
18649     }
18650   /* Do not output a trailing newline, as this causes \r\n confusion
18651      on some platforms.  */
18652   return ferror (f) || fclose (f) != 0;
18653
18654   ;
18655   return 0;
18656 }
18657 _ACEOF
18658 rm -f conftest$ac_exeext
18659 if { (ac_try="$ac_link"
18660 case "(($ac_try" in
18661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18662   *) ac_try_echo=$ac_try;;
18663 esac
18664 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18665 $as_echo "$ac_try_echo") >&5
18666   (eval "$ac_link") 2>&5
18667   ac_status=$?
18668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18669   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18670   { (case "(($ac_try" in
18671   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18672   *) ac_try_echo=$ac_try;;
18673 esac
18674 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18675 $as_echo "$ac_try_echo") >&5
18676   (eval "$ac_try") 2>&5
18677   ac_status=$?
18678   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18679   (exit $ac_status); }; }; then
18680   ac_cv_sizeof_off_t=`cat conftest.val`
18681 else
18682   $as_echo "$as_me: program exited with status $ac_status" >&5
18683 $as_echo "$as_me: failed program was:" >&5
18684 sed 's/^/| /' conftest.$ac_ext >&5
18685
18686 ( exit $ac_status )
18687 if test "$ac_cv_type_off_t" = yes; then
18688      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18689 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18690 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18691 See \`config.log' for more details." >&5
18692 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18693 See \`config.log' for more details." >&2;}
18694    { (exit 77); exit 77; }; }; }
18695    else
18696      ac_cv_sizeof_off_t=0
18697    fi
18698 fi
18699 rm -rf conftest.dSYM
18700 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18701 fi
18702 rm -f conftest.val
18703 fi
18704 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
18705 $as_echo "$ac_cv_sizeof_off_t" >&6; }
18706
18707
18708
18709 cat >>confdefs.h <<_ACEOF
18710 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
18711 _ACEOF
18712
18713
18714
18715 # If we don't have largefile support, can't handle segsize >= 2GB.
18716 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
18717    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
18718 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
18719    { (exit 1); exit 1; }; }
18720 fi
18721
18722
18723 ##
18724 ## Functions, global variables
18725 ##
18726
18727 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
18728 $as_echo_n "checking for int timezone... " >&6; }
18729 if test "${pgac_cv_var_int_timezone+set}" = set; then
18730   $as_echo_n "(cached) " >&6
18731 else
18732   cat >conftest.$ac_ext <<_ACEOF
18733 /* confdefs.h.  */
18734 _ACEOF
18735 cat confdefs.h >>conftest.$ac_ext
18736 cat >>conftest.$ac_ext <<_ACEOF
18737 /* end confdefs.h.  */
18738 #include <time.h>
18739 int res;
18740 int
18741 main ()
18742 {
18743 #ifndef __CYGWIN__
18744 res = timezone / 60;
18745 #else
18746 res = _timezone / 60;
18747 #endif
18748   ;
18749   return 0;
18750 }
18751 _ACEOF
18752 rm -f conftest.$ac_objext conftest$ac_exeext
18753 if { (ac_try="$ac_link"
18754 case "(($ac_try" in
18755   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18756   *) ac_try_echo=$ac_try;;
18757 esac
18758 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18759 $as_echo "$ac_try_echo") >&5
18760   (eval "$ac_link") 2>conftest.er1
18761   ac_status=$?
18762   grep -v '^ *+' conftest.er1 >conftest.err
18763   rm -f conftest.er1
18764   cat conftest.err >&5
18765   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18766   (exit $ac_status); } && {
18767          test -z "$ac_c_werror_flag" ||
18768          test ! -s conftest.err
18769        } && test -s conftest$ac_exeext && {
18770          test "$cross_compiling" = yes ||
18771          $as_test_x conftest$ac_exeext
18772        }; then
18773   pgac_cv_var_int_timezone=yes
18774 else
18775   $as_echo "$as_me: failed program was:" >&5
18776 sed 's/^/| /' conftest.$ac_ext >&5
18777
18778         pgac_cv_var_int_timezone=no
18779 fi
18780
18781 rm -rf conftest.dSYM
18782 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18783       conftest$ac_exeext conftest.$ac_ext
18784 fi
18785 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
18786 $as_echo "$pgac_cv_var_int_timezone" >&6; }
18787 if test x"$pgac_cv_var_int_timezone" = xyes ; then
18788
18789 cat >>confdefs.h <<\_ACEOF
18790 #define HAVE_INT_TIMEZONE /**/
18791 _ACEOF
18792
18793 fi
18794 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
18795 $as_echo_n "checking types of arguments for accept()... " >&6; }
18796  if test "${ac_cv_func_accept_return+set}" = set; then
18797   $as_echo_n "(cached) " >&6
18798 else
18799    if test "${ac_cv_func_accept_arg1+set}" = set; then
18800   $as_echo_n "(cached) " >&6
18801 else
18802     if test "${ac_cv_func_accept_arg2+set}" = set; then
18803   $as_echo_n "(cached) " >&6
18804 else
18805      if test "${ac_cv_func_accept_arg3+set}" = set; then
18806   $as_echo_n "(cached) " >&6
18807 else
18808       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET'; do
18809       for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
18810        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
18811         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
18812          cat >conftest.$ac_ext <<_ACEOF
18813 /* confdefs.h.  */
18814 _ACEOF
18815 cat confdefs.h >>conftest.$ac_ext
18816 cat >>conftest.$ac_ext <<_ACEOF
18817 /* end confdefs.h.  */
18818 #ifdef HAVE_SYS_TYPES_H
18819 #include <sys/types.h>
18820 #endif
18821 #ifdef HAVE_SYS_SOCKET_H
18822 #include <sys/socket.h>
18823 #endif
18824 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
18825 int
18826 main ()
18827 {
18828
18829   ;
18830   return 0;
18831 }
18832 _ACEOF
18833 rm -f conftest.$ac_objext
18834 if { (ac_try="$ac_compile"
18835 case "(($ac_try" in
18836   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18837   *) ac_try_echo=$ac_try;;
18838 esac
18839 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18840 $as_echo "$ac_try_echo") >&5
18841   (eval "$ac_compile") 2>conftest.er1
18842   ac_status=$?
18843   grep -v '^ *+' conftest.er1 >conftest.err
18844   rm -f conftest.er1
18845   cat conftest.err >&5
18846   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18847   (exit $ac_status); } && {
18848          test -z "$ac_c_werror_flag" ||
18849          test ! -s conftest.err
18850        } && test -s conftest.$ac_objext; then
18851   ac_not_found=no; break 4
18852 else
18853   $as_echo "$as_me: failed program was:" >&5
18854 sed 's/^/| /' conftest.$ac_ext >&5
18855
18856         ac_not_found=yes
18857 fi
18858
18859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18860        done
18861       done
18862      done
18863     done
18864     if test "$ac_not_found" = yes; then
18865       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
18866 $as_echo "$as_me: error: could not determine argument types" >&2;}
18867    { (exit 1); exit 1; }; }
18868     fi
18869     if test "$ac_cv_func_accept_arg3" = "void"; then
18870       ac_cv_func_accept_arg3=int
18871     fi
18872
18873 fi
18874
18875 fi
18876
18877 fi
18878
18879 fi
18880  { $as_echo "$as_me:$LINENO: result: $ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&5
18881 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
18882
18883 cat >>confdefs.h <<_ACEOF
18884 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
18885 _ACEOF
18886
18887
18888 cat >>confdefs.h <<_ACEOF
18889 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
18890 _ACEOF
18891
18892
18893 cat >>confdefs.h <<_ACEOF
18894 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
18895 _ACEOF
18896
18897
18898 cat >>confdefs.h <<_ACEOF
18899 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
18900 _ACEOF
18901
18902
18903 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
18904 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
18905 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
18906   $as_echo_n "(cached) " >&6
18907 else
18908   cat >conftest.$ac_ext <<_ACEOF
18909 /* confdefs.h.  */
18910 _ACEOF
18911 cat confdefs.h >>conftest.$ac_ext
18912 cat >>conftest.$ac_ext <<_ACEOF
18913 /* end confdefs.h.  */
18914 #include <sys/time.h>
18915 int
18916 main ()
18917 {
18918 struct timeval *tp;
18919 struct timezone *tzp;
18920 gettimeofday(tp,tzp);
18921   ;
18922   return 0;
18923 }
18924 _ACEOF
18925 rm -f conftest.$ac_objext
18926 if { (ac_try="$ac_compile"
18927 case "(($ac_try" in
18928   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18929   *) ac_try_echo=$ac_try;;
18930 esac
18931 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18932 $as_echo "$ac_try_echo") >&5
18933   (eval "$ac_compile") 2>conftest.er1
18934   ac_status=$?
18935   grep -v '^ *+' conftest.er1 >conftest.err
18936   rm -f conftest.er1
18937   cat conftest.err >&5
18938   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18939   (exit $ac_status); } && {
18940          test -z "$ac_c_werror_flag" ||
18941          test ! -s conftest.err
18942        } && test -s conftest.$ac_objext; then
18943   pgac_cv_func_gettimeofday_1arg=no
18944 else
18945   $as_echo "$as_me: failed program was:" >&5
18946 sed 's/^/| /' conftest.$ac_ext >&5
18947
18948         pgac_cv_func_gettimeofday_1arg=yes
18949 fi
18950
18951 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18952 fi
18953 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
18954 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
18955 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
18956
18957 cat >>confdefs.h <<\_ACEOF
18958 #define GETTIMEOFDAY_1ARG /**/
18959 _ACEOF
18960
18961 fi
18962
18963
18964
18965
18966
18967
18968
18969
18970
18971
18972
18973
18974
18975
18976
18977
18978
18979
18980
18981
18982
18983
18984
18985
18986
18987
18988 for ac_func in cbrt dlopen fcvt fdatasync getifaddrs getpeereid getpeerucred getrlimit memmove poll pstat readlink scandir setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
18989 do
18990 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18991 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18992 $as_echo_n "checking for $ac_func... " >&6; }
18993 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18994   $as_echo_n "(cached) " >&6
18995 else
18996   cat >conftest.$ac_ext <<_ACEOF
18997 /* confdefs.h.  */
18998 _ACEOF
18999 cat confdefs.h >>conftest.$ac_ext
19000 cat >>conftest.$ac_ext <<_ACEOF
19001 /* end confdefs.h.  */
19002 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19003    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19004 #define $ac_func innocuous_$ac_func
19005
19006 /* System header to define __stub macros and hopefully few prototypes,
19007     which can conflict with char $ac_func (); below.
19008     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19009     <limits.h> exists even on freestanding compilers.  */
19010
19011 #ifdef __STDC__
19012 # include <limits.h>
19013 #else
19014 # include <assert.h>
19015 #endif
19016
19017 #undef $ac_func
19018
19019 /* Override any GCC internal prototype to avoid an error.
19020    Use char because int might match the return type of a GCC
19021    builtin and then its argument prototype would still apply.  */
19022 #ifdef __cplusplus
19023 extern "C"
19024 #endif
19025 char $ac_func ();
19026 /* The GNU C library defines this for functions which it implements
19027     to always fail with ENOSYS.  Some functions are actually named
19028     something starting with __ and the normal name is an alias.  */
19029 #if defined __stub_$ac_func || defined __stub___$ac_func
19030 choke me
19031 #endif
19032
19033 int
19034 main ()
19035 {
19036 return $ac_func ();
19037   ;
19038   return 0;
19039 }
19040 _ACEOF
19041 rm -f conftest.$ac_objext conftest$ac_exeext
19042 if { (ac_try="$ac_link"
19043 case "(($ac_try" in
19044   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19045   *) ac_try_echo=$ac_try;;
19046 esac
19047 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19048 $as_echo "$ac_try_echo") >&5
19049   (eval "$ac_link") 2>conftest.er1
19050   ac_status=$?
19051   grep -v '^ *+' conftest.er1 >conftest.err
19052   rm -f conftest.er1
19053   cat conftest.err >&5
19054   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19055   (exit $ac_status); } && {
19056          test -z "$ac_c_werror_flag" ||
19057          test ! -s conftest.err
19058        } && test -s conftest$ac_exeext && {
19059          test "$cross_compiling" = yes ||
19060          $as_test_x conftest$ac_exeext
19061        }; then
19062   eval "$as_ac_var=yes"
19063 else
19064   $as_echo "$as_me: failed program was:" >&5
19065 sed 's/^/| /' conftest.$ac_ext >&5
19066
19067         eval "$as_ac_var=no"
19068 fi
19069
19070 rm -rf conftest.dSYM
19071 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19072       conftest$ac_exeext conftest.$ac_ext
19073 fi
19074 ac_res=`eval 'as_val=${'$as_ac_var'}
19075                  $as_echo "$as_val"'`
19076                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19077 $as_echo "$ac_res" >&6; }
19078 as_val=`eval 'as_val=${'$as_ac_var'}
19079                  $as_echo "$as_val"'`
19080    if test "x$as_val" = x""yes; then
19081   cat >>confdefs.h <<_ACEOF
19082 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19083 _ACEOF
19084
19085 fi
19086 done
19087
19088
19089
19090 for ac_func in fseeko
19091 do
19092 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19093 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19094 $as_echo_n "checking for $ac_func... " >&6; }
19095 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19096   $as_echo_n "(cached) " >&6
19097 else
19098   cat >conftest.$ac_ext <<_ACEOF
19099 /* confdefs.h.  */
19100 _ACEOF
19101 cat confdefs.h >>conftest.$ac_ext
19102 cat >>conftest.$ac_ext <<_ACEOF
19103 /* end confdefs.h.  */
19104 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19105    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19106 #define $ac_func innocuous_$ac_func
19107
19108 /* System header to define __stub macros and hopefully few prototypes,
19109     which can conflict with char $ac_func (); below.
19110     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19111     <limits.h> exists even on freestanding compilers.  */
19112
19113 #ifdef __STDC__
19114 # include <limits.h>
19115 #else
19116 # include <assert.h>
19117 #endif
19118
19119 #undef $ac_func
19120
19121 /* Override any GCC internal prototype to avoid an error.
19122    Use char because int might match the return type of a GCC
19123    builtin and then its argument prototype would still apply.  */
19124 #ifdef __cplusplus
19125 extern "C"
19126 #endif
19127 char $ac_func ();
19128 /* The GNU C library defines this for functions which it implements
19129     to always fail with ENOSYS.  Some functions are actually named
19130     something starting with __ and the normal name is an alias.  */
19131 #if defined __stub_$ac_func || defined __stub___$ac_func
19132 choke me
19133 #endif
19134
19135 int
19136 main ()
19137 {
19138 return $ac_func ();
19139   ;
19140   return 0;
19141 }
19142 _ACEOF
19143 rm -f conftest.$ac_objext conftest$ac_exeext
19144 if { (ac_try="$ac_link"
19145 case "(($ac_try" in
19146   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19147   *) ac_try_echo=$ac_try;;
19148 esac
19149 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19150 $as_echo "$ac_try_echo") >&5
19151   (eval "$ac_link") 2>conftest.er1
19152   ac_status=$?
19153   grep -v '^ *+' conftest.er1 >conftest.err
19154   rm -f conftest.er1
19155   cat conftest.err >&5
19156   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19157   (exit $ac_status); } && {
19158          test -z "$ac_c_werror_flag" ||
19159          test ! -s conftest.err
19160        } && test -s conftest$ac_exeext && {
19161          test "$cross_compiling" = yes ||
19162          $as_test_x conftest$ac_exeext
19163        }; then
19164   eval "$as_ac_var=yes"
19165 else
19166   $as_echo "$as_me: failed program was:" >&5
19167 sed 's/^/| /' conftest.$ac_ext >&5
19168
19169         eval "$as_ac_var=no"
19170 fi
19171
19172 rm -rf conftest.dSYM
19173 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19174       conftest$ac_exeext conftest.$ac_ext
19175 fi
19176 ac_res=`eval 'as_val=${'$as_ac_var'}
19177                  $as_echo "$as_val"'`
19178                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19179 $as_echo "$ac_res" >&6; }
19180 as_val=`eval 'as_val=${'$as_ac_var'}
19181                  $as_echo "$as_val"'`
19182    if test "x$as_val" = x""yes; then
19183   cat >>confdefs.h <<_ACEOF
19184 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19185 _ACEOF
19186
19187 else
19188   case " $LIBOBJS " in
19189   *" $ac_func.$ac_objext "* ) ;;
19190   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19191  ;;
19192 esac
19193
19194 fi
19195 done
19196
19197
19198 case $host_os in
19199         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
19200         # Mingw uses macros to access Win32 API calls
19201         bsdi*|netbsd*|mingw*)
19202
19203 cat >>confdefs.h <<\_ACEOF
19204 #define HAVE_FSEEKO 1
19205 _ACEOF
19206
19207                 ac_cv_func_fseeko=yes;;
19208         *)
19209                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
19210 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
19211 if test "${ac_cv_sys_largefile_source+set}" = set; then
19212   $as_echo_n "(cached) " >&6
19213 else
19214   while :; do
19215   cat >conftest.$ac_ext <<_ACEOF
19216 /* confdefs.h.  */
19217 _ACEOF
19218 cat confdefs.h >>conftest.$ac_ext
19219 cat >>conftest.$ac_ext <<_ACEOF
19220 /* end confdefs.h.  */
19221 #include <sys/types.h> /* for off_t */
19222      #include <stdio.h>
19223 int
19224 main ()
19225 {
19226 int (*fp) (FILE *, off_t, int) = fseeko;
19227      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19228   ;
19229   return 0;
19230 }
19231 _ACEOF
19232 rm -f conftest.$ac_objext conftest$ac_exeext
19233 if { (ac_try="$ac_link"
19234 case "(($ac_try" in
19235   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19236   *) ac_try_echo=$ac_try;;
19237 esac
19238 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19239 $as_echo "$ac_try_echo") >&5
19240   (eval "$ac_link") 2>conftest.er1
19241   ac_status=$?
19242   grep -v '^ *+' conftest.er1 >conftest.err
19243   rm -f conftest.er1
19244   cat conftest.err >&5
19245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19246   (exit $ac_status); } && {
19247          test -z "$ac_c_werror_flag" ||
19248          test ! -s conftest.err
19249        } && test -s conftest$ac_exeext && {
19250          test "$cross_compiling" = yes ||
19251          $as_test_x conftest$ac_exeext
19252        }; then
19253   ac_cv_sys_largefile_source=no; break
19254 else
19255   $as_echo "$as_me: failed program was:" >&5
19256 sed 's/^/| /' conftest.$ac_ext >&5
19257
19258
19259 fi
19260
19261 rm -rf conftest.dSYM
19262 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19263       conftest$ac_exeext conftest.$ac_ext
19264   cat >conftest.$ac_ext <<_ACEOF
19265 /* confdefs.h.  */
19266 _ACEOF
19267 cat confdefs.h >>conftest.$ac_ext
19268 cat >>conftest.$ac_ext <<_ACEOF
19269 /* end confdefs.h.  */
19270 #define _LARGEFILE_SOURCE 1
19271 #include <sys/types.h> /* for off_t */
19272      #include <stdio.h>
19273 int
19274 main ()
19275 {
19276 int (*fp) (FILE *, off_t, int) = fseeko;
19277      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19278   ;
19279   return 0;
19280 }
19281 _ACEOF
19282 rm -f conftest.$ac_objext conftest$ac_exeext
19283 if { (ac_try="$ac_link"
19284 case "(($ac_try" in
19285   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19286   *) ac_try_echo=$ac_try;;
19287 esac
19288 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19289 $as_echo "$ac_try_echo") >&5
19290   (eval "$ac_link") 2>conftest.er1
19291   ac_status=$?
19292   grep -v '^ *+' conftest.er1 >conftest.err
19293   rm -f conftest.er1
19294   cat conftest.err >&5
19295   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19296   (exit $ac_status); } && {
19297          test -z "$ac_c_werror_flag" ||
19298          test ! -s conftest.err
19299        } && test -s conftest$ac_exeext && {
19300          test "$cross_compiling" = yes ||
19301          $as_test_x conftest$ac_exeext
19302        }; then
19303   ac_cv_sys_largefile_source=1; break
19304 else
19305   $as_echo "$as_me: failed program was:" >&5
19306 sed 's/^/| /' conftest.$ac_ext >&5
19307
19308
19309 fi
19310
19311 rm -rf conftest.dSYM
19312 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19313       conftest$ac_exeext conftest.$ac_ext
19314   ac_cv_sys_largefile_source=unknown
19315   break
19316 done
19317 fi
19318 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
19319 $as_echo "$ac_cv_sys_largefile_source" >&6; }
19320 case $ac_cv_sys_largefile_source in #(
19321   no | unknown) ;;
19322   *)
19323 cat >>confdefs.h <<_ACEOF
19324 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
19325 _ACEOF
19326 ;;
19327 esac
19328 rm -rf conftest*
19329
19330 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
19331 # in glibc 2.1.3, but that breaks too many other things.
19332 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
19333 if test $ac_cv_sys_largefile_source != unknown; then
19334
19335 cat >>confdefs.h <<\_ACEOF
19336 #define HAVE_FSEEKO 1
19337 _ACEOF
19338
19339 fi
19340 ;;
19341 esac
19342
19343 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
19344 # by calling it, 2009-04-02
19345 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
19346 if test "$PORTNAME" != "solaris"; then
19347
19348 for ac_func in posix_fadvise
19349 do
19350 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19351 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19352 $as_echo_n "checking for $ac_func... " >&6; }
19353 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19354   $as_echo_n "(cached) " >&6
19355 else
19356   cat >conftest.$ac_ext <<_ACEOF
19357 /* confdefs.h.  */
19358 _ACEOF
19359 cat confdefs.h >>conftest.$ac_ext
19360 cat >>conftest.$ac_ext <<_ACEOF
19361 /* end confdefs.h.  */
19362 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19363    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19364 #define $ac_func innocuous_$ac_func
19365
19366 /* System header to define __stub macros and hopefully few prototypes,
19367     which can conflict with char $ac_func (); below.
19368     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19369     <limits.h> exists even on freestanding compilers.  */
19370
19371 #ifdef __STDC__
19372 # include <limits.h>
19373 #else
19374 # include <assert.h>
19375 #endif
19376
19377 #undef $ac_func
19378
19379 /* Override any GCC internal prototype to avoid an error.
19380    Use char because int might match the return type of a GCC
19381    builtin and then its argument prototype would still apply.  */
19382 #ifdef __cplusplus
19383 extern "C"
19384 #endif
19385 char $ac_func ();
19386 /* The GNU C library defines this for functions which it implements
19387     to always fail with ENOSYS.  Some functions are actually named
19388     something starting with __ and the normal name is an alias.  */
19389 #if defined __stub_$ac_func || defined __stub___$ac_func
19390 choke me
19391 #endif
19392
19393 int
19394 main ()
19395 {
19396 return $ac_func ();
19397   ;
19398   return 0;
19399 }
19400 _ACEOF
19401 rm -f conftest.$ac_objext conftest$ac_exeext
19402 if { (ac_try="$ac_link"
19403 case "(($ac_try" in
19404   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19405   *) ac_try_echo=$ac_try;;
19406 esac
19407 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19408 $as_echo "$ac_try_echo") >&5
19409   (eval "$ac_link") 2>conftest.er1
19410   ac_status=$?
19411   grep -v '^ *+' conftest.er1 >conftest.err
19412   rm -f conftest.er1
19413   cat conftest.err >&5
19414   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19415   (exit $ac_status); } && {
19416          test -z "$ac_c_werror_flag" ||
19417          test ! -s conftest.err
19418        } && test -s conftest$ac_exeext && {
19419          test "$cross_compiling" = yes ||
19420          $as_test_x conftest$ac_exeext
19421        }; then
19422   eval "$as_ac_var=yes"
19423 else
19424   $as_echo "$as_me: failed program was:" >&5
19425 sed 's/^/| /' conftest.$ac_ext >&5
19426
19427         eval "$as_ac_var=no"
19428 fi
19429
19430 rm -rf conftest.dSYM
19431 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19432       conftest$ac_exeext conftest.$ac_ext
19433 fi
19434 ac_res=`eval 'as_val=${'$as_ac_var'}
19435                  $as_echo "$as_val"'`
19436                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19437 $as_echo "$ac_res" >&6; }
19438 as_val=`eval 'as_val=${'$as_ac_var'}
19439                  $as_echo "$as_val"'`
19440    if test "x$as_val" = x""yes; then
19441   cat >>confdefs.h <<_ACEOF
19442 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19443 _ACEOF
19444
19445 fi
19446 done
19447
19448 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
19449 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
19450 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
19451   $as_echo_n "(cached) " >&6
19452 else
19453   cat >conftest.$ac_ext <<_ACEOF
19454 /* confdefs.h.  */
19455 _ACEOF
19456 cat confdefs.h >>conftest.$ac_ext
19457 cat >>conftest.$ac_ext <<_ACEOF
19458 /* end confdefs.h.  */
19459 #include <fcntl.h>
19460
19461 int
19462 main ()
19463 {
19464 #ifndef posix_fadvise
19465   (void) posix_fadvise;
19466 #endif
19467
19468   ;
19469   return 0;
19470 }
19471 _ACEOF
19472 rm -f conftest.$ac_objext
19473 if { (ac_try="$ac_compile"
19474 case "(($ac_try" in
19475   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19476   *) ac_try_echo=$ac_try;;
19477 esac
19478 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19479 $as_echo "$ac_try_echo") >&5
19480   (eval "$ac_compile") 2>conftest.er1
19481   ac_status=$?
19482   grep -v '^ *+' conftest.er1 >conftest.err
19483   rm -f conftest.er1
19484   cat conftest.err >&5
19485   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19486   (exit $ac_status); } && {
19487          test -z "$ac_c_werror_flag" ||
19488          test ! -s conftest.err
19489        } && test -s conftest.$ac_objext; then
19490   ac_cv_have_decl_posix_fadvise=yes
19491 else
19492   $as_echo "$as_me: failed program was:" >&5
19493 sed 's/^/| /' conftest.$ac_ext >&5
19494
19495         ac_cv_have_decl_posix_fadvise=no
19496 fi
19497
19498 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19499 fi
19500 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
19501 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
19502 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
19503
19504 cat >>confdefs.h <<_ACEOF
19505 #define HAVE_DECL_POSIX_FADVISE 1
19506 _ACEOF
19507
19508
19509 else
19510   cat >>confdefs.h <<_ACEOF
19511 #define HAVE_DECL_POSIX_FADVISE 0
19512 _ACEOF
19513
19514
19515 fi
19516
19517
19518 fi
19519
19520 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
19521 $as_echo_n "checking whether fdatasync is declared... " >&6; }
19522 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
19523   $as_echo_n "(cached) " >&6
19524 else
19525   cat >conftest.$ac_ext <<_ACEOF
19526 /* confdefs.h.  */
19527 _ACEOF
19528 cat confdefs.h >>conftest.$ac_ext
19529 cat >>conftest.$ac_ext <<_ACEOF
19530 /* end confdefs.h.  */
19531 #include <unistd.h>
19532
19533 int
19534 main ()
19535 {
19536 #ifndef fdatasync
19537   (void) fdatasync;
19538 #endif
19539
19540   ;
19541   return 0;
19542 }
19543 _ACEOF
19544 rm -f conftest.$ac_objext
19545 if { (ac_try="$ac_compile"
19546 case "(($ac_try" in
19547   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19548   *) ac_try_echo=$ac_try;;
19549 esac
19550 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19551 $as_echo "$ac_try_echo") >&5
19552   (eval "$ac_compile") 2>conftest.er1
19553   ac_status=$?
19554   grep -v '^ *+' conftest.er1 >conftest.err
19555   rm -f conftest.er1
19556   cat conftest.err >&5
19557   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19558   (exit $ac_status); } && {
19559          test -z "$ac_c_werror_flag" ||
19560          test ! -s conftest.err
19561        } && test -s conftest.$ac_objext; then
19562   ac_cv_have_decl_fdatasync=yes
19563 else
19564   $as_echo "$as_me: failed program was:" >&5
19565 sed 's/^/| /' conftest.$ac_ext >&5
19566
19567         ac_cv_have_decl_fdatasync=no
19568 fi
19569
19570 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19571 fi
19572 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
19573 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
19574 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
19575
19576 cat >>confdefs.h <<_ACEOF
19577 #define HAVE_DECL_FDATASYNC 1
19578 _ACEOF
19579
19580
19581 else
19582   cat >>confdefs.h <<_ACEOF
19583 #define HAVE_DECL_FDATASYNC 0
19584 _ACEOF
19585
19586
19587 fi
19588
19589
19590 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
19591 $as_echo_n "checking whether strlcat is declared... " >&6; }
19592 if test "${ac_cv_have_decl_strlcat+set}" = set; then
19593   $as_echo_n "(cached) " >&6
19594 else
19595   cat >conftest.$ac_ext <<_ACEOF
19596 /* confdefs.h.  */
19597 _ACEOF
19598 cat confdefs.h >>conftest.$ac_ext
19599 cat >>conftest.$ac_ext <<_ACEOF
19600 /* end confdefs.h.  */
19601 $ac_includes_default
19602 int
19603 main ()
19604 {
19605 #ifndef strlcat
19606   (void) strlcat;
19607 #endif
19608
19609   ;
19610   return 0;
19611 }
19612 _ACEOF
19613 rm -f conftest.$ac_objext
19614 if { (ac_try="$ac_compile"
19615 case "(($ac_try" in
19616   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19617   *) ac_try_echo=$ac_try;;
19618 esac
19619 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19620 $as_echo "$ac_try_echo") >&5
19621   (eval "$ac_compile") 2>conftest.er1
19622   ac_status=$?
19623   grep -v '^ *+' conftest.er1 >conftest.err
19624   rm -f conftest.er1
19625   cat conftest.err >&5
19626   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19627   (exit $ac_status); } && {
19628          test -z "$ac_c_werror_flag" ||
19629          test ! -s conftest.err
19630        } && test -s conftest.$ac_objext; then
19631   ac_cv_have_decl_strlcat=yes
19632 else
19633   $as_echo "$as_me: failed program was:" >&5
19634 sed 's/^/| /' conftest.$ac_ext >&5
19635
19636         ac_cv_have_decl_strlcat=no
19637 fi
19638
19639 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19640 fi
19641 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
19642 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
19643 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
19644
19645 cat >>confdefs.h <<_ACEOF
19646 #define HAVE_DECL_STRLCAT 1
19647 _ACEOF
19648
19649
19650 else
19651   cat >>confdefs.h <<_ACEOF
19652 #define HAVE_DECL_STRLCAT 0
19653 _ACEOF
19654
19655
19656 fi
19657 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
19658 $as_echo_n "checking whether strlcpy is declared... " >&6; }
19659 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
19660   $as_echo_n "(cached) " >&6
19661 else
19662   cat >conftest.$ac_ext <<_ACEOF
19663 /* confdefs.h.  */
19664 _ACEOF
19665 cat confdefs.h >>conftest.$ac_ext
19666 cat >>conftest.$ac_ext <<_ACEOF
19667 /* end confdefs.h.  */
19668 $ac_includes_default
19669 int
19670 main ()
19671 {
19672 #ifndef strlcpy
19673   (void) strlcpy;
19674 #endif
19675
19676   ;
19677   return 0;
19678 }
19679 _ACEOF
19680 rm -f conftest.$ac_objext
19681 if { (ac_try="$ac_compile"
19682 case "(($ac_try" in
19683   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19684   *) ac_try_echo=$ac_try;;
19685 esac
19686 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19687 $as_echo "$ac_try_echo") >&5
19688   (eval "$ac_compile") 2>conftest.er1
19689   ac_status=$?
19690   grep -v '^ *+' conftest.er1 >conftest.err
19691   rm -f conftest.er1
19692   cat conftest.err >&5
19693   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19694   (exit $ac_status); } && {
19695          test -z "$ac_c_werror_flag" ||
19696          test ! -s conftest.err
19697        } && test -s conftest.$ac_objext; then
19698   ac_cv_have_decl_strlcpy=yes
19699 else
19700   $as_echo "$as_me: failed program was:" >&5
19701 sed 's/^/| /' conftest.$ac_ext >&5
19702
19703         ac_cv_have_decl_strlcpy=no
19704 fi
19705
19706 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19707 fi
19708 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
19709 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
19710 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
19711
19712 cat >>confdefs.h <<_ACEOF
19713 #define HAVE_DECL_STRLCPY 1
19714 _ACEOF
19715
19716
19717 else
19718   cat >>confdefs.h <<_ACEOF
19719 #define HAVE_DECL_STRLCPY 0
19720 _ACEOF
19721
19722
19723 fi
19724
19725
19726 # This is probably only present on Darwin, but may as well check always
19727 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
19728 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
19729 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
19730   $as_echo_n "(cached) " >&6
19731 else
19732   cat >conftest.$ac_ext <<_ACEOF
19733 /* confdefs.h.  */
19734 _ACEOF
19735 cat confdefs.h >>conftest.$ac_ext
19736 cat >>conftest.$ac_ext <<_ACEOF
19737 /* end confdefs.h.  */
19738 #include <fcntl.h>
19739
19740 int
19741 main ()
19742 {
19743 #ifndef F_FULLFSYNC
19744   (void) F_FULLFSYNC;
19745 #endif
19746
19747   ;
19748   return 0;
19749 }
19750 _ACEOF
19751 rm -f conftest.$ac_objext
19752 if { (ac_try="$ac_compile"
19753 case "(($ac_try" in
19754   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19755   *) ac_try_echo=$ac_try;;
19756 esac
19757 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19758 $as_echo "$ac_try_echo") >&5
19759   (eval "$ac_compile") 2>conftest.er1
19760   ac_status=$?
19761   grep -v '^ *+' conftest.er1 >conftest.err
19762   rm -f conftest.er1
19763   cat conftest.err >&5
19764   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19765   (exit $ac_status); } && {
19766          test -z "$ac_c_werror_flag" ||
19767          test ! -s conftest.err
19768        } && test -s conftest.$ac_objext; then
19769   ac_cv_have_decl_F_FULLFSYNC=yes
19770 else
19771   $as_echo "$as_me: failed program was:" >&5
19772 sed 's/^/| /' conftest.$ac_ext >&5
19773
19774         ac_cv_have_decl_F_FULLFSYNC=no
19775 fi
19776
19777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19778 fi
19779 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
19780 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
19781 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
19782
19783 cat >>confdefs.h <<_ACEOF
19784 #define HAVE_DECL_F_FULLFSYNC 1
19785 _ACEOF
19786
19787
19788 else
19789   cat >>confdefs.h <<_ACEOF
19790 #define HAVE_DECL_F_FULLFSYNC 0
19791 _ACEOF
19792
19793
19794 fi
19795
19796
19797
19798 HAVE_IPV6=no
19799 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
19800 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
19801 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
19802   $as_echo_n "(cached) " >&6
19803 else
19804   ac_cv_type_struct_sockaddr_in6=no
19805 cat >conftest.$ac_ext <<_ACEOF
19806 /* confdefs.h.  */
19807 _ACEOF
19808 cat confdefs.h >>conftest.$ac_ext
19809 cat >>conftest.$ac_ext <<_ACEOF
19810 /* end confdefs.h.  */
19811 $ac_includes_default
19812 #include <netinet/in.h>
19813
19814 int
19815 main ()
19816 {
19817 if (sizeof (struct sockaddr_in6))
19818        return 0;
19819   ;
19820   return 0;
19821 }
19822 _ACEOF
19823 rm -f conftest.$ac_objext
19824 if { (ac_try="$ac_compile"
19825 case "(($ac_try" in
19826   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19827   *) ac_try_echo=$ac_try;;
19828 esac
19829 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19830 $as_echo "$ac_try_echo") >&5
19831   (eval "$ac_compile") 2>conftest.er1
19832   ac_status=$?
19833   grep -v '^ *+' conftest.er1 >conftest.err
19834   rm -f conftest.er1
19835   cat conftest.err >&5
19836   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19837   (exit $ac_status); } && {
19838          test -z "$ac_c_werror_flag" ||
19839          test ! -s conftest.err
19840        } && test -s conftest.$ac_objext; then
19841   cat >conftest.$ac_ext <<_ACEOF
19842 /* confdefs.h.  */
19843 _ACEOF
19844 cat confdefs.h >>conftest.$ac_ext
19845 cat >>conftest.$ac_ext <<_ACEOF
19846 /* end confdefs.h.  */
19847 $ac_includes_default
19848 #include <netinet/in.h>
19849
19850 int
19851 main ()
19852 {
19853 if (sizeof ((struct sockaddr_in6)))
19854           return 0;
19855   ;
19856   return 0;
19857 }
19858 _ACEOF
19859 rm -f conftest.$ac_objext
19860 if { (ac_try="$ac_compile"
19861 case "(($ac_try" in
19862   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19863   *) ac_try_echo=$ac_try;;
19864 esac
19865 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19866 $as_echo "$ac_try_echo") >&5
19867   (eval "$ac_compile") 2>conftest.er1
19868   ac_status=$?
19869   grep -v '^ *+' conftest.er1 >conftest.err
19870   rm -f conftest.er1
19871   cat conftest.err >&5
19872   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19873   (exit $ac_status); } && {
19874          test -z "$ac_c_werror_flag" ||
19875          test ! -s conftest.err
19876        } && test -s conftest.$ac_objext; then
19877   :
19878 else
19879   $as_echo "$as_me: failed program was:" >&5
19880 sed 's/^/| /' conftest.$ac_ext >&5
19881
19882         ac_cv_type_struct_sockaddr_in6=yes
19883 fi
19884
19885 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19886 else
19887   $as_echo "$as_me: failed program was:" >&5
19888 sed 's/^/| /' conftest.$ac_ext >&5
19889
19890
19891 fi
19892
19893 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19894 fi
19895 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
19896 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
19897 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
19898
19899 cat >>confdefs.h <<\_ACEOF
19900 #define HAVE_IPV6 1
19901 _ACEOF
19902
19903          HAVE_IPV6=yes
19904 fi
19905
19906
19907
19908 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
19909 $as_echo_n "checking for PS_STRINGS... " >&6; }
19910 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
19911   $as_echo_n "(cached) " >&6
19912 else
19913   cat >conftest.$ac_ext <<_ACEOF
19914 /* confdefs.h.  */
19915 _ACEOF
19916 cat confdefs.h >>conftest.$ac_ext
19917 cat >>conftest.$ac_ext <<_ACEOF
19918 /* end confdefs.h.  */
19919 #include <machine/vmparam.h>
19920 #include <sys/exec.h>
19921
19922 int
19923 main ()
19924 {
19925 PS_STRINGS->ps_nargvstr = 1;
19926 PS_STRINGS->ps_argvstr = "foo";
19927   ;
19928   return 0;
19929 }
19930 _ACEOF
19931 rm -f conftest.$ac_objext conftest$ac_exeext
19932 if { (ac_try="$ac_link"
19933 case "(($ac_try" in
19934   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19935   *) ac_try_echo=$ac_try;;
19936 esac
19937 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19938 $as_echo "$ac_try_echo") >&5
19939   (eval "$ac_link") 2>conftest.er1
19940   ac_status=$?
19941   grep -v '^ *+' conftest.er1 >conftest.err
19942   rm -f conftest.er1
19943   cat conftest.err >&5
19944   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19945   (exit $ac_status); } && {
19946          test -z "$ac_c_werror_flag" ||
19947          test ! -s conftest.err
19948        } && test -s conftest$ac_exeext && {
19949          test "$cross_compiling" = yes ||
19950          $as_test_x conftest$ac_exeext
19951        }; then
19952   pgac_cv_var_PS_STRINGS=yes
19953 else
19954   $as_echo "$as_me: failed program was:" >&5
19955 sed 's/^/| /' conftest.$ac_ext >&5
19956
19957         pgac_cv_var_PS_STRINGS=no
19958 fi
19959
19960 rm -rf conftest.dSYM
19961 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19962       conftest$ac_exeext conftest.$ac_ext
19963 fi
19964 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
19965 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
19966 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
19967
19968 cat >>confdefs.h <<\_ACEOF
19969 #define HAVE_PS_STRINGS /**/
19970 _ACEOF
19971
19972 fi
19973
19974
19975 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
19976 # is missing.  Yes, there are machines that have only one.  We may
19977 # also decide to use snprintf.c if snprintf() is present but does not
19978 # have all the features we need --- see below.
19979
19980 if test "$PORTNAME" = "win32"; then
19981   # Win32 gets snprintf.c built unconditionally.
19982   #
19983   # To properly translate all NLS languages strings, we must support the
19984   # *printf() %$ format, which allows *printf() arguments to be selected
19985   # by position in the translated string.
19986   #
19987   # libintl versions < 0.13 use the native *printf() functions, and Win32
19988   # *printf() doesn't understand %$, so we must use our /port versions,
19989   # which do understand %$. libintl versions >= 0.13 include their own
19990   # *printf versions on Win32.  The libintl 0.13 release note text is:
19991   #
19992   #   C format strings with positions, as they arise when a translator
19993   #   needs to reorder a sentence, are now supported on all platforms.
19994   #   On those few platforms (NetBSD and Woe32) for which the native
19995   #   printf()/fprintf()/... functions don't support such format
19996   #   strings, replacements are provided through <libintl.h>.
19997   #
19998   # We could use libintl >= 0.13's *printf() if we were sure that we had
19999   # a litint >= 0.13 at runtime, but seeing that there is no clean way
20000   # to guarantee that, it is best to just use our own, so we are sure to
20001   # get %$ support. In include/port.h we disable the *printf() macros
20002   # that might have been defined by libintl.
20003   #
20004   # We do this unconditionally whether NLS is used or not so we are sure
20005   # that all Win32 libraries and binaries behave the same.
20006   pgac_need_repl_snprintf=yes
20007 else
20008   pgac_need_repl_snprintf=no
20009
20010 for ac_func in snprintf
20011 do
20012 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20013 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20014 $as_echo_n "checking for $ac_func... " >&6; }
20015 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20016   $as_echo_n "(cached) " >&6
20017 else
20018   cat >conftest.$ac_ext <<_ACEOF
20019 /* confdefs.h.  */
20020 _ACEOF
20021 cat confdefs.h >>conftest.$ac_ext
20022 cat >>conftest.$ac_ext <<_ACEOF
20023 /* end confdefs.h.  */
20024 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20025    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20026 #define $ac_func innocuous_$ac_func
20027
20028 /* System header to define __stub macros and hopefully few prototypes,
20029     which can conflict with char $ac_func (); below.
20030     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20031     <limits.h> exists even on freestanding compilers.  */
20032
20033 #ifdef __STDC__
20034 # include <limits.h>
20035 #else
20036 # include <assert.h>
20037 #endif
20038
20039 #undef $ac_func
20040
20041 /* Override any GCC internal prototype to avoid an error.
20042    Use char because int might match the return type of a GCC
20043    builtin and then its argument prototype would still apply.  */
20044 #ifdef __cplusplus
20045 extern "C"
20046 #endif
20047 char $ac_func ();
20048 /* The GNU C library defines this for functions which it implements
20049     to always fail with ENOSYS.  Some functions are actually named
20050     something starting with __ and the normal name is an alias.  */
20051 #if defined __stub_$ac_func || defined __stub___$ac_func
20052 choke me
20053 #endif
20054
20055 int
20056 main ()
20057 {
20058 return $ac_func ();
20059   ;
20060   return 0;
20061 }
20062 _ACEOF
20063 rm -f conftest.$ac_objext conftest$ac_exeext
20064 if { (ac_try="$ac_link"
20065 case "(($ac_try" in
20066   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20067   *) ac_try_echo=$ac_try;;
20068 esac
20069 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20070 $as_echo "$ac_try_echo") >&5
20071   (eval "$ac_link") 2>conftest.er1
20072   ac_status=$?
20073   grep -v '^ *+' conftest.er1 >conftest.err
20074   rm -f conftest.er1
20075   cat conftest.err >&5
20076   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20077   (exit $ac_status); } && {
20078          test -z "$ac_c_werror_flag" ||
20079          test ! -s conftest.err
20080        } && test -s conftest$ac_exeext && {
20081          test "$cross_compiling" = yes ||
20082          $as_test_x conftest$ac_exeext
20083        }; then
20084   eval "$as_ac_var=yes"
20085 else
20086   $as_echo "$as_me: failed program was:" >&5
20087 sed 's/^/| /' conftest.$ac_ext >&5
20088
20089         eval "$as_ac_var=no"
20090 fi
20091
20092 rm -rf conftest.dSYM
20093 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20094       conftest$ac_exeext conftest.$ac_ext
20095 fi
20096 ac_res=`eval 'as_val=${'$as_ac_var'}
20097                  $as_echo "$as_val"'`
20098                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20099 $as_echo "$ac_res" >&6; }
20100 as_val=`eval 'as_val=${'$as_ac_var'}
20101                  $as_echo "$as_val"'`
20102    if test "x$as_val" = x""yes; then
20103   cat >>confdefs.h <<_ACEOF
20104 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20105 _ACEOF
20106
20107 else
20108   pgac_need_repl_snprintf=yes
20109 fi
20110 done
20111
20112
20113 for ac_func in vsnprintf
20114 do
20115 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20116 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20117 $as_echo_n "checking for $ac_func... " >&6; }
20118 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20119   $as_echo_n "(cached) " >&6
20120 else
20121   cat >conftest.$ac_ext <<_ACEOF
20122 /* confdefs.h.  */
20123 _ACEOF
20124 cat confdefs.h >>conftest.$ac_ext
20125 cat >>conftest.$ac_ext <<_ACEOF
20126 /* end confdefs.h.  */
20127 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20128    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20129 #define $ac_func innocuous_$ac_func
20130
20131 /* System header to define __stub macros and hopefully few prototypes,
20132     which can conflict with char $ac_func (); below.
20133     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20134     <limits.h> exists even on freestanding compilers.  */
20135
20136 #ifdef __STDC__
20137 # include <limits.h>
20138 #else
20139 # include <assert.h>
20140 #endif
20141
20142 #undef $ac_func
20143
20144 /* Override any GCC internal prototype to avoid an error.
20145    Use char because int might match the return type of a GCC
20146    builtin and then its argument prototype would still apply.  */
20147 #ifdef __cplusplus
20148 extern "C"
20149 #endif
20150 char $ac_func ();
20151 /* The GNU C library defines this for functions which it implements
20152     to always fail with ENOSYS.  Some functions are actually named
20153     something starting with __ and the normal name is an alias.  */
20154 #if defined __stub_$ac_func || defined __stub___$ac_func
20155 choke me
20156 #endif
20157
20158 int
20159 main ()
20160 {
20161 return $ac_func ();
20162   ;
20163   return 0;
20164 }
20165 _ACEOF
20166 rm -f conftest.$ac_objext conftest$ac_exeext
20167 if { (ac_try="$ac_link"
20168 case "(($ac_try" in
20169   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20170   *) ac_try_echo=$ac_try;;
20171 esac
20172 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20173 $as_echo "$ac_try_echo") >&5
20174   (eval "$ac_link") 2>conftest.er1
20175   ac_status=$?
20176   grep -v '^ *+' conftest.er1 >conftest.err
20177   rm -f conftest.er1
20178   cat conftest.err >&5
20179   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20180   (exit $ac_status); } && {
20181          test -z "$ac_c_werror_flag" ||
20182          test ! -s conftest.err
20183        } && test -s conftest$ac_exeext && {
20184          test "$cross_compiling" = yes ||
20185          $as_test_x conftest$ac_exeext
20186        }; then
20187   eval "$as_ac_var=yes"
20188 else
20189   $as_echo "$as_me: failed program was:" >&5
20190 sed 's/^/| /' conftest.$ac_ext >&5
20191
20192         eval "$as_ac_var=no"
20193 fi
20194
20195 rm -rf conftest.dSYM
20196 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20197       conftest$ac_exeext conftest.$ac_ext
20198 fi
20199 ac_res=`eval 'as_val=${'$as_ac_var'}
20200                  $as_echo "$as_val"'`
20201                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20202 $as_echo "$ac_res" >&6; }
20203 as_val=`eval 'as_val=${'$as_ac_var'}
20204                  $as_echo "$as_val"'`
20205    if test "x$as_val" = x""yes; then
20206   cat >>confdefs.h <<_ACEOF
20207 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20208 _ACEOF
20209
20210 else
20211   pgac_need_repl_snprintf=yes
20212 fi
20213 done
20214
20215 fi
20216
20217
20218 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
20219 # include/c.h will provide declarations.  Note this is a separate test
20220 # from whether the functions exist in the C library --- there are
20221 # systems that have the functions but don't bother to declare them :-(
20222
20223 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
20224 $as_echo_n "checking whether snprintf is declared... " >&6; }
20225 if test "${ac_cv_have_decl_snprintf+set}" = set; then
20226   $as_echo_n "(cached) " >&6
20227 else
20228   cat >conftest.$ac_ext <<_ACEOF
20229 /* confdefs.h.  */
20230 _ACEOF
20231 cat confdefs.h >>conftest.$ac_ext
20232 cat >>conftest.$ac_ext <<_ACEOF
20233 /* end confdefs.h.  */
20234 $ac_includes_default
20235 int
20236 main ()
20237 {
20238 #ifndef snprintf
20239   (void) snprintf;
20240 #endif
20241
20242   ;
20243   return 0;
20244 }
20245 _ACEOF
20246 rm -f conftest.$ac_objext
20247 if { (ac_try="$ac_compile"
20248 case "(($ac_try" in
20249   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20250   *) ac_try_echo=$ac_try;;
20251 esac
20252 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20253 $as_echo "$ac_try_echo") >&5
20254   (eval "$ac_compile") 2>conftest.er1
20255   ac_status=$?
20256   grep -v '^ *+' conftest.er1 >conftest.err
20257   rm -f conftest.er1
20258   cat conftest.err >&5
20259   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20260   (exit $ac_status); } && {
20261          test -z "$ac_c_werror_flag" ||
20262          test ! -s conftest.err
20263        } && test -s conftest.$ac_objext; then
20264   ac_cv_have_decl_snprintf=yes
20265 else
20266   $as_echo "$as_me: failed program was:" >&5
20267 sed 's/^/| /' conftest.$ac_ext >&5
20268
20269         ac_cv_have_decl_snprintf=no
20270 fi
20271
20272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20273 fi
20274 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
20275 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
20276 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
20277
20278 cat >>confdefs.h <<_ACEOF
20279 #define HAVE_DECL_SNPRINTF 1
20280 _ACEOF
20281
20282
20283 else
20284   cat >>confdefs.h <<_ACEOF
20285 #define HAVE_DECL_SNPRINTF 0
20286 _ACEOF
20287
20288
20289 fi
20290 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
20291 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
20292 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
20293   $as_echo_n "(cached) " >&6
20294 else
20295   cat >conftest.$ac_ext <<_ACEOF
20296 /* confdefs.h.  */
20297 _ACEOF
20298 cat confdefs.h >>conftest.$ac_ext
20299 cat >>conftest.$ac_ext <<_ACEOF
20300 /* end confdefs.h.  */
20301 $ac_includes_default
20302 int
20303 main ()
20304 {
20305 #ifndef vsnprintf
20306   (void) vsnprintf;
20307 #endif
20308
20309   ;
20310   return 0;
20311 }
20312 _ACEOF
20313 rm -f conftest.$ac_objext
20314 if { (ac_try="$ac_compile"
20315 case "(($ac_try" in
20316   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20317   *) ac_try_echo=$ac_try;;
20318 esac
20319 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20320 $as_echo "$ac_try_echo") >&5
20321   (eval "$ac_compile") 2>conftest.er1
20322   ac_status=$?
20323   grep -v '^ *+' conftest.er1 >conftest.err
20324   rm -f conftest.er1
20325   cat conftest.err >&5
20326   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20327   (exit $ac_status); } && {
20328          test -z "$ac_c_werror_flag" ||
20329          test ! -s conftest.err
20330        } && test -s conftest.$ac_objext; then
20331   ac_cv_have_decl_vsnprintf=yes
20332 else
20333   $as_echo "$as_me: failed program was:" >&5
20334 sed 's/^/| /' conftest.$ac_ext >&5
20335
20336         ac_cv_have_decl_vsnprintf=no
20337 fi
20338
20339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20340 fi
20341 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
20342 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
20343 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
20344
20345 cat >>confdefs.h <<_ACEOF
20346 #define HAVE_DECL_VSNPRINTF 1
20347 _ACEOF
20348
20349
20350 else
20351   cat >>confdefs.h <<_ACEOF
20352 #define HAVE_DECL_VSNPRINTF 0
20353 _ACEOF
20354
20355
20356 fi
20357
20358
20359
20360
20361 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
20362 $as_echo_n "checking for isinf... " >&6; }
20363 if test "${ac_cv_func_isinf+set}" = set; then
20364   $as_echo_n "(cached) " >&6
20365 else
20366   cat >conftest.$ac_ext <<_ACEOF
20367 /* confdefs.h.  */
20368 _ACEOF
20369 cat confdefs.h >>conftest.$ac_ext
20370 cat >>conftest.$ac_ext <<_ACEOF
20371 /* end confdefs.h.  */
20372
20373 #include <math.h>
20374 double glob_double;
20375
20376 int
20377 main ()
20378 {
20379 return isinf(glob_double) ? 0 : 1;
20380   ;
20381   return 0;
20382 }
20383 _ACEOF
20384 rm -f conftest.$ac_objext conftest$ac_exeext
20385 if { (ac_try="$ac_link"
20386 case "(($ac_try" in
20387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20388   *) ac_try_echo=$ac_try;;
20389 esac
20390 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20391 $as_echo "$ac_try_echo") >&5
20392   (eval "$ac_link") 2>conftest.er1
20393   ac_status=$?
20394   grep -v '^ *+' conftest.er1 >conftest.err
20395   rm -f conftest.er1
20396   cat conftest.err >&5
20397   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20398   (exit $ac_status); } && {
20399          test -z "$ac_c_werror_flag" ||
20400          test ! -s conftest.err
20401        } && test -s conftest$ac_exeext && {
20402          test "$cross_compiling" = yes ||
20403          $as_test_x conftest$ac_exeext
20404        }; then
20405   ac_cv_func_isinf=yes
20406 else
20407   $as_echo "$as_me: failed program was:" >&5
20408 sed 's/^/| /' conftest.$ac_ext >&5
20409
20410         ac_cv_func_isinf=no
20411 fi
20412
20413 rm -rf conftest.dSYM
20414 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20415       conftest$ac_exeext conftest.$ac_ext
20416 fi
20417 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
20418 $as_echo "$ac_cv_func_isinf" >&6; }
20419
20420 if test $ac_cv_func_isinf = yes ; then
20421
20422 cat >>confdefs.h <<\_ACEOF
20423 #define HAVE_ISINF 1
20424 _ACEOF
20425
20426 else
20427   case " $LIBOBJS " in
20428   *" isinf.$ac_objext "* ) ;;
20429   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
20430  ;;
20431 esac
20432
20433   # Look for a way to implement a substitute for isinf()
20434
20435
20436
20437
20438 for ac_func in fpclass fp_class fp_class_d class
20439 do
20440 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20441 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20442 $as_echo_n "checking for $ac_func... " >&6; }
20443 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20444   $as_echo_n "(cached) " >&6
20445 else
20446   cat >conftest.$ac_ext <<_ACEOF
20447 /* confdefs.h.  */
20448 _ACEOF
20449 cat confdefs.h >>conftest.$ac_ext
20450 cat >>conftest.$ac_ext <<_ACEOF
20451 /* end confdefs.h.  */
20452 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20453    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20454 #define $ac_func innocuous_$ac_func
20455
20456 /* System header to define __stub macros and hopefully few prototypes,
20457     which can conflict with char $ac_func (); below.
20458     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20459     <limits.h> exists even on freestanding compilers.  */
20460
20461 #ifdef __STDC__
20462 # include <limits.h>
20463 #else
20464 # include <assert.h>
20465 #endif
20466
20467 #undef $ac_func
20468
20469 /* Override any GCC internal prototype to avoid an error.
20470    Use char because int might match the return type of a GCC
20471    builtin and then its argument prototype would still apply.  */
20472 #ifdef __cplusplus
20473 extern "C"
20474 #endif
20475 char $ac_func ();
20476 /* The GNU C library defines this for functions which it implements
20477     to always fail with ENOSYS.  Some functions are actually named
20478     something starting with __ and the normal name is an alias.  */
20479 #if defined __stub_$ac_func || defined __stub___$ac_func
20480 choke me
20481 #endif
20482
20483 int
20484 main ()
20485 {
20486 return $ac_func ();
20487   ;
20488   return 0;
20489 }
20490 _ACEOF
20491 rm -f conftest.$ac_objext conftest$ac_exeext
20492 if { (ac_try="$ac_link"
20493 case "(($ac_try" in
20494   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20495   *) ac_try_echo=$ac_try;;
20496 esac
20497 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20498 $as_echo "$ac_try_echo") >&5
20499   (eval "$ac_link") 2>conftest.er1
20500   ac_status=$?
20501   grep -v '^ *+' conftest.er1 >conftest.err
20502   rm -f conftest.er1
20503   cat conftest.err >&5
20504   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20505   (exit $ac_status); } && {
20506          test -z "$ac_c_werror_flag" ||
20507          test ! -s conftest.err
20508        } && test -s conftest$ac_exeext && {
20509          test "$cross_compiling" = yes ||
20510          $as_test_x conftest$ac_exeext
20511        }; then
20512   eval "$as_ac_var=yes"
20513 else
20514   $as_echo "$as_me: failed program was:" >&5
20515 sed 's/^/| /' conftest.$ac_ext >&5
20516
20517         eval "$as_ac_var=no"
20518 fi
20519
20520 rm -rf conftest.dSYM
20521 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20522       conftest$ac_exeext conftest.$ac_ext
20523 fi
20524 ac_res=`eval 'as_val=${'$as_ac_var'}
20525                  $as_echo "$as_val"'`
20526                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20527 $as_echo "$ac_res" >&6; }
20528 as_val=`eval 'as_val=${'$as_ac_var'}
20529                  $as_echo "$as_val"'`
20530    if test "x$as_val" = x""yes; then
20531   cat >>confdefs.h <<_ACEOF
20532 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20533 _ACEOF
20534  break
20535 fi
20536 done
20537
20538 fi
20539
20540 # Some versions of libedit contain strlcpy(); so disregard that library while
20541 # checking for these standard libc functions.
20542 pgac_save_LIBS="$LIBS"
20543 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
20544
20545
20546
20547
20548
20549
20550
20551
20552
20553
20554
20555
20556
20557
20558
20559 for ac_func in crypt erand48 getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul
20560 do
20561 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20562 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20563 $as_echo_n "checking for $ac_func... " >&6; }
20564 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20565   $as_echo_n "(cached) " >&6
20566 else
20567   cat >conftest.$ac_ext <<_ACEOF
20568 /* confdefs.h.  */
20569 _ACEOF
20570 cat confdefs.h >>conftest.$ac_ext
20571 cat >>conftest.$ac_ext <<_ACEOF
20572 /* end confdefs.h.  */
20573 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20574    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20575 #define $ac_func innocuous_$ac_func
20576
20577 /* System header to define __stub macros and hopefully few prototypes,
20578     which can conflict with char $ac_func (); below.
20579     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20580     <limits.h> exists even on freestanding compilers.  */
20581
20582 #ifdef __STDC__
20583 # include <limits.h>
20584 #else
20585 # include <assert.h>
20586 #endif
20587
20588 #undef $ac_func
20589
20590 /* Override any GCC internal prototype to avoid an error.
20591    Use char because int might match the return type of a GCC
20592    builtin and then its argument prototype would still apply.  */
20593 #ifdef __cplusplus
20594 extern "C"
20595 #endif
20596 char $ac_func ();
20597 /* The GNU C library defines this for functions which it implements
20598     to always fail with ENOSYS.  Some functions are actually named
20599     something starting with __ and the normal name is an alias.  */
20600 #if defined __stub_$ac_func || defined __stub___$ac_func
20601 choke me
20602 #endif
20603
20604 int
20605 main ()
20606 {
20607 return $ac_func ();
20608   ;
20609   return 0;
20610 }
20611 _ACEOF
20612 rm -f conftest.$ac_objext conftest$ac_exeext
20613 if { (ac_try="$ac_link"
20614 case "(($ac_try" in
20615   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20616   *) ac_try_echo=$ac_try;;
20617 esac
20618 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20619 $as_echo "$ac_try_echo") >&5
20620   (eval "$ac_link") 2>conftest.er1
20621   ac_status=$?
20622   grep -v '^ *+' conftest.er1 >conftest.err
20623   rm -f conftest.er1
20624   cat conftest.err >&5
20625   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20626   (exit $ac_status); } && {
20627          test -z "$ac_c_werror_flag" ||
20628          test ! -s conftest.err
20629        } && test -s conftest$ac_exeext && {
20630          test "$cross_compiling" = yes ||
20631          $as_test_x conftest$ac_exeext
20632        }; then
20633   eval "$as_ac_var=yes"
20634 else
20635   $as_echo "$as_me: failed program was:" >&5
20636 sed 's/^/| /' conftest.$ac_ext >&5
20637
20638         eval "$as_ac_var=no"
20639 fi
20640
20641 rm -rf conftest.dSYM
20642 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20643       conftest$ac_exeext conftest.$ac_ext
20644 fi
20645 ac_res=`eval 'as_val=${'$as_ac_var'}
20646                  $as_echo "$as_val"'`
20647                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20648 $as_echo "$ac_res" >&6; }
20649 as_val=`eval 'as_val=${'$as_ac_var'}
20650                  $as_echo "$as_val"'`
20651    if test "x$as_val" = x""yes; then
20652   cat >>confdefs.h <<_ACEOF
20653 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20654 _ACEOF
20655
20656 else
20657   case " $LIBOBJS " in
20658   *" $ac_func.$ac_objext "* ) ;;
20659   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20660  ;;
20661 esac
20662
20663 fi
20664 done
20665
20666
20667
20668 case $host_os in
20669
20670         # Windows uses a specialised env handler
20671         mingw*)
20672
20673 cat >>confdefs.h <<\_ACEOF
20674 #define HAVE_UNSETENV 1
20675 _ACEOF
20676
20677                 ac_cv_func_unsetenv=yes;;
20678         *)
20679
20680 for ac_func in unsetenv
20681 do
20682 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20683 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20684 $as_echo_n "checking for $ac_func... " >&6; }
20685 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20686   $as_echo_n "(cached) " >&6
20687 else
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 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20695    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20696 #define $ac_func innocuous_$ac_func
20697
20698 /* System header to define __stub macros and hopefully few prototypes,
20699     which can conflict with char $ac_func (); below.
20700     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20701     <limits.h> exists even on freestanding compilers.  */
20702
20703 #ifdef __STDC__
20704 # include <limits.h>
20705 #else
20706 # include <assert.h>
20707 #endif
20708
20709 #undef $ac_func
20710
20711 /* Override any GCC internal prototype to avoid an error.
20712    Use char because int might match the return type of a GCC
20713    builtin and then its argument prototype would still apply.  */
20714 #ifdef __cplusplus
20715 extern "C"
20716 #endif
20717 char $ac_func ();
20718 /* The GNU C library defines this for functions which it implements
20719     to always fail with ENOSYS.  Some functions are actually named
20720     something starting with __ and the normal name is an alias.  */
20721 #if defined __stub_$ac_func || defined __stub___$ac_func
20722 choke me
20723 #endif
20724
20725 int
20726 main ()
20727 {
20728 return $ac_func ();
20729   ;
20730   return 0;
20731 }
20732 _ACEOF
20733 rm -f conftest.$ac_objext conftest$ac_exeext
20734 if { (ac_try="$ac_link"
20735 case "(($ac_try" in
20736   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20737   *) ac_try_echo=$ac_try;;
20738 esac
20739 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20740 $as_echo "$ac_try_echo") >&5
20741   (eval "$ac_link") 2>conftest.er1
20742   ac_status=$?
20743   grep -v '^ *+' conftest.er1 >conftest.err
20744   rm -f conftest.er1
20745   cat conftest.err >&5
20746   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20747   (exit $ac_status); } && {
20748          test -z "$ac_c_werror_flag" ||
20749          test ! -s conftest.err
20750        } && test -s conftest$ac_exeext && {
20751          test "$cross_compiling" = yes ||
20752          $as_test_x conftest$ac_exeext
20753        }; then
20754   eval "$as_ac_var=yes"
20755 else
20756   $as_echo "$as_me: failed program was:" >&5
20757 sed 's/^/| /' conftest.$ac_ext >&5
20758
20759         eval "$as_ac_var=no"
20760 fi
20761
20762 rm -rf conftest.dSYM
20763 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20764       conftest$ac_exeext conftest.$ac_ext
20765 fi
20766 ac_res=`eval 'as_val=${'$as_ac_var'}
20767                  $as_echo "$as_val"'`
20768                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20769 $as_echo "$ac_res" >&6; }
20770 as_val=`eval 'as_val=${'$as_ac_var'}
20771                  $as_echo "$as_val"'`
20772    if test "x$as_val" = x""yes; then
20773   cat >>confdefs.h <<_ACEOF
20774 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20775 _ACEOF
20776
20777 else
20778   case " $LIBOBJS " in
20779   *" $ac_func.$ac_objext "* ) ;;
20780   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20781  ;;
20782 esac
20783
20784 fi
20785 done
20786
20787
20788                 ;;
20789 esac
20790
20791
20792 LIBS="$pgac_save_LIBS"
20793
20794 # System's version of getaddrinfo(), if any, may be used only if we found
20795 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
20796 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
20797 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
20798 # because we want to use our own getaddrinfo.c on Windows anyway.)
20799 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
20800
20801 for ac_func in getaddrinfo
20802 do
20803 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20804 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20805 $as_echo_n "checking for $ac_func... " >&6; }
20806 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20807   $as_echo_n "(cached) " >&6
20808 else
20809   cat >conftest.$ac_ext <<_ACEOF
20810 /* confdefs.h.  */
20811 _ACEOF
20812 cat confdefs.h >>conftest.$ac_ext
20813 cat >>conftest.$ac_ext <<_ACEOF
20814 /* end confdefs.h.  */
20815 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20816    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20817 #define $ac_func innocuous_$ac_func
20818
20819 /* System header to define __stub macros and hopefully few prototypes,
20820     which can conflict with char $ac_func (); below.
20821     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20822     <limits.h> exists even on freestanding compilers.  */
20823
20824 #ifdef __STDC__
20825 # include <limits.h>
20826 #else
20827 # include <assert.h>
20828 #endif
20829
20830 #undef $ac_func
20831
20832 /* Override any GCC internal prototype to avoid an error.
20833    Use char because int might match the return type of a GCC
20834    builtin and then its argument prototype would still apply.  */
20835 #ifdef __cplusplus
20836 extern "C"
20837 #endif
20838 char $ac_func ();
20839 /* The GNU C library defines this for functions which it implements
20840     to always fail with ENOSYS.  Some functions are actually named
20841     something starting with __ and the normal name is an alias.  */
20842 #if defined __stub_$ac_func || defined __stub___$ac_func
20843 choke me
20844 #endif
20845
20846 int
20847 main ()
20848 {
20849 return $ac_func ();
20850   ;
20851   return 0;
20852 }
20853 _ACEOF
20854 rm -f conftest.$ac_objext conftest$ac_exeext
20855 if { (ac_try="$ac_link"
20856 case "(($ac_try" in
20857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20858   *) ac_try_echo=$ac_try;;
20859 esac
20860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20861 $as_echo "$ac_try_echo") >&5
20862   (eval "$ac_link") 2>conftest.er1
20863   ac_status=$?
20864   grep -v '^ *+' conftest.er1 >conftest.err
20865   rm -f conftest.er1
20866   cat conftest.err >&5
20867   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20868   (exit $ac_status); } && {
20869          test -z "$ac_c_werror_flag" ||
20870          test ! -s conftest.err
20871        } && test -s conftest$ac_exeext && {
20872          test "$cross_compiling" = yes ||
20873          $as_test_x conftest$ac_exeext
20874        }; then
20875   eval "$as_ac_var=yes"
20876 else
20877   $as_echo "$as_me: failed program was:" >&5
20878 sed 's/^/| /' conftest.$ac_ext >&5
20879
20880         eval "$as_ac_var=no"
20881 fi
20882
20883 rm -rf conftest.dSYM
20884 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20885       conftest$ac_exeext conftest.$ac_ext
20886 fi
20887 ac_res=`eval 'as_val=${'$as_ac_var'}
20888                  $as_echo "$as_val"'`
20889                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20890 $as_echo "$ac_res" >&6; }
20891 as_val=`eval 'as_val=${'$as_ac_var'}
20892                  $as_echo "$as_val"'`
20893    if test "x$as_val" = x""yes; then
20894   cat >>confdefs.h <<_ACEOF
20895 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20896 _ACEOF
20897
20898 else
20899   case " $LIBOBJS " in
20900   *" $ac_func.$ac_objext "* ) ;;
20901   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20902  ;;
20903 esac
20904
20905 fi
20906 done
20907
20908
20909 else
20910   case " $LIBOBJS " in
20911   *" getaddrinfo.$ac_objext "* ) ;;
20912   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
20913  ;;
20914 esac
20915
20916 fi
20917
20918 # Similarly, use system's getopt_long() only if system provides struct option.
20919 if test x"$ac_cv_type_struct_option" = xyes ; then
20920
20921 for ac_func in getopt_long
20922 do
20923 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20924 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20925 $as_echo_n "checking for $ac_func... " >&6; }
20926 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20927   $as_echo_n "(cached) " >&6
20928 else
20929   cat >conftest.$ac_ext <<_ACEOF
20930 /* confdefs.h.  */
20931 _ACEOF
20932 cat confdefs.h >>conftest.$ac_ext
20933 cat >>conftest.$ac_ext <<_ACEOF
20934 /* end confdefs.h.  */
20935 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20936    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20937 #define $ac_func innocuous_$ac_func
20938
20939 /* System header to define __stub macros and hopefully few prototypes,
20940     which can conflict with char $ac_func (); below.
20941     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20942     <limits.h> exists even on freestanding compilers.  */
20943
20944 #ifdef __STDC__
20945 # include <limits.h>
20946 #else
20947 # include <assert.h>
20948 #endif
20949
20950 #undef $ac_func
20951
20952 /* Override any GCC internal prototype to avoid an error.
20953    Use char because int might match the return type of a GCC
20954    builtin and then its argument prototype would still apply.  */
20955 #ifdef __cplusplus
20956 extern "C"
20957 #endif
20958 char $ac_func ();
20959 /* The GNU C library defines this for functions which it implements
20960     to always fail with ENOSYS.  Some functions are actually named
20961     something starting with __ and the normal name is an alias.  */
20962 #if defined __stub_$ac_func || defined __stub___$ac_func
20963 choke me
20964 #endif
20965
20966 int
20967 main ()
20968 {
20969 return $ac_func ();
20970   ;
20971   return 0;
20972 }
20973 _ACEOF
20974 rm -f conftest.$ac_objext conftest$ac_exeext
20975 if { (ac_try="$ac_link"
20976 case "(($ac_try" in
20977   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20978   *) ac_try_echo=$ac_try;;
20979 esac
20980 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20981 $as_echo "$ac_try_echo") >&5
20982   (eval "$ac_link") 2>conftest.er1
20983   ac_status=$?
20984   grep -v '^ *+' conftest.er1 >conftest.err
20985   rm -f conftest.er1
20986   cat conftest.err >&5
20987   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20988   (exit $ac_status); } && {
20989          test -z "$ac_c_werror_flag" ||
20990          test ! -s conftest.err
20991        } && test -s conftest$ac_exeext && {
20992          test "$cross_compiling" = yes ||
20993          $as_test_x conftest$ac_exeext
20994        }; then
20995   eval "$as_ac_var=yes"
20996 else
20997   $as_echo "$as_me: failed program was:" >&5
20998 sed 's/^/| /' conftest.$ac_ext >&5
20999
21000         eval "$as_ac_var=no"
21001 fi
21002
21003 rm -rf conftest.dSYM
21004 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21005       conftest$ac_exeext conftest.$ac_ext
21006 fi
21007 ac_res=`eval 'as_val=${'$as_ac_var'}
21008                  $as_echo "$as_val"'`
21009                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21010 $as_echo "$ac_res" >&6; }
21011 as_val=`eval 'as_val=${'$as_ac_var'}
21012                  $as_echo "$as_val"'`
21013    if test "x$as_val" = x""yes; then
21014   cat >>confdefs.h <<_ACEOF
21015 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21016 _ACEOF
21017
21018 else
21019   case " $LIBOBJS " in
21020   *" $ac_func.$ac_objext "* ) ;;
21021   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21022  ;;
21023 esac
21024
21025 fi
21026 done
21027
21028
21029 else
21030   case " $LIBOBJS " in
21031   *" getopt_long.$ac_objext "* ) ;;
21032   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
21033  ;;
21034 esac
21035
21036 fi
21037
21038 # Solaris' getopt() doesn't do what we want for long options, so always use
21039 # our version on that platform.
21040 if test "$PORTNAME" = "solaris"; then
21041   case " $LIBOBJS " in
21042   *" getopt.$ac_objext "* ) ;;
21043   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
21044  ;;
21045 esac
21046
21047 fi
21048
21049 # mingw has adopted a GNU-centric interpretation of optind/optreset,
21050 # so always use our version on Windows.
21051 if test "$PORTNAME" = "win32"; then
21052   case " $LIBOBJS " in
21053   *" getopt.$ac_objext "* ) ;;
21054   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
21055  ;;
21056 esac
21057
21058   case " $LIBOBJS " in
21059   *" getopt_long.$ac_objext "* ) ;;
21060   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
21061  ;;
21062 esac
21063
21064 fi
21065
21066 # Cygwin's erand48() is broken (always returns zero) in some releases,
21067 # so force use of ours.
21068 if test "$PORTNAME" = "cygwin"; then
21069   case " $LIBOBJS " in
21070   *" erand48.$ac_objext "* ) ;;
21071   *) LIBOBJS="$LIBOBJS erand48.$ac_objext"
21072  ;;
21073 esac
21074
21075 fi
21076
21077 # Win32 support
21078 if test "$PORTNAME" = "win32"; then
21079
21080 for ac_func in gettimeofday
21081 do
21082 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21083 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21084 $as_echo_n "checking for $ac_func... " >&6; }
21085 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21086   $as_echo_n "(cached) " >&6
21087 else
21088   cat >conftest.$ac_ext <<_ACEOF
21089 /* confdefs.h.  */
21090 _ACEOF
21091 cat confdefs.h >>conftest.$ac_ext
21092 cat >>conftest.$ac_ext <<_ACEOF
21093 /* end confdefs.h.  */
21094 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21095    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21096 #define $ac_func innocuous_$ac_func
21097
21098 /* System header to define __stub macros and hopefully few prototypes,
21099     which can conflict with char $ac_func (); below.
21100     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21101     <limits.h> exists even on freestanding compilers.  */
21102
21103 #ifdef __STDC__
21104 # include <limits.h>
21105 #else
21106 # include <assert.h>
21107 #endif
21108
21109 #undef $ac_func
21110
21111 /* Override any GCC internal prototype to avoid an error.
21112    Use char because int might match the return type of a GCC
21113    builtin and then its argument prototype would still apply.  */
21114 #ifdef __cplusplus
21115 extern "C"
21116 #endif
21117 char $ac_func ();
21118 /* The GNU C library defines this for functions which it implements
21119     to always fail with ENOSYS.  Some functions are actually named
21120     something starting with __ and the normal name is an alias.  */
21121 #if defined __stub_$ac_func || defined __stub___$ac_func
21122 choke me
21123 #endif
21124
21125 int
21126 main ()
21127 {
21128 return $ac_func ();
21129   ;
21130   return 0;
21131 }
21132 _ACEOF
21133 rm -f conftest.$ac_objext conftest$ac_exeext
21134 if { (ac_try="$ac_link"
21135 case "(($ac_try" in
21136   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21137   *) ac_try_echo=$ac_try;;
21138 esac
21139 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21140 $as_echo "$ac_try_echo") >&5
21141   (eval "$ac_link") 2>conftest.er1
21142   ac_status=$?
21143   grep -v '^ *+' conftest.er1 >conftest.err
21144   rm -f conftest.er1
21145   cat conftest.err >&5
21146   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21147   (exit $ac_status); } && {
21148          test -z "$ac_c_werror_flag" ||
21149          test ! -s conftest.err
21150        } && test -s conftest$ac_exeext && {
21151          test "$cross_compiling" = yes ||
21152          $as_test_x conftest$ac_exeext
21153        }; then
21154   eval "$as_ac_var=yes"
21155 else
21156   $as_echo "$as_me: failed program was:" >&5
21157 sed 's/^/| /' conftest.$ac_ext >&5
21158
21159         eval "$as_ac_var=no"
21160 fi
21161
21162 rm -rf conftest.dSYM
21163 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21164       conftest$ac_exeext conftest.$ac_ext
21165 fi
21166 ac_res=`eval 'as_val=${'$as_ac_var'}
21167                  $as_echo "$as_val"'`
21168                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21169 $as_echo "$ac_res" >&6; }
21170 as_val=`eval 'as_val=${'$as_ac_var'}
21171                  $as_echo "$as_val"'`
21172    if test "x$as_val" = x""yes; then
21173   cat >>confdefs.h <<_ACEOF
21174 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21175 _ACEOF
21176
21177 else
21178   case " $LIBOBJS " in
21179   *" $ac_func.$ac_objext "* ) ;;
21180   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21181  ;;
21182 esac
21183
21184 fi
21185 done
21186
21187
21188   case " $LIBOBJS " in
21189   *" kill.$ac_objext "* ) ;;
21190   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
21191  ;;
21192 esac
21193
21194   case " $LIBOBJS " in
21195   *" open.$ac_objext "* ) ;;
21196   *) LIBOBJS="$LIBOBJS open.$ac_objext"
21197  ;;
21198 esac
21199
21200   case " $LIBOBJS " in
21201   *" win32env.$ac_objext "* ) ;;
21202   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
21203  ;;
21204 esac
21205
21206   case " $LIBOBJS " in
21207   *" win32error.$ac_objext "* ) ;;
21208   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
21209  ;;
21210 esac
21211
21212
21213 cat >>confdefs.h <<\_ACEOF
21214 #define HAVE_SYMLINK 1
21215 _ACEOF
21216
21217   { $as_echo "$as_me:$LINENO: checking for MINIDUMP_TYPE" >&5
21218 $as_echo_n "checking for MINIDUMP_TYPE... " >&6; }
21219 if test "${ac_cv_type_MINIDUMP_TYPE+set}" = set; then
21220   $as_echo_n "(cached) " >&6
21221 else
21222   ac_cv_type_MINIDUMP_TYPE=no
21223 cat >conftest.$ac_ext <<_ACEOF
21224 /* confdefs.h.  */
21225 _ACEOF
21226 cat confdefs.h >>conftest.$ac_ext
21227 cat >>conftest.$ac_ext <<_ACEOF
21228 /* end confdefs.h.  */
21229
21230 #define WIN32_LEAN_AND_MEAN
21231 #include <windows.h>
21232 #include <string.h>
21233 #include <dbghelp.h>
21234
21235 int
21236 main ()
21237 {
21238 if (sizeof (MINIDUMP_TYPE))
21239        return 0;
21240   ;
21241   return 0;
21242 }
21243 _ACEOF
21244 rm -f conftest.$ac_objext
21245 if { (ac_try="$ac_compile"
21246 case "(($ac_try" in
21247   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21248   *) ac_try_echo=$ac_try;;
21249 esac
21250 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21251 $as_echo "$ac_try_echo") >&5
21252   (eval "$ac_compile") 2>conftest.er1
21253   ac_status=$?
21254   grep -v '^ *+' conftest.er1 >conftest.err
21255   rm -f conftest.er1
21256   cat conftest.err >&5
21257   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21258   (exit $ac_status); } && {
21259          test -z "$ac_c_werror_flag" ||
21260          test ! -s conftest.err
21261        } && test -s conftest.$ac_objext; then
21262   cat >conftest.$ac_ext <<_ACEOF
21263 /* confdefs.h.  */
21264 _ACEOF
21265 cat confdefs.h >>conftest.$ac_ext
21266 cat >>conftest.$ac_ext <<_ACEOF
21267 /* end confdefs.h.  */
21268
21269 #define WIN32_LEAN_AND_MEAN
21270 #include <windows.h>
21271 #include <string.h>
21272 #include <dbghelp.h>
21273
21274 int
21275 main ()
21276 {
21277 if (sizeof ((MINIDUMP_TYPE)))
21278           return 0;
21279   ;
21280   return 0;
21281 }
21282 _ACEOF
21283 rm -f conftest.$ac_objext
21284 if { (ac_try="$ac_compile"
21285 case "(($ac_try" in
21286   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21287   *) ac_try_echo=$ac_try;;
21288 esac
21289 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21290 $as_echo "$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   $as_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   :
21302 else
21303   $as_echo "$as_me: failed program was:" >&5
21304 sed 's/^/| /' conftest.$ac_ext >&5
21305
21306         ac_cv_type_MINIDUMP_TYPE=yes
21307 fi
21308
21309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21310 else
21311   $as_echo "$as_me: failed program was:" >&5
21312 sed 's/^/| /' conftest.$ac_ext >&5
21313
21314
21315 fi
21316
21317 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21318 fi
21319 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_MINIDUMP_TYPE" >&5
21320 $as_echo "$ac_cv_type_MINIDUMP_TYPE" >&6; }
21321 if test "x$ac_cv_type_MINIDUMP_TYPE" = x""yes; then
21322
21323 cat >>confdefs.h <<_ACEOF
21324 #define HAVE_MINIDUMP_TYPE 1
21325 _ACEOF
21326
21327 pgac_minidump_type=yes
21328 else
21329   pgac_minidump_type=no
21330 fi
21331
21332 fi
21333 if test x"$pgac_minidump_type" = x"yes" ; then
21334   have_win32_dbghelp=yes
21335
21336 else
21337   have_win32_dbghelp=no
21338
21339 fi
21340
21341 if test "$with_readline" = yes; then
21342   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
21343 $as_echo_n "checking for rl_completion_append_character... " >&6; }
21344 if test "${pgac_cv_var_rl_completion_append_character+set}" = set; then
21345   $as_echo_n "(cached) " >&6
21346 else
21347   cat >conftest.$ac_ext <<_ACEOF
21348 /* confdefs.h.  */
21349 _ACEOF
21350 cat confdefs.h >>conftest.$ac_ext
21351 cat >>conftest.$ac_ext <<_ACEOF
21352 /* end confdefs.h.  */
21353 #include <stdio.h>
21354 #ifdef HAVE_READLINE_READLINE_H
21355 # include <readline/readline.h>
21356 #elif defined(HAVE_READLINE_H)
21357 # include <readline.h>
21358 #endif
21359
21360 int
21361 main ()
21362 {
21363 rl_completion_append_character = 'x';
21364   ;
21365   return 0;
21366 }
21367 _ACEOF
21368 rm -f conftest.$ac_objext conftest$ac_exeext
21369 if { (ac_try="$ac_link"
21370 case "(($ac_try" in
21371   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21372   *) ac_try_echo=$ac_try;;
21373 esac
21374 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21375 $as_echo "$ac_try_echo") >&5
21376   (eval "$ac_link") 2>conftest.er1
21377   ac_status=$?
21378   grep -v '^ *+' conftest.er1 >conftest.err
21379   rm -f conftest.er1
21380   cat conftest.err >&5
21381   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21382   (exit $ac_status); } && {
21383          test -z "$ac_c_werror_flag" ||
21384          test ! -s conftest.err
21385        } && test -s conftest$ac_exeext && {
21386          test "$cross_compiling" = yes ||
21387          $as_test_x conftest$ac_exeext
21388        }; then
21389   pgac_cv_var_rl_completion_append_character=yes
21390 else
21391   $as_echo "$as_me: failed program was:" >&5
21392 sed 's/^/| /' conftest.$ac_ext >&5
21393
21394         pgac_cv_var_rl_completion_append_character=no
21395 fi
21396
21397 rm -rf conftest.dSYM
21398 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21399       conftest$ac_exeext conftest.$ac_ext
21400 fi
21401 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_rl_completion_append_character" >&5
21402 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
21403 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
21404
21405 cat >>confdefs.h <<\_ACEOF
21406 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
21407 _ACEOF
21408
21409 fi
21410
21411
21412 for ac_func in rl_completion_matches rl_filename_completion_function
21413 do
21414 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21415 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21416 $as_echo_n "checking for $ac_func... " >&6; }
21417 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21418   $as_echo_n "(cached) " >&6
21419 else
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 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21427    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21428 #define $ac_func innocuous_$ac_func
21429
21430 /* System header to define __stub macros and hopefully few prototypes,
21431     which can conflict with char $ac_func (); below.
21432     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21433     <limits.h> exists even on freestanding compilers.  */
21434
21435 #ifdef __STDC__
21436 # include <limits.h>
21437 #else
21438 # include <assert.h>
21439 #endif
21440
21441 #undef $ac_func
21442
21443 /* Override any GCC internal prototype to avoid an error.
21444    Use char because int might match the return type of a GCC
21445    builtin and then its argument prototype would still apply.  */
21446 #ifdef __cplusplus
21447 extern "C"
21448 #endif
21449 char $ac_func ();
21450 /* The GNU C library defines this for functions which it implements
21451     to always fail with ENOSYS.  Some functions are actually named
21452     something starting with __ and the normal name is an alias.  */
21453 #if defined __stub_$ac_func || defined __stub___$ac_func
21454 choke me
21455 #endif
21456
21457 int
21458 main ()
21459 {
21460 return $ac_func ();
21461   ;
21462   return 0;
21463 }
21464 _ACEOF
21465 rm -f conftest.$ac_objext conftest$ac_exeext
21466 if { (ac_try="$ac_link"
21467 case "(($ac_try" in
21468   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21469   *) ac_try_echo=$ac_try;;
21470 esac
21471 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21472 $as_echo "$ac_try_echo") >&5
21473   (eval "$ac_link") 2>conftest.er1
21474   ac_status=$?
21475   grep -v '^ *+' conftest.er1 >conftest.err
21476   rm -f conftest.er1
21477   cat conftest.err >&5
21478   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21479   (exit $ac_status); } && {
21480          test -z "$ac_c_werror_flag" ||
21481          test ! -s conftest.err
21482        } && test -s conftest$ac_exeext && {
21483          test "$cross_compiling" = yes ||
21484          $as_test_x conftest$ac_exeext
21485        }; then
21486   eval "$as_ac_var=yes"
21487 else
21488   $as_echo "$as_me: failed program was:" >&5
21489 sed 's/^/| /' conftest.$ac_ext >&5
21490
21491         eval "$as_ac_var=no"
21492 fi
21493
21494 rm -rf conftest.dSYM
21495 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21496       conftest$ac_exeext conftest.$ac_ext
21497 fi
21498 ac_res=`eval 'as_val=${'$as_ac_var'}
21499                  $as_echo "$as_val"'`
21500                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21501 $as_echo "$ac_res" >&6; }
21502 as_val=`eval 'as_val=${'$as_ac_var'}
21503                  $as_echo "$as_val"'`
21504    if test "x$as_val" = x""yes; then
21505   cat >>confdefs.h <<_ACEOF
21506 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21507 _ACEOF
21508
21509 fi
21510 done
21511
21512
21513
21514 for ac_func in append_history history_truncate_file
21515 do
21516 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21517 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21518 $as_echo_n "checking for $ac_func... " >&6; }
21519 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21520   $as_echo_n "(cached) " >&6
21521 else
21522   cat >conftest.$ac_ext <<_ACEOF
21523 /* confdefs.h.  */
21524 _ACEOF
21525 cat confdefs.h >>conftest.$ac_ext
21526 cat >>conftest.$ac_ext <<_ACEOF
21527 /* end confdefs.h.  */
21528 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21529    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21530 #define $ac_func innocuous_$ac_func
21531
21532 /* System header to define __stub macros and hopefully few prototypes,
21533     which can conflict with char $ac_func (); below.
21534     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21535     <limits.h> exists even on freestanding compilers.  */
21536
21537 #ifdef __STDC__
21538 # include <limits.h>
21539 #else
21540 # include <assert.h>
21541 #endif
21542
21543 #undef $ac_func
21544
21545 /* Override any GCC internal prototype to avoid an error.
21546    Use char because int might match the return type of a GCC
21547    builtin and then its argument prototype would still apply.  */
21548 #ifdef __cplusplus
21549 extern "C"
21550 #endif
21551 char $ac_func ();
21552 /* The GNU C library defines this for functions which it implements
21553     to always fail with ENOSYS.  Some functions are actually named
21554     something starting with __ and the normal name is an alias.  */
21555 #if defined __stub_$ac_func || defined __stub___$ac_func
21556 choke me
21557 #endif
21558
21559 int
21560 main ()
21561 {
21562 return $ac_func ();
21563   ;
21564   return 0;
21565 }
21566 _ACEOF
21567 rm -f conftest.$ac_objext conftest$ac_exeext
21568 if { (ac_try="$ac_link"
21569 case "(($ac_try" in
21570   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21571   *) ac_try_echo=$ac_try;;
21572 esac
21573 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21574 $as_echo "$ac_try_echo") >&5
21575   (eval "$ac_link") 2>conftest.er1
21576   ac_status=$?
21577   grep -v '^ *+' conftest.er1 >conftest.err
21578   rm -f conftest.er1
21579   cat conftest.err >&5
21580   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21581   (exit $ac_status); } && {
21582          test -z "$ac_c_werror_flag" ||
21583          test ! -s conftest.err
21584        } && test -s conftest$ac_exeext && {
21585          test "$cross_compiling" = yes ||
21586          $as_test_x conftest$ac_exeext
21587        }; then
21588   eval "$as_ac_var=yes"
21589 else
21590   $as_echo "$as_me: failed program was:" >&5
21591 sed 's/^/| /' conftest.$ac_ext >&5
21592
21593         eval "$as_ac_var=no"
21594 fi
21595
21596 rm -rf conftest.dSYM
21597 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21598       conftest$ac_exeext conftest.$ac_ext
21599 fi
21600 ac_res=`eval 'as_val=${'$as_ac_var'}
21601                  $as_echo "$as_val"'`
21602                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21603 $as_echo "$ac_res" >&6; }
21604 as_val=`eval 'as_val=${'$as_ac_var'}
21605                  $as_echo "$as_val"'`
21606    if test "x$as_val" = x""yes; then
21607   cat >>confdefs.h <<_ACEOF
21608 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21609 _ACEOF
21610
21611 fi
21612 done
21613
21614 fi
21615
21616
21617 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
21618 $as_echo_n "checking for sigsetjmp... " >&6; }
21619 if test "${pgac_cv_func_sigsetjmp+set}" = set; then
21620   $as_echo_n "(cached) " >&6
21621 else
21622   cat >conftest.$ac_ext <<_ACEOF
21623 /* confdefs.h.  */
21624 _ACEOF
21625 cat confdefs.h >>conftest.$ac_ext
21626 cat >>conftest.$ac_ext <<_ACEOF
21627 /* end confdefs.h.  */
21628 #include <setjmp.h>
21629 int
21630 main ()
21631 {
21632 sigjmp_buf x; sigsetjmp(x, 1);
21633   ;
21634   return 0;
21635 }
21636 _ACEOF
21637 rm -f conftest.$ac_objext conftest$ac_exeext
21638 if { (ac_try="$ac_link"
21639 case "(($ac_try" in
21640   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21641   *) ac_try_echo=$ac_try;;
21642 esac
21643 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21644 $as_echo "$ac_try_echo") >&5
21645   (eval "$ac_link") 2>conftest.er1
21646   ac_status=$?
21647   grep -v '^ *+' conftest.er1 >conftest.err
21648   rm -f conftest.er1
21649   cat conftest.err >&5
21650   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21651   (exit $ac_status); } && {
21652          test -z "$ac_c_werror_flag" ||
21653          test ! -s conftest.err
21654        } && test -s conftest$ac_exeext && {
21655          test "$cross_compiling" = yes ||
21656          $as_test_x conftest$ac_exeext
21657        }; then
21658   pgac_cv_func_sigsetjmp=yes
21659 else
21660   $as_echo "$as_me: failed program was:" >&5
21661 sed 's/^/| /' conftest.$ac_ext >&5
21662
21663         pgac_cv_func_sigsetjmp=no
21664 fi
21665
21666 rm -rf conftest.dSYM
21667 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21668       conftest$ac_exeext conftest.$ac_ext
21669 fi
21670 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_sigsetjmp" >&5
21671 $as_echo "$pgac_cv_func_sigsetjmp" >&6; }
21672 if test x"$pgac_cv_func_sigsetjmp" = x"yes"; then
21673
21674 cat >>confdefs.h <<\_ACEOF
21675 #define HAVE_SIGSETJMP 1
21676 _ACEOF
21677
21678 fi
21679
21680 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
21681 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
21682 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
21683   $as_echo_n "(cached) " >&6
21684 else
21685   cat >conftest.$ac_ext <<_ACEOF
21686 /* confdefs.h.  */
21687 _ACEOF
21688 cat confdefs.h >>conftest.$ac_ext
21689 cat >>conftest.$ac_ext <<_ACEOF
21690 /* end confdefs.h.  */
21691 #include <signal.h>
21692 /* NetBSD declares sys_siglist in unistd.h.  */
21693 #ifdef HAVE_UNISTD_H
21694 # include <unistd.h>
21695 #endif
21696
21697
21698 int
21699 main ()
21700 {
21701 #ifndef sys_siglist
21702   (void) sys_siglist;
21703 #endif
21704
21705   ;
21706   return 0;
21707 }
21708 _ACEOF
21709 rm -f conftest.$ac_objext
21710 if { (ac_try="$ac_compile"
21711 case "(($ac_try" in
21712   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21713   *) ac_try_echo=$ac_try;;
21714 esac
21715 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21716 $as_echo "$ac_try_echo") >&5
21717   (eval "$ac_compile") 2>conftest.er1
21718   ac_status=$?
21719   grep -v '^ *+' conftest.er1 >conftest.err
21720   rm -f conftest.er1
21721   cat conftest.err >&5
21722   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21723   (exit $ac_status); } && {
21724          test -z "$ac_c_werror_flag" ||
21725          test ! -s conftest.err
21726        } && test -s conftest.$ac_objext; then
21727   ac_cv_have_decl_sys_siglist=yes
21728 else
21729   $as_echo "$as_me: failed program was:" >&5
21730 sed 's/^/| /' conftest.$ac_ext >&5
21731
21732         ac_cv_have_decl_sys_siglist=no
21733 fi
21734
21735 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21736 fi
21737 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
21738 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
21739 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
21740
21741 cat >>confdefs.h <<_ACEOF
21742 #define HAVE_DECL_SYS_SIGLIST 1
21743 _ACEOF
21744
21745
21746 else
21747   cat >>confdefs.h <<_ACEOF
21748 #define HAVE_DECL_SYS_SIGLIST 0
21749 _ACEOF
21750
21751
21752 fi
21753
21754
21755
21756
21757 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
21758 $as_echo_n "checking for syslog... " >&6; }
21759 if test "${ac_cv_func_syslog+set}" = set; then
21760   $as_echo_n "(cached) " >&6
21761 else
21762   cat >conftest.$ac_ext <<_ACEOF
21763 /* confdefs.h.  */
21764 _ACEOF
21765 cat confdefs.h >>conftest.$ac_ext
21766 cat >>conftest.$ac_ext <<_ACEOF
21767 /* end confdefs.h.  */
21768 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
21769    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21770 #define syslog innocuous_syslog
21771
21772 /* System header to define __stub macros and hopefully few prototypes,
21773     which can conflict with char syslog (); below.
21774     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21775     <limits.h> exists even on freestanding compilers.  */
21776
21777 #ifdef __STDC__
21778 # include <limits.h>
21779 #else
21780 # include <assert.h>
21781 #endif
21782
21783 #undef syslog
21784
21785 /* Override any GCC internal prototype to avoid an error.
21786    Use char because int might match the return type of a GCC
21787    builtin and then its argument prototype would still apply.  */
21788 #ifdef __cplusplus
21789 extern "C"
21790 #endif
21791 char syslog ();
21792 /* The GNU C library defines this for functions which it implements
21793     to always fail with ENOSYS.  Some functions are actually named
21794     something starting with __ and the normal name is an alias.  */
21795 #if defined __stub_syslog || defined __stub___syslog
21796 choke me
21797 #endif
21798
21799 int
21800 main ()
21801 {
21802 return syslog ();
21803   ;
21804   return 0;
21805 }
21806 _ACEOF
21807 rm -f conftest.$ac_objext conftest$ac_exeext
21808 if { (ac_try="$ac_link"
21809 case "(($ac_try" in
21810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21811   *) ac_try_echo=$ac_try;;
21812 esac
21813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21814 $as_echo "$ac_try_echo") >&5
21815   (eval "$ac_link") 2>conftest.er1
21816   ac_status=$?
21817   grep -v '^ *+' conftest.er1 >conftest.err
21818   rm -f conftest.er1
21819   cat conftest.err >&5
21820   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21821   (exit $ac_status); } && {
21822          test -z "$ac_c_werror_flag" ||
21823          test ! -s conftest.err
21824        } && test -s conftest$ac_exeext && {
21825          test "$cross_compiling" = yes ||
21826          $as_test_x conftest$ac_exeext
21827        }; then
21828   ac_cv_func_syslog=yes
21829 else
21830   $as_echo "$as_me: failed program was:" >&5
21831 sed 's/^/| /' conftest.$ac_ext >&5
21832
21833         ac_cv_func_syslog=no
21834 fi
21835
21836 rm -rf conftest.dSYM
21837 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21838       conftest$ac_exeext conftest.$ac_ext
21839 fi
21840 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
21841 $as_echo "$ac_cv_func_syslog" >&6; }
21842 if test "x$ac_cv_func_syslog" = x""yes; then
21843   if test "${ac_cv_header_syslog_h+set}" = set; then
21844   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21845 $as_echo_n "checking for syslog.h... " >&6; }
21846 if test "${ac_cv_header_syslog_h+set}" = set; then
21847   $as_echo_n "(cached) " >&6
21848 fi
21849 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21850 $as_echo "$ac_cv_header_syslog_h" >&6; }
21851 else
21852   # Is the header compilable?
21853 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
21854 $as_echo_n "checking syslog.h usability... " >&6; }
21855 cat >conftest.$ac_ext <<_ACEOF
21856 /* confdefs.h.  */
21857 _ACEOF
21858 cat confdefs.h >>conftest.$ac_ext
21859 cat >>conftest.$ac_ext <<_ACEOF
21860 /* end confdefs.h.  */
21861 $ac_includes_default
21862 #include <syslog.h>
21863 _ACEOF
21864 rm -f conftest.$ac_objext
21865 if { (ac_try="$ac_compile"
21866 case "(($ac_try" in
21867   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21868   *) ac_try_echo=$ac_try;;
21869 esac
21870 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21871 $as_echo "$ac_try_echo") >&5
21872   (eval "$ac_compile") 2>conftest.er1
21873   ac_status=$?
21874   grep -v '^ *+' conftest.er1 >conftest.err
21875   rm -f conftest.er1
21876   cat conftest.err >&5
21877   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21878   (exit $ac_status); } && {
21879          test -z "$ac_c_werror_flag" ||
21880          test ! -s conftest.err
21881        } && test -s conftest.$ac_objext; then
21882   ac_header_compiler=yes
21883 else
21884   $as_echo "$as_me: failed program was:" >&5
21885 sed 's/^/| /' conftest.$ac_ext >&5
21886
21887         ac_header_compiler=no
21888 fi
21889
21890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21891 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21892 $as_echo "$ac_header_compiler" >&6; }
21893
21894 # Is the header present?
21895 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
21896 $as_echo_n "checking syslog.h presence... " >&6; }
21897 cat >conftest.$ac_ext <<_ACEOF
21898 /* confdefs.h.  */
21899 _ACEOF
21900 cat confdefs.h >>conftest.$ac_ext
21901 cat >>conftest.$ac_ext <<_ACEOF
21902 /* end confdefs.h.  */
21903 #include <syslog.h>
21904 _ACEOF
21905 if { (ac_try="$ac_cpp conftest.$ac_ext"
21906 case "(($ac_try" in
21907   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21908   *) ac_try_echo=$ac_try;;
21909 esac
21910 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21911 $as_echo "$ac_try_echo") >&5
21912   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21913   ac_status=$?
21914   grep -v '^ *+' conftest.er1 >conftest.err
21915   rm -f conftest.er1
21916   cat conftest.err >&5
21917   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21918   (exit $ac_status); } >/dev/null && {
21919          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21920          test ! -s conftest.err
21921        }; then
21922   ac_header_preproc=yes
21923 else
21924   $as_echo "$as_me: failed program was:" >&5
21925 sed 's/^/| /' conftest.$ac_ext >&5
21926
21927   ac_header_preproc=no
21928 fi
21929
21930 rm -f conftest.err conftest.$ac_ext
21931 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21932 $as_echo "$ac_header_preproc" >&6; }
21933
21934 # So?  What about this header?
21935 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21936   yes:no: )
21937     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
21938 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21939     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
21940 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
21941     ac_header_preproc=yes
21942     ;;
21943   no:yes:* )
21944     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
21945 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
21946     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
21947 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
21948     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
21949 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
21950     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
21951 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21952     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
21953 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
21954     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
21955 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
21956     ( cat <<\_ASBOX
21957 ## ---------------------------------------- ##
21958 ## Report this to pgsql-bugs@postgresql.org ##
21959 ## ---------------------------------------- ##
21960 _ASBOX
21961      ) | sed "s/^/$as_me: WARNING:     /" >&2
21962     ;;
21963 esac
21964 { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21965 $as_echo_n "checking for syslog.h... " >&6; }
21966 if test "${ac_cv_header_syslog_h+set}" = set; then
21967   $as_echo_n "(cached) " >&6
21968 else
21969   ac_cv_header_syslog_h=$ac_header_preproc
21970 fi
21971 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21972 $as_echo "$ac_cv_header_syslog_h" >&6; }
21973
21974 fi
21975 if test "x$ac_cv_header_syslog_h" = x""yes; then
21976
21977 cat >>confdefs.h <<\_ACEOF
21978 #define HAVE_SYSLOG 1
21979 _ACEOF
21980
21981 fi
21982
21983
21984 fi
21985
21986
21987 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
21988 $as_echo_n "checking for opterr... " >&6; }
21989 if test "${pgac_cv_var_int_opterr+set}" = set; then
21990   $as_echo_n "(cached) " >&6
21991 else
21992   cat >conftest.$ac_ext <<_ACEOF
21993 /* confdefs.h.  */
21994 _ACEOF
21995 cat confdefs.h >>conftest.$ac_ext
21996 cat >>conftest.$ac_ext <<_ACEOF
21997 /* end confdefs.h.  */
21998 #include <unistd.h>
21999 int
22000 main ()
22001 {
22002 extern int opterr; opterr = 1;
22003   ;
22004   return 0;
22005 }
22006 _ACEOF
22007 rm -f conftest.$ac_objext conftest$ac_exeext
22008 if { (ac_try="$ac_link"
22009 case "(($ac_try" in
22010   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22011   *) ac_try_echo=$ac_try;;
22012 esac
22013 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22014 $as_echo "$ac_try_echo") >&5
22015   (eval "$ac_link") 2>conftest.er1
22016   ac_status=$?
22017   grep -v '^ *+' conftest.er1 >conftest.err
22018   rm -f conftest.er1
22019   cat conftest.err >&5
22020   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22021   (exit $ac_status); } && {
22022          test -z "$ac_c_werror_flag" ||
22023          test ! -s conftest.err
22024        } && test -s conftest$ac_exeext && {
22025          test "$cross_compiling" = yes ||
22026          $as_test_x conftest$ac_exeext
22027        }; then
22028   pgac_cv_var_int_opterr=yes
22029 else
22030   $as_echo "$as_me: failed program was:" >&5
22031 sed 's/^/| /' conftest.$ac_ext >&5
22032
22033         pgac_cv_var_int_opterr=no
22034 fi
22035
22036 rm -rf conftest.dSYM
22037 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22038       conftest$ac_exeext conftest.$ac_ext
22039 fi
22040 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
22041 $as_echo "$pgac_cv_var_int_opterr" >&6; }
22042 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
22043
22044 cat >>confdefs.h <<\_ACEOF
22045 #define HAVE_INT_OPTERR 1
22046 _ACEOF
22047
22048 fi
22049
22050 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
22051 $as_echo_n "checking for optreset... " >&6; }
22052 if test "${pgac_cv_var_int_optreset+set}" = set; then
22053   $as_echo_n "(cached) " >&6
22054 else
22055   cat >conftest.$ac_ext <<_ACEOF
22056 /* confdefs.h.  */
22057 _ACEOF
22058 cat confdefs.h >>conftest.$ac_ext
22059 cat >>conftest.$ac_ext <<_ACEOF
22060 /* end confdefs.h.  */
22061 #include <unistd.h>
22062 int
22063 main ()
22064 {
22065 extern int optreset; optreset = 1;
22066   ;
22067   return 0;
22068 }
22069 _ACEOF
22070 rm -f conftest.$ac_objext conftest$ac_exeext
22071 if { (ac_try="$ac_link"
22072 case "(($ac_try" in
22073   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22074   *) ac_try_echo=$ac_try;;
22075 esac
22076 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22077 $as_echo "$ac_try_echo") >&5
22078   (eval "$ac_link") 2>conftest.er1
22079   ac_status=$?
22080   grep -v '^ *+' conftest.er1 >conftest.err
22081   rm -f conftest.er1
22082   cat conftest.err >&5
22083   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22084   (exit $ac_status); } && {
22085          test -z "$ac_c_werror_flag" ||
22086          test ! -s conftest.err
22087        } && test -s conftest$ac_exeext && {
22088          test "$cross_compiling" = yes ||
22089          $as_test_x conftest$ac_exeext
22090        }; then
22091   pgac_cv_var_int_optreset=yes
22092 else
22093   $as_echo "$as_me: failed program was:" >&5
22094 sed 's/^/| /' conftest.$ac_ext >&5
22095
22096         pgac_cv_var_int_optreset=no
22097 fi
22098
22099 rm -rf conftest.dSYM
22100 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22101       conftest$ac_exeext conftest.$ac_ext
22102 fi
22103 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
22104 $as_echo "$pgac_cv_var_int_optreset" >&6; }
22105 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
22106
22107 cat >>confdefs.h <<\_ACEOF
22108 #define HAVE_INT_OPTRESET 1
22109 _ACEOF
22110
22111 fi
22112
22113
22114
22115 for ac_func in strtoll strtoq
22116 do
22117 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22118 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22119 $as_echo_n "checking for $ac_func... " >&6; }
22120 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22121   $as_echo_n "(cached) " >&6
22122 else
22123   cat >conftest.$ac_ext <<_ACEOF
22124 /* confdefs.h.  */
22125 _ACEOF
22126 cat confdefs.h >>conftest.$ac_ext
22127 cat >>conftest.$ac_ext <<_ACEOF
22128 /* end confdefs.h.  */
22129 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22130    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22131 #define $ac_func innocuous_$ac_func
22132
22133 /* System header to define __stub macros and hopefully few prototypes,
22134     which can conflict with char $ac_func (); below.
22135     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22136     <limits.h> exists even on freestanding compilers.  */
22137
22138 #ifdef __STDC__
22139 # include <limits.h>
22140 #else
22141 # include <assert.h>
22142 #endif
22143
22144 #undef $ac_func
22145
22146 /* Override any GCC internal prototype to avoid an error.
22147    Use char because int might match the return type of a GCC
22148    builtin and then its argument prototype would still apply.  */
22149 #ifdef __cplusplus
22150 extern "C"
22151 #endif
22152 char $ac_func ();
22153 /* The GNU C library defines this for functions which it implements
22154     to always fail with ENOSYS.  Some functions are actually named
22155     something starting with __ and the normal name is an alias.  */
22156 #if defined __stub_$ac_func || defined __stub___$ac_func
22157 choke me
22158 #endif
22159
22160 int
22161 main ()
22162 {
22163 return $ac_func ();
22164   ;
22165   return 0;
22166 }
22167 _ACEOF
22168 rm -f conftest.$ac_objext conftest$ac_exeext
22169 if { (ac_try="$ac_link"
22170 case "(($ac_try" in
22171   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22172   *) ac_try_echo=$ac_try;;
22173 esac
22174 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22175 $as_echo "$ac_try_echo") >&5
22176   (eval "$ac_link") 2>conftest.er1
22177   ac_status=$?
22178   grep -v '^ *+' conftest.er1 >conftest.err
22179   rm -f conftest.er1
22180   cat conftest.err >&5
22181   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22182   (exit $ac_status); } && {
22183          test -z "$ac_c_werror_flag" ||
22184          test ! -s conftest.err
22185        } && test -s conftest$ac_exeext && {
22186          test "$cross_compiling" = yes ||
22187          $as_test_x conftest$ac_exeext
22188        }; then
22189   eval "$as_ac_var=yes"
22190 else
22191   $as_echo "$as_me: failed program was:" >&5
22192 sed 's/^/| /' conftest.$ac_ext >&5
22193
22194         eval "$as_ac_var=no"
22195 fi
22196
22197 rm -rf conftest.dSYM
22198 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22199       conftest$ac_exeext conftest.$ac_ext
22200 fi
22201 ac_res=`eval 'as_val=${'$as_ac_var'}
22202                  $as_echo "$as_val"'`
22203                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22204 $as_echo "$ac_res" >&6; }
22205 as_val=`eval 'as_val=${'$as_ac_var'}
22206                  $as_echo "$as_val"'`
22207    if test "x$as_val" = x""yes; then
22208   cat >>confdefs.h <<_ACEOF
22209 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22210 _ACEOF
22211  break
22212 fi
22213 done
22214
22215
22216
22217 for ac_func in strtoull strtouq
22218 do
22219 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22220 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22221 $as_echo_n "checking for $ac_func... " >&6; }
22222 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22223   $as_echo_n "(cached) " >&6
22224 else
22225   cat >conftest.$ac_ext <<_ACEOF
22226 /* confdefs.h.  */
22227 _ACEOF
22228 cat confdefs.h >>conftest.$ac_ext
22229 cat >>conftest.$ac_ext <<_ACEOF
22230 /* end confdefs.h.  */
22231 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22232    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22233 #define $ac_func innocuous_$ac_func
22234
22235 /* System header to define __stub macros and hopefully few prototypes,
22236     which can conflict with char $ac_func (); below.
22237     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22238     <limits.h> exists even on freestanding compilers.  */
22239
22240 #ifdef __STDC__
22241 # include <limits.h>
22242 #else
22243 # include <assert.h>
22244 #endif
22245
22246 #undef $ac_func
22247
22248 /* Override any GCC internal prototype to avoid an error.
22249    Use char because int might match the return type of a GCC
22250    builtin and then its argument prototype would still apply.  */
22251 #ifdef __cplusplus
22252 extern "C"
22253 #endif
22254 char $ac_func ();
22255 /* The GNU C library defines this for functions which it implements
22256     to always fail with ENOSYS.  Some functions are actually named
22257     something starting with __ and the normal name is an alias.  */
22258 #if defined __stub_$ac_func || defined __stub___$ac_func
22259 choke me
22260 #endif
22261
22262 int
22263 main ()
22264 {
22265 return $ac_func ();
22266   ;
22267   return 0;
22268 }
22269 _ACEOF
22270 rm -f conftest.$ac_objext conftest$ac_exeext
22271 if { (ac_try="$ac_link"
22272 case "(($ac_try" in
22273   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22274   *) ac_try_echo=$ac_try;;
22275 esac
22276 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22277 $as_echo "$ac_try_echo") >&5
22278   (eval "$ac_link") 2>conftest.er1
22279   ac_status=$?
22280   grep -v '^ *+' conftest.er1 >conftest.err
22281   rm -f conftest.er1
22282   cat conftest.err >&5
22283   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22284   (exit $ac_status); } && {
22285          test -z "$ac_c_werror_flag" ||
22286          test ! -s conftest.err
22287        } && test -s conftest$ac_exeext && {
22288          test "$cross_compiling" = yes ||
22289          $as_test_x conftest$ac_exeext
22290        }; then
22291   eval "$as_ac_var=yes"
22292 else
22293   $as_echo "$as_me: failed program was:" >&5
22294 sed 's/^/| /' conftest.$ac_ext >&5
22295
22296         eval "$as_ac_var=no"
22297 fi
22298
22299 rm -rf conftest.dSYM
22300 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22301       conftest$ac_exeext conftest.$ac_ext
22302 fi
22303 ac_res=`eval 'as_val=${'$as_ac_var'}
22304                  $as_echo "$as_val"'`
22305                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22306 $as_echo "$ac_res" >&6; }
22307 as_val=`eval 'as_val=${'$as_ac_var'}
22308                  $as_echo "$as_val"'`
22309    if test "x$as_val" = x""yes; then
22310   cat >>confdefs.h <<_ACEOF
22311 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22312 _ACEOF
22313  break
22314 fi
22315 done
22316
22317
22318 # Check for one of atexit() or on_exit()
22319
22320 for ac_func in atexit
22321 do
22322 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22323 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22324 $as_echo_n "checking for $ac_func... " >&6; }
22325 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22326   $as_echo_n "(cached) " >&6
22327 else
22328   cat >conftest.$ac_ext <<_ACEOF
22329 /* confdefs.h.  */
22330 _ACEOF
22331 cat confdefs.h >>conftest.$ac_ext
22332 cat >>conftest.$ac_ext <<_ACEOF
22333 /* end confdefs.h.  */
22334 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22335    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22336 #define $ac_func innocuous_$ac_func
22337
22338 /* System header to define __stub macros and hopefully few prototypes,
22339     which can conflict with char $ac_func (); below.
22340     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22341     <limits.h> exists even on freestanding compilers.  */
22342
22343 #ifdef __STDC__
22344 # include <limits.h>
22345 #else
22346 # include <assert.h>
22347 #endif
22348
22349 #undef $ac_func
22350
22351 /* Override any GCC internal prototype to avoid an error.
22352    Use char because int might match the return type of a GCC
22353    builtin and then its argument prototype would still apply.  */
22354 #ifdef __cplusplus
22355 extern "C"
22356 #endif
22357 char $ac_func ();
22358 /* The GNU C library defines this for functions which it implements
22359     to always fail with ENOSYS.  Some functions are actually named
22360     something starting with __ and the normal name is an alias.  */
22361 #if defined __stub_$ac_func || defined __stub___$ac_func
22362 choke me
22363 #endif
22364
22365 int
22366 main ()
22367 {
22368 return $ac_func ();
22369   ;
22370   return 0;
22371 }
22372 _ACEOF
22373 rm -f conftest.$ac_objext conftest$ac_exeext
22374 if { (ac_try="$ac_link"
22375 case "(($ac_try" in
22376   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22377   *) ac_try_echo=$ac_try;;
22378 esac
22379 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22380 $as_echo "$ac_try_echo") >&5
22381   (eval "$ac_link") 2>conftest.er1
22382   ac_status=$?
22383   grep -v '^ *+' conftest.er1 >conftest.err
22384   rm -f conftest.er1
22385   cat conftest.err >&5
22386   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22387   (exit $ac_status); } && {
22388          test -z "$ac_c_werror_flag" ||
22389          test ! -s conftest.err
22390        } && test -s conftest$ac_exeext && {
22391          test "$cross_compiling" = yes ||
22392          $as_test_x conftest$ac_exeext
22393        }; then
22394   eval "$as_ac_var=yes"
22395 else
22396   $as_echo "$as_me: failed program was:" >&5
22397 sed 's/^/| /' conftest.$ac_ext >&5
22398
22399         eval "$as_ac_var=no"
22400 fi
22401
22402 rm -rf conftest.dSYM
22403 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22404       conftest$ac_exeext conftest.$ac_ext
22405 fi
22406 ac_res=`eval 'as_val=${'$as_ac_var'}
22407                  $as_echo "$as_val"'`
22408                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22409 $as_echo "$ac_res" >&6; }
22410 as_val=`eval 'as_val=${'$as_ac_var'}
22411                  $as_echo "$as_val"'`
22412    if test "x$as_val" = x""yes; then
22413   cat >>confdefs.h <<_ACEOF
22414 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22415 _ACEOF
22416
22417 else
22418
22419 for ac_func in on_exit
22420 do
22421 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22422 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22423 $as_echo_n "checking for $ac_func... " >&6; }
22424 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22425   $as_echo_n "(cached) " >&6
22426 else
22427   cat >conftest.$ac_ext <<_ACEOF
22428 /* confdefs.h.  */
22429 _ACEOF
22430 cat confdefs.h >>conftest.$ac_ext
22431 cat >>conftest.$ac_ext <<_ACEOF
22432 /* end confdefs.h.  */
22433 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22434    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22435 #define $ac_func innocuous_$ac_func
22436
22437 /* System header to define __stub macros and hopefully few prototypes,
22438     which can conflict with char $ac_func (); below.
22439     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22440     <limits.h> exists even on freestanding compilers.  */
22441
22442 #ifdef __STDC__
22443 # include <limits.h>
22444 #else
22445 # include <assert.h>
22446 #endif
22447
22448 #undef $ac_func
22449
22450 /* Override any GCC internal prototype to avoid an error.
22451    Use char because int might match the return type of a GCC
22452    builtin and then its argument prototype would still apply.  */
22453 #ifdef __cplusplus
22454 extern "C"
22455 #endif
22456 char $ac_func ();
22457 /* The GNU C library defines this for functions which it implements
22458     to always fail with ENOSYS.  Some functions are actually named
22459     something starting with __ and the normal name is an alias.  */
22460 #if defined __stub_$ac_func || defined __stub___$ac_func
22461 choke me
22462 #endif
22463
22464 int
22465 main ()
22466 {
22467 return $ac_func ();
22468   ;
22469   return 0;
22470 }
22471 _ACEOF
22472 rm -f conftest.$ac_objext conftest$ac_exeext
22473 if { (ac_try="$ac_link"
22474 case "(($ac_try" in
22475   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22476   *) ac_try_echo=$ac_try;;
22477 esac
22478 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22479 $as_echo "$ac_try_echo") >&5
22480   (eval "$ac_link") 2>conftest.er1
22481   ac_status=$?
22482   grep -v '^ *+' conftest.er1 >conftest.err
22483   rm -f conftest.er1
22484   cat conftest.err >&5
22485   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22486   (exit $ac_status); } && {
22487          test -z "$ac_c_werror_flag" ||
22488          test ! -s conftest.err
22489        } && test -s conftest$ac_exeext && {
22490          test "$cross_compiling" = yes ||
22491          $as_test_x conftest$ac_exeext
22492        }; then
22493   eval "$as_ac_var=yes"
22494 else
22495   $as_echo "$as_me: failed program was:" >&5
22496 sed 's/^/| /' conftest.$ac_ext >&5
22497
22498         eval "$as_ac_var=no"
22499 fi
22500
22501 rm -rf conftest.dSYM
22502 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22503       conftest$ac_exeext conftest.$ac_ext
22504 fi
22505 ac_res=`eval 'as_val=${'$as_ac_var'}
22506                  $as_echo "$as_val"'`
22507                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22508 $as_echo "$ac_res" >&6; }
22509 as_val=`eval 'as_val=${'$as_ac_var'}
22510                  $as_echo "$as_val"'`
22511    if test "x$as_val" = x""yes; then
22512   cat >>confdefs.h <<_ACEOF
22513 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22514 _ACEOF
22515
22516 else
22517   { { $as_echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
22518 $as_echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
22519    { (exit 1); exit 1; }; }
22520 fi
22521 done
22522
22523 fi
22524 done
22525
22526
22527
22528 #
22529 # Pthreads
22530 #
22531 # For each platform, we need to know about any special compile and link
22532 # libraries, and whether the normal C function names are thread-safe.
22533 # See the comment at the top of src/port/thread.c for more information.
22534 # WIN32 doesn't need the pthread tests;  it always uses threads
22535 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
22536
22537
22538
22539 ac_ext=c
22540 ac_cpp='$CPP $CPPFLAGS'
22541 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22542 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22543 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22544
22545 acx_pthread_ok=no
22546
22547 # We used to check for pthread.h first, but this fails if pthread.h
22548 # requires special compiler flags (e.g. on True64 or Sequent).
22549 # It gets checked for in the link test anyway.
22550
22551 # First of all, check if the user has set any of the PTHREAD_LIBS,
22552 # etcetera environment variables, and if threads linking works using
22553 # them:
22554 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
22555         save_CFLAGS="$CFLAGS"
22556         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22557         save_LIBS="$LIBS"
22558         LIBS="$PTHREAD_LIBS $LIBS"
22559         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
22560 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
22561         cat >conftest.$ac_ext <<_ACEOF
22562 /* confdefs.h.  */
22563 _ACEOF
22564 cat confdefs.h >>conftest.$ac_ext
22565 cat >>conftest.$ac_ext <<_ACEOF
22566 /* end confdefs.h.  */
22567
22568 /* Override any GCC internal prototype to avoid an error.
22569    Use char because int might match the return type of a GCC
22570    builtin and then its argument prototype would still apply.  */
22571 #ifdef __cplusplus
22572 extern "C"
22573 #endif
22574 char pthread_join ();
22575 int
22576 main ()
22577 {
22578 return pthread_join ();
22579   ;
22580   return 0;
22581 }
22582 _ACEOF
22583 rm -f conftest.$ac_objext conftest$ac_exeext
22584 if { (ac_try="$ac_link"
22585 case "(($ac_try" in
22586   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22587   *) ac_try_echo=$ac_try;;
22588 esac
22589 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22590 $as_echo "$ac_try_echo") >&5
22591   (eval "$ac_link") 2>conftest.er1
22592   ac_status=$?
22593   grep -v '^ *+' conftest.er1 >conftest.err
22594   rm -f conftest.er1
22595   cat conftest.err >&5
22596   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22597   (exit $ac_status); } && {
22598          test -z "$ac_c_werror_flag" ||
22599          test ! -s conftest.err
22600        } && test -s conftest$ac_exeext && {
22601          test "$cross_compiling" = yes ||
22602          $as_test_x conftest$ac_exeext
22603        }; then
22604   acx_pthread_ok=yes
22605 else
22606   $as_echo "$as_me: failed program was:" >&5
22607 sed 's/^/| /' conftest.$ac_ext >&5
22608
22609
22610 fi
22611
22612 rm -rf conftest.dSYM
22613 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22614       conftest$ac_exeext conftest.$ac_ext
22615         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22616 $as_echo "$acx_pthread_ok" >&6; }
22617         if test x"$acx_pthread_ok" = xno; then
22618                 PTHREAD_LIBS=""
22619                 PTHREAD_CFLAGS=""
22620         fi
22621         LIBS="$save_LIBS"
22622         CFLAGS="$save_CFLAGS"
22623 fi
22624
22625 # We must check for the threads library under a number of different
22626 # names; the ordering is very important because some systems
22627 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
22628 # libraries is broken (non-POSIX).
22629
22630 # Create a list of thread flags to try.  Items starting with a "-" are
22631 # C compiler flags, and other items are library names, except for "none"
22632 # which indicates that we try without any flags at all, and "pthread-config"
22633 # which is a program returning the flags for the Pth emulation library.
22634
22635 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
22636
22637 # The ordering *is* (sometimes) important.  Some notes on the
22638 # individual items follow:
22639
22640 # pthreads: AIX (must check this before -lpthread)
22641 # none: in case threads are in libc; should be tried before -Kthread and
22642 #       other compiler flags to prevent continual compiler warnings
22643 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
22644 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
22645 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
22646 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
22647 # -pthreads: Solaris/gcc
22648 # -mthreads: Mingw32/gcc, Lynx/gcc
22649 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
22650 #      doesn't hurt to check since this sometimes defines pthreads too;
22651 #      also defines -D_REENTRANT)
22652 # pthread: Linux, etcetera
22653 # --thread-safe: KAI C++
22654 # pthread-config: use pthread-config program (for GNU Pth library)
22655
22656 case "${host_cpu}-${host_os}" in
22657         *solaris*)
22658
22659         # On Solaris (at least, for some versions), libc contains stubbed
22660         # (non-functional) versions of the pthreads routines, so link-based
22661         # tests will erroneously succeed.  (We need to link with -pthread or
22662         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
22663         # a function called by this macro, so we could check for that, but
22664         # who knows whether they'll stub that too in a future libc.)  So,
22665         # we'll just look for -pthreads and -lpthread first:
22666
22667         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
22668         ;;
22669 esac
22670
22671 if test x"$acx_pthread_ok" = xno; then
22672 for flag in $acx_pthread_flags; do
22673
22674         tryPTHREAD_CFLAGS=""
22675         tryPTHREAD_LIBS=""
22676         case $flag in
22677                 none)
22678                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
22679 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
22680                 ;;
22681
22682                 -*)
22683                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
22684 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
22685                 tryPTHREAD_CFLAGS="$flag"
22686                 ;;
22687
22688                 pthread-config)
22689                 # skip this if we already have flags defined, for PostgreSQL
22690                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
22691                 # Extract the first word of "pthread-config", so it can be a program name with args.
22692 set dummy pthread-config; ac_word=$2
22693 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22694 $as_echo_n "checking for $ac_word... " >&6; }
22695 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
22696   $as_echo_n "(cached) " >&6
22697 else
22698   if test -n "$acx_pthread_config"; then
22699   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
22700 else
22701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22702 for as_dir in $PATH
22703 do
22704   IFS=$as_save_IFS
22705   test -z "$as_dir" && as_dir=.
22706   for ac_exec_ext in '' $ac_executable_extensions; do
22707   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22708     ac_cv_prog_acx_pthread_config="yes"
22709     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22710     break 2
22711   fi
22712 done
22713 done
22714 IFS=$as_save_IFS
22715
22716   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
22717 fi
22718 fi
22719 acx_pthread_config=$ac_cv_prog_acx_pthread_config
22720 if test -n "$acx_pthread_config"; then
22721   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
22722 $as_echo "$acx_pthread_config" >&6; }
22723 else
22724   { $as_echo "$as_me:$LINENO: result: no" >&5
22725 $as_echo "no" >&6; }
22726 fi
22727
22728
22729                 if test x"$acx_pthread_config" = xno; then continue; fi
22730                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
22731                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
22732                 ;;
22733
22734                 *)
22735                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
22736 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
22737                 tryPTHREAD_LIBS="-l$flag"
22738                 ;;
22739         esac
22740
22741         save_LIBS="$LIBS"
22742         save_CFLAGS="$CFLAGS"
22743         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
22744         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22745
22746         # Check for various functions.  We must include pthread.h,
22747         # since some functions may be macros.  (On the Sequent, we
22748         # need a special flag -Kthread to make this header compile.)
22749         # We check for pthread_join because it is in -lpthread on IRIX
22750         # while pthread_create is in libc.  We check for pthread_attr_init
22751         # due to DEC craziness with -lpthreads.  We check for
22752         # pthread_cleanup_push because it is one of the few pthread
22753         # functions on Solaris that doesn't have a non-functional libc stub.
22754         # We try pthread_create on general principles.
22755         cat >conftest.$ac_ext <<_ACEOF
22756 /* confdefs.h.  */
22757 _ACEOF
22758 cat confdefs.h >>conftest.$ac_ext
22759 cat >>conftest.$ac_ext <<_ACEOF
22760 /* end confdefs.h.  */
22761 #include <pthread.h>
22762 int
22763 main ()
22764 {
22765 pthread_t th; pthread_join(th, 0);
22766                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
22767                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
22768   ;
22769   return 0;
22770 }
22771 _ACEOF
22772 rm -f conftest.$ac_objext conftest$ac_exeext
22773 if { (ac_try="$ac_link"
22774 case "(($ac_try" in
22775   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22776   *) ac_try_echo=$ac_try;;
22777 esac
22778 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22779 $as_echo "$ac_try_echo") >&5
22780   (eval "$ac_link") 2>conftest.er1
22781   ac_status=$?
22782   grep -v '^ *+' conftest.er1 >conftest.err
22783   rm -f conftest.er1
22784   cat conftest.err >&5
22785   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22786   (exit $ac_status); } && {
22787          test -z "$ac_c_werror_flag" ||
22788          test ! -s conftest.err
22789        } && test -s conftest$ac_exeext && {
22790          test "$cross_compiling" = yes ||
22791          $as_test_x conftest$ac_exeext
22792        }; then
22793   acx_pthread_ok=yes
22794 else
22795   $as_echo "$as_me: failed program was:" >&5
22796 sed 's/^/| /' conftest.$ac_ext >&5
22797
22798         acx_pthread_ok=no
22799 fi
22800
22801 rm -rf conftest.dSYM
22802 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22803       conftest$ac_exeext conftest.$ac_ext
22804
22805         if test "x$acx_pthread_ok" = xyes; then
22806             # Don't use options that are ignored by the compiler.
22807             # We find them by checking stderror.
22808             cat >conftest.$ac_ext <<_ACEOF
22809 int
22810 main (int argc, char **argv)
22811 {
22812   (void) argc;
22813   (void) argv;
22814   return 0;
22815 }
22816 _ACEOF
22817             rm -f conftest.$ac_objext conftest$ac_exeext
22818             # Check both linking and compiling, because they might tolerate different options.
22819             if test "`(eval $ac_link 2>&1 1>&5)`" = "" && test "`(eval $ac_compile 2>&1 1>&5)`" = ""; then
22820                 # we continue with more flags because Linux needs -lpthread
22821                 # for libpq builds on PostgreSQL.  The test above only
22822                 # tests for building binaries, not shared libraries.
22823                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
22824                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22825             else   acx_pthread_ok=no
22826             fi
22827         fi
22828
22829         LIBS="$save_LIBS"
22830         CFLAGS="$save_CFLAGS"
22831
22832         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22833 $as_echo "$acx_pthread_ok" >&6; }
22834 done
22835 fi
22836
22837 # Various other checks:
22838 if test "x$acx_pthread_ok" = xyes; then
22839         save_LIBS="$LIBS"
22840         LIBS="$PTHREAD_LIBS $LIBS"
22841         save_CFLAGS="$CFLAGS"
22842         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22843
22844         # Detect AIX lossage: threads are created detached by default
22845         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
22846         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
22847 $as_echo_n "checking for joinable pthread attribute... " >&6; }
22848         cat >conftest.$ac_ext <<_ACEOF
22849 /* confdefs.h.  */
22850 _ACEOF
22851 cat confdefs.h >>conftest.$ac_ext
22852 cat >>conftest.$ac_ext <<_ACEOF
22853 /* end confdefs.h.  */
22854 #include <pthread.h>
22855 int
22856 main ()
22857 {
22858 int attr=PTHREAD_CREATE_JOINABLE;
22859   ;
22860   return 0;
22861 }
22862 _ACEOF
22863 rm -f conftest.$ac_objext conftest$ac_exeext
22864 if { (ac_try="$ac_link"
22865 case "(($ac_try" in
22866   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22867   *) ac_try_echo=$ac_try;;
22868 esac
22869 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22870 $as_echo "$ac_try_echo") >&5
22871   (eval "$ac_link") 2>conftest.er1
22872   ac_status=$?
22873   grep -v '^ *+' conftest.er1 >conftest.err
22874   rm -f conftest.er1
22875   cat conftest.err >&5
22876   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22877   (exit $ac_status); } && {
22878          test -z "$ac_c_werror_flag" ||
22879          test ! -s conftest.err
22880        } && test -s conftest$ac_exeext && {
22881          test "$cross_compiling" = yes ||
22882          $as_test_x conftest$ac_exeext
22883        }; then
22884   ok=PTHREAD_CREATE_JOINABLE
22885 else
22886   $as_echo "$as_me: failed program was:" >&5
22887 sed 's/^/| /' conftest.$ac_ext >&5
22888
22889         ok=unknown
22890 fi
22891
22892 rm -rf conftest.dSYM
22893 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22894       conftest$ac_exeext conftest.$ac_ext
22895         if test x"$ok" = xunknown; then
22896                 cat >conftest.$ac_ext <<_ACEOF
22897 /* confdefs.h.  */
22898 _ACEOF
22899 cat confdefs.h >>conftest.$ac_ext
22900 cat >>conftest.$ac_ext <<_ACEOF
22901 /* end confdefs.h.  */
22902 #include <pthread.h>
22903 int
22904 main ()
22905 {
22906 int attr=PTHREAD_CREATE_UNDETACHED;
22907   ;
22908   return 0;
22909 }
22910 _ACEOF
22911 rm -f conftest.$ac_objext conftest$ac_exeext
22912 if { (ac_try="$ac_link"
22913 case "(($ac_try" in
22914   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22915   *) ac_try_echo=$ac_try;;
22916 esac
22917 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22918 $as_echo "$ac_try_echo") >&5
22919   (eval "$ac_link") 2>conftest.er1
22920   ac_status=$?
22921   grep -v '^ *+' conftest.er1 >conftest.err
22922   rm -f conftest.er1
22923   cat conftest.err >&5
22924   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22925   (exit $ac_status); } && {
22926          test -z "$ac_c_werror_flag" ||
22927          test ! -s conftest.err
22928        } && test -s conftest$ac_exeext && {
22929          test "$cross_compiling" = yes ||
22930          $as_test_x conftest$ac_exeext
22931        }; then
22932   ok=PTHREAD_CREATE_UNDETACHED
22933 else
22934   $as_echo "$as_me: failed program was:" >&5
22935 sed 's/^/| /' conftest.$ac_ext >&5
22936
22937         ok=unknown
22938 fi
22939
22940 rm -rf conftest.dSYM
22941 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22942       conftest$ac_exeext conftest.$ac_ext
22943         fi
22944         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
22945
22946 cat >>confdefs.h <<\_ACEOF
22947 #define PTHREAD_CREATE_JOINABLE $ok
22948 _ACEOF
22949
22950         fi
22951         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
22952 $as_echo "${ok}" >&6; }
22953         if test x"$ok" = xunknown; then
22954                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
22955 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
22956         fi
22957
22958         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
22959 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
22960         flag=no
22961 # We always add these in PostgreSQL
22962 #       case "${host_cpu}-${host_os}" in
22963 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
22964 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
22965 #       esac
22966         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
22967 $as_echo "${flag}" >&6; }
22968         if test "x$flag" != xno; then
22969                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
22970         fi
22971
22972         LIBS="$save_LIBS"
22973         CFLAGS="$save_CFLAGS"
22974
22975 # Supporting cc_r would require a special CC in all places that
22976 # use libpq, and that is ugly, so we don't do it.  Users can still
22977 # define their compiler as cc_r to do thread builds of everything.
22978         # More AIX lossage: must compile with cc_r
22979         # Extract the first word of "cc_r", so it can be a program name with args.
22980 set dummy cc_r; ac_word=$2
22981 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22982 $as_echo_n "checking for $ac_word... " >&6; }
22983 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
22984   $as_echo_n "(cached) " >&6
22985 else
22986   if test -n "$PTHREAD_CC"; then
22987   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
22988 else
22989 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22990 for as_dir in $PATH
22991 do
22992   IFS=$as_save_IFS
22993   test -z "$as_dir" && as_dir=.
22994   for ac_exec_ext in '' $ac_executable_extensions; do
22995   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22996     ac_cv_prog_PTHREAD_CC="cc_r"
22997     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22998     break 2
22999   fi
23000 done
23001 done
23002 IFS=$as_save_IFS
23003
23004   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
23005 fi
23006 fi
23007 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
23008 if test -n "$PTHREAD_CC"; then
23009   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
23010 $as_echo "$PTHREAD_CC" >&6; }
23011 else
23012   { $as_echo "$as_me:$LINENO: result: no" >&5
23013 $as_echo "no" >&6; }
23014 fi
23015
23016
23017 else
23018         PTHREAD_CC="$CC"
23019 fi
23020
23021
23022
23023
23024
23025 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
23026 if test x"$acx_pthread_ok" = xyes; then
23027
23028 cat >>confdefs.h <<\_ACEOF
23029 #define HAVE_PTHREAD 1
23030 _ACEOF
23031
23032         :
23033 else
23034         acx_pthread_ok=no
23035
23036 fi
23037 ac_ext=c
23038 ac_cpp='$CPP $CPPFLAGS'
23039 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
23040 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
23041 ac_compiler_gnu=$ac_cv_c_compiler_gnu
23042
23043         # set thread flags
23044
23045 # Some platforms use these, so just define them.  They can't hurt if they
23046 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
23047 # enables 5-arg getpwuid_r, among other things.
23048 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
23049
23050
23051 # At this point, we don't want to muck with the compiler name for threading.
23052 # Let's see who fails, perhaps AIX.  2004-04-23
23053 if test "$PTHREAD_CC" != "$CC"; then
23054 { { $as_echo "$as_me:$LINENO: error:
23055 PostgreSQL does not support platforms that require a special compiler
23056 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
23057 $as_echo "$as_me: error:
23058 PostgreSQL does not support platforms that require a special compiler
23059 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
23060    { (exit 1); exit 1; }; }
23061 fi
23062
23063 # Check for *_r functions
23064 _CFLAGS="$CFLAGS"
23065 _LIBS="$LIBS"
23066 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
23067 LIBS="$LIBS $PTHREAD_LIBS"
23068
23069 if test "$PORTNAME" != "win32"; then
23070 if test "${ac_cv_header_pthread_h+set}" = set; then
23071   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23072 $as_echo_n "checking for pthread.h... " >&6; }
23073 if test "${ac_cv_header_pthread_h+set}" = set; then
23074   $as_echo_n "(cached) " >&6
23075 fi
23076 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23077 $as_echo "$ac_cv_header_pthread_h" >&6; }
23078 else
23079   # Is the header compilable?
23080 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
23081 $as_echo_n "checking pthread.h usability... " >&6; }
23082 cat >conftest.$ac_ext <<_ACEOF
23083 /* confdefs.h.  */
23084 _ACEOF
23085 cat confdefs.h >>conftest.$ac_ext
23086 cat >>conftest.$ac_ext <<_ACEOF
23087 /* end confdefs.h.  */
23088 $ac_includes_default
23089 #include <pthread.h>
23090 _ACEOF
23091 rm -f conftest.$ac_objext
23092 if { (ac_try="$ac_compile"
23093 case "(($ac_try" in
23094   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23095   *) ac_try_echo=$ac_try;;
23096 esac
23097 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23098 $as_echo "$ac_try_echo") >&5
23099   (eval "$ac_compile") 2>conftest.er1
23100   ac_status=$?
23101   grep -v '^ *+' conftest.er1 >conftest.err
23102   rm -f conftest.er1
23103   cat conftest.err >&5
23104   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23105   (exit $ac_status); } && {
23106          test -z "$ac_c_werror_flag" ||
23107          test ! -s conftest.err
23108        } && test -s conftest.$ac_objext; then
23109   ac_header_compiler=yes
23110 else
23111   $as_echo "$as_me: failed program was:" >&5
23112 sed 's/^/| /' conftest.$ac_ext >&5
23113
23114         ac_header_compiler=no
23115 fi
23116
23117 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23118 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23119 $as_echo "$ac_header_compiler" >&6; }
23120
23121 # Is the header present?
23122 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
23123 $as_echo_n "checking pthread.h presence... " >&6; }
23124 cat >conftest.$ac_ext <<_ACEOF
23125 /* confdefs.h.  */
23126 _ACEOF
23127 cat confdefs.h >>conftest.$ac_ext
23128 cat >>conftest.$ac_ext <<_ACEOF
23129 /* end confdefs.h.  */
23130 #include <pthread.h>
23131 _ACEOF
23132 if { (ac_try="$ac_cpp conftest.$ac_ext"
23133 case "(($ac_try" in
23134   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23135   *) ac_try_echo=$ac_try;;
23136 esac
23137 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23138 $as_echo "$ac_try_echo") >&5
23139   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
23140   ac_status=$?
23141   grep -v '^ *+' conftest.er1 >conftest.err
23142   rm -f conftest.er1
23143   cat conftest.err >&5
23144   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23145   (exit $ac_status); } >/dev/null && {
23146          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
23147          test ! -s conftest.err
23148        }; then
23149   ac_header_preproc=yes
23150 else
23151   $as_echo "$as_me: failed program was:" >&5
23152 sed 's/^/| /' conftest.$ac_ext >&5
23153
23154   ac_header_preproc=no
23155 fi
23156
23157 rm -f conftest.err conftest.$ac_ext
23158 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23159 $as_echo "$ac_header_preproc" >&6; }
23160
23161 # So?  What about this header?
23162 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
23163   yes:no: )
23164     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
23165 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
23166     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
23167 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
23168     ac_header_preproc=yes
23169     ;;
23170   no:yes:* )
23171     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
23172 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
23173     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
23174 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
23175     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
23176 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
23177     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
23178 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
23179     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
23180 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
23181     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
23182 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
23183     ( cat <<\_ASBOX
23184 ## ---------------------------------------- ##
23185 ## Report this to pgsql-bugs@postgresql.org ##
23186 ## ---------------------------------------- ##
23187 _ASBOX
23188      ) | sed "s/^/$as_me: WARNING:     /" >&2
23189     ;;
23190 esac
23191 { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23192 $as_echo_n "checking for pthread.h... " >&6; }
23193 if test "${ac_cv_header_pthread_h+set}" = set; then
23194   $as_echo_n "(cached) " >&6
23195 else
23196   ac_cv_header_pthread_h=$ac_header_preproc
23197 fi
23198 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23199 $as_echo "$ac_cv_header_pthread_h" >&6; }
23200
23201 fi
23202 if test "x$ac_cv_header_pthread_h" = x""yes; then
23203   :
23204 else
23205   { { $as_echo "$as_me:$LINENO: error:
23206 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
23207 $as_echo "$as_me: error:
23208 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
23209    { (exit 1); exit 1; }; }
23210 fi
23211
23212
23213 fi
23214
23215
23216
23217
23218 for ac_func in strerror_r getpwuid_r gethostbyname_r
23219 do
23220 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23221 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
23222 $as_echo_n "checking for $ac_func... " >&6; }
23223 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23224   $as_echo_n "(cached) " >&6
23225 else
23226   cat >conftest.$ac_ext <<_ACEOF
23227 /* confdefs.h.  */
23228 _ACEOF
23229 cat confdefs.h >>conftest.$ac_ext
23230 cat >>conftest.$ac_ext <<_ACEOF
23231 /* end confdefs.h.  */
23232 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23233    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23234 #define $ac_func innocuous_$ac_func
23235
23236 /* System header to define __stub macros and hopefully few prototypes,
23237     which can conflict with char $ac_func (); below.
23238     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23239     <limits.h> exists even on freestanding compilers.  */
23240
23241 #ifdef __STDC__
23242 # include <limits.h>
23243 #else
23244 # include <assert.h>
23245 #endif
23246
23247 #undef $ac_func
23248
23249 /* Override any GCC internal prototype to avoid an error.
23250    Use char because int might match the return type of a GCC
23251    builtin and then its argument prototype would still apply.  */
23252 #ifdef __cplusplus
23253 extern "C"
23254 #endif
23255 char $ac_func ();
23256 /* The GNU C library defines this for functions which it implements
23257     to always fail with ENOSYS.  Some functions are actually named
23258     something starting with __ and the normal name is an alias.  */
23259 #if defined __stub_$ac_func || defined __stub___$ac_func
23260 choke me
23261 #endif
23262
23263 int
23264 main ()
23265 {
23266 return $ac_func ();
23267   ;
23268   return 0;
23269 }
23270 _ACEOF
23271 rm -f conftest.$ac_objext conftest$ac_exeext
23272 if { (ac_try="$ac_link"
23273 case "(($ac_try" in
23274   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23275   *) ac_try_echo=$ac_try;;
23276 esac
23277 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23278 $as_echo "$ac_try_echo") >&5
23279   (eval "$ac_link") 2>conftest.er1
23280   ac_status=$?
23281   grep -v '^ *+' conftest.er1 >conftest.err
23282   rm -f conftest.er1
23283   cat conftest.err >&5
23284   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23285   (exit $ac_status); } && {
23286          test -z "$ac_c_werror_flag" ||
23287          test ! -s conftest.err
23288        } && test -s conftest$ac_exeext && {
23289          test "$cross_compiling" = yes ||
23290          $as_test_x conftest$ac_exeext
23291        }; then
23292   eval "$as_ac_var=yes"
23293 else
23294   $as_echo "$as_me: failed program was:" >&5
23295 sed 's/^/| /' conftest.$ac_ext >&5
23296
23297         eval "$as_ac_var=no"
23298 fi
23299
23300 rm -rf conftest.dSYM
23301 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23302       conftest$ac_exeext conftest.$ac_ext
23303 fi
23304 ac_res=`eval 'as_val=${'$as_ac_var'}
23305                  $as_echo "$as_val"'`
23306                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23307 $as_echo "$ac_res" >&6; }
23308 as_val=`eval 'as_val=${'$as_ac_var'}
23309                  $as_echo "$as_val"'`
23310    if test "x$as_val" = x""yes; then
23311   cat >>confdefs.h <<_ACEOF
23312 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23313 _ACEOF
23314
23315 fi
23316 done
23317
23318
23319 # Do test here with the proper thread flags
23320 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
23321 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
23322 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
23323   $as_echo_n "(cached) " >&6
23324 else
23325   cat >conftest.$ac_ext <<_ACEOF
23326 /* confdefs.h.  */
23327 _ACEOF
23328 cat confdefs.h >>conftest.$ac_ext
23329 cat >>conftest.$ac_ext <<_ACEOF
23330 /* end confdefs.h.  */
23331 #include <sys/types.h>
23332 #include <pwd.h>
23333 int
23334 main ()
23335 {
23336 uid_t uid;
23337 struct passwd *space;
23338 char *buf;
23339 size_t bufsize;
23340 struct passwd **result;
23341 getpwuid_r(uid, space, buf, bufsize, result);
23342   ;
23343   return 0;
23344 }
23345 _ACEOF
23346 rm -f conftest.$ac_objext
23347 if { (ac_try="$ac_compile"
23348 case "(($ac_try" in
23349   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23350   *) ac_try_echo=$ac_try;;
23351 esac
23352 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23353 $as_echo "$ac_try_echo") >&5
23354   (eval "$ac_compile") 2>conftest.er1
23355   ac_status=$?
23356   grep -v '^ *+' conftest.er1 >conftest.err
23357   rm -f conftest.er1
23358   cat conftest.err >&5
23359   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23360   (exit $ac_status); } && {
23361          test -z "$ac_c_werror_flag" ||
23362          test ! -s conftest.err
23363        } && test -s conftest.$ac_objext; then
23364   pgac_cv_func_getpwuid_r_5arg=yes
23365 else
23366   $as_echo "$as_me: failed program was:" >&5
23367 sed 's/^/| /' conftest.$ac_ext >&5
23368
23369         pgac_cv_func_getpwuid_r_5arg=no
23370 fi
23371
23372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23373 fi
23374 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
23375 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
23376 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
23377
23378 cat >>confdefs.h <<\_ACEOF
23379 #define GETPWUID_R_5ARG /**/
23380 _ACEOF
23381
23382 fi
23383
23384 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
23385 $as_echo_n "checking whether strerror_r returns int... " >&6; }
23386 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
23387   $as_echo_n "(cached) " >&6
23388 else
23389   cat >conftest.$ac_ext <<_ACEOF
23390 /* confdefs.h.  */
23391 _ACEOF
23392 cat confdefs.h >>conftest.$ac_ext
23393 cat >>conftest.$ac_ext <<_ACEOF
23394 /* end confdefs.h.  */
23395 #include <string.h>
23396 int
23397 main ()
23398 {
23399 #ifndef _AIX
23400 int strerror_r(int, char *, size_t);
23401 #else
23402 /* Older AIX has 'int' for the third argument so we don't test the args. */
23403 int strerror_r();
23404 #endif
23405   ;
23406   return 0;
23407 }
23408 _ACEOF
23409 rm -f conftest.$ac_objext
23410 if { (ac_try="$ac_compile"
23411 case "(($ac_try" in
23412   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23413   *) ac_try_echo=$ac_try;;
23414 esac
23415 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23416 $as_echo "$ac_try_echo") >&5
23417   (eval "$ac_compile") 2>conftest.er1
23418   ac_status=$?
23419   grep -v '^ *+' conftest.er1 >conftest.err
23420   rm -f conftest.er1
23421   cat conftest.err >&5
23422   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23423   (exit $ac_status); } && {
23424          test -z "$ac_c_werror_flag" ||
23425          test ! -s conftest.err
23426        } && test -s conftest.$ac_objext; then
23427   pgac_cv_func_strerror_r_int=yes
23428 else
23429   $as_echo "$as_me: failed program was:" >&5
23430 sed 's/^/| /' conftest.$ac_ext >&5
23431
23432         pgac_cv_func_strerror_r_int=no
23433 fi
23434
23435 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23436 fi
23437 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
23438 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
23439 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
23440
23441 cat >>confdefs.h <<\_ACEOF
23442 #define STRERROR_R_INT /**/
23443 _ACEOF
23444
23445 fi
23446
23447
23448 CFLAGS="$_CFLAGS"
23449 LIBS="$_LIBS"
23450
23451 else
23452 # do not use values from template file
23453 PTHREAD_CFLAGS=
23454 PTHREAD_LIBS=
23455 fi
23456
23457
23458
23459
23460
23461 # We can test for libldap_r only after we know PTHREAD_LIBS
23462 if test "$with_ldap" = yes ; then
23463   _LIBS="$LIBS"
23464   if test "$PORTNAME" != "win32"; then
23465
23466 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
23467 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
23468 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
23469   $as_echo_n "(cached) " >&6
23470 else
23471   ac_check_lib_save_LIBS=$LIBS
23472 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
23473 cat >conftest.$ac_ext <<_ACEOF
23474 /* confdefs.h.  */
23475 _ACEOF
23476 cat confdefs.h >>conftest.$ac_ext
23477 cat >>conftest.$ac_ext <<_ACEOF
23478 /* end confdefs.h.  */
23479
23480 /* Override any GCC internal prototype to avoid an error.
23481    Use char because int might match the return type of a GCC
23482    builtin and then its argument prototype would still apply.  */
23483 #ifdef __cplusplus
23484 extern "C"
23485 #endif
23486 char ldap_bind ();
23487 int
23488 main ()
23489 {
23490 return ldap_bind ();
23491   ;
23492   return 0;
23493 }
23494 _ACEOF
23495 rm -f conftest.$ac_objext conftest$ac_exeext
23496 if { (ac_try="$ac_link"
23497 case "(($ac_try" in
23498   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23499   *) ac_try_echo=$ac_try;;
23500 esac
23501 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23502 $as_echo "$ac_try_echo") >&5
23503   (eval "$ac_link") 2>conftest.er1
23504   ac_status=$?
23505   grep -v '^ *+' conftest.er1 >conftest.err
23506   rm -f conftest.er1
23507   cat conftest.err >&5
23508   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23509   (exit $ac_status); } && {
23510          test -z "$ac_c_werror_flag" ||
23511          test ! -s conftest.err
23512        } && test -s conftest$ac_exeext && {
23513          test "$cross_compiling" = yes ||
23514          $as_test_x conftest$ac_exeext
23515        }; then
23516   ac_cv_lib_ldap_ldap_bind=yes
23517 else
23518   $as_echo "$as_me: failed program was:" >&5
23519 sed 's/^/| /' conftest.$ac_ext >&5
23520
23521         ac_cv_lib_ldap_ldap_bind=no
23522 fi
23523
23524 rm -rf conftest.dSYM
23525 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23526       conftest$ac_exeext conftest.$ac_ext
23527 LIBS=$ac_check_lib_save_LIBS
23528 fi
23529 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
23530 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
23531 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
23532   cat >>confdefs.h <<_ACEOF
23533 #define HAVE_LIBLDAP 1
23534 _ACEOF
23535
23536   LIBS="-lldap $LIBS"
23537
23538 else
23539   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
23540 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
23541    { (exit 1); exit 1; }; }
23542 fi
23543
23544     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
23545     if test "$enable_thread_safety" = yes; then
23546       # on some platforms ldap_r fails to link without PTHREAD_LIBS
23547
23548 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
23549 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
23550 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
23551   $as_echo_n "(cached) " >&6
23552 else
23553   ac_check_lib_save_LIBS=$LIBS
23554 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
23555 cat >conftest.$ac_ext <<_ACEOF
23556 /* confdefs.h.  */
23557 _ACEOF
23558 cat confdefs.h >>conftest.$ac_ext
23559 cat >>conftest.$ac_ext <<_ACEOF
23560 /* end confdefs.h.  */
23561
23562 /* Override any GCC internal prototype to avoid an error.
23563    Use char because int might match the return type of a GCC
23564    builtin and then its argument prototype would still apply.  */
23565 #ifdef __cplusplus
23566 extern "C"
23567 #endif
23568 char ldap_simple_bind ();
23569 int
23570 main ()
23571 {
23572 return ldap_simple_bind ();
23573   ;
23574   return 0;
23575 }
23576 _ACEOF
23577 rm -f conftest.$ac_objext conftest$ac_exeext
23578 if { (ac_try="$ac_link"
23579 case "(($ac_try" in
23580   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23581   *) ac_try_echo=$ac_try;;
23582 esac
23583 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23584 $as_echo "$ac_try_echo") >&5
23585   (eval "$ac_link") 2>conftest.er1
23586   ac_status=$?
23587   grep -v '^ *+' conftest.er1 >conftest.err
23588   rm -f conftest.er1
23589   cat conftest.err >&5
23590   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23591   (exit $ac_status); } && {
23592          test -z "$ac_c_werror_flag" ||
23593          test ! -s conftest.err
23594        } && test -s conftest$ac_exeext && {
23595          test "$cross_compiling" = yes ||
23596          $as_test_x conftest$ac_exeext
23597        }; then
23598   ac_cv_lib_ldap_r_ldap_simple_bind=yes
23599 else
23600   $as_echo "$as_me: failed program was:" >&5
23601 sed 's/^/| /' conftest.$ac_ext >&5
23602
23603         ac_cv_lib_ldap_r_ldap_simple_bind=no
23604 fi
23605
23606 rm -rf conftest.dSYM
23607 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23608       conftest$ac_exeext conftest.$ac_ext
23609 LIBS=$ac_check_lib_save_LIBS
23610 fi
23611 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
23612 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
23613 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
23614   cat >>confdefs.h <<_ACEOF
23615 #define HAVE_LIBLDAP_R 1
23616 _ACEOF
23617
23618   LIBS="-lldap_r $LIBS"
23619
23620 else
23621   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
23622 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
23623    { (exit 1); exit 1; }; }
23624 fi
23625
23626       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
23627     else
23628       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
23629     fi
23630   else
23631
23632 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
23633 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
23634 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
23635   $as_echo_n "(cached) " >&6
23636 else
23637   ac_check_lib_save_LIBS=$LIBS
23638 LIBS="-lwldap32  $LIBS"
23639 cat >conftest.$ac_ext <<_ACEOF
23640 /* confdefs.h.  */
23641 _ACEOF
23642 cat confdefs.h >>conftest.$ac_ext
23643 cat >>conftest.$ac_ext <<_ACEOF
23644 /* end confdefs.h.  */
23645
23646 /* Override any GCC internal prototype to avoid an error.
23647    Use char because int might match the return type of a GCC
23648    builtin and then its argument prototype would still apply.  */
23649 #ifdef __cplusplus
23650 extern "C"
23651 #endif
23652 char ldap_bind ();
23653 int
23654 main ()
23655 {
23656 return ldap_bind ();
23657   ;
23658   return 0;
23659 }
23660 _ACEOF
23661 rm -f conftest.$ac_objext conftest$ac_exeext
23662 if { (ac_try="$ac_link"
23663 case "(($ac_try" in
23664   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23665   *) ac_try_echo=$ac_try;;
23666 esac
23667 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23668 $as_echo "$ac_try_echo") >&5
23669   (eval "$ac_link") 2>conftest.er1
23670   ac_status=$?
23671   grep -v '^ *+' conftest.er1 >conftest.err
23672   rm -f conftest.er1
23673   cat conftest.err >&5
23674   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23675   (exit $ac_status); } && {
23676          test -z "$ac_c_werror_flag" ||
23677          test ! -s conftest.err
23678        } && test -s conftest$ac_exeext && {
23679          test "$cross_compiling" = yes ||
23680          $as_test_x conftest$ac_exeext
23681        }; then
23682   ac_cv_lib_wldap32_ldap_bind=yes
23683 else
23684   $as_echo "$as_me: failed program was:" >&5
23685 sed 's/^/| /' conftest.$ac_ext >&5
23686
23687         ac_cv_lib_wldap32_ldap_bind=no
23688 fi
23689
23690 rm -rf conftest.dSYM
23691 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23692       conftest$ac_exeext conftest.$ac_ext
23693 LIBS=$ac_check_lib_save_LIBS
23694 fi
23695 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
23696 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
23697 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
23698   cat >>confdefs.h <<_ACEOF
23699 #define HAVE_LIBWLDAP32 1
23700 _ACEOF
23701
23702   LIBS="-lwldap32 $LIBS"
23703
23704 else
23705   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
23706 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
23707    { (exit 1); exit 1; }; }
23708 fi
23709
23710     LDAP_LIBS_FE="-lwldap32"
23711     LDAP_LIBS_BE="-lwldap32"
23712   fi
23713   LIBS="$_LIBS"
23714 fi
23715
23716
23717
23718
23719 # This test makes sure that run tests work at all.  Sometimes a shared
23720 # library is found by the linker, but the runtime linker can't find it.
23721 # This check should come after all modifications of compiler or linker
23722 # variables, and before any other run tests.
23723 { $as_echo "$as_me:$LINENO: checking test program" >&5
23724 $as_echo_n "checking test program... " >&6; }
23725 if test "$cross_compiling" = yes; then
23726   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
23727 $as_echo "cross-compiling" >&6; }
23728 else
23729   cat >conftest.$ac_ext <<_ACEOF
23730 /* confdefs.h.  */
23731 _ACEOF
23732 cat confdefs.h >>conftest.$ac_ext
23733 cat >>conftest.$ac_ext <<_ACEOF
23734 /* end confdefs.h.  */
23735 int main() { return 0; }
23736 _ACEOF
23737 rm -f conftest$ac_exeext
23738 if { (ac_try="$ac_link"
23739 case "(($ac_try" in
23740   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23741   *) ac_try_echo=$ac_try;;
23742 esac
23743 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23744 $as_echo "$ac_try_echo") >&5
23745   (eval "$ac_link") 2>&5
23746   ac_status=$?
23747   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23748   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23749   { (case "(($ac_try" in
23750   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23751   *) ac_try_echo=$ac_try;;
23752 esac
23753 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23754 $as_echo "$ac_try_echo") >&5
23755   (eval "$ac_try") 2>&5
23756   ac_status=$?
23757   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23758   (exit $ac_status); }; }; then
23759   { $as_echo "$as_me:$LINENO: result: ok" >&5
23760 $as_echo "ok" >&6; }
23761 else
23762   $as_echo "$as_me: program exited with status $ac_status" >&5
23763 $as_echo "$as_me: failed program was:" >&5
23764 sed 's/^/| /' conftest.$ac_ext >&5
23765
23766 ( exit $ac_status )
23767 { $as_echo "$as_me:$LINENO: result: failed" >&5
23768 $as_echo "failed" >&6; }
23769 { { $as_echo "$as_me:$LINENO: error:
23770 Could not execute a simple test program.  This may be a problem
23771 related to locating shared libraries.  Check the file 'config.log'
23772 for the exact reason." >&5
23773 $as_echo "$as_me: error:
23774 Could not execute a simple test program.  This may be a problem
23775 related to locating shared libraries.  Check the file 'config.log'
23776 for the exact reason." >&2;}
23777    { (exit 1); exit 1; }; }
23778 fi
23779 rm -rf conftest.dSYM
23780 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23781 fi
23782
23783
23784
23785 # --------------------
23786 # Run tests below here
23787 # --------------------
23788
23789 # Force use of our snprintf if system's doesn't do arg control
23790 # See comment above at snprintf test for details.
23791 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
23792   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
23793 $as_echo_n "checking whether printf supports argument control... " >&6; }
23794 if test "${pgac_cv_printf_arg_control+set}" = set; then
23795   $as_echo_n "(cached) " >&6
23796 else
23797   if test "$cross_compiling" = yes; then
23798   pgac_cv_printf_arg_control=cross
23799 else
23800   cat >conftest.$ac_ext <<_ACEOF
23801 /* confdefs.h.  */
23802 _ACEOF
23803 cat confdefs.h >>conftest.$ac_ext
23804 cat >>conftest.$ac_ext <<_ACEOF
23805 /* end confdefs.h.  */
23806 #include <stdio.h>
23807 #include <string.h>
23808
23809 int main()
23810 {
23811   char buf[100];
23812
23813   /* can it swap arguments? */
23814   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
23815   if (strcmp(buf, "4 3") != 0)
23816     return 1;
23817   return 0;
23818 }
23819 _ACEOF
23820 rm -f conftest$ac_exeext
23821 if { (ac_try="$ac_link"
23822 case "(($ac_try" in
23823   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23824   *) ac_try_echo=$ac_try;;
23825 esac
23826 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23827 $as_echo "$ac_try_echo") >&5
23828   (eval "$ac_link") 2>&5
23829   ac_status=$?
23830   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23831   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23832   { (case "(($ac_try" in
23833   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23834   *) ac_try_echo=$ac_try;;
23835 esac
23836 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23837 $as_echo "$ac_try_echo") >&5
23838   (eval "$ac_try") 2>&5
23839   ac_status=$?
23840   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23841   (exit $ac_status); }; }; then
23842   pgac_cv_printf_arg_control=yes
23843 else
23844   $as_echo "$as_me: program exited with status $ac_status" >&5
23845 $as_echo "$as_me: failed program was:" >&5
23846 sed 's/^/| /' conftest.$ac_ext >&5
23847
23848 ( exit $ac_status )
23849 pgac_cv_printf_arg_control=no
23850 fi
23851 rm -rf conftest.dSYM
23852 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23853 fi
23854
23855
23856
23857 fi
23858 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
23859 $as_echo "$pgac_cv_printf_arg_control" >&6; }
23860
23861   if test $pgac_cv_printf_arg_control != yes ; then
23862     pgac_need_repl_snprintf=yes
23863   fi
23864 fi
23865
23866
23867
23868
23869 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
23870 $as_echo_n "checking whether long int is 64 bits... " >&6; }
23871 if test "${pgac_cv_type_long_int_64+set}" = set; then
23872   $as_echo_n "(cached) " >&6
23873 else
23874   if test "$cross_compiling" = yes; then
23875   # If cross-compiling, check the size reported by the compiler and
23876 # trust that the arithmetic works.
23877 cat >conftest.$ac_ext <<_ACEOF
23878 /* confdefs.h.  */
23879 _ACEOF
23880 cat confdefs.h >>conftest.$ac_ext
23881 cat >>conftest.$ac_ext <<_ACEOF
23882 /* end confdefs.h.  */
23883
23884 int
23885 main ()
23886 {
23887 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
23888 test_array [0] = 0
23889
23890   ;
23891   return 0;
23892 }
23893 _ACEOF
23894 rm -f conftest.$ac_objext
23895 if { (ac_try="$ac_compile"
23896 case "(($ac_try" in
23897   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23898   *) ac_try_echo=$ac_try;;
23899 esac
23900 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23901 $as_echo "$ac_try_echo") >&5
23902   (eval "$ac_compile") 2>conftest.er1
23903   ac_status=$?
23904   grep -v '^ *+' conftest.er1 >conftest.err
23905   rm -f conftest.er1
23906   cat conftest.err >&5
23907   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23908   (exit $ac_status); } && {
23909          test -z "$ac_c_werror_flag" ||
23910          test ! -s conftest.err
23911        } && test -s conftest.$ac_objext; then
23912   pgac_cv_type_long_int_64=yes
23913 else
23914   $as_echo "$as_me: failed program was:" >&5
23915 sed 's/^/| /' conftest.$ac_ext >&5
23916
23917         pgac_cv_type_long_int_64=no
23918 fi
23919
23920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23921 else
23922   cat >conftest.$ac_ext <<_ACEOF
23923 /* confdefs.h.  */
23924 _ACEOF
23925 cat confdefs.h >>conftest.$ac_ext
23926 cat >>conftest.$ac_ext <<_ACEOF
23927 /* end confdefs.h.  */
23928 typedef long int ac_int64;
23929
23930 /*
23931  * These are globals to discourage the compiler from folding all the
23932  * arithmetic tests down to compile-time constants.
23933  */
23934 ac_int64 a = 20000001;
23935 ac_int64 b = 40000005;
23936
23937 int does_int64_work()
23938 {
23939   ac_int64 c,d;
23940
23941   if (sizeof(ac_int64) != 8)
23942     return 0;                   /* definitely not the right size */
23943
23944   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23945   c = a * b;
23946   d = (c + b) / b;
23947   if (d != a+1)
23948     return 0;
23949   return 1;
23950 }
23951 main() {
23952   exit(! does_int64_work());
23953 }
23954 _ACEOF
23955 rm -f conftest$ac_exeext
23956 if { (ac_try="$ac_link"
23957 case "(($ac_try" in
23958   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23959   *) ac_try_echo=$ac_try;;
23960 esac
23961 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23962 $as_echo "$ac_try_echo") >&5
23963   (eval "$ac_link") 2>&5
23964   ac_status=$?
23965   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23966   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23967   { (case "(($ac_try" in
23968   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23969   *) ac_try_echo=$ac_try;;
23970 esac
23971 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23972 $as_echo "$ac_try_echo") >&5
23973   (eval "$ac_try") 2>&5
23974   ac_status=$?
23975   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23976   (exit $ac_status); }; }; then
23977   pgac_cv_type_long_int_64=yes
23978 else
23979   $as_echo "$as_me: program exited with status $ac_status" >&5
23980 $as_echo "$as_me: failed program was:" >&5
23981 sed 's/^/| /' conftest.$ac_ext >&5
23982
23983 ( exit $ac_status )
23984 pgac_cv_type_long_int_64=no
23985 fi
23986 rm -rf conftest.dSYM
23987 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23988 fi
23989
23990
23991 fi
23992 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
23993 $as_echo "$pgac_cv_type_long_int_64" >&6; }
23994
23995 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
23996 if test x"$pgac_cv_type_long_int_64" = xyes ; then
23997
23998 cat >>confdefs.h <<\_ACEOF
23999 #define HAVE_LONG_INT_64 1
24000 _ACEOF
24001
24002 fi
24003
24004
24005 if test x"$HAVE_LONG_INT_64" = x"no" ; then
24006   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
24007 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
24008 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
24009   $as_echo_n "(cached) " >&6
24010 else
24011   if test "$cross_compiling" = yes; then
24012   # If cross-compiling, check the size reported by the compiler and
24013 # trust that the arithmetic works.
24014 cat >conftest.$ac_ext <<_ACEOF
24015 /* confdefs.h.  */
24016 _ACEOF
24017 cat confdefs.h >>conftest.$ac_ext
24018 cat >>conftest.$ac_ext <<_ACEOF
24019 /* end confdefs.h.  */
24020
24021 int
24022 main ()
24023 {
24024 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
24025 test_array [0] = 0
24026
24027   ;
24028   return 0;
24029 }
24030 _ACEOF
24031 rm -f conftest.$ac_objext
24032 if { (ac_try="$ac_compile"
24033 case "(($ac_try" in
24034   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24035   *) ac_try_echo=$ac_try;;
24036 esac
24037 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24038 $as_echo "$ac_try_echo") >&5
24039   (eval "$ac_compile") 2>conftest.er1
24040   ac_status=$?
24041   grep -v '^ *+' conftest.er1 >conftest.err
24042   rm -f conftest.er1
24043   cat conftest.err >&5
24044   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24045   (exit $ac_status); } && {
24046          test -z "$ac_c_werror_flag" ||
24047          test ! -s conftest.err
24048        } && test -s conftest.$ac_objext; then
24049   pgac_cv_type_long_long_int_64=yes
24050 else
24051   $as_echo "$as_me: failed program was:" >&5
24052 sed 's/^/| /' conftest.$ac_ext >&5
24053
24054         pgac_cv_type_long_long_int_64=no
24055 fi
24056
24057 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24058 else
24059   cat >conftest.$ac_ext <<_ACEOF
24060 /* confdefs.h.  */
24061 _ACEOF
24062 cat confdefs.h >>conftest.$ac_ext
24063 cat >>conftest.$ac_ext <<_ACEOF
24064 /* end confdefs.h.  */
24065 typedef long long int ac_int64;
24066
24067 /*
24068  * These are globals to discourage the compiler from folding all the
24069  * arithmetic tests down to compile-time constants.
24070  */
24071 ac_int64 a = 20000001;
24072 ac_int64 b = 40000005;
24073
24074 int does_int64_work()
24075 {
24076   ac_int64 c,d;
24077
24078   if (sizeof(ac_int64) != 8)
24079     return 0;                   /* definitely not the right size */
24080
24081   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
24082   c = a * b;
24083   d = (c + b) / b;
24084   if (d != a+1)
24085     return 0;
24086   return 1;
24087 }
24088 main() {
24089   exit(! does_int64_work());
24090 }
24091 _ACEOF
24092 rm -f conftest$ac_exeext
24093 if { (ac_try="$ac_link"
24094 case "(($ac_try" in
24095   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24096   *) ac_try_echo=$ac_try;;
24097 esac
24098 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24099 $as_echo "$ac_try_echo") >&5
24100   (eval "$ac_link") 2>&5
24101   ac_status=$?
24102   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24103   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24104   { (case "(($ac_try" in
24105   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24106   *) ac_try_echo=$ac_try;;
24107 esac
24108 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24109 $as_echo "$ac_try_echo") >&5
24110   (eval "$ac_try") 2>&5
24111   ac_status=$?
24112   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24113   (exit $ac_status); }; }; then
24114   pgac_cv_type_long_long_int_64=yes
24115 else
24116   $as_echo "$as_me: program exited with status $ac_status" >&5
24117 $as_echo "$as_me: failed program was:" >&5
24118 sed 's/^/| /' conftest.$ac_ext >&5
24119
24120 ( exit $ac_status )
24121 pgac_cv_type_long_long_int_64=no
24122 fi
24123 rm -rf conftest.dSYM
24124 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24125 fi
24126
24127
24128 fi
24129 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
24130 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
24131
24132 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
24133 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
24134
24135 cat >>confdefs.h <<\_ACEOF
24136 #define HAVE_LONG_LONG_INT_64 1
24137 _ACEOF
24138
24139 fi
24140
24141   if test x"$HAVE_LONG_LONG_INT_64" = x"no" ; then
24142     { { $as_echo "$as_me:$LINENO: error: Cannot find a working 64-bit integer type." >&5
24143 $as_echo "$as_me: error: Cannot find a working 64-bit integer type." >&2;}
24144    { (exit 1); exit 1; }; }
24145   fi
24146 fi
24147
24148
24149
24150 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
24151   cat >conftest.$ac_ext <<_ACEOF
24152 /* confdefs.h.  */
24153 _ACEOF
24154 cat confdefs.h >>conftest.$ac_ext
24155 cat >>conftest.$ac_ext <<_ACEOF
24156 /* end confdefs.h.  */
24157
24158 #define INT64CONST(x)  x##LL
24159 long long int foo = INT64CONST(0x1234567890123456);
24160
24161 int
24162 main ()
24163 {
24164
24165   ;
24166   return 0;
24167 }
24168 _ACEOF
24169 rm -f conftest.$ac_objext
24170 if { (ac_try="$ac_compile"
24171 case "(($ac_try" in
24172   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24173   *) ac_try_echo=$ac_try;;
24174 esac
24175 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24176 $as_echo "$ac_try_echo") >&5
24177   (eval "$ac_compile") 2>conftest.er1
24178   ac_status=$?
24179   grep -v '^ *+' conftest.er1 >conftest.err
24180   rm -f conftest.er1
24181   cat conftest.err >&5
24182   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24183   (exit $ac_status); } && {
24184          test -z "$ac_c_werror_flag" ||
24185          test ! -s conftest.err
24186        } && test -s conftest.$ac_objext; then
24187
24188 cat >>confdefs.h <<\_ACEOF
24189 #define HAVE_LL_CONSTANTS 1
24190 _ACEOF
24191
24192 else
24193   $as_echo "$as_me: failed program was:" >&5
24194 sed 's/^/| /' conftest.$ac_ext >&5
24195
24196
24197 fi
24198
24199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24200 fi
24201
24202
24203 # If we found "long int" is 64 bits, assume snprintf handles it.  If
24204 # we found we need to use "long long int", better check.  We cope with
24205 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
24206 # work, fall back to our own snprintf emulation (which we know uses %lld).
24207
24208 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
24209   if test $pgac_need_repl_snprintf = no; then
24210     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
24211 $as_echo_n "checking snprintf format for long long int... " >&6; }
24212 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
24213   $as_echo_n "(cached) " >&6
24214 else
24215   for pgac_format in '%lld' '%qd' '%I64d'; do
24216 if test "$cross_compiling" = yes; then
24217   pgac_cv_snprintf_long_long_int_format=cross; break
24218 else
24219   cat >conftest.$ac_ext <<_ACEOF
24220 /* confdefs.h.  */
24221 _ACEOF
24222 cat confdefs.h >>conftest.$ac_ext
24223 cat >>conftest.$ac_ext <<_ACEOF
24224 /* end confdefs.h.  */
24225 #include <stdio.h>
24226 typedef long long int ac_int64;
24227 #define INT64_FORMAT "$pgac_format"
24228
24229 ac_int64 a = 20000001;
24230 ac_int64 b = 40000005;
24231
24232 int does_int64_snprintf_work()
24233 {
24234   ac_int64 c;
24235   char buf[100];
24236
24237   if (sizeof(ac_int64) != 8)
24238     return 0;                   /* doesn't look like the right size */
24239
24240   c = a * b;
24241   snprintf(buf, 100, INT64_FORMAT, c);
24242   if (strcmp(buf, "800000140000005") != 0)
24243     return 0;                   /* either multiply or snprintf is busted */
24244   return 1;
24245 }
24246 main() {
24247   exit(! does_int64_snprintf_work());
24248 }
24249 _ACEOF
24250 rm -f conftest$ac_exeext
24251 if { (ac_try="$ac_link"
24252 case "(($ac_try" in
24253   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24254   *) ac_try_echo=$ac_try;;
24255 esac
24256 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24257 $as_echo "$ac_try_echo") >&5
24258   (eval "$ac_link") 2>&5
24259   ac_status=$?
24260   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24261   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24262   { (case "(($ac_try" in
24263   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24264   *) ac_try_echo=$ac_try;;
24265 esac
24266 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24267 $as_echo "$ac_try_echo") >&5
24268   (eval "$ac_try") 2>&5
24269   ac_status=$?
24270   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24271   (exit $ac_status); }; }; then
24272   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
24273 else
24274   $as_echo "$as_me: program exited with status $ac_status" >&5
24275 $as_echo "$as_me: failed program was:" >&5
24276 sed 's/^/| /' conftest.$ac_ext >&5
24277
24278 fi
24279 rm -rf conftest.dSYM
24280 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24281 fi
24282
24283
24284 done
24285 fi
24286
24287 LONG_LONG_INT_FORMAT=''
24288
24289 case $pgac_cv_snprintf_long_long_int_format in
24290   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
24291 $as_echo "cannot test (not on host machine)" >&6; };;
24292   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
24293 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
24294          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
24295   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
24296 $as_echo "none" >&6; };;
24297 esac
24298     if test "$LONG_LONG_INT_FORMAT" = ""; then
24299       # Force usage of our own snprintf, since system snprintf is broken
24300       pgac_need_repl_snprintf=yes
24301       LONG_LONG_INT_FORMAT='%lld'
24302     fi
24303   else
24304     # Here if we previously decided we needed to use our own snprintf
24305     LONG_LONG_INT_FORMAT='%lld'
24306   fi
24307   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
24308   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
24309   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
24310 else
24311   # Here if we are not using 'long long int' at all
24312   INT64_FORMAT='"%ld"'
24313   UINT64_FORMAT='"%lu"'
24314 fi
24315
24316
24317 cat >>confdefs.h <<_ACEOF
24318 #define INT64_FORMAT $INT64_FORMAT
24319 _ACEOF
24320
24321
24322
24323 cat >>confdefs.h <<_ACEOF
24324 #define UINT64_FORMAT $UINT64_FORMAT
24325 _ACEOF
24326
24327
24328 # Now we have checked all the reasons to replace snprintf
24329 if test $pgac_need_repl_snprintf = yes; then
24330
24331 cat >>confdefs.h <<\_ACEOF
24332 #define USE_REPL_SNPRINTF 1
24333 _ACEOF
24334
24335   case " $LIBOBJS " in
24336   *" snprintf.$ac_objext "* ) ;;
24337   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
24338  ;;
24339 esac
24340
24341 fi
24342
24343 # Check size of void *, size_t (enables tweaks for > 32bit address space)
24344 # The cast to long int works around a bug in the HP C Compiler
24345 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24346 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24347 # This bug is HP SR number 8606223364.
24348 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
24349 $as_echo_n "checking size of void *... " >&6; }
24350 if test "${ac_cv_sizeof_void_p+set}" = set; then
24351   $as_echo_n "(cached) " >&6
24352 else
24353   if test "$cross_compiling" = yes; then
24354   # Depending upon the size, compute the lo and hi bounds.
24355 cat >conftest.$ac_ext <<_ACEOF
24356 /* confdefs.h.  */
24357 _ACEOF
24358 cat confdefs.h >>conftest.$ac_ext
24359 cat >>conftest.$ac_ext <<_ACEOF
24360 /* end confdefs.h.  */
24361 $ac_includes_default
24362 int
24363 main ()
24364 {
24365 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
24366 test_array [0] = 0
24367
24368   ;
24369   return 0;
24370 }
24371 _ACEOF
24372 rm -f conftest.$ac_objext
24373 if { (ac_try="$ac_compile"
24374 case "(($ac_try" in
24375   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24376   *) ac_try_echo=$ac_try;;
24377 esac
24378 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24379 $as_echo "$ac_try_echo") >&5
24380   (eval "$ac_compile") 2>conftest.er1
24381   ac_status=$?
24382   grep -v '^ *+' conftest.er1 >conftest.err
24383   rm -f conftest.er1
24384   cat conftest.err >&5
24385   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24386   (exit $ac_status); } && {
24387          test -z "$ac_c_werror_flag" ||
24388          test ! -s conftest.err
24389        } && test -s conftest.$ac_objext; then
24390   ac_lo=0 ac_mid=0
24391   while :; do
24392     cat >conftest.$ac_ext <<_ACEOF
24393 /* confdefs.h.  */
24394 _ACEOF
24395 cat confdefs.h >>conftest.$ac_ext
24396 cat >>conftest.$ac_ext <<_ACEOF
24397 /* end confdefs.h.  */
24398 $ac_includes_default
24399 int
24400 main ()
24401 {
24402 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24403 test_array [0] = 0
24404
24405   ;
24406   return 0;
24407 }
24408 _ACEOF
24409 rm -f conftest.$ac_objext
24410 if { (ac_try="$ac_compile"
24411 case "(($ac_try" in
24412   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24413   *) ac_try_echo=$ac_try;;
24414 esac
24415 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24416 $as_echo "$ac_try_echo") >&5
24417   (eval "$ac_compile") 2>conftest.er1
24418   ac_status=$?
24419   grep -v '^ *+' conftest.er1 >conftest.err
24420   rm -f conftest.er1
24421   cat conftest.err >&5
24422   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24423   (exit $ac_status); } && {
24424          test -z "$ac_c_werror_flag" ||
24425          test ! -s conftest.err
24426        } && test -s conftest.$ac_objext; then
24427   ac_hi=$ac_mid; break
24428 else
24429   $as_echo "$as_me: failed program was:" >&5
24430 sed 's/^/| /' conftest.$ac_ext >&5
24431
24432         ac_lo=`expr $ac_mid + 1`
24433                         if test $ac_lo -le $ac_mid; then
24434                           ac_lo= ac_hi=
24435                           break
24436                         fi
24437                         ac_mid=`expr 2 '*' $ac_mid + 1`
24438 fi
24439
24440 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24441   done
24442 else
24443   $as_echo "$as_me: failed program was:" >&5
24444 sed 's/^/| /' conftest.$ac_ext >&5
24445
24446         cat >conftest.$ac_ext <<_ACEOF
24447 /* confdefs.h.  */
24448 _ACEOF
24449 cat confdefs.h >>conftest.$ac_ext
24450 cat >>conftest.$ac_ext <<_ACEOF
24451 /* end confdefs.h.  */
24452 $ac_includes_default
24453 int
24454 main ()
24455 {
24456 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
24457 test_array [0] = 0
24458
24459   ;
24460   return 0;
24461 }
24462 _ACEOF
24463 rm -f conftest.$ac_objext
24464 if { (ac_try="$ac_compile"
24465 case "(($ac_try" in
24466   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24467   *) ac_try_echo=$ac_try;;
24468 esac
24469 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24470 $as_echo "$ac_try_echo") >&5
24471   (eval "$ac_compile") 2>conftest.er1
24472   ac_status=$?
24473   grep -v '^ *+' conftest.er1 >conftest.err
24474   rm -f conftest.er1
24475   cat conftest.err >&5
24476   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24477   (exit $ac_status); } && {
24478          test -z "$ac_c_werror_flag" ||
24479          test ! -s conftest.err
24480        } && test -s conftest.$ac_objext; then
24481   ac_hi=-1 ac_mid=-1
24482   while :; do
24483     cat >conftest.$ac_ext <<_ACEOF
24484 /* confdefs.h.  */
24485 _ACEOF
24486 cat confdefs.h >>conftest.$ac_ext
24487 cat >>conftest.$ac_ext <<_ACEOF
24488 /* end confdefs.h.  */
24489 $ac_includes_default
24490 int
24491 main ()
24492 {
24493 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
24494 test_array [0] = 0
24495
24496   ;
24497   return 0;
24498 }
24499 _ACEOF
24500 rm -f conftest.$ac_objext
24501 if { (ac_try="$ac_compile"
24502 case "(($ac_try" in
24503   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24504   *) ac_try_echo=$ac_try;;
24505 esac
24506 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24507 $as_echo "$ac_try_echo") >&5
24508   (eval "$ac_compile") 2>conftest.er1
24509   ac_status=$?
24510   grep -v '^ *+' conftest.er1 >conftest.err
24511   rm -f conftest.er1
24512   cat conftest.err >&5
24513   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24514   (exit $ac_status); } && {
24515          test -z "$ac_c_werror_flag" ||
24516          test ! -s conftest.err
24517        } && test -s conftest.$ac_objext; then
24518   ac_lo=$ac_mid; break
24519 else
24520   $as_echo "$as_me: failed program was:" >&5
24521 sed 's/^/| /' conftest.$ac_ext >&5
24522
24523         ac_hi=`expr '(' $ac_mid ')' - 1`
24524                         if test $ac_mid -le $ac_hi; then
24525                           ac_lo= ac_hi=
24526                           break
24527                         fi
24528                         ac_mid=`expr 2 '*' $ac_mid`
24529 fi
24530
24531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24532   done
24533 else
24534   $as_echo "$as_me: failed program was:" >&5
24535 sed 's/^/| /' conftest.$ac_ext >&5
24536
24537         ac_lo= ac_hi=
24538 fi
24539
24540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24541 fi
24542
24543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24544 # Binary search between lo and hi bounds.
24545 while test "x$ac_lo" != "x$ac_hi"; do
24546   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24547   cat >conftest.$ac_ext <<_ACEOF
24548 /* confdefs.h.  */
24549 _ACEOF
24550 cat confdefs.h >>conftest.$ac_ext
24551 cat >>conftest.$ac_ext <<_ACEOF
24552 /* end confdefs.h.  */
24553 $ac_includes_default
24554 int
24555 main ()
24556 {
24557 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24558 test_array [0] = 0
24559
24560   ;
24561   return 0;
24562 }
24563 _ACEOF
24564 rm -f conftest.$ac_objext
24565 if { (ac_try="$ac_compile"
24566 case "(($ac_try" in
24567   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24568   *) ac_try_echo=$ac_try;;
24569 esac
24570 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24571 $as_echo "$ac_try_echo") >&5
24572   (eval "$ac_compile") 2>conftest.er1
24573   ac_status=$?
24574   grep -v '^ *+' conftest.er1 >conftest.err
24575   rm -f conftest.er1
24576   cat conftest.err >&5
24577   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24578   (exit $ac_status); } && {
24579          test -z "$ac_c_werror_flag" ||
24580          test ! -s conftest.err
24581        } && test -s conftest.$ac_objext; then
24582   ac_hi=$ac_mid
24583 else
24584   $as_echo "$as_me: failed program was:" >&5
24585 sed 's/^/| /' conftest.$ac_ext >&5
24586
24587         ac_lo=`expr '(' $ac_mid ')' + 1`
24588 fi
24589
24590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24591 done
24592 case $ac_lo in
24593 ?*) ac_cv_sizeof_void_p=$ac_lo;;
24594 '') if test "$ac_cv_type_void_p" = yes; then
24595      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24596 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24597 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24598 See \`config.log' for more details." >&5
24599 $as_echo "$as_me: error: cannot compute sizeof (void *)
24600 See \`config.log' for more details." >&2;}
24601    { (exit 77); exit 77; }; }; }
24602    else
24603      ac_cv_sizeof_void_p=0
24604    fi ;;
24605 esac
24606 else
24607   cat >conftest.$ac_ext <<_ACEOF
24608 /* confdefs.h.  */
24609 _ACEOF
24610 cat confdefs.h >>conftest.$ac_ext
24611 cat >>conftest.$ac_ext <<_ACEOF
24612 /* end confdefs.h.  */
24613 $ac_includes_default
24614 static long int longval () { return (long int) (sizeof (void *)); }
24615 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
24616 #include <stdio.h>
24617 #include <stdlib.h>
24618 int
24619 main ()
24620 {
24621
24622   FILE *f = fopen ("conftest.val", "w");
24623   if (! f)
24624     return 1;
24625   if (((long int) (sizeof (void *))) < 0)
24626     {
24627       long int i = longval ();
24628       if (i != ((long int) (sizeof (void *))))
24629         return 1;
24630       fprintf (f, "%ld", i);
24631     }
24632   else
24633     {
24634       unsigned long int i = ulongval ();
24635       if (i != ((long int) (sizeof (void *))))
24636         return 1;
24637       fprintf (f, "%lu", i);
24638     }
24639   /* Do not output a trailing newline, as this causes \r\n confusion
24640      on some platforms.  */
24641   return ferror (f) || fclose (f) != 0;
24642
24643   ;
24644   return 0;
24645 }
24646 _ACEOF
24647 rm -f conftest$ac_exeext
24648 if { (ac_try="$ac_link"
24649 case "(($ac_try" in
24650   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24651   *) ac_try_echo=$ac_try;;
24652 esac
24653 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24654 $as_echo "$ac_try_echo") >&5
24655   (eval "$ac_link") 2>&5
24656   ac_status=$?
24657   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24658   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24659   { (case "(($ac_try" in
24660   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24661   *) ac_try_echo=$ac_try;;
24662 esac
24663 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24664 $as_echo "$ac_try_echo") >&5
24665   (eval "$ac_try") 2>&5
24666   ac_status=$?
24667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24668   (exit $ac_status); }; }; then
24669   ac_cv_sizeof_void_p=`cat conftest.val`
24670 else
24671   $as_echo "$as_me: program exited with status $ac_status" >&5
24672 $as_echo "$as_me: failed program was:" >&5
24673 sed 's/^/| /' conftest.$ac_ext >&5
24674
24675 ( exit $ac_status )
24676 if test "$ac_cv_type_void_p" = yes; then
24677      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24678 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24679 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24680 See \`config.log' for more details." >&5
24681 $as_echo "$as_me: error: cannot compute sizeof (void *)
24682 See \`config.log' for more details." >&2;}
24683    { (exit 77); exit 77; }; }; }
24684    else
24685      ac_cv_sizeof_void_p=0
24686    fi
24687 fi
24688 rm -rf conftest.dSYM
24689 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24690 fi
24691 rm -f conftest.val
24692 fi
24693 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
24694 $as_echo "$ac_cv_sizeof_void_p" >&6; }
24695
24696
24697
24698 cat >>confdefs.h <<_ACEOF
24699 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
24700 _ACEOF
24701
24702
24703 # The cast to long int works around a bug in the HP C Compiler
24704 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24705 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24706 # This bug is HP SR number 8606223364.
24707 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
24708 $as_echo_n "checking size of size_t... " >&6; }
24709 if test "${ac_cv_sizeof_size_t+set}" = set; then
24710   $as_echo_n "(cached) " >&6
24711 else
24712   if test "$cross_compiling" = yes; then
24713   # Depending upon the size, compute the lo and hi bounds.
24714 cat >conftest.$ac_ext <<_ACEOF
24715 /* confdefs.h.  */
24716 _ACEOF
24717 cat confdefs.h >>conftest.$ac_ext
24718 cat >>conftest.$ac_ext <<_ACEOF
24719 /* end confdefs.h.  */
24720 $ac_includes_default
24721 int
24722 main ()
24723 {
24724 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
24725 test_array [0] = 0
24726
24727   ;
24728   return 0;
24729 }
24730 _ACEOF
24731 rm -f conftest.$ac_objext
24732 if { (ac_try="$ac_compile"
24733 case "(($ac_try" in
24734   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24735   *) ac_try_echo=$ac_try;;
24736 esac
24737 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24738 $as_echo "$ac_try_echo") >&5
24739   (eval "$ac_compile") 2>conftest.er1
24740   ac_status=$?
24741   grep -v '^ *+' conftest.er1 >conftest.err
24742   rm -f conftest.er1
24743   cat conftest.err >&5
24744   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24745   (exit $ac_status); } && {
24746          test -z "$ac_c_werror_flag" ||
24747          test ! -s conftest.err
24748        } && test -s conftest.$ac_objext; then
24749   ac_lo=0 ac_mid=0
24750   while :; do
24751     cat >conftest.$ac_ext <<_ACEOF
24752 /* confdefs.h.  */
24753 _ACEOF
24754 cat confdefs.h >>conftest.$ac_ext
24755 cat >>conftest.$ac_ext <<_ACEOF
24756 /* end confdefs.h.  */
24757 $ac_includes_default
24758 int
24759 main ()
24760 {
24761 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24762 test_array [0] = 0
24763
24764   ;
24765   return 0;
24766 }
24767 _ACEOF
24768 rm -f conftest.$ac_objext
24769 if { (ac_try="$ac_compile"
24770 case "(($ac_try" in
24771   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24772   *) ac_try_echo=$ac_try;;
24773 esac
24774 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24775 $as_echo "$ac_try_echo") >&5
24776   (eval "$ac_compile") 2>conftest.er1
24777   ac_status=$?
24778   grep -v '^ *+' conftest.er1 >conftest.err
24779   rm -f conftest.er1
24780   cat conftest.err >&5
24781   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24782   (exit $ac_status); } && {
24783          test -z "$ac_c_werror_flag" ||
24784          test ! -s conftest.err
24785        } && test -s conftest.$ac_objext; then
24786   ac_hi=$ac_mid; break
24787 else
24788   $as_echo "$as_me: failed program was:" >&5
24789 sed 's/^/| /' conftest.$ac_ext >&5
24790
24791         ac_lo=`expr $ac_mid + 1`
24792                         if test $ac_lo -le $ac_mid; then
24793                           ac_lo= ac_hi=
24794                           break
24795                         fi
24796                         ac_mid=`expr 2 '*' $ac_mid + 1`
24797 fi
24798
24799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24800   done
24801 else
24802   $as_echo "$as_me: failed program was:" >&5
24803 sed 's/^/| /' conftest.$ac_ext >&5
24804
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 $ac_includes_default
24812 int
24813 main ()
24814 {
24815 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
24816 test_array [0] = 0
24817
24818   ;
24819   return 0;
24820 }
24821 _ACEOF
24822 rm -f conftest.$ac_objext
24823 if { (ac_try="$ac_compile"
24824 case "(($ac_try" in
24825   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24826   *) ac_try_echo=$ac_try;;
24827 esac
24828 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24829 $as_echo "$ac_try_echo") >&5
24830   (eval "$ac_compile") 2>conftest.er1
24831   ac_status=$?
24832   grep -v '^ *+' conftest.er1 >conftest.err
24833   rm -f conftest.er1
24834   cat conftest.err >&5
24835   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24836   (exit $ac_status); } && {
24837          test -z "$ac_c_werror_flag" ||
24838          test ! -s conftest.err
24839        } && test -s conftest.$ac_objext; then
24840   ac_hi=-1 ac_mid=-1
24841   while :; do
24842     cat >conftest.$ac_ext <<_ACEOF
24843 /* confdefs.h.  */
24844 _ACEOF
24845 cat confdefs.h >>conftest.$ac_ext
24846 cat >>conftest.$ac_ext <<_ACEOF
24847 /* end confdefs.h.  */
24848 $ac_includes_default
24849 int
24850 main ()
24851 {
24852 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
24853 test_array [0] = 0
24854
24855   ;
24856   return 0;
24857 }
24858 _ACEOF
24859 rm -f conftest.$ac_objext
24860 if { (ac_try="$ac_compile"
24861 case "(($ac_try" in
24862   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24863   *) ac_try_echo=$ac_try;;
24864 esac
24865 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24866 $as_echo "$ac_try_echo") >&5
24867   (eval "$ac_compile") 2>conftest.er1
24868   ac_status=$?
24869   grep -v '^ *+' conftest.er1 >conftest.err
24870   rm -f conftest.er1
24871   cat conftest.err >&5
24872   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24873   (exit $ac_status); } && {
24874          test -z "$ac_c_werror_flag" ||
24875          test ! -s conftest.err
24876        } && test -s conftest.$ac_objext; then
24877   ac_lo=$ac_mid; break
24878 else
24879   $as_echo "$as_me: failed program was:" >&5
24880 sed 's/^/| /' conftest.$ac_ext >&5
24881
24882         ac_hi=`expr '(' $ac_mid ')' - 1`
24883                         if test $ac_mid -le $ac_hi; then
24884                           ac_lo= ac_hi=
24885                           break
24886                         fi
24887                         ac_mid=`expr 2 '*' $ac_mid`
24888 fi
24889
24890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24891   done
24892 else
24893   $as_echo "$as_me: failed program was:" >&5
24894 sed 's/^/| /' conftest.$ac_ext >&5
24895
24896         ac_lo= ac_hi=
24897 fi
24898
24899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24900 fi
24901
24902 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24903 # Binary search between lo and hi bounds.
24904 while test "x$ac_lo" != "x$ac_hi"; do
24905   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24906   cat >conftest.$ac_ext <<_ACEOF
24907 /* confdefs.h.  */
24908 _ACEOF
24909 cat confdefs.h >>conftest.$ac_ext
24910 cat >>conftest.$ac_ext <<_ACEOF
24911 /* end confdefs.h.  */
24912 $ac_includes_default
24913 int
24914 main ()
24915 {
24916 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24917 test_array [0] = 0
24918
24919   ;
24920   return 0;
24921 }
24922 _ACEOF
24923 rm -f conftest.$ac_objext
24924 if { (ac_try="$ac_compile"
24925 case "(($ac_try" in
24926   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24927   *) ac_try_echo=$ac_try;;
24928 esac
24929 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24930 $as_echo "$ac_try_echo") >&5
24931   (eval "$ac_compile") 2>conftest.er1
24932   ac_status=$?
24933   grep -v '^ *+' conftest.er1 >conftest.err
24934   rm -f conftest.er1
24935   cat conftest.err >&5
24936   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24937   (exit $ac_status); } && {
24938          test -z "$ac_c_werror_flag" ||
24939          test ! -s conftest.err
24940        } && test -s conftest.$ac_objext; then
24941   ac_hi=$ac_mid
24942 else
24943   $as_echo "$as_me: failed program was:" >&5
24944 sed 's/^/| /' conftest.$ac_ext >&5
24945
24946         ac_lo=`expr '(' $ac_mid ')' + 1`
24947 fi
24948
24949 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24950 done
24951 case $ac_lo in
24952 ?*) ac_cv_sizeof_size_t=$ac_lo;;
24953 '') if test "$ac_cv_type_size_t" = yes; then
24954      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24955 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24956 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24957 See \`config.log' for more details." >&5
24958 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24959 See \`config.log' for more details." >&2;}
24960    { (exit 77); exit 77; }; }; }
24961    else
24962      ac_cv_sizeof_size_t=0
24963    fi ;;
24964 esac
24965 else
24966   cat >conftest.$ac_ext <<_ACEOF
24967 /* confdefs.h.  */
24968 _ACEOF
24969 cat confdefs.h >>conftest.$ac_ext
24970 cat >>conftest.$ac_ext <<_ACEOF
24971 /* end confdefs.h.  */
24972 $ac_includes_default
24973 static long int longval () { return (long int) (sizeof (size_t)); }
24974 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
24975 #include <stdio.h>
24976 #include <stdlib.h>
24977 int
24978 main ()
24979 {
24980
24981   FILE *f = fopen ("conftest.val", "w");
24982   if (! f)
24983     return 1;
24984   if (((long int) (sizeof (size_t))) < 0)
24985     {
24986       long int i = longval ();
24987       if (i != ((long int) (sizeof (size_t))))
24988         return 1;
24989       fprintf (f, "%ld", i);
24990     }
24991   else
24992     {
24993       unsigned long int i = ulongval ();
24994       if (i != ((long int) (sizeof (size_t))))
24995         return 1;
24996       fprintf (f, "%lu", i);
24997     }
24998   /* Do not output a trailing newline, as this causes \r\n confusion
24999      on some platforms.  */
25000   return ferror (f) || fclose (f) != 0;
25001
25002   ;
25003   return 0;
25004 }
25005 _ACEOF
25006 rm -f conftest$ac_exeext
25007 if { (ac_try="$ac_link"
25008 case "(($ac_try" in
25009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25010   *) ac_try_echo=$ac_try;;
25011 esac
25012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25013 $as_echo "$ac_try_echo") >&5
25014   (eval "$ac_link") 2>&5
25015   ac_status=$?
25016   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25017   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25018   { (case "(($ac_try" in
25019   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25020   *) ac_try_echo=$ac_try;;
25021 esac
25022 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25023 $as_echo "$ac_try_echo") >&5
25024   (eval "$ac_try") 2>&5
25025   ac_status=$?
25026   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25027   (exit $ac_status); }; }; then
25028   ac_cv_sizeof_size_t=`cat conftest.val`
25029 else
25030   $as_echo "$as_me: program exited with status $ac_status" >&5
25031 $as_echo "$as_me: failed program was:" >&5
25032 sed 's/^/| /' conftest.$ac_ext >&5
25033
25034 ( exit $ac_status )
25035 if test "$ac_cv_type_size_t" = yes; then
25036      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25037 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25038 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
25039 See \`config.log' for more details." >&5
25040 $as_echo "$as_me: error: cannot compute sizeof (size_t)
25041 See \`config.log' for more details." >&2;}
25042    { (exit 77); exit 77; }; }; }
25043    else
25044      ac_cv_sizeof_size_t=0
25045    fi
25046 fi
25047 rm -rf conftest.dSYM
25048 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25049 fi
25050 rm -f conftest.val
25051 fi
25052 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
25053 $as_echo "$ac_cv_sizeof_size_t" >&6; }
25054
25055
25056
25057 cat >>confdefs.h <<_ACEOF
25058 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
25059 _ACEOF
25060
25061
25062 # The cast to long int works around a bug in the HP C Compiler
25063 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
25064 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
25065 # This bug is HP SR number 8606223364.
25066 { $as_echo "$as_me:$LINENO: checking size of long" >&5
25067 $as_echo_n "checking size of long... " >&6; }
25068 if test "${ac_cv_sizeof_long+set}" = set; then
25069   $as_echo_n "(cached) " >&6
25070 else
25071   if test "$cross_compiling" = yes; then
25072   # Depending upon the size, compute the lo and hi bounds.
25073 cat >conftest.$ac_ext <<_ACEOF
25074 /* confdefs.h.  */
25075 _ACEOF
25076 cat confdefs.h >>conftest.$ac_ext
25077 cat >>conftest.$ac_ext <<_ACEOF
25078 /* end confdefs.h.  */
25079 $ac_includes_default
25080 int
25081 main ()
25082 {
25083 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
25084 test_array [0] = 0
25085
25086   ;
25087   return 0;
25088 }
25089 _ACEOF
25090 rm -f conftest.$ac_objext
25091 if { (ac_try="$ac_compile"
25092 case "(($ac_try" in
25093   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25094   *) ac_try_echo=$ac_try;;
25095 esac
25096 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25097 $as_echo "$ac_try_echo") >&5
25098   (eval "$ac_compile") 2>conftest.er1
25099   ac_status=$?
25100   grep -v '^ *+' conftest.er1 >conftest.err
25101   rm -f conftest.er1
25102   cat conftest.err >&5
25103   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25104   (exit $ac_status); } && {
25105          test -z "$ac_c_werror_flag" ||
25106          test ! -s conftest.err
25107        } && test -s conftest.$ac_objext; then
25108   ac_lo=0 ac_mid=0
25109   while :; do
25110     cat >conftest.$ac_ext <<_ACEOF
25111 /* confdefs.h.  */
25112 _ACEOF
25113 cat confdefs.h >>conftest.$ac_ext
25114 cat >>conftest.$ac_ext <<_ACEOF
25115 /* end confdefs.h.  */
25116 $ac_includes_default
25117 int
25118 main ()
25119 {
25120 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25121 test_array [0] = 0
25122
25123   ;
25124   return 0;
25125 }
25126 _ACEOF
25127 rm -f conftest.$ac_objext
25128 if { (ac_try="$ac_compile"
25129 case "(($ac_try" in
25130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25131   *) ac_try_echo=$ac_try;;
25132 esac
25133 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25134 $as_echo "$ac_try_echo") >&5
25135   (eval "$ac_compile") 2>conftest.er1
25136   ac_status=$?
25137   grep -v '^ *+' conftest.er1 >conftest.err
25138   rm -f conftest.er1
25139   cat conftest.err >&5
25140   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25141   (exit $ac_status); } && {
25142          test -z "$ac_c_werror_flag" ||
25143          test ! -s conftest.err
25144        } && test -s conftest.$ac_objext; then
25145   ac_hi=$ac_mid; break
25146 else
25147   $as_echo "$as_me: failed program was:" >&5
25148 sed 's/^/| /' conftest.$ac_ext >&5
25149
25150         ac_lo=`expr $ac_mid + 1`
25151                         if test $ac_lo -le $ac_mid; then
25152                           ac_lo= ac_hi=
25153                           break
25154                         fi
25155                         ac_mid=`expr 2 '*' $ac_mid + 1`
25156 fi
25157
25158 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25159   done
25160 else
25161   $as_echo "$as_me: failed program was:" >&5
25162 sed 's/^/| /' conftest.$ac_ext >&5
25163
25164         cat >conftest.$ac_ext <<_ACEOF
25165 /* confdefs.h.  */
25166 _ACEOF
25167 cat confdefs.h >>conftest.$ac_ext
25168 cat >>conftest.$ac_ext <<_ACEOF
25169 /* end confdefs.h.  */
25170 $ac_includes_default
25171 int
25172 main ()
25173 {
25174 static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
25175 test_array [0] = 0
25176
25177   ;
25178   return 0;
25179 }
25180 _ACEOF
25181 rm -f conftest.$ac_objext
25182 if { (ac_try="$ac_compile"
25183 case "(($ac_try" in
25184   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25185   *) ac_try_echo=$ac_try;;
25186 esac
25187 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25188 $as_echo "$ac_try_echo") >&5
25189   (eval "$ac_compile") 2>conftest.er1
25190   ac_status=$?
25191   grep -v '^ *+' conftest.er1 >conftest.err
25192   rm -f conftest.er1
25193   cat conftest.err >&5
25194   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25195   (exit $ac_status); } && {
25196          test -z "$ac_c_werror_flag" ||
25197          test ! -s conftest.err
25198        } && test -s conftest.$ac_objext; then
25199   ac_hi=-1 ac_mid=-1
25200   while :; do
25201     cat >conftest.$ac_ext <<_ACEOF
25202 /* confdefs.h.  */
25203 _ACEOF
25204 cat confdefs.h >>conftest.$ac_ext
25205 cat >>conftest.$ac_ext <<_ACEOF
25206 /* end confdefs.h.  */
25207 $ac_includes_default
25208 int
25209 main ()
25210 {
25211 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
25212 test_array [0] = 0
25213
25214   ;
25215   return 0;
25216 }
25217 _ACEOF
25218 rm -f conftest.$ac_objext
25219 if { (ac_try="$ac_compile"
25220 case "(($ac_try" in
25221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25222   *) ac_try_echo=$ac_try;;
25223 esac
25224 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25225 $as_echo "$ac_try_echo") >&5
25226   (eval "$ac_compile") 2>conftest.er1
25227   ac_status=$?
25228   grep -v '^ *+' conftest.er1 >conftest.err
25229   rm -f conftest.er1
25230   cat conftest.err >&5
25231   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25232   (exit $ac_status); } && {
25233          test -z "$ac_c_werror_flag" ||
25234          test ! -s conftest.err
25235        } && test -s conftest.$ac_objext; then
25236   ac_lo=$ac_mid; break
25237 else
25238   $as_echo "$as_me: failed program was:" >&5
25239 sed 's/^/| /' conftest.$ac_ext >&5
25240
25241         ac_hi=`expr '(' $ac_mid ')' - 1`
25242                         if test $ac_mid -le $ac_hi; then
25243                           ac_lo= ac_hi=
25244                           break
25245                         fi
25246                         ac_mid=`expr 2 '*' $ac_mid`
25247 fi
25248
25249 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25250   done
25251 else
25252   $as_echo "$as_me: failed program was:" >&5
25253 sed 's/^/| /' conftest.$ac_ext >&5
25254
25255         ac_lo= ac_hi=
25256 fi
25257
25258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25259 fi
25260
25261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25262 # Binary search between lo and hi bounds.
25263 while test "x$ac_lo" != "x$ac_hi"; do
25264   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25265   cat >conftest.$ac_ext <<_ACEOF
25266 /* confdefs.h.  */
25267 _ACEOF
25268 cat confdefs.h >>conftest.$ac_ext
25269 cat >>conftest.$ac_ext <<_ACEOF
25270 /* end confdefs.h.  */
25271 $ac_includes_default
25272 int
25273 main ()
25274 {
25275 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25276 test_array [0] = 0
25277
25278   ;
25279   return 0;
25280 }
25281 _ACEOF
25282 rm -f conftest.$ac_objext
25283 if { (ac_try="$ac_compile"
25284 case "(($ac_try" in
25285   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25286   *) ac_try_echo=$ac_try;;
25287 esac
25288 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25289 $as_echo "$ac_try_echo") >&5
25290   (eval "$ac_compile") 2>conftest.er1
25291   ac_status=$?
25292   grep -v '^ *+' conftest.er1 >conftest.err
25293   rm -f conftest.er1
25294   cat conftest.err >&5
25295   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25296   (exit $ac_status); } && {
25297          test -z "$ac_c_werror_flag" ||
25298          test ! -s conftest.err
25299        } && test -s conftest.$ac_objext; then
25300   ac_hi=$ac_mid
25301 else
25302   $as_echo "$as_me: failed program was:" >&5
25303 sed 's/^/| /' conftest.$ac_ext >&5
25304
25305         ac_lo=`expr '(' $ac_mid ')' + 1`
25306 fi
25307
25308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25309 done
25310 case $ac_lo in
25311 ?*) ac_cv_sizeof_long=$ac_lo;;
25312 '') if test "$ac_cv_type_long" = yes; then
25313      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25314 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25315 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25316 See \`config.log' for more details." >&5
25317 $as_echo "$as_me: error: cannot compute sizeof (long)
25318 See \`config.log' for more details." >&2;}
25319    { (exit 77); exit 77; }; }; }
25320    else
25321      ac_cv_sizeof_long=0
25322    fi ;;
25323 esac
25324 else
25325   cat >conftest.$ac_ext <<_ACEOF
25326 /* confdefs.h.  */
25327 _ACEOF
25328 cat confdefs.h >>conftest.$ac_ext
25329 cat >>conftest.$ac_ext <<_ACEOF
25330 /* end confdefs.h.  */
25331 $ac_includes_default
25332 static long int longval () { return (long int) (sizeof (long)); }
25333 static unsigned long int ulongval () { return (long int) (sizeof (long)); }
25334 #include <stdio.h>
25335 #include <stdlib.h>
25336 int
25337 main ()
25338 {
25339
25340   FILE *f = fopen ("conftest.val", "w");
25341   if (! f)
25342     return 1;
25343   if (((long int) (sizeof (long))) < 0)
25344     {
25345       long int i = longval ();
25346       if (i != ((long int) (sizeof (long))))
25347         return 1;
25348       fprintf (f, "%ld", i);
25349     }
25350   else
25351     {
25352       unsigned long int i = ulongval ();
25353       if (i != ((long int) (sizeof (long))))
25354         return 1;
25355       fprintf (f, "%lu", i);
25356     }
25357   /* Do not output a trailing newline, as this causes \r\n confusion
25358      on some platforms.  */
25359   return ferror (f) || fclose (f) != 0;
25360
25361   ;
25362   return 0;
25363 }
25364 _ACEOF
25365 rm -f conftest$ac_exeext
25366 if { (ac_try="$ac_link"
25367 case "(($ac_try" in
25368   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25369   *) ac_try_echo=$ac_try;;
25370 esac
25371 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25372 $as_echo "$ac_try_echo") >&5
25373   (eval "$ac_link") 2>&5
25374   ac_status=$?
25375   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25376   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25377   { (case "(($ac_try" in
25378   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25379   *) ac_try_echo=$ac_try;;
25380 esac
25381 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25382 $as_echo "$ac_try_echo") >&5
25383   (eval "$ac_try") 2>&5
25384   ac_status=$?
25385   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25386   (exit $ac_status); }; }; then
25387   ac_cv_sizeof_long=`cat conftest.val`
25388 else
25389   $as_echo "$as_me: program exited with status $ac_status" >&5
25390 $as_echo "$as_me: failed program was:" >&5
25391 sed 's/^/| /' conftest.$ac_ext >&5
25392
25393 ( exit $ac_status )
25394 if test "$ac_cv_type_long" = yes; then
25395      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25396 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25397 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25398 See \`config.log' for more details." >&5
25399 $as_echo "$as_me: error: cannot compute sizeof (long)
25400 See \`config.log' for more details." >&2;}
25401    { (exit 77); exit 77; }; }; }
25402    else
25403      ac_cv_sizeof_long=0
25404    fi
25405 fi
25406 rm -rf conftest.dSYM
25407 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25408 fi
25409 rm -f conftest.val
25410 fi
25411 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
25412 $as_echo "$ac_cv_sizeof_long" >&6; }
25413
25414
25415
25416 cat >>confdefs.h <<_ACEOF
25417 #define SIZEOF_LONG $ac_cv_sizeof_long
25418 _ACEOF
25419
25420
25421
25422 # Decide whether float4 is passed by value: user-selectable, enabled by default
25423 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
25424 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
25425
25426
25427 # Check whether --enable-float4-byval was given.
25428 if test "${enable_float4_byval+set}" = set; then
25429   enableval=$enable_float4_byval;
25430   case $enableval in
25431     yes)
25432
25433 cat >>confdefs.h <<\_ACEOF
25434 #define USE_FLOAT4_BYVAL 1
25435 _ACEOF
25436
25437                float4passbyval=true
25438       ;;
25439     no)
25440       float4passbyval=false
25441       ;;
25442     *)
25443       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
25444 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
25445    { (exit 1); exit 1; }; }
25446       ;;
25447   esac
25448
25449 else
25450   enable_float4_byval=yes
25451
25452 cat >>confdefs.h <<\_ACEOF
25453 #define USE_FLOAT4_BYVAL 1
25454 _ACEOF
25455
25456                float4passbyval=true
25457 fi
25458
25459
25460 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
25461 $as_echo "$enable_float4_byval" >&6; }
25462
25463 cat >>confdefs.h <<_ACEOF
25464 #define FLOAT4PASSBYVAL $float4passbyval
25465 _ACEOF
25466
25467
25468 # Decide whether float8 is passed by value.
25469 # Note: this setting also controls int8 and related types such as timestamp.
25470 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
25471 # If not, trying to select it is an error.
25472 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
25473 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
25474 if test $ac_cv_sizeof_void_p -ge 8 ; then
25475
25476
25477 # Check whether --enable-float8-byval was given.
25478 if test "${enable_float8_byval+set}" = set; then
25479   enableval=$enable_float8_byval;
25480   case $enableval in
25481     yes)
25482       :
25483       ;;
25484     no)
25485       :
25486       ;;
25487     *)
25488       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25489 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25490    { (exit 1); exit 1; }; }
25491       ;;
25492   esac
25493
25494 else
25495   enable_float8_byval=yes
25496
25497 fi
25498
25499
25500 else
25501
25502
25503 # Check whether --enable-float8-byval was given.
25504 if test "${enable_float8_byval+set}" = set; then
25505   enableval=$enable_float8_byval;
25506   case $enableval in
25507     yes)
25508       :
25509       ;;
25510     no)
25511       :
25512       ;;
25513     *)
25514       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25515 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25516    { (exit 1); exit 1; }; }
25517       ;;
25518   esac
25519
25520 else
25521   enable_float8_byval=no
25522
25523 fi
25524
25525
25526   if test "$enable_float8_byval" = yes ; then
25527     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
25528 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
25529    { (exit 1); exit 1; }; }
25530   fi
25531 fi
25532 if test "$enable_float8_byval" = yes ; then
25533
25534 cat >>confdefs.h <<\_ACEOF
25535 #define USE_FLOAT8_BYVAL 1
25536 _ACEOF
25537
25538   float8passbyval=true
25539 else
25540   float8passbyval=false
25541 fi
25542 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
25543 $as_echo "$enable_float8_byval" >&6; }
25544
25545 cat >>confdefs.h <<_ACEOF
25546 #define FLOAT8PASSBYVAL $float8passbyval
25547 _ACEOF
25548
25549
25550 # Determine memory alignment requirements for the basic C data types.
25551
25552 # The cast to long int works around a bug in the HP C Compiler,
25553 # see AC_CHECK_SIZEOF for more information.
25554 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
25555 $as_echo_n "checking alignment of short... " >&6; }
25556 if test "${ac_cv_alignof_short+set}" = set; then
25557   $as_echo_n "(cached) " >&6
25558 else
25559   if test "$cross_compiling" = yes; then
25560   # Depending upon the size, compute the lo and hi bounds.
25561 cat >conftest.$ac_ext <<_ACEOF
25562 /* confdefs.h.  */
25563 _ACEOF
25564 cat confdefs.h >>conftest.$ac_ext
25565 cat >>conftest.$ac_ext <<_ACEOF
25566 /* end confdefs.h.  */
25567 $ac_includes_default
25568 #ifndef offsetof
25569 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25570 #endif
25571 typedef struct { char x; short y; } ac__type_alignof_;
25572 int
25573 main ()
25574 {
25575 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25576 test_array [0] = 0
25577
25578   ;
25579   return 0;
25580 }
25581 _ACEOF
25582 rm -f conftest.$ac_objext
25583 if { (ac_try="$ac_compile"
25584 case "(($ac_try" in
25585   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25586   *) ac_try_echo=$ac_try;;
25587 esac
25588 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25589 $as_echo "$ac_try_echo") >&5
25590   (eval "$ac_compile") 2>conftest.er1
25591   ac_status=$?
25592   grep -v '^ *+' conftest.er1 >conftest.err
25593   rm -f conftest.er1
25594   cat conftest.err >&5
25595   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25596   (exit $ac_status); } && {
25597          test -z "$ac_c_werror_flag" ||
25598          test ! -s conftest.err
25599        } && test -s conftest.$ac_objext; then
25600   ac_lo=0 ac_mid=0
25601   while :; do
25602     cat >conftest.$ac_ext <<_ACEOF
25603 /* confdefs.h.  */
25604 _ACEOF
25605 cat confdefs.h >>conftest.$ac_ext
25606 cat >>conftest.$ac_ext <<_ACEOF
25607 /* end confdefs.h.  */
25608 $ac_includes_default
25609 #ifndef offsetof
25610 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25611 #endif
25612 typedef struct { char x; short y; } ac__type_alignof_;
25613 int
25614 main ()
25615 {
25616 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25617 test_array [0] = 0
25618
25619   ;
25620   return 0;
25621 }
25622 _ACEOF
25623 rm -f conftest.$ac_objext
25624 if { (ac_try="$ac_compile"
25625 case "(($ac_try" in
25626   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25627   *) ac_try_echo=$ac_try;;
25628 esac
25629 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25630 $as_echo "$ac_try_echo") >&5
25631   (eval "$ac_compile") 2>conftest.er1
25632   ac_status=$?
25633   grep -v '^ *+' conftest.er1 >conftest.err
25634   rm -f conftest.er1
25635   cat conftest.err >&5
25636   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25637   (exit $ac_status); } && {
25638          test -z "$ac_c_werror_flag" ||
25639          test ! -s conftest.err
25640        } && test -s conftest.$ac_objext; then
25641   ac_hi=$ac_mid; break
25642 else
25643   $as_echo "$as_me: failed program was:" >&5
25644 sed 's/^/| /' conftest.$ac_ext >&5
25645
25646         ac_lo=`expr $ac_mid + 1`
25647                         if test $ac_lo -le $ac_mid; then
25648                           ac_lo= ac_hi=
25649                           break
25650                         fi
25651                         ac_mid=`expr 2 '*' $ac_mid + 1`
25652 fi
25653
25654 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25655   done
25656 else
25657   $as_echo "$as_me: failed program was:" >&5
25658 sed 's/^/| /' conftest.$ac_ext >&5
25659
25660         cat >conftest.$ac_ext <<_ACEOF
25661 /* confdefs.h.  */
25662 _ACEOF
25663 cat confdefs.h >>conftest.$ac_ext
25664 cat >>conftest.$ac_ext <<_ACEOF
25665 /* end confdefs.h.  */
25666 $ac_includes_default
25667 #ifndef offsetof
25668 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25669 #endif
25670 typedef struct { char x; short y; } ac__type_alignof_;
25671 int
25672 main ()
25673 {
25674 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25675 test_array [0] = 0
25676
25677   ;
25678   return 0;
25679 }
25680 _ACEOF
25681 rm -f conftest.$ac_objext
25682 if { (ac_try="$ac_compile"
25683 case "(($ac_try" in
25684   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25685   *) ac_try_echo=$ac_try;;
25686 esac
25687 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25688 $as_echo "$ac_try_echo") >&5
25689   (eval "$ac_compile") 2>conftest.er1
25690   ac_status=$?
25691   grep -v '^ *+' conftest.er1 >conftest.err
25692   rm -f conftest.er1
25693   cat conftest.err >&5
25694   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25695   (exit $ac_status); } && {
25696          test -z "$ac_c_werror_flag" ||
25697          test ! -s conftest.err
25698        } && test -s conftest.$ac_objext; then
25699   ac_hi=-1 ac_mid=-1
25700   while :; do
25701     cat >conftest.$ac_ext <<_ACEOF
25702 /* confdefs.h.  */
25703 _ACEOF
25704 cat confdefs.h >>conftest.$ac_ext
25705 cat >>conftest.$ac_ext <<_ACEOF
25706 /* end confdefs.h.  */
25707 $ac_includes_default
25708 #ifndef offsetof
25709 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25710 #endif
25711 typedef struct { char x; short y; } ac__type_alignof_;
25712 int
25713 main ()
25714 {
25715 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25716 test_array [0] = 0
25717
25718   ;
25719   return 0;
25720 }
25721 _ACEOF
25722 rm -f conftest.$ac_objext
25723 if { (ac_try="$ac_compile"
25724 case "(($ac_try" in
25725   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25726   *) ac_try_echo=$ac_try;;
25727 esac
25728 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25729 $as_echo "$ac_try_echo") >&5
25730   (eval "$ac_compile") 2>conftest.er1
25731   ac_status=$?
25732   grep -v '^ *+' conftest.er1 >conftest.err
25733   rm -f conftest.er1
25734   cat conftest.err >&5
25735   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25736   (exit $ac_status); } && {
25737          test -z "$ac_c_werror_flag" ||
25738          test ! -s conftest.err
25739        } && test -s conftest.$ac_objext; then
25740   ac_lo=$ac_mid; break
25741 else
25742   $as_echo "$as_me: failed program was:" >&5
25743 sed 's/^/| /' conftest.$ac_ext >&5
25744
25745         ac_hi=`expr '(' $ac_mid ')' - 1`
25746                         if test $ac_mid -le $ac_hi; then
25747                           ac_lo= ac_hi=
25748                           break
25749                         fi
25750                         ac_mid=`expr 2 '*' $ac_mid`
25751 fi
25752
25753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25754   done
25755 else
25756   $as_echo "$as_me: failed program was:" >&5
25757 sed 's/^/| /' conftest.$ac_ext >&5
25758
25759         ac_lo= ac_hi=
25760 fi
25761
25762 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25763 fi
25764
25765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25766 # Binary search between lo and hi bounds.
25767 while test "x$ac_lo" != "x$ac_hi"; do
25768   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25769   cat >conftest.$ac_ext <<_ACEOF
25770 /* confdefs.h.  */
25771 _ACEOF
25772 cat confdefs.h >>conftest.$ac_ext
25773 cat >>conftest.$ac_ext <<_ACEOF
25774 /* end confdefs.h.  */
25775 $ac_includes_default
25776 #ifndef offsetof
25777 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25778 #endif
25779 typedef struct { char x; short y; } ac__type_alignof_;
25780 int
25781 main ()
25782 {
25783 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25784 test_array [0] = 0
25785
25786   ;
25787   return 0;
25788 }
25789 _ACEOF
25790 rm -f conftest.$ac_objext
25791 if { (ac_try="$ac_compile"
25792 case "(($ac_try" in
25793   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25794   *) ac_try_echo=$ac_try;;
25795 esac
25796 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25797 $as_echo "$ac_try_echo") >&5
25798   (eval "$ac_compile") 2>conftest.er1
25799   ac_status=$?
25800   grep -v '^ *+' conftest.er1 >conftest.err
25801   rm -f conftest.er1
25802   cat conftest.err >&5
25803   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25804   (exit $ac_status); } && {
25805          test -z "$ac_c_werror_flag" ||
25806          test ! -s conftest.err
25807        } && test -s conftest.$ac_objext; then
25808   ac_hi=$ac_mid
25809 else
25810   $as_echo "$as_me: failed program was:" >&5
25811 sed 's/^/| /' conftest.$ac_ext >&5
25812
25813         ac_lo=`expr '(' $ac_mid ')' + 1`
25814 fi
25815
25816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25817 done
25818 case $ac_lo in
25819 ?*) ac_cv_alignof_short=$ac_lo;;
25820 '') if test "$ac_cv_type_short" = yes; then
25821      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25822 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25823 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25824 See \`config.log' for more details." >&5
25825 $as_echo "$as_me: error: cannot compute alignment of short
25826 See \`config.log' for more details." >&2;}
25827    { (exit 77); exit 77; }; }; }
25828    else
25829      ac_cv_alignof_short=0
25830    fi ;;
25831 esac
25832 else
25833   cat >conftest.$ac_ext <<_ACEOF
25834 /* confdefs.h.  */
25835 _ACEOF
25836 cat confdefs.h >>conftest.$ac_ext
25837 cat >>conftest.$ac_ext <<_ACEOF
25838 /* end confdefs.h.  */
25839 $ac_includes_default
25840 #ifndef offsetof
25841 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25842 #endif
25843 typedef struct { char x; short y; } ac__type_alignof_;
25844 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25845 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25846 #include <stdio.h>
25847 #include <stdlib.h>
25848 int
25849 main ()
25850 {
25851
25852   FILE *f = fopen ("conftest.val", "w");
25853   if (! f)
25854     return 1;
25855   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25856     {
25857       long int i = longval ();
25858       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25859         return 1;
25860       fprintf (f, "%ld", i);
25861     }
25862   else
25863     {
25864       unsigned long int i = ulongval ();
25865       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25866         return 1;
25867       fprintf (f, "%lu", i);
25868     }
25869   /* Do not output a trailing newline, as this causes \r\n confusion
25870      on some platforms.  */
25871   return ferror (f) || fclose (f) != 0;
25872
25873   ;
25874   return 0;
25875 }
25876 _ACEOF
25877 rm -f conftest$ac_exeext
25878 if { (ac_try="$ac_link"
25879 case "(($ac_try" in
25880   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25881   *) ac_try_echo=$ac_try;;
25882 esac
25883 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25884 $as_echo "$ac_try_echo") >&5
25885   (eval "$ac_link") 2>&5
25886   ac_status=$?
25887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25888   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25889   { (case "(($ac_try" in
25890   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25891   *) ac_try_echo=$ac_try;;
25892 esac
25893 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25894 $as_echo "$ac_try_echo") >&5
25895   (eval "$ac_try") 2>&5
25896   ac_status=$?
25897   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25898   (exit $ac_status); }; }; then
25899   ac_cv_alignof_short=`cat conftest.val`
25900 else
25901   $as_echo "$as_me: program exited with status $ac_status" >&5
25902 $as_echo "$as_me: failed program was:" >&5
25903 sed 's/^/| /' conftest.$ac_ext >&5
25904
25905 ( exit $ac_status )
25906 if test "$ac_cv_type_short" = yes; then
25907      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25908 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25909 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25910 See \`config.log' for more details." >&5
25911 $as_echo "$as_me: error: cannot compute alignment of short
25912 See \`config.log' for more details." >&2;}
25913    { (exit 77); exit 77; }; }; }
25914    else
25915      ac_cv_alignof_short=0
25916    fi
25917 fi
25918 rm -rf conftest.dSYM
25919 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25920 fi
25921 rm -f conftest.val
25922 fi
25923 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
25924 $as_echo "$ac_cv_alignof_short" >&6; }
25925
25926
25927
25928 cat >>confdefs.h <<_ACEOF
25929 #define ALIGNOF_SHORT $ac_cv_alignof_short
25930 _ACEOF
25931
25932
25933 # The cast to long int works around a bug in the HP C Compiler,
25934 # see AC_CHECK_SIZEOF for more information.
25935 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
25936 $as_echo_n "checking alignment of int... " >&6; }
25937 if test "${ac_cv_alignof_int+set}" = set; then
25938   $as_echo_n "(cached) " >&6
25939 else
25940   if test "$cross_compiling" = yes; then
25941   # Depending upon the size, compute the lo and hi bounds.
25942 cat >conftest.$ac_ext <<_ACEOF
25943 /* confdefs.h.  */
25944 _ACEOF
25945 cat confdefs.h >>conftest.$ac_ext
25946 cat >>conftest.$ac_ext <<_ACEOF
25947 /* end confdefs.h.  */
25948 $ac_includes_default
25949 #ifndef offsetof
25950 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25951 #endif
25952 typedef struct { char x; int y; } ac__type_alignof_;
25953 int
25954 main ()
25955 {
25956 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25957 test_array [0] = 0
25958
25959   ;
25960   return 0;
25961 }
25962 _ACEOF
25963 rm -f conftest.$ac_objext
25964 if { (ac_try="$ac_compile"
25965 case "(($ac_try" in
25966   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25967   *) ac_try_echo=$ac_try;;
25968 esac
25969 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25970 $as_echo "$ac_try_echo") >&5
25971   (eval "$ac_compile") 2>conftest.er1
25972   ac_status=$?
25973   grep -v '^ *+' conftest.er1 >conftest.err
25974   rm -f conftest.er1
25975   cat conftest.err >&5
25976   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25977   (exit $ac_status); } && {
25978          test -z "$ac_c_werror_flag" ||
25979          test ! -s conftest.err
25980        } && test -s conftest.$ac_objext; then
25981   ac_lo=0 ac_mid=0
25982   while :; do
25983     cat >conftest.$ac_ext <<_ACEOF
25984 /* confdefs.h.  */
25985 _ACEOF
25986 cat confdefs.h >>conftest.$ac_ext
25987 cat >>conftest.$ac_ext <<_ACEOF
25988 /* end confdefs.h.  */
25989 $ac_includes_default
25990 #ifndef offsetof
25991 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25992 #endif
25993 typedef struct { char x; int y; } ac__type_alignof_;
25994 int
25995 main ()
25996 {
25997 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25998 test_array [0] = 0
25999
26000   ;
26001   return 0;
26002 }
26003 _ACEOF
26004 rm -f conftest.$ac_objext
26005 if { (ac_try="$ac_compile"
26006 case "(($ac_try" in
26007   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26008   *) ac_try_echo=$ac_try;;
26009 esac
26010 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26011 $as_echo "$ac_try_echo") >&5
26012   (eval "$ac_compile") 2>conftest.er1
26013   ac_status=$?
26014   grep -v '^ *+' conftest.er1 >conftest.err
26015   rm -f conftest.er1
26016   cat conftest.err >&5
26017   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26018   (exit $ac_status); } && {
26019          test -z "$ac_c_werror_flag" ||
26020          test ! -s conftest.err
26021        } && test -s conftest.$ac_objext; then
26022   ac_hi=$ac_mid; break
26023 else
26024   $as_echo "$as_me: failed program was:" >&5
26025 sed 's/^/| /' conftest.$ac_ext >&5
26026
26027         ac_lo=`expr $ac_mid + 1`
26028                         if test $ac_lo -le $ac_mid; then
26029                           ac_lo= ac_hi=
26030                           break
26031                         fi
26032                         ac_mid=`expr 2 '*' $ac_mid + 1`
26033 fi
26034
26035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26036   done
26037 else
26038   $as_echo "$as_me: failed program was:" >&5
26039 sed 's/^/| /' conftest.$ac_ext >&5
26040
26041         cat >conftest.$ac_ext <<_ACEOF
26042 /* confdefs.h.  */
26043 _ACEOF
26044 cat confdefs.h >>conftest.$ac_ext
26045 cat >>conftest.$ac_ext <<_ACEOF
26046 /* end confdefs.h.  */
26047 $ac_includes_default
26048 #ifndef offsetof
26049 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26050 #endif
26051 typedef struct { char x; int y; } ac__type_alignof_;
26052 int
26053 main ()
26054 {
26055 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26056 test_array [0] = 0
26057
26058   ;
26059   return 0;
26060 }
26061 _ACEOF
26062 rm -f conftest.$ac_objext
26063 if { (ac_try="$ac_compile"
26064 case "(($ac_try" in
26065   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26066   *) ac_try_echo=$ac_try;;
26067 esac
26068 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26069 $as_echo "$ac_try_echo") >&5
26070   (eval "$ac_compile") 2>conftest.er1
26071   ac_status=$?
26072   grep -v '^ *+' conftest.er1 >conftest.err
26073   rm -f conftest.er1
26074   cat conftest.err >&5
26075   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26076   (exit $ac_status); } && {
26077          test -z "$ac_c_werror_flag" ||
26078          test ! -s conftest.err
26079        } && test -s conftest.$ac_objext; then
26080   ac_hi=-1 ac_mid=-1
26081   while :; do
26082     cat >conftest.$ac_ext <<_ACEOF
26083 /* confdefs.h.  */
26084 _ACEOF
26085 cat confdefs.h >>conftest.$ac_ext
26086 cat >>conftest.$ac_ext <<_ACEOF
26087 /* end confdefs.h.  */
26088 $ac_includes_default
26089 #ifndef offsetof
26090 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26091 #endif
26092 typedef struct { char x; int y; } ac__type_alignof_;
26093 int
26094 main ()
26095 {
26096 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26097 test_array [0] = 0
26098
26099   ;
26100   return 0;
26101 }
26102 _ACEOF
26103 rm -f conftest.$ac_objext
26104 if { (ac_try="$ac_compile"
26105 case "(($ac_try" in
26106   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26107   *) ac_try_echo=$ac_try;;
26108 esac
26109 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26110 $as_echo "$ac_try_echo") >&5
26111   (eval "$ac_compile") 2>conftest.er1
26112   ac_status=$?
26113   grep -v '^ *+' conftest.er1 >conftest.err
26114   rm -f conftest.er1
26115   cat conftest.err >&5
26116   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26117   (exit $ac_status); } && {
26118          test -z "$ac_c_werror_flag" ||
26119          test ! -s conftest.err
26120        } && test -s conftest.$ac_objext; then
26121   ac_lo=$ac_mid; break
26122 else
26123   $as_echo "$as_me: failed program was:" >&5
26124 sed 's/^/| /' conftest.$ac_ext >&5
26125
26126         ac_hi=`expr '(' $ac_mid ')' - 1`
26127                         if test $ac_mid -le $ac_hi; then
26128                           ac_lo= ac_hi=
26129                           break
26130                         fi
26131                         ac_mid=`expr 2 '*' $ac_mid`
26132 fi
26133
26134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26135   done
26136 else
26137   $as_echo "$as_me: failed program was:" >&5
26138 sed 's/^/| /' conftest.$ac_ext >&5
26139
26140         ac_lo= ac_hi=
26141 fi
26142
26143 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26144 fi
26145
26146 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26147 # Binary search between lo and hi bounds.
26148 while test "x$ac_lo" != "x$ac_hi"; do
26149   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26150   cat >conftest.$ac_ext <<_ACEOF
26151 /* confdefs.h.  */
26152 _ACEOF
26153 cat confdefs.h >>conftest.$ac_ext
26154 cat >>conftest.$ac_ext <<_ACEOF
26155 /* end confdefs.h.  */
26156 $ac_includes_default
26157 #ifndef offsetof
26158 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26159 #endif
26160 typedef struct { char x; int y; } ac__type_alignof_;
26161 int
26162 main ()
26163 {
26164 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26165 test_array [0] = 0
26166
26167   ;
26168   return 0;
26169 }
26170 _ACEOF
26171 rm -f conftest.$ac_objext
26172 if { (ac_try="$ac_compile"
26173 case "(($ac_try" in
26174   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26175   *) ac_try_echo=$ac_try;;
26176 esac
26177 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26178 $as_echo "$ac_try_echo") >&5
26179   (eval "$ac_compile") 2>conftest.er1
26180   ac_status=$?
26181   grep -v '^ *+' conftest.er1 >conftest.err
26182   rm -f conftest.er1
26183   cat conftest.err >&5
26184   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26185   (exit $ac_status); } && {
26186          test -z "$ac_c_werror_flag" ||
26187          test ! -s conftest.err
26188        } && test -s conftest.$ac_objext; then
26189   ac_hi=$ac_mid
26190 else
26191   $as_echo "$as_me: failed program was:" >&5
26192 sed 's/^/| /' conftest.$ac_ext >&5
26193
26194         ac_lo=`expr '(' $ac_mid ')' + 1`
26195 fi
26196
26197 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26198 done
26199 case $ac_lo in
26200 ?*) ac_cv_alignof_int=$ac_lo;;
26201 '') if test "$ac_cv_type_int" = yes; then
26202      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26203 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26204 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26205 See \`config.log' for more details." >&5
26206 $as_echo "$as_me: error: cannot compute alignment of int
26207 See \`config.log' for more details." >&2;}
26208    { (exit 77); exit 77; }; }; }
26209    else
26210      ac_cv_alignof_int=0
26211    fi ;;
26212 esac
26213 else
26214   cat >conftest.$ac_ext <<_ACEOF
26215 /* confdefs.h.  */
26216 _ACEOF
26217 cat confdefs.h >>conftest.$ac_ext
26218 cat >>conftest.$ac_ext <<_ACEOF
26219 /* end confdefs.h.  */
26220 $ac_includes_default
26221 #ifndef offsetof
26222 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26223 #endif
26224 typedef struct { char x; int y; } ac__type_alignof_;
26225 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26226 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26227 #include <stdio.h>
26228 #include <stdlib.h>
26229 int
26230 main ()
26231 {
26232
26233   FILE *f = fopen ("conftest.val", "w");
26234   if (! f)
26235     return 1;
26236   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26237     {
26238       long int i = longval ();
26239       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26240         return 1;
26241       fprintf (f, "%ld", i);
26242     }
26243   else
26244     {
26245       unsigned long int i = ulongval ();
26246       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26247         return 1;
26248       fprintf (f, "%lu", i);
26249     }
26250   /* Do not output a trailing newline, as this causes \r\n confusion
26251      on some platforms.  */
26252   return ferror (f) || fclose (f) != 0;
26253
26254   ;
26255   return 0;
26256 }
26257 _ACEOF
26258 rm -f conftest$ac_exeext
26259 if { (ac_try="$ac_link"
26260 case "(($ac_try" in
26261   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26262   *) ac_try_echo=$ac_try;;
26263 esac
26264 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26265 $as_echo "$ac_try_echo") >&5
26266   (eval "$ac_link") 2>&5
26267   ac_status=$?
26268   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26269   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26270   { (case "(($ac_try" in
26271   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26272   *) ac_try_echo=$ac_try;;
26273 esac
26274 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26275 $as_echo "$ac_try_echo") >&5
26276   (eval "$ac_try") 2>&5
26277   ac_status=$?
26278   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26279   (exit $ac_status); }; }; then
26280   ac_cv_alignof_int=`cat conftest.val`
26281 else
26282   $as_echo "$as_me: program exited with status $ac_status" >&5
26283 $as_echo "$as_me: failed program was:" >&5
26284 sed 's/^/| /' conftest.$ac_ext >&5
26285
26286 ( exit $ac_status )
26287 if test "$ac_cv_type_int" = yes; then
26288      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26289 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26290 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26291 See \`config.log' for more details." >&5
26292 $as_echo "$as_me: error: cannot compute alignment of int
26293 See \`config.log' for more details." >&2;}
26294    { (exit 77); exit 77; }; }; }
26295    else
26296      ac_cv_alignof_int=0
26297    fi
26298 fi
26299 rm -rf conftest.dSYM
26300 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26301 fi
26302 rm -f conftest.val
26303 fi
26304 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
26305 $as_echo "$ac_cv_alignof_int" >&6; }
26306
26307
26308
26309 cat >>confdefs.h <<_ACEOF
26310 #define ALIGNOF_INT $ac_cv_alignof_int
26311 _ACEOF
26312
26313
26314 # The cast to long int works around a bug in the HP C Compiler,
26315 # see AC_CHECK_SIZEOF for more information.
26316 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
26317 $as_echo_n "checking alignment of long... " >&6; }
26318 if test "${ac_cv_alignof_long+set}" = set; then
26319   $as_echo_n "(cached) " >&6
26320 else
26321   if test "$cross_compiling" = yes; then
26322   # Depending upon the size, compute the lo and hi bounds.
26323 cat >conftest.$ac_ext <<_ACEOF
26324 /* confdefs.h.  */
26325 _ACEOF
26326 cat confdefs.h >>conftest.$ac_ext
26327 cat >>conftest.$ac_ext <<_ACEOF
26328 /* end confdefs.h.  */
26329 $ac_includes_default
26330 #ifndef offsetof
26331 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26332 #endif
26333 typedef struct { char x; long y; } ac__type_alignof_;
26334 int
26335 main ()
26336 {
26337 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26338 test_array [0] = 0
26339
26340   ;
26341   return 0;
26342 }
26343 _ACEOF
26344 rm -f conftest.$ac_objext
26345 if { (ac_try="$ac_compile"
26346 case "(($ac_try" in
26347   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26348   *) ac_try_echo=$ac_try;;
26349 esac
26350 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26351 $as_echo "$ac_try_echo") >&5
26352   (eval "$ac_compile") 2>conftest.er1
26353   ac_status=$?
26354   grep -v '^ *+' conftest.er1 >conftest.err
26355   rm -f conftest.er1
26356   cat conftest.err >&5
26357   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26358   (exit $ac_status); } && {
26359          test -z "$ac_c_werror_flag" ||
26360          test ! -s conftest.err
26361        } && test -s conftest.$ac_objext; then
26362   ac_lo=0 ac_mid=0
26363   while :; do
26364     cat >conftest.$ac_ext <<_ACEOF
26365 /* confdefs.h.  */
26366 _ACEOF
26367 cat confdefs.h >>conftest.$ac_ext
26368 cat >>conftest.$ac_ext <<_ACEOF
26369 /* end confdefs.h.  */
26370 $ac_includes_default
26371 #ifndef offsetof
26372 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26373 #endif
26374 typedef struct { char x; long y; } ac__type_alignof_;
26375 int
26376 main ()
26377 {
26378 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26379 test_array [0] = 0
26380
26381   ;
26382   return 0;
26383 }
26384 _ACEOF
26385 rm -f conftest.$ac_objext
26386 if { (ac_try="$ac_compile"
26387 case "(($ac_try" in
26388   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26389   *) ac_try_echo=$ac_try;;
26390 esac
26391 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26392 $as_echo "$ac_try_echo") >&5
26393   (eval "$ac_compile") 2>conftest.er1
26394   ac_status=$?
26395   grep -v '^ *+' conftest.er1 >conftest.err
26396   rm -f conftest.er1
26397   cat conftest.err >&5
26398   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26399   (exit $ac_status); } && {
26400          test -z "$ac_c_werror_flag" ||
26401          test ! -s conftest.err
26402        } && test -s conftest.$ac_objext; then
26403   ac_hi=$ac_mid; break
26404 else
26405   $as_echo "$as_me: failed program was:" >&5
26406 sed 's/^/| /' conftest.$ac_ext >&5
26407
26408         ac_lo=`expr $ac_mid + 1`
26409                         if test $ac_lo -le $ac_mid; then
26410                           ac_lo= ac_hi=
26411                           break
26412                         fi
26413                         ac_mid=`expr 2 '*' $ac_mid + 1`
26414 fi
26415
26416 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26417   done
26418 else
26419   $as_echo "$as_me: failed program was:" >&5
26420 sed 's/^/| /' conftest.$ac_ext >&5
26421
26422         cat >conftest.$ac_ext <<_ACEOF
26423 /* confdefs.h.  */
26424 _ACEOF
26425 cat confdefs.h >>conftest.$ac_ext
26426 cat >>conftest.$ac_ext <<_ACEOF
26427 /* end confdefs.h.  */
26428 $ac_includes_default
26429 #ifndef offsetof
26430 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26431 #endif
26432 typedef struct { char x; long y; } ac__type_alignof_;
26433 int
26434 main ()
26435 {
26436 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26437 test_array [0] = 0
26438
26439   ;
26440   return 0;
26441 }
26442 _ACEOF
26443 rm -f conftest.$ac_objext
26444 if { (ac_try="$ac_compile"
26445 case "(($ac_try" in
26446   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26447   *) ac_try_echo=$ac_try;;
26448 esac
26449 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26450 $as_echo "$ac_try_echo") >&5
26451   (eval "$ac_compile") 2>conftest.er1
26452   ac_status=$?
26453   grep -v '^ *+' conftest.er1 >conftest.err
26454   rm -f conftest.er1
26455   cat conftest.err >&5
26456   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26457   (exit $ac_status); } && {
26458          test -z "$ac_c_werror_flag" ||
26459          test ! -s conftest.err
26460        } && test -s conftest.$ac_objext; then
26461   ac_hi=-1 ac_mid=-1
26462   while :; do
26463     cat >conftest.$ac_ext <<_ACEOF
26464 /* confdefs.h.  */
26465 _ACEOF
26466 cat confdefs.h >>conftest.$ac_ext
26467 cat >>conftest.$ac_ext <<_ACEOF
26468 /* end confdefs.h.  */
26469 $ac_includes_default
26470 #ifndef offsetof
26471 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26472 #endif
26473 typedef struct { char x; long y; } ac__type_alignof_;
26474 int
26475 main ()
26476 {
26477 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26478 test_array [0] = 0
26479
26480   ;
26481   return 0;
26482 }
26483 _ACEOF
26484 rm -f conftest.$ac_objext
26485 if { (ac_try="$ac_compile"
26486 case "(($ac_try" in
26487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26488   *) ac_try_echo=$ac_try;;
26489 esac
26490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26491 $as_echo "$ac_try_echo") >&5
26492   (eval "$ac_compile") 2>conftest.er1
26493   ac_status=$?
26494   grep -v '^ *+' conftest.er1 >conftest.err
26495   rm -f conftest.er1
26496   cat conftest.err >&5
26497   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26498   (exit $ac_status); } && {
26499          test -z "$ac_c_werror_flag" ||
26500          test ! -s conftest.err
26501        } && test -s conftest.$ac_objext; then
26502   ac_lo=$ac_mid; break
26503 else
26504   $as_echo "$as_me: failed program was:" >&5
26505 sed 's/^/| /' conftest.$ac_ext >&5
26506
26507         ac_hi=`expr '(' $ac_mid ')' - 1`
26508                         if test $ac_mid -le $ac_hi; then
26509                           ac_lo= ac_hi=
26510                           break
26511                         fi
26512                         ac_mid=`expr 2 '*' $ac_mid`
26513 fi
26514
26515 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26516   done
26517 else
26518   $as_echo "$as_me: failed program was:" >&5
26519 sed 's/^/| /' conftest.$ac_ext >&5
26520
26521         ac_lo= ac_hi=
26522 fi
26523
26524 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26525 fi
26526
26527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26528 # Binary search between lo and hi bounds.
26529 while test "x$ac_lo" != "x$ac_hi"; do
26530   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26531   cat >conftest.$ac_ext <<_ACEOF
26532 /* confdefs.h.  */
26533 _ACEOF
26534 cat confdefs.h >>conftest.$ac_ext
26535 cat >>conftest.$ac_ext <<_ACEOF
26536 /* end confdefs.h.  */
26537 $ac_includes_default
26538 #ifndef offsetof
26539 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26540 #endif
26541 typedef struct { char x; long y; } ac__type_alignof_;
26542 int
26543 main ()
26544 {
26545 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26546 test_array [0] = 0
26547
26548   ;
26549   return 0;
26550 }
26551 _ACEOF
26552 rm -f conftest.$ac_objext
26553 if { (ac_try="$ac_compile"
26554 case "(($ac_try" in
26555   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26556   *) ac_try_echo=$ac_try;;
26557 esac
26558 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26559 $as_echo "$ac_try_echo") >&5
26560   (eval "$ac_compile") 2>conftest.er1
26561   ac_status=$?
26562   grep -v '^ *+' conftest.er1 >conftest.err
26563   rm -f conftest.er1
26564   cat conftest.err >&5
26565   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26566   (exit $ac_status); } && {
26567          test -z "$ac_c_werror_flag" ||
26568          test ! -s conftest.err
26569        } && test -s conftest.$ac_objext; then
26570   ac_hi=$ac_mid
26571 else
26572   $as_echo "$as_me: failed program was:" >&5
26573 sed 's/^/| /' conftest.$ac_ext >&5
26574
26575         ac_lo=`expr '(' $ac_mid ')' + 1`
26576 fi
26577
26578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26579 done
26580 case $ac_lo in
26581 ?*) ac_cv_alignof_long=$ac_lo;;
26582 '') if test "$ac_cv_type_long" = yes; then
26583      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26584 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26585 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26586 See \`config.log' for more details." >&5
26587 $as_echo "$as_me: error: cannot compute alignment of long
26588 See \`config.log' for more details." >&2;}
26589    { (exit 77); exit 77; }; }; }
26590    else
26591      ac_cv_alignof_long=0
26592    fi ;;
26593 esac
26594 else
26595   cat >conftest.$ac_ext <<_ACEOF
26596 /* confdefs.h.  */
26597 _ACEOF
26598 cat confdefs.h >>conftest.$ac_ext
26599 cat >>conftest.$ac_ext <<_ACEOF
26600 /* end confdefs.h.  */
26601 $ac_includes_default
26602 #ifndef offsetof
26603 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26604 #endif
26605 typedef struct { char x; long y; } ac__type_alignof_;
26606 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26607 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26608 #include <stdio.h>
26609 #include <stdlib.h>
26610 int
26611 main ()
26612 {
26613
26614   FILE *f = fopen ("conftest.val", "w");
26615   if (! f)
26616     return 1;
26617   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26618     {
26619       long int i = longval ();
26620       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26621         return 1;
26622       fprintf (f, "%ld", i);
26623     }
26624   else
26625     {
26626       unsigned long int i = ulongval ();
26627       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26628         return 1;
26629       fprintf (f, "%lu", i);
26630     }
26631   /* Do not output a trailing newline, as this causes \r\n confusion
26632      on some platforms.  */
26633   return ferror (f) || fclose (f) != 0;
26634
26635   ;
26636   return 0;
26637 }
26638 _ACEOF
26639 rm -f conftest$ac_exeext
26640 if { (ac_try="$ac_link"
26641 case "(($ac_try" in
26642   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26643   *) ac_try_echo=$ac_try;;
26644 esac
26645 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26646 $as_echo "$ac_try_echo") >&5
26647   (eval "$ac_link") 2>&5
26648   ac_status=$?
26649   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26650   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26651   { (case "(($ac_try" in
26652   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26653   *) ac_try_echo=$ac_try;;
26654 esac
26655 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26656 $as_echo "$ac_try_echo") >&5
26657   (eval "$ac_try") 2>&5
26658   ac_status=$?
26659   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26660   (exit $ac_status); }; }; then
26661   ac_cv_alignof_long=`cat conftest.val`
26662 else
26663   $as_echo "$as_me: program exited with status $ac_status" >&5
26664 $as_echo "$as_me: failed program was:" >&5
26665 sed 's/^/| /' conftest.$ac_ext >&5
26666
26667 ( exit $ac_status )
26668 if test "$ac_cv_type_long" = yes; then
26669      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26670 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26671 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26672 See \`config.log' for more details." >&5
26673 $as_echo "$as_me: error: cannot compute alignment of long
26674 See \`config.log' for more details." >&2;}
26675    { (exit 77); exit 77; }; }; }
26676    else
26677      ac_cv_alignof_long=0
26678    fi
26679 fi
26680 rm -rf conftest.dSYM
26681 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26682 fi
26683 rm -f conftest.val
26684 fi
26685 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
26686 $as_echo "$ac_cv_alignof_long" >&6; }
26687
26688
26689
26690 cat >>confdefs.h <<_ACEOF
26691 #define ALIGNOF_LONG $ac_cv_alignof_long
26692 _ACEOF
26693
26694
26695 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
26696   # The cast to long int works around a bug in the HP C Compiler,
26697 # see AC_CHECK_SIZEOF for more information.
26698 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
26699 $as_echo_n "checking alignment of long long int... " >&6; }
26700 if test "${ac_cv_alignof_long_long_int+set}" = set; then
26701   $as_echo_n "(cached) " >&6
26702 else
26703   if test "$cross_compiling" = yes; then
26704   # Depending upon the size, compute the lo and hi bounds.
26705 cat >conftest.$ac_ext <<_ACEOF
26706 /* confdefs.h.  */
26707 _ACEOF
26708 cat confdefs.h >>conftest.$ac_ext
26709 cat >>conftest.$ac_ext <<_ACEOF
26710 /* end confdefs.h.  */
26711 $ac_includes_default
26712 #ifndef offsetof
26713 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26714 #endif
26715 typedef struct { char x; long long int y; } ac__type_alignof_;
26716 int
26717 main ()
26718 {
26719 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26720 test_array [0] = 0
26721
26722   ;
26723   return 0;
26724 }
26725 _ACEOF
26726 rm -f conftest.$ac_objext
26727 if { (ac_try="$ac_compile"
26728 case "(($ac_try" in
26729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26730   *) ac_try_echo=$ac_try;;
26731 esac
26732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26733 $as_echo "$ac_try_echo") >&5
26734   (eval "$ac_compile") 2>conftest.er1
26735   ac_status=$?
26736   grep -v '^ *+' conftest.er1 >conftest.err
26737   rm -f conftest.er1
26738   cat conftest.err >&5
26739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26740   (exit $ac_status); } && {
26741          test -z "$ac_c_werror_flag" ||
26742          test ! -s conftest.err
26743        } && test -s conftest.$ac_objext; then
26744   ac_lo=0 ac_mid=0
26745   while :; do
26746     cat >conftest.$ac_ext <<_ACEOF
26747 /* confdefs.h.  */
26748 _ACEOF
26749 cat confdefs.h >>conftest.$ac_ext
26750 cat >>conftest.$ac_ext <<_ACEOF
26751 /* end confdefs.h.  */
26752 $ac_includes_default
26753 #ifndef offsetof
26754 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26755 #endif
26756 typedef struct { char x; long long int y; } ac__type_alignof_;
26757 int
26758 main ()
26759 {
26760 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26761 test_array [0] = 0
26762
26763   ;
26764   return 0;
26765 }
26766 _ACEOF
26767 rm -f conftest.$ac_objext
26768 if { (ac_try="$ac_compile"
26769 case "(($ac_try" in
26770   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26771   *) ac_try_echo=$ac_try;;
26772 esac
26773 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26774 $as_echo "$ac_try_echo") >&5
26775   (eval "$ac_compile") 2>conftest.er1
26776   ac_status=$?
26777   grep -v '^ *+' conftest.er1 >conftest.err
26778   rm -f conftest.er1
26779   cat conftest.err >&5
26780   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26781   (exit $ac_status); } && {
26782          test -z "$ac_c_werror_flag" ||
26783          test ! -s conftest.err
26784        } && test -s conftest.$ac_objext; then
26785   ac_hi=$ac_mid; break
26786 else
26787   $as_echo "$as_me: failed program was:" >&5
26788 sed 's/^/| /' conftest.$ac_ext >&5
26789
26790         ac_lo=`expr $ac_mid + 1`
26791                         if test $ac_lo -le $ac_mid; then
26792                           ac_lo= ac_hi=
26793                           break
26794                         fi
26795                         ac_mid=`expr 2 '*' $ac_mid + 1`
26796 fi
26797
26798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26799   done
26800 else
26801   $as_echo "$as_me: failed program was:" >&5
26802 sed 's/^/| /' conftest.$ac_ext >&5
26803
26804         cat >conftest.$ac_ext <<_ACEOF
26805 /* confdefs.h.  */
26806 _ACEOF
26807 cat confdefs.h >>conftest.$ac_ext
26808 cat >>conftest.$ac_ext <<_ACEOF
26809 /* end confdefs.h.  */
26810 $ac_includes_default
26811 #ifndef offsetof
26812 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26813 #endif
26814 typedef struct { char x; long long int y; } ac__type_alignof_;
26815 int
26816 main ()
26817 {
26818 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26819 test_array [0] = 0
26820
26821   ;
26822   return 0;
26823 }
26824 _ACEOF
26825 rm -f conftest.$ac_objext
26826 if { (ac_try="$ac_compile"
26827 case "(($ac_try" in
26828   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26829   *) ac_try_echo=$ac_try;;
26830 esac
26831 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26832 $as_echo "$ac_try_echo") >&5
26833   (eval "$ac_compile") 2>conftest.er1
26834   ac_status=$?
26835   grep -v '^ *+' conftest.er1 >conftest.err
26836   rm -f conftest.er1
26837   cat conftest.err >&5
26838   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26839   (exit $ac_status); } && {
26840          test -z "$ac_c_werror_flag" ||
26841          test ! -s conftest.err
26842        } && test -s conftest.$ac_objext; then
26843   ac_hi=-1 ac_mid=-1
26844   while :; do
26845     cat >conftest.$ac_ext <<_ACEOF
26846 /* confdefs.h.  */
26847 _ACEOF
26848 cat confdefs.h >>conftest.$ac_ext
26849 cat >>conftest.$ac_ext <<_ACEOF
26850 /* end confdefs.h.  */
26851 $ac_includes_default
26852 #ifndef offsetof
26853 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26854 #endif
26855 typedef struct { char x; long long int y; } ac__type_alignof_;
26856 int
26857 main ()
26858 {
26859 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26860 test_array [0] = 0
26861
26862   ;
26863   return 0;
26864 }
26865 _ACEOF
26866 rm -f conftest.$ac_objext
26867 if { (ac_try="$ac_compile"
26868 case "(($ac_try" in
26869   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26870   *) ac_try_echo=$ac_try;;
26871 esac
26872 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26873 $as_echo "$ac_try_echo") >&5
26874   (eval "$ac_compile") 2>conftest.er1
26875   ac_status=$?
26876   grep -v '^ *+' conftest.er1 >conftest.err
26877   rm -f conftest.er1
26878   cat conftest.err >&5
26879   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26880   (exit $ac_status); } && {
26881          test -z "$ac_c_werror_flag" ||
26882          test ! -s conftest.err
26883        } && test -s conftest.$ac_objext; then
26884   ac_lo=$ac_mid; break
26885 else
26886   $as_echo "$as_me: failed program was:" >&5
26887 sed 's/^/| /' conftest.$ac_ext >&5
26888
26889         ac_hi=`expr '(' $ac_mid ')' - 1`
26890                         if test $ac_mid -le $ac_hi; then
26891                           ac_lo= ac_hi=
26892                           break
26893                         fi
26894                         ac_mid=`expr 2 '*' $ac_mid`
26895 fi
26896
26897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26898   done
26899 else
26900   $as_echo "$as_me: failed program was:" >&5
26901 sed 's/^/| /' conftest.$ac_ext >&5
26902
26903         ac_lo= ac_hi=
26904 fi
26905
26906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26907 fi
26908
26909 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26910 # Binary search between lo and hi bounds.
26911 while test "x$ac_lo" != "x$ac_hi"; do
26912   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26913   cat >conftest.$ac_ext <<_ACEOF
26914 /* confdefs.h.  */
26915 _ACEOF
26916 cat confdefs.h >>conftest.$ac_ext
26917 cat >>conftest.$ac_ext <<_ACEOF
26918 /* end confdefs.h.  */
26919 $ac_includes_default
26920 #ifndef offsetof
26921 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26922 #endif
26923 typedef struct { char x; long long int y; } ac__type_alignof_;
26924 int
26925 main ()
26926 {
26927 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26928 test_array [0] = 0
26929
26930   ;
26931   return 0;
26932 }
26933 _ACEOF
26934 rm -f conftest.$ac_objext
26935 if { (ac_try="$ac_compile"
26936 case "(($ac_try" in
26937   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26938   *) ac_try_echo=$ac_try;;
26939 esac
26940 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26941 $as_echo "$ac_try_echo") >&5
26942   (eval "$ac_compile") 2>conftest.er1
26943   ac_status=$?
26944   grep -v '^ *+' conftest.er1 >conftest.err
26945   rm -f conftest.er1
26946   cat conftest.err >&5
26947   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26948   (exit $ac_status); } && {
26949          test -z "$ac_c_werror_flag" ||
26950          test ! -s conftest.err
26951        } && test -s conftest.$ac_objext; then
26952   ac_hi=$ac_mid
26953 else
26954   $as_echo "$as_me: failed program was:" >&5
26955 sed 's/^/| /' conftest.$ac_ext >&5
26956
26957         ac_lo=`expr '(' $ac_mid ')' + 1`
26958 fi
26959
26960 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26961 done
26962 case $ac_lo in
26963 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
26964 '') if test "$ac_cv_type_long_long_int" = yes; then
26965      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26966 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26967 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26968 See \`config.log' for more details." >&5
26969 $as_echo "$as_me: error: cannot compute alignment of long long int
26970 See \`config.log' for more details." >&2;}
26971    { (exit 77); exit 77; }; }; }
26972    else
26973      ac_cv_alignof_long_long_int=0
26974    fi ;;
26975 esac
26976 else
26977   cat >conftest.$ac_ext <<_ACEOF
26978 /* confdefs.h.  */
26979 _ACEOF
26980 cat confdefs.h >>conftest.$ac_ext
26981 cat >>conftest.$ac_ext <<_ACEOF
26982 /* end confdefs.h.  */
26983 $ac_includes_default
26984 #ifndef offsetof
26985 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26986 #endif
26987 typedef struct { char x; long long int y; } ac__type_alignof_;
26988 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26989 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26990 #include <stdio.h>
26991 #include <stdlib.h>
26992 int
26993 main ()
26994 {
26995
26996   FILE *f = fopen ("conftest.val", "w");
26997   if (! f)
26998     return 1;
26999   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27000     {
27001       long int i = longval ();
27002       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27003         return 1;
27004       fprintf (f, "%ld", i);
27005     }
27006   else
27007     {
27008       unsigned long int i = ulongval ();
27009       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27010         return 1;
27011       fprintf (f, "%lu", i);
27012     }
27013   /* Do not output a trailing newline, as this causes \r\n confusion
27014      on some platforms.  */
27015   return ferror (f) || fclose (f) != 0;
27016
27017   ;
27018   return 0;
27019 }
27020 _ACEOF
27021 rm -f conftest$ac_exeext
27022 if { (ac_try="$ac_link"
27023 case "(($ac_try" in
27024   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27025   *) ac_try_echo=$ac_try;;
27026 esac
27027 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27028 $as_echo "$ac_try_echo") >&5
27029   (eval "$ac_link") 2>&5
27030   ac_status=$?
27031   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27032   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27033   { (case "(($ac_try" in
27034   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27035   *) ac_try_echo=$ac_try;;
27036 esac
27037 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27038 $as_echo "$ac_try_echo") >&5
27039   (eval "$ac_try") 2>&5
27040   ac_status=$?
27041   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27042   (exit $ac_status); }; }; then
27043   ac_cv_alignof_long_long_int=`cat conftest.val`
27044 else
27045   $as_echo "$as_me: program exited with status $ac_status" >&5
27046 $as_echo "$as_me: failed program was:" >&5
27047 sed 's/^/| /' conftest.$ac_ext >&5
27048
27049 ( exit $ac_status )
27050 if test "$ac_cv_type_long_long_int" = yes; then
27051      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27052 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27053 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
27054 See \`config.log' for more details." >&5
27055 $as_echo "$as_me: error: cannot compute alignment of long long int
27056 See \`config.log' for more details." >&2;}
27057    { (exit 77); exit 77; }; }; }
27058    else
27059      ac_cv_alignof_long_long_int=0
27060    fi
27061 fi
27062 rm -rf conftest.dSYM
27063 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27064 fi
27065 rm -f conftest.val
27066 fi
27067 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
27068 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
27069
27070
27071
27072 cat >>confdefs.h <<_ACEOF
27073 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
27074 _ACEOF
27075
27076
27077 fi
27078 # The cast to long int works around a bug in the HP C Compiler,
27079 # see AC_CHECK_SIZEOF for more information.
27080 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
27081 $as_echo_n "checking alignment of double... " >&6; }
27082 if test "${ac_cv_alignof_double+set}" = set; then
27083   $as_echo_n "(cached) " >&6
27084 else
27085   if test "$cross_compiling" = yes; then
27086   # Depending upon the size, compute the lo and hi bounds.
27087 cat >conftest.$ac_ext <<_ACEOF
27088 /* confdefs.h.  */
27089 _ACEOF
27090 cat confdefs.h >>conftest.$ac_ext
27091 cat >>conftest.$ac_ext <<_ACEOF
27092 /* end confdefs.h.  */
27093 $ac_includes_default
27094 #ifndef offsetof
27095 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27096 #endif
27097 typedef struct { char x; double y; } ac__type_alignof_;
27098 int
27099 main ()
27100 {
27101 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
27102 test_array [0] = 0
27103
27104   ;
27105   return 0;
27106 }
27107 _ACEOF
27108 rm -f conftest.$ac_objext
27109 if { (ac_try="$ac_compile"
27110 case "(($ac_try" in
27111   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27112   *) ac_try_echo=$ac_try;;
27113 esac
27114 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27115 $as_echo "$ac_try_echo") >&5
27116   (eval "$ac_compile") 2>conftest.er1
27117   ac_status=$?
27118   grep -v '^ *+' conftest.er1 >conftest.err
27119   rm -f conftest.er1
27120   cat conftest.err >&5
27121   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27122   (exit $ac_status); } && {
27123          test -z "$ac_c_werror_flag" ||
27124          test ! -s conftest.err
27125        } && test -s conftest.$ac_objext; then
27126   ac_lo=0 ac_mid=0
27127   while :; do
27128     cat >conftest.$ac_ext <<_ACEOF
27129 /* confdefs.h.  */
27130 _ACEOF
27131 cat confdefs.h >>conftest.$ac_ext
27132 cat >>conftest.$ac_ext <<_ACEOF
27133 /* end confdefs.h.  */
27134 $ac_includes_default
27135 #ifndef offsetof
27136 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27137 #endif
27138 typedef struct { char x; double y; } ac__type_alignof_;
27139 int
27140 main ()
27141 {
27142 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27143 test_array [0] = 0
27144
27145   ;
27146   return 0;
27147 }
27148 _ACEOF
27149 rm -f conftest.$ac_objext
27150 if { (ac_try="$ac_compile"
27151 case "(($ac_try" in
27152   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27153   *) ac_try_echo=$ac_try;;
27154 esac
27155 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27156 $as_echo "$ac_try_echo") >&5
27157   (eval "$ac_compile") 2>conftest.er1
27158   ac_status=$?
27159   grep -v '^ *+' conftest.er1 >conftest.err
27160   rm -f conftest.er1
27161   cat conftest.err >&5
27162   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27163   (exit $ac_status); } && {
27164          test -z "$ac_c_werror_flag" ||
27165          test ! -s conftest.err
27166        } && test -s conftest.$ac_objext; then
27167   ac_hi=$ac_mid; break
27168 else
27169   $as_echo "$as_me: failed program was:" >&5
27170 sed 's/^/| /' conftest.$ac_ext >&5
27171
27172         ac_lo=`expr $ac_mid + 1`
27173                         if test $ac_lo -le $ac_mid; then
27174                           ac_lo= ac_hi=
27175                           break
27176                         fi
27177                         ac_mid=`expr 2 '*' $ac_mid + 1`
27178 fi
27179
27180 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27181   done
27182 else
27183   $as_echo "$as_me: failed program was:" >&5
27184 sed 's/^/| /' conftest.$ac_ext >&5
27185
27186         cat >conftest.$ac_ext <<_ACEOF
27187 /* confdefs.h.  */
27188 _ACEOF
27189 cat confdefs.h >>conftest.$ac_ext
27190 cat >>conftest.$ac_ext <<_ACEOF
27191 /* end confdefs.h.  */
27192 $ac_includes_default
27193 #ifndef offsetof
27194 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27195 #endif
27196 typedef struct { char x; double y; } ac__type_alignof_;
27197 int
27198 main ()
27199 {
27200 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
27201 test_array [0] = 0
27202
27203   ;
27204   return 0;
27205 }
27206 _ACEOF
27207 rm -f conftest.$ac_objext
27208 if { (ac_try="$ac_compile"
27209 case "(($ac_try" in
27210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27211   *) ac_try_echo=$ac_try;;
27212 esac
27213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27214 $as_echo "$ac_try_echo") >&5
27215   (eval "$ac_compile") 2>conftest.er1
27216   ac_status=$?
27217   grep -v '^ *+' conftest.er1 >conftest.err
27218   rm -f conftest.er1
27219   cat conftest.err >&5
27220   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27221   (exit $ac_status); } && {
27222          test -z "$ac_c_werror_flag" ||
27223          test ! -s conftest.err
27224        } && test -s conftest.$ac_objext; then
27225   ac_hi=-1 ac_mid=-1
27226   while :; do
27227     cat >conftest.$ac_ext <<_ACEOF
27228 /* confdefs.h.  */
27229 _ACEOF
27230 cat confdefs.h >>conftest.$ac_ext
27231 cat >>conftest.$ac_ext <<_ACEOF
27232 /* end confdefs.h.  */
27233 $ac_includes_default
27234 #ifndef offsetof
27235 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27236 #endif
27237 typedef struct { char x; double y; } ac__type_alignof_;
27238 int
27239 main ()
27240 {
27241 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
27242 test_array [0] = 0
27243
27244   ;
27245   return 0;
27246 }
27247 _ACEOF
27248 rm -f conftest.$ac_objext
27249 if { (ac_try="$ac_compile"
27250 case "(($ac_try" in
27251   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27252   *) ac_try_echo=$ac_try;;
27253 esac
27254 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27255 $as_echo "$ac_try_echo") >&5
27256   (eval "$ac_compile") 2>conftest.er1
27257   ac_status=$?
27258   grep -v '^ *+' conftest.er1 >conftest.err
27259   rm -f conftest.er1
27260   cat conftest.err >&5
27261   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27262   (exit $ac_status); } && {
27263          test -z "$ac_c_werror_flag" ||
27264          test ! -s conftest.err
27265        } && test -s conftest.$ac_objext; then
27266   ac_lo=$ac_mid; break
27267 else
27268   $as_echo "$as_me: failed program was:" >&5
27269 sed 's/^/| /' conftest.$ac_ext >&5
27270
27271         ac_hi=`expr '(' $ac_mid ')' - 1`
27272                         if test $ac_mid -le $ac_hi; then
27273                           ac_lo= ac_hi=
27274                           break
27275                         fi
27276                         ac_mid=`expr 2 '*' $ac_mid`
27277 fi
27278
27279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27280   done
27281 else
27282   $as_echo "$as_me: failed program was:" >&5
27283 sed 's/^/| /' conftest.$ac_ext >&5
27284
27285         ac_lo= ac_hi=
27286 fi
27287
27288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27289 fi
27290
27291 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27292 # Binary search between lo and hi bounds.
27293 while test "x$ac_lo" != "x$ac_hi"; do
27294   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27295   cat >conftest.$ac_ext <<_ACEOF
27296 /* confdefs.h.  */
27297 _ACEOF
27298 cat confdefs.h >>conftest.$ac_ext
27299 cat >>conftest.$ac_ext <<_ACEOF
27300 /* end confdefs.h.  */
27301 $ac_includes_default
27302 #ifndef offsetof
27303 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27304 #endif
27305 typedef struct { char x; double y; } ac__type_alignof_;
27306 int
27307 main ()
27308 {
27309 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27310 test_array [0] = 0
27311
27312   ;
27313   return 0;
27314 }
27315 _ACEOF
27316 rm -f conftest.$ac_objext
27317 if { (ac_try="$ac_compile"
27318 case "(($ac_try" in
27319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27320   *) ac_try_echo=$ac_try;;
27321 esac
27322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27323 $as_echo "$ac_try_echo") >&5
27324   (eval "$ac_compile") 2>conftest.er1
27325   ac_status=$?
27326   grep -v '^ *+' conftest.er1 >conftest.err
27327   rm -f conftest.er1
27328   cat conftest.err >&5
27329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27330   (exit $ac_status); } && {
27331          test -z "$ac_c_werror_flag" ||
27332          test ! -s conftest.err
27333        } && test -s conftest.$ac_objext; then
27334   ac_hi=$ac_mid
27335 else
27336   $as_echo "$as_me: failed program was:" >&5
27337 sed 's/^/| /' conftest.$ac_ext >&5
27338
27339         ac_lo=`expr '(' $ac_mid ')' + 1`
27340 fi
27341
27342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27343 done
27344 case $ac_lo in
27345 ?*) ac_cv_alignof_double=$ac_lo;;
27346 '') if test "$ac_cv_type_double" = yes; then
27347      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27348 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27349 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27350 See \`config.log' for more details." >&5
27351 $as_echo "$as_me: error: cannot compute alignment of double
27352 See \`config.log' for more details." >&2;}
27353    { (exit 77); exit 77; }; }; }
27354    else
27355      ac_cv_alignof_double=0
27356    fi ;;
27357 esac
27358 else
27359   cat >conftest.$ac_ext <<_ACEOF
27360 /* confdefs.h.  */
27361 _ACEOF
27362 cat confdefs.h >>conftest.$ac_ext
27363 cat >>conftest.$ac_ext <<_ACEOF
27364 /* end confdefs.h.  */
27365 $ac_includes_default
27366 #ifndef offsetof
27367 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27368 #endif
27369 typedef struct { char x; double y; } ac__type_alignof_;
27370 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27371 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27372 #include <stdio.h>
27373 #include <stdlib.h>
27374 int
27375 main ()
27376 {
27377
27378   FILE *f = fopen ("conftest.val", "w");
27379   if (! f)
27380     return 1;
27381   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27382     {
27383       long int i = longval ();
27384       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27385         return 1;
27386       fprintf (f, "%ld", i);
27387     }
27388   else
27389     {
27390       unsigned long int i = ulongval ();
27391       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27392         return 1;
27393       fprintf (f, "%lu", i);
27394     }
27395   /* Do not output a trailing newline, as this causes \r\n confusion
27396      on some platforms.  */
27397   return ferror (f) || fclose (f) != 0;
27398
27399   ;
27400   return 0;
27401 }
27402 _ACEOF
27403 rm -f conftest$ac_exeext
27404 if { (ac_try="$ac_link"
27405 case "(($ac_try" in
27406   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27407   *) ac_try_echo=$ac_try;;
27408 esac
27409 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27410 $as_echo "$ac_try_echo") >&5
27411   (eval "$ac_link") 2>&5
27412   ac_status=$?
27413   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27414   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27415   { (case "(($ac_try" in
27416   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27417   *) ac_try_echo=$ac_try;;
27418 esac
27419 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27420 $as_echo "$ac_try_echo") >&5
27421   (eval "$ac_try") 2>&5
27422   ac_status=$?
27423   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27424   (exit $ac_status); }; }; then
27425   ac_cv_alignof_double=`cat conftest.val`
27426 else
27427   $as_echo "$as_me: program exited with status $ac_status" >&5
27428 $as_echo "$as_me: failed program was:" >&5
27429 sed 's/^/| /' conftest.$ac_ext >&5
27430
27431 ( exit $ac_status )
27432 if test "$ac_cv_type_double" = yes; then
27433      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27434 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27435 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27436 See \`config.log' for more details." >&5
27437 $as_echo "$as_me: error: cannot compute alignment of double
27438 See \`config.log' for more details." >&2;}
27439    { (exit 77); exit 77; }; }; }
27440    else
27441      ac_cv_alignof_double=0
27442    fi
27443 fi
27444 rm -rf conftest.dSYM
27445 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27446 fi
27447 rm -f conftest.val
27448 fi
27449 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
27450 $as_echo "$ac_cv_alignof_double" >&6; }
27451
27452
27453
27454 cat >>confdefs.h <<_ACEOF
27455 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
27456 _ACEOF
27457
27458
27459
27460 # Compute maximum alignment of any basic type.
27461 # We assume long's alignment is at least as strong as char, short, or int;
27462 # but we must check long long (if it exists) and double.
27463
27464 MAX_ALIGNOF=$ac_cv_alignof_long
27465 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
27466   MAX_ALIGNOF=$ac_cv_alignof_double
27467 fi
27468 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
27469   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
27470 fi
27471
27472 cat >>confdefs.h <<_ACEOF
27473 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
27474 _ACEOF
27475
27476
27477
27478 # Some platforms predefine the types int8, int16, etc.  Only check
27479 # a (hopefully) representative subset.
27480 { $as_echo "$as_me:$LINENO: checking for int8" >&5
27481 $as_echo_n "checking for int8... " >&6; }
27482 if test "${ac_cv_type_int8+set}" = set; then
27483   $as_echo_n "(cached) " >&6
27484 else
27485   ac_cv_type_int8=no
27486 cat >conftest.$ac_ext <<_ACEOF
27487 /* confdefs.h.  */
27488 _ACEOF
27489 cat confdefs.h >>conftest.$ac_ext
27490 cat >>conftest.$ac_ext <<_ACEOF
27491 /* end confdefs.h.  */
27492 #include <stdio.h>
27493 #ifdef HAVE_SUPPORTDEFS_H
27494 #include <SupportDefs.h>
27495 #endif
27496
27497 int
27498 main ()
27499 {
27500 if (sizeof (int8))
27501        return 0;
27502   ;
27503   return 0;
27504 }
27505 _ACEOF
27506 rm -f conftest.$ac_objext
27507 if { (ac_try="$ac_compile"
27508 case "(($ac_try" in
27509   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27510   *) ac_try_echo=$ac_try;;
27511 esac
27512 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27513 $as_echo "$ac_try_echo") >&5
27514   (eval "$ac_compile") 2>conftest.er1
27515   ac_status=$?
27516   grep -v '^ *+' conftest.er1 >conftest.err
27517   rm -f conftest.er1
27518   cat conftest.err >&5
27519   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27520   (exit $ac_status); } && {
27521          test -z "$ac_c_werror_flag" ||
27522          test ! -s conftest.err
27523        } && test -s conftest.$ac_objext; then
27524   cat >conftest.$ac_ext <<_ACEOF
27525 /* confdefs.h.  */
27526 _ACEOF
27527 cat confdefs.h >>conftest.$ac_ext
27528 cat >>conftest.$ac_ext <<_ACEOF
27529 /* end confdefs.h.  */
27530 #include <stdio.h>
27531 #ifdef HAVE_SUPPORTDEFS_H
27532 #include <SupportDefs.h>
27533 #endif
27534
27535 int
27536 main ()
27537 {
27538 if (sizeof ((int8)))
27539           return 0;
27540   ;
27541   return 0;
27542 }
27543 _ACEOF
27544 rm -f conftest.$ac_objext
27545 if { (ac_try="$ac_compile"
27546 case "(($ac_try" in
27547   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27548   *) ac_try_echo=$ac_try;;
27549 esac
27550 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27551 $as_echo "$ac_try_echo") >&5
27552   (eval "$ac_compile") 2>conftest.er1
27553   ac_status=$?
27554   grep -v '^ *+' conftest.er1 >conftest.err
27555   rm -f conftest.er1
27556   cat conftest.err >&5
27557   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27558   (exit $ac_status); } && {
27559          test -z "$ac_c_werror_flag" ||
27560          test ! -s conftest.err
27561        } && test -s conftest.$ac_objext; then
27562   :
27563 else
27564   $as_echo "$as_me: failed program was:" >&5
27565 sed 's/^/| /' conftest.$ac_ext >&5
27566
27567         ac_cv_type_int8=yes
27568 fi
27569
27570 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27571 else
27572   $as_echo "$as_me: failed program was:" >&5
27573 sed 's/^/| /' conftest.$ac_ext >&5
27574
27575
27576 fi
27577
27578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27579 fi
27580 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
27581 $as_echo "$ac_cv_type_int8" >&6; }
27582 if test "x$ac_cv_type_int8" = x""yes; then
27583
27584 cat >>confdefs.h <<_ACEOF
27585 #define HAVE_INT8 1
27586 _ACEOF
27587
27588
27589 fi
27590 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
27591 $as_echo_n "checking for uint8... " >&6; }
27592 if test "${ac_cv_type_uint8+set}" = set; then
27593   $as_echo_n "(cached) " >&6
27594 else
27595   ac_cv_type_uint8=no
27596 cat >conftest.$ac_ext <<_ACEOF
27597 /* confdefs.h.  */
27598 _ACEOF
27599 cat confdefs.h >>conftest.$ac_ext
27600 cat >>conftest.$ac_ext <<_ACEOF
27601 /* end confdefs.h.  */
27602 #include <stdio.h>
27603 #ifdef HAVE_SUPPORTDEFS_H
27604 #include <SupportDefs.h>
27605 #endif
27606
27607 int
27608 main ()
27609 {
27610 if (sizeof (uint8))
27611        return 0;
27612   ;
27613   return 0;
27614 }
27615 _ACEOF
27616 rm -f conftest.$ac_objext
27617 if { (ac_try="$ac_compile"
27618 case "(($ac_try" in
27619   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27620   *) ac_try_echo=$ac_try;;
27621 esac
27622 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27623 $as_echo "$ac_try_echo") >&5
27624   (eval "$ac_compile") 2>conftest.er1
27625   ac_status=$?
27626   grep -v '^ *+' conftest.er1 >conftest.err
27627   rm -f conftest.er1
27628   cat conftest.err >&5
27629   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27630   (exit $ac_status); } && {
27631          test -z "$ac_c_werror_flag" ||
27632          test ! -s conftest.err
27633        } && test -s conftest.$ac_objext; then
27634   cat >conftest.$ac_ext <<_ACEOF
27635 /* confdefs.h.  */
27636 _ACEOF
27637 cat confdefs.h >>conftest.$ac_ext
27638 cat >>conftest.$ac_ext <<_ACEOF
27639 /* end confdefs.h.  */
27640 #include <stdio.h>
27641 #ifdef HAVE_SUPPORTDEFS_H
27642 #include <SupportDefs.h>
27643 #endif
27644
27645 int
27646 main ()
27647 {
27648 if (sizeof ((uint8)))
27649           return 0;
27650   ;
27651   return 0;
27652 }
27653 _ACEOF
27654 rm -f conftest.$ac_objext
27655 if { (ac_try="$ac_compile"
27656 case "(($ac_try" in
27657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27658   *) ac_try_echo=$ac_try;;
27659 esac
27660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27661 $as_echo "$ac_try_echo") >&5
27662   (eval "$ac_compile") 2>conftest.er1
27663   ac_status=$?
27664   grep -v '^ *+' conftest.er1 >conftest.err
27665   rm -f conftest.er1
27666   cat conftest.err >&5
27667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27668   (exit $ac_status); } && {
27669          test -z "$ac_c_werror_flag" ||
27670          test ! -s conftest.err
27671        } && test -s conftest.$ac_objext; then
27672   :
27673 else
27674   $as_echo "$as_me: failed program was:" >&5
27675 sed 's/^/| /' conftest.$ac_ext >&5
27676
27677         ac_cv_type_uint8=yes
27678 fi
27679
27680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27681 else
27682   $as_echo "$as_me: failed program was:" >&5
27683 sed 's/^/| /' conftest.$ac_ext >&5
27684
27685
27686 fi
27687
27688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27689 fi
27690 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
27691 $as_echo "$ac_cv_type_uint8" >&6; }
27692 if test "x$ac_cv_type_uint8" = x""yes; then
27693
27694 cat >>confdefs.h <<_ACEOF
27695 #define HAVE_UINT8 1
27696 _ACEOF
27697
27698
27699 fi
27700 { $as_echo "$as_me:$LINENO: checking for int64" >&5
27701 $as_echo_n "checking for int64... " >&6; }
27702 if test "${ac_cv_type_int64+set}" = set; then
27703   $as_echo_n "(cached) " >&6
27704 else
27705   ac_cv_type_int64=no
27706 cat >conftest.$ac_ext <<_ACEOF
27707 /* confdefs.h.  */
27708 _ACEOF
27709 cat confdefs.h >>conftest.$ac_ext
27710 cat >>conftest.$ac_ext <<_ACEOF
27711 /* end confdefs.h.  */
27712 #include <stdio.h>
27713 #ifdef HAVE_SUPPORTDEFS_H
27714 #include <SupportDefs.h>
27715 #endif
27716
27717 int
27718 main ()
27719 {
27720 if (sizeof (int64))
27721        return 0;
27722   ;
27723   return 0;
27724 }
27725 _ACEOF
27726 rm -f conftest.$ac_objext
27727 if { (ac_try="$ac_compile"
27728 case "(($ac_try" in
27729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27730   *) ac_try_echo=$ac_try;;
27731 esac
27732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27733 $as_echo "$ac_try_echo") >&5
27734   (eval "$ac_compile") 2>conftest.er1
27735   ac_status=$?
27736   grep -v '^ *+' conftest.er1 >conftest.err
27737   rm -f conftest.er1
27738   cat conftest.err >&5
27739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27740   (exit $ac_status); } && {
27741          test -z "$ac_c_werror_flag" ||
27742          test ! -s conftest.err
27743        } && test -s conftest.$ac_objext; then
27744   cat >conftest.$ac_ext <<_ACEOF
27745 /* confdefs.h.  */
27746 _ACEOF
27747 cat confdefs.h >>conftest.$ac_ext
27748 cat >>conftest.$ac_ext <<_ACEOF
27749 /* end confdefs.h.  */
27750 #include <stdio.h>
27751 #ifdef HAVE_SUPPORTDEFS_H
27752 #include <SupportDefs.h>
27753 #endif
27754
27755 int
27756 main ()
27757 {
27758 if (sizeof ((int64)))
27759           return 0;
27760   ;
27761   return 0;
27762 }
27763 _ACEOF
27764 rm -f conftest.$ac_objext
27765 if { (ac_try="$ac_compile"
27766 case "(($ac_try" in
27767   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27768   *) ac_try_echo=$ac_try;;
27769 esac
27770 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27771 $as_echo "$ac_try_echo") >&5
27772   (eval "$ac_compile") 2>conftest.er1
27773   ac_status=$?
27774   grep -v '^ *+' conftest.er1 >conftest.err
27775   rm -f conftest.er1
27776   cat conftest.err >&5
27777   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27778   (exit $ac_status); } && {
27779          test -z "$ac_c_werror_flag" ||
27780          test ! -s conftest.err
27781        } && test -s conftest.$ac_objext; then
27782   :
27783 else
27784   $as_echo "$as_me: failed program was:" >&5
27785 sed 's/^/| /' conftest.$ac_ext >&5
27786
27787         ac_cv_type_int64=yes
27788 fi
27789
27790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27791 else
27792   $as_echo "$as_me: failed program was:" >&5
27793 sed 's/^/| /' conftest.$ac_ext >&5
27794
27795
27796 fi
27797
27798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27799 fi
27800 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
27801 $as_echo "$ac_cv_type_int64" >&6; }
27802 if test "x$ac_cv_type_int64" = x""yes; then
27803
27804 cat >>confdefs.h <<_ACEOF
27805 #define HAVE_INT64 1
27806 _ACEOF
27807
27808
27809 fi
27810 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
27811 $as_echo_n "checking for uint64... " >&6; }
27812 if test "${ac_cv_type_uint64+set}" = set; then
27813   $as_echo_n "(cached) " >&6
27814 else
27815   ac_cv_type_uint64=no
27816 cat >conftest.$ac_ext <<_ACEOF
27817 /* confdefs.h.  */
27818 _ACEOF
27819 cat confdefs.h >>conftest.$ac_ext
27820 cat >>conftest.$ac_ext <<_ACEOF
27821 /* end confdefs.h.  */
27822 #include <stdio.h>
27823 #ifdef HAVE_SUPPORTDEFS_H
27824 #include <SupportDefs.h>
27825 #endif
27826
27827 int
27828 main ()
27829 {
27830 if (sizeof (uint64))
27831        return 0;
27832   ;
27833   return 0;
27834 }
27835 _ACEOF
27836 rm -f conftest.$ac_objext
27837 if { (ac_try="$ac_compile"
27838 case "(($ac_try" in
27839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27840   *) ac_try_echo=$ac_try;;
27841 esac
27842 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27843 $as_echo "$ac_try_echo") >&5
27844   (eval "$ac_compile") 2>conftest.er1
27845   ac_status=$?
27846   grep -v '^ *+' conftest.er1 >conftest.err
27847   rm -f conftest.er1
27848   cat conftest.err >&5
27849   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27850   (exit $ac_status); } && {
27851          test -z "$ac_c_werror_flag" ||
27852          test ! -s conftest.err
27853        } && test -s conftest.$ac_objext; then
27854   cat >conftest.$ac_ext <<_ACEOF
27855 /* confdefs.h.  */
27856 _ACEOF
27857 cat confdefs.h >>conftest.$ac_ext
27858 cat >>conftest.$ac_ext <<_ACEOF
27859 /* end confdefs.h.  */
27860 #include <stdio.h>
27861 #ifdef HAVE_SUPPORTDEFS_H
27862 #include <SupportDefs.h>
27863 #endif
27864
27865 int
27866 main ()
27867 {
27868 if (sizeof ((uint64)))
27869           return 0;
27870   ;
27871   return 0;
27872 }
27873 _ACEOF
27874 rm -f conftest.$ac_objext
27875 if { (ac_try="$ac_compile"
27876 case "(($ac_try" in
27877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27878   *) ac_try_echo=$ac_try;;
27879 esac
27880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27881 $as_echo "$ac_try_echo") >&5
27882   (eval "$ac_compile") 2>conftest.er1
27883   ac_status=$?
27884   grep -v '^ *+' conftest.er1 >conftest.err
27885   rm -f conftest.er1
27886   cat conftest.err >&5
27887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27888   (exit $ac_status); } && {
27889          test -z "$ac_c_werror_flag" ||
27890          test ! -s conftest.err
27891        } && test -s conftest.$ac_objext; then
27892   :
27893 else
27894   $as_echo "$as_me: failed program was:" >&5
27895 sed 's/^/| /' conftest.$ac_ext >&5
27896
27897         ac_cv_type_uint64=yes
27898 fi
27899
27900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27901 else
27902   $as_echo "$as_me: failed program was:" >&5
27903 sed 's/^/| /' conftest.$ac_ext >&5
27904
27905
27906 fi
27907
27908 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27909 fi
27910 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
27911 $as_echo "$ac_cv_type_uint64" >&6; }
27912 if test "x$ac_cv_type_uint64" = x""yes; then
27913
27914 cat >>confdefs.h <<_ACEOF
27915 #define HAVE_UINT64 1
27916 _ACEOF
27917
27918
27919 fi
27920
27921
27922 # We also check for sig_atomic_t, which *should* be defined per ANSI
27923 # C, but is missing on some old platforms.
27924 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
27925 $as_echo_n "checking for sig_atomic_t... " >&6; }
27926 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
27927   $as_echo_n "(cached) " >&6
27928 else
27929   ac_cv_type_sig_atomic_t=no
27930 cat >conftest.$ac_ext <<_ACEOF
27931 /* confdefs.h.  */
27932 _ACEOF
27933 cat confdefs.h >>conftest.$ac_ext
27934 cat >>conftest.$ac_ext <<_ACEOF
27935 /* end confdefs.h.  */
27936 #include <signal.h>
27937
27938 int
27939 main ()
27940 {
27941 if (sizeof (sig_atomic_t))
27942        return 0;
27943   ;
27944   return 0;
27945 }
27946 _ACEOF
27947 rm -f conftest.$ac_objext
27948 if { (ac_try="$ac_compile"
27949 case "(($ac_try" in
27950   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27951   *) ac_try_echo=$ac_try;;
27952 esac
27953 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27954 $as_echo "$ac_try_echo") >&5
27955   (eval "$ac_compile") 2>conftest.er1
27956   ac_status=$?
27957   grep -v '^ *+' conftest.er1 >conftest.err
27958   rm -f conftest.er1
27959   cat conftest.err >&5
27960   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27961   (exit $ac_status); } && {
27962          test -z "$ac_c_werror_flag" ||
27963          test ! -s conftest.err
27964        } && test -s conftest.$ac_objext; then
27965   cat >conftest.$ac_ext <<_ACEOF
27966 /* confdefs.h.  */
27967 _ACEOF
27968 cat confdefs.h >>conftest.$ac_ext
27969 cat >>conftest.$ac_ext <<_ACEOF
27970 /* end confdefs.h.  */
27971 #include <signal.h>
27972
27973 int
27974 main ()
27975 {
27976 if (sizeof ((sig_atomic_t)))
27977           return 0;
27978   ;
27979   return 0;
27980 }
27981 _ACEOF
27982 rm -f conftest.$ac_objext
27983 if { (ac_try="$ac_compile"
27984 case "(($ac_try" in
27985   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27986   *) ac_try_echo=$ac_try;;
27987 esac
27988 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27989 $as_echo "$ac_try_echo") >&5
27990   (eval "$ac_compile") 2>conftest.er1
27991   ac_status=$?
27992   grep -v '^ *+' conftest.er1 >conftest.err
27993   rm -f conftest.er1
27994   cat conftest.err >&5
27995   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27996   (exit $ac_status); } && {
27997          test -z "$ac_c_werror_flag" ||
27998          test ! -s conftest.err
27999        } && test -s conftest.$ac_objext; then
28000   :
28001 else
28002   $as_echo "$as_me: failed program was:" >&5
28003 sed 's/^/| /' conftest.$ac_ext >&5
28004
28005         ac_cv_type_sig_atomic_t=yes
28006 fi
28007
28008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28009 else
28010   $as_echo "$as_me: failed program was:" >&5
28011 sed 's/^/| /' conftest.$ac_ext >&5
28012
28013
28014 fi
28015
28016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28017 fi
28018 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
28019 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
28020 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
28021
28022 cat >>confdefs.h <<_ACEOF
28023 #define HAVE_SIG_ATOMIC_T 1
28024 _ACEOF
28025
28026
28027 fi
28028
28029
28030
28031 if test "$PORTNAME" != "win32"
28032 then
28033 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
28034 $as_echo_n "checking for POSIX signal interface... " >&6; }
28035 if test "${pgac_cv_func_posix_signals+set}" = set; then
28036   $as_echo_n "(cached) " >&6
28037 else
28038   cat >conftest.$ac_ext <<_ACEOF
28039 /* confdefs.h.  */
28040 _ACEOF
28041 cat confdefs.h >>conftest.$ac_ext
28042 cat >>conftest.$ac_ext <<_ACEOF
28043 /* end confdefs.h.  */
28044 #include <signal.h>
28045
28046 int
28047 main ()
28048 {
28049 struct sigaction act, oact;
28050 sigemptyset(&act.sa_mask);
28051 act.sa_flags = SA_RESTART;
28052 sigaction(0, &act, &oact);
28053   ;
28054   return 0;
28055 }
28056 _ACEOF
28057 rm -f conftest.$ac_objext conftest$ac_exeext
28058 if { (ac_try="$ac_link"
28059 case "(($ac_try" in
28060   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28061   *) ac_try_echo=$ac_try;;
28062 esac
28063 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28064 $as_echo "$ac_try_echo") >&5
28065   (eval "$ac_link") 2>conftest.er1
28066   ac_status=$?
28067   grep -v '^ *+' conftest.er1 >conftest.err
28068   rm -f conftest.er1
28069   cat conftest.err >&5
28070   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28071   (exit $ac_status); } && {
28072          test -z "$ac_c_werror_flag" ||
28073          test ! -s conftest.err
28074        } && test -s conftest$ac_exeext && {
28075          test "$cross_compiling" = yes ||
28076          $as_test_x conftest$ac_exeext
28077        }; then
28078   pgac_cv_func_posix_signals=yes
28079 else
28080   $as_echo "$as_me: failed program was:" >&5
28081 sed 's/^/| /' conftest.$ac_ext >&5
28082
28083         pgac_cv_func_posix_signals=no
28084 fi
28085
28086 rm -rf conftest.dSYM
28087 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28088       conftest$ac_exeext conftest.$ac_ext
28089 fi
28090 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
28091 $as_echo "$pgac_cv_func_posix_signals" >&6; }
28092 if test x"$pgac_cv_func_posix_signals" = xyes ; then
28093
28094 cat >>confdefs.h <<\_ACEOF
28095 #define HAVE_POSIX_SIGNALS /**/
28096 _ACEOF
28097
28098 fi
28099 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
28100
28101 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
28102   { { $as_echo "$as_me:$LINENO: error:
28103 Thread-safety requires POSIX signals, which are not supported by this
28104 operating system;  use --disable-thread-safety to disable thread safety." >&5
28105 $as_echo "$as_me: error:
28106 Thread-safety requires POSIX signals, which are not supported by this
28107 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
28108    { (exit 1); exit 1; }; }
28109 fi
28110 fi
28111
28112 # SunOS doesn't handle negative byte comparisons properly with +/- return
28113 { $as_echo "$as_me:$LINENO: checking for working memcmp" >&5
28114 $as_echo_n "checking for working memcmp... " >&6; }
28115 if test "${ac_cv_func_memcmp_working+set}" = set; then
28116   $as_echo_n "(cached) " >&6
28117 else
28118   if test "$cross_compiling" = yes; then
28119   ac_cv_func_memcmp_working=no
28120 else
28121   cat >conftest.$ac_ext <<_ACEOF
28122 /* confdefs.h.  */
28123 _ACEOF
28124 cat confdefs.h >>conftest.$ac_ext
28125 cat >>conftest.$ac_ext <<_ACEOF
28126 /* end confdefs.h.  */
28127 $ac_includes_default
28128 int
28129 main ()
28130 {
28131
28132   /* Some versions of memcmp are not 8-bit clean.  */
28133   char c0 = '\100', c1 = '\200', c2 = '\201';
28134   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
28135     return 1;
28136
28137   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
28138      or more and with at least one buffer not starting on a 4-byte boundary.
28139      William Lewis provided this test program.   */
28140   {
28141     char foo[21];
28142     char bar[21];
28143     int i;
28144     for (i = 0; i < 4; i++)
28145       {
28146         char *a = foo + i;
28147         char *b = bar + i;
28148         strcpy (a, "--------01111111");
28149         strcpy (b, "--------10000000");
28150         if (memcmp (a, b, 16) >= 0)
28151           return 1;
28152       }
28153     return 0;
28154   }
28155
28156   ;
28157   return 0;
28158 }
28159 _ACEOF
28160 rm -f conftest$ac_exeext
28161 if { (ac_try="$ac_link"
28162 case "(($ac_try" in
28163   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28164   *) ac_try_echo=$ac_try;;
28165 esac
28166 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28167 $as_echo "$ac_try_echo") >&5
28168   (eval "$ac_link") 2>&5
28169   ac_status=$?
28170   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28171   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28172   { (case "(($ac_try" in
28173   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28174   *) ac_try_echo=$ac_try;;
28175 esac
28176 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28177 $as_echo "$ac_try_echo") >&5
28178   (eval "$ac_try") 2>&5
28179   ac_status=$?
28180   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28181   (exit $ac_status); }; }; then
28182   ac_cv_func_memcmp_working=yes
28183 else
28184   $as_echo "$as_me: program exited with status $ac_status" >&5
28185 $as_echo "$as_me: failed program was:" >&5
28186 sed 's/^/| /' conftest.$ac_ext >&5
28187
28188 ( exit $ac_status )
28189 ac_cv_func_memcmp_working=no
28190 fi
28191 rm -rf conftest.dSYM
28192 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28193 fi
28194
28195
28196 fi
28197 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
28198 $as_echo "$ac_cv_func_memcmp_working" >&6; }
28199 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
28200   *" memcmp.$ac_objext "* ) ;;
28201   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
28202  ;;
28203 esac
28204
28205
28206
28207
28208 # Select semaphore implementation type.
28209 if test "$PORTNAME" != "win32"; then
28210   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
28211
28212 cat >>confdefs.h <<\_ACEOF
28213 #define USE_NAMED_POSIX_SEMAPHORES 1
28214 _ACEOF
28215
28216     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28217   else
28218     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
28219
28220 cat >>confdefs.h <<\_ACEOF
28221 #define USE_UNNAMED_POSIX_SEMAPHORES 1
28222 _ACEOF
28223
28224       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28225     else
28226
28227 cat >>confdefs.h <<\_ACEOF
28228 #define USE_SYSV_SEMAPHORES 1
28229 _ACEOF
28230
28231       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
28232     fi
28233   fi
28234 else
28235
28236 cat >>confdefs.h <<\_ACEOF
28237 #define USE_WIN32_SEMAPHORES 1
28238 _ACEOF
28239
28240   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
28241 fi
28242
28243
28244 # Select shared-memory implementation type.
28245 if test "$PORTNAME" != "win32"; then
28246
28247 cat >>confdefs.h <<\_ACEOF
28248 #define USE_SYSV_SHARED_MEMORY 1
28249 _ACEOF
28250
28251   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
28252 else
28253
28254 cat >>confdefs.h <<\_ACEOF
28255 #define USE_WIN32_SHARED_MEMORY 1
28256 _ACEOF
28257
28258   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
28259 fi
28260
28261 # Select latch implementation type.
28262 if test "$PORTNAME" != "win32"; then
28263   LATCH_IMPLEMENTATION="src/backend/port/unix_latch.c"
28264 else
28265   LATCH_IMPLEMENTATION="src/backend/port/win32_latch.c"
28266 fi
28267
28268 # If not set in template file, set bytes to use libc memset()
28269 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
28270   MEMSET_LOOP_LIMIT=1024
28271 fi
28272
28273 cat >>confdefs.h <<_ACEOF
28274 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
28275 _ACEOF
28276
28277
28278
28279 if test "$enable_nls" = yes ; then
28280
28281   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
28282 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
28283 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28284   $as_echo_n "(cached) " >&6
28285 else
28286   ac_func_search_save_LIBS=$LIBS
28287 cat >conftest.$ac_ext <<_ACEOF
28288 /* confdefs.h.  */
28289 _ACEOF
28290 cat confdefs.h >>conftest.$ac_ext
28291 cat >>conftest.$ac_ext <<_ACEOF
28292 /* end confdefs.h.  */
28293
28294 /* Override any GCC internal prototype to avoid an error.
28295    Use char because int might match the return type of a GCC
28296    builtin and then its argument prototype would still apply.  */
28297 #ifdef __cplusplus
28298 extern "C"
28299 #endif
28300 char bind_textdomain_codeset ();
28301 int
28302 main ()
28303 {
28304 return bind_textdomain_codeset ();
28305   ;
28306   return 0;
28307 }
28308 _ACEOF
28309 for ac_lib in '' intl; do
28310   if test -z "$ac_lib"; then
28311     ac_res="none required"
28312   else
28313     ac_res=-l$ac_lib
28314     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
28315   fi
28316   rm -f conftest.$ac_objext conftest$ac_exeext
28317 if { (ac_try="$ac_link"
28318 case "(($ac_try" in
28319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28320   *) ac_try_echo=$ac_try;;
28321 esac
28322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28323 $as_echo "$ac_try_echo") >&5
28324   (eval "$ac_link") 2>conftest.er1
28325   ac_status=$?
28326   grep -v '^ *+' conftest.er1 >conftest.err
28327   rm -f conftest.er1
28328   cat conftest.err >&5
28329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28330   (exit $ac_status); } && {
28331          test -z "$ac_c_werror_flag" ||
28332          test ! -s conftest.err
28333        } && test -s conftest$ac_exeext && {
28334          test "$cross_compiling" = yes ||
28335          $as_test_x conftest$ac_exeext
28336        }; then
28337   ac_cv_search_bind_textdomain_codeset=$ac_res
28338 else
28339   $as_echo "$as_me: failed program was:" >&5
28340 sed 's/^/| /' conftest.$ac_ext >&5
28341
28342
28343 fi
28344
28345 rm -rf conftest.dSYM
28346 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28347       conftest$ac_exeext
28348   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28349   break
28350 fi
28351 done
28352 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28353   :
28354 else
28355   ac_cv_search_bind_textdomain_codeset=no
28356 fi
28357 rm conftest.$ac_ext
28358 LIBS=$ac_func_search_save_LIBS
28359 fi
28360 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
28361 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
28362 ac_res=$ac_cv_search_bind_textdomain_codeset
28363 if test "$ac_res" != no; then
28364   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28365
28366 else
28367   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
28368 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
28369    { (exit 1); exit 1; }; }
28370 fi
28371
28372   if test "${ac_cv_header_libintl_h+set}" = set; then
28373   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28374 $as_echo_n "checking for libintl.h... " >&6; }
28375 if test "${ac_cv_header_libintl_h+set}" = set; then
28376   $as_echo_n "(cached) " >&6
28377 fi
28378 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28379 $as_echo "$ac_cv_header_libintl_h" >&6; }
28380 else
28381   # Is the header compilable?
28382 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
28383 $as_echo_n "checking libintl.h usability... " >&6; }
28384 cat >conftest.$ac_ext <<_ACEOF
28385 /* confdefs.h.  */
28386 _ACEOF
28387 cat confdefs.h >>conftest.$ac_ext
28388 cat >>conftest.$ac_ext <<_ACEOF
28389 /* end confdefs.h.  */
28390 $ac_includes_default
28391 #include <libintl.h>
28392 _ACEOF
28393 rm -f conftest.$ac_objext
28394 if { (ac_try="$ac_compile"
28395 case "(($ac_try" in
28396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28397   *) ac_try_echo=$ac_try;;
28398 esac
28399 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28400 $as_echo "$ac_try_echo") >&5
28401   (eval "$ac_compile") 2>conftest.er1
28402   ac_status=$?
28403   grep -v '^ *+' conftest.er1 >conftest.err
28404   rm -f conftest.er1
28405   cat conftest.err >&5
28406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28407   (exit $ac_status); } && {
28408          test -z "$ac_c_werror_flag" ||
28409          test ! -s conftest.err
28410        } && test -s conftest.$ac_objext; then
28411   ac_header_compiler=yes
28412 else
28413   $as_echo "$as_me: failed program was:" >&5
28414 sed 's/^/| /' conftest.$ac_ext >&5
28415
28416         ac_header_compiler=no
28417 fi
28418
28419 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28420 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28421 $as_echo "$ac_header_compiler" >&6; }
28422
28423 # Is the header present?
28424 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
28425 $as_echo_n "checking libintl.h presence... " >&6; }
28426 cat >conftest.$ac_ext <<_ACEOF
28427 /* confdefs.h.  */
28428 _ACEOF
28429 cat confdefs.h >>conftest.$ac_ext
28430 cat >>conftest.$ac_ext <<_ACEOF
28431 /* end confdefs.h.  */
28432 #include <libintl.h>
28433 _ACEOF
28434 if { (ac_try="$ac_cpp conftest.$ac_ext"
28435 case "(($ac_try" in
28436   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28437   *) ac_try_echo=$ac_try;;
28438 esac
28439 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28440 $as_echo "$ac_try_echo") >&5
28441   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28442   ac_status=$?
28443   grep -v '^ *+' conftest.er1 >conftest.err
28444   rm -f conftest.er1
28445   cat conftest.err >&5
28446   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28447   (exit $ac_status); } >/dev/null && {
28448          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28449          test ! -s conftest.err
28450        }; then
28451   ac_header_preproc=yes
28452 else
28453   $as_echo "$as_me: failed program was:" >&5
28454 sed 's/^/| /' conftest.$ac_ext >&5
28455
28456   ac_header_preproc=no
28457 fi
28458
28459 rm -f conftest.err conftest.$ac_ext
28460 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28461 $as_echo "$ac_header_preproc" >&6; }
28462
28463 # So?  What about this header?
28464 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28465   yes:no: )
28466     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28467 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28468     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
28469 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
28470     ac_header_preproc=yes
28471     ;;
28472   no:yes:* )
28473     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
28474 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
28475     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
28476 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
28477     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
28478 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
28479     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
28480 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28481     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
28482 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
28483     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
28484 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
28485     ( cat <<\_ASBOX
28486 ## ---------------------------------------- ##
28487 ## Report this to pgsql-bugs@postgresql.org ##
28488 ## ---------------------------------------- ##
28489 _ASBOX
28490      ) | sed "s/^/$as_me: WARNING:     /" >&2
28491     ;;
28492 esac
28493 { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28494 $as_echo_n "checking for libintl.h... " >&6; }
28495 if test "${ac_cv_header_libintl_h+set}" = set; then
28496   $as_echo_n "(cached) " >&6
28497 else
28498   ac_cv_header_libintl_h=$ac_header_preproc
28499 fi
28500 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28501 $as_echo "$ac_cv_header_libintl_h" >&6; }
28502
28503 fi
28504 if test "x$ac_cv_header_libintl_h" = x""yes; then
28505   :
28506 else
28507   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
28508 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
28509    { (exit 1); exit 1; }; }
28510 fi
28511
28512
28513   for ac_prog in msgfmt
28514 do
28515   # Extract the first word of "$ac_prog", so it can be a program name with args.
28516 set dummy $ac_prog; ac_word=$2
28517 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28518 $as_echo_n "checking for $ac_word... " >&6; }
28519 if test "${ac_cv_prog_MSGFMT+set}" = set; then
28520   $as_echo_n "(cached) " >&6
28521 else
28522   if test -n "$MSGFMT"; then
28523   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
28524 else
28525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28526 for as_dir in $PATH
28527 do
28528   IFS=$as_save_IFS
28529   test -z "$as_dir" && as_dir=.
28530   for ac_exec_ext in '' $ac_executable_extensions; do
28531   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28532     ac_cv_prog_MSGFMT="$ac_prog"
28533     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28534     break 2
28535   fi
28536 done
28537 done
28538 IFS=$as_save_IFS
28539
28540 fi
28541 fi
28542 MSGFMT=$ac_cv_prog_MSGFMT
28543 if test -n "$MSGFMT"; then
28544   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
28545 $as_echo "$MSGFMT" >&6; }
28546 else
28547   { $as_echo "$as_me:$LINENO: result: no" >&5
28548 $as_echo "no" >&6; }
28549 fi
28550
28551
28552   test -n "$MSGFMT" && break
28553 done
28554
28555   if test -z "$MSGFMT"; then
28556     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
28557 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
28558    { (exit 1); exit 1; }; }
28559   fi
28560   for ac_prog in msgmerge
28561 do
28562   # Extract the first word of "$ac_prog", so it can be a program name with args.
28563 set dummy $ac_prog; ac_word=$2
28564 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28565 $as_echo_n "checking for $ac_word... " >&6; }
28566 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
28567   $as_echo_n "(cached) " >&6
28568 else
28569   if test -n "$MSGMERGE"; then
28570   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
28571 else
28572 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28573 for as_dir in $PATH
28574 do
28575   IFS=$as_save_IFS
28576   test -z "$as_dir" && as_dir=.
28577   for ac_exec_ext in '' $ac_executable_extensions; do
28578   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28579     ac_cv_prog_MSGMERGE="$ac_prog"
28580     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28581     break 2
28582   fi
28583 done
28584 done
28585 IFS=$as_save_IFS
28586
28587 fi
28588 fi
28589 MSGMERGE=$ac_cv_prog_MSGMERGE
28590 if test -n "$MSGMERGE"; then
28591   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
28592 $as_echo "$MSGMERGE" >&6; }
28593 else
28594   { $as_echo "$as_me:$LINENO: result: no" >&5
28595 $as_echo "no" >&6; }
28596 fi
28597
28598
28599   test -n "$MSGMERGE" && break
28600 done
28601
28602   for ac_prog in xgettext
28603 do
28604   # Extract the first word of "$ac_prog", so it can be a program name with args.
28605 set dummy $ac_prog; ac_word=$2
28606 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28607 $as_echo_n "checking for $ac_word... " >&6; }
28608 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
28609   $as_echo_n "(cached) " >&6
28610 else
28611   if test -n "$XGETTEXT"; then
28612   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
28613 else
28614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28615 for as_dir in $PATH
28616 do
28617   IFS=$as_save_IFS
28618   test -z "$as_dir" && as_dir=.
28619   for ac_exec_ext in '' $ac_executable_extensions; do
28620   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28621     ac_cv_prog_XGETTEXT="$ac_prog"
28622     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28623     break 2
28624   fi
28625 done
28626 done
28627 IFS=$as_save_IFS
28628
28629 fi
28630 fi
28631 XGETTEXT=$ac_cv_prog_XGETTEXT
28632 if test -n "$XGETTEXT"; then
28633   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
28634 $as_echo "$XGETTEXT" >&6; }
28635 else
28636   { $as_echo "$as_me:$LINENO: result: no" >&5
28637 $as_echo "no" >&6; }
28638 fi
28639
28640
28641   test -n "$XGETTEXT" && break
28642 done
28643
28644
28645 fi
28646
28647 # Check for Tcl configuration script tclConfig.sh
28648 if test "$with_tcl" = yes; then
28649     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
28650 do
28651   # Extract the first word of "$ac_prog", so it can be a program name with args.
28652 set dummy $ac_prog; ac_word=$2
28653 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28654 $as_echo_n "checking for $ac_word... " >&6; }
28655 if test "${ac_cv_path_TCLSH+set}" = set; then
28656   $as_echo_n "(cached) " >&6
28657 else
28658   case $TCLSH in
28659   [\\/]* | ?:[\\/]*)
28660   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
28661   ;;
28662   *)
28663   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28664 for as_dir in $PATH
28665 do
28666   IFS=$as_save_IFS
28667   test -z "$as_dir" && as_dir=.
28668   for ac_exec_ext in '' $ac_executable_extensions; do
28669   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28670     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
28671     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28672     break 2
28673   fi
28674 done
28675 done
28676 IFS=$as_save_IFS
28677
28678   ;;
28679 esac
28680 fi
28681 TCLSH=$ac_cv_path_TCLSH
28682 if test -n "$TCLSH"; then
28683   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
28684 $as_echo "$TCLSH" >&6; }
28685 else
28686   { $as_echo "$as_me:$LINENO: result: no" >&5
28687 $as_echo "no" >&6; }
28688 fi
28689
28690
28691   test -n "$TCLSH" && break
28692 done
28693
28694 if test x"$TCLSH" = x""; then
28695   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
28696 $as_echo "$as_me: error: Tcl shell not found" >&2;}
28697    { (exit 1); exit 1; }; }
28698 fi
28699
28700 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
28701 $as_echo_n "checking for tclConfig.sh... " >&6; }
28702 # Let user override test
28703 if test -z "$TCL_CONFIG_SH"; then
28704     pgac_test_dirs="$with_tclconfig"
28705
28706     set X $pgac_test_dirs; shift
28707     if test $# -eq 0; then
28708         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
28709 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
28710    { (exit 1); exit 1; }; }
28711         set X `echo 'puts $auto_path' | $TCLSH`; shift
28712     fi
28713
28714     for pgac_dir do
28715         if test -r "$pgac_dir/tclConfig.sh"; then
28716             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
28717             break
28718         fi
28719     done
28720 fi
28721
28722 if test -z "$TCL_CONFIG_SH"; then
28723     { $as_echo "$as_me:$LINENO: result: no" >&5
28724 $as_echo "no" >&6; }
28725     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
28726 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
28727    { (exit 1); exit 1; }; }
28728 else
28729     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
28730 $as_echo "$TCL_CONFIG_SH" >&6; }
28731 fi
28732
28733
28734
28735     . "$TCL_CONFIG_SH"
28736 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
28737 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
28738 eval TCL_LIBS=\"$TCL_LIBS\"
28739 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
28740 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
28741
28742         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
28743     ac_save_CPPFLAGS=$CPPFLAGS
28744     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
28745     if test "${ac_cv_header_tcl_h+set}" = set; then
28746   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28747 $as_echo_n "checking for tcl.h... " >&6; }
28748 if test "${ac_cv_header_tcl_h+set}" = set; then
28749   $as_echo_n "(cached) " >&6
28750 fi
28751 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28752 $as_echo "$ac_cv_header_tcl_h" >&6; }
28753 else
28754   # Is the header compilable?
28755 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
28756 $as_echo_n "checking tcl.h usability... " >&6; }
28757 cat >conftest.$ac_ext <<_ACEOF
28758 /* confdefs.h.  */
28759 _ACEOF
28760 cat confdefs.h >>conftest.$ac_ext
28761 cat >>conftest.$ac_ext <<_ACEOF
28762 /* end confdefs.h.  */
28763 $ac_includes_default
28764 #include <tcl.h>
28765 _ACEOF
28766 rm -f conftest.$ac_objext
28767 if { (ac_try="$ac_compile"
28768 case "(($ac_try" in
28769   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28770   *) ac_try_echo=$ac_try;;
28771 esac
28772 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28773 $as_echo "$ac_try_echo") >&5
28774   (eval "$ac_compile") 2>conftest.er1
28775   ac_status=$?
28776   grep -v '^ *+' conftest.er1 >conftest.err
28777   rm -f conftest.er1
28778   cat conftest.err >&5
28779   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28780   (exit $ac_status); } && {
28781          test -z "$ac_c_werror_flag" ||
28782          test ! -s conftest.err
28783        } && test -s conftest.$ac_objext; then
28784   ac_header_compiler=yes
28785 else
28786   $as_echo "$as_me: failed program was:" >&5
28787 sed 's/^/| /' conftest.$ac_ext >&5
28788
28789         ac_header_compiler=no
28790 fi
28791
28792 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28793 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28794 $as_echo "$ac_header_compiler" >&6; }
28795
28796 # Is the header present?
28797 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
28798 $as_echo_n "checking tcl.h presence... " >&6; }
28799 cat >conftest.$ac_ext <<_ACEOF
28800 /* confdefs.h.  */
28801 _ACEOF
28802 cat confdefs.h >>conftest.$ac_ext
28803 cat >>conftest.$ac_ext <<_ACEOF
28804 /* end confdefs.h.  */
28805 #include <tcl.h>
28806 _ACEOF
28807 if { (ac_try="$ac_cpp conftest.$ac_ext"
28808 case "(($ac_try" in
28809   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28810   *) ac_try_echo=$ac_try;;
28811 esac
28812 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28813 $as_echo "$ac_try_echo") >&5
28814   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28815   ac_status=$?
28816   grep -v '^ *+' conftest.er1 >conftest.err
28817   rm -f conftest.er1
28818   cat conftest.err >&5
28819   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28820   (exit $ac_status); } >/dev/null && {
28821          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28822          test ! -s conftest.err
28823        }; then
28824   ac_header_preproc=yes
28825 else
28826   $as_echo "$as_me: failed program was:" >&5
28827 sed 's/^/| /' conftest.$ac_ext >&5
28828
28829   ac_header_preproc=no
28830 fi
28831
28832 rm -f conftest.err conftest.$ac_ext
28833 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28834 $as_echo "$ac_header_preproc" >&6; }
28835
28836 # So?  What about this header?
28837 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28838   yes:no: )
28839     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28840 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28841     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
28842 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
28843     ac_header_preproc=yes
28844     ;;
28845   no:yes:* )
28846     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
28847 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
28848     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
28849 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
28850     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
28851 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
28852     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
28853 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28854     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
28855 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
28856     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
28857 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
28858     ( cat <<\_ASBOX
28859 ## ---------------------------------------- ##
28860 ## Report this to pgsql-bugs@postgresql.org ##
28861 ## ---------------------------------------- ##
28862 _ASBOX
28863      ) | sed "s/^/$as_me: WARNING:     /" >&2
28864     ;;
28865 esac
28866 { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28867 $as_echo_n "checking for tcl.h... " >&6; }
28868 if test "${ac_cv_header_tcl_h+set}" = set; then
28869   $as_echo_n "(cached) " >&6
28870 else
28871   ac_cv_header_tcl_h=$ac_header_preproc
28872 fi
28873 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28874 $as_echo "$ac_cv_header_tcl_h" >&6; }
28875
28876 fi
28877 if test "x$ac_cv_header_tcl_h" = x""yes; then
28878   :
28879 else
28880   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
28881 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
28882    { (exit 1); exit 1; }; }
28883 fi
28884
28885
28886     CPPFLAGS=$ac_save_CPPFLAGS
28887 fi
28888
28889 # check for <Python.h>
28890 if test "$with_python" = yes; then
28891   ac_save_CPPFLAGS=$CPPFLAGS
28892   CPPFLAGS="$python_includespec $CPPFLAGS"
28893   if test "${ac_cv_header_Python_h+set}" = set; then
28894   { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
28895 $as_echo_n "checking for Python.h... " >&6; }
28896 if test "${ac_cv_header_Python_h+set}" = set; then
28897   $as_echo_n "(cached) " >&6
28898 fi
28899 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
28900 $as_echo "$ac_cv_header_Python_h" >&6; }
28901 else
28902   # Is the header compilable?
28903 { $as_echo "$as_me:$LINENO: checking Python.h usability" >&5
28904 $as_echo_n "checking Python.h usability... " >&6; }
28905 cat >conftest.$ac_ext <<_ACEOF
28906 /* confdefs.h.  */
28907 _ACEOF
28908 cat confdefs.h >>conftest.$ac_ext
28909 cat >>conftest.$ac_ext <<_ACEOF
28910 /* end confdefs.h.  */
28911 $ac_includes_default
28912 #include <Python.h>
28913 _ACEOF
28914 rm -f conftest.$ac_objext
28915 if { (ac_try="$ac_compile"
28916 case "(($ac_try" in
28917   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28918   *) ac_try_echo=$ac_try;;
28919 esac
28920 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28921 $as_echo "$ac_try_echo") >&5
28922   (eval "$ac_compile") 2>conftest.er1
28923   ac_status=$?
28924   grep -v '^ *+' conftest.er1 >conftest.err
28925   rm -f conftest.er1
28926   cat conftest.err >&5
28927   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28928   (exit $ac_status); } && {
28929          test -z "$ac_c_werror_flag" ||
28930          test ! -s conftest.err
28931        } && test -s conftest.$ac_objext; then
28932   ac_header_compiler=yes
28933 else
28934   $as_echo "$as_me: failed program was:" >&5
28935 sed 's/^/| /' conftest.$ac_ext >&5
28936
28937         ac_header_compiler=no
28938 fi
28939
28940 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28941 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28942 $as_echo "$ac_header_compiler" >&6; }
28943
28944 # Is the header present?
28945 { $as_echo "$as_me:$LINENO: checking Python.h presence" >&5
28946 $as_echo_n "checking Python.h presence... " >&6; }
28947 cat >conftest.$ac_ext <<_ACEOF
28948 /* confdefs.h.  */
28949 _ACEOF
28950 cat confdefs.h >>conftest.$ac_ext
28951 cat >>conftest.$ac_ext <<_ACEOF
28952 /* end confdefs.h.  */
28953 #include <Python.h>
28954 _ACEOF
28955 if { (ac_try="$ac_cpp conftest.$ac_ext"
28956 case "(($ac_try" in
28957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28958   *) ac_try_echo=$ac_try;;
28959 esac
28960 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28961 $as_echo "$ac_try_echo") >&5
28962   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28963   ac_status=$?
28964   grep -v '^ *+' conftest.er1 >conftest.err
28965   rm -f conftest.er1
28966   cat conftest.err >&5
28967   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28968   (exit $ac_status); } >/dev/null && {
28969          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28970          test ! -s conftest.err
28971        }; then
28972   ac_header_preproc=yes
28973 else
28974   $as_echo "$as_me: failed program was:" >&5
28975 sed 's/^/| /' conftest.$ac_ext >&5
28976
28977   ac_header_preproc=no
28978 fi
28979
28980 rm -f conftest.err conftest.$ac_ext
28981 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28982 $as_echo "$ac_header_preproc" >&6; }
28983
28984 # So?  What about this header?
28985 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28986   yes:no: )
28987     { $as_echo "$as_me:$LINENO: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&5
28988 $as_echo "$as_me: WARNING: Python.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28989     { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the compiler's result" >&5
28990 $as_echo "$as_me: WARNING: Python.h: proceeding with the compiler's result" >&2;}
28991     ac_header_preproc=yes
28992     ;;
28993   no:yes:* )
28994     { $as_echo "$as_me:$LINENO: WARNING: Python.h: present but cannot be compiled" >&5
28995 $as_echo "$as_me: WARNING: Python.h: present but cannot be compiled" >&2;}
28996     { $as_echo "$as_me:$LINENO: WARNING: Python.h:     check for missing prerequisite headers?" >&5
28997 $as_echo "$as_me: WARNING: Python.h:     check for missing prerequisite headers?" >&2;}
28998     { $as_echo "$as_me:$LINENO: WARNING: Python.h: see the Autoconf documentation" >&5
28999 $as_echo "$as_me: WARNING: Python.h: see the Autoconf documentation" >&2;}
29000     { $as_echo "$as_me:$LINENO: WARNING: Python.h:     section \"Present But Cannot Be Compiled\"" >&5
29001 $as_echo "$as_me: WARNING: Python.h:     section \"Present But Cannot Be Compiled\"" >&2;}
29002     { $as_echo "$as_me:$LINENO: WARNING: Python.h: proceeding with the preprocessor's result" >&5
29003 $as_echo "$as_me: WARNING: Python.h: proceeding with the preprocessor's result" >&2;}
29004     { $as_echo "$as_me:$LINENO: WARNING: Python.h: in the future, the compiler will take precedence" >&5
29005 $as_echo "$as_me: WARNING: Python.h: in the future, the compiler will take precedence" >&2;}
29006     ( cat <<\_ASBOX
29007 ## ---------------------------------------- ##
29008 ## Report this to pgsql-bugs@postgresql.org ##
29009 ## ---------------------------------------- ##
29010 _ASBOX
29011      ) | sed "s/^/$as_me: WARNING:     /" >&2
29012     ;;
29013 esac
29014 { $as_echo "$as_me:$LINENO: checking for Python.h" >&5
29015 $as_echo_n "checking for Python.h... " >&6; }
29016 if test "${ac_cv_header_Python_h+set}" = set; then
29017   $as_echo_n "(cached) " >&6
29018 else
29019   ac_cv_header_Python_h=$ac_header_preproc
29020 fi
29021 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_Python_h" >&5
29022 $as_echo "$ac_cv_header_Python_h" >&6; }
29023
29024 fi
29025 if test "x$ac_cv_header_Python_h" = x""yes; then
29026   :
29027 else
29028   { { $as_echo "$as_me:$LINENO: error: header file <Python.h> is required for Python" >&5
29029 $as_echo "$as_me: error: header file <Python.h> is required for Python" >&2;}
29030    { (exit 1); exit 1; }; }
29031 fi
29032
29033
29034   CPPFLAGS=$ac_save_CPPFLAGS
29035 fi
29036
29037 #
29038 # Check for DocBook and tools
29039 #
29040 for ac_prog in onsgmls nsgmls
29041 do
29042   # Extract the first word of "$ac_prog", so it can be a program name with args.
29043 set dummy $ac_prog; ac_word=$2
29044 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29045 $as_echo_n "checking for $ac_word... " >&6; }
29046 if test "${ac_cv_prog_NSGMLS+set}" = set; then
29047   $as_echo_n "(cached) " >&6
29048 else
29049   if test -n "$NSGMLS"; then
29050   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
29051 else
29052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29053 for as_dir in $PATH
29054 do
29055   IFS=$as_save_IFS
29056   test -z "$as_dir" && as_dir=.
29057   for ac_exec_ext in '' $ac_executable_extensions; do
29058   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29059     ac_cv_prog_NSGMLS="$ac_prog"
29060     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29061     break 2
29062   fi
29063 done
29064 done
29065 IFS=$as_save_IFS
29066
29067 fi
29068 fi
29069 NSGMLS=$ac_cv_prog_NSGMLS
29070 if test -n "$NSGMLS"; then
29071   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
29072 $as_echo "$NSGMLS" >&6; }
29073 else
29074   { $as_echo "$as_me:$LINENO: result: no" >&5
29075 $as_echo "no" >&6; }
29076 fi
29077
29078
29079   test -n "$NSGMLS" && break
29080 done
29081
29082 for ac_prog in openjade jade
29083 do
29084   # Extract the first word of "$ac_prog", so it can be a program name with args.
29085 set dummy $ac_prog; ac_word=$2
29086 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29087 $as_echo_n "checking for $ac_word... " >&6; }
29088 if test "${ac_cv_prog_JADE+set}" = set; then
29089   $as_echo_n "(cached) " >&6
29090 else
29091   if test -n "$JADE"; then
29092   ac_cv_prog_JADE="$JADE" # Let the user override the test.
29093 else
29094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29095 for as_dir in $PATH
29096 do
29097   IFS=$as_save_IFS
29098   test -z "$as_dir" && as_dir=.
29099   for ac_exec_ext in '' $ac_executable_extensions; do
29100   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29101     ac_cv_prog_JADE="$ac_prog"
29102     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29103     break 2
29104   fi
29105 done
29106 done
29107 IFS=$as_save_IFS
29108
29109 fi
29110 fi
29111 JADE=$ac_cv_prog_JADE
29112 if test -n "$JADE"; then
29113   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
29114 $as_echo "$JADE" >&6; }
29115 else
29116   { $as_echo "$as_me:$LINENO: result: no" >&5
29117 $as_echo "no" >&6; }
29118 fi
29119
29120
29121   test -n "$JADE" && break
29122 done
29123
29124
29125 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
29126 $as_echo_n "checking for DocBook V4.2... " >&6; }
29127 if test "${pgac_cv_check_docbook+set}" = set; then
29128   $as_echo_n "(cached) " >&6
29129 else
29130   cat >conftest.sgml <<EOF
29131 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
29132 <book>
29133  <title>test</title>
29134  <chapter>
29135   <title>random</title>
29136    <sect1>
29137     <title>testsect</title>
29138     <para>text</para>
29139   </sect1>
29140  </chapter>
29141 </book>
29142 EOF
29143
29144 pgac_cv_check_docbook=no
29145
29146 if test -n "$NSGMLS"; then
29147   $NSGMLS -s conftest.sgml 1>&5 2>&1
29148   if test $? -eq 0; then
29149     pgac_cv_check_docbook=yes
29150   fi
29151 fi
29152 rm -f conftest.sgml
29153 fi
29154 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
29155 $as_echo "$pgac_cv_check_docbook" >&6; }
29156
29157 have_docbook=$pgac_cv_check_docbook
29158
29159
29160 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
29161 $as_echo_n "checking for DocBook stylesheets... " >&6; }
29162 if test "${pgac_cv_path_stylesheets+set}" = set; then
29163   $as_echo_n "(cached) " >&6
29164 else
29165   if test -n "$DOCBOOKSTYLE"; then
29166   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
29167 else
29168   for pgac_prefix in /usr /usr/local /opt /sw; do
29169     for pgac_infix in share lib; do
29170       for pgac_postfix in \
29171         sgml/stylesheets/nwalsh-modular \
29172         sgml/stylesheets/docbook \
29173         sgml/stylesheets/dsssl/docbook \
29174         sgml/docbook-dsssl \
29175         sgml/docbook/dsssl/modular \
29176         sgml/docbook/stylesheet/dsssl/modular \
29177         sgml/docbook/dsssl-stylesheets \
29178         sgml/dsssl/docbook-dsssl-nwalsh
29179       do
29180         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
29181         if test -r "$pgac_candidate/html/docbook.dsl" \
29182            && test -r "$pgac_candidate/print/docbook.dsl"
29183         then
29184           pgac_cv_path_stylesheets=$pgac_candidate
29185           break 3
29186         fi
29187       done
29188     done
29189   done
29190 fi
29191 fi
29192
29193 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
29194
29195 if test -n "$DOCBOOKSTYLE"; then
29196   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
29197 $as_echo "$DOCBOOKSTYLE" >&6; }
29198 else
29199   { $as_echo "$as_me:$LINENO: result: no" >&5
29200 $as_echo "no" >&6; }
29201 fi
29202 if test -n "$DOCBOOKSTYLE"; then
29203   for ac_prog in collateindex.pl
29204 do
29205   # Extract the first word of "$ac_prog", so it can be a program name with args.
29206 set dummy $ac_prog; ac_word=$2
29207 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29208 $as_echo_n "checking for $ac_word... " >&6; }
29209 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
29210   $as_echo_n "(cached) " >&6
29211 else
29212   case $COLLATEINDEX in
29213   [\\/]* | ?:[\\/]*)
29214   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
29215   ;;
29216   *)
29217   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29218 for as_dir in $DOCBOOKSTYLE/bin $PATH
29219 do
29220   IFS=$as_save_IFS
29221   test -z "$as_dir" && as_dir=.
29222   for ac_exec_ext in '' $ac_executable_extensions; do
29223   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29224     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
29225     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29226     break 2
29227   fi
29228 done
29229 done
29230 IFS=$as_save_IFS
29231
29232   ;;
29233 esac
29234 fi
29235 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
29236 if test -n "$COLLATEINDEX"; then
29237   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
29238 $as_echo "$COLLATEINDEX" >&6; }
29239 else
29240   { $as_echo "$as_me:$LINENO: result: no" >&5
29241 $as_echo "no" >&6; }
29242 fi
29243
29244
29245   test -n "$COLLATEINDEX" && break
29246 done
29247
29248 else
29249   for ac_prog in collateindex.pl
29250 do
29251   # Extract the first word of "$ac_prog", so it can be a program name with args.
29252 set dummy $ac_prog; ac_word=$2
29253 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29254 $as_echo_n "checking for $ac_word... " >&6; }
29255 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
29256   $as_echo_n "(cached) " >&6
29257 else
29258   case $COLLATEINDEX in
29259   [\\/]* | ?:[\\/]*)
29260   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
29261   ;;
29262   *)
29263   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29264 for as_dir in $PATH
29265 do
29266   IFS=$as_save_IFS
29267   test -z "$as_dir" && as_dir=.
29268   for ac_exec_ext in '' $ac_executable_extensions; do
29269   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29270     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
29271     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29272     break 2
29273   fi
29274 done
29275 done
29276 IFS=$as_save_IFS
29277
29278   ;;
29279 esac
29280 fi
29281 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
29282 if test -n "$COLLATEINDEX"; then
29283   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
29284 $as_echo "$COLLATEINDEX" >&6; }
29285 else
29286   { $as_echo "$as_me:$LINENO: result: no" >&5
29287 $as_echo "no" >&6; }
29288 fi
29289
29290
29291   test -n "$COLLATEINDEX" && break
29292 done
29293
29294 fi
29295 for ac_prog in xsltproc
29296 do
29297   # Extract the first word of "$ac_prog", so it can be a program name with args.
29298 set dummy $ac_prog; ac_word=$2
29299 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29300 $as_echo_n "checking for $ac_word... " >&6; }
29301 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
29302   $as_echo_n "(cached) " >&6
29303 else
29304   if test -n "$XSLTPROC"; then
29305   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
29306 else
29307 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29308 for as_dir in $PATH
29309 do
29310   IFS=$as_save_IFS
29311   test -z "$as_dir" && as_dir=.
29312   for ac_exec_ext in '' $ac_executable_extensions; do
29313   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29314     ac_cv_prog_XSLTPROC="$ac_prog"
29315     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29316     break 2
29317   fi
29318 done
29319 done
29320 IFS=$as_save_IFS
29321
29322 fi
29323 fi
29324 XSLTPROC=$ac_cv_prog_XSLTPROC
29325 if test -n "$XSLTPROC"; then
29326   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
29327 $as_echo "$XSLTPROC" >&6; }
29328 else
29329   { $as_echo "$as_me:$LINENO: result: no" >&5
29330 $as_echo "no" >&6; }
29331 fi
29332
29333
29334   test -n "$XSLTPROC" && break
29335 done
29336
29337 for ac_prog in osx sgml2xml sx
29338 do
29339   # Extract the first word of "$ac_prog", so it can be a program name with args.
29340 set dummy $ac_prog; ac_word=$2
29341 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29342 $as_echo_n "checking for $ac_word... " >&6; }
29343 if test "${ac_cv_prog_OSX+set}" = set; then
29344   $as_echo_n "(cached) " >&6
29345 else
29346   if test -n "$OSX"; then
29347   ac_cv_prog_OSX="$OSX" # Let the user override the test.
29348 else
29349 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29350 for as_dir in $PATH
29351 do
29352   IFS=$as_save_IFS
29353   test -z "$as_dir" && as_dir=.
29354   for ac_exec_ext in '' $ac_executable_extensions; do
29355   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29356     ac_cv_prog_OSX="$ac_prog"
29357     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29358     break 2
29359   fi
29360 done
29361 done
29362 IFS=$as_save_IFS
29363
29364 fi
29365 fi
29366 OSX=$ac_cv_prog_OSX
29367 if test -n "$OSX"; then
29368   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
29369 $as_echo "$OSX" >&6; }
29370 else
29371   { $as_echo "$as_me:$LINENO: result: no" >&5
29372 $as_echo "no" >&6; }
29373 fi
29374
29375
29376   test -n "$OSX" && break
29377 done
29378
29379
29380 # Thread testing
29381
29382 # We have to run the thread test near the end so we have all our symbols
29383 # defined.  Cross compiling throws a warning.
29384 #
29385 if test "$enable_thread_safety" = yes; then
29386 if test "$PORTNAME" != "win32"
29387 then
29388 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
29389 $as_echo_n "checking thread safety of required library functions... " >&6; }
29390
29391 _CFLAGS="$CFLAGS"
29392 _LIBS="$LIBS"
29393 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
29394 LIBS="$LIBS $PTHREAD_LIBS"
29395 if test "$cross_compiling" = yes; then
29396   { $as_echo "$as_me:$LINENO: result: maybe" >&5
29397 $as_echo "maybe" >&6; }
29398   { $as_echo "$as_me:$LINENO: WARNING:
29399 *** Skipping thread test program because of cross-compile build.
29400 *** Run the program in src/test/thread on the target machine.
29401 " >&5
29402 $as_echo "$as_me: WARNING:
29403 *** Skipping thread test program because of cross-compile build.
29404 *** Run the program in src/test/thread on the target machine.
29405 " >&2;}
29406 else
29407   cat >conftest.$ac_ext <<_ACEOF
29408 /* confdefs.h.  */
29409 _ACEOF
29410 cat confdefs.h >>conftest.$ac_ext
29411 cat >>conftest.$ac_ext <<_ACEOF
29412 /* end confdefs.h.  */
29413 #include "$srcdir/src/test/thread/thread_test.c"
29414 _ACEOF
29415 rm -f conftest$ac_exeext
29416 if { (ac_try="$ac_link"
29417 case "(($ac_try" in
29418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29419   *) ac_try_echo=$ac_try;;
29420 esac
29421 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29422 $as_echo "$ac_try_echo") >&5
29423   (eval "$ac_link") 2>&5
29424   ac_status=$?
29425   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29426   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29427   { (case "(($ac_try" in
29428   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29429   *) ac_try_echo=$ac_try;;
29430 esac
29431 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29432 $as_echo "$ac_try_echo") >&5
29433   (eval "$ac_try") 2>&5
29434   ac_status=$?
29435   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29436   (exit $ac_status); }; }; then
29437   { $as_echo "$as_me:$LINENO: result: yes" >&5
29438 $as_echo "yes" >&6; }
29439 else
29440   $as_echo "$as_me: program exited with status $ac_status" >&5
29441 $as_echo "$as_me: failed program was:" >&5
29442 sed 's/^/| /' conftest.$ac_ext >&5
29443
29444 ( exit $ac_status )
29445 { $as_echo "$as_me:$LINENO: result: no" >&5
29446 $as_echo "no" >&6; }
29447   { { $as_echo "$as_me:$LINENO: error: thread test program failed
29448 This platform is not thread-safe.  Check the file 'config.log' or compile
29449 and run src/test/thread/thread_test for the exact reason.
29450 Use --disable-thread-safety to disable thread safety." >&5
29451 $as_echo "$as_me: error: thread test program failed
29452 This platform is not thread-safe.  Check the file 'config.log' or compile
29453 and run src/test/thread/thread_test for the exact reason.
29454 Use --disable-thread-safety to disable thread safety." >&2;}
29455    { (exit 1); exit 1; }; }
29456 fi
29457 rm -rf conftest.dSYM
29458 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29459 fi
29460
29461
29462 CFLAGS="$_CFLAGS"
29463 LIBS="$_LIBS"
29464 else
29465 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
29466 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
29467 fi
29468 fi
29469
29470 # If compiler will take -Wl,--as-needed (or various platform-specific
29471 # spellings thereof) then add that to LDFLAGS.  This is much easier than
29472 # trying to filter LIBS to the minimum for each executable.
29473 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
29474 # libreadline; therefore we postpone testing it until we know what library
29475 # dependencies readline has.  The test code will try to link with $LIBS.
29476 if test "$with_readline" = yes; then
29477   link_test_func=readline
29478 else
29479   link_test_func=exit
29480 fi
29481
29482 if test "$PORTNAME" = "darwin"; then
29483   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
29484 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
29485 if test "${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+set}" = set; then
29486   $as_echo_n "(cached) " >&6
29487 else
29488   pgac_save_LDFLAGS=$LDFLAGS
29489 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
29490 if test "$cross_compiling" = yes; then
29491   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
29492 else
29493   cat >conftest.$ac_ext <<_ACEOF
29494 /* confdefs.h.  */
29495 _ACEOF
29496 cat confdefs.h >>conftest.$ac_ext
29497 cat >>conftest.$ac_ext <<_ACEOF
29498 /* end confdefs.h.  */
29499 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29500 int
29501 main ()
29502 {
29503
29504   ;
29505   return 0;
29506 }
29507 _ACEOF
29508 rm -f conftest$ac_exeext
29509 if { (ac_try="$ac_link"
29510 case "(($ac_try" in
29511   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29512   *) ac_try_echo=$ac_try;;
29513 esac
29514 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29515 $as_echo "$ac_try_echo") >&5
29516   (eval "$ac_link") 2>&5
29517   ac_status=$?
29518   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29519   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29520   { (case "(($ac_try" in
29521   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29522   *) ac_try_echo=$ac_try;;
29523 esac
29524 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29525 $as_echo "$ac_try_echo") >&5
29526   (eval "$ac_try") 2>&5
29527   ac_status=$?
29528   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29529   (exit $ac_status); }; }; then
29530   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
29531 else
29532   $as_echo "$as_me: program exited with status $ac_status" >&5
29533 $as_echo "$as_me: failed program was:" >&5
29534 sed 's/^/| /' conftest.$ac_ext >&5
29535
29536 ( exit $ac_status )
29537 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
29538 fi
29539 rm -rf conftest.dSYM
29540 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29541 fi
29542
29543
29544 LDFLAGS="$pgac_save_LDFLAGS"
29545 fi
29546 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
29547 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
29548 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
29549   LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
29550 fi
29551
29552 elif test "$PORTNAME" = "openbsd"; then
29553   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-Bdynamic" >&5
29554 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
29555 if test "${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+set}" = set; then
29556   $as_echo_n "(cached) " >&6
29557 else
29558   pgac_save_LDFLAGS=$LDFLAGS
29559 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
29560 if test "$cross_compiling" = yes; then
29561   pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
29562 else
29563   cat >conftest.$ac_ext <<_ACEOF
29564 /* confdefs.h.  */
29565 _ACEOF
29566 cat confdefs.h >>conftest.$ac_ext
29567 cat >>conftest.$ac_ext <<_ACEOF
29568 /* end confdefs.h.  */
29569 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29570 int
29571 main ()
29572 {
29573
29574   ;
29575   return 0;
29576 }
29577 _ACEOF
29578 rm -f conftest$ac_exeext
29579 if { (ac_try="$ac_link"
29580 case "(($ac_try" in
29581   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29582   *) ac_try_echo=$ac_try;;
29583 esac
29584 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29585 $as_echo "$ac_try_echo") >&5
29586   (eval "$ac_link") 2>&5
29587   ac_status=$?
29588   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29589   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29590   { (case "(($ac_try" in
29591   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29592   *) ac_try_echo=$ac_try;;
29593 esac
29594 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29595 $as_echo "$ac_try_echo") >&5
29596   (eval "$ac_try") 2>&5
29597   ac_status=$?
29598   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29599   (exit $ac_status); }; }; then
29600   pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
29601 else
29602   $as_echo "$as_me: program exited with status $ac_status" >&5
29603 $as_echo "$as_me: failed program was:" >&5
29604 sed 's/^/| /' conftest.$ac_ext >&5
29605
29606 ( exit $ac_status )
29607 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
29608 fi
29609 rm -rf conftest.dSYM
29610 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29611 fi
29612
29613
29614 LDFLAGS="$pgac_save_LDFLAGS"
29615 fi
29616 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
29617 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
29618 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
29619   LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
29620 fi
29621
29622 else
29623   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,--as-needed" >&5
29624 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
29625 if test "${pgac_cv_prog_cc_ldflags__Wl___as_needed+set}" = set; then
29626   $as_echo_n "(cached) " >&6
29627 else
29628   pgac_save_LDFLAGS=$LDFLAGS
29629 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
29630 if test "$cross_compiling" = yes; then
29631   pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
29632 else
29633   cat >conftest.$ac_ext <<_ACEOF
29634 /* confdefs.h.  */
29635 _ACEOF
29636 cat confdefs.h >>conftest.$ac_ext
29637 cat >>conftest.$ac_ext <<_ACEOF
29638 /* end confdefs.h.  */
29639 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29640 int
29641 main ()
29642 {
29643
29644   ;
29645   return 0;
29646 }
29647 _ACEOF
29648 rm -f conftest$ac_exeext
29649 if { (ac_try="$ac_link"
29650 case "(($ac_try" in
29651   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29652   *) ac_try_echo=$ac_try;;
29653 esac
29654 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29655 $as_echo "$ac_try_echo") >&5
29656   (eval "$ac_link") 2>&5
29657   ac_status=$?
29658   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29659   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29660   { (case "(($ac_try" in
29661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29662   *) ac_try_echo=$ac_try;;
29663 esac
29664 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29665 $as_echo "$ac_try_echo") >&5
29666   (eval "$ac_try") 2>&5
29667   ac_status=$?
29668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29669   (exit $ac_status); }; }; then
29670   pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
29671 else
29672   $as_echo "$as_me: program exited with status $ac_status" >&5
29673 $as_echo "$as_me: failed program was:" >&5
29674 sed 's/^/| /' conftest.$ac_ext >&5
29675
29676 ( exit $ac_status )
29677 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
29678 fi
29679 rm -rf conftest.dSYM
29680 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29681 fi
29682
29683
29684 LDFLAGS="$pgac_save_LDFLAGS"
29685 fi
29686 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
29687 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
29688 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
29689   LDFLAGS="$LDFLAGS -Wl,--as-needed"
29690 fi
29691
29692 fi
29693
29694
29695 # Begin output steps
29696
29697 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
29698 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
29699 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
29700 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
29701 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
29702 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
29703
29704 # Create compiler version string
29705 if test x"$GCC" = x"yes" ; then
29706   cc_string="GCC `${CC} --version | sed q`"
29707 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
29708   cc_string=`${CC} -V 2>&1 | sed q`
29709 else
29710   cc_string=$CC
29711 fi
29712
29713
29714 cat >>confdefs.h <<_ACEOF
29715 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
29716 _ACEOF
29717
29718
29719 # Supply a numeric version string for use by 3rd party add-ons
29720 # awk -F is a regex on some platforms, and not on others, so make "." a tab
29721 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
29722 tr '.' '        ' |
29723 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
29724
29725 cat >>confdefs.h <<_ACEOF
29726 #define PG_VERSION_NUM $PG_VERSION_NUM
29727 _ACEOF
29728
29729
29730
29731 # prepare build tree if outside source tree
29732 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
29733 # Note 2: /bin/pwd might be better than shell's built-in at getting
29734 #         a symlink-free name.
29735 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
29736   vpath_build=no
29737 else
29738   vpath_build=yes
29739   if test "$no_create" != yes; then
29740     $as_echo_n "preparing build tree... " >&6
29741     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
29742     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
29743       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
29744 $as_echo "$as_me: error: failed" >&2;}
29745    { (exit 1); exit 1; }; }
29746     { $as_echo "$as_me:$LINENO: result: done" >&5
29747 $as_echo "done" >&6; }
29748   fi
29749 fi
29750
29751
29752
29753 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
29754
29755
29756 ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
29757
29758
29759 if test "$PORTNAME" = "win32"; then
29760 ac_config_commands="$ac_config_commands check_win32_symlinks"
29761
29762 fi
29763
29764 ac_config_headers="$ac_config_headers src/include/pg_config.h"
29765
29766
29767 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
29768
29769
29770 cat >confcache <<\_ACEOF
29771 # This file is a shell script that caches the results of configure
29772 # tests run on this system so they can be shared between configure
29773 # scripts and configure runs, see configure's option --config-cache.
29774 # It is not useful on other systems.  If it contains results you don't
29775 # want to keep, you may remove or edit it.
29776 #
29777 # config.status only pays attention to the cache file if you give it
29778 # the --recheck option to rerun configure.
29779 #
29780 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29781 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29782 # following values.
29783
29784 _ACEOF
29785
29786 # The following way of writing the cache mishandles newlines in values,
29787 # but we know of no workaround that is simple, portable, and efficient.
29788 # So, we kill variables containing newlines.
29789 # Ultrix sh set writes to stderr and can't be redirected directly,
29790 # and sets the high bit in the cache file unless we assign to the vars.
29791 (
29792   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29793     eval ac_val=\$$ac_var
29794     case $ac_val in #(
29795     *${as_nl}*)
29796       case $ac_var in #(
29797       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
29798 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29799       esac
29800       case $ac_var in #(
29801       _ | IFS | as_nl) ;; #(
29802       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29803       *) $as_unset $ac_var ;;
29804       esac ;;
29805     esac
29806   done
29807
29808   (set) 2>&1 |
29809     case $as_nl`(ac_space=' '; set) 2>&1` in #(
29810     *${as_nl}ac_space=\ *)
29811       # `set' does not quote correctly, so add quotes (double-quote
29812       # substitution turns \\\\ into \\, and sed turns \\ into \).
29813       sed -n \
29814         "s/'/'\\\\''/g;
29815           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29816       ;; #(
29817     *)
29818       # `set' quotes correctly as required by POSIX, so do not add quotes.
29819       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29820       ;;
29821     esac |
29822     sort
29823 ) |
29824   sed '
29825      /^ac_cv_env_/b end
29826      t clear
29827      :clear
29828      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29829      t end
29830      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29831      :end' >>confcache
29832 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29833   if test -w "$cache_file"; then
29834     test "x$cache_file" != "x/dev/null" &&
29835       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
29836 $as_echo "$as_me: updating cache $cache_file" >&6;}
29837     cat confcache >$cache_file
29838   else
29839     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
29840 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29841   fi
29842 fi
29843 rm -f confcache
29844
29845 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29846 # Let make expand exec_prefix.
29847 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29848
29849 DEFS=-DHAVE_CONFIG_H
29850
29851 ac_libobjs=
29852 ac_ltlibobjs=
29853 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29854   # 1. Remove the extension, and $U if already installed.
29855   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29856   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29857   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
29858   #    will be set to the directory where LIBOBJS objects are built.
29859   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29860   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
29861 done
29862 LIBOBJS=$ac_libobjs
29863
29864 LTLIBOBJS=$ac_ltlibobjs
29865
29866
29867
29868
29869 : ${CONFIG_STATUS=./config.status}
29870 ac_write_fail=0
29871 ac_clean_files_save=$ac_clean_files
29872 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29873 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
29874 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29875 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29876 #! $SHELL
29877 # Generated by $as_me.
29878 # Run this file to recreate the current configuration.
29879 # Compiler output produced by configure, useful for debugging
29880 # configure, is in config.log if it exists.
29881
29882 debug=false
29883 ac_cs_recheck=false
29884 ac_cs_silent=false
29885 SHELL=\${CONFIG_SHELL-$SHELL}
29886 _ACEOF
29887
29888 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29889 ## --------------------- ##
29890 ## M4sh Initialization.  ##
29891 ## --------------------- ##
29892
29893 # Be more Bourne compatible
29894 DUALCASE=1; export DUALCASE # for MKS sh
29895 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
29896   emulate sh
29897   NULLCMD=:
29898   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29899   # is contrary to our usage.  Disable this feature.
29900   alias -g '${1+"$@"}'='"$@"'
29901   setopt NO_GLOB_SUBST
29902 else
29903   case `(set -o) 2>/dev/null` in
29904   *posix*) set -o posix ;;
29905 esac
29906
29907 fi
29908
29909
29910
29911
29912 # PATH needs CR
29913 # Avoid depending upon Character Ranges.
29914 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29915 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29916 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29917 as_cr_digits='0123456789'
29918 as_cr_alnum=$as_cr_Letters$as_cr_digits
29919
29920 as_nl='
29921 '
29922 export as_nl
29923 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29924 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29925 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29926 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29927 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29928   as_echo='printf %s\n'
29929   as_echo_n='printf %s'
29930 else
29931   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29932     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29933     as_echo_n='/usr/ucb/echo -n'
29934   else
29935     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29936     as_echo_n_body='eval
29937       arg=$1;
29938       case $arg in
29939       *"$as_nl"*)
29940         expr "X$arg" : "X\\(.*\\)$as_nl";
29941         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29942       esac;
29943       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29944     '
29945     export as_echo_n_body
29946     as_echo_n='sh -c $as_echo_n_body as_echo'
29947   fi
29948   export as_echo_body
29949   as_echo='sh -c $as_echo_body as_echo'
29950 fi
29951
29952 # The user is always right.
29953 if test "${PATH_SEPARATOR+set}" != set; then
29954   PATH_SEPARATOR=:
29955   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29956     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29957       PATH_SEPARATOR=';'
29958   }
29959 fi
29960
29961 # Support unset when possible.
29962 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
29963   as_unset=unset
29964 else
29965   as_unset=false
29966 fi
29967
29968
29969 # IFS
29970 # We need space, tab and new line, in precisely that order.  Quoting is
29971 # there to prevent editors from complaining about space-tab.
29972 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29973 # splitting by setting IFS to empty value.)
29974 IFS=" ""        $as_nl"
29975
29976 # Find who we are.  Look in the path if we contain no directory separator.
29977 case $0 in
29978   *[\\/]* ) as_myself=$0 ;;
29979   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29980 for as_dir in $PATH
29981 do
29982   IFS=$as_save_IFS
29983   test -z "$as_dir" && as_dir=.
29984   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29985 done
29986 IFS=$as_save_IFS
29987
29988      ;;
29989 esac
29990 # We did not find ourselves, most probably we were run as `sh COMMAND'
29991 # in which case we are not to be found in the path.
29992 if test "x$as_myself" = x; then
29993   as_myself=$0
29994 fi
29995 if test ! -f "$as_myself"; then
29996   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29997   { (exit 1); exit 1; }
29998 fi
29999
30000 # Work around bugs in pre-3.0 UWIN ksh.
30001 for as_var in ENV MAIL MAILPATH
30002 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
30003 done
30004 PS1='$ '
30005 PS2='> '
30006 PS4='+ '
30007
30008 # NLS nuisances.
30009 LC_ALL=C
30010 export LC_ALL
30011 LANGUAGE=C
30012 export LANGUAGE
30013
30014 # Required to use basename.
30015 if expr a : '\(a\)' >/dev/null 2>&1 &&
30016    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30017   as_expr=expr
30018 else
30019   as_expr=false
30020 fi
30021
30022 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
30023   as_basename=basename
30024 else
30025   as_basename=false
30026 fi
30027
30028
30029 # Name of the executable.
30030 as_me=`$as_basename -- "$0" ||
30031 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
30032          X"$0" : 'X\(//\)$' \| \
30033          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
30034 $as_echo X/"$0" |
30035     sed '/^.*\/\([^/][^/]*\)\/*$/{
30036             s//\1/
30037             q
30038           }
30039           /^X\/\(\/\/\)$/{
30040             s//\1/
30041             q
30042           }
30043           /^X\/\(\/\).*/{
30044             s//\1/
30045             q
30046           }
30047           s/.*/./; q'`
30048
30049 # CDPATH.
30050 $as_unset CDPATH
30051
30052
30053
30054   as_lineno_1=$LINENO
30055   as_lineno_2=$LINENO
30056   test "x$as_lineno_1" != "x$as_lineno_2" &&
30057   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
30058
30059   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
30060   # uniformly replaced by the line number.  The first 'sed' inserts a
30061   # line-number line after each line using $LINENO; the second 'sed'
30062   # does the real work.  The second script uses 'N' to pair each
30063   # line-number line with the line containing $LINENO, and appends
30064   # trailing '-' during substitution so that $LINENO is not a special
30065   # case at line end.
30066   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
30067   # scripts with optimization help from Paolo Bonzini.  Blame Lee
30068   # E. McMahon (1931-1989) for sed's syntax.  :-)
30069   sed -n '
30070     p
30071     /[$]LINENO/=
30072   ' <$as_myself |
30073     sed '
30074       s/[$]LINENO.*/&-/
30075       t lineno
30076       b
30077       :lineno
30078       N
30079       :loop
30080       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
30081       t loop
30082       s/-\n.*//
30083     ' >$as_me.lineno &&
30084   chmod +x "$as_me.lineno" ||
30085     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
30086    { (exit 1); exit 1; }; }
30087
30088   # Don't try to exec as it changes $[0], causing all sort of problems
30089   # (the dirname of $[0] is not the place where we might find the
30090   # original and so on.  Autoconf is especially sensitive to this).
30091   . "./$as_me.lineno"
30092   # Exit status is that of the last command.
30093   exit
30094 }
30095
30096
30097 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
30098   as_dirname=dirname
30099 else
30100   as_dirname=false
30101 fi
30102
30103 ECHO_C= ECHO_N= ECHO_T=
30104 case `echo -n x` in
30105 -n*)
30106   case `echo 'x\c'` in
30107   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
30108   *)   ECHO_C='\c';;
30109   esac;;
30110 *)
30111   ECHO_N='-n';;
30112 esac
30113 if expr a : '\(a\)' >/dev/null 2>&1 &&
30114    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30115   as_expr=expr
30116 else
30117   as_expr=false
30118 fi
30119
30120 rm -f conf$$ conf$$.exe conf$$.file
30121 if test -d conf$$.dir; then
30122   rm -f conf$$.dir/conf$$.file
30123 else
30124   rm -f conf$$.dir
30125   mkdir conf$$.dir 2>/dev/null
30126 fi
30127 if (echo >conf$$.file) 2>/dev/null; then
30128   if ln -s conf$$.file conf$$ 2>/dev/null; then
30129     as_ln_s='ln -s'
30130     # ... but there are two gotchas:
30131     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
30132     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
30133     # In both cases, we have to default to `cp -p'.
30134     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
30135       as_ln_s='cp -p'
30136   elif ln conf$$.file conf$$ 2>/dev/null; then
30137     as_ln_s=ln
30138   else
30139     as_ln_s='cp -p'
30140   fi
30141 else
30142   as_ln_s='cp -p'
30143 fi
30144 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
30145 rmdir conf$$.dir 2>/dev/null
30146
30147 if mkdir -p . 2>/dev/null; then
30148   as_mkdir_p=:
30149 else
30150   test -d ./-p && rmdir ./-p
30151   as_mkdir_p=false
30152 fi
30153
30154 if test -x / >/dev/null 2>&1; then
30155   as_test_x='test -x'
30156 else
30157   if ls -dL / >/dev/null 2>&1; then
30158     as_ls_L_option=L
30159   else
30160     as_ls_L_option=
30161   fi
30162   as_test_x='
30163     eval sh -c '\''
30164       if test -d "$1"; then
30165         test -d "$1/.";
30166       else
30167         case $1 in
30168         -*)set "./$1";;
30169         esac;
30170         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
30171         ???[sx]*):;;*)false;;esac;fi
30172     '\'' sh
30173   '
30174 fi
30175 as_executable_p=$as_test_x
30176
30177 # Sed expression to map a string onto a valid CPP name.
30178 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
30179
30180 # Sed expression to map a string onto a valid variable name.
30181 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
30182
30183
30184 exec 6>&1
30185
30186 # Save the log message, to keep $[0] and so on meaningful, and to
30187 # report actual input values of CONFIG_FILES etc. instead of their
30188 # values after options handling.
30189 ac_log="
30190 This file was extended by PostgreSQL $as_me 9.1devel, which was
30191 generated by GNU Autoconf 2.63.  Invocation command line was
30192
30193   CONFIG_FILES    = $CONFIG_FILES
30194   CONFIG_HEADERS  = $CONFIG_HEADERS
30195   CONFIG_LINKS    = $CONFIG_LINKS
30196   CONFIG_COMMANDS = $CONFIG_COMMANDS
30197   $ $0 $@
30198
30199 on `(hostname || uname -n) 2>/dev/null | sed 1q`
30200 "
30201
30202 _ACEOF
30203
30204 case $ac_config_files in *"
30205 "*) set x $ac_config_files; shift; ac_config_files=$*;;
30206 esac
30207
30208 case $ac_config_headers in *"
30209 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30210 esac
30211
30212
30213 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30214 # Files that config.status was made for.
30215 config_files="$ac_config_files"
30216 config_headers="$ac_config_headers"
30217 config_links="$ac_config_links"
30218 config_commands="$ac_config_commands"
30219
30220 _ACEOF
30221
30222 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30223 ac_cs_usage="\
30224 \`$as_me' instantiates files from templates according to the
30225 current configuration.
30226
30227 Usage: $0 [OPTION]... [FILE]...
30228
30229   -h, --help       print this help, then exit
30230   -V, --version    print version number and configuration settings, then exit
30231   -q, --quiet, --silent
30232                    do not print progress messages
30233   -d, --debug      don't remove temporary files
30234       --recheck    update $as_me by reconfiguring in the same conditions
30235       --file=FILE[:TEMPLATE]
30236                    instantiate the configuration file FILE
30237       --header=FILE[:TEMPLATE]
30238                    instantiate the configuration header FILE
30239
30240 Configuration files:
30241 $config_files
30242
30243 Configuration headers:
30244 $config_headers
30245
30246 Configuration links:
30247 $config_links
30248
30249 Configuration commands:
30250 $config_commands
30251
30252 Report bugs to <bug-autoconf@gnu.org>."
30253
30254 _ACEOF
30255 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30256 ac_cs_version="\\
30257 PostgreSQL config.status 9.1devel
30258 configured by $0, generated by GNU Autoconf 2.63,
30259   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
30260
30261 Copyright (C) 2008 Free Software Foundation, Inc.
30262 This config.status script is free software; the Free Software Foundation
30263 gives unlimited permission to copy, distribute and modify it."
30264
30265 ac_pwd='$ac_pwd'
30266 srcdir='$srcdir'
30267 MKDIR_P='$MKDIR_P'
30268 AWK='$AWK'
30269 test -n "\$AWK" || AWK=awk
30270 _ACEOF
30271
30272 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30273 # The default lists apply if the user does not specify any file.
30274 ac_need_defaults=:
30275 while test $# != 0
30276 do
30277   case $1 in
30278   --*=*)
30279     ac_option=`expr "X$1" : 'X\([^=]*\)='`
30280     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30281     ac_shift=:
30282     ;;
30283   *)
30284     ac_option=$1
30285     ac_optarg=$2
30286     ac_shift=shift
30287     ;;
30288   esac
30289
30290   case $ac_option in
30291   # Handling of the options.
30292   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30293     ac_cs_recheck=: ;;
30294   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30295     $as_echo "$ac_cs_version"; exit ;;
30296   --debug | --debu | --deb | --de | --d | -d )
30297     debug=: ;;
30298   --file | --fil | --fi | --f )
30299     $ac_shift
30300     case $ac_optarg in
30301     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30302     esac
30303     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
30304     ac_need_defaults=false;;
30305   --header | --heade | --head | --hea )
30306     $ac_shift
30307     case $ac_optarg in
30308     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30309     esac
30310     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
30311     ac_need_defaults=false;;
30312   --he | --h)
30313     # Conflict between --help and --header
30314     { $as_echo "$as_me: error: ambiguous option: $1
30315 Try \`$0 --help' for more information." >&2
30316    { (exit 1); exit 1; }; };;
30317   --help | --hel | -h )
30318     $as_echo "$ac_cs_usage"; exit ;;
30319   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30320   | -silent | --silent | --silen | --sile | --sil | --si | --s)
30321     ac_cs_silent=: ;;
30322
30323   # This is an error.
30324   -*) { $as_echo "$as_me: error: unrecognized option: $1
30325 Try \`$0 --help' for more information." >&2
30326    { (exit 1); exit 1; }; } ;;
30327
30328   *) ac_config_targets="$ac_config_targets $1"
30329      ac_need_defaults=false ;;
30330
30331   esac
30332   shift
30333 done
30334
30335 ac_configure_extra_args=
30336
30337 if $ac_cs_silent; then
30338   exec 6>/dev/null
30339   ac_configure_extra_args="$ac_configure_extra_args --silent"
30340 fi
30341
30342 _ACEOF
30343 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30344 if \$ac_cs_recheck; then
30345   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30346   shift
30347   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30348   CONFIG_SHELL='$SHELL'
30349   export CONFIG_SHELL
30350   exec "\$@"
30351 fi
30352
30353 _ACEOF
30354 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30355 exec 5>>config.log
30356 {
30357   echo
30358   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30359 ## Running $as_me. ##
30360 _ASBOX
30361   $as_echo "$ac_log"
30362 } >&5
30363
30364 _ACEOF
30365 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30366 _ACEOF
30367
30368 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30369
30370 # Handling of arguments.
30371 for ac_config_target in $ac_config_targets
30372 do
30373   case $ac_config_target in
30374     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
30375     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
30376     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
30377     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
30378     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
30379     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
30380     "src/backend/port/pg_latch.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION}" ;;
30381     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
30382     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
30383     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
30384     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
30385     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
30386     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
30387
30388   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
30389 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
30390    { (exit 1); exit 1; }; };;
30391   esac
30392 done
30393
30394
30395 # If the user did not use the arguments to specify the items to instantiate,
30396 # then the envvar interface is used.  Set only those that are not.
30397 # We use the long form for the default assignment because of an extremely
30398 # bizarre bug on SunOS 4.1.3.
30399 if $ac_need_defaults; then
30400   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30401   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30402   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
30403   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30404 fi
30405
30406 # Have a temporary directory for convenience.  Make it in the build tree
30407 # simply because there is no reason against having it here, and in addition,
30408 # creating and moving files from /tmp can sometimes cause problems.
30409 # Hook for its removal unless debugging.
30410 # Note that there is a small window in which the directory will not be cleaned:
30411 # after its creation but before its name has been assigned to `$tmp'.
30412 $debug ||
30413 {
30414   tmp=
30415   trap 'exit_status=$?
30416   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
30417 ' 0
30418   trap '{ (exit 1); exit 1; }' 1 2 13 15
30419 }
30420 # Create a (secure) tmp directory for tmp files.
30421
30422 {
30423   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
30424   test -n "$tmp" && test -d "$tmp"
30425 }  ||
30426 {
30427   tmp=./conf$$-$RANDOM
30428   (umask 077 && mkdir "$tmp")
30429 } ||
30430 {
30431    $as_echo "$as_me: cannot create a temporary directory in ." >&2
30432    { (exit 1); exit 1; }
30433 }
30434
30435 # Set up the scripts for CONFIG_FILES section.
30436 # No need to generate them if there are no CONFIG_FILES.
30437 # This happens for instance with `./config.status config.h'.
30438 if test -n "$CONFIG_FILES"; then
30439
30440
30441 ac_cr='\r'
30442 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30443 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30444   ac_cs_awk_cr='\\r'
30445 else
30446   ac_cs_awk_cr=$ac_cr
30447 fi
30448
30449 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30450 _ACEOF
30451
30452
30453 {
30454   echo "cat >conf$$subs.awk <<_ACEOF" &&
30455   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30456   echo "_ACEOF"
30457 } >conf$$subs.sh ||
30458   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30459 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30460    { (exit 1); exit 1; }; }
30461 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30462 ac_delim='%!_!# '
30463 for ac_last_try in false false false false false :; do
30464   . ./conf$$subs.sh ||
30465     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30466 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30467    { (exit 1); exit 1; }; }
30468
30469   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30470   if test $ac_delim_n = $ac_delim_num; then
30471     break
30472   elif $ac_last_try; then
30473     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30474 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30475    { (exit 1); exit 1; }; }
30476   else
30477     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30478   fi
30479 done
30480 rm -f conf$$subs.sh
30481
30482 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30483 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30484 _ACEOF
30485 sed -n '
30486 h
30487 s/^/S["/; s/!.*/"]=/
30488 p
30489 g
30490 s/^[^!]*!//
30491 :repl
30492 t repl
30493 s/'"$ac_delim"'$//
30494 t delim
30495 :nl
30496 h
30497 s/\(.\{148\}\).*/\1/
30498 t more1
30499 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30500 p
30501 n
30502 b repl
30503 :more1
30504 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30505 p
30506 g
30507 s/.\{148\}//
30508 t nl
30509 :delim
30510 h
30511 s/\(.\{148\}\).*/\1/
30512 t more2
30513 s/["\\]/\\&/g; s/^/"/; s/$/"/
30514 p
30515 b
30516 :more2
30517 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30518 p
30519 g
30520 s/.\{148\}//
30521 t delim
30522 ' <conf$$subs.awk | sed '
30523 /^[^""]/{
30524   N
30525   s/\n//
30526 }
30527 ' >>$CONFIG_STATUS || ac_write_fail=1
30528 rm -f conf$$subs.awk
30529 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30530 _ACAWK
30531 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30532   for (key in S) S_is_set[key] = 1
30533   FS = "\a"
30534
30535 }
30536 {
30537   line = $ 0
30538   nfields = split(line, field, "@")
30539   substed = 0
30540   len = length(field[1])
30541   for (i = 2; i < nfields; i++) {
30542     key = field[i]
30543     keylen = length(key)
30544     if (S_is_set[key]) {
30545       value = S[key]
30546       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30547       len += length(value) + length(field[++i])
30548       substed = 1
30549     } else
30550       len += 1 + keylen
30551   }
30552
30553   print line
30554 }
30555
30556 _ACAWK
30557 _ACEOF
30558 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30559 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30560   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30561 else
30562   cat
30563 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30564   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
30565 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
30566    { (exit 1); exit 1; }; }
30567 _ACEOF
30568
30569 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30570 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30571 # trailing colons and then remove the whole line if VPATH becomes empty
30572 # (actually we leave an empty line to preserve line numbers).
30573 if test "x$srcdir" = x.; then
30574   ac_vpsub='/^[  ]*VPATH[        ]*=/{
30575 s/:*\$(srcdir):*/:/
30576 s/:*\${srcdir}:*/:/
30577 s/:*@srcdir@:*/:/
30578 s/^\([^=]*=[     ]*\):*/\1/
30579 s/:*$//
30580 s/^[^=]*=[       ]*$//
30581 }'
30582 fi
30583
30584 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30585 fi # test -n "$CONFIG_FILES"
30586
30587 # Set up the scripts for CONFIG_HEADERS section.
30588 # No need to generate them if there are no CONFIG_HEADERS.
30589 # This happens for instance with `./config.status Makefile'.
30590 if test -n "$CONFIG_HEADERS"; then
30591 cat >"$tmp/defines.awk" <<\_ACAWK ||
30592 BEGIN {
30593 _ACEOF
30594
30595 # Transform confdefs.h into an awk script `defines.awk', embedded as
30596 # here-document in config.status, that substitutes the proper values into
30597 # config.h.in to produce config.h.
30598
30599 # Create a delimiter string that does not exist in confdefs.h, to ease
30600 # handling of long lines.
30601 ac_delim='%!_!# '
30602 for ac_last_try in false false :; do
30603   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30604   if test -z "$ac_t"; then
30605     break
30606   elif $ac_last_try; then
30607     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
30608 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
30609    { (exit 1); exit 1; }; }
30610   else
30611     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30612   fi
30613 done
30614
30615 # For the awk script, D is an array of macro values keyed by name,
30616 # likewise P contains macro parameters if any.  Preserve backslash
30617 # newline sequences.
30618
30619 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30620 sed -n '
30621 s/.\{148\}/&'"$ac_delim"'/g
30622 t rset
30623 :rset
30624 s/^[     ]*#[    ]*define[       ][      ]*/ /
30625 t def
30626 d
30627 :def
30628 s/\\$//
30629 t bsnl
30630 s/["\\]/\\&/g
30631 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30632 D["\1"]=" \3"/p
30633 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
30634 d
30635 :bsnl
30636 s/["\\]/\\&/g
30637 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30638 D["\1"]=" \3\\\\\\n"\\/p
30639 t cont
30640 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30641 t cont
30642 d
30643 :cont
30644 n
30645 s/.\{148\}/&'"$ac_delim"'/g
30646 t clear
30647 :clear
30648 s/\\$//
30649 t bsnlc
30650 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30651 d
30652 :bsnlc
30653 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30654 b cont
30655 ' <confdefs.h | sed '
30656 s/'"$ac_delim"'/"\\\
30657 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30658
30659 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30660   for (key in D) D_is_set[key] = 1
30661   FS = "\a"
30662 }
30663 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30664   line = \$ 0
30665   split(line, arg, " ")
30666   if (arg[1] == "#") {
30667     defundef = arg[2]
30668     mac1 = arg[3]
30669   } else {
30670     defundef = substr(arg[1], 2)
30671     mac1 = arg[2]
30672   }
30673   split(mac1, mac2, "(") #)
30674   macro = mac2[1]
30675   prefix = substr(line, 1, index(line, defundef) - 1)
30676   if (D_is_set[macro]) {
30677     # Preserve the white space surrounding the "#".
30678     print prefix "define", macro P[macro] D[macro]
30679     next
30680   } else {
30681     # Replace #undef with comments.  This is necessary, for example,
30682     # in the case of _POSIX_SOURCE, which is predefined and required
30683     # on some systems where configure will not decide to define it.
30684     if (defundef == "undef") {
30685       print "/*", prefix defundef, macro, "*/"
30686       next
30687     }
30688   }
30689 }
30690 { print }
30691 _ACAWK
30692 _ACEOF
30693 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30694   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
30695 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
30696    { (exit 1); exit 1; }; }
30697 fi # test -n "$CONFIG_HEADERS"
30698
30699
30700 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
30701 shift
30702 for ac_tag
30703 do
30704   case $ac_tag in
30705   :[FHLC]) ac_mode=$ac_tag; continue;;
30706   esac
30707   case $ac_mode$ac_tag in
30708   :[FHL]*:*);;
30709   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
30710 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
30711    { (exit 1); exit 1; }; };;
30712   :[FH]-) ac_tag=-:-;;
30713   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30714   esac
30715   ac_save_IFS=$IFS
30716   IFS=:
30717   set x $ac_tag
30718   IFS=$ac_save_IFS
30719   shift
30720   ac_file=$1
30721   shift
30722
30723   case $ac_mode in
30724   :L) ac_source=$1;;
30725   :[FH])
30726     ac_file_inputs=
30727     for ac_f
30728     do
30729       case $ac_f in
30730       -) ac_f="$tmp/stdin";;
30731       *) # Look for the file first in the build tree, then in the source tree
30732          # (if the path is not absolute).  The absolute path cannot be DOS-style,
30733          # because $ac_f cannot contain `:'.
30734          test -f "$ac_f" ||
30735            case $ac_f in
30736            [\\/$]*) false;;
30737            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30738            esac ||
30739            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
30740 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
30741    { (exit 1); exit 1; }; };;
30742       esac
30743       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30744       ac_file_inputs="$ac_file_inputs '$ac_f'"
30745     done
30746
30747     # Let's still pretend it is `configure' which instantiates (i.e., don't
30748     # use $as_me), people would be surprised to read:
30749     #    /* config.h.  Generated by config.status.  */
30750     configure_input='Generated from '`
30751           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30752         `' by configure.'
30753     if test x"$ac_file" != x-; then
30754       configure_input="$ac_file.  $configure_input"
30755       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
30756 $as_echo "$as_me: creating $ac_file" >&6;}
30757     fi
30758     # Neutralize special characters interpreted by sed in replacement strings.
30759     case $configure_input in #(
30760     *\&* | *\|* | *\\* )
30761        ac_sed_conf_input=`$as_echo "$configure_input" |
30762        sed 's/[\\\\&|]/\\\\&/g'`;; #(
30763     *) ac_sed_conf_input=$configure_input;;
30764     esac
30765
30766     case $ac_tag in
30767     *:-:* | *:-) cat >"$tmp/stdin" \
30768       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30769 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30770    { (exit 1); exit 1; }; } ;;
30771     esac
30772     ;;
30773   esac
30774
30775   ac_dir=`$as_dirname -- "$ac_file" ||
30776 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30777          X"$ac_file" : 'X\(//\)[^/]' \| \
30778          X"$ac_file" : 'X\(//\)$' \| \
30779          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30780 $as_echo X"$ac_file" |
30781     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30782             s//\1/
30783             q
30784           }
30785           /^X\(\/\/\)[^/].*/{
30786             s//\1/
30787             q
30788           }
30789           /^X\(\/\/\)$/{
30790             s//\1/
30791             q
30792           }
30793           /^X\(\/\).*/{
30794             s//\1/
30795             q
30796           }
30797           s/.*/./; q'`
30798   { as_dir="$ac_dir"
30799   case $as_dir in #(
30800   -*) as_dir=./$as_dir;;
30801   esac
30802   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
30803     as_dirs=
30804     while :; do
30805       case $as_dir in #(
30806       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30807       *) as_qdir=$as_dir;;
30808       esac
30809       as_dirs="'$as_qdir' $as_dirs"
30810       as_dir=`$as_dirname -- "$as_dir" ||
30811 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30812          X"$as_dir" : 'X\(//\)[^/]' \| \
30813          X"$as_dir" : 'X\(//\)$' \| \
30814          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30815 $as_echo X"$as_dir" |
30816     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30817             s//\1/
30818             q
30819           }
30820           /^X\(\/\/\)[^/].*/{
30821             s//\1/
30822             q
30823           }
30824           /^X\(\/\/\)$/{
30825             s//\1/
30826             q
30827           }
30828           /^X\(\/\).*/{
30829             s//\1/
30830             q
30831           }
30832           s/.*/./; q'`
30833       test -d "$as_dir" && break
30834     done
30835     test -z "$as_dirs" || eval "mkdir $as_dirs"
30836   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
30837 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
30838    { (exit 1); exit 1; }; }; }
30839   ac_builddir=.
30840
30841 case "$ac_dir" in
30842 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30843 *)
30844   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30845   # A ".." for each directory in $ac_dir_suffix.
30846   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30847   case $ac_top_builddir_sub in
30848   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30849   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30850   esac ;;
30851 esac
30852 ac_abs_top_builddir=$ac_pwd
30853 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30854 # for backward compatibility:
30855 ac_top_builddir=$ac_top_build_prefix
30856
30857 case $srcdir in
30858   .)  # We are building in place.
30859     ac_srcdir=.
30860     ac_top_srcdir=$ac_top_builddir_sub
30861     ac_abs_top_srcdir=$ac_pwd ;;
30862   [\\/]* | ?:[\\/]* )  # Absolute name.
30863     ac_srcdir=$srcdir$ac_dir_suffix;
30864     ac_top_srcdir=$srcdir
30865     ac_abs_top_srcdir=$srcdir ;;
30866   *) # Relative name.
30867     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30868     ac_top_srcdir=$ac_top_build_prefix$srcdir
30869     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30870 esac
30871 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30872
30873
30874   case $ac_mode in
30875   :F)
30876   #
30877   # CONFIG_FILE
30878   #
30879
30880   ac_MKDIR_P=$MKDIR_P
30881   case $MKDIR_P in
30882   [\\/$]* | ?:[\\/]* ) ;;
30883   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30884   esac
30885 _ACEOF
30886
30887 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30888 # If the template does not know about datarootdir, expand it.
30889 # FIXME: This hack should be removed a few years after 2.60.
30890 ac_datarootdir_hack=; ac_datarootdir_seen=
30891
30892 ac_sed_dataroot='
30893 /datarootdir/ {
30894   p
30895   q
30896 }
30897 /@datadir@/p
30898 /@docdir@/p
30899 /@infodir@/p
30900 /@localedir@/p
30901 /@mandir@/p
30902 '
30903 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30904 *datarootdir*) ac_datarootdir_seen=yes;;
30905 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30906   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30907 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30908 _ACEOF
30909 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30910   ac_datarootdir_hack='
30911   s&@datadir@&$datadir&g
30912   s&@docdir@&$docdir&g
30913   s&@infodir@&$infodir&g
30914   s&@localedir@&$localedir&g
30915   s&@mandir@&$mandir&g
30916     s&\\\${datarootdir}&$datarootdir&g' ;;
30917 esac
30918 _ACEOF
30919
30920 # Neutralize VPATH when `$srcdir' = `.'.
30921 # Shell code in configure.ac might set extrasub.
30922 # FIXME: do we really want to maintain this feature?
30923 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30924 ac_sed_extra="$ac_vpsub
30925 $extrasub
30926 _ACEOF
30927 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30928 :t
30929 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30930 s|@configure_input@|$ac_sed_conf_input|;t t
30931 s&@top_builddir@&$ac_top_builddir_sub&;t t
30932 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30933 s&@srcdir@&$ac_srcdir&;t t
30934 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30935 s&@top_srcdir@&$ac_top_srcdir&;t t
30936 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30937 s&@builddir@&$ac_builddir&;t t
30938 s&@abs_builddir@&$ac_abs_builddir&;t t
30939 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30940 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30941 $ac_datarootdir_hack
30942 "
30943 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
30944   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30945 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30946    { (exit 1); exit 1; }; }
30947
30948 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30949   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30950   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30951   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30952 which seems to be undefined.  Please make sure it is defined." >&5
30953 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30954 which seems to be undefined.  Please make sure it is defined." >&2;}
30955
30956   rm -f "$tmp/stdin"
30957   case $ac_file in
30958   -) cat "$tmp/out" && rm -f "$tmp/out";;
30959   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30960   esac \
30961   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30962 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30963    { (exit 1); exit 1; }; }
30964  ;;
30965   :H)
30966   #
30967   # CONFIG_HEADER
30968   #
30969   if test x"$ac_file" != x-; then
30970     {
30971       $as_echo "/* $configure_input  */" \
30972       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30973     } >"$tmp/config.h" \
30974       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30975 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30976    { (exit 1); exit 1; }; }
30977     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30978       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
30979 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30980     else
30981       rm -f "$ac_file"
30982       mv "$tmp/config.h" "$ac_file" \
30983         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30984 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30985    { (exit 1); exit 1; }; }
30986     fi
30987   else
30988     $as_echo "/* $configure_input  */" \
30989       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30990       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
30991 $as_echo "$as_me: error: could not create -" >&2;}
30992    { (exit 1); exit 1; }; }
30993   fi
30994  ;;
30995   :L)
30996   #
30997   # CONFIG_LINK
30998   #
30999
31000   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
31001     :
31002   else
31003     # Prefer the file from the source tree if names are identical.
31004     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
31005       ac_source=$srcdir/$ac_source
31006     fi
31007
31008     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
31009 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
31010
31011     if test ! -r "$ac_source"; then
31012       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
31013 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
31014    { (exit 1); exit 1; }; }
31015     fi
31016     rm -f "$ac_file"
31017
31018     # Try a relative symlink, then a hard link, then a copy.
31019     case $srcdir in
31020     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
31021         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
31022     esac
31023     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
31024       ln "$ac_source" "$ac_file" 2>/dev/null ||
31025       cp -p "$ac_source" "$ac_file" ||
31026       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
31027 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
31028    { (exit 1); exit 1; }; }
31029   fi
31030  ;;
31031   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
31032 $as_echo "$as_me: executing $ac_file commands" >&6;}
31033  ;;
31034   esac
31035
31036
31037   case $ac_file$ac_mode in
31038     "check_win32_symlinks":C)
31039 # Links sometimes fail undetected on Mingw -
31040 # so here we detect it and warn the user
31041 for FILE in $CONFIG_LINKS
31042  do
31043         # test -e works for symlinks in the MinGW console
31044         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
31045 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
31046  done
31047  ;;
31048     "src/include/pg_config.h":H)
31049 # Update timestamp for pg_config.h (see Makefile.global)
31050 echo >src/include/stamp-h
31051  ;;
31052     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
31053
31054   esac
31055 done # for ac_tag
31056
31057
31058 { (exit 0); exit 0; }
31059 _ACEOF
31060 chmod +x $CONFIG_STATUS
31061 ac_clean_files=$ac_clean_files_save
31062
31063 test $ac_write_fail = 0 ||
31064   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
31065 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
31066    { (exit 1); exit 1; }; }
31067
31068
31069 # configure is writing to config.log, and then calls config.status.
31070 # config.status does its own redirection, appending to config.log.
31071 # Unfortunately, on DOS this fails, as config.log is still kept open
31072 # by configure, so config.status won't be able to write to it; its
31073 # output is simply discarded.  So we exec the FD to /dev/null,
31074 # effectively closing config.log, so it can be properly (re)opened and
31075 # appended to by config.status.  When coming back to configure, we
31076 # need to make the FD available again.
31077 if test "$no_create" != yes; then
31078   ac_cs_success=:
31079   ac_config_status_args=
31080   test "$silent" = yes &&
31081     ac_config_status_args="$ac_config_status_args --quiet"
31082   exec 5>/dev/null
31083   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
31084   exec 5>>config.log
31085   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
31086   # would make configure fail if this is the last instruction.
31087   $ac_cs_success || { (exit 1); exit 1; }
31088 fi
31089 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
31090   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
31091 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
31092 fi
31093