OSDN Git Service

Replace self written 'long long int' configure test by standard 'AC_TYPE_LONG_LONG_IN...
[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.0beta1.
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-2010, 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.0beta1'
602 PACKAGE_STRING='PostgreSQL 9.0beta1'
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_IPV6
671 LIBOBJS
672 OSSP_UUID_LIBS
673 ZIC
674 python_additional_libs
675 python_libspec
676 python_libdir
677 python_includespec
678 python_configdir
679 python_version
680 python_majorversion
681 PYTHON
682 perl_embed_ldflags
683 perl_useshrplib
684 perl_privlibexp
685 perl_archlibexp
686 PERL
687 FLEXFLAGS
688 FLEX
689 BISONFLAGS
690 BISON
691 MKDIR_P
692 AWK
693 LN_S
694 TAR
695 WINDRES
696 DLLWRAP
697 DLLTOOL
698 AR
699 STRIP_SHARED_LIB
700 STRIP_STATIC_LIB
701 STRIP
702 RANLIB
703 ld_R_works
704 with_gnu_ld
705 LD
706 LDFLAGS_SL
707 ELF_SYS
708 EGREP
709 GREP
710 with_zlib
711 with_system_tzdata
712 with_libxslt
713 with_libxml
714 XML2_CONFIG
715 with_ossp_uuid
716 with_openssl
717 with_bonjour
718 with_ldap
719 with_pam
720 krb_srvtab
721 with_krb5
722 with_gssapi
723 with_python
724 with_perl
725 with_tcl
726 enable_thread_safety
727 INCLUDES
728 autodepend
729 TAS
730 GCC
731 CPP
732 SUN_STUDIO_CC
733 OBJEXT
734 EXEEXT
735 ac_ct_CC
736 CPPFLAGS
737 LDFLAGS
738 CFLAGS
739 CC
740 enable_dtrace
741 DTRACEFLAGS
742 DTRACE
743 enable_coverage
744 GENHTML
745 LCOV
746 GCOV
747 enable_profiling
748 enable_debug
749 enable_rpath
750 enable_shared
751 default_port
752 WANTED_LANGUAGES
753 enable_nls
754 PORTNAME
755 host_os
756 host_vendor
757 host_cpu
758 host
759 build_os
760 build_vendor
761 build_cpu
762 build
763 PG_MAJORVERSION
764 configure_args
765 target_alias
766 host_alias
767 build_alias
768 LIBS
769 ECHO_T
770 ECHO_N
771 ECHO_C
772 DEFS
773 mandir
774 localedir
775 libdir
776 psdir
777 pdfdir
778 dvidir
779 htmldir
780 infodir
781 docdir
782 oldincludedir
783 includedir
784 localstatedir
785 sharedstatedir
786 sysconfdir
787 datadir
788 datarootdir
789 libexecdir
790 sbindir
791 bindir
792 program_transform_name
793 prefix
794 exec_prefix
795 PACKAGE_BUGREPORT
796 PACKAGE_STRING
797 PACKAGE_VERSION
798 PACKAGE_TARNAME
799 PACKAGE_NAME
800 PATH_SEPARATOR
801 SHELL'
802 ac_subst_files=''
803 ac_user_opts='
804 enable_option_checking
805 with_template
806 with_includes
807 with_libraries
808 with_libs
809 enable_integer_datetimes
810 enable_nls
811 with_pgport
812 enable_shared
813 enable_rpath
814 enable_spinlocks
815 enable_debug
816 enable_profiling
817 enable_coverage
818 enable_dtrace
819 with_blocksize
820 with_segsize
821 with_wal_blocksize
822 with_wal_segsize
823 with_CC
824 enable_depend
825 enable_cassert
826 enable_thread_safety
827 with_tcl
828 with_tclconfig
829 with_perl
830 with_python
831 with_gssapi
832 with_krb5
833 with_krb_srvnam
834 with_pam
835 with_ldap
836 with_bonjour
837 with_openssl
838 with_readline
839 with_libedit_preferred
840 with_ossp_uuid
841 with_libxml
842 with_libxslt
843 with_system_tzdata
844 with_zlib
845 with_gnu_ld
846 enable_largefile
847 enable_float4_byval
848 enable_float8_byval
849 '
850       ac_precious_vars='build_alias
851 host_alias
852 target_alias
853 CC
854 CFLAGS
855 LDFLAGS
856 LIBS
857 CPPFLAGS
858 CPP
859 LDFLAGS_SL
860 DOCBOOKSTYLE'
861
862
863 # Initialize some variables set by options.
864 ac_init_help=
865 ac_init_version=false
866 ac_unrecognized_opts=
867 ac_unrecognized_sep=
868 # The variables have the same names as the options, with
869 # dashes changed to underlines.
870 cache_file=/dev/null
871 exec_prefix=NONE
872 no_create=
873 no_recursion=
874 prefix=NONE
875 program_prefix=NONE
876 program_suffix=NONE
877 program_transform_name=s,x,x,
878 silent=
879 site=
880 srcdir=
881 verbose=
882 x_includes=NONE
883 x_libraries=NONE
884
885 # Installation directory options.
886 # These are left unexpanded so users can "make install exec_prefix=/foo"
887 # and all the variables that are supposed to be based on exec_prefix
888 # by default will actually change.
889 # Use braces instead of parens because sh, perl, etc. also accept them.
890 # (The list follows the same order as the GNU Coding Standards.)
891 bindir='${exec_prefix}/bin'
892 sbindir='${exec_prefix}/sbin'
893 libexecdir='${exec_prefix}/libexec'
894 datarootdir='${prefix}/share'
895 datadir='${datarootdir}'
896 sysconfdir='${prefix}/etc'
897 sharedstatedir='${prefix}/com'
898 localstatedir='${prefix}/var'
899 includedir='${prefix}/include'
900 oldincludedir='/usr/include'
901 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
902 infodir='${datarootdir}/info'
903 htmldir='${docdir}'
904 dvidir='${docdir}'
905 pdfdir='${docdir}'
906 psdir='${docdir}'
907 libdir='${exec_prefix}/lib'
908 localedir='${datarootdir}/locale'
909 mandir='${datarootdir}/man'
910
911 ac_prev=
912 ac_dashdash=
913 for ac_option
914 do
915   # If the previous option needs an argument, assign it.
916   if test -n "$ac_prev"; then
917     eval $ac_prev=\$ac_option
918     ac_prev=
919     continue
920   fi
921
922   case $ac_option in
923   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
924   *)    ac_optarg=yes ;;
925   esac
926
927   # Accept the important Cygnus configure options, so we can diagnose typos.
928
929   case $ac_dashdash$ac_option in
930   --)
931     ac_dashdash=yes ;;
932
933   -bindir | --bindir | --bindi | --bind | --bin | --bi)
934     ac_prev=bindir ;;
935   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
936     bindir=$ac_optarg ;;
937
938   -build | --build | --buil | --bui | --bu)
939     ac_prev=build_alias ;;
940   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
941     build_alias=$ac_optarg ;;
942
943   -cache-file | --cache-file | --cache-fil | --cache-fi \
944   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
945     ac_prev=cache_file ;;
946   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
947   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
948     cache_file=$ac_optarg ;;
949
950   --config-cache | -C)
951     cache_file=config.cache ;;
952
953   -datadir | --datadir | --datadi | --datad)
954     ac_prev=datadir ;;
955   -datadir=* | --datadir=* | --datadi=* | --datad=*)
956     datadir=$ac_optarg ;;
957
958   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
959   | --dataroo | --dataro | --datar)
960     ac_prev=datarootdir ;;
961   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
962   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
963     datarootdir=$ac_optarg ;;
964
965   -disable-* | --disable-*)
966     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
967     # Reject names that are not valid shell variable names.
968     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
969       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
970    { (exit 1); exit 1; }; }
971     ac_useropt_orig=$ac_useropt
972     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
973     case $ac_user_opts in
974       *"
975 "enable_$ac_useropt"
976 "*) ;;
977       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
978          ac_unrecognized_sep=', ';;
979     esac
980     eval enable_$ac_useropt=no ;;
981
982   -docdir | --docdir | --docdi | --doc | --do)
983     ac_prev=docdir ;;
984   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
985     docdir=$ac_optarg ;;
986
987   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
988     ac_prev=dvidir ;;
989   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
990     dvidir=$ac_optarg ;;
991
992   -enable-* | --enable-*)
993     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
994     # Reject names that are not valid shell variable names.
995     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
996       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
997    { (exit 1); exit 1; }; }
998     ac_useropt_orig=$ac_useropt
999     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1000     case $ac_user_opts in
1001       *"
1002 "enable_$ac_useropt"
1003 "*) ;;
1004       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1005          ac_unrecognized_sep=', ';;
1006     esac
1007     eval enable_$ac_useropt=\$ac_optarg ;;
1008
1009   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1010   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1011   | --exec | --exe | --ex)
1012     ac_prev=exec_prefix ;;
1013   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1014   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1015   | --exec=* | --exe=* | --ex=*)
1016     exec_prefix=$ac_optarg ;;
1017
1018   -gas | --gas | --ga | --g)
1019     # Obsolete; use --with-gas.
1020     with_gas=yes ;;
1021
1022   -help | --help | --hel | --he | -h)
1023     ac_init_help=long ;;
1024   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1025     ac_init_help=recursive ;;
1026   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1027     ac_init_help=short ;;
1028
1029   -host | --host | --hos | --ho)
1030     ac_prev=host_alias ;;
1031   -host=* | --host=* | --hos=* | --ho=*)
1032     host_alias=$ac_optarg ;;
1033
1034   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1035     ac_prev=htmldir ;;
1036   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1037   | --ht=*)
1038     htmldir=$ac_optarg ;;
1039
1040   -includedir | --includedir | --includedi | --included | --include \
1041   | --includ | --inclu | --incl | --inc)
1042     ac_prev=includedir ;;
1043   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1044   | --includ=* | --inclu=* | --incl=* | --inc=*)
1045     includedir=$ac_optarg ;;
1046
1047   -infodir | --infodir | --infodi | --infod | --info | --inf)
1048     ac_prev=infodir ;;
1049   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1050     infodir=$ac_optarg ;;
1051
1052   -libdir | --libdir | --libdi | --libd)
1053     ac_prev=libdir ;;
1054   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1055     libdir=$ac_optarg ;;
1056
1057   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1058   | --libexe | --libex | --libe)
1059     ac_prev=libexecdir ;;
1060   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1061   | --libexe=* | --libex=* | --libe=*)
1062     libexecdir=$ac_optarg ;;
1063
1064   -localedir | --localedir | --localedi | --localed | --locale)
1065     ac_prev=localedir ;;
1066   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1067     localedir=$ac_optarg ;;
1068
1069   -localstatedir | --localstatedir | --localstatedi | --localstated \
1070   | --localstate | --localstat | --localsta | --localst | --locals)
1071     ac_prev=localstatedir ;;
1072   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1073   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1074     localstatedir=$ac_optarg ;;
1075
1076   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1077     ac_prev=mandir ;;
1078   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1079     mandir=$ac_optarg ;;
1080
1081   -nfp | --nfp | --nf)
1082     # Obsolete; use --without-fp.
1083     with_fp=no ;;
1084
1085   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1086   | --no-cr | --no-c | -n)
1087     no_create=yes ;;
1088
1089   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1090   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1091     no_recursion=yes ;;
1092
1093   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1094   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1095   | --oldin | --oldi | --old | --ol | --o)
1096     ac_prev=oldincludedir ;;
1097   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1098   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1099   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1100     oldincludedir=$ac_optarg ;;
1101
1102   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1103     ac_prev=prefix ;;
1104   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1105     prefix=$ac_optarg ;;
1106
1107   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1108   | --program-pre | --program-pr | --program-p)
1109     ac_prev=program_prefix ;;
1110   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1111   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1112     program_prefix=$ac_optarg ;;
1113
1114   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1115   | --program-suf | --program-su | --program-s)
1116     ac_prev=program_suffix ;;
1117   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1118   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1119     program_suffix=$ac_optarg ;;
1120
1121   -program-transform-name | --program-transform-name \
1122   | --program-transform-nam | --program-transform-na \
1123   | --program-transform-n | --program-transform- \
1124   | --program-transform | --program-transfor \
1125   | --program-transfo | --program-transf \
1126   | --program-trans | --program-tran \
1127   | --progr-tra | --program-tr | --program-t)
1128     ac_prev=program_transform_name ;;
1129   -program-transform-name=* | --program-transform-name=* \
1130   | --program-transform-nam=* | --program-transform-na=* \
1131   | --program-transform-n=* | --program-transform-=* \
1132   | --program-transform=* | --program-transfor=* \
1133   | --program-transfo=* | --program-transf=* \
1134   | --program-trans=* | --program-tran=* \
1135   | --progr-tra=* | --program-tr=* | --program-t=*)
1136     program_transform_name=$ac_optarg ;;
1137
1138   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1139     ac_prev=pdfdir ;;
1140   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1141     pdfdir=$ac_optarg ;;
1142
1143   -psdir | --psdir | --psdi | --psd | --ps)
1144     ac_prev=psdir ;;
1145   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1146     psdir=$ac_optarg ;;
1147
1148   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1149   | -silent | --silent | --silen | --sile | --sil)
1150     silent=yes ;;
1151
1152   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1153     ac_prev=sbindir ;;
1154   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1155   | --sbi=* | --sb=*)
1156     sbindir=$ac_optarg ;;
1157
1158   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1159   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1160   | --sharedst | --shareds | --shared | --share | --shar \
1161   | --sha | --sh)
1162     ac_prev=sharedstatedir ;;
1163   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1164   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1165   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1166   | --sha=* | --sh=*)
1167     sharedstatedir=$ac_optarg ;;
1168
1169   -site | --site | --sit)
1170     ac_prev=site ;;
1171   -site=* | --site=* | --sit=*)
1172     site=$ac_optarg ;;
1173
1174   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1175     ac_prev=srcdir ;;
1176   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1177     srcdir=$ac_optarg ;;
1178
1179   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1180   | --syscon | --sysco | --sysc | --sys | --sy)
1181     ac_prev=sysconfdir ;;
1182   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1183   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1184     sysconfdir=$ac_optarg ;;
1185
1186   -target | --target | --targe | --targ | --tar | --ta | --t)
1187     ac_prev=target_alias ;;
1188   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1189     target_alias=$ac_optarg ;;
1190
1191   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1192     verbose=yes ;;
1193
1194   -version | --version | --versio | --versi | --vers | -V)
1195     ac_init_version=: ;;
1196
1197   -with-* | --with-*)
1198     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1199     # Reject names that are not valid shell variable names.
1200     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1201       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1202    { (exit 1); exit 1; }; }
1203     ac_useropt_orig=$ac_useropt
1204     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1205     case $ac_user_opts in
1206       *"
1207 "with_$ac_useropt"
1208 "*) ;;
1209       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1210          ac_unrecognized_sep=', ';;
1211     esac
1212     eval with_$ac_useropt=\$ac_optarg ;;
1213
1214   -without-* | --without-*)
1215     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1216     # Reject names that are not valid shell variable names.
1217     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1218       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1219    { (exit 1); exit 1; }; }
1220     ac_useropt_orig=$ac_useropt
1221     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1222     case $ac_user_opts in
1223       *"
1224 "with_$ac_useropt"
1225 "*) ;;
1226       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1227          ac_unrecognized_sep=', ';;
1228     esac
1229     eval with_$ac_useropt=no ;;
1230
1231   --x)
1232     # Obsolete; use --with-x.
1233     with_x=yes ;;
1234
1235   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1236   | --x-incl | --x-inc | --x-in | --x-i)
1237     ac_prev=x_includes ;;
1238   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1239   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1240     x_includes=$ac_optarg ;;
1241
1242   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1243   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1244     ac_prev=x_libraries ;;
1245   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1246   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1247     x_libraries=$ac_optarg ;;
1248
1249   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1250 Try \`$0 --help' for more information." >&2
1251    { (exit 1); exit 1; }; }
1252     ;;
1253
1254   *=*)
1255     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1256     # Reject names that are not valid shell variable names.
1257     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1258       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1259    { (exit 1); exit 1; }; }
1260     eval $ac_envvar=\$ac_optarg
1261     export $ac_envvar ;;
1262
1263   *)
1264     # FIXME: should be removed in autoconf 3.0.
1265     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1266     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1267       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1268     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1269     ;;
1270
1271   esac
1272 done
1273
1274 if test -n "$ac_prev"; then
1275   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1276   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1277    { (exit 1); exit 1; }; }
1278 fi
1279
1280 if test -n "$ac_unrecognized_opts"; then
1281   case $enable_option_checking in
1282     no) ;;
1283     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1284    { (exit 1); exit 1; }; } ;;
1285     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1286   esac
1287 fi
1288
1289 # Check all directory arguments for consistency.
1290 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1291                 datadir sysconfdir sharedstatedir localstatedir includedir \
1292                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1293                 libdir localedir mandir
1294 do
1295   eval ac_val=\$$ac_var
1296   # Remove trailing slashes.
1297   case $ac_val in
1298     */ )
1299       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1300       eval $ac_var=\$ac_val;;
1301   esac
1302   # Be sure to have absolute directory names.
1303   case $ac_val in
1304     [\\/$]* | ?:[\\/]* )  continue;;
1305     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1306   esac
1307   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1308    { (exit 1); exit 1; }; }
1309 done
1310
1311 # There might be people who depend on the old broken behavior: `$host'
1312 # used to hold the argument of --host etc.
1313 # FIXME: To remove some day.
1314 build=$build_alias
1315 host=$host_alias
1316 target=$target_alias
1317
1318 # FIXME: To remove some day.
1319 if test "x$host_alias" != x; then
1320   if test "x$build_alias" = x; then
1321     cross_compiling=maybe
1322     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1323     If a cross compiler is detected then cross compile mode will be used." >&2
1324   elif test "x$build_alias" != "x$host_alias"; then
1325     cross_compiling=yes
1326   fi
1327 fi
1328
1329 ac_tool_prefix=
1330 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1331
1332 test "$silent" = yes && exec 6>/dev/null
1333
1334
1335 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1336 ac_ls_di=`ls -di .` &&
1337 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1338   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1339    { (exit 1); exit 1; }; }
1340 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1341   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1342    { (exit 1); exit 1; }; }
1343
1344
1345 # Find the source files, if location was not specified.
1346 if test -z "$srcdir"; then
1347   ac_srcdir_defaulted=yes
1348   # Try the directory containing this script, then the parent directory.
1349   ac_confdir=`$as_dirname -- "$as_myself" ||
1350 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1351          X"$as_myself" : 'X\(//\)[^/]' \| \
1352          X"$as_myself" : 'X\(//\)$' \| \
1353          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1354 $as_echo X"$as_myself" |
1355     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1356             s//\1/
1357             q
1358           }
1359           /^X\(\/\/\)[^/].*/{
1360             s//\1/
1361             q
1362           }
1363           /^X\(\/\/\)$/{
1364             s//\1/
1365             q
1366           }
1367           /^X\(\/\).*/{
1368             s//\1/
1369             q
1370           }
1371           s/.*/./; q'`
1372   srcdir=$ac_confdir
1373   if test ! -r "$srcdir/$ac_unique_file"; then
1374     srcdir=..
1375   fi
1376 else
1377   ac_srcdir_defaulted=no
1378 fi
1379 if test ! -r "$srcdir/$ac_unique_file"; then
1380   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1381   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1382    { (exit 1); exit 1; }; }
1383 fi
1384 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1385 ac_abs_confdir=`(
1386         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1387    { (exit 1); exit 1; }; }
1388         pwd)`
1389 # When building in place, set srcdir=.
1390 if test "$ac_abs_confdir" = "$ac_pwd"; then
1391   srcdir=.
1392 fi
1393 # Remove unnecessary trailing slashes from srcdir.
1394 # Double slashes in file names in object file debugging info
1395 # mess up M-x gdb in Emacs.
1396 case $srcdir in
1397 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1398 esac
1399 for ac_var in $ac_precious_vars; do
1400   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1401   eval ac_env_${ac_var}_value=\$${ac_var}
1402   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1403   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1404 done
1405
1406 #
1407 # Report the --help message.
1408 #
1409 if test "$ac_init_help" = "long"; then
1410   # Omit some internal or obsolete options to make the list less imposing.
1411   # This message is too long to be a string in the A/UX 3.1 sh.
1412   cat <<_ACEOF
1413 \`configure' configures PostgreSQL 9.0beta1 to adapt to many kinds of systems.
1414
1415 Usage: $0 [OPTION]... [VAR=VALUE]...
1416
1417 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1418 VAR=VALUE.  See below for descriptions of some of the useful variables.
1419
1420 Defaults for the options are specified in brackets.
1421
1422 Configuration:
1423   -h, --help              display this help and exit
1424       --help=short        display options specific to this package
1425       --help=recursive    display the short help of all the included packages
1426   -V, --version           display version information and exit
1427   -q, --quiet, --silent   do not print \`checking...' messages
1428       --cache-file=FILE   cache test results in FILE [disabled]
1429   -C, --config-cache      alias for \`--cache-file=config.cache'
1430   -n, --no-create         do not create output files
1431       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1432
1433 Installation directories:
1434   --prefix=PREFIX         install architecture-independent files in PREFIX
1435                           [$ac_default_prefix]
1436   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1437                           [PREFIX]
1438
1439 By default, \`make install' will install all the files in
1440 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1441 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1442 for instance \`--prefix=\$HOME'.
1443
1444 For better control, use the options below.
1445
1446 Fine tuning of the installation directories:
1447   --bindir=DIR            user executables [EPREFIX/bin]
1448   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1449   --libexecdir=DIR        program executables [EPREFIX/libexec]
1450   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1451   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1452   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1453   --libdir=DIR            object code libraries [EPREFIX/lib]
1454   --includedir=DIR        C header files [PREFIX/include]
1455   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1456   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1457   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1458   --infodir=DIR           info documentation [DATAROOTDIR/info]
1459   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1460   --mandir=DIR            man documentation [DATAROOTDIR/man]
1461   --docdir=DIR            documentation root [DATAROOTDIR/doc/postgresql]
1462   --htmldir=DIR           html documentation [DOCDIR]
1463   --dvidir=DIR            dvi documentation [DOCDIR]
1464   --pdfdir=DIR            pdf documentation [DOCDIR]
1465   --psdir=DIR             ps documentation [DOCDIR]
1466 _ACEOF
1467
1468   cat <<\_ACEOF
1469
1470 System types:
1471   --build=BUILD     configure for building on BUILD [guessed]
1472   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1473 _ACEOF
1474 fi
1475
1476 if test -n "$ac_init_help"; then
1477   case $ac_init_help in
1478      short | recursive ) echo "Configuration of PostgreSQL 9.0beta1:";;
1479    esac
1480   cat <<\_ACEOF
1481
1482 Optional Features:
1483   --disable-option-checking  ignore unrecognized --enable/--with options
1484   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1485   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1486   --disable-integer-datetimes
1487                           disable 64-bit integer date/time support
1488   --enable-nls[=LANGUAGES]
1489                           enable Native Language Support
1490   --disable-shared        do not build shared libraries
1491   --disable-rpath         do not embed shared library search path in
1492                           executables
1493   --disable-spinlocks     do not use spinlocks
1494   --enable-debug          build with debugging symbols (-g)
1495   --enable-profiling      build with profiling enabled
1496   --enable-coverage       build with coverage testing instrumentation
1497   --enable-dtrace         build with DTrace support
1498   --enable-depend         turn on automatic dependency tracking
1499   --enable-cassert        enable assertion checks (for debugging)
1500   --disable-thread-safety disable thread-safety in client libraries
1501   --disable-largefile     omit support for large files
1502   --disable-float4-byval  disable float4 passed by value
1503   --disable-float8-byval  disable float8 passed by value
1504
1505 Optional Packages:
1506   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1507   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1508   --with-template=NAME    override operating system template
1509   --with-includes=DIRS    look for additional header files in DIRS
1510   --with-libraries=DIRS   look for additional libraries in DIRS
1511   --with-libs=DIRS        alternative spelling of --with-libraries
1512   --with-pgport=PORTNUM   set default port number [5432]
1513   --with-blocksize=BLOCKSIZE
1514                           set table block size in kB [8]
1515   --with-segsize=SEGSIZE  set table segment size in GB [1]
1516   --with-wal-blocksize=BLOCKSIZE
1517                           set WAL block size in kB [8]
1518   --with-wal-segsize=SEGSIZE
1519                           set WAL segment size in MB [16]
1520   --with-CC=CMD           set compiler (deprecated)
1521   --with-tcl              build Tcl modules (PL/Tcl)
1522   --with-tclconfig=DIR    tclConfig.sh is in DIR
1523   --with-perl             build Perl modules (PL/Perl)
1524   --with-python           build Python modules (PL/Python)
1525   --with-gssapi           build with GSSAPI support
1526   --with-krb5             build with Kerberos 5 support
1527   --with-krb-srvnam=NAME  default service principal name in Kerberos
1528                           [postgres]
1529   --with-pam              build with PAM support
1530   --with-ldap             build with LDAP support
1531   --with-bonjour          build with Bonjour support
1532   --with-openssl          build with OpenSSL support
1533   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1534   --with-libedit-preferred
1535                           prefer BSD Libedit over GNU Readline
1536   --with-ossp-uuid        use OSSP UUID library when building
1537                           contrib/uuid-ossp
1538   --with-libxml           build with XML support
1539   --with-libxslt          use XSLT support when building contrib/xml2
1540   --with-system-tzdata=DIR
1541                           use system time zone data in DIR
1542   --without-zlib          do not use Zlib
1543   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1544
1545 Some influential environment variables:
1546   CC          C compiler command
1547   CFLAGS      C compiler flags
1548   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1549               nonstandard directory <lib dir>
1550   LIBS        libraries to pass to the linker, e.g. -l<library>
1551   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1552               you have headers in a nonstandard directory <include dir>
1553   CPP         C preprocessor
1554   LDFLAGS_SL  linker flags for shared library linking
1555   DOCBOOKSTYLE
1556               location of DocBook stylesheets
1557
1558 Use these variables to override the choices made by `configure' or to help
1559 it to find libraries and programs with nonstandard names/locations.
1560
1561 Report bugs to <pgsql-bugs@postgresql.org>.
1562 _ACEOF
1563 ac_status=$?
1564 fi
1565
1566 if test "$ac_init_help" = "recursive"; then
1567   # If there are subdirs, report their specific --help.
1568   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1569     test -d "$ac_dir" ||
1570       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1571       continue
1572     ac_builddir=.
1573
1574 case "$ac_dir" in
1575 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1576 *)
1577   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1578   # A ".." for each directory in $ac_dir_suffix.
1579   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1580   case $ac_top_builddir_sub in
1581   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1582   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1583   esac ;;
1584 esac
1585 ac_abs_top_builddir=$ac_pwd
1586 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1587 # for backward compatibility:
1588 ac_top_builddir=$ac_top_build_prefix
1589
1590 case $srcdir in
1591   .)  # We are building in place.
1592     ac_srcdir=.
1593     ac_top_srcdir=$ac_top_builddir_sub
1594     ac_abs_top_srcdir=$ac_pwd ;;
1595   [\\/]* | ?:[\\/]* )  # Absolute name.
1596     ac_srcdir=$srcdir$ac_dir_suffix;
1597     ac_top_srcdir=$srcdir
1598     ac_abs_top_srcdir=$srcdir ;;
1599   *) # Relative name.
1600     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1601     ac_top_srcdir=$ac_top_build_prefix$srcdir
1602     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1603 esac
1604 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1605
1606     cd "$ac_dir" || { ac_status=$?; continue; }
1607     # Check for guested configure.
1608     if test -f "$ac_srcdir/configure.gnu"; then
1609       echo &&
1610       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1611     elif test -f "$ac_srcdir/configure"; then
1612       echo &&
1613       $SHELL "$ac_srcdir/configure" --help=recursive
1614     else
1615       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1616     fi || ac_status=$?
1617     cd "$ac_pwd" || { ac_status=$?; break; }
1618   done
1619 fi
1620
1621 test -n "$ac_init_help" && exit $ac_status
1622 if $ac_init_version; then
1623   cat <<\_ACEOF
1624 PostgreSQL configure 9.0beta1
1625 generated by GNU Autoconf 2.63
1626
1627 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1628 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1629 This configure script is free software; the Free Software Foundation
1630 gives unlimited permission to copy, distribute and modify it.
1631
1632 Copyright (c) 1996-2010, PostgreSQL Global Development Group
1633 _ACEOF
1634   exit
1635 fi
1636 cat >config.log <<_ACEOF
1637 This file contains any messages produced by compilers while
1638 running configure, to aid debugging if configure makes a mistake.
1639
1640 It was created by PostgreSQL $as_me 9.0beta1, which was
1641 generated by GNU Autoconf 2.63.  Invocation command line was
1642
1643   $ $0 $@
1644
1645 _ACEOF
1646 exec 5>>config.log
1647 {
1648 cat <<_ASUNAME
1649 ## --------- ##
1650 ## Platform. ##
1651 ## --------- ##
1652
1653 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1654 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1655 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1656 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1657 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1658
1659 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1660 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1661
1662 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1663 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1664 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1665 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1666 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1667 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1668 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1669
1670 _ASUNAME
1671
1672 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1673 for as_dir in $PATH
1674 do
1675   IFS=$as_save_IFS
1676   test -z "$as_dir" && as_dir=.
1677   $as_echo "PATH: $as_dir"
1678 done
1679 IFS=$as_save_IFS
1680
1681 } >&5
1682
1683 cat >&5 <<_ACEOF
1684
1685
1686 ## ----------- ##
1687 ## Core tests. ##
1688 ## ----------- ##
1689
1690 _ACEOF
1691
1692
1693 # Keep a trace of the command line.
1694 # Strip out --no-create and --no-recursion so they do not pile up.
1695 # Strip out --silent because we don't want to record it for future runs.
1696 # Also quote any args containing shell meta-characters.
1697 # Make two passes to allow for proper duplicate-argument suppression.
1698 ac_configure_args=
1699 ac_configure_args0=
1700 ac_configure_args1=
1701 ac_must_keep_next=false
1702 for ac_pass in 1 2
1703 do
1704   for ac_arg
1705   do
1706     case $ac_arg in
1707     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1708     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1709     | -silent | --silent | --silen | --sile | --sil)
1710       continue ;;
1711     *\'*)
1712       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1713     esac
1714     case $ac_pass in
1715     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1716     2)
1717       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1718       if test $ac_must_keep_next = true; then
1719         ac_must_keep_next=false # Got value, back to normal.
1720       else
1721         case $ac_arg in
1722           *=* | --config-cache | -C | -disable-* | --disable-* \
1723           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1724           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1725           | -with-* | --with-* | -without-* | --without-* | --x)
1726             case "$ac_configure_args0 " in
1727               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1728             esac
1729             ;;
1730           -* ) ac_must_keep_next=true ;;
1731         esac
1732       fi
1733       ac_configure_args="$ac_configure_args '$ac_arg'"
1734       ;;
1735     esac
1736   done
1737 done
1738 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1739 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1740
1741 # When interrupted or exit'd, cleanup temporary files, and complete
1742 # config.log.  We remove comments because anyway the quotes in there
1743 # would cause problems or look ugly.
1744 # WARNING: Use '\'' to represent an apostrophe within the trap.
1745 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1746 trap 'exit_status=$?
1747   # Save into config.log some information that might help in debugging.
1748   {
1749     echo
1750
1751     cat <<\_ASBOX
1752 ## ---------------- ##
1753 ## Cache variables. ##
1754 ## ---------------- ##
1755 _ASBOX
1756     echo
1757     # The following way of writing the cache mishandles newlines in values,
1758 (
1759   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1760     eval ac_val=\$$ac_var
1761     case $ac_val in #(
1762     *${as_nl}*)
1763       case $ac_var in #(
1764       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1765 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1766       esac
1767       case $ac_var in #(
1768       _ | IFS | as_nl) ;; #(
1769       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1770       *) $as_unset $ac_var ;;
1771       esac ;;
1772     esac
1773   done
1774   (set) 2>&1 |
1775     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1776     *${as_nl}ac_space=\ *)
1777       sed -n \
1778         "s/'\''/'\''\\\\'\'''\''/g;
1779           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1780       ;; #(
1781     *)
1782       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1783       ;;
1784     esac |
1785     sort
1786 )
1787     echo
1788
1789     cat <<\_ASBOX
1790 ## ----------------- ##
1791 ## Output variables. ##
1792 ## ----------------- ##
1793 _ASBOX
1794     echo
1795     for ac_var in $ac_subst_vars
1796     do
1797       eval ac_val=\$$ac_var
1798       case $ac_val in
1799       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1800       esac
1801       $as_echo "$ac_var='\''$ac_val'\''"
1802     done | sort
1803     echo
1804
1805     if test -n "$ac_subst_files"; then
1806       cat <<\_ASBOX
1807 ## ------------------- ##
1808 ## File substitutions. ##
1809 ## ------------------- ##
1810 _ASBOX
1811       echo
1812       for ac_var in $ac_subst_files
1813       do
1814         eval ac_val=\$$ac_var
1815         case $ac_val in
1816         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1817         esac
1818         $as_echo "$ac_var='\''$ac_val'\''"
1819       done | sort
1820       echo
1821     fi
1822
1823     if test -s confdefs.h; then
1824       cat <<\_ASBOX
1825 ## ----------- ##
1826 ## confdefs.h. ##
1827 ## ----------- ##
1828 _ASBOX
1829       echo
1830       cat confdefs.h
1831       echo
1832     fi
1833     test "$ac_signal" != 0 &&
1834       $as_echo "$as_me: caught signal $ac_signal"
1835     $as_echo "$as_me: exit $exit_status"
1836   } >&5
1837   rm -f core *.core core.conftest.* &&
1838     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1839     exit $exit_status
1840 ' 0
1841 for ac_signal in 1 2 13 15; do
1842   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1843 done
1844 ac_signal=0
1845
1846 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1847 rm -f -r conftest* confdefs.h
1848
1849 # Predefined preprocessor variables.
1850
1851 cat >>confdefs.h <<_ACEOF
1852 #define PACKAGE_NAME "$PACKAGE_NAME"
1853 _ACEOF
1854
1855
1856 cat >>confdefs.h <<_ACEOF
1857 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1858 _ACEOF
1859
1860
1861 cat >>confdefs.h <<_ACEOF
1862 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1863 _ACEOF
1864
1865
1866 cat >>confdefs.h <<_ACEOF
1867 #define PACKAGE_STRING "$PACKAGE_STRING"
1868 _ACEOF
1869
1870
1871 cat >>confdefs.h <<_ACEOF
1872 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1873 _ACEOF
1874
1875
1876 # Let the site file select an alternate cache file if it wants to.
1877 # Prefer an explicitly selected file to automatically selected ones.
1878 ac_site_file1=NONE
1879 ac_site_file2=NONE
1880 if test -n "$CONFIG_SITE"; then
1881   ac_site_file1=$CONFIG_SITE
1882 elif test "x$prefix" != xNONE; then
1883   ac_site_file1=$prefix/share/config.site
1884   ac_site_file2=$prefix/etc/config.site
1885 else
1886   ac_site_file1=$ac_default_prefix/share/config.site
1887   ac_site_file2=$ac_default_prefix/etc/config.site
1888 fi
1889 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1890 do
1891   test "x$ac_site_file" = xNONE && continue
1892   if test -r "$ac_site_file"; then
1893     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1894 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1895     sed 's/^/| /' "$ac_site_file" >&5
1896     . "$ac_site_file"
1897   fi
1898 done
1899
1900 if test -r "$cache_file"; then
1901   # Some versions of bash will fail to source /dev/null (special
1902   # files actually), so we avoid doing that.
1903   if test -f "$cache_file"; then
1904     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1905 $as_echo "$as_me: loading cache $cache_file" >&6;}
1906     case $cache_file in
1907       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1908       *)                      . "./$cache_file";;
1909     esac
1910   fi
1911 else
1912   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1913 $as_echo "$as_me: creating cache $cache_file" >&6;}
1914   >$cache_file
1915 fi
1916
1917 # Check that the precious variables saved in the cache have kept the same
1918 # value.
1919 ac_cache_corrupted=false
1920 for ac_var in $ac_precious_vars; do
1921   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1922   eval ac_new_set=\$ac_env_${ac_var}_set
1923   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1924   eval ac_new_val=\$ac_env_${ac_var}_value
1925   case $ac_old_set,$ac_new_set in
1926     set,)
1927       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1928 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1929       ac_cache_corrupted=: ;;
1930     ,set)
1931       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1932 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1933       ac_cache_corrupted=: ;;
1934     ,);;
1935     *)
1936       if test "x$ac_old_val" != "x$ac_new_val"; then
1937         # differences in whitespace do not lead to failure.
1938         ac_old_val_w=`echo x $ac_old_val`
1939         ac_new_val_w=`echo x $ac_new_val`
1940         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1941           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1942 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1943           ac_cache_corrupted=:
1944         else
1945           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1946 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1947           eval $ac_var=\$ac_old_val
1948         fi
1949         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1950 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1951         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1952 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1953       fi;;
1954   esac
1955   # Pass precious variables to config.status.
1956   if test "$ac_new_set" = set; then
1957     case $ac_new_val in
1958     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1959     *) ac_arg=$ac_var=$ac_new_val ;;
1960     esac
1961     case " $ac_configure_args " in
1962       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1963       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1964     esac
1965   fi
1966 done
1967 if $ac_cache_corrupted; then
1968   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1969 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1970   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1971 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1972   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1973 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1974    { (exit 1); exit 1; }; }
1975 fi
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001 ac_ext=c
2002 ac_cpp='$CPP $CPPFLAGS'
2003 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2004 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2005 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2006
2007
2008
2009
2010
2011
2012 ac_aux_dir=
2013 for ac_dir in config "$srcdir"/config; do
2014   if test -f "$ac_dir/install-sh"; then
2015     ac_aux_dir=$ac_dir
2016     ac_install_sh="$ac_aux_dir/install-sh -c"
2017     break
2018   elif test -f "$ac_dir/install.sh"; then
2019     ac_aux_dir=$ac_dir
2020     ac_install_sh="$ac_aux_dir/install.sh -c"
2021     break
2022   elif test -f "$ac_dir/shtool"; then
2023     ac_aux_dir=$ac_dir
2024     ac_install_sh="$ac_aux_dir/shtool install -c"
2025     break
2026   fi
2027 done
2028 if test -z "$ac_aux_dir"; then
2029   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2030 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2031    { (exit 1); exit 1; }; }
2032 fi
2033
2034 # These three variables are undocumented and unsupported,
2035 # and are intended to be withdrawn in a future Autoconf release.
2036 # They can cause serious problems if a builder's source tree is in a directory
2037 # whose full name contains unusual characters.
2038 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2039 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2040 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2041
2042
2043
2044 configure_args=$ac_configure_args
2045
2046
2047
2048 cat >>confdefs.h <<_ACEOF
2049 #define PG_VERSION "$PACKAGE_VERSION"
2050 _ACEOF
2051
2052 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2053
2054
2055 cat >>confdefs.h <<_ACEOF
2056 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2057 _ACEOF
2058
2059
2060 # Make sure we can run config.sub.
2061 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2062   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2063 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2064    { (exit 1); exit 1; }; }
2065
2066 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2067 $as_echo_n "checking build system type... " >&6; }
2068 if test "${ac_cv_build+set}" = set; then
2069   $as_echo_n "(cached) " >&6
2070 else
2071   ac_build_alias=$build_alias
2072 test "x$ac_build_alias" = x &&
2073   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2074 test "x$ac_build_alias" = x &&
2075   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2076 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2077    { (exit 1); exit 1; }; }
2078 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2079   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2080 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2081    { (exit 1); exit 1; }; }
2082
2083 fi
2084 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2085 $as_echo "$ac_cv_build" >&6; }
2086 case $ac_cv_build in
2087 *-*-*) ;;
2088 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2089 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2090    { (exit 1); exit 1; }; };;
2091 esac
2092 build=$ac_cv_build
2093 ac_save_IFS=$IFS; IFS='-'
2094 set x $ac_cv_build
2095 shift
2096 build_cpu=$1
2097 build_vendor=$2
2098 shift; shift
2099 # Remember, the first character of IFS is used to create $*,
2100 # except with old shells:
2101 build_os=$*
2102 IFS=$ac_save_IFS
2103 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2104
2105
2106 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2107 $as_echo_n "checking host system type... " >&6; }
2108 if test "${ac_cv_host+set}" = set; then
2109   $as_echo_n "(cached) " >&6
2110 else
2111   if test "x$host_alias" = x; then
2112   ac_cv_host=$ac_cv_build
2113 else
2114   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2115     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2116 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2117    { (exit 1); exit 1; }; }
2118 fi
2119
2120 fi
2121 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2122 $as_echo "$ac_cv_host" >&6; }
2123 case $ac_cv_host in
2124 *-*-*) ;;
2125 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2126 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2127    { (exit 1); exit 1; }; };;
2128 esac
2129 host=$ac_cv_host
2130 ac_save_IFS=$IFS; IFS='-'
2131 set x $ac_cv_host
2132 shift
2133 host_cpu=$1
2134 host_vendor=$2
2135 shift; shift
2136 # Remember, the first character of IFS is used to create $*,
2137 # except with old shells:
2138 host_os=$*
2139 IFS=$ac_save_IFS
2140 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2141
2142
2143
2144 template=
2145 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2146 $as_echo_n "checking which template to use... " >&6; }
2147
2148
2149
2150
2151 # Check whether --with-template was given.
2152 if test "${with_template+set}" = set; then
2153   withval=$with_template;
2154   case $withval in
2155     yes)
2156       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2157 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2158    { (exit 1); exit 1; }; }
2159       ;;
2160     no)
2161       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2162 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2163    { (exit 1); exit 1; }; }
2164       ;;
2165     *)
2166
2167   case $withval in
2168     list)   echo; ls "$srcdir/src/template"; exit;;
2169     *)      if test -f "$srcdir/src/template/$with_template" ; then
2170               template=$withval
2171             else
2172               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2173 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2174    { (exit 1); exit 1; }; }
2175             fi;;
2176   esac
2177
2178       ;;
2179   esac
2180
2181 else
2182
2183 # --with-template not given
2184
2185 case $host_os in
2186      aix*) template=aix ;;
2187     bsdi*) template=bsdi ;;
2188   cygwin*) template=cygwin ;;
2189   darwin*) template=darwin ;;
2190     dgux*) template=dgux ;;
2191  freebsd*) template=freebsd ;;
2192     hpux*) template=hpux ;;
2193     irix*) template=irix ;;
2194  linux*|gnu*|k*bsd*-gnu)
2195            template=linux ;;
2196    mingw*) template=win32 ;;
2197   netbsd*) template=netbsd ;;
2198 nextstep*) template=nextstep ;;
2199  openbsd*) template=openbsd ;;
2200      osf*) template=osf ;;
2201      sco*) template=sco ;;
2202  solaris*) template=solaris ;;
2203    sunos*) template=sunos4 ;;
2204  sysv4.2*)
2205         case $host_vendor in
2206           univel) template=univel ;;
2207         esac ;;
2208    sysv4*) template=svr4 ;;
2209    sysv5*) template=unixware ;;
2210   ultrix*) template=ultrix4 ;;
2211 esac
2212
2213   if test x"$template" = x"" ; then
2214     { { $as_echo "$as_me:$LINENO: error:
2215 *******************************************************************
2216 PostgreSQL has apparently not been ported to your platform yet.
2217 To try a manual configuration, look into the src/template directory
2218 for a similar platform and use the '--with-template=' option.
2219
2220 Please also contact <pgsql-bugs@postgresql.org> to see about
2221 rectifying this.  Include the above 'checking host system type...'
2222 line.
2223 *******************************************************************
2224 " >&5
2225 $as_echo "$as_me: error:
2226 *******************************************************************
2227 PostgreSQL has apparently not been ported to your platform yet.
2228 To try a manual configuration, look into the src/template directory
2229 for a similar platform and use the '--with-template=' option.
2230
2231 Please also contact <pgsql-bugs@postgresql.org> to see about
2232 rectifying this.  Include the above 'checking host system type...'
2233 line.
2234 *******************************************************************
2235 " >&2;}
2236    { (exit 1); exit 1; }; }
2237   fi
2238
2239
2240 fi
2241
2242
2243
2244 { $as_echo "$as_me:$LINENO: result: $template" >&5
2245 $as_echo "$template" >&6; }
2246
2247 PORTNAME=$template
2248
2249
2250 # Initialize default assumption that we do not need separate assembly code
2251 # for TAS (test-and-set).  This can be overridden by the template file
2252 # when it's executed.
2253 need_tas=no
2254 tas_file=dummy.s
2255
2256
2257
2258 ##
2259 ## Command line options
2260 ##
2261
2262 #
2263 # Add non-standard directories to the include path
2264 #
2265
2266
2267
2268 # Check whether --with-includes was given.
2269 if test "${with_includes+set}" = set; then
2270   withval=$with_includes;
2271   case $withval in
2272     yes)
2273       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2274 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2275    { (exit 1); exit 1; }; }
2276       ;;
2277     no)
2278       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2279 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2280    { (exit 1); exit 1; }; }
2281       ;;
2282     *)
2283
2284       ;;
2285   esac
2286
2287 fi
2288
2289
2290
2291
2292 #
2293 # Add non-standard directories to the library search path
2294 #
2295
2296
2297
2298 # Check whether --with-libraries was given.
2299 if test "${with_libraries+set}" = set; then
2300   withval=$with_libraries;
2301   case $withval in
2302     yes)
2303       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2304 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2305    { (exit 1); exit 1; }; }
2306       ;;
2307     no)
2308       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2309 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2310    { (exit 1); exit 1; }; }
2311       ;;
2312     *)
2313       LIBRARY_DIRS=$withval
2314       ;;
2315   esac
2316
2317 fi
2318
2319
2320
2321
2322
2323
2324 # Check whether --with-libs was given.
2325 if test "${with_libs+set}" = set; then
2326   withval=$with_libs;
2327   case $withval in
2328     yes)
2329       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2330 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2331    { (exit 1); exit 1; }; }
2332       ;;
2333     no)
2334       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2335 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2336    { (exit 1); exit 1; }; }
2337       ;;
2338     *)
2339       LIBRARY_DIRS=$withval
2340       ;;
2341   esac
2342
2343 fi
2344
2345
2346
2347
2348 #
2349 # 64-bit integer date/time storage: enabled by default.
2350 #
2351 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2352 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2353
2354
2355 # Check whether --enable-integer-datetimes was given.
2356 if test "${enable_integer_datetimes+set}" = set; then
2357   enableval=$enable_integer_datetimes;
2358   case $enableval in
2359     yes)
2360
2361 cat >>confdefs.h <<\_ACEOF
2362 #define USE_INTEGER_DATETIMES 1
2363 _ACEOF
2364
2365       ;;
2366     no)
2367       :
2368       ;;
2369     *)
2370       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2371 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2372    { (exit 1); exit 1; }; }
2373       ;;
2374   esac
2375
2376 else
2377   enable_integer_datetimes=yes
2378
2379 cat >>confdefs.h <<\_ACEOF
2380 #define USE_INTEGER_DATETIMES 1
2381 _ACEOF
2382
2383 fi
2384
2385
2386 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2387 $as_echo "$enable_integer_datetimes" >&6; }
2388
2389
2390 #
2391 # NLS
2392 #
2393 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2394 $as_echo_n "checking whether NLS is wanted... " >&6; }
2395
2396
2397 # Check whether --enable-nls was given.
2398 if test "${enable_nls+set}" = set; then
2399   enableval=$enable_nls;
2400   case $enableval in
2401     yes)
2402       :
2403       ;;
2404     no)
2405       :
2406       ;;
2407     *)
2408       enable_nls=yes
2409 WANTED_LANGUAGES=$enableval
2410       ;;
2411   esac
2412
2413 else
2414   enable_nls=no
2415 fi
2416
2417
2418
2419 if test "$enable_nls" = yes; then
2420
2421 cat >>confdefs.h <<\_ACEOF
2422 #define ENABLE_NLS 1
2423 _ACEOF
2424
2425 fi
2426
2427 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2428 $as_echo "$enable_nls" >&6; }
2429
2430
2431
2432 #
2433 # Default port number (--with-pgport), default 5432
2434 #
2435 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2436 $as_echo_n "checking for default port number... " >&6; }
2437
2438
2439
2440 # Check whether --with-pgport was given.
2441 if test "${with_pgport+set}" = set; then
2442   withval=$with_pgport;
2443   case $withval in
2444     yes)
2445       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2446 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2447    { (exit 1); exit 1; }; }
2448       ;;
2449     no)
2450       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2451 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2452    { (exit 1); exit 1; }; }
2453       ;;
2454     *)
2455       default_port=$withval
2456       ;;
2457   esac
2458
2459 else
2460   default_port=5432
2461 fi
2462
2463
2464 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2465 $as_echo "$default_port" >&6; }
2466 # Need both of these because some places want an integer and some a string
2467
2468 cat >>confdefs.h <<_ACEOF
2469 #define DEF_PGPORT ${default_port}
2470 _ACEOF
2471
2472
2473 cat >>confdefs.h <<_ACEOF
2474 #define DEF_PGPORT_STR "${default_port}"
2475 _ACEOF
2476
2477
2478
2479 #
2480 # Option to disable shared libraries
2481 #
2482
2483
2484 # Check whether --enable-shared was given.
2485 if test "${enable_shared+set}" = set; then
2486   enableval=$enable_shared;
2487   case $enableval in
2488     yes)
2489       :
2490       ;;
2491     no)
2492       :
2493       ;;
2494     *)
2495       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2496 $as_echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2497    { (exit 1); exit 1; }; }
2498       ;;
2499   esac
2500
2501 else
2502   enable_shared=yes
2503
2504 fi
2505
2506
2507
2508
2509 #
2510 # '-rpath'-like feature can be disabled
2511 #
2512
2513
2514 # Check whether --enable-rpath was given.
2515 if test "${enable_rpath+set}" = set; then
2516   enableval=$enable_rpath;
2517   case $enableval in
2518     yes)
2519       :
2520       ;;
2521     no)
2522       :
2523       ;;
2524     *)
2525       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2526 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2527    { (exit 1); exit 1; }; }
2528       ;;
2529   esac
2530
2531 else
2532   enable_rpath=yes
2533
2534 fi
2535
2536
2537
2538
2539 #
2540 # Spinlocks
2541 #
2542
2543
2544 # Check whether --enable-spinlocks was given.
2545 if test "${enable_spinlocks+set}" = set; then
2546   enableval=$enable_spinlocks;
2547   case $enableval in
2548     yes)
2549       :
2550       ;;
2551     no)
2552       :
2553       ;;
2554     *)
2555       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2556 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2557    { (exit 1); exit 1; }; }
2558       ;;
2559   esac
2560
2561 else
2562   enable_spinlocks=yes
2563
2564 fi
2565
2566
2567
2568 #
2569 # --enable-debug adds -g to compiler flags
2570 #
2571
2572
2573 # Check whether --enable-debug was given.
2574 if test "${enable_debug+set}" = set; then
2575   enableval=$enable_debug;
2576   case $enableval in
2577     yes)
2578       :
2579       ;;
2580     no)
2581       :
2582       ;;
2583     *)
2584       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2585 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2586    { (exit 1); exit 1; }; }
2587       ;;
2588   esac
2589
2590 else
2591   enable_debug=no
2592
2593 fi
2594
2595
2596
2597
2598 #
2599 # --enable-profiling enables gcc profiling
2600 #
2601
2602
2603 # Check whether --enable-profiling was given.
2604 if test "${enable_profiling+set}" = set; then
2605   enableval=$enable_profiling;
2606   case $enableval in
2607     yes)
2608       :
2609       ;;
2610     no)
2611       :
2612       ;;
2613     *)
2614       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2615 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2616    { (exit 1); exit 1; }; }
2617       ;;
2618   esac
2619
2620 else
2621   enable_profiling=no
2622
2623 fi
2624
2625
2626
2627
2628 #
2629 # --enable-coverage enables generation of code coverage metrics with gcov
2630 #
2631
2632
2633 # Check whether --enable-coverage was given.
2634 if test "${enable_coverage+set}" = set; then
2635   enableval=$enable_coverage;
2636   case $enableval in
2637     yes)
2638       for ac_prog in gcov
2639 do
2640   # Extract the first word of "$ac_prog", so it can be a program name with args.
2641 set dummy $ac_prog; ac_word=$2
2642 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2643 $as_echo_n "checking for $ac_word... " >&6; }
2644 if test "${ac_cv_prog_GCOV+set}" = set; then
2645   $as_echo_n "(cached) " >&6
2646 else
2647   if test -n "$GCOV"; then
2648   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2649 else
2650 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2651 for as_dir in $PATH
2652 do
2653   IFS=$as_save_IFS
2654   test -z "$as_dir" && as_dir=.
2655   for ac_exec_ext in '' $ac_executable_extensions; do
2656   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2657     ac_cv_prog_GCOV="$ac_prog"
2658     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2659     break 2
2660   fi
2661 done
2662 done
2663 IFS=$as_save_IFS
2664
2665 fi
2666 fi
2667 GCOV=$ac_cv_prog_GCOV
2668 if test -n "$GCOV"; then
2669   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2670 $as_echo "$GCOV" >&6; }
2671 else
2672   { $as_echo "$as_me:$LINENO: result: no" >&5
2673 $as_echo "no" >&6; }
2674 fi
2675
2676
2677   test -n "$GCOV" && break
2678 done
2679
2680 if test -z "$GCOV"; then
2681   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2682 $as_echo "$as_me: error: gcov not found" >&2;}
2683    { (exit 1); exit 1; }; }
2684 fi
2685 for ac_prog in lcov
2686 do
2687   # Extract the first word of "$ac_prog", so it can be a program name with args.
2688 set dummy $ac_prog; ac_word=$2
2689 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2690 $as_echo_n "checking for $ac_word... " >&6; }
2691 if test "${ac_cv_prog_LCOV+set}" = set; then
2692   $as_echo_n "(cached) " >&6
2693 else
2694   if test -n "$LCOV"; then
2695   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2696 else
2697 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2698 for as_dir in $PATH
2699 do
2700   IFS=$as_save_IFS
2701   test -z "$as_dir" && as_dir=.
2702   for ac_exec_ext in '' $ac_executable_extensions; do
2703   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2704     ac_cv_prog_LCOV="$ac_prog"
2705     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2706     break 2
2707   fi
2708 done
2709 done
2710 IFS=$as_save_IFS
2711
2712 fi
2713 fi
2714 LCOV=$ac_cv_prog_LCOV
2715 if test -n "$LCOV"; then
2716   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2717 $as_echo "$LCOV" >&6; }
2718 else
2719   { $as_echo "$as_me:$LINENO: result: no" >&5
2720 $as_echo "no" >&6; }
2721 fi
2722
2723
2724   test -n "$LCOV" && break
2725 done
2726
2727 if test -z "$LCOV"; then
2728   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2729 $as_echo "$as_me: error: lcov not found" >&2;}
2730    { (exit 1); exit 1; }; }
2731 fi
2732 for ac_prog in genhtml
2733 do
2734   # Extract the first word of "$ac_prog", so it can be a program name with args.
2735 set dummy $ac_prog; ac_word=$2
2736 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2737 $as_echo_n "checking for $ac_word... " >&6; }
2738 if test "${ac_cv_prog_GENHTML+set}" = set; then
2739   $as_echo_n "(cached) " >&6
2740 else
2741   if test -n "$GENHTML"; then
2742   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2743 else
2744 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2745 for as_dir in $PATH
2746 do
2747   IFS=$as_save_IFS
2748   test -z "$as_dir" && as_dir=.
2749   for ac_exec_ext in '' $ac_executable_extensions; do
2750   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2751     ac_cv_prog_GENHTML="$ac_prog"
2752     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2753     break 2
2754   fi
2755 done
2756 done
2757 IFS=$as_save_IFS
2758
2759 fi
2760 fi
2761 GENHTML=$ac_cv_prog_GENHTML
2762 if test -n "$GENHTML"; then
2763   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2764 $as_echo "$GENHTML" >&6; }
2765 else
2766   { $as_echo "$as_me:$LINENO: result: no" >&5
2767 $as_echo "no" >&6; }
2768 fi
2769
2770
2771   test -n "$GENHTML" && break
2772 done
2773
2774 if test -z "$GENHTML"; then
2775   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2776 $as_echo "$as_me: error: genhtml not found" >&2;}
2777    { (exit 1); exit 1; }; }
2778 fi
2779       ;;
2780     no)
2781       :
2782       ;;
2783     *)
2784       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2785 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2786    { (exit 1); exit 1; }; }
2787       ;;
2788   esac
2789
2790 else
2791   enable_coverage=no
2792
2793 fi
2794
2795
2796
2797
2798 #
2799 # DTrace
2800 #
2801
2802
2803 # Check whether --enable-dtrace was given.
2804 if test "${enable_dtrace+set}" = set; then
2805   enableval=$enable_dtrace;
2806   case $enableval in
2807     yes)
2808
2809 cat >>confdefs.h <<\_ACEOF
2810 #define ENABLE_DTRACE 1
2811 _ACEOF
2812
2813 for ac_prog in dtrace
2814 do
2815   # Extract the first word of "$ac_prog", so it can be a program name with args.
2816 set dummy $ac_prog; ac_word=$2
2817 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2818 $as_echo_n "checking for $ac_word... " >&6; }
2819 if test "${ac_cv_prog_DTRACE+set}" = set; then
2820   $as_echo_n "(cached) " >&6
2821 else
2822   if test -n "$DTRACE"; then
2823   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2824 else
2825 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2826 for as_dir in $PATH
2827 do
2828   IFS=$as_save_IFS
2829   test -z "$as_dir" && as_dir=.
2830   for ac_exec_ext in '' $ac_executable_extensions; do
2831   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2832     ac_cv_prog_DTRACE="$ac_prog"
2833     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2834     break 2
2835   fi
2836 done
2837 done
2838 IFS=$as_save_IFS
2839
2840 fi
2841 fi
2842 DTRACE=$ac_cv_prog_DTRACE
2843 if test -n "$DTRACE"; then
2844   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2845 $as_echo "$DTRACE" >&6; }
2846 else
2847   { $as_echo "$as_me:$LINENO: result: no" >&5
2848 $as_echo "no" >&6; }
2849 fi
2850
2851
2852   test -n "$DTRACE" && break
2853 done
2854
2855 if test -z "$DTRACE"; then
2856   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2857 $as_echo "$as_me: error: dtrace not found" >&2;}
2858    { (exit 1); exit 1; }; }
2859 fi
2860
2861       ;;
2862     no)
2863       :
2864       ;;
2865     *)
2866       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2867 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2868    { (exit 1); exit 1; }; }
2869       ;;
2870   esac
2871
2872 else
2873   enable_dtrace=no
2874
2875 fi
2876
2877
2878
2879
2880 #
2881 # Block size
2882 #
2883 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2884 $as_echo_n "checking for block size... " >&6; }
2885
2886
2887
2888 # Check whether --with-blocksize was given.
2889 if test "${with_blocksize+set}" = set; then
2890   withval=$with_blocksize;
2891   case $withval in
2892     yes)
2893       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2894 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2895    { (exit 1); exit 1; }; }
2896       ;;
2897     no)
2898       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2899 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2900    { (exit 1); exit 1; }; }
2901       ;;
2902     *)
2903       blocksize=$withval
2904       ;;
2905   esac
2906
2907 else
2908   blocksize=8
2909 fi
2910
2911
2912 case ${blocksize} in
2913   1) BLCKSZ=1024;;
2914   2) BLCKSZ=2048;;
2915   4) BLCKSZ=4096;;
2916   8) BLCKSZ=8192;;
2917  16) BLCKSZ=16384;;
2918  32) BLCKSZ=32768;;
2919   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2920 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2921    { (exit 1); exit 1; }; }
2922 esac
2923 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2924 $as_echo "${blocksize}kB" >&6; }
2925
2926
2927 cat >>confdefs.h <<_ACEOF
2928 #define BLCKSZ ${BLCKSZ}
2929 _ACEOF
2930
2931
2932 #
2933 # Relation segment size
2934 #
2935 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2936 $as_echo_n "checking for segment size... " >&6; }
2937
2938
2939
2940 # Check whether --with-segsize was given.
2941 if test "${with_segsize+set}" = set; then
2942   withval=$with_segsize;
2943   case $withval in
2944     yes)
2945       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2946 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2947    { (exit 1); exit 1; }; }
2948       ;;
2949     no)
2950       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2951 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2952    { (exit 1); exit 1; }; }
2953       ;;
2954     *)
2955       segsize=$withval
2956       ;;
2957   esac
2958
2959 else
2960   segsize=1
2961 fi
2962
2963
2964 # this expression is set up to avoid unnecessary integer overflow
2965 # blocksize is already guaranteed to be a factor of 1024
2966 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2967 test $? -eq 0 || exit 1
2968 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2969 $as_echo "${segsize}GB" >&6; }
2970
2971
2972 cat >>confdefs.h <<_ACEOF
2973 #define RELSEG_SIZE ${RELSEG_SIZE}
2974 _ACEOF
2975
2976
2977 #
2978 # WAL block size
2979 #
2980 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2981 $as_echo_n "checking for WAL block size... " >&6; }
2982
2983
2984
2985 # Check whether --with-wal-blocksize was given.
2986 if test "${with_wal_blocksize+set}" = set; then
2987   withval=$with_wal_blocksize;
2988   case $withval in
2989     yes)
2990       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2991 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2992    { (exit 1); exit 1; }; }
2993       ;;
2994     no)
2995       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2996 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2997    { (exit 1); exit 1; }; }
2998       ;;
2999     *)
3000       wal_blocksize=$withval
3001       ;;
3002   esac
3003
3004 else
3005   wal_blocksize=8
3006 fi
3007
3008
3009 case ${wal_blocksize} in
3010   1) XLOG_BLCKSZ=1024;;
3011   2) XLOG_BLCKSZ=2048;;
3012   4) XLOG_BLCKSZ=4096;;
3013   8) XLOG_BLCKSZ=8192;;
3014  16) XLOG_BLCKSZ=16384;;
3015  32) XLOG_BLCKSZ=32768;;
3016  64) XLOG_BLCKSZ=65536;;
3017   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
3018 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3019    { (exit 1); exit 1; }; }
3020 esac
3021 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
3022 $as_echo "${wal_blocksize}kB" >&6; }
3023
3024
3025 cat >>confdefs.h <<_ACEOF
3026 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3027 _ACEOF
3028
3029
3030 #
3031 # WAL segment size
3032 #
3033 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
3034 $as_echo_n "checking for WAL segment size... " >&6; }
3035
3036
3037
3038 # Check whether --with-wal-segsize was given.
3039 if test "${with_wal_segsize+set}" = set; then
3040   withval=$with_wal_segsize;
3041   case $withval in
3042     yes)
3043       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3044 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3045    { (exit 1); exit 1; }; }
3046       ;;
3047     no)
3048       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3049 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3050    { (exit 1); exit 1; }; }
3051       ;;
3052     *)
3053       wal_segsize=$withval
3054       ;;
3055   esac
3056
3057 else
3058   wal_segsize=16
3059 fi
3060
3061
3062 case ${wal_segsize} in
3063   1) ;;
3064   2) ;;
3065   4) ;;
3066   8) ;;
3067  16) ;;
3068  32) ;;
3069  64) ;;
3070   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3071 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3072    { (exit 1); exit 1; }; }
3073 esac
3074 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3075 $as_echo "${wal_segsize}MB" >&6; }
3076
3077
3078 cat >>confdefs.h <<_ACEOF
3079 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3080 _ACEOF
3081
3082
3083 #
3084 # C compiler
3085 #
3086
3087 # For historical reasons you can also use --with-CC to specify the C compiler
3088 # to use, although the standard way to do this is to set the CC environment
3089 # variable.
3090
3091
3092
3093 # Check whether --with-CC was given.
3094 if test "${with_CC+set}" = set; then
3095   withval=$with_CC;
3096   case $withval in
3097     yes)
3098       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3099 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3100    { (exit 1); exit 1; }; }
3101       ;;
3102     no)
3103       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3104 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3105    { (exit 1); exit 1; }; }
3106       ;;
3107     *)
3108       CC=$with_CC
3109       ;;
3110   esac
3111
3112 fi
3113
3114
3115
3116 case $template in
3117   aix) pgac_cc_list="gcc xlc";;
3118  irix) pgac_cc_list="cc";; # no gcc
3119     *) pgac_cc_list="gcc cc";;
3120 esac
3121
3122 ac_ext=c
3123 ac_cpp='$CPP $CPPFLAGS'
3124 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3125 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3126 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3127 if test -n "$ac_tool_prefix"; then
3128   for ac_prog in $pgac_cc_list
3129   do
3130     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3131 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3132 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3133 $as_echo_n "checking for $ac_word... " >&6; }
3134 if test "${ac_cv_prog_CC+set}" = set; then
3135   $as_echo_n "(cached) " >&6
3136 else
3137   if test -n "$CC"; then
3138   ac_cv_prog_CC="$CC" # Let the user override the test.
3139 else
3140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3141 for as_dir in $PATH
3142 do
3143   IFS=$as_save_IFS
3144   test -z "$as_dir" && as_dir=.
3145   for ac_exec_ext in '' $ac_executable_extensions; do
3146   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3147     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3148     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3149     break 2
3150   fi
3151 done
3152 done
3153 IFS=$as_save_IFS
3154
3155 fi
3156 fi
3157 CC=$ac_cv_prog_CC
3158 if test -n "$CC"; then
3159   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3160 $as_echo "$CC" >&6; }
3161 else
3162   { $as_echo "$as_me:$LINENO: result: no" >&5
3163 $as_echo "no" >&6; }
3164 fi
3165
3166
3167     test -n "$CC" && break
3168   done
3169 fi
3170 if test -z "$CC"; then
3171   ac_ct_CC=$CC
3172   for ac_prog in $pgac_cc_list
3173 do
3174   # Extract the first word of "$ac_prog", so it can be a program name with args.
3175 set dummy $ac_prog; ac_word=$2
3176 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3177 $as_echo_n "checking for $ac_word... " >&6; }
3178 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3179   $as_echo_n "(cached) " >&6
3180 else
3181   if test -n "$ac_ct_CC"; then
3182   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3183 else
3184 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3185 for as_dir in $PATH
3186 do
3187   IFS=$as_save_IFS
3188   test -z "$as_dir" && as_dir=.
3189   for ac_exec_ext in '' $ac_executable_extensions; do
3190   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3191     ac_cv_prog_ac_ct_CC="$ac_prog"
3192     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3193     break 2
3194   fi
3195 done
3196 done
3197 IFS=$as_save_IFS
3198
3199 fi
3200 fi
3201 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3202 if test -n "$ac_ct_CC"; then
3203   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3204 $as_echo "$ac_ct_CC" >&6; }
3205 else
3206   { $as_echo "$as_me:$LINENO: result: no" >&5
3207 $as_echo "no" >&6; }
3208 fi
3209
3210
3211   test -n "$ac_ct_CC" && break
3212 done
3213
3214   if test "x$ac_ct_CC" = x; then
3215     CC=""
3216   else
3217     case $cross_compiling:$ac_tool_warned in
3218 yes:)
3219 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3220 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3221 ac_tool_warned=yes ;;
3222 esac
3223     CC=$ac_ct_CC
3224   fi
3225 fi
3226
3227
3228 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3229 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3230 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3231 See \`config.log' for more details." >&5
3232 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3233 See \`config.log' for more details." >&2;}
3234    { (exit 1); exit 1; }; }; }
3235
3236 # Provide some information about the compiler.
3237 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3238 set X $ac_compile
3239 ac_compiler=$2
3240 { (ac_try="$ac_compiler --version >&5"
3241 case "(($ac_try" in
3242   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3243   *) ac_try_echo=$ac_try;;
3244 esac
3245 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3246 $as_echo "$ac_try_echo") >&5
3247   (eval "$ac_compiler --version >&5") 2>&5
3248   ac_status=$?
3249   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3250   (exit $ac_status); }
3251 { (ac_try="$ac_compiler -v >&5"
3252 case "(($ac_try" in
3253   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3254   *) ac_try_echo=$ac_try;;
3255 esac
3256 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3257 $as_echo "$ac_try_echo") >&5
3258   (eval "$ac_compiler -v >&5") 2>&5
3259   ac_status=$?
3260   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3261   (exit $ac_status); }
3262 { (ac_try="$ac_compiler -V >&5"
3263 case "(($ac_try" in
3264   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3265   *) ac_try_echo=$ac_try;;
3266 esac
3267 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3268 $as_echo "$ac_try_echo") >&5
3269   (eval "$ac_compiler -V >&5") 2>&5
3270   ac_status=$?
3271   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3272   (exit $ac_status); }
3273
3274 cat >conftest.$ac_ext <<_ACEOF
3275 /* confdefs.h.  */
3276 _ACEOF
3277 cat confdefs.h >>conftest.$ac_ext
3278 cat >>conftest.$ac_ext <<_ACEOF
3279 /* end confdefs.h.  */
3280
3281 int
3282 main ()
3283 {
3284
3285   ;
3286   return 0;
3287 }
3288 _ACEOF
3289 ac_clean_files_save=$ac_clean_files
3290 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3291 # Try to create an executable without -o first, disregard a.out.
3292 # It will help us diagnose broken compilers, and finding out an intuition
3293 # of exeext.
3294 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3295 $as_echo_n "checking for C compiler default output file name... " >&6; }
3296 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3297
3298 # The possible output files:
3299 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3300
3301 ac_rmfiles=
3302 for ac_file in $ac_files
3303 do
3304   case $ac_file in
3305     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3306     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3307   esac
3308 done
3309 rm -f $ac_rmfiles
3310
3311 if { (ac_try="$ac_link_default"
3312 case "(($ac_try" in
3313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3314   *) ac_try_echo=$ac_try;;
3315 esac
3316 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3317 $as_echo "$ac_try_echo") >&5
3318   (eval "$ac_link_default") 2>&5
3319   ac_status=$?
3320   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3321   (exit $ac_status); }; then
3322   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3323 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3324 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3325 # so that the user can short-circuit this test for compilers unknown to
3326 # Autoconf.
3327 for ac_file in $ac_files ''
3328 do
3329   test -f "$ac_file" || continue
3330   case $ac_file in
3331     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3332         ;;
3333     [ab].out )
3334         # We found the default executable, but exeext='' is most
3335         # certainly right.
3336         break;;
3337     *.* )
3338         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3339         then :; else
3340            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3341         fi
3342         # We set ac_cv_exeext here because the later test for it is not
3343         # safe: cross compilers may not add the suffix if given an `-o'
3344         # argument, so we may need to know it at that point already.
3345         # Even if this section looks crufty: it has the advantage of
3346         # actually working.
3347         break;;
3348     * )
3349         break;;
3350   esac
3351 done
3352 test "$ac_cv_exeext" = no && ac_cv_exeext=
3353
3354 else
3355   ac_file=''
3356 fi
3357
3358 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3359 $as_echo "$ac_file" >&6; }
3360 if test -z "$ac_file"; then
3361   $as_echo "$as_me: failed program was:" >&5
3362 sed 's/^/| /' conftest.$ac_ext >&5
3363
3364 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3365 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3366 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3367 See \`config.log' for more details." >&5
3368 $as_echo "$as_me: error: C compiler cannot create executables
3369 See \`config.log' for more details." >&2;}
3370    { (exit 77); exit 77; }; }; }
3371 fi
3372
3373 ac_exeext=$ac_cv_exeext
3374
3375 # Check that the compiler produces executables we can run.  If not, either
3376 # the compiler is broken, or we cross compile.
3377 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3378 $as_echo_n "checking whether the C compiler works... " >&6; }
3379 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3380 # If not cross compiling, check that we can run a simple program.
3381 if test "$cross_compiling" != yes; then
3382   if { ac_try='./$ac_file'
3383   { (case "(($ac_try" in
3384   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3385   *) ac_try_echo=$ac_try;;
3386 esac
3387 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3388 $as_echo "$ac_try_echo") >&5
3389   (eval "$ac_try") 2>&5
3390   ac_status=$?
3391   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3392   (exit $ac_status); }; }; then
3393     cross_compiling=no
3394   else
3395     if test "$cross_compiling" = maybe; then
3396         cross_compiling=yes
3397     else
3398         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3399 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3400 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3401 If you meant to cross compile, use \`--host'.
3402 See \`config.log' for more details." >&5
3403 $as_echo "$as_me: error: cannot run C compiled programs.
3404 If you meant to cross compile, use \`--host'.
3405 See \`config.log' for more details." >&2;}
3406    { (exit 1); exit 1; }; }; }
3407     fi
3408   fi
3409 fi
3410 { $as_echo "$as_me:$LINENO: result: yes" >&5
3411 $as_echo "yes" >&6; }
3412
3413 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3414 ac_clean_files=$ac_clean_files_save
3415 # Check that the compiler produces executables we can run.  If not, either
3416 # the compiler is broken, or we cross compile.
3417 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3418 $as_echo_n "checking whether we are cross compiling... " >&6; }
3419 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3420 $as_echo "$cross_compiling" >&6; }
3421
3422 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3423 $as_echo_n "checking for suffix of executables... " >&6; }
3424 if { (ac_try="$ac_link"
3425 case "(($ac_try" in
3426   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3427   *) ac_try_echo=$ac_try;;
3428 esac
3429 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3430 $as_echo "$ac_try_echo") >&5
3431   (eval "$ac_link") 2>&5
3432   ac_status=$?
3433   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3434   (exit $ac_status); }; then
3435   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3436 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3437 # work properly (i.e., refer to `conftest.exe'), while it won't with
3438 # `rm'.
3439 for ac_file in conftest.exe conftest conftest.*; do
3440   test -f "$ac_file" || continue
3441   case $ac_file in
3442     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3443     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3444           break;;
3445     * ) break;;
3446   esac
3447 done
3448 else
3449   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3450 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3451 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3452 See \`config.log' for more details." >&5
3453 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3454 See \`config.log' for more details." >&2;}
3455    { (exit 1); exit 1; }; }; }
3456 fi
3457
3458 rm -f conftest$ac_cv_exeext
3459 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3460 $as_echo "$ac_cv_exeext" >&6; }
3461
3462 rm -f conftest.$ac_ext
3463 EXEEXT=$ac_cv_exeext
3464 ac_exeext=$EXEEXT
3465 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3466 $as_echo_n "checking for suffix of object files... " >&6; }
3467 if test "${ac_cv_objext+set}" = set; then
3468   $as_echo_n "(cached) " >&6
3469 else
3470   cat >conftest.$ac_ext <<_ACEOF
3471 /* confdefs.h.  */
3472 _ACEOF
3473 cat confdefs.h >>conftest.$ac_ext
3474 cat >>conftest.$ac_ext <<_ACEOF
3475 /* end confdefs.h.  */
3476
3477 int
3478 main ()
3479 {
3480
3481   ;
3482   return 0;
3483 }
3484 _ACEOF
3485 rm -f conftest.o conftest.obj
3486 if { (ac_try="$ac_compile"
3487 case "(($ac_try" in
3488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3489   *) ac_try_echo=$ac_try;;
3490 esac
3491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3492 $as_echo "$ac_try_echo") >&5
3493   (eval "$ac_compile") 2>&5
3494   ac_status=$?
3495   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3496   (exit $ac_status); }; then
3497   for ac_file in conftest.o conftest.obj conftest.*; do
3498   test -f "$ac_file" || continue;
3499   case $ac_file in
3500     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3501     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3502        break;;
3503   esac
3504 done
3505 else
3506   $as_echo "$as_me: failed program was:" >&5
3507 sed 's/^/| /' conftest.$ac_ext >&5
3508
3509 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3510 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3511 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3512 See \`config.log' for more details." >&5
3513 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3514 See \`config.log' for more details." >&2;}
3515    { (exit 1); exit 1; }; }; }
3516 fi
3517
3518 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3519 fi
3520 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3521 $as_echo "$ac_cv_objext" >&6; }
3522 OBJEXT=$ac_cv_objext
3523 ac_objext=$OBJEXT
3524 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3525 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3526 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3527   $as_echo_n "(cached) " >&6
3528 else
3529   cat >conftest.$ac_ext <<_ACEOF
3530 /* confdefs.h.  */
3531 _ACEOF
3532 cat confdefs.h >>conftest.$ac_ext
3533 cat >>conftest.$ac_ext <<_ACEOF
3534 /* end confdefs.h.  */
3535
3536 int
3537 main ()
3538 {
3539 #ifndef __GNUC__
3540        choke me
3541 #endif
3542
3543   ;
3544   return 0;
3545 }
3546 _ACEOF
3547 rm -f conftest.$ac_objext
3548 if { (ac_try="$ac_compile"
3549 case "(($ac_try" in
3550   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3551   *) ac_try_echo=$ac_try;;
3552 esac
3553 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3554 $as_echo "$ac_try_echo") >&5
3555   (eval "$ac_compile") 2>conftest.er1
3556   ac_status=$?
3557   grep -v '^ *+' conftest.er1 >conftest.err
3558   rm -f conftest.er1
3559   cat conftest.err >&5
3560   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3561   (exit $ac_status); } && {
3562          test -z "$ac_c_werror_flag" ||
3563          test ! -s conftest.err
3564        } && test -s conftest.$ac_objext; then
3565   ac_compiler_gnu=yes
3566 else
3567   $as_echo "$as_me: failed program was:" >&5
3568 sed 's/^/| /' conftest.$ac_ext >&5
3569
3570         ac_compiler_gnu=no
3571 fi
3572
3573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3574 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3575
3576 fi
3577 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3578 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3579 if test $ac_compiler_gnu = yes; then
3580   GCC=yes
3581 else
3582   GCC=
3583 fi
3584 ac_test_CFLAGS=${CFLAGS+set}
3585 ac_save_CFLAGS=$CFLAGS
3586 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3587 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3588 if test "${ac_cv_prog_cc_g+set}" = set; then
3589   $as_echo_n "(cached) " >&6
3590 else
3591   ac_save_c_werror_flag=$ac_c_werror_flag
3592    ac_c_werror_flag=yes
3593    ac_cv_prog_cc_g=no
3594    CFLAGS="-g"
3595    cat >conftest.$ac_ext <<_ACEOF
3596 /* confdefs.h.  */
3597 _ACEOF
3598 cat confdefs.h >>conftest.$ac_ext
3599 cat >>conftest.$ac_ext <<_ACEOF
3600 /* end confdefs.h.  */
3601
3602 int
3603 main ()
3604 {
3605
3606   ;
3607   return 0;
3608 }
3609 _ACEOF
3610 rm -f conftest.$ac_objext
3611 if { (ac_try="$ac_compile"
3612 case "(($ac_try" in
3613   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3614   *) ac_try_echo=$ac_try;;
3615 esac
3616 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3617 $as_echo "$ac_try_echo") >&5
3618   (eval "$ac_compile") 2>conftest.er1
3619   ac_status=$?
3620   grep -v '^ *+' conftest.er1 >conftest.err
3621   rm -f conftest.er1
3622   cat conftest.err >&5
3623   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3624   (exit $ac_status); } && {
3625          test -z "$ac_c_werror_flag" ||
3626          test ! -s conftest.err
3627        } && test -s conftest.$ac_objext; then
3628   ac_cv_prog_cc_g=yes
3629 else
3630   $as_echo "$as_me: failed program was:" >&5
3631 sed 's/^/| /' conftest.$ac_ext >&5
3632
3633         CFLAGS=""
3634       cat >conftest.$ac_ext <<_ACEOF
3635 /* confdefs.h.  */
3636 _ACEOF
3637 cat confdefs.h >>conftest.$ac_ext
3638 cat >>conftest.$ac_ext <<_ACEOF
3639 /* end confdefs.h.  */
3640
3641 int
3642 main ()
3643 {
3644
3645   ;
3646   return 0;
3647 }
3648 _ACEOF
3649 rm -f conftest.$ac_objext
3650 if { (ac_try="$ac_compile"
3651 case "(($ac_try" in
3652   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3653   *) ac_try_echo=$ac_try;;
3654 esac
3655 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3656 $as_echo "$ac_try_echo") >&5
3657   (eval "$ac_compile") 2>conftest.er1
3658   ac_status=$?
3659   grep -v '^ *+' conftest.er1 >conftest.err
3660   rm -f conftest.er1
3661   cat conftest.err >&5
3662   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3663   (exit $ac_status); } && {
3664          test -z "$ac_c_werror_flag" ||
3665          test ! -s conftest.err
3666        } && test -s conftest.$ac_objext; then
3667   :
3668 else
3669   $as_echo "$as_me: failed program was:" >&5
3670 sed 's/^/| /' conftest.$ac_ext >&5
3671
3672         ac_c_werror_flag=$ac_save_c_werror_flag
3673          CFLAGS="-g"
3674          cat >conftest.$ac_ext <<_ACEOF
3675 /* confdefs.h.  */
3676 _ACEOF
3677 cat confdefs.h >>conftest.$ac_ext
3678 cat >>conftest.$ac_ext <<_ACEOF
3679 /* end confdefs.h.  */
3680
3681 int
3682 main ()
3683 {
3684
3685   ;
3686   return 0;
3687 }
3688 _ACEOF
3689 rm -f conftest.$ac_objext
3690 if { (ac_try="$ac_compile"
3691 case "(($ac_try" in
3692   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3693   *) ac_try_echo=$ac_try;;
3694 esac
3695 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3696 $as_echo "$ac_try_echo") >&5
3697   (eval "$ac_compile") 2>conftest.er1
3698   ac_status=$?
3699   grep -v '^ *+' conftest.er1 >conftest.err
3700   rm -f conftest.er1
3701   cat conftest.err >&5
3702   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3703   (exit $ac_status); } && {
3704          test -z "$ac_c_werror_flag" ||
3705          test ! -s conftest.err
3706        } && test -s conftest.$ac_objext; then
3707   ac_cv_prog_cc_g=yes
3708 else
3709   $as_echo "$as_me: failed program was:" >&5
3710 sed 's/^/| /' conftest.$ac_ext >&5
3711
3712
3713 fi
3714
3715 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3716 fi
3717
3718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3719 fi
3720
3721 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3722    ac_c_werror_flag=$ac_save_c_werror_flag
3723 fi
3724 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3725 $as_echo "$ac_cv_prog_cc_g" >&6; }
3726 if test "$ac_test_CFLAGS" = set; then
3727   CFLAGS=$ac_save_CFLAGS
3728 elif test $ac_cv_prog_cc_g = yes; then
3729   if test "$GCC" = yes; then
3730     CFLAGS="-g -O2"
3731   else
3732     CFLAGS="-g"
3733   fi
3734 else
3735   if test "$GCC" = yes; then
3736     CFLAGS="-O2"
3737   else
3738     CFLAGS=
3739   fi
3740 fi
3741 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3742 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3743 if test "${ac_cv_prog_cc_c89+set}" = set; then
3744   $as_echo_n "(cached) " >&6
3745 else
3746   ac_cv_prog_cc_c89=no
3747 ac_save_CC=$CC
3748 cat >conftest.$ac_ext <<_ACEOF
3749 /* confdefs.h.  */
3750 _ACEOF
3751 cat confdefs.h >>conftest.$ac_ext
3752 cat >>conftest.$ac_ext <<_ACEOF
3753 /* end confdefs.h.  */
3754 #include <stdarg.h>
3755 #include <stdio.h>
3756 #include <sys/types.h>
3757 #include <sys/stat.h>
3758 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3759 struct buf { int x; };
3760 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3761 static char *e (p, i)
3762      char **p;
3763      int i;
3764 {
3765   return p[i];
3766 }
3767 static char *f (char * (*g) (char **, int), char **p, ...)
3768 {
3769   char *s;
3770   va_list v;
3771   va_start (v,p);
3772   s = g (p, va_arg (v,int));
3773   va_end (v);
3774   return s;
3775 }
3776
3777 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3778    function prototypes and stuff, but not '\xHH' hex character constants.
3779    These don't provoke an error unfortunately, instead are silently treated
3780    as 'x'.  The following induces an error, until -std is added to get
3781    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3782    array size at least.  It's necessary to write '\x00'==0 to get something
3783    that's true only with -std.  */
3784 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3785
3786 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3787    inside strings and character constants.  */
3788 #define FOO(x) 'x'
3789 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3790
3791 int test (int i, double x);
3792 struct s1 {int (*f) (int a);};
3793 struct s2 {int (*f) (double a);};
3794 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3795 int argc;
3796 char **argv;
3797 int
3798 main ()
3799 {
3800 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3801   ;
3802   return 0;
3803 }
3804 _ACEOF
3805 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3806         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3807 do
3808   CC="$ac_save_CC $ac_arg"
3809   rm -f conftest.$ac_objext
3810 if { (ac_try="$ac_compile"
3811 case "(($ac_try" in
3812   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3813   *) ac_try_echo=$ac_try;;
3814 esac
3815 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3816 $as_echo "$ac_try_echo") >&5
3817   (eval "$ac_compile") 2>conftest.er1
3818   ac_status=$?
3819   grep -v '^ *+' conftest.er1 >conftest.err
3820   rm -f conftest.er1
3821   cat conftest.err >&5
3822   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3823   (exit $ac_status); } && {
3824          test -z "$ac_c_werror_flag" ||
3825          test ! -s conftest.err
3826        } && test -s conftest.$ac_objext; then
3827   ac_cv_prog_cc_c89=$ac_arg
3828 else
3829   $as_echo "$as_me: failed program was:" >&5
3830 sed 's/^/| /' conftest.$ac_ext >&5
3831
3832
3833 fi
3834
3835 rm -f core conftest.err conftest.$ac_objext
3836   test "x$ac_cv_prog_cc_c89" != "xno" && break
3837 done
3838 rm -f conftest.$ac_ext
3839 CC=$ac_save_CC
3840
3841 fi
3842 # AC_CACHE_VAL
3843 case "x$ac_cv_prog_cc_c89" in
3844   x)
3845     { $as_echo "$as_me:$LINENO: result: none needed" >&5
3846 $as_echo "none needed" >&6; } ;;
3847   xno)
3848     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3849 $as_echo "unsupported" >&6; } ;;
3850   *)
3851     CC="$CC $ac_cv_prog_cc_c89"
3852     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3853 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3854 esac
3855
3856
3857 ac_ext=c
3858 ac_cpp='$CPP $CPPFLAGS'
3859 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3860 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3861 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3862
3863
3864 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3865 # but has idiosyncrasies of its own.  We assume icc will define
3866 # __INTEL_COMPILER regardless of CFLAGS.
3867
3868 cat >conftest.$ac_ext <<_ACEOF
3869 /* confdefs.h.  */
3870 _ACEOF
3871 cat confdefs.h >>conftest.$ac_ext
3872 cat >>conftest.$ac_ext <<_ACEOF
3873 /* end confdefs.h.  */
3874
3875 int
3876 main ()
3877 {
3878 #ifndef __INTEL_COMPILER
3879 choke me
3880 #endif
3881   ;
3882   return 0;
3883 }
3884 _ACEOF
3885 rm -f conftest.$ac_objext
3886 if { (ac_try="$ac_compile"
3887 case "(($ac_try" in
3888   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3889   *) ac_try_echo=$ac_try;;
3890 esac
3891 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3892 $as_echo "$ac_try_echo") >&5
3893   (eval "$ac_compile") 2>conftest.er1
3894   ac_status=$?
3895   grep -v '^ *+' conftest.er1 >conftest.err
3896   rm -f conftest.er1
3897   cat conftest.err >&5
3898   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3899   (exit $ac_status); } && {
3900          test -z "$ac_c_werror_flag" ||
3901          test ! -s conftest.err
3902        } && test -s conftest.$ac_objext; then
3903   ICC=yes
3904 else
3905   $as_echo "$as_me: failed program was:" >&5
3906 sed 's/^/| /' conftest.$ac_ext >&5
3907
3908         ICC=no
3909 fi
3910
3911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3912
3913 # Check if it's Sun Studio compiler. We assume that
3914 # __SUNPRO_C will be defined for Sun Studio compilers
3915 cat >conftest.$ac_ext <<_ACEOF
3916 /* confdefs.h.  */
3917 _ACEOF
3918 cat confdefs.h >>conftest.$ac_ext
3919 cat >>conftest.$ac_ext <<_ACEOF
3920 /* end confdefs.h.  */
3921
3922 int
3923 main ()
3924 {
3925 #ifndef __SUNPRO_C
3926 choke me
3927 #endif
3928   ;
3929   return 0;
3930 }
3931 _ACEOF
3932 rm -f conftest.$ac_objext
3933 if { (ac_try="$ac_compile"
3934 case "(($ac_try" in
3935   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3936   *) ac_try_echo=$ac_try;;
3937 esac
3938 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3939 $as_echo "$ac_try_echo") >&5
3940   (eval "$ac_compile") 2>conftest.er1
3941   ac_status=$?
3942   grep -v '^ *+' conftest.er1 >conftest.err
3943   rm -f conftest.er1
3944   cat conftest.err >&5
3945   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3946   (exit $ac_status); } && {
3947          test -z "$ac_c_werror_flag" ||
3948          test ! -s conftest.err
3949        } && test -s conftest.$ac_objext; then
3950   SUN_STUDIO_CC=yes
3951 else
3952   $as_echo "$as_me: failed program was:" >&5
3953 sed 's/^/| /' conftest.$ac_ext >&5
3954
3955         SUN_STUDIO_CC=no
3956 fi
3957
3958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3959
3960
3961
3962 unset CFLAGS
3963
3964 #
3965 # Read the template
3966 #
3967 . "$srcdir/src/template/$template" || exit
3968
3969 # CFLAGS are selected so:
3970 # If the user specifies something in the environment, that is used.
3971 # else:  If the template file set something, that is used.
3972 # else:  If coverage was enabled, don't set anything.
3973 # else:  If the compiler is GCC, then we use -O2.
3974 # else:  If the compiler is something else, then we use -O, unless debugging.
3975
3976 if test "$ac_env_CFLAGS_set" = set; then
3977   CFLAGS=$ac_env_CFLAGS_value
3978 elif test "${CFLAGS+set}" = set; then
3979   : # (keep what template set)
3980 elif test "$enable_coverage" = yes; then
3981   : # no optimization by default
3982 elif test "$GCC" = yes; then
3983   CFLAGS="-O2"
3984 else
3985   # if the user selected debug mode, don't use -O
3986   if test "$enable_debug" != yes; then
3987     CFLAGS="-O"
3988   fi
3989 fi
3990
3991 # Some versions of GCC support some additional useful warning flags.
3992 # Check whether they are supported, and add them to CFLAGS if so.
3993 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
3994 # but has its own.  Also check other compiler-specific flags here.
3995
3996 if test "$GCC" = yes -a "$ICC" = no; then
3997   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
3998   # These work in some but not all gcc versions
3999   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
4000 $as_echo_n "checking if $CC supports -Wdeclaration-after-statement... " >&6; }
4001 pgac_save_CFLAGS=$CFLAGS
4002 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
4003 cat >conftest.$ac_ext <<_ACEOF
4004 /* confdefs.h.  */
4005 _ACEOF
4006 cat confdefs.h >>conftest.$ac_ext
4007 cat >>conftest.$ac_ext <<_ACEOF
4008 /* end confdefs.h.  */
4009
4010 int
4011 main ()
4012 {
4013
4014   ;
4015   return 0;
4016 }
4017 _ACEOF
4018 rm -f conftest.$ac_objext
4019 if { (ac_try="$ac_compile"
4020 case "(($ac_try" in
4021   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4022   *) ac_try_echo=$ac_try;;
4023 esac
4024 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4025 $as_echo "$ac_try_echo") >&5
4026   (eval "$ac_compile") 2>conftest.er1
4027   ac_status=$?
4028   grep -v '^ *+' conftest.er1 >conftest.err
4029   rm -f conftest.er1
4030   cat conftest.err >&5
4031   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4032   (exit $ac_status); } && {
4033          test -z "$ac_c_werror_flag" ||
4034          test ! -s conftest.err
4035        } && test -s conftest.$ac_objext; then
4036   { $as_echo "$as_me:$LINENO: result: yes" >&5
4037 $as_echo "yes" >&6; }
4038 else
4039   $as_echo "$as_me: failed program was:" >&5
4040 sed 's/^/| /' conftest.$ac_ext >&5
4041
4042         CFLAGS="$pgac_save_CFLAGS"
4043                     { $as_echo "$as_me:$LINENO: result: no" >&5
4044 $as_echo "no" >&6; }
4045 fi
4046
4047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4048
4049   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
4050 $as_echo_n "checking if $CC supports -Wendif-labels... " >&6; }
4051 pgac_save_CFLAGS=$CFLAGS
4052 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4053 cat >conftest.$ac_ext <<_ACEOF
4054 /* confdefs.h.  */
4055 _ACEOF
4056 cat confdefs.h >>conftest.$ac_ext
4057 cat >>conftest.$ac_ext <<_ACEOF
4058 /* end confdefs.h.  */
4059
4060 int
4061 main ()
4062 {
4063
4064   ;
4065   return 0;
4066 }
4067 _ACEOF
4068 rm -f conftest.$ac_objext
4069 if { (ac_try="$ac_compile"
4070 case "(($ac_try" in
4071   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4072   *) ac_try_echo=$ac_try;;
4073 esac
4074 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4075 $as_echo "$ac_try_echo") >&5
4076   (eval "$ac_compile") 2>conftest.er1
4077   ac_status=$?
4078   grep -v '^ *+' conftest.er1 >conftest.err
4079   rm -f conftest.er1
4080   cat conftest.err >&5
4081   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4082   (exit $ac_status); } && {
4083          test -z "$ac_c_werror_flag" ||
4084          test ! -s conftest.err
4085        } && test -s conftest.$ac_objext; then
4086   { $as_echo "$as_me:$LINENO: result: yes" >&5
4087 $as_echo "yes" >&6; }
4088 else
4089   $as_echo "$as_me: failed program was:" >&5
4090 sed 's/^/| /' conftest.$ac_ext >&5
4091
4092         CFLAGS="$pgac_save_CFLAGS"
4093                     { $as_echo "$as_me:$LINENO: result: no" >&5
4094 $as_echo "no" >&6; }
4095 fi
4096
4097 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4098
4099   # Disable strict-aliasing rules; needed for gcc 3.3+
4100   { $as_echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
4101 $as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; }
4102 pgac_save_CFLAGS=$CFLAGS
4103 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4104 cat >conftest.$ac_ext <<_ACEOF
4105 /* confdefs.h.  */
4106 _ACEOF
4107 cat confdefs.h >>conftest.$ac_ext
4108 cat >>conftest.$ac_ext <<_ACEOF
4109 /* end confdefs.h.  */
4110
4111 int
4112 main ()
4113 {
4114
4115   ;
4116   return 0;
4117 }
4118 _ACEOF
4119 rm -f conftest.$ac_objext
4120 if { (ac_try="$ac_compile"
4121 case "(($ac_try" in
4122   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4123   *) ac_try_echo=$ac_try;;
4124 esac
4125 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4126 $as_echo "$ac_try_echo") >&5
4127   (eval "$ac_compile") 2>conftest.er1
4128   ac_status=$?
4129   grep -v '^ *+' conftest.er1 >conftest.err
4130   rm -f conftest.er1
4131   cat conftest.err >&5
4132   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4133   (exit $ac_status); } && {
4134          test -z "$ac_c_werror_flag" ||
4135          test ! -s conftest.err
4136        } && test -s conftest.$ac_objext; then
4137   { $as_echo "$as_me:$LINENO: result: yes" >&5
4138 $as_echo "yes" >&6; }
4139 else
4140   $as_echo "$as_me: failed program was:" >&5
4141 sed 's/^/| /' conftest.$ac_ext >&5
4142
4143         CFLAGS="$pgac_save_CFLAGS"
4144                     { $as_echo "$as_me:$LINENO: result: no" >&5
4145 $as_echo "no" >&6; }
4146 fi
4147
4148 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4149
4150   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4151   { $as_echo "$as_me:$LINENO: checking if $CC supports -fwrapv" >&5
4152 $as_echo_n "checking if $CC supports -fwrapv... " >&6; }
4153 pgac_save_CFLAGS=$CFLAGS
4154 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4155 cat >conftest.$ac_ext <<_ACEOF
4156 /* confdefs.h.  */
4157 _ACEOF
4158 cat confdefs.h >>conftest.$ac_ext
4159 cat >>conftest.$ac_ext <<_ACEOF
4160 /* end confdefs.h.  */
4161
4162 int
4163 main ()
4164 {
4165
4166   ;
4167   return 0;
4168 }
4169 _ACEOF
4170 rm -f conftest.$ac_objext
4171 if { (ac_try="$ac_compile"
4172 case "(($ac_try" in
4173   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4174   *) ac_try_echo=$ac_try;;
4175 esac
4176 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4177 $as_echo "$ac_try_echo") >&5
4178   (eval "$ac_compile") 2>conftest.er1
4179   ac_status=$?
4180   grep -v '^ *+' conftest.er1 >conftest.err
4181   rm -f conftest.er1
4182   cat conftest.err >&5
4183   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4184   (exit $ac_status); } && {
4185          test -z "$ac_c_werror_flag" ||
4186          test ! -s conftest.err
4187        } && test -s conftest.$ac_objext; then
4188   { $as_echo "$as_me:$LINENO: result: yes" >&5
4189 $as_echo "yes" >&6; }
4190 else
4191   $as_echo "$as_me: failed program was:" >&5
4192 sed 's/^/| /' conftest.$ac_ext >&5
4193
4194         CFLAGS="$pgac_save_CFLAGS"
4195                     { $as_echo "$as_me:$LINENO: result: no" >&5
4196 $as_echo "no" >&6; }
4197 fi
4198
4199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4200
4201 elif test "$ICC" = yes; then
4202   # Intel's compiler has a bug/misoptimization in checking for
4203   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4204   { $as_echo "$as_me:$LINENO: checking if $CC supports -mp1" >&5
4205 $as_echo_n "checking if $CC supports -mp1... " >&6; }
4206 pgac_save_CFLAGS=$CFLAGS
4207 CFLAGS="$pgac_save_CFLAGS -mp1"
4208 cat >conftest.$ac_ext <<_ACEOF
4209 /* confdefs.h.  */
4210 _ACEOF
4211 cat confdefs.h >>conftest.$ac_ext
4212 cat >>conftest.$ac_ext <<_ACEOF
4213 /* end confdefs.h.  */
4214
4215 int
4216 main ()
4217 {
4218
4219   ;
4220   return 0;
4221 }
4222 _ACEOF
4223 rm -f conftest.$ac_objext
4224 if { (ac_try="$ac_compile"
4225 case "(($ac_try" in
4226   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4227   *) ac_try_echo=$ac_try;;
4228 esac
4229 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4230 $as_echo "$ac_try_echo") >&5
4231   (eval "$ac_compile") 2>conftest.er1
4232   ac_status=$?
4233   grep -v '^ *+' conftest.er1 >conftest.err
4234   rm -f conftest.er1
4235   cat conftest.err >&5
4236   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4237   (exit $ac_status); } && {
4238          test -z "$ac_c_werror_flag" ||
4239          test ! -s conftest.err
4240        } && test -s conftest.$ac_objext; then
4241   { $as_echo "$as_me:$LINENO: result: yes" >&5
4242 $as_echo "yes" >&6; }
4243 else
4244   $as_echo "$as_me: failed program was:" >&5
4245 sed 's/^/| /' conftest.$ac_ext >&5
4246
4247         CFLAGS="$pgac_save_CFLAGS"
4248                     { $as_echo "$as_me:$LINENO: result: no" >&5
4249 $as_echo "no" >&6; }
4250 fi
4251
4252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4253
4254   # Make sure strict aliasing is off (though this is said to be the default)
4255   { $as_echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
4256 $as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; }
4257 pgac_save_CFLAGS=$CFLAGS
4258 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4259 cat >conftest.$ac_ext <<_ACEOF
4260 /* confdefs.h.  */
4261 _ACEOF
4262 cat confdefs.h >>conftest.$ac_ext
4263 cat >>conftest.$ac_ext <<_ACEOF
4264 /* end confdefs.h.  */
4265
4266 int
4267 main ()
4268 {
4269
4270   ;
4271   return 0;
4272 }
4273 _ACEOF
4274 rm -f conftest.$ac_objext
4275 if { (ac_try="$ac_compile"
4276 case "(($ac_try" in
4277   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4278   *) ac_try_echo=$ac_try;;
4279 esac
4280 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4281 $as_echo "$ac_try_echo") >&5
4282   (eval "$ac_compile") 2>conftest.er1
4283   ac_status=$?
4284   grep -v '^ *+' conftest.er1 >conftest.err
4285   rm -f conftest.er1
4286   cat conftest.err >&5
4287   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4288   (exit $ac_status); } && {
4289          test -z "$ac_c_werror_flag" ||
4290          test ! -s conftest.err
4291        } && test -s conftest.$ac_objext; then
4292   { $as_echo "$as_me:$LINENO: result: yes" >&5
4293 $as_echo "yes" >&6; }
4294 else
4295   $as_echo "$as_me: failed program was:" >&5
4296 sed 's/^/| /' conftest.$ac_ext >&5
4297
4298         CFLAGS="$pgac_save_CFLAGS"
4299                     { $as_echo "$as_me:$LINENO: result: no" >&5
4300 $as_echo "no" >&6; }
4301 fi
4302
4303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4304
4305 elif test "$PORTNAME" = "aix"; then
4306   # AIX's xlc has to have strict aliasing turned off too
4307   { $as_echo "$as_me:$LINENO: checking if $CC supports -qnoansialias" >&5
4308 $as_echo_n "checking if $CC supports -qnoansialias... " >&6; }
4309 pgac_save_CFLAGS=$CFLAGS
4310 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4311 cat >conftest.$ac_ext <<_ACEOF
4312 /* confdefs.h.  */
4313 _ACEOF
4314 cat confdefs.h >>conftest.$ac_ext
4315 cat >>conftest.$ac_ext <<_ACEOF
4316 /* end confdefs.h.  */
4317
4318 int
4319 main ()
4320 {
4321
4322   ;
4323   return 0;
4324 }
4325 _ACEOF
4326 rm -f conftest.$ac_objext
4327 if { (ac_try="$ac_compile"
4328 case "(($ac_try" in
4329   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4330   *) ac_try_echo=$ac_try;;
4331 esac
4332 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4333 $as_echo "$ac_try_echo") >&5
4334   (eval "$ac_compile") 2>conftest.er1
4335   ac_status=$?
4336   grep -v '^ *+' conftest.er1 >conftest.err
4337   rm -f conftest.er1
4338   cat conftest.err >&5
4339   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4340   (exit $ac_status); } && {
4341          test -z "$ac_c_werror_flag" ||
4342          test ! -s conftest.err
4343        } && test -s conftest.$ac_objext; then
4344   { $as_echo "$as_me:$LINENO: result: yes" >&5
4345 $as_echo "yes" >&6; }
4346 else
4347   $as_echo "$as_me: failed program was:" >&5
4348 sed 's/^/| /' conftest.$ac_ext >&5
4349
4350         CFLAGS="$pgac_save_CFLAGS"
4351                     { $as_echo "$as_me:$LINENO: result: no" >&5
4352 $as_echo "no" >&6; }
4353 fi
4354
4355 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4356
4357 fi
4358
4359 # supply -g if --enable-debug
4360 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4361   CFLAGS="$CFLAGS -g"
4362 fi
4363
4364 # enable code coverage if --enable-coverage
4365 if test "$enable_coverage" = yes; then
4366   if test "$GCC" = yes; then
4367     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4368   else
4369     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4370 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4371    { (exit 1); exit 1; }; }
4372   fi
4373 fi
4374
4375 # enable profiling if --enable-profiling
4376 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4377   if test "$GCC" = yes; then
4378
4379 cat >>confdefs.h <<\_ACEOF
4380 #define PROFILE_PID_DIR 1
4381 _ACEOF
4382
4383     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4384   else
4385     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4386 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4387    { (exit 1); exit 1; }; }
4388   fi
4389 fi
4390
4391 # We already have this in Makefile.win32, but configure needs it too
4392 if test "$PORTNAME" = "win32"; then
4393   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4394 fi
4395
4396 # Check if the compiler still works with the template settings
4397 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4398 $as_echo_n "checking whether the C compiler still works... " >&6; }
4399 cat >conftest.$ac_ext <<_ACEOF
4400 /* confdefs.h.  */
4401 _ACEOF
4402 cat confdefs.h >>conftest.$ac_ext
4403 cat >>conftest.$ac_ext <<_ACEOF
4404 /* end confdefs.h.  */
4405
4406 int
4407 main ()
4408 {
4409 return 0;
4410   ;
4411   return 0;
4412 }
4413 _ACEOF
4414 rm -f conftest.$ac_objext conftest$ac_exeext
4415 if { (ac_try="$ac_link"
4416 case "(($ac_try" in
4417   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4418   *) ac_try_echo=$ac_try;;
4419 esac
4420 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4421 $as_echo "$ac_try_echo") >&5
4422   (eval "$ac_link") 2>conftest.er1
4423   ac_status=$?
4424   grep -v '^ *+' conftest.er1 >conftest.err
4425   rm -f conftest.er1
4426   cat conftest.err >&5
4427   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4428   (exit $ac_status); } && {
4429          test -z "$ac_c_werror_flag" ||
4430          test ! -s conftest.err
4431        } && test -s conftest$ac_exeext && {
4432          test "$cross_compiling" = yes ||
4433          $as_test_x conftest$ac_exeext
4434        }; then
4435   { $as_echo "$as_me:$LINENO: result: yes" >&5
4436 $as_echo "yes" >&6; }
4437 else
4438   $as_echo "$as_me: failed program was:" >&5
4439 sed 's/^/| /' conftest.$ac_ext >&5
4440
4441         { $as_echo "$as_me:$LINENO: result: no" >&5
4442 $as_echo "no" >&6; }
4443    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4444 $as_echo "$as_me: error: cannot proceed" >&2;}
4445    { (exit 1); exit 1; }; }
4446 fi
4447
4448 rm -rf conftest.dSYM
4449 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4450       conftest$ac_exeext conftest.$ac_ext
4451
4452 # Defend against gcc -ffast-math
4453 if test "$GCC" = yes; then
4454 cat >conftest.$ac_ext <<_ACEOF
4455 /* confdefs.h.  */
4456 _ACEOF
4457 cat confdefs.h >>conftest.$ac_ext
4458 cat >>conftest.$ac_ext <<_ACEOF
4459 /* end confdefs.h.  */
4460
4461 int
4462 main ()
4463 {
4464 #ifdef __FAST_MATH__
4465 choke me
4466 #endif
4467   ;
4468   return 0;
4469 }
4470 _ACEOF
4471 rm -f conftest.$ac_objext
4472 if { (ac_try="$ac_compile"
4473 case "(($ac_try" in
4474   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4475   *) ac_try_echo=$ac_try;;
4476 esac
4477 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4478 $as_echo "$ac_try_echo") >&5
4479   (eval "$ac_compile") 2>conftest.er1
4480   ac_status=$?
4481   grep -v '^ *+' conftest.er1 >conftest.err
4482   rm -f conftest.er1
4483   cat conftest.err >&5
4484   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4485   (exit $ac_status); } && {
4486          test -z "$ac_c_werror_flag" ||
4487          test ! -s conftest.err
4488        } && test -s conftest.$ac_objext; then
4489   :
4490 else
4491   $as_echo "$as_me: failed program was:" >&5
4492 sed 's/^/| /' conftest.$ac_ext >&5
4493
4494         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4495 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4496    { (exit 1); exit 1; }; }
4497 fi
4498
4499 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4500 fi
4501
4502 ac_ext=c
4503 ac_cpp='$CPP $CPPFLAGS'
4504 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4505 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4506 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4507 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4508 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4509 # On Suns, sometimes $CPP names a directory.
4510 if test -n "$CPP" && test -d "$CPP"; then
4511   CPP=
4512 fi
4513 if test -z "$CPP"; then
4514   if test "${ac_cv_prog_CPP+set}" = set; then
4515   $as_echo_n "(cached) " >&6
4516 else
4517       # Double quotes because CPP needs to be expanded
4518     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4519     do
4520       ac_preproc_ok=false
4521 for ac_c_preproc_warn_flag in '' yes
4522 do
4523   # Use a header file that comes with gcc, so configuring glibc
4524   # with a fresh cross-compiler works.
4525   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4526   # <limits.h> exists even on freestanding compilers.
4527   # On the NeXT, cc -E runs the code through the compiler's parser,
4528   # not just through cpp. "Syntax error" is here to catch this case.
4529   cat >conftest.$ac_ext <<_ACEOF
4530 /* confdefs.h.  */
4531 _ACEOF
4532 cat confdefs.h >>conftest.$ac_ext
4533 cat >>conftest.$ac_ext <<_ACEOF
4534 /* end confdefs.h.  */
4535 #ifdef __STDC__
4536 # include <limits.h>
4537 #else
4538 # include <assert.h>
4539 #endif
4540                      Syntax error
4541 _ACEOF
4542 if { (ac_try="$ac_cpp conftest.$ac_ext"
4543 case "(($ac_try" in
4544   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4545   *) ac_try_echo=$ac_try;;
4546 esac
4547 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4548 $as_echo "$ac_try_echo") >&5
4549   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4550   ac_status=$?
4551   grep -v '^ *+' conftest.er1 >conftest.err
4552   rm -f conftest.er1
4553   cat conftest.err >&5
4554   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4555   (exit $ac_status); } >/dev/null && {
4556          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4557          test ! -s conftest.err
4558        }; then
4559   :
4560 else
4561   $as_echo "$as_me: failed program was:" >&5
4562 sed 's/^/| /' conftest.$ac_ext >&5
4563
4564   # Broken: fails on valid input.
4565 continue
4566 fi
4567
4568 rm -f conftest.err conftest.$ac_ext
4569
4570   # OK, works on sane cases.  Now check whether nonexistent headers
4571   # can be detected and how.
4572   cat >conftest.$ac_ext <<_ACEOF
4573 /* confdefs.h.  */
4574 _ACEOF
4575 cat confdefs.h >>conftest.$ac_ext
4576 cat >>conftest.$ac_ext <<_ACEOF
4577 /* end confdefs.h.  */
4578 #include <ac_nonexistent.h>
4579 _ACEOF
4580 if { (ac_try="$ac_cpp conftest.$ac_ext"
4581 case "(($ac_try" in
4582   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4583   *) ac_try_echo=$ac_try;;
4584 esac
4585 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4586 $as_echo "$ac_try_echo") >&5
4587   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4588   ac_status=$?
4589   grep -v '^ *+' conftest.er1 >conftest.err
4590   rm -f conftest.er1
4591   cat conftest.err >&5
4592   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4593   (exit $ac_status); } >/dev/null && {
4594          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4595          test ! -s conftest.err
4596        }; then
4597   # Broken: success on invalid input.
4598 continue
4599 else
4600   $as_echo "$as_me: failed program was:" >&5
4601 sed 's/^/| /' conftest.$ac_ext >&5
4602
4603   # Passes both tests.
4604 ac_preproc_ok=:
4605 break
4606 fi
4607
4608 rm -f conftest.err conftest.$ac_ext
4609
4610 done
4611 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4612 rm -f conftest.err conftest.$ac_ext
4613 if $ac_preproc_ok; then
4614   break
4615 fi
4616
4617     done
4618     ac_cv_prog_CPP=$CPP
4619
4620 fi
4621   CPP=$ac_cv_prog_CPP
4622 else
4623   ac_cv_prog_CPP=$CPP
4624 fi
4625 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
4626 $as_echo "$CPP" >&6; }
4627 ac_preproc_ok=false
4628 for ac_c_preproc_warn_flag in '' yes
4629 do
4630   # Use a header file that comes with gcc, so configuring glibc
4631   # with a fresh cross-compiler works.
4632   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4633   # <limits.h> exists even on freestanding compilers.
4634   # On the NeXT, cc -E runs the code through the compiler's parser,
4635   # not just through cpp. "Syntax error" is here to catch this case.
4636   cat >conftest.$ac_ext <<_ACEOF
4637 /* confdefs.h.  */
4638 _ACEOF
4639 cat confdefs.h >>conftest.$ac_ext
4640 cat >>conftest.$ac_ext <<_ACEOF
4641 /* end confdefs.h.  */
4642 #ifdef __STDC__
4643 # include <limits.h>
4644 #else
4645 # include <assert.h>
4646 #endif
4647                      Syntax error
4648 _ACEOF
4649 if { (ac_try="$ac_cpp conftest.$ac_ext"
4650 case "(($ac_try" in
4651   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4652   *) ac_try_echo=$ac_try;;
4653 esac
4654 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4655 $as_echo "$ac_try_echo") >&5
4656   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4657   ac_status=$?
4658   grep -v '^ *+' conftest.er1 >conftest.err
4659   rm -f conftest.er1
4660   cat conftest.err >&5
4661   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4662   (exit $ac_status); } >/dev/null && {
4663          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4664          test ! -s conftest.err
4665        }; then
4666   :
4667 else
4668   $as_echo "$as_me: failed program was:" >&5
4669 sed 's/^/| /' conftest.$ac_ext >&5
4670
4671   # Broken: fails on valid input.
4672 continue
4673 fi
4674
4675 rm -f conftest.err conftest.$ac_ext
4676
4677   # OK, works on sane cases.  Now check whether nonexistent headers
4678   # can be detected and how.
4679   cat >conftest.$ac_ext <<_ACEOF
4680 /* confdefs.h.  */
4681 _ACEOF
4682 cat confdefs.h >>conftest.$ac_ext
4683 cat >>conftest.$ac_ext <<_ACEOF
4684 /* end confdefs.h.  */
4685 #include <ac_nonexistent.h>
4686 _ACEOF
4687 if { (ac_try="$ac_cpp conftest.$ac_ext"
4688 case "(($ac_try" in
4689   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4690   *) ac_try_echo=$ac_try;;
4691 esac
4692 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4693 $as_echo "$ac_try_echo") >&5
4694   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4695   ac_status=$?
4696   grep -v '^ *+' conftest.er1 >conftest.err
4697   rm -f conftest.er1
4698   cat conftest.err >&5
4699   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4700   (exit $ac_status); } >/dev/null && {
4701          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4702          test ! -s conftest.err
4703        }; then
4704   # Broken: success on invalid input.
4705 continue
4706 else
4707   $as_echo "$as_me: failed program was:" >&5
4708 sed 's/^/| /' conftest.$ac_ext >&5
4709
4710   # Passes both tests.
4711 ac_preproc_ok=:
4712 break
4713 fi
4714
4715 rm -f conftest.err conftest.$ac_ext
4716
4717 done
4718 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4719 rm -f conftest.err conftest.$ac_ext
4720 if $ac_preproc_ok; then
4721   :
4722 else
4723   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4724 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4725 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4726 See \`config.log' for more details." >&5
4727 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4728 See \`config.log' for more details." >&2;}
4729    { (exit 1); exit 1; }; }; }
4730 fi
4731
4732 ac_ext=c
4733 ac_cpp='$CPP $CPPFLAGS'
4734 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4735 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4736 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4737
4738
4739
4740
4741 #
4742 # Set up TAS assembly code if needed; the template file has now had its
4743 # chance to request this.
4744 #
4745 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4746
4747
4748 if test "$need_tas" = yes ; then
4749   TAS=tas.o
4750 else
4751   TAS=""
4752 fi
4753
4754
4755
4756 #
4757 # Automatic dependency tracking
4758 #
4759
4760
4761 # Check whether --enable-depend was given.
4762 if test "${enable_depend+set}" = set; then
4763   enableval=$enable_depend;
4764   case $enableval in
4765     yes)
4766       autodepend=yes
4767       ;;
4768     no)
4769       :
4770       ;;
4771     *)
4772       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4773 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4774    { (exit 1); exit 1; }; }
4775       ;;
4776   esac
4777
4778 else
4779   enable_depend=no
4780
4781 fi
4782
4783
4784
4785
4786
4787 #
4788 # Enable assert checks
4789 #
4790
4791
4792 # Check whether --enable-cassert was given.
4793 if test "${enable_cassert+set}" = set; then
4794   enableval=$enable_cassert;
4795   case $enableval in
4796     yes)
4797
4798 cat >>confdefs.h <<\_ACEOF
4799 #define USE_ASSERT_CHECKING 1
4800 _ACEOF
4801
4802       ;;
4803     no)
4804       :
4805       ;;
4806     *)
4807       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4808 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4809    { (exit 1); exit 1; }; }
4810       ;;
4811   esac
4812
4813 else
4814   enable_cassert=no
4815
4816 fi
4817
4818
4819
4820
4821 #
4822 # Include directories
4823 #
4824 ac_save_IFS=$IFS
4825 IFS="${IFS}${PATH_SEPARATOR}"
4826 # SRCH_INC comes from the template file
4827 for dir in $with_includes $SRCH_INC; do
4828   if test -d "$dir"; then
4829     INCLUDES="$INCLUDES -I$dir"
4830   else
4831     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4832 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4833   fi
4834 done
4835 IFS=$ac_save_IFS
4836
4837
4838
4839 #
4840 # Library directories
4841 #
4842 ac_save_IFS=$IFS
4843 IFS="${IFS}${PATH_SEPARATOR}"
4844 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4845 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4846   if test -d "$dir"; then
4847     LIBDIRS="$LIBDIRS -L$dir"
4848   else
4849     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4850 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4851   fi
4852 done
4853 IFS=$ac_save_IFS
4854
4855 #
4856 # Enable thread-safe client libraries
4857 #
4858 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4859 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
4860
4861
4862 # Check whether --enable-thread-safety was given.
4863 if test "${enable_thread_safety+set}" = set; then
4864   enableval=$enable_thread_safety;
4865   case $enableval in
4866     yes)
4867       :
4868       ;;
4869     no)
4870       :
4871       ;;
4872     *)
4873       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4874 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4875    { (exit 1); exit 1; }; }
4876       ;;
4877   esac
4878
4879 else
4880   enable_thread_safety=yes
4881
4882 fi
4883
4884
4885 if test "$enable_thread_safety" = yes; then
4886
4887 cat >>confdefs.h <<\_ACEOF
4888 #define ENABLE_THREAD_SAFETY 1
4889 _ACEOF
4890
4891 fi
4892 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
4893 $as_echo "$enable_thread_safety" >&6; }
4894
4895
4896 #
4897 # Optionally build Tcl modules (PL/Tcl)
4898 #
4899 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
4900 $as_echo_n "checking whether to build with Tcl... " >&6; }
4901
4902
4903
4904 # Check whether --with-tcl was given.
4905 if test "${with_tcl+set}" = set; then
4906   withval=$with_tcl;
4907   case $withval in
4908     yes)
4909       :
4910       ;;
4911     no)
4912       :
4913       ;;
4914     *)
4915       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
4916 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
4917    { (exit 1); exit 1; }; }
4918       ;;
4919   esac
4920
4921 else
4922   with_tcl=no
4923
4924 fi
4925
4926
4927 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
4928 $as_echo "$with_tcl" >&6; }
4929
4930
4931 # We see if the path to the Tcl/Tk configuration scripts is specified.
4932 # This will override the use of tclsh to find the paths to search.
4933
4934
4935
4936
4937 # Check whether --with-tclconfig was given.
4938 if test "${with_tclconfig+set}" = set; then
4939   withval=$with_tclconfig;
4940   case $withval in
4941     yes)
4942       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4943 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4944    { (exit 1); exit 1; }; }
4945       ;;
4946     no)
4947       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4948 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4949    { (exit 1); exit 1; }; }
4950       ;;
4951     *)
4952
4953       ;;
4954   esac
4955
4956 fi
4957
4958
4959
4960 #
4961 # Optionally build Perl modules (PL/Perl)
4962 #
4963 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
4964 $as_echo_n "checking whether to build Perl modules... " >&6; }
4965
4966
4967
4968 # Check whether --with-perl was given.
4969 if test "${with_perl+set}" = set; then
4970   withval=$with_perl;
4971   case $withval in
4972     yes)
4973       :
4974       ;;
4975     no)
4976       :
4977       ;;
4978     *)
4979       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
4980 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
4981    { (exit 1); exit 1; }; }
4982       ;;
4983   esac
4984
4985 else
4986   with_perl=no
4987
4988 fi
4989
4990
4991 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
4992 $as_echo "$with_perl" >&6; }
4993
4994
4995 #
4996 # Optionally build Python modules (PL/Python)
4997 #
4998 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
4999 $as_echo_n "checking whether to build Python modules... " >&6; }
5000
5001
5002
5003 # Check whether --with-python was given.
5004 if test "${with_python+set}" = set; then
5005   withval=$with_python;
5006   case $withval in
5007     yes)
5008       :
5009       ;;
5010     no)
5011       :
5012       ;;
5013     *)
5014       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5015 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5016    { (exit 1); exit 1; }; }
5017       ;;
5018   esac
5019
5020 else
5021   with_python=no
5022
5023 fi
5024
5025
5026 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5027 $as_echo "$with_python" >&6; }
5028
5029
5030 #
5031 # GSSAPI
5032 #
5033 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5034 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5035
5036
5037
5038 # Check whether --with-gssapi was given.
5039 if test "${with_gssapi+set}" = set; then
5040   withval=$with_gssapi;
5041   case $withval in
5042     yes)
5043
5044
5045 cat >>confdefs.h <<\_ACEOF
5046 #define ENABLE_GSS 1
5047 _ACEOF
5048
5049   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5050
5051       ;;
5052     no)
5053       :
5054       ;;
5055     *)
5056       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5057 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5058    { (exit 1); exit 1; }; }
5059       ;;
5060   esac
5061
5062 else
5063   with_gssapi=no
5064
5065 fi
5066
5067
5068 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5069 $as_echo "$with_gssapi" >&6; }
5070
5071
5072 #
5073 # Kerberos 5
5074 #
5075 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5076 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5077
5078
5079
5080 # Check whether --with-krb5 was given.
5081 if test "${with_krb5+set}" = set; then
5082   withval=$with_krb5;
5083   case $withval in
5084     yes)
5085
5086
5087 cat >>confdefs.h <<\_ACEOF
5088 #define KRB5 1
5089 _ACEOF
5090
5091   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5092
5093       ;;
5094     no)
5095       :
5096       ;;
5097     *)
5098       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5099 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5100    { (exit 1); exit 1; }; }
5101       ;;
5102   esac
5103
5104 else
5105   with_krb5=no
5106
5107 fi
5108
5109
5110 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5111 $as_echo "$with_krb5" >&6; }
5112
5113
5114
5115
5116
5117
5118 #
5119 # Kerberos configuration parameters
5120 #
5121
5122
5123
5124 # Check whether --with-krb-srvnam was given.
5125 if test "${with_krb_srvnam+set}" = set; then
5126   withval=$with_krb_srvnam;
5127   case $withval in
5128     yes)
5129       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5130 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5131    { (exit 1); exit 1; }; }
5132       ;;
5133     no)
5134       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5135 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5136    { (exit 1); exit 1; }; }
5137       ;;
5138     *)
5139
5140       ;;
5141   esac
5142
5143 else
5144   with_krb_srvnam="postgres"
5145 fi
5146
5147
5148
5149 cat >>confdefs.h <<_ACEOF
5150 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5151 _ACEOF
5152
5153
5154
5155 #
5156 # PAM
5157 #
5158 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5159 $as_echo_n "checking whether to build with PAM support... " >&6; }
5160
5161
5162
5163 # Check whether --with-pam was given.
5164 if test "${with_pam+set}" = set; then
5165   withval=$with_pam;
5166   case $withval in
5167     yes)
5168
5169 cat >>confdefs.h <<\_ACEOF
5170 #define USE_PAM 1
5171 _ACEOF
5172
5173       ;;
5174     no)
5175       :
5176       ;;
5177     *)
5178       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5179 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5180    { (exit 1); exit 1; }; }
5181       ;;
5182   esac
5183
5184 else
5185   with_pam=no
5186
5187 fi
5188
5189
5190 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5191 $as_echo "$with_pam" >&6; }
5192
5193
5194
5195 #
5196 # LDAP
5197 #
5198 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5199 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5200
5201
5202
5203 # Check whether --with-ldap was given.
5204 if test "${with_ldap+set}" = set; then
5205   withval=$with_ldap;
5206   case $withval in
5207     yes)
5208
5209 cat >>confdefs.h <<\_ACEOF
5210 #define USE_LDAP 1
5211 _ACEOF
5212
5213       ;;
5214     no)
5215       :
5216       ;;
5217     *)
5218       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5219 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5220    { (exit 1); exit 1; }; }
5221       ;;
5222   esac
5223
5224 else
5225   with_ldap=no
5226
5227 fi
5228
5229
5230 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5231 $as_echo "$with_ldap" >&6; }
5232
5233
5234
5235 #
5236 # Bonjour
5237 #
5238 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5239 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5240
5241
5242
5243 # Check whether --with-bonjour was given.
5244 if test "${with_bonjour+set}" = set; then
5245   withval=$with_bonjour;
5246   case $withval in
5247     yes)
5248
5249 cat >>confdefs.h <<\_ACEOF
5250 #define USE_BONJOUR 1
5251 _ACEOF
5252
5253       ;;
5254     no)
5255       :
5256       ;;
5257     *)
5258       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5259 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5260    { (exit 1); exit 1; }; }
5261       ;;
5262   esac
5263
5264 else
5265   with_bonjour=no
5266
5267 fi
5268
5269
5270 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5271 $as_echo "$with_bonjour" >&6; }
5272
5273
5274
5275 #
5276 # OpenSSL
5277 #
5278 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5279 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5280
5281
5282
5283 # Check whether --with-openssl was given.
5284 if test "${with_openssl+set}" = set; then
5285   withval=$with_openssl;
5286   case $withval in
5287     yes)
5288
5289 cat >>confdefs.h <<\_ACEOF
5290 #define USE_SSL 1
5291 _ACEOF
5292
5293       ;;
5294     no)
5295       :
5296       ;;
5297     *)
5298       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5299 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5300    { (exit 1); exit 1; }; }
5301       ;;
5302   esac
5303
5304 else
5305   with_openssl=no
5306
5307 fi
5308
5309
5310 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5311 $as_echo "$with_openssl" >&6; }
5312
5313
5314
5315 #
5316 # Readline
5317 #
5318
5319
5320
5321 # Check whether --with-readline was given.
5322 if test "${with_readline+set}" = set; then
5323   withval=$with_readline;
5324   case $withval in
5325     yes)
5326       :
5327       ;;
5328     no)
5329       :
5330       ;;
5331     *)
5332       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5333 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5334    { (exit 1); exit 1; }; }
5335       ;;
5336   esac
5337
5338 else
5339   with_readline=yes
5340
5341 fi
5342
5343
5344 # readline on MinGW has problems with backslashes in psql and other bugs.
5345 # This is particularly a problem with non-US code pages.
5346 # Therefore disable its use until we understand the cause. 2004-07-20
5347 if test "$PORTNAME" = "win32"; then
5348   if test "$with_readline" = yes; then
5349     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5350 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5351     with_readline=no
5352   fi
5353 fi
5354
5355
5356 #
5357 # Prefer libedit
5358 #
5359
5360
5361
5362 # Check whether --with-libedit-preferred was given.
5363 if test "${with_libedit_preferred+set}" = set; then
5364   withval=$with_libedit_preferred;
5365   case $withval in
5366     yes)
5367       :
5368       ;;
5369     no)
5370       :
5371       ;;
5372     *)
5373       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5374 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5375    { (exit 1); exit 1; }; }
5376       ;;
5377   esac
5378
5379 else
5380   with_libedit_preferred=no
5381
5382 fi
5383
5384
5385
5386
5387 #
5388 # OSSP UUID library
5389 #
5390
5391
5392
5393 # Check whether --with-ossp-uuid was given.
5394 if test "${with_ossp_uuid+set}" = set; then
5395   withval=$with_ossp_uuid;
5396   case $withval in
5397     yes)
5398       :
5399       ;;
5400     no)
5401       :
5402       ;;
5403     *)
5404       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5405 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5406    { (exit 1); exit 1; }; }
5407       ;;
5408   esac
5409
5410 else
5411   with_ossp_uuid=no
5412
5413 fi
5414
5415
5416
5417
5418
5419 #
5420 # XML
5421 #
5422
5423
5424
5425 # Check whether --with-libxml was given.
5426 if test "${with_libxml+set}" = set; then
5427   withval=$with_libxml;
5428   case $withval in
5429     yes)
5430
5431 cat >>confdefs.h <<\_ACEOF
5432 #define USE_LIBXML 1
5433 _ACEOF
5434
5435       ;;
5436     no)
5437       :
5438       ;;
5439     *)
5440       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5441 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5442    { (exit 1); exit 1; }; }
5443       ;;
5444   esac
5445
5446 else
5447   with_libxml=no
5448
5449 fi
5450
5451
5452
5453 if test "$with_libxml" = yes ; then
5454   for ac_prog in xml2-config
5455 do
5456   # Extract the first word of "$ac_prog", so it can be a program name with args.
5457 set dummy $ac_prog; ac_word=$2
5458 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5459 $as_echo_n "checking for $ac_word... " >&6; }
5460 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5461   $as_echo_n "(cached) " >&6
5462 else
5463   if test -n "$XML2_CONFIG"; then
5464   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5465 else
5466 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5467 for as_dir in $PATH
5468 do
5469   IFS=$as_save_IFS
5470   test -z "$as_dir" && as_dir=.
5471   for ac_exec_ext in '' $ac_executable_extensions; do
5472   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5473     ac_cv_prog_XML2_CONFIG="$ac_prog"
5474     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5475     break 2
5476   fi
5477 done
5478 done
5479 IFS=$as_save_IFS
5480
5481 fi
5482 fi
5483 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5484 if test -n "$XML2_CONFIG"; then
5485   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5486 $as_echo "$XML2_CONFIG" >&6; }
5487 else
5488   { $as_echo "$as_me:$LINENO: result: no" >&5
5489 $as_echo "no" >&6; }
5490 fi
5491
5492
5493   test -n "$XML2_CONFIG" && break
5494 done
5495
5496   if test -n "$XML2_CONFIG"; then
5497     for pgac_option in `$XML2_CONFIG --cflags`; do
5498       case $pgac_option in
5499         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5500       esac
5501     done
5502     for pgac_option in `$XML2_CONFIG --libs`; do
5503       case $pgac_option in
5504         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5505       esac
5506     done
5507   fi
5508 fi
5509
5510
5511
5512 #
5513 # XSLT
5514 #
5515
5516
5517
5518 # Check whether --with-libxslt was given.
5519 if test "${with_libxslt+set}" = set; then
5520   withval=$with_libxslt;
5521   case $withval in
5522     yes)
5523
5524 cat >>confdefs.h <<\_ACEOF
5525 #define USE_LIBXSLT 1
5526 _ACEOF
5527
5528       ;;
5529     no)
5530       :
5531       ;;
5532     *)
5533       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5534 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5535    { (exit 1); exit 1; }; }
5536       ;;
5537   esac
5538
5539 else
5540   with_libxslt=no
5541
5542 fi
5543
5544
5545
5546
5547
5548
5549 #
5550 # tzdata
5551 #
5552
5553
5554
5555 # Check whether --with-system-tzdata was given.
5556 if test "${with_system_tzdata+set}" = set; then
5557   withval=$with_system_tzdata;
5558   case $withval in
5559     yes)
5560       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5561 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5562    { (exit 1); exit 1; }; }
5563       ;;
5564     no)
5565       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5566 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5567    { (exit 1); exit 1; }; }
5568       ;;
5569     *)
5570
5571       ;;
5572   esac
5573
5574 fi
5575
5576
5577
5578
5579 #
5580 # Zlib
5581 #
5582
5583
5584
5585 # Check whether --with-zlib was given.
5586 if test "${with_zlib+set}" = set; then
5587   withval=$with_zlib;
5588   case $withval in
5589     yes)
5590       :
5591       ;;
5592     no)
5593       :
5594       ;;
5595     *)
5596       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5597 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5598    { (exit 1); exit 1; }; }
5599       ;;
5600   esac
5601
5602 else
5603   with_zlib=yes
5604
5605 fi
5606
5607
5608
5609
5610 #
5611 # Elf
5612 #
5613
5614 # Assume system is ELF if it predefines __ELF__ as 1,
5615 # otherwise believe host_os based default.
5616 case $host_os in
5617     freebsd1*|freebsd2*) elf=no;;
5618     freebsd3*|freebsd4*) elf=yes;;
5619 esac
5620
5621
5622 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5623 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5624 if test "${ac_cv_path_GREP+set}" = set; then
5625   $as_echo_n "(cached) " >&6
5626 else
5627   if test -z "$GREP"; then
5628   ac_path_GREP_found=false
5629   # Loop through the user's path and test for each of PROGNAME-LIST
5630   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5631 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5632 do
5633   IFS=$as_save_IFS
5634   test -z "$as_dir" && as_dir=.
5635   for ac_prog in grep ggrep; do
5636     for ac_exec_ext in '' $ac_executable_extensions; do
5637       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5638       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5639 # Check for GNU ac_path_GREP and select it if it is found.
5640   # Check for GNU $ac_path_GREP
5641 case `"$ac_path_GREP" --version 2>&1` in
5642 *GNU*)
5643   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5644 *)
5645   ac_count=0
5646   $as_echo_n 0123456789 >"conftest.in"
5647   while :
5648   do
5649     cat "conftest.in" "conftest.in" >"conftest.tmp"
5650     mv "conftest.tmp" "conftest.in"
5651     cp "conftest.in" "conftest.nl"
5652     $as_echo 'GREP' >> "conftest.nl"
5653     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5654     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5655     ac_count=`expr $ac_count + 1`
5656     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5657       # Best one so far, save it but keep looking for a better one
5658       ac_cv_path_GREP="$ac_path_GREP"
5659       ac_path_GREP_max=$ac_count
5660     fi
5661     # 10*(2^10) chars as input seems more than enough
5662     test $ac_count -gt 10 && break
5663   done
5664   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5665 esac
5666
5667       $ac_path_GREP_found && break 3
5668     done
5669   done
5670 done
5671 IFS=$as_save_IFS
5672   if test -z "$ac_cv_path_GREP"; then
5673     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5674 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5675    { (exit 1); exit 1; }; }
5676   fi
5677 else
5678   ac_cv_path_GREP=$GREP
5679 fi
5680
5681 fi
5682 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5683 $as_echo "$ac_cv_path_GREP" >&6; }
5684  GREP="$ac_cv_path_GREP"
5685
5686
5687 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
5688 $as_echo_n "checking for egrep... " >&6; }
5689 if test "${ac_cv_path_EGREP+set}" = set; then
5690   $as_echo_n "(cached) " >&6
5691 else
5692   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5693    then ac_cv_path_EGREP="$GREP -E"
5694    else
5695      if test -z "$EGREP"; then
5696   ac_path_EGREP_found=false
5697   # Loop through the user's path and test for each of PROGNAME-LIST
5698   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5699 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5700 do
5701   IFS=$as_save_IFS
5702   test -z "$as_dir" && as_dir=.
5703   for ac_prog in egrep; do
5704     for ac_exec_ext in '' $ac_executable_extensions; do
5705       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5706       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5707 # Check for GNU ac_path_EGREP and select it if it is found.
5708   # Check for GNU $ac_path_EGREP
5709 case `"$ac_path_EGREP" --version 2>&1` in
5710 *GNU*)
5711   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5712 *)
5713   ac_count=0
5714   $as_echo_n 0123456789 >"conftest.in"
5715   while :
5716   do
5717     cat "conftest.in" "conftest.in" >"conftest.tmp"
5718     mv "conftest.tmp" "conftest.in"
5719     cp "conftest.in" "conftest.nl"
5720     $as_echo 'EGREP' >> "conftest.nl"
5721     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5722     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5723     ac_count=`expr $ac_count + 1`
5724     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5725       # Best one so far, save it but keep looking for a better one
5726       ac_cv_path_EGREP="$ac_path_EGREP"
5727       ac_path_EGREP_max=$ac_count
5728     fi
5729     # 10*(2^10) chars as input seems more than enough
5730     test $ac_count -gt 10 && break
5731   done
5732   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5733 esac
5734
5735       $ac_path_EGREP_found && break 3
5736     done
5737   done
5738 done
5739 IFS=$as_save_IFS
5740   if test -z "$ac_cv_path_EGREP"; then
5741     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5742 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5743    { (exit 1); exit 1; }; }
5744   fi
5745 else
5746   ac_cv_path_EGREP=$EGREP
5747 fi
5748
5749    fi
5750 fi
5751 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5752 $as_echo "$ac_cv_path_EGREP" >&6; }
5753  EGREP="$ac_cv_path_EGREP"
5754
5755
5756 cat >conftest.$ac_ext <<_ACEOF
5757 /* confdefs.h.  */
5758 _ACEOF
5759 cat confdefs.h >>conftest.$ac_ext
5760 cat >>conftest.$ac_ext <<_ACEOF
5761 /* end confdefs.h.  */
5762 #if __ELF__
5763   yes
5764 #endif
5765
5766 _ACEOF
5767 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5768   $EGREP "yes" >/dev/null 2>&1; then
5769   ELF_SYS=true
5770 else
5771   if test "X$elf" = "Xyes" ; then
5772   ELF_SYS=true
5773 else
5774   ELF_SYS=
5775 fi
5776 fi
5777 rm -f conftest*
5778
5779
5780
5781 #
5782 # Assignments
5783 #
5784
5785 CPPFLAGS="$CPPFLAGS $INCLUDES"
5786 LDFLAGS="$LDFLAGS $LIBDIRS"
5787
5788
5789
5790
5791 # Check whether --with-gnu-ld was given.
5792 if test "${with_gnu_ld+set}" = set; then
5793   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5794 else
5795   with_gnu_ld=no
5796 fi
5797
5798 ac_prog=ld
5799 if test "$GCC" = yes; then
5800   # Check if gcc -print-prog-name=ld gives a path.
5801   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5802 $as_echo_n "checking for ld used by GCC... " >&6; }
5803   case $host in
5804   *-*-mingw*)
5805     # gcc leaves a trailing carriage return which upsets mingw
5806     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5807   *)
5808     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5809   esac
5810   case "$ac_prog" in
5811     # Accept absolute paths.
5812     [\\/]* | [A-Za-z]:[\\/]*)
5813       re_direlt='/[^/][^/]*/\.\./'
5814       # Canonicalize the path of ld
5815       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5816       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5817         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5818       done
5819       test -z "$LD" && LD="$ac_prog"
5820       ;;
5821   "")
5822     # If it fails, then pretend we aren't using GCC.
5823     ac_prog=ld
5824     ;;
5825   *)
5826     # If it is relative, then search for the first ld in PATH.
5827     with_gnu_ld=unknown
5828     ;;
5829   esac
5830 elif test "$with_gnu_ld" = yes; then
5831   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
5832 $as_echo_n "checking for GNU ld... " >&6; }
5833 else
5834   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5835 $as_echo_n "checking for non-GNU ld... " >&6; }
5836 fi
5837 if test "${ac_cv_path_LD+set}" = set; then
5838   $as_echo_n "(cached) " >&6
5839 else
5840   if test -z "$LD"; then
5841   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5842   for ac_dir in $PATH; do
5843     test -z "$ac_dir" && ac_dir=.
5844     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5845       ac_cv_path_LD="$ac_dir/$ac_prog"
5846       # Check to see if the program is GNU ld.  I'd rather use --version,
5847       # but apparently some GNU ld's only accept -v.
5848       # Break only if it was the GNU/non-GNU ld that we prefer.
5849       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
5850         test "$with_gnu_ld" != no && break
5851       else
5852         test "$with_gnu_ld" != yes && break
5853       fi
5854     fi
5855   done
5856   IFS="$ac_save_ifs"
5857 else
5858   ac_cv_path_LD="$LD" # Let the user override the test with a path.
5859 fi
5860 fi
5861
5862 LD="$ac_cv_path_LD"
5863 if test -n "$LD"; then
5864   { $as_echo "$as_me:$LINENO: result: $LD" >&5
5865 $as_echo "$LD" >&6; }
5866 else
5867   { $as_echo "$as_me:$LINENO: result: no" >&5
5868 $as_echo "no" >&6; }
5869 fi
5870 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5871 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5872    { (exit 1); exit 1; }; }
5873 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5874 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
5875 if test "${ac_cv_prog_gnu_ld+set}" = set; then
5876   $as_echo_n "(cached) " >&6
5877 else
5878   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
5879 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
5880   ac_cv_prog_gnu_ld=yes
5881 else
5882   ac_cv_prog_gnu_ld=no
5883 fi
5884 fi
5885 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
5886 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
5887 with_gnu_ld=$ac_cv_prog_gnu_ld
5888
5889
5890
5891
5892 case $host_os in sysv5*)
5893   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
5894 $as_echo_n "checking whether ld -R works... " >&6; }
5895 if test "${pgac_cv_prog_ld_R+set}" = set; then
5896   $as_echo_n "(cached) " >&6
5897 else
5898
5899     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
5900     cat >conftest.$ac_ext <<_ACEOF
5901 /* confdefs.h.  */
5902 _ACEOF
5903 cat confdefs.h >>conftest.$ac_ext
5904 cat >>conftest.$ac_ext <<_ACEOF
5905 /* end confdefs.h.  */
5906
5907 int
5908 main ()
5909 {
5910
5911   ;
5912   return 0;
5913 }
5914 _ACEOF
5915 rm -f conftest.$ac_objext conftest$ac_exeext
5916 if { (ac_try="$ac_link"
5917 case "(($ac_try" in
5918   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5919   *) ac_try_echo=$ac_try;;
5920 esac
5921 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5922 $as_echo "$ac_try_echo") >&5
5923   (eval "$ac_link") 2>conftest.er1
5924   ac_status=$?
5925   grep -v '^ *+' conftest.er1 >conftest.err
5926   rm -f conftest.er1
5927   cat conftest.err >&5
5928   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5929   (exit $ac_status); } && {
5930          test -z "$ac_c_werror_flag" ||
5931          test ! -s conftest.err
5932        } && test -s conftest$ac_exeext && {
5933          test "$cross_compiling" = yes ||
5934          $as_test_x conftest$ac_exeext
5935        }; then
5936   pgac_cv_prog_ld_R=yes
5937 else
5938   $as_echo "$as_me: failed program was:" >&5
5939 sed 's/^/| /' conftest.$ac_ext >&5
5940
5941         pgac_cv_prog_ld_R=no
5942 fi
5943
5944 rm -rf conftest.dSYM
5945 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5946       conftest$ac_exeext conftest.$ac_ext
5947     LDFLAGS=$pgac_save_LDFLAGS
5948
5949 fi
5950 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
5951 $as_echo "$pgac_cv_prog_ld_R" >&6; }
5952   ld_R_works=$pgac_cv_prog_ld_R
5953
5954 esac
5955 if test -n "$ac_tool_prefix"; then
5956   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5957 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5958 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5959 $as_echo_n "checking for $ac_word... " >&6; }
5960 if test "${ac_cv_prog_RANLIB+set}" = set; then
5961   $as_echo_n "(cached) " >&6
5962 else
5963   if test -n "$RANLIB"; then
5964   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5965 else
5966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5967 for as_dir in $PATH
5968 do
5969   IFS=$as_save_IFS
5970   test -z "$as_dir" && as_dir=.
5971   for ac_exec_ext in '' $ac_executable_extensions; do
5972   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5973     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5974     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5975     break 2
5976   fi
5977 done
5978 done
5979 IFS=$as_save_IFS
5980
5981 fi
5982 fi
5983 RANLIB=$ac_cv_prog_RANLIB
5984 if test -n "$RANLIB"; then
5985   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
5986 $as_echo "$RANLIB" >&6; }
5987 else
5988   { $as_echo "$as_me:$LINENO: result: no" >&5
5989 $as_echo "no" >&6; }
5990 fi
5991
5992
5993 fi
5994 if test -z "$ac_cv_prog_RANLIB"; then
5995   ac_ct_RANLIB=$RANLIB
5996   # Extract the first word of "ranlib", so it can be a program name with args.
5997 set dummy ranlib; ac_word=$2
5998 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5999 $as_echo_n "checking for $ac_word... " >&6; }
6000 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6001   $as_echo_n "(cached) " >&6
6002 else
6003   if test -n "$ac_ct_RANLIB"; then
6004   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6005 else
6006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6007 for as_dir in $PATH
6008 do
6009   IFS=$as_save_IFS
6010   test -z "$as_dir" && as_dir=.
6011   for ac_exec_ext in '' $ac_executable_extensions; do
6012   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6013     ac_cv_prog_ac_ct_RANLIB="ranlib"
6014     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6015     break 2
6016   fi
6017 done
6018 done
6019 IFS=$as_save_IFS
6020
6021 fi
6022 fi
6023 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6024 if test -n "$ac_ct_RANLIB"; then
6025   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6026 $as_echo "$ac_ct_RANLIB" >&6; }
6027 else
6028   { $as_echo "$as_me:$LINENO: result: no" >&5
6029 $as_echo "no" >&6; }
6030 fi
6031
6032   if test "x$ac_ct_RANLIB" = x; then
6033     RANLIB=":"
6034   else
6035     case $cross_compiling:$ac_tool_warned in
6036 yes:)
6037 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6038 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6039 ac_tool_warned=yes ;;
6040 esac
6041     RANLIB=$ac_ct_RANLIB
6042   fi
6043 else
6044   RANLIB="$ac_cv_prog_RANLIB"
6045 fi
6046
6047
6048   if test -n "$ac_tool_prefix"; then
6049   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6050 set dummy ${ac_tool_prefix}strip; ac_word=$2
6051 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6052 $as_echo_n "checking for $ac_word... " >&6; }
6053 if test "${ac_cv_prog_STRIP+set}" = set; then
6054   $as_echo_n "(cached) " >&6
6055 else
6056   if test -n "$STRIP"; then
6057   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6058 else
6059 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6060 for as_dir in $PATH
6061 do
6062   IFS=$as_save_IFS
6063   test -z "$as_dir" && as_dir=.
6064   for ac_exec_ext in '' $ac_executable_extensions; do
6065   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6066     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6067     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6068     break 2
6069   fi
6070 done
6071 done
6072 IFS=$as_save_IFS
6073
6074 fi
6075 fi
6076 STRIP=$ac_cv_prog_STRIP
6077 if test -n "$STRIP"; then
6078   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6079 $as_echo "$STRIP" >&6; }
6080 else
6081   { $as_echo "$as_me:$LINENO: result: no" >&5
6082 $as_echo "no" >&6; }
6083 fi
6084
6085
6086 fi
6087 if test -z "$ac_cv_prog_STRIP"; then
6088   ac_ct_STRIP=$STRIP
6089   # Extract the first word of "strip", so it can be a program name with args.
6090 set dummy strip; ac_word=$2
6091 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6092 $as_echo_n "checking for $ac_word... " >&6; }
6093 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6094   $as_echo_n "(cached) " >&6
6095 else
6096   if test -n "$ac_ct_STRIP"; then
6097   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6098 else
6099 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6100 for as_dir in $PATH
6101 do
6102   IFS=$as_save_IFS
6103   test -z "$as_dir" && as_dir=.
6104   for ac_exec_ext in '' $ac_executable_extensions; do
6105   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6106     ac_cv_prog_ac_ct_STRIP="strip"
6107     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6108     break 2
6109   fi
6110 done
6111 done
6112 IFS=$as_save_IFS
6113
6114 fi
6115 fi
6116 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6117 if test -n "$ac_ct_STRIP"; then
6118   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6119 $as_echo "$ac_ct_STRIP" >&6; }
6120 else
6121   { $as_echo "$as_me:$LINENO: result: no" >&5
6122 $as_echo "no" >&6; }
6123 fi
6124
6125   if test "x$ac_ct_STRIP" = x; then
6126     STRIP=":"
6127   else
6128     case $cross_compiling:$ac_tool_warned in
6129 yes:)
6130 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6131 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6132 ac_tool_warned=yes ;;
6133 esac
6134     STRIP=$ac_ct_STRIP
6135   fi
6136 else
6137   STRIP="$ac_cv_prog_STRIP"
6138 fi
6139
6140
6141   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6142 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6143   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6144     STRIP_STATIC_LIB="$STRIP -x"
6145     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6146     { $as_echo "$as_me:$LINENO: result: yes" >&5
6147 $as_echo "yes" >&6; }
6148   else
6149     STRIP_STATIC_LIB=:
6150     STRIP_SHARED_LIB=:
6151     { $as_echo "$as_me:$LINENO: result: no" >&5
6152 $as_echo "no" >&6; }
6153   fi
6154
6155
6156
6157 if test -n "$ac_tool_prefix"; then
6158   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6159 set dummy ${ac_tool_prefix}ar; ac_word=$2
6160 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6161 $as_echo_n "checking for $ac_word... " >&6; }
6162 if test "${ac_cv_prog_AR+set}" = set; then
6163   $as_echo_n "(cached) " >&6
6164 else
6165   if test -n "$AR"; then
6166   ac_cv_prog_AR="$AR" # Let the user override the test.
6167 else
6168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6169 for as_dir in $PATH
6170 do
6171   IFS=$as_save_IFS
6172   test -z "$as_dir" && as_dir=.
6173   for ac_exec_ext in '' $ac_executable_extensions; do
6174   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6175     ac_cv_prog_AR="${ac_tool_prefix}ar"
6176     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6177     break 2
6178   fi
6179 done
6180 done
6181 IFS=$as_save_IFS
6182
6183 fi
6184 fi
6185 AR=$ac_cv_prog_AR
6186 if test -n "$AR"; then
6187   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6188 $as_echo "$AR" >&6; }
6189 else
6190   { $as_echo "$as_me:$LINENO: result: no" >&5
6191 $as_echo "no" >&6; }
6192 fi
6193
6194
6195 fi
6196 if test -z "$ac_cv_prog_AR"; then
6197   ac_ct_AR=$AR
6198   # Extract the first word of "ar", so it can be a program name with args.
6199 set dummy ar; ac_word=$2
6200 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6201 $as_echo_n "checking for $ac_word... " >&6; }
6202 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6203   $as_echo_n "(cached) " >&6
6204 else
6205   if test -n "$ac_ct_AR"; then
6206   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6207 else
6208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6209 for as_dir in $PATH
6210 do
6211   IFS=$as_save_IFS
6212   test -z "$as_dir" && as_dir=.
6213   for ac_exec_ext in '' $ac_executable_extensions; do
6214   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6215     ac_cv_prog_ac_ct_AR="ar"
6216     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6217     break 2
6218   fi
6219 done
6220 done
6221 IFS=$as_save_IFS
6222
6223 fi
6224 fi
6225 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6226 if test -n "$ac_ct_AR"; then
6227   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6228 $as_echo "$ac_ct_AR" >&6; }
6229 else
6230   { $as_echo "$as_me:$LINENO: result: no" >&5
6231 $as_echo "no" >&6; }
6232 fi
6233
6234   if test "x$ac_ct_AR" = x; then
6235     AR="ar"
6236   else
6237     case $cross_compiling:$ac_tool_warned in
6238 yes:)
6239 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6240 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6241 ac_tool_warned=yes ;;
6242 esac
6243     AR=$ac_ct_AR
6244   fi
6245 else
6246   AR="$ac_cv_prog_AR"
6247 fi
6248
6249 if test "$PORTNAME" = "win32"; then
6250   if test -n "$ac_tool_prefix"; then
6251   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6252 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6253 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6254 $as_echo_n "checking for $ac_word... " >&6; }
6255 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6256   $as_echo_n "(cached) " >&6
6257 else
6258   if test -n "$DLLTOOL"; then
6259   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6260 else
6261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6262 for as_dir in $PATH
6263 do
6264   IFS=$as_save_IFS
6265   test -z "$as_dir" && as_dir=.
6266   for ac_exec_ext in '' $ac_executable_extensions; do
6267   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6268     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6269     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6270     break 2
6271   fi
6272 done
6273 done
6274 IFS=$as_save_IFS
6275
6276 fi
6277 fi
6278 DLLTOOL=$ac_cv_prog_DLLTOOL
6279 if test -n "$DLLTOOL"; then
6280   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6281 $as_echo "$DLLTOOL" >&6; }
6282 else
6283   { $as_echo "$as_me:$LINENO: result: no" >&5
6284 $as_echo "no" >&6; }
6285 fi
6286
6287
6288 fi
6289 if test -z "$ac_cv_prog_DLLTOOL"; then
6290   ac_ct_DLLTOOL=$DLLTOOL
6291   # Extract the first word of "dlltool", so it can be a program name with args.
6292 set dummy dlltool; ac_word=$2
6293 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6294 $as_echo_n "checking for $ac_word... " >&6; }
6295 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6296   $as_echo_n "(cached) " >&6
6297 else
6298   if test -n "$ac_ct_DLLTOOL"; then
6299   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6300 else
6301 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6302 for as_dir in $PATH
6303 do
6304   IFS=$as_save_IFS
6305   test -z "$as_dir" && as_dir=.
6306   for ac_exec_ext in '' $ac_executable_extensions; do
6307   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6308     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6309     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6310     break 2
6311   fi
6312 done
6313 done
6314 IFS=$as_save_IFS
6315
6316 fi
6317 fi
6318 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6319 if test -n "$ac_ct_DLLTOOL"; then
6320   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6321 $as_echo "$ac_ct_DLLTOOL" >&6; }
6322 else
6323   { $as_echo "$as_me:$LINENO: result: no" >&5
6324 $as_echo "no" >&6; }
6325 fi
6326
6327   if test "x$ac_ct_DLLTOOL" = x; then
6328     DLLTOOL="dlltool"
6329   else
6330     case $cross_compiling:$ac_tool_warned in
6331 yes:)
6332 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6333 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6334 ac_tool_warned=yes ;;
6335 esac
6336     DLLTOOL=$ac_ct_DLLTOOL
6337   fi
6338 else
6339   DLLTOOL="$ac_cv_prog_DLLTOOL"
6340 fi
6341
6342   if test -n "$ac_tool_prefix"; then
6343   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6344 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6345 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6346 $as_echo_n "checking for $ac_word... " >&6; }
6347 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6348   $as_echo_n "(cached) " >&6
6349 else
6350   if test -n "$DLLWRAP"; then
6351   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6352 else
6353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6354 for as_dir in $PATH
6355 do
6356   IFS=$as_save_IFS
6357   test -z "$as_dir" && as_dir=.
6358   for ac_exec_ext in '' $ac_executable_extensions; do
6359   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6360     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6361     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6362     break 2
6363   fi
6364 done
6365 done
6366 IFS=$as_save_IFS
6367
6368 fi
6369 fi
6370 DLLWRAP=$ac_cv_prog_DLLWRAP
6371 if test -n "$DLLWRAP"; then
6372   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6373 $as_echo "$DLLWRAP" >&6; }
6374 else
6375   { $as_echo "$as_me:$LINENO: result: no" >&5
6376 $as_echo "no" >&6; }
6377 fi
6378
6379
6380 fi
6381 if test -z "$ac_cv_prog_DLLWRAP"; then
6382   ac_ct_DLLWRAP=$DLLWRAP
6383   # Extract the first word of "dllwrap", so it can be a program name with args.
6384 set dummy dllwrap; ac_word=$2
6385 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6386 $as_echo_n "checking for $ac_word... " >&6; }
6387 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6388   $as_echo_n "(cached) " >&6
6389 else
6390   if test -n "$ac_ct_DLLWRAP"; then
6391   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6392 else
6393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6394 for as_dir in $PATH
6395 do
6396   IFS=$as_save_IFS
6397   test -z "$as_dir" && as_dir=.
6398   for ac_exec_ext in '' $ac_executable_extensions; do
6399   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6400     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6401     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6402     break 2
6403   fi
6404 done
6405 done
6406 IFS=$as_save_IFS
6407
6408 fi
6409 fi
6410 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6411 if test -n "$ac_ct_DLLWRAP"; then
6412   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6413 $as_echo "$ac_ct_DLLWRAP" >&6; }
6414 else
6415   { $as_echo "$as_me:$LINENO: result: no" >&5
6416 $as_echo "no" >&6; }
6417 fi
6418
6419   if test "x$ac_ct_DLLWRAP" = x; then
6420     DLLWRAP="dllwrap"
6421   else
6422     case $cross_compiling:$ac_tool_warned in
6423 yes:)
6424 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6425 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6426 ac_tool_warned=yes ;;
6427 esac
6428     DLLWRAP=$ac_ct_DLLWRAP
6429   fi
6430 else
6431   DLLWRAP="$ac_cv_prog_DLLWRAP"
6432 fi
6433
6434   if test -n "$ac_tool_prefix"; then
6435   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6436 set dummy ${ac_tool_prefix}windres; ac_word=$2
6437 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6438 $as_echo_n "checking for $ac_word... " >&6; }
6439 if test "${ac_cv_prog_WINDRES+set}" = set; then
6440   $as_echo_n "(cached) " >&6
6441 else
6442   if test -n "$WINDRES"; then
6443   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6444 else
6445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6446 for as_dir in $PATH
6447 do
6448   IFS=$as_save_IFS
6449   test -z "$as_dir" && as_dir=.
6450   for ac_exec_ext in '' $ac_executable_extensions; do
6451   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6452     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6453     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6454     break 2
6455   fi
6456 done
6457 done
6458 IFS=$as_save_IFS
6459
6460 fi
6461 fi
6462 WINDRES=$ac_cv_prog_WINDRES
6463 if test -n "$WINDRES"; then
6464   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6465 $as_echo "$WINDRES" >&6; }
6466 else
6467   { $as_echo "$as_me:$LINENO: result: no" >&5
6468 $as_echo "no" >&6; }
6469 fi
6470
6471
6472 fi
6473 if test -z "$ac_cv_prog_WINDRES"; then
6474   ac_ct_WINDRES=$WINDRES
6475   # Extract the first word of "windres", so it can be a program name with args.
6476 set dummy windres; ac_word=$2
6477 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6478 $as_echo_n "checking for $ac_word... " >&6; }
6479 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6480   $as_echo_n "(cached) " >&6
6481 else
6482   if test -n "$ac_ct_WINDRES"; then
6483   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6484 else
6485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6486 for as_dir in $PATH
6487 do
6488   IFS=$as_save_IFS
6489   test -z "$as_dir" && as_dir=.
6490   for ac_exec_ext in '' $ac_executable_extensions; do
6491   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6492     ac_cv_prog_ac_ct_WINDRES="windres"
6493     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6494     break 2
6495   fi
6496 done
6497 done
6498 IFS=$as_save_IFS
6499
6500 fi
6501 fi
6502 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6503 if test -n "$ac_ct_WINDRES"; then
6504   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6505 $as_echo "$ac_ct_WINDRES" >&6; }
6506 else
6507   { $as_echo "$as_me:$LINENO: result: no" >&5
6508 $as_echo "no" >&6; }
6509 fi
6510
6511   if test "x$ac_ct_WINDRES" = x; then
6512     WINDRES="windres"
6513   else
6514     case $cross_compiling:$ac_tool_warned in
6515 yes:)
6516 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6517 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6518 ac_tool_warned=yes ;;
6519 esac
6520     WINDRES=$ac_ct_WINDRES
6521   fi
6522 else
6523   WINDRES="$ac_cv_prog_WINDRES"
6524 fi
6525
6526 fi
6527
6528 # Extract the first word of "tar", so it can be a program name with args.
6529 set dummy tar; ac_word=$2
6530 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6531 $as_echo_n "checking for $ac_word... " >&6; }
6532 if test "${ac_cv_path_TAR+set}" = set; then
6533   $as_echo_n "(cached) " >&6
6534 else
6535   case $TAR in
6536   [\\/]* | ?:[\\/]*)
6537   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
6538   ;;
6539   *)
6540   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6541 for as_dir in $PATH
6542 do
6543   IFS=$as_save_IFS
6544   test -z "$as_dir" && as_dir=.
6545   for ac_exec_ext in '' $ac_executable_extensions; do
6546   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6547     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
6548     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6549     break 2
6550   fi
6551 done
6552 done
6553 IFS=$as_save_IFS
6554
6555   ;;
6556 esac
6557 fi
6558 TAR=$ac_cv_path_TAR
6559 if test -n "$TAR"; then
6560   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
6561 $as_echo "$TAR" >&6; }
6562 else
6563   { $as_echo "$as_me:$LINENO: result: no" >&5
6564 $as_echo "no" >&6; }
6565 fi
6566
6567
6568 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
6569 $as_echo_n "checking whether ln -s works... " >&6; }
6570 LN_S=$as_ln_s
6571 if test "$LN_S" = "ln -s"; then
6572   { $as_echo "$as_me:$LINENO: result: yes" >&5
6573 $as_echo "yes" >&6; }
6574 else
6575   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6576 $as_echo "no, using $LN_S" >&6; }
6577 fi
6578
6579 for ac_prog in gawk mawk nawk awk
6580 do
6581   # Extract the first word of "$ac_prog", so it can be a program name with args.
6582 set dummy $ac_prog; ac_word=$2
6583 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6584 $as_echo_n "checking for $ac_word... " >&6; }
6585 if test "${ac_cv_prog_AWK+set}" = set; then
6586   $as_echo_n "(cached) " >&6
6587 else
6588   if test -n "$AWK"; then
6589   ac_cv_prog_AWK="$AWK" # Let the user override the test.
6590 else
6591 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6592 for as_dir in $PATH
6593 do
6594   IFS=$as_save_IFS
6595   test -z "$as_dir" && as_dir=.
6596   for ac_exec_ext in '' $ac_executable_extensions; do
6597   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6598     ac_cv_prog_AWK="$ac_prog"
6599     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6600     break 2
6601   fi
6602 done
6603 done
6604 IFS=$as_save_IFS
6605
6606 fi
6607 fi
6608 AWK=$ac_cv_prog_AWK
6609 if test -n "$AWK"; then
6610   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
6611 $as_echo "$AWK" >&6; }
6612 else
6613   { $as_echo "$as_me:$LINENO: result: no" >&5
6614 $as_echo "no" >&6; }
6615 fi
6616
6617
6618   test -n "$AWK" && break
6619 done
6620
6621 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
6622 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
6623 if test -z "$MKDIR_P"; then
6624   if test "${ac_cv_path_mkdir+set}" = set; then
6625   $as_echo_n "(cached) " >&6
6626 else
6627   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6628 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6629 do
6630   IFS=$as_save_IFS
6631   test -z "$as_dir" && as_dir=.
6632   for ac_prog in mkdir gmkdir; do
6633          for ac_exec_ext in '' $ac_executable_extensions; do
6634            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
6635            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
6636              'mkdir (GNU coreutils) '* | \
6637              'mkdir (coreutils) '* | \
6638              'mkdir (fileutils) '4.1*)
6639                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
6640                break 3;;
6641            esac
6642          done
6643        done
6644 done
6645 IFS=$as_save_IFS
6646
6647 fi
6648
6649   if test "${ac_cv_path_mkdir+set}" = set; then
6650     MKDIR_P="$ac_cv_path_mkdir -p"
6651   else
6652     # As a last resort, use the slow shell script.  Don't cache a
6653     # value for MKDIR_P within a source directory, because that will
6654     # break other packages using the cache if that directory is
6655     # removed, or if the value is a relative name.
6656     test -d ./--version && rmdir ./--version
6657     MKDIR_P="$ac_install_sh -d"
6658   fi
6659 fi
6660 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
6661 $as_echo "$MKDIR_P" >&6; }
6662
6663 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
6664 # a relative path to it in each makefile where it subsitutes it. This clashes
6665 # with our Makefile.global concept. This workaround helps.
6666 case $MKDIR_P in
6667   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
6668 esac
6669
6670 # Let the user override the search
6671 if test -z "$BISON"; then
6672   for ac_prog in bison
6673 do
6674   # Extract the first word of "$ac_prog", so it can be a program name with args.
6675 set dummy $ac_prog; ac_word=$2
6676 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6677 $as_echo_n "checking for $ac_word... " >&6; }
6678 if test "${ac_cv_path_BISON+set}" = set; then
6679   $as_echo_n "(cached) " >&6
6680 else
6681   case $BISON in
6682   [\\/]* | ?:[\\/]*)
6683   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
6684   ;;
6685   *)
6686   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6687 for as_dir in $PATH
6688 do
6689   IFS=$as_save_IFS
6690   test -z "$as_dir" && as_dir=.
6691   for ac_exec_ext in '' $ac_executable_extensions; do
6692   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6693     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
6694     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6695     break 2
6696   fi
6697 done
6698 done
6699 IFS=$as_save_IFS
6700
6701   ;;
6702 esac
6703 fi
6704 BISON=$ac_cv_path_BISON
6705 if test -n "$BISON"; then
6706   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
6707 $as_echo "$BISON" >&6; }
6708 else
6709   { $as_echo "$as_me:$LINENO: result: no" >&5
6710 $as_echo "no" >&6; }
6711 fi
6712
6713
6714   test -n "$BISON" && break
6715 done
6716
6717 fi
6718
6719 if test "$BISON"; then
6720   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
6721   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
6722 $as_echo "$as_me: using $pgac_bison_version" >&6;}
6723   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
6724   then
6725     { $as_echo "$as_me:$LINENO: WARNING:
6726 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6727 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
6728 $as_echo "$as_me: WARNING:
6729 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6730 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
6731     BISON=""
6732   fi
6733 fi
6734
6735 if test -z "$BISON"; then
6736   { $as_echo "$as_me:$LINENO: WARNING:
6737 *** Without Bison you will not be able to build PostgreSQL from CVS nor
6738 *** change any of the parser definition files.  You can obtain Bison from
6739 *** a GNU mirror site.  (If you are using the official distribution of
6740 *** PostgreSQL then you do not need to worry about this, because the Bison
6741 *** output is pre-generated.)" >&5
6742 $as_echo "$as_me: WARNING:
6743 *** Without Bison you will not be able to build PostgreSQL from CVS nor
6744 *** change any of the parser definition files.  You can obtain Bison from
6745 *** a GNU mirror site.  (If you are using the official distribution of
6746 *** PostgreSQL then you do not need to worry about this, because the Bison
6747 *** output is pre-generated.)" >&2;}
6748 fi
6749 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
6750
6751
6752 { $as_echo "$as_me:$LINENO: checking for flex" >&5
6753 $as_echo_n "checking for flex... " >&6; }
6754 if test "${pgac_cv_path_flex+set}" = set; then
6755   $as_echo_n "(cached) " >&6
6756 else
6757   # Let the user override the test
6758 if test -n "$FLEX"; then
6759   pgac_cv_path_flex=$FLEX
6760 else
6761   pgac_save_IFS=$IFS
6762   IFS=$PATH_SEPARATOR
6763   for pgac_dir in $PATH; do
6764     IFS=$pgac_save_IFS
6765     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
6766       pgac_dir=`pwd`
6767     fi
6768     for pgac_prog in flex lex; do
6769       pgac_candidate="$pgac_dir/$pgac_prog"
6770       if test -f "$pgac_candidate" \
6771         && $pgac_candidate --version </dev/null >/dev/null 2>&1
6772       then
6773         echo '%%'  > conftest.l
6774         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
6775           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
6776           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
6777           then
6778             pgac_cv_path_flex=$pgac_candidate
6779             break 2
6780           else
6781             { $as_echo "$as_me:$LINENO: WARNING:
6782 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6783 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
6784 $as_echo "$as_me: WARNING:
6785 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6786 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
6787           fi
6788         fi
6789       fi
6790     done
6791   done
6792   rm -f conftest.l lex.yy.c
6793   : ${pgac_cv_path_flex=no}
6794 fi
6795
6796 fi
6797 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
6798 $as_echo "$pgac_cv_path_flex" >&6; }
6799 if test x"$pgac_cv_path_flex" = x"no"; then
6800   { $as_echo "$as_me:$LINENO: WARNING:
6801 *** Without Flex you will not be able to build PostgreSQL from CVS nor
6802 *** change any of the scanner definition files.  You can obtain Flex from
6803 *** a GNU mirror site.  (If you are using the official distribution of
6804 *** PostgreSQL then you do not need to worry about this because the Flex
6805 *** output is pre-generated.)" >&5
6806 $as_echo "$as_me: WARNING:
6807 *** Without Flex you will not be able to build PostgreSQL from CVS nor
6808 *** change any of the scanner definition files.  You can obtain Flex from
6809 *** a GNU mirror site.  (If you are using the official distribution of
6810 *** PostgreSQL then you do not need to worry about this because the Flex
6811 *** output is pre-generated.)" >&2;}
6812
6813   FLEX=
6814 else
6815   FLEX=$pgac_cv_path_flex
6816   pgac_flex_version=`$FLEX --version 2>/dev/null`
6817   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
6818 $as_echo "$as_me: using $pgac_flex_version" >&6;}
6819 fi
6820
6821
6822
6823
6824
6825 # Let the user override the search
6826 if test -z "$PERL"; then
6827   # Extract the first word of "perl", so it can be a program name with args.
6828 set dummy perl; ac_word=$2
6829 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6830 $as_echo_n "checking for $ac_word... " >&6; }
6831 if test "${ac_cv_path_PERL+set}" = set; then
6832   $as_echo_n "(cached) " >&6
6833 else
6834   case $PERL in
6835   [\\/]* | ?:[\\/]*)
6836   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
6837   ;;
6838   *)
6839   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6840 for as_dir in $PATH
6841 do
6842   IFS=$as_save_IFS
6843   test -z "$as_dir" && as_dir=.
6844   for ac_exec_ext in '' $ac_executable_extensions; do
6845   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6846     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
6847     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6848     break 2
6849   fi
6850 done
6851 done
6852 IFS=$as_save_IFS
6853
6854   ;;
6855 esac
6856 fi
6857 PERL=$ac_cv_path_PERL
6858 if test -n "$PERL"; then
6859   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
6860 $as_echo "$PERL" >&6; }
6861 else
6862   { $as_echo "$as_me:$LINENO: result: no" >&5
6863 $as_echo "no" >&6; }
6864 fi
6865
6866
6867 fi
6868
6869 if test "$PERL"; then
6870   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'`
6871   { $as_echo "$as_me:$LINENO: using perl $pgac_perl_version" >&5
6872 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
6873   if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
6874     $AWK '{ if ($1 = 5 && $2 >= 8) exit 1; else exit 0;}'
6875   then
6876     { $as_echo "$as_me:$LINENO: WARNING:
6877 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
6878 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
6879 $as_echo "$as_me: WARNING:
6880 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
6881 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
6882     PERL=""
6883   fi
6884 fi
6885
6886 if test -z "$PERL"; then
6887   { $as_echo "$as_me:$LINENO: WARNING:
6888 *** Without Perl you will not be able to build PostgreSQL from CVS.
6889 *** You can obtain Perl from any CPAN mirror site.
6890 *** (If you are using the official distribution of PostgreSQL then you do not
6891 *** need to worry about this, because the Perl output is pre-generated.)" >&5
6892 $as_echo "$as_me: WARNING:
6893 *** Without Perl you will not be able to build PostgreSQL from CVS.
6894 *** You can obtain Perl from any CPAN mirror site.
6895 *** (If you are using the official distribution of PostgreSQL then you do not
6896 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
6897 fi
6898
6899 if test "$with_perl" = yes; then
6900   if test -z "$PERL"; then
6901     { { $as_echo "$as_me:$LINENO: error: Perl not found" >&5
6902 $as_echo "$as_me: error: Perl not found" >&2;}
6903    { (exit 1); exit 1; }; }
6904   fi
6905
6906 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
6907 $as_echo_n "checking for Perl archlibexp... " >&6; }
6908 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
6909 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
6910 $as_echo "$perl_archlibexp" >&6; }
6911 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
6912 $as_echo_n "checking for Perl privlibexp... " >&6; }
6913 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
6914 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
6915 $as_echo "$perl_privlibexp" >&6; }
6916 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
6917 $as_echo_n "checking for Perl useshrplib... " >&6; }
6918 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
6919 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
6920 $as_echo "$perl_useshrplib" >&6; }
6921
6922 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
6923 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
6924 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
6925 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
6926 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
6927 if test -z "$perl_embed_ldflags" ; then
6928         { $as_echo "$as_me:$LINENO: result: no" >&5
6929 $as_echo "no" >&6; }
6930         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
6931 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
6932 installed." >&5
6933 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
6934 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
6935 installed." >&2;}
6936    { (exit 1); exit 1; }; }
6937 else
6938         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
6939 $as_echo "$perl_embed_ldflags" >&6; }
6940 fi
6941
6942 fi
6943
6944 if test "$with_python" = yes; then
6945   # Extract the first word of "python", so it can be a program name with args.
6946 set dummy python; ac_word=$2
6947 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6948 $as_echo_n "checking for $ac_word... " >&6; }
6949 if test "${ac_cv_path_PYTHON+set}" = set; then
6950   $as_echo_n "(cached) " >&6
6951 else
6952   case $PYTHON in
6953   [\\/]* | ?:[\\/]*)
6954   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
6955   ;;
6956   *)
6957   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6958 for as_dir in $PATH
6959 do
6960   IFS=$as_save_IFS
6961   test -z "$as_dir" && as_dir=.
6962   for ac_exec_ext in '' $ac_executable_extensions; do
6963   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6964     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
6965     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6966     break 2
6967   fi
6968 done
6969 done
6970 IFS=$as_save_IFS
6971
6972   ;;
6973 esac
6974 fi
6975 PYTHON=$ac_cv_path_PYTHON
6976 if test -n "$PYTHON"; then
6977   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
6978 $as_echo "$PYTHON" >&6; }
6979 else
6980   { $as_echo "$as_me:$LINENO: result: no" >&5
6981 $as_echo "no" >&6; }
6982 fi
6983
6984
6985 if test x"$PYTHON" = x""; then
6986   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
6987 $as_echo "$as_me: error: Python not found" >&2;}
6988    { (exit 1); exit 1; }; }
6989 fi
6990
6991
6992 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
6993 $as_echo_n "checking for Python distutils module... " >&6; }
6994 if "${PYTHON}" -c 'import distutils' 2>&5
6995 then
6996     { $as_echo "$as_me:$LINENO: result: yes" >&5
6997 $as_echo "yes" >&6; }
6998 else
6999     { $as_echo "$as_me:$LINENO: result: no" >&5
7000 $as_echo "no" >&6; }
7001     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
7002 $as_echo "$as_me: error: distutils module not found" >&2;}
7003    { (exit 1); exit 1; }; }
7004 fi
7005 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
7006 $as_echo_n "checking Python configuration directory... " >&6; }
7007 python_majorversion=`${PYTHON} -c "import sys; print(sys.version[0])"`
7008 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
7009 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'))"`
7010 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print('-I'+distutils.sysconfig.get_python_inc())"`
7011
7012 # This should be enough of a message.
7013 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
7014 $as_echo "$python_configdir" >&6; }
7015
7016
7017 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
7018 $as_echo_n "checking how to link an embedded Python application... " >&6; }
7019
7020 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
7021 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
7022 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
7023 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
7024
7025 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
7026 then
7027         # New way: use the official shared library
7028         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
7029         python_libspec="-L${python_libdir} -l${ldlibrary}"
7030 else
7031         # Old way: use libpython from python_configdir
7032         python_libdir="${python_configdir}"
7033         python_libspec="-L${python_libdir} -lpython${python_version}"
7034 fi
7035
7036 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
7037
7038 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
7039 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
7040
7041
7042 # threaded python is not supported on bsd's
7043 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7044 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7045 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7046 if test "$pythreads" = "1"; then
7047   { $as_echo "$as_me:$LINENO: result: yes" >&5
7048 $as_echo "yes" >&6; }
7049   case $host_os in
7050   openbsd*|freebsd*)
7051     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7052 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7053    { (exit 1); exit 1; }; }
7054     ;;
7055   esac
7056 else
7057   { $as_echo "$as_me:$LINENO: result: no" >&5
7058 $as_echo "no" >&6; }
7059 fi
7060
7061
7062 fi
7063
7064 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7065   # Extract the first word of "zic", so it can be a program name with args.
7066 set dummy zic; ac_word=$2
7067 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7068 $as_echo_n "checking for $ac_word... " >&6; }
7069 if test "${ac_cv_path_ZIC+set}" = set; then
7070   $as_echo_n "(cached) " >&6
7071 else
7072   case $ZIC in
7073   [\\/]* | ?:[\\/]*)
7074   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7075   ;;
7076   *)
7077   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7078 for as_dir in $PATH
7079 do
7080   IFS=$as_save_IFS
7081   test -z "$as_dir" && as_dir=.
7082   for ac_exec_ext in '' $ac_executable_extensions; do
7083   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7084     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7085     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7086     break 2
7087   fi
7088 done
7089 done
7090 IFS=$as_save_IFS
7091
7092   ;;
7093 esac
7094 fi
7095 ZIC=$ac_cv_path_ZIC
7096 if test -n "$ZIC"; then
7097   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7098 $as_echo "$ZIC" >&6; }
7099 else
7100   { $as_echo "$as_me:$LINENO: result: no" >&5
7101 $as_echo "no" >&6; }
7102 fi
7103
7104
7105   if test -z "$ZIC"; then
7106     { { $as_echo "$as_me:$LINENO: error:
7107 When cross-compiling, either use the option --with-system-tzdata to use
7108 existing time-zone data, or set the environment variable ZIC to a zic
7109 program to use during the build." >&5
7110 $as_echo "$as_me: error:
7111 When cross-compiling, either use the option --with-system-tzdata to use
7112 existing time-zone data, or set the environment variable ZIC to a zic
7113 program to use during the build." >&2;}
7114    { (exit 1); exit 1; }; }
7115   fi
7116 fi
7117
7118
7119 ##
7120 ## Libraries
7121 ##
7122 ## Most libraries are included only if they demonstrably provide a function
7123 ## we need, but libm is an exception: always include it, because there are
7124 ## too many compilers that play cute optimization games that will break
7125 ## probes for standard functions such as pow().
7126 ##
7127
7128
7129 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7130 $as_echo_n "checking for main in -lm... " >&6; }
7131 if test "${ac_cv_lib_m_main+set}" = set; then
7132   $as_echo_n "(cached) " >&6
7133 else
7134   ac_check_lib_save_LIBS=$LIBS
7135 LIBS="-lm  $LIBS"
7136 cat >conftest.$ac_ext <<_ACEOF
7137 /* confdefs.h.  */
7138 _ACEOF
7139 cat confdefs.h >>conftest.$ac_ext
7140 cat >>conftest.$ac_ext <<_ACEOF
7141 /* end confdefs.h.  */
7142
7143
7144 int
7145 main ()
7146 {
7147 return main ();
7148   ;
7149   return 0;
7150 }
7151 _ACEOF
7152 rm -f conftest.$ac_objext conftest$ac_exeext
7153 if { (ac_try="$ac_link"
7154 case "(($ac_try" in
7155   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7156   *) ac_try_echo=$ac_try;;
7157 esac
7158 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7159 $as_echo "$ac_try_echo") >&5
7160   (eval "$ac_link") 2>conftest.er1
7161   ac_status=$?
7162   grep -v '^ *+' conftest.er1 >conftest.err
7163   rm -f conftest.er1
7164   cat conftest.err >&5
7165   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7166   (exit $ac_status); } && {
7167          test -z "$ac_c_werror_flag" ||
7168          test ! -s conftest.err
7169        } && test -s conftest$ac_exeext && {
7170          test "$cross_compiling" = yes ||
7171          $as_test_x conftest$ac_exeext
7172        }; then
7173   ac_cv_lib_m_main=yes
7174 else
7175   $as_echo "$as_me: failed program was:" >&5
7176 sed 's/^/| /' conftest.$ac_ext >&5
7177
7178         ac_cv_lib_m_main=no
7179 fi
7180
7181 rm -rf conftest.dSYM
7182 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7183       conftest$ac_exeext conftest.$ac_ext
7184 LIBS=$ac_check_lib_save_LIBS
7185 fi
7186 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7187 $as_echo "$ac_cv_lib_m_main" >&6; }
7188 if test "x$ac_cv_lib_m_main" = x""yes; then
7189   cat >>confdefs.h <<_ACEOF
7190 #define HAVE_LIBM 1
7191 _ACEOF
7192
7193   LIBS="-lm $LIBS"
7194
7195 fi
7196
7197 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7198 $as_echo_n "checking for library containing setproctitle... " >&6; }
7199 if test "${ac_cv_search_setproctitle+set}" = set; then
7200   $as_echo_n "(cached) " >&6
7201 else
7202   ac_func_search_save_LIBS=$LIBS
7203 cat >conftest.$ac_ext <<_ACEOF
7204 /* confdefs.h.  */
7205 _ACEOF
7206 cat confdefs.h >>conftest.$ac_ext
7207 cat >>conftest.$ac_ext <<_ACEOF
7208 /* end confdefs.h.  */
7209
7210 /* Override any GCC internal prototype to avoid an error.
7211    Use char because int might match the return type of a GCC
7212    builtin and then its argument prototype would still apply.  */
7213 #ifdef __cplusplus
7214 extern "C"
7215 #endif
7216 char setproctitle ();
7217 int
7218 main ()
7219 {
7220 return setproctitle ();
7221   ;
7222   return 0;
7223 }
7224 _ACEOF
7225 for ac_lib in '' util; do
7226   if test -z "$ac_lib"; then
7227     ac_res="none required"
7228   else
7229     ac_res=-l$ac_lib
7230     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7231   fi
7232   rm -f conftest.$ac_objext conftest$ac_exeext
7233 if { (ac_try="$ac_link"
7234 case "(($ac_try" in
7235   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7236   *) ac_try_echo=$ac_try;;
7237 esac
7238 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7239 $as_echo "$ac_try_echo") >&5
7240   (eval "$ac_link") 2>conftest.er1
7241   ac_status=$?
7242   grep -v '^ *+' conftest.er1 >conftest.err
7243   rm -f conftest.er1
7244   cat conftest.err >&5
7245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7246   (exit $ac_status); } && {
7247          test -z "$ac_c_werror_flag" ||
7248          test ! -s conftest.err
7249        } && test -s conftest$ac_exeext && {
7250          test "$cross_compiling" = yes ||
7251          $as_test_x conftest$ac_exeext
7252        }; then
7253   ac_cv_search_setproctitle=$ac_res
7254 else
7255   $as_echo "$as_me: failed program was:" >&5
7256 sed 's/^/| /' conftest.$ac_ext >&5
7257
7258
7259 fi
7260
7261 rm -rf conftest.dSYM
7262 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7263       conftest$ac_exeext
7264   if test "${ac_cv_search_setproctitle+set}" = set; then
7265   break
7266 fi
7267 done
7268 if test "${ac_cv_search_setproctitle+set}" = set; then
7269   :
7270 else
7271   ac_cv_search_setproctitle=no
7272 fi
7273 rm conftest.$ac_ext
7274 LIBS=$ac_func_search_save_LIBS
7275 fi
7276 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7277 $as_echo "$ac_cv_search_setproctitle" >&6; }
7278 ac_res=$ac_cv_search_setproctitle
7279 if test "$ac_res" != no; then
7280   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7281
7282 fi
7283
7284 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7285 $as_echo_n "checking for library containing dlopen... " >&6; }
7286 if test "${ac_cv_search_dlopen+set}" = set; then
7287   $as_echo_n "(cached) " >&6
7288 else
7289   ac_func_search_save_LIBS=$LIBS
7290 cat >conftest.$ac_ext <<_ACEOF
7291 /* confdefs.h.  */
7292 _ACEOF
7293 cat confdefs.h >>conftest.$ac_ext
7294 cat >>conftest.$ac_ext <<_ACEOF
7295 /* end confdefs.h.  */
7296
7297 /* Override any GCC internal prototype to avoid an error.
7298    Use char because int might match the return type of a GCC
7299    builtin and then its argument prototype would still apply.  */
7300 #ifdef __cplusplus
7301 extern "C"
7302 #endif
7303 char dlopen ();
7304 int
7305 main ()
7306 {
7307 return dlopen ();
7308   ;
7309   return 0;
7310 }
7311 _ACEOF
7312 for ac_lib in '' dl; do
7313   if test -z "$ac_lib"; then
7314     ac_res="none required"
7315   else
7316     ac_res=-l$ac_lib
7317     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7318   fi
7319   rm -f conftest.$ac_objext conftest$ac_exeext
7320 if { (ac_try="$ac_link"
7321 case "(($ac_try" in
7322   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7323   *) ac_try_echo=$ac_try;;
7324 esac
7325 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7326 $as_echo "$ac_try_echo") >&5
7327   (eval "$ac_link") 2>conftest.er1
7328   ac_status=$?
7329   grep -v '^ *+' conftest.er1 >conftest.err
7330   rm -f conftest.er1
7331   cat conftest.err >&5
7332   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7333   (exit $ac_status); } && {
7334          test -z "$ac_c_werror_flag" ||
7335          test ! -s conftest.err
7336        } && test -s conftest$ac_exeext && {
7337          test "$cross_compiling" = yes ||
7338          $as_test_x conftest$ac_exeext
7339        }; then
7340   ac_cv_search_dlopen=$ac_res
7341 else
7342   $as_echo "$as_me: failed program was:" >&5
7343 sed 's/^/| /' conftest.$ac_ext >&5
7344
7345
7346 fi
7347
7348 rm -rf conftest.dSYM
7349 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7350       conftest$ac_exeext
7351   if test "${ac_cv_search_dlopen+set}" = set; then
7352   break
7353 fi
7354 done
7355 if test "${ac_cv_search_dlopen+set}" = set; then
7356   :
7357 else
7358   ac_cv_search_dlopen=no
7359 fi
7360 rm conftest.$ac_ext
7361 LIBS=$ac_func_search_save_LIBS
7362 fi
7363 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7364 $as_echo "$ac_cv_search_dlopen" >&6; }
7365 ac_res=$ac_cv_search_dlopen
7366 if test "$ac_res" != no; then
7367   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7368
7369 fi
7370
7371 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7372 $as_echo_n "checking for library containing socket... " >&6; }
7373 if test "${ac_cv_search_socket+set}" = set; then
7374   $as_echo_n "(cached) " >&6
7375 else
7376   ac_func_search_save_LIBS=$LIBS
7377 cat >conftest.$ac_ext <<_ACEOF
7378 /* confdefs.h.  */
7379 _ACEOF
7380 cat confdefs.h >>conftest.$ac_ext
7381 cat >>conftest.$ac_ext <<_ACEOF
7382 /* end confdefs.h.  */
7383
7384 /* Override any GCC internal prototype to avoid an error.
7385    Use char because int might match the return type of a GCC
7386    builtin and then its argument prototype would still apply.  */
7387 #ifdef __cplusplus
7388 extern "C"
7389 #endif
7390 char socket ();
7391 int
7392 main ()
7393 {
7394 return socket ();
7395   ;
7396   return 0;
7397 }
7398 _ACEOF
7399 for ac_lib in '' socket wsock32; do
7400   if test -z "$ac_lib"; then
7401     ac_res="none required"
7402   else
7403     ac_res=-l$ac_lib
7404     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7405   fi
7406   rm -f conftest.$ac_objext conftest$ac_exeext
7407 if { (ac_try="$ac_link"
7408 case "(($ac_try" in
7409   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7410   *) ac_try_echo=$ac_try;;
7411 esac
7412 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7413 $as_echo "$ac_try_echo") >&5
7414   (eval "$ac_link") 2>conftest.er1
7415   ac_status=$?
7416   grep -v '^ *+' conftest.er1 >conftest.err
7417   rm -f conftest.er1
7418   cat conftest.err >&5
7419   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7420   (exit $ac_status); } && {
7421          test -z "$ac_c_werror_flag" ||
7422          test ! -s conftest.err
7423        } && test -s conftest$ac_exeext && {
7424          test "$cross_compiling" = yes ||
7425          $as_test_x conftest$ac_exeext
7426        }; then
7427   ac_cv_search_socket=$ac_res
7428 else
7429   $as_echo "$as_me: failed program was:" >&5
7430 sed 's/^/| /' conftest.$ac_ext >&5
7431
7432
7433 fi
7434
7435 rm -rf conftest.dSYM
7436 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7437       conftest$ac_exeext
7438   if test "${ac_cv_search_socket+set}" = set; then
7439   break
7440 fi
7441 done
7442 if test "${ac_cv_search_socket+set}" = set; then
7443   :
7444 else
7445   ac_cv_search_socket=no
7446 fi
7447 rm conftest.$ac_ext
7448 LIBS=$ac_func_search_save_LIBS
7449 fi
7450 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
7451 $as_echo "$ac_cv_search_socket" >&6; }
7452 ac_res=$ac_cv_search_socket
7453 if test "$ac_res" != no; then
7454   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7455
7456 fi
7457
7458 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
7459 $as_echo_n "checking for library containing shl_load... " >&6; }
7460 if test "${ac_cv_search_shl_load+set}" = set; then
7461   $as_echo_n "(cached) " >&6
7462 else
7463   ac_func_search_save_LIBS=$LIBS
7464 cat >conftest.$ac_ext <<_ACEOF
7465 /* confdefs.h.  */
7466 _ACEOF
7467 cat confdefs.h >>conftest.$ac_ext
7468 cat >>conftest.$ac_ext <<_ACEOF
7469 /* end confdefs.h.  */
7470
7471 /* Override any GCC internal prototype to avoid an error.
7472    Use char because int might match the return type of a GCC
7473    builtin and then its argument prototype would still apply.  */
7474 #ifdef __cplusplus
7475 extern "C"
7476 #endif
7477 char shl_load ();
7478 int
7479 main ()
7480 {
7481 return shl_load ();
7482   ;
7483   return 0;
7484 }
7485 _ACEOF
7486 for ac_lib in '' dld; do
7487   if test -z "$ac_lib"; then
7488     ac_res="none required"
7489   else
7490     ac_res=-l$ac_lib
7491     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7492   fi
7493   rm -f conftest.$ac_objext conftest$ac_exeext
7494 if { (ac_try="$ac_link"
7495 case "(($ac_try" in
7496   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7497   *) ac_try_echo=$ac_try;;
7498 esac
7499 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7500 $as_echo "$ac_try_echo") >&5
7501   (eval "$ac_link") 2>conftest.er1
7502   ac_status=$?
7503   grep -v '^ *+' conftest.er1 >conftest.err
7504   rm -f conftest.er1
7505   cat conftest.err >&5
7506   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7507   (exit $ac_status); } && {
7508          test -z "$ac_c_werror_flag" ||
7509          test ! -s conftest.err
7510        } && test -s conftest$ac_exeext && {
7511          test "$cross_compiling" = yes ||
7512          $as_test_x conftest$ac_exeext
7513        }; then
7514   ac_cv_search_shl_load=$ac_res
7515 else
7516   $as_echo "$as_me: failed program was:" >&5
7517 sed 's/^/| /' conftest.$ac_ext >&5
7518
7519
7520 fi
7521
7522 rm -rf conftest.dSYM
7523 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7524       conftest$ac_exeext
7525   if test "${ac_cv_search_shl_load+set}" = set; then
7526   break
7527 fi
7528 done
7529 if test "${ac_cv_search_shl_load+set}" = set; then
7530   :
7531 else
7532   ac_cv_search_shl_load=no
7533 fi
7534 rm conftest.$ac_ext
7535 LIBS=$ac_func_search_save_LIBS
7536 fi
7537 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
7538 $as_echo "$ac_cv_search_shl_load" >&6; }
7539 ac_res=$ac_cv_search_shl_load
7540 if test "$ac_res" != no; then
7541   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7542
7543 fi
7544
7545 # We only use libld in port/dynloader/aix.c
7546 case $host_os in
7547      aix*)
7548         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
7549 $as_echo_n "checking for library containing ldopen... " >&6; }
7550 if test "${ac_cv_search_ldopen+set}" = set; then
7551   $as_echo_n "(cached) " >&6
7552 else
7553   ac_func_search_save_LIBS=$LIBS
7554 cat >conftest.$ac_ext <<_ACEOF
7555 /* confdefs.h.  */
7556 _ACEOF
7557 cat confdefs.h >>conftest.$ac_ext
7558 cat >>conftest.$ac_ext <<_ACEOF
7559 /* end confdefs.h.  */
7560
7561 /* Override any GCC internal prototype to avoid an error.
7562    Use char because int might match the return type of a GCC
7563    builtin and then its argument prototype would still apply.  */
7564 #ifdef __cplusplus
7565 extern "C"
7566 #endif
7567 char ldopen ();
7568 int
7569 main ()
7570 {
7571 return ldopen ();
7572   ;
7573   return 0;
7574 }
7575 _ACEOF
7576 for ac_lib in '' ld; do
7577   if test -z "$ac_lib"; then
7578     ac_res="none required"
7579   else
7580     ac_res=-l$ac_lib
7581     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7582   fi
7583   rm -f conftest.$ac_objext conftest$ac_exeext
7584 if { (ac_try="$ac_link"
7585 case "(($ac_try" in
7586   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7587   *) ac_try_echo=$ac_try;;
7588 esac
7589 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7590 $as_echo "$ac_try_echo") >&5
7591   (eval "$ac_link") 2>conftest.er1
7592   ac_status=$?
7593   grep -v '^ *+' conftest.er1 >conftest.err
7594   rm -f conftest.er1
7595   cat conftest.err >&5
7596   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7597   (exit $ac_status); } && {
7598          test -z "$ac_c_werror_flag" ||
7599          test ! -s conftest.err
7600        } && test -s conftest$ac_exeext && {
7601          test "$cross_compiling" = yes ||
7602          $as_test_x conftest$ac_exeext
7603        }; then
7604   ac_cv_search_ldopen=$ac_res
7605 else
7606   $as_echo "$as_me: failed program was:" >&5
7607 sed 's/^/| /' conftest.$ac_ext >&5
7608
7609
7610 fi
7611
7612 rm -rf conftest.dSYM
7613 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7614       conftest$ac_exeext
7615   if test "${ac_cv_search_ldopen+set}" = set; then
7616   break
7617 fi
7618 done
7619 if test "${ac_cv_search_ldopen+set}" = set; then
7620   :
7621 else
7622   ac_cv_search_ldopen=no
7623 fi
7624 rm conftest.$ac_ext
7625 LIBS=$ac_func_search_save_LIBS
7626 fi
7627 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
7628 $as_echo "$ac_cv_search_ldopen" >&6; }
7629 ac_res=$ac_cv_search_ldopen
7630 if test "$ac_res" != no; then
7631   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7632
7633 fi
7634
7635         ;;
7636 esac
7637 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
7638 $as_echo_n "checking for library containing getopt_long... " >&6; }
7639 if test "${ac_cv_search_getopt_long+set}" = set; then
7640   $as_echo_n "(cached) " >&6
7641 else
7642   ac_func_search_save_LIBS=$LIBS
7643 cat >conftest.$ac_ext <<_ACEOF
7644 /* confdefs.h.  */
7645 _ACEOF
7646 cat confdefs.h >>conftest.$ac_ext
7647 cat >>conftest.$ac_ext <<_ACEOF
7648 /* end confdefs.h.  */
7649
7650 /* Override any GCC internal prototype to avoid an error.
7651    Use char because int might match the return type of a GCC
7652    builtin and then its argument prototype would still apply.  */
7653 #ifdef __cplusplus
7654 extern "C"
7655 #endif
7656 char getopt_long ();
7657 int
7658 main ()
7659 {
7660 return getopt_long ();
7661   ;
7662   return 0;
7663 }
7664 _ACEOF
7665 for ac_lib in '' getopt gnugetopt; do
7666   if test -z "$ac_lib"; then
7667     ac_res="none required"
7668   else
7669     ac_res=-l$ac_lib
7670     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7671   fi
7672   rm -f conftest.$ac_objext conftest$ac_exeext
7673 if { (ac_try="$ac_link"
7674 case "(($ac_try" in
7675   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7676   *) ac_try_echo=$ac_try;;
7677 esac
7678 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7679 $as_echo "$ac_try_echo") >&5
7680   (eval "$ac_link") 2>conftest.er1
7681   ac_status=$?
7682   grep -v '^ *+' conftest.er1 >conftest.err
7683   rm -f conftest.er1
7684   cat conftest.err >&5
7685   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7686   (exit $ac_status); } && {
7687          test -z "$ac_c_werror_flag" ||
7688          test ! -s conftest.err
7689        } && test -s conftest$ac_exeext && {
7690          test "$cross_compiling" = yes ||
7691          $as_test_x conftest$ac_exeext
7692        }; then
7693   ac_cv_search_getopt_long=$ac_res
7694 else
7695   $as_echo "$as_me: failed program was:" >&5
7696 sed 's/^/| /' conftest.$ac_ext >&5
7697
7698
7699 fi
7700
7701 rm -rf conftest.dSYM
7702 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7703       conftest$ac_exeext
7704   if test "${ac_cv_search_getopt_long+set}" = set; then
7705   break
7706 fi
7707 done
7708 if test "${ac_cv_search_getopt_long+set}" = set; then
7709   :
7710 else
7711   ac_cv_search_getopt_long=no
7712 fi
7713 rm conftest.$ac_ext
7714 LIBS=$ac_func_search_save_LIBS
7715 fi
7716 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
7717 $as_echo "$ac_cv_search_getopt_long" >&6; }
7718 ac_res=$ac_cv_search_getopt_long
7719 if test "$ac_res" != no; then
7720   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7721
7722 fi
7723
7724 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
7725 $as_echo_n "checking for library containing crypt... " >&6; }
7726 if test "${ac_cv_search_crypt+set}" = set; then
7727   $as_echo_n "(cached) " >&6
7728 else
7729   ac_func_search_save_LIBS=$LIBS
7730 cat >conftest.$ac_ext <<_ACEOF
7731 /* confdefs.h.  */
7732 _ACEOF
7733 cat confdefs.h >>conftest.$ac_ext
7734 cat >>conftest.$ac_ext <<_ACEOF
7735 /* end confdefs.h.  */
7736
7737 /* Override any GCC internal prototype to avoid an error.
7738    Use char because int might match the return type of a GCC
7739    builtin and then its argument prototype would still apply.  */
7740 #ifdef __cplusplus
7741 extern "C"
7742 #endif
7743 char crypt ();
7744 int
7745 main ()
7746 {
7747 return crypt ();
7748   ;
7749   return 0;
7750 }
7751 _ACEOF
7752 for ac_lib in '' crypt; do
7753   if test -z "$ac_lib"; then
7754     ac_res="none required"
7755   else
7756     ac_res=-l$ac_lib
7757     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7758   fi
7759   rm -f conftest.$ac_objext conftest$ac_exeext
7760 if { (ac_try="$ac_link"
7761 case "(($ac_try" in
7762   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7763   *) ac_try_echo=$ac_try;;
7764 esac
7765 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7766 $as_echo "$ac_try_echo") >&5
7767   (eval "$ac_link") 2>conftest.er1
7768   ac_status=$?
7769   grep -v '^ *+' conftest.er1 >conftest.err
7770   rm -f conftest.er1
7771   cat conftest.err >&5
7772   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7773   (exit $ac_status); } && {
7774          test -z "$ac_c_werror_flag" ||
7775          test ! -s conftest.err
7776        } && test -s conftest$ac_exeext && {
7777          test "$cross_compiling" = yes ||
7778          $as_test_x conftest$ac_exeext
7779        }; then
7780   ac_cv_search_crypt=$ac_res
7781 else
7782   $as_echo "$as_me: failed program was:" >&5
7783 sed 's/^/| /' conftest.$ac_ext >&5
7784
7785
7786 fi
7787
7788 rm -rf conftest.dSYM
7789 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7790       conftest$ac_exeext
7791   if test "${ac_cv_search_crypt+set}" = set; then
7792   break
7793 fi
7794 done
7795 if test "${ac_cv_search_crypt+set}" = set; then
7796   :
7797 else
7798   ac_cv_search_crypt=no
7799 fi
7800 rm conftest.$ac_ext
7801 LIBS=$ac_func_search_save_LIBS
7802 fi
7803 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
7804 $as_echo "$ac_cv_search_crypt" >&6; }
7805 ac_res=$ac_cv_search_crypt
7806 if test "$ac_res" != no; then
7807   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7808
7809 fi
7810
7811 # Solaris:
7812 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
7813 $as_echo_n "checking for library containing fdatasync... " >&6; }
7814 if test "${ac_cv_search_fdatasync+set}" = set; then
7815   $as_echo_n "(cached) " >&6
7816 else
7817   ac_func_search_save_LIBS=$LIBS
7818 cat >conftest.$ac_ext <<_ACEOF
7819 /* confdefs.h.  */
7820 _ACEOF
7821 cat confdefs.h >>conftest.$ac_ext
7822 cat >>conftest.$ac_ext <<_ACEOF
7823 /* end confdefs.h.  */
7824
7825 /* Override any GCC internal prototype to avoid an error.
7826    Use char because int might match the return type of a GCC
7827    builtin and then its argument prototype would still apply.  */
7828 #ifdef __cplusplus
7829 extern "C"
7830 #endif
7831 char fdatasync ();
7832 int
7833 main ()
7834 {
7835 return fdatasync ();
7836   ;
7837   return 0;
7838 }
7839 _ACEOF
7840 for ac_lib in '' rt posix4; do
7841   if test -z "$ac_lib"; then
7842     ac_res="none required"
7843   else
7844     ac_res=-l$ac_lib
7845     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7846   fi
7847   rm -f conftest.$ac_objext conftest$ac_exeext
7848 if { (ac_try="$ac_link"
7849 case "(($ac_try" in
7850   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7851   *) ac_try_echo=$ac_try;;
7852 esac
7853 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7854 $as_echo "$ac_try_echo") >&5
7855   (eval "$ac_link") 2>conftest.er1
7856   ac_status=$?
7857   grep -v '^ *+' conftest.er1 >conftest.err
7858   rm -f conftest.er1
7859   cat conftest.err >&5
7860   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7861   (exit $ac_status); } && {
7862          test -z "$ac_c_werror_flag" ||
7863          test ! -s conftest.err
7864        } && test -s conftest$ac_exeext && {
7865          test "$cross_compiling" = yes ||
7866          $as_test_x conftest$ac_exeext
7867        }; then
7868   ac_cv_search_fdatasync=$ac_res
7869 else
7870   $as_echo "$as_me: failed program was:" >&5
7871 sed 's/^/| /' conftest.$ac_ext >&5
7872
7873
7874 fi
7875
7876 rm -rf conftest.dSYM
7877 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7878       conftest$ac_exeext
7879   if test "${ac_cv_search_fdatasync+set}" = set; then
7880   break
7881 fi
7882 done
7883 if test "${ac_cv_search_fdatasync+set}" = set; then
7884   :
7885 else
7886   ac_cv_search_fdatasync=no
7887 fi
7888 rm conftest.$ac_ext
7889 LIBS=$ac_func_search_save_LIBS
7890 fi
7891 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
7892 $as_echo "$ac_cv_search_fdatasync" >&6; }
7893 ac_res=$ac_cv_search_fdatasync
7894 if test "$ac_res" != no; then
7895   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7896
7897 fi
7898
7899 # Required for thread_test.c on Solaris 2.5:
7900 # Other ports use it too (HP-UX) so test unconditionally
7901 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
7902 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
7903 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7904   $as_echo_n "(cached) " >&6
7905 else
7906   ac_func_search_save_LIBS=$LIBS
7907 cat >conftest.$ac_ext <<_ACEOF
7908 /* confdefs.h.  */
7909 _ACEOF
7910 cat confdefs.h >>conftest.$ac_ext
7911 cat >>conftest.$ac_ext <<_ACEOF
7912 /* end confdefs.h.  */
7913
7914 /* Override any GCC internal prototype to avoid an error.
7915    Use char because int might match the return type of a GCC
7916    builtin and then its argument prototype would still apply.  */
7917 #ifdef __cplusplus
7918 extern "C"
7919 #endif
7920 char gethostbyname_r ();
7921 int
7922 main ()
7923 {
7924 return gethostbyname_r ();
7925   ;
7926   return 0;
7927 }
7928 _ACEOF
7929 for ac_lib in '' nsl; do
7930   if test -z "$ac_lib"; then
7931     ac_res="none required"
7932   else
7933     ac_res=-l$ac_lib
7934     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7935   fi
7936   rm -f conftest.$ac_objext conftest$ac_exeext
7937 if { (ac_try="$ac_link"
7938 case "(($ac_try" in
7939   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7940   *) ac_try_echo=$ac_try;;
7941 esac
7942 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7943 $as_echo "$ac_try_echo") >&5
7944   (eval "$ac_link") 2>conftest.er1
7945   ac_status=$?
7946   grep -v '^ *+' conftest.er1 >conftest.err
7947   rm -f conftest.er1
7948   cat conftest.err >&5
7949   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7950   (exit $ac_status); } && {
7951          test -z "$ac_c_werror_flag" ||
7952          test ! -s conftest.err
7953        } && test -s conftest$ac_exeext && {
7954          test "$cross_compiling" = yes ||
7955          $as_test_x conftest$ac_exeext
7956        }; then
7957   ac_cv_search_gethostbyname_r=$ac_res
7958 else
7959   $as_echo "$as_me: failed program was:" >&5
7960 sed 's/^/| /' conftest.$ac_ext >&5
7961
7962
7963 fi
7964
7965 rm -rf conftest.dSYM
7966 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7967       conftest$ac_exeext
7968   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7969   break
7970 fi
7971 done
7972 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7973   :
7974 else
7975   ac_cv_search_gethostbyname_r=no
7976 fi
7977 rm conftest.$ac_ext
7978 LIBS=$ac_func_search_save_LIBS
7979 fi
7980 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
7981 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
7982 ac_res=$ac_cv_search_gethostbyname_r
7983 if test "$ac_res" != no; then
7984   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7985
7986 fi
7987
7988 # Cygwin:
7989 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
7990 $as_echo_n "checking for library containing shmget... " >&6; }
7991 if test "${ac_cv_search_shmget+set}" = set; then
7992   $as_echo_n "(cached) " >&6
7993 else
7994   ac_func_search_save_LIBS=$LIBS
7995 cat >conftest.$ac_ext <<_ACEOF
7996 /* confdefs.h.  */
7997 _ACEOF
7998 cat confdefs.h >>conftest.$ac_ext
7999 cat >>conftest.$ac_ext <<_ACEOF
8000 /* end confdefs.h.  */
8001
8002 /* Override any GCC internal prototype to avoid an error.
8003    Use char because int might match the return type of a GCC
8004    builtin and then its argument prototype would still apply.  */
8005 #ifdef __cplusplus
8006 extern "C"
8007 #endif
8008 char shmget ();
8009 int
8010 main ()
8011 {
8012 return shmget ();
8013   ;
8014   return 0;
8015 }
8016 _ACEOF
8017 for ac_lib in '' cygipc; do
8018   if test -z "$ac_lib"; then
8019     ac_res="none required"
8020   else
8021     ac_res=-l$ac_lib
8022     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8023   fi
8024   rm -f conftest.$ac_objext conftest$ac_exeext
8025 if { (ac_try="$ac_link"
8026 case "(($ac_try" in
8027   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8028   *) ac_try_echo=$ac_try;;
8029 esac
8030 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8031 $as_echo "$ac_try_echo") >&5
8032   (eval "$ac_link") 2>conftest.er1
8033   ac_status=$?
8034   grep -v '^ *+' conftest.er1 >conftest.err
8035   rm -f conftest.er1
8036   cat conftest.err >&5
8037   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8038   (exit $ac_status); } && {
8039          test -z "$ac_c_werror_flag" ||
8040          test ! -s conftest.err
8041        } && test -s conftest$ac_exeext && {
8042          test "$cross_compiling" = yes ||
8043          $as_test_x conftest$ac_exeext
8044        }; then
8045   ac_cv_search_shmget=$ac_res
8046 else
8047   $as_echo "$as_me: failed program was:" >&5
8048 sed 's/^/| /' conftest.$ac_ext >&5
8049
8050
8051 fi
8052
8053 rm -rf conftest.dSYM
8054 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8055       conftest$ac_exeext
8056   if test "${ac_cv_search_shmget+set}" = set; then
8057   break
8058 fi
8059 done
8060 if test "${ac_cv_search_shmget+set}" = set; then
8061   :
8062 else
8063   ac_cv_search_shmget=no
8064 fi
8065 rm conftest.$ac_ext
8066 LIBS=$ac_func_search_save_LIBS
8067 fi
8068 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8069 $as_echo "$ac_cv_search_shmget" >&6; }
8070 ac_res=$ac_cv_search_shmget
8071 if test "$ac_res" != no; then
8072   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8073
8074 fi
8075
8076
8077 if test "$with_readline" = yes; then
8078
8079
8080 if test "${pgac_cv_check_readline+set}" = set; then
8081   $as_echo_n "(cached) " >&6
8082 else
8083   pgac_cv_check_readline=no
8084 pgac_save_LIBS=$LIBS
8085 if test x"$with_libedit_preferred" != x"yes"
8086 then    READLINE_ORDER="-lreadline -ledit"
8087 else    READLINE_ORDER="-ledit -lreadline"
8088 fi
8089 for pgac_rllib in $READLINE_ORDER ; do
8090   { $as_echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
8091 $as_echo_n "checking for ${pgac_rllib}... " >&6; }
8092   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8093     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8094     cat >conftest.$ac_ext <<_ACEOF
8095 /* confdefs.h.  */
8096 _ACEOF
8097 cat confdefs.h >>conftest.$ac_ext
8098 cat >>conftest.$ac_ext <<_ACEOF
8099 /* end confdefs.h.  */
8100
8101 /* Override any GCC internal prototype to avoid an error.
8102    Use char because int might match the return type of a GCC
8103    builtin and then its argument prototype would still apply.  */
8104 #ifdef __cplusplus
8105 extern "C"
8106 #endif
8107 char readline ();
8108 int
8109 main ()
8110 {
8111 return readline ();
8112   ;
8113   return 0;
8114 }
8115 _ACEOF
8116 rm -f conftest.$ac_objext conftest$ac_exeext
8117 if { (ac_try="$ac_link"
8118 case "(($ac_try" in
8119   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8120   *) ac_try_echo=$ac_try;;
8121 esac
8122 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8123 $as_echo "$ac_try_echo") >&5
8124   (eval "$ac_link") 2>conftest.er1
8125   ac_status=$?
8126   grep -v '^ *+' conftest.er1 >conftest.err
8127   rm -f conftest.er1
8128   cat conftest.err >&5
8129   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8130   (exit $ac_status); } && {
8131          test -z "$ac_c_werror_flag" ||
8132          test ! -s conftest.err
8133        } && test -s conftest$ac_exeext && {
8134          test "$cross_compiling" = yes ||
8135          $as_test_x conftest$ac_exeext
8136        }; then
8137
8138       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8139       # recognize dependent libraries; assume curses is needed if we didn't
8140       # find any dependency.
8141       case $host_os in
8142         netbsd* | openbsd* | irix*)
8143           if test x"$pgac_lib" = x"" ; then
8144             pgac_lib=" -lcurses"
8145           fi ;;
8146       esac
8147
8148       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8149       break
8150
8151 else
8152   $as_echo "$as_me: failed program was:" >&5
8153 sed 's/^/| /' conftest.$ac_ext >&5
8154
8155
8156 fi
8157
8158 rm -rf conftest.dSYM
8159 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8160       conftest$ac_exeext conftest.$ac_ext
8161   done
8162   if test "$pgac_cv_check_readline" != no ; then
8163     { $as_echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
8164 $as_echo "yes ($pgac_cv_check_readline)" >&6; }
8165     break
8166   else
8167     { $as_echo "$as_me:$LINENO: result: no" >&5
8168 $as_echo "no" >&6; }
8169   fi
8170 done
8171 LIBS=$pgac_save_LIBS
8172
8173 fi
8174
8175 if test "$pgac_cv_check_readline" != no ; then
8176   LIBS="$pgac_cv_check_readline $LIBS"
8177
8178 cat >>confdefs.h <<\_ACEOF
8179 #define HAVE_LIBREADLINE 1
8180 _ACEOF
8181
8182 fi
8183
8184
8185   if test x"$pgac_cv_check_readline" = x"no"; then
8186     { { $as_echo "$as_me:$LINENO: error: readline library not found
8187 If you have readline already installed, see config.log for details on the
8188 failure.  It is possible the compiler isn't looking in the proper directory.
8189 Use --without-readline to disable readline support." >&5
8190 $as_echo "$as_me: error: readline library not found
8191 If you have readline already installed, see config.log for details on the
8192 failure.  It is possible the compiler isn't looking in the proper directory.
8193 Use --without-readline to disable readline support." >&2;}
8194    { (exit 1); exit 1; }; }
8195   fi
8196 fi
8197
8198 if test "$with_zlib" = yes; then
8199
8200 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8201 $as_echo_n "checking for inflate in -lz... " >&6; }
8202 if test "${ac_cv_lib_z_inflate+set}" = set; then
8203   $as_echo_n "(cached) " >&6
8204 else
8205   ac_check_lib_save_LIBS=$LIBS
8206 LIBS="-lz  $LIBS"
8207 cat >conftest.$ac_ext <<_ACEOF
8208 /* confdefs.h.  */
8209 _ACEOF
8210 cat confdefs.h >>conftest.$ac_ext
8211 cat >>conftest.$ac_ext <<_ACEOF
8212 /* end confdefs.h.  */
8213
8214 /* Override any GCC internal prototype to avoid an error.
8215    Use char because int might match the return type of a GCC
8216    builtin and then its argument prototype would still apply.  */
8217 #ifdef __cplusplus
8218 extern "C"
8219 #endif
8220 char inflate ();
8221 int
8222 main ()
8223 {
8224 return inflate ();
8225   ;
8226   return 0;
8227 }
8228 _ACEOF
8229 rm -f conftest.$ac_objext conftest$ac_exeext
8230 if { (ac_try="$ac_link"
8231 case "(($ac_try" in
8232   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8233   *) ac_try_echo=$ac_try;;
8234 esac
8235 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8236 $as_echo "$ac_try_echo") >&5
8237   (eval "$ac_link") 2>conftest.er1
8238   ac_status=$?
8239   grep -v '^ *+' conftest.er1 >conftest.err
8240   rm -f conftest.er1
8241   cat conftest.err >&5
8242   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8243   (exit $ac_status); } && {
8244          test -z "$ac_c_werror_flag" ||
8245          test ! -s conftest.err
8246        } && test -s conftest$ac_exeext && {
8247          test "$cross_compiling" = yes ||
8248          $as_test_x conftest$ac_exeext
8249        }; then
8250   ac_cv_lib_z_inflate=yes
8251 else
8252   $as_echo "$as_me: failed program was:" >&5
8253 sed 's/^/| /' conftest.$ac_ext >&5
8254
8255         ac_cv_lib_z_inflate=no
8256 fi
8257
8258 rm -rf conftest.dSYM
8259 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8260       conftest$ac_exeext conftest.$ac_ext
8261 LIBS=$ac_check_lib_save_LIBS
8262 fi
8263 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
8264 $as_echo "$ac_cv_lib_z_inflate" >&6; }
8265 if test "x$ac_cv_lib_z_inflate" = x""yes; then
8266   cat >>confdefs.h <<_ACEOF
8267 #define HAVE_LIBZ 1
8268 _ACEOF
8269
8270   LIBS="-lz $LIBS"
8271
8272 else
8273   { { $as_echo "$as_me:$LINENO: error: zlib library not found
8274 If you have zlib already installed, see config.log for details on the
8275 failure.  It is possible the compiler isn't looking in the proper directory.
8276 Use --without-zlib to disable zlib support." >&5
8277 $as_echo "$as_me: error: zlib library not found
8278 If you have zlib already installed, see config.log for details on the
8279 failure.  It is possible the compiler isn't looking in the proper directory.
8280 Use --without-zlib to disable zlib support." >&2;}
8281    { (exit 1); exit 1; }; }
8282 fi
8283
8284 fi
8285
8286 if test "$enable_spinlocks" = yes; then
8287
8288 cat >>confdefs.h <<\_ACEOF
8289 #define HAVE_SPINLOCKS 1
8290 _ACEOF
8291
8292 else
8293   { $as_echo "$as_me:$LINENO: WARNING:
8294 *** Not using spinlocks will cause poor performance." >&5
8295 $as_echo "$as_me: WARNING:
8296 *** Not using spinlocks will cause poor performance." >&2;}
8297 fi
8298
8299 if test "$with_gssapi" = yes ; then
8300   if test "$PORTNAME" != "win32"; then
8301     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
8302 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
8303 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8304   $as_echo_n "(cached) " >&6
8305 else
8306   ac_func_search_save_LIBS=$LIBS
8307 cat >conftest.$ac_ext <<_ACEOF
8308 /* confdefs.h.  */
8309 _ACEOF
8310 cat confdefs.h >>conftest.$ac_ext
8311 cat >>conftest.$ac_ext <<_ACEOF
8312 /* end confdefs.h.  */
8313
8314 /* Override any GCC internal prototype to avoid an error.
8315    Use char because int might match the return type of a GCC
8316    builtin and then its argument prototype would still apply.  */
8317 #ifdef __cplusplus
8318 extern "C"
8319 #endif
8320 char gss_init_sec_context ();
8321 int
8322 main ()
8323 {
8324 return gss_init_sec_context ();
8325   ;
8326   return 0;
8327 }
8328 _ACEOF
8329 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
8330   if test -z "$ac_lib"; then
8331     ac_res="none required"
8332   else
8333     ac_res=-l$ac_lib
8334     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8335   fi
8336   rm -f conftest.$ac_objext conftest$ac_exeext
8337 if { (ac_try="$ac_link"
8338 case "(($ac_try" in
8339   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8340   *) ac_try_echo=$ac_try;;
8341 esac
8342 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8343 $as_echo "$ac_try_echo") >&5
8344   (eval "$ac_link") 2>conftest.er1
8345   ac_status=$?
8346   grep -v '^ *+' conftest.er1 >conftest.err
8347   rm -f conftest.er1
8348   cat conftest.err >&5
8349   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8350   (exit $ac_status); } && {
8351          test -z "$ac_c_werror_flag" ||
8352          test ! -s conftest.err
8353        } && test -s conftest$ac_exeext && {
8354          test "$cross_compiling" = yes ||
8355          $as_test_x conftest$ac_exeext
8356        }; then
8357   ac_cv_search_gss_init_sec_context=$ac_res
8358 else
8359   $as_echo "$as_me: failed program was:" >&5
8360 sed 's/^/| /' conftest.$ac_ext >&5
8361
8362
8363 fi
8364
8365 rm -rf conftest.dSYM
8366 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8367       conftest$ac_exeext
8368   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8369   break
8370 fi
8371 done
8372 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8373   :
8374 else
8375   ac_cv_search_gss_init_sec_context=no
8376 fi
8377 rm conftest.$ac_ext
8378 LIBS=$ac_func_search_save_LIBS
8379 fi
8380 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
8381 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
8382 ac_res=$ac_cv_search_gss_init_sec_context
8383 if test "$ac_res" != no; then
8384   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8385
8386 else
8387   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
8388 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
8389    { (exit 1); exit 1; }; }
8390 fi
8391
8392   else
8393     LIBS="$LIBS -lgssapi32"
8394   fi
8395 fi
8396
8397 if test "$with_krb5" = yes ; then
8398   if test "$PORTNAME" != "win32"; then
8399      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8400 $as_echo_n "checking for library containing com_err... " >&6; }
8401 if test "${ac_cv_search_com_err+set}" = set; then
8402   $as_echo_n "(cached) " >&6
8403 else
8404   ac_func_search_save_LIBS=$LIBS
8405 cat >conftest.$ac_ext <<_ACEOF
8406 /* confdefs.h.  */
8407 _ACEOF
8408 cat confdefs.h >>conftest.$ac_ext
8409 cat >>conftest.$ac_ext <<_ACEOF
8410 /* end confdefs.h.  */
8411
8412 /* Override any GCC internal prototype to avoid an error.
8413    Use char because int might match the return type of a GCC
8414    builtin and then its argument prototype would still apply.  */
8415 #ifdef __cplusplus
8416 extern "C"
8417 #endif
8418 char com_err ();
8419 int
8420 main ()
8421 {
8422 return com_err ();
8423   ;
8424   return 0;
8425 }
8426 _ACEOF
8427 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
8428   if test -z "$ac_lib"; then
8429     ac_res="none required"
8430   else
8431     ac_res=-l$ac_lib
8432     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8433   fi
8434   rm -f conftest.$ac_objext conftest$ac_exeext
8435 if { (ac_try="$ac_link"
8436 case "(($ac_try" in
8437   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8438   *) ac_try_echo=$ac_try;;
8439 esac
8440 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8441 $as_echo "$ac_try_echo") >&5
8442   (eval "$ac_link") 2>conftest.er1
8443   ac_status=$?
8444   grep -v '^ *+' conftest.er1 >conftest.err
8445   rm -f conftest.er1
8446   cat conftest.err >&5
8447   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8448   (exit $ac_status); } && {
8449          test -z "$ac_c_werror_flag" ||
8450          test ! -s conftest.err
8451        } && test -s conftest$ac_exeext && {
8452          test "$cross_compiling" = yes ||
8453          $as_test_x conftest$ac_exeext
8454        }; then
8455   ac_cv_search_com_err=$ac_res
8456 else
8457   $as_echo "$as_me: failed program was:" >&5
8458 sed 's/^/| /' conftest.$ac_ext >&5
8459
8460
8461 fi
8462
8463 rm -rf conftest.dSYM
8464 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8465       conftest$ac_exeext
8466   if test "${ac_cv_search_com_err+set}" = set; then
8467   break
8468 fi
8469 done
8470 if test "${ac_cv_search_com_err+set}" = set; then
8471   :
8472 else
8473   ac_cv_search_com_err=no
8474 fi
8475 rm conftest.$ac_ext
8476 LIBS=$ac_func_search_save_LIBS
8477 fi
8478 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8479 $as_echo "$ac_cv_search_com_err" >&6; }
8480 ac_res=$ac_cv_search_com_err
8481 if test "$ac_res" != no; then
8482   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8483
8484 else
8485   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8486 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8487    { (exit 1); exit 1; }; }
8488 fi
8489
8490      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
8491 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
8492 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8493   $as_echo_n "(cached) " >&6
8494 else
8495   ac_func_search_save_LIBS=$LIBS
8496 cat >conftest.$ac_ext <<_ACEOF
8497 /* confdefs.h.  */
8498 _ACEOF
8499 cat confdefs.h >>conftest.$ac_ext
8500 cat >>conftest.$ac_ext <<_ACEOF
8501 /* end confdefs.h.  */
8502
8503 /* Override any GCC internal prototype to avoid an error.
8504    Use char because int might match the return type of a GCC
8505    builtin and then its argument prototype would still apply.  */
8506 #ifdef __cplusplus
8507 extern "C"
8508 #endif
8509 char krb5_sendauth ();
8510 int
8511 main ()
8512 {
8513 return krb5_sendauth ();
8514   ;
8515   return 0;
8516 }
8517 _ACEOF
8518 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
8519   if test -z "$ac_lib"; then
8520     ac_res="none required"
8521   else
8522     ac_res=-l$ac_lib
8523     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8524   fi
8525   rm -f conftest.$ac_objext conftest$ac_exeext
8526 if { (ac_try="$ac_link"
8527 case "(($ac_try" in
8528   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8529   *) ac_try_echo=$ac_try;;
8530 esac
8531 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8532 $as_echo "$ac_try_echo") >&5
8533   (eval "$ac_link") 2>conftest.er1
8534   ac_status=$?
8535   grep -v '^ *+' conftest.er1 >conftest.err
8536   rm -f conftest.er1
8537   cat conftest.err >&5
8538   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8539   (exit $ac_status); } && {
8540          test -z "$ac_c_werror_flag" ||
8541          test ! -s conftest.err
8542        } && test -s conftest$ac_exeext && {
8543          test "$cross_compiling" = yes ||
8544          $as_test_x conftest$ac_exeext
8545        }; then
8546   ac_cv_search_krb5_sendauth=$ac_res
8547 else
8548   $as_echo "$as_me: failed program was:" >&5
8549 sed 's/^/| /' conftest.$ac_ext >&5
8550
8551
8552 fi
8553
8554 rm -rf conftest.dSYM
8555 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8556       conftest$ac_exeext
8557   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8558   break
8559 fi
8560 done
8561 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8562   :
8563 else
8564   ac_cv_search_krb5_sendauth=no
8565 fi
8566 rm conftest.$ac_ext
8567 LIBS=$ac_func_search_save_LIBS
8568 fi
8569 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
8570 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
8571 ac_res=$ac_cv_search_krb5_sendauth
8572 if test "$ac_res" != no; then
8573   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8574
8575 else
8576   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
8577 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
8578    { (exit 1); exit 1; }; }
8579 fi
8580
8581   else
8582      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8583 $as_echo_n "checking for library containing com_err... " >&6; }
8584 if test "${ac_cv_search_com_err+set}" = set; then
8585   $as_echo_n "(cached) " >&6
8586 else
8587   ac_func_search_save_LIBS=$LIBS
8588 cat >conftest.$ac_ext <<_ACEOF
8589 /* confdefs.h.  */
8590 _ACEOF
8591 cat confdefs.h >>conftest.$ac_ext
8592 cat >>conftest.$ac_ext <<_ACEOF
8593 /* end confdefs.h.  */
8594
8595 /* Override any GCC internal prototype to avoid an error.
8596    Use char because int might match the return type of a GCC
8597    builtin and then its argument prototype would still apply.  */
8598 #ifdef __cplusplus
8599 extern "C"
8600 #endif
8601 char com_err ();
8602 int
8603 main ()
8604 {
8605 return com_err ();
8606   ;
8607   return 0;
8608 }
8609 _ACEOF
8610 for ac_lib in '' 'comerr32 -lkrb5_32'; do
8611   if test -z "$ac_lib"; then
8612     ac_res="none required"
8613   else
8614     ac_res=-l$ac_lib
8615     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8616   fi
8617   rm -f conftest.$ac_objext conftest$ac_exeext
8618 if { (ac_try="$ac_link"
8619 case "(($ac_try" in
8620   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8621   *) ac_try_echo=$ac_try;;
8622 esac
8623 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8624 $as_echo "$ac_try_echo") >&5
8625   (eval "$ac_link") 2>conftest.er1
8626   ac_status=$?
8627   grep -v '^ *+' conftest.er1 >conftest.err
8628   rm -f conftest.er1
8629   cat conftest.err >&5
8630   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8631   (exit $ac_status); } && {
8632          test -z "$ac_c_werror_flag" ||
8633          test ! -s conftest.err
8634        } && test -s conftest$ac_exeext && {
8635          test "$cross_compiling" = yes ||
8636          $as_test_x conftest$ac_exeext
8637        }; then
8638   ac_cv_search_com_err=$ac_res
8639 else
8640   $as_echo "$as_me: failed program was:" >&5
8641 sed 's/^/| /' conftest.$ac_ext >&5
8642
8643
8644 fi
8645
8646 rm -rf conftest.dSYM
8647 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8648       conftest$ac_exeext
8649   if test "${ac_cv_search_com_err+set}" = set; then
8650   break
8651 fi
8652 done
8653 if test "${ac_cv_search_com_err+set}" = set; then
8654   :
8655 else
8656   ac_cv_search_com_err=no
8657 fi
8658 rm conftest.$ac_ext
8659 LIBS=$ac_func_search_save_LIBS
8660 fi
8661 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8662 $as_echo "$ac_cv_search_com_err" >&6; }
8663 ac_res=$ac_cv_search_com_err
8664 if test "$ac_res" != no; then
8665   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8666
8667 else
8668   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8669 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8670    { (exit 1); exit 1; }; }
8671 fi
8672
8673   fi
8674 fi
8675
8676 if test "$with_openssl" = yes ; then
8677     if test "$PORTNAME" != "win32"; then
8678
8679 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
8680 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
8681 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
8682   $as_echo_n "(cached) " >&6
8683 else
8684   ac_check_lib_save_LIBS=$LIBS
8685 LIBS="-lcrypto  $LIBS"
8686 cat >conftest.$ac_ext <<_ACEOF
8687 /* confdefs.h.  */
8688 _ACEOF
8689 cat confdefs.h >>conftest.$ac_ext
8690 cat >>conftest.$ac_ext <<_ACEOF
8691 /* end confdefs.h.  */
8692
8693 /* Override any GCC internal prototype to avoid an error.
8694    Use char because int might match the return type of a GCC
8695    builtin and then its argument prototype would still apply.  */
8696 #ifdef __cplusplus
8697 extern "C"
8698 #endif
8699 char CRYPTO_new_ex_data ();
8700 int
8701 main ()
8702 {
8703 return CRYPTO_new_ex_data ();
8704   ;
8705   return 0;
8706 }
8707 _ACEOF
8708 rm -f conftest.$ac_objext conftest$ac_exeext
8709 if { (ac_try="$ac_link"
8710 case "(($ac_try" in
8711   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8712   *) ac_try_echo=$ac_try;;
8713 esac
8714 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8715 $as_echo "$ac_try_echo") >&5
8716   (eval "$ac_link") 2>conftest.er1
8717   ac_status=$?
8718   grep -v '^ *+' conftest.er1 >conftest.err
8719   rm -f conftest.er1
8720   cat conftest.err >&5
8721   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8722   (exit $ac_status); } && {
8723          test -z "$ac_c_werror_flag" ||
8724          test ! -s conftest.err
8725        } && test -s conftest$ac_exeext && {
8726          test "$cross_compiling" = yes ||
8727          $as_test_x conftest$ac_exeext
8728        }; then
8729   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
8730 else
8731   $as_echo "$as_me: failed program was:" >&5
8732 sed 's/^/| /' conftest.$ac_ext >&5
8733
8734         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
8735 fi
8736
8737 rm -rf conftest.dSYM
8738 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8739       conftest$ac_exeext conftest.$ac_ext
8740 LIBS=$ac_check_lib_save_LIBS
8741 fi
8742 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
8743 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
8744 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
8745   cat >>confdefs.h <<_ACEOF
8746 #define HAVE_LIBCRYPTO 1
8747 _ACEOF
8748
8749   LIBS="-lcrypto $LIBS"
8750
8751 else
8752   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
8753 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
8754    { (exit 1); exit 1; }; }
8755 fi
8756
8757
8758 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
8759 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
8760 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
8761   $as_echo_n "(cached) " >&6
8762 else
8763   ac_check_lib_save_LIBS=$LIBS
8764 LIBS="-lssl  $LIBS"
8765 cat >conftest.$ac_ext <<_ACEOF
8766 /* confdefs.h.  */
8767 _ACEOF
8768 cat confdefs.h >>conftest.$ac_ext
8769 cat >>conftest.$ac_ext <<_ACEOF
8770 /* end confdefs.h.  */
8771
8772 /* Override any GCC internal prototype to avoid an error.
8773    Use char because int might match the return type of a GCC
8774    builtin and then its argument prototype would still apply.  */
8775 #ifdef __cplusplus
8776 extern "C"
8777 #endif
8778 char SSL_library_init ();
8779 int
8780 main ()
8781 {
8782 return SSL_library_init ();
8783   ;
8784   return 0;
8785 }
8786 _ACEOF
8787 rm -f conftest.$ac_objext conftest$ac_exeext
8788 if { (ac_try="$ac_link"
8789 case "(($ac_try" in
8790   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8791   *) ac_try_echo=$ac_try;;
8792 esac
8793 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8794 $as_echo "$ac_try_echo") >&5
8795   (eval "$ac_link") 2>conftest.er1
8796   ac_status=$?
8797   grep -v '^ *+' conftest.er1 >conftest.err
8798   rm -f conftest.er1
8799   cat conftest.err >&5
8800   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8801   (exit $ac_status); } && {
8802          test -z "$ac_c_werror_flag" ||
8803          test ! -s conftest.err
8804        } && test -s conftest$ac_exeext && {
8805          test "$cross_compiling" = yes ||
8806          $as_test_x conftest$ac_exeext
8807        }; then
8808   ac_cv_lib_ssl_SSL_library_init=yes
8809 else
8810   $as_echo "$as_me: failed program was:" >&5
8811 sed 's/^/| /' conftest.$ac_ext >&5
8812
8813         ac_cv_lib_ssl_SSL_library_init=no
8814 fi
8815
8816 rm -rf conftest.dSYM
8817 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8818       conftest$ac_exeext conftest.$ac_ext
8819 LIBS=$ac_check_lib_save_LIBS
8820 fi
8821 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
8822 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
8823 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
8824   cat >>confdefs.h <<_ACEOF
8825 #define HAVE_LIBSSL 1
8826 _ACEOF
8827
8828   LIBS="-lssl $LIBS"
8829
8830 else
8831   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
8832 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
8833    { (exit 1); exit 1; }; }
8834 fi
8835
8836   else
8837
8838 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
8839 $as_echo_n "checking for CRYPTO_new_ex_data in -leay32... " >&6; }
8840 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
8841   $as_echo_n "(cached) " >&6
8842 else
8843   ac_check_lib_save_LIBS=$LIBS
8844 LIBS="-leay32  $LIBS"
8845 cat >conftest.$ac_ext <<_ACEOF
8846 /* confdefs.h.  */
8847 _ACEOF
8848 cat confdefs.h >>conftest.$ac_ext
8849 cat >>conftest.$ac_ext <<_ACEOF
8850 /* end confdefs.h.  */
8851
8852 /* Override any GCC internal prototype to avoid an error.
8853    Use char because int might match the return type of a GCC
8854    builtin and then its argument prototype would still apply.  */
8855 #ifdef __cplusplus
8856 extern "C"
8857 #endif
8858 char CRYPTO_new_ex_data ();
8859 int
8860 main ()
8861 {
8862 return CRYPTO_new_ex_data ();
8863   ;
8864   return 0;
8865 }
8866 _ACEOF
8867 rm -f conftest.$ac_objext conftest$ac_exeext
8868 if { (ac_try="$ac_link"
8869 case "(($ac_try" in
8870   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8871   *) ac_try_echo=$ac_try;;
8872 esac
8873 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8874 $as_echo "$ac_try_echo") >&5
8875   (eval "$ac_link") 2>conftest.er1
8876   ac_status=$?
8877   grep -v '^ *+' conftest.er1 >conftest.err
8878   rm -f conftest.er1
8879   cat conftest.err >&5
8880   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8881   (exit $ac_status); } && {
8882          test -z "$ac_c_werror_flag" ||
8883          test ! -s conftest.err
8884        } && test -s conftest$ac_exeext && {
8885          test "$cross_compiling" = yes ||
8886          $as_test_x conftest$ac_exeext
8887        }; then
8888   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
8889 else
8890   $as_echo "$as_me: failed program was:" >&5
8891 sed 's/^/| /' conftest.$ac_ext >&5
8892
8893         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
8894 fi
8895
8896 rm -rf conftest.dSYM
8897 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8898       conftest$ac_exeext conftest.$ac_ext
8899 LIBS=$ac_check_lib_save_LIBS
8900 fi
8901 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
8902 $as_echo "$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
8903 if test "x$ac_cv_lib_eay32_CRYPTO_new_ex_data" = x""yes; then
8904   cat >>confdefs.h <<_ACEOF
8905 #define HAVE_LIBEAY32 1
8906 _ACEOF
8907
8908   LIBS="-leay32 $LIBS"
8909
8910 else
8911   { { $as_echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
8912 $as_echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
8913    { (exit 1); exit 1; }; }
8914 fi
8915
8916
8917 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
8918 $as_echo_n "checking for SSL_library_init in -lssleay32... " >&6; }
8919 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
8920   $as_echo_n "(cached) " >&6
8921 else
8922   ac_check_lib_save_LIBS=$LIBS
8923 LIBS="-lssleay32  $LIBS"
8924 cat >conftest.$ac_ext <<_ACEOF
8925 /* confdefs.h.  */
8926 _ACEOF
8927 cat confdefs.h >>conftest.$ac_ext
8928 cat >>conftest.$ac_ext <<_ACEOF
8929 /* end confdefs.h.  */
8930
8931 /* Override any GCC internal prototype to avoid an error.
8932    Use char because int might match the return type of a GCC
8933    builtin and then its argument prototype would still apply.  */
8934 #ifdef __cplusplus
8935 extern "C"
8936 #endif
8937 char SSL_library_init ();
8938 int
8939 main ()
8940 {
8941 return SSL_library_init ();
8942   ;
8943   return 0;
8944 }
8945 _ACEOF
8946 rm -f conftest.$ac_objext conftest$ac_exeext
8947 if { (ac_try="$ac_link"
8948 case "(($ac_try" in
8949   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8950   *) ac_try_echo=$ac_try;;
8951 esac
8952 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8953 $as_echo "$ac_try_echo") >&5
8954   (eval "$ac_link") 2>conftest.er1
8955   ac_status=$?
8956   grep -v '^ *+' conftest.er1 >conftest.err
8957   rm -f conftest.er1
8958   cat conftest.err >&5
8959   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8960   (exit $ac_status); } && {
8961          test -z "$ac_c_werror_flag" ||
8962          test ! -s conftest.err
8963        } && test -s conftest$ac_exeext && {
8964          test "$cross_compiling" = yes ||
8965          $as_test_x conftest$ac_exeext
8966        }; then
8967   ac_cv_lib_ssleay32_SSL_library_init=yes
8968 else
8969   $as_echo "$as_me: failed program was:" >&5
8970 sed 's/^/| /' conftest.$ac_ext >&5
8971
8972         ac_cv_lib_ssleay32_SSL_library_init=no
8973 fi
8974
8975 rm -rf conftest.dSYM
8976 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8977       conftest$ac_exeext conftest.$ac_ext
8978 LIBS=$ac_check_lib_save_LIBS
8979 fi
8980 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
8981 $as_echo "$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
8982 if test "x$ac_cv_lib_ssleay32_SSL_library_init" = x""yes; then
8983   cat >>confdefs.h <<_ACEOF
8984 #define HAVE_LIBSSLEAY32 1
8985 _ACEOF
8986
8987   LIBS="-lssleay32 $LIBS"
8988
8989 else
8990   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
8991 $as_echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
8992    { (exit 1); exit 1; }; }
8993 fi
8994
8995   fi
8996 fi
8997
8998 if test "$with_pam" = yes ; then
8999
9000 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
9001 $as_echo_n "checking for pam_start in -lpam... " >&6; }
9002 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
9003   $as_echo_n "(cached) " >&6
9004 else
9005   ac_check_lib_save_LIBS=$LIBS
9006 LIBS="-lpam  $LIBS"
9007 cat >conftest.$ac_ext <<_ACEOF
9008 /* confdefs.h.  */
9009 _ACEOF
9010 cat confdefs.h >>conftest.$ac_ext
9011 cat >>conftest.$ac_ext <<_ACEOF
9012 /* end confdefs.h.  */
9013
9014 /* Override any GCC internal prototype to avoid an error.
9015    Use char because int might match the return type of a GCC
9016    builtin and then its argument prototype would still apply.  */
9017 #ifdef __cplusplus
9018 extern "C"
9019 #endif
9020 char pam_start ();
9021 int
9022 main ()
9023 {
9024 return pam_start ();
9025   ;
9026   return 0;
9027 }
9028 _ACEOF
9029 rm -f conftest.$ac_objext conftest$ac_exeext
9030 if { (ac_try="$ac_link"
9031 case "(($ac_try" in
9032   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9033   *) ac_try_echo=$ac_try;;
9034 esac
9035 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9036 $as_echo "$ac_try_echo") >&5
9037   (eval "$ac_link") 2>conftest.er1
9038   ac_status=$?
9039   grep -v '^ *+' conftest.er1 >conftest.err
9040   rm -f conftest.er1
9041   cat conftest.err >&5
9042   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9043   (exit $ac_status); } && {
9044          test -z "$ac_c_werror_flag" ||
9045          test ! -s conftest.err
9046        } && test -s conftest$ac_exeext && {
9047          test "$cross_compiling" = yes ||
9048          $as_test_x conftest$ac_exeext
9049        }; then
9050   ac_cv_lib_pam_pam_start=yes
9051 else
9052   $as_echo "$as_me: failed program was:" >&5
9053 sed 's/^/| /' conftest.$ac_ext >&5
9054
9055         ac_cv_lib_pam_pam_start=no
9056 fi
9057
9058 rm -rf conftest.dSYM
9059 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9060       conftest$ac_exeext conftest.$ac_ext
9061 LIBS=$ac_check_lib_save_LIBS
9062 fi
9063 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9064 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9065 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9066   cat >>confdefs.h <<_ACEOF
9067 #define HAVE_LIBPAM 1
9068 _ACEOF
9069
9070   LIBS="-lpam $LIBS"
9071
9072 else
9073   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9074 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9075    { (exit 1); exit 1; }; }
9076 fi
9077
9078 fi
9079
9080 if test "$with_libxml" = yes ; then
9081
9082 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9083 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9084 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9085   $as_echo_n "(cached) " >&6
9086 else
9087   ac_check_lib_save_LIBS=$LIBS
9088 LIBS="-lxml2  $LIBS"
9089 cat >conftest.$ac_ext <<_ACEOF
9090 /* confdefs.h.  */
9091 _ACEOF
9092 cat confdefs.h >>conftest.$ac_ext
9093 cat >>conftest.$ac_ext <<_ACEOF
9094 /* end confdefs.h.  */
9095
9096 /* Override any GCC internal prototype to avoid an error.
9097    Use char because int might match the return type of a GCC
9098    builtin and then its argument prototype would still apply.  */
9099 #ifdef __cplusplus
9100 extern "C"
9101 #endif
9102 char xmlSaveToBuffer ();
9103 int
9104 main ()
9105 {
9106 return xmlSaveToBuffer ();
9107   ;
9108   return 0;
9109 }
9110 _ACEOF
9111 rm -f conftest.$ac_objext conftest$ac_exeext
9112 if { (ac_try="$ac_link"
9113 case "(($ac_try" in
9114   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9115   *) ac_try_echo=$ac_try;;
9116 esac
9117 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9118 $as_echo "$ac_try_echo") >&5
9119   (eval "$ac_link") 2>conftest.er1
9120   ac_status=$?
9121   grep -v '^ *+' conftest.er1 >conftest.err
9122   rm -f conftest.er1
9123   cat conftest.err >&5
9124   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9125   (exit $ac_status); } && {
9126          test -z "$ac_c_werror_flag" ||
9127          test ! -s conftest.err
9128        } && test -s conftest$ac_exeext && {
9129          test "$cross_compiling" = yes ||
9130          $as_test_x conftest$ac_exeext
9131        }; then
9132   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9133 else
9134   $as_echo "$as_me: failed program was:" >&5
9135 sed 's/^/| /' conftest.$ac_ext >&5
9136
9137         ac_cv_lib_xml2_xmlSaveToBuffer=no
9138 fi
9139
9140 rm -rf conftest.dSYM
9141 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9142       conftest$ac_exeext conftest.$ac_ext
9143 LIBS=$ac_check_lib_save_LIBS
9144 fi
9145 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9146 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9147 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9148   cat >>confdefs.h <<_ACEOF
9149 #define HAVE_LIBXML2 1
9150 _ACEOF
9151
9152   LIBS="-lxml2 $LIBS"
9153
9154 else
9155   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9156 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9157    { (exit 1); exit 1; }; }
9158 fi
9159
9160 fi
9161
9162 if test "$with_libxslt" = yes ; then
9163
9164 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9165 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9166 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9167   $as_echo_n "(cached) " >&6
9168 else
9169   ac_check_lib_save_LIBS=$LIBS
9170 LIBS="-lxslt  $LIBS"
9171 cat >conftest.$ac_ext <<_ACEOF
9172 /* confdefs.h.  */
9173 _ACEOF
9174 cat confdefs.h >>conftest.$ac_ext
9175 cat >>conftest.$ac_ext <<_ACEOF
9176 /* end confdefs.h.  */
9177
9178 /* Override any GCC internal prototype to avoid an error.
9179    Use char because int might match the return type of a GCC
9180    builtin and then its argument prototype would still apply.  */
9181 #ifdef __cplusplus
9182 extern "C"
9183 #endif
9184 char xsltCleanupGlobals ();
9185 int
9186 main ()
9187 {
9188 return xsltCleanupGlobals ();
9189   ;
9190   return 0;
9191 }
9192 _ACEOF
9193 rm -f conftest.$ac_objext conftest$ac_exeext
9194 if { (ac_try="$ac_link"
9195 case "(($ac_try" in
9196   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9197   *) ac_try_echo=$ac_try;;
9198 esac
9199 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9200 $as_echo "$ac_try_echo") >&5
9201   (eval "$ac_link") 2>conftest.er1
9202   ac_status=$?
9203   grep -v '^ *+' conftest.er1 >conftest.err
9204   rm -f conftest.er1
9205   cat conftest.err >&5
9206   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9207   (exit $ac_status); } && {
9208          test -z "$ac_c_werror_flag" ||
9209          test ! -s conftest.err
9210        } && test -s conftest$ac_exeext && {
9211          test "$cross_compiling" = yes ||
9212          $as_test_x conftest$ac_exeext
9213        }; then
9214   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9215 else
9216   $as_echo "$as_me: failed program was:" >&5
9217 sed 's/^/| /' conftest.$ac_ext >&5
9218
9219         ac_cv_lib_xslt_xsltCleanupGlobals=no
9220 fi
9221
9222 rm -rf conftest.dSYM
9223 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9224       conftest$ac_exeext conftest.$ac_ext
9225 LIBS=$ac_check_lib_save_LIBS
9226 fi
9227 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9228 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9229 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9230   cat >>confdefs.h <<_ACEOF
9231 #define HAVE_LIBXSLT 1
9232 _ACEOF
9233
9234   LIBS="-lxslt $LIBS"
9235
9236 else
9237   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
9238 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
9239    { (exit 1); exit 1; }; }
9240 fi
9241
9242 fi
9243
9244 # for contrib/uuid-ossp
9245 if test "$with_ossp_uuid" = yes ; then
9246   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
9247 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
9248 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
9249   $as_echo_n "(cached) " >&6
9250 else
9251   ac_check_lib_save_LIBS=$LIBS
9252 LIBS="-lossp-uuid  $LIBS"
9253 cat >conftest.$ac_ext <<_ACEOF
9254 /* confdefs.h.  */
9255 _ACEOF
9256 cat confdefs.h >>conftest.$ac_ext
9257 cat >>conftest.$ac_ext <<_ACEOF
9258 /* end confdefs.h.  */
9259
9260 /* Override any GCC internal prototype to avoid an error.
9261    Use char because int might match the return type of a GCC
9262    builtin and then its argument prototype would still apply.  */
9263 #ifdef __cplusplus
9264 extern "C"
9265 #endif
9266 char uuid_export ();
9267 int
9268 main ()
9269 {
9270 return uuid_export ();
9271   ;
9272   return 0;
9273 }
9274 _ACEOF
9275 rm -f conftest.$ac_objext conftest$ac_exeext
9276 if { (ac_try="$ac_link"
9277 case "(($ac_try" in
9278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9279   *) ac_try_echo=$ac_try;;
9280 esac
9281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9282 $as_echo "$ac_try_echo") >&5
9283   (eval "$ac_link") 2>conftest.er1
9284   ac_status=$?
9285   grep -v '^ *+' conftest.er1 >conftest.err
9286   rm -f conftest.er1
9287   cat conftest.err >&5
9288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9289   (exit $ac_status); } && {
9290          test -z "$ac_c_werror_flag" ||
9291          test ! -s conftest.err
9292        } && test -s conftest$ac_exeext && {
9293          test "$cross_compiling" = yes ||
9294          $as_test_x conftest$ac_exeext
9295        }; then
9296   ac_cv_lib_ossp_uuid_uuid_export=yes
9297 else
9298   $as_echo "$as_me: failed program was:" >&5
9299 sed 's/^/| /' conftest.$ac_ext >&5
9300
9301         ac_cv_lib_ossp_uuid_uuid_export=no
9302 fi
9303
9304 rm -rf conftest.dSYM
9305 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9306       conftest$ac_exeext conftest.$ac_ext
9307 LIBS=$ac_check_lib_save_LIBS
9308 fi
9309 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
9310 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
9311 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
9312   OSSP_UUID_LIBS="-lossp-uuid"
9313 else
9314   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
9315 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
9316 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
9317   $as_echo_n "(cached) " >&6
9318 else
9319   ac_check_lib_save_LIBS=$LIBS
9320 LIBS="-luuid  $LIBS"
9321 cat >conftest.$ac_ext <<_ACEOF
9322 /* confdefs.h.  */
9323 _ACEOF
9324 cat confdefs.h >>conftest.$ac_ext
9325 cat >>conftest.$ac_ext <<_ACEOF
9326 /* end confdefs.h.  */
9327
9328 /* Override any GCC internal prototype to avoid an error.
9329    Use char because int might match the return type of a GCC
9330    builtin and then its argument prototype would still apply.  */
9331 #ifdef __cplusplus
9332 extern "C"
9333 #endif
9334 char uuid_export ();
9335 int
9336 main ()
9337 {
9338 return uuid_export ();
9339   ;
9340   return 0;
9341 }
9342 _ACEOF
9343 rm -f conftest.$ac_objext conftest$ac_exeext
9344 if { (ac_try="$ac_link"
9345 case "(($ac_try" in
9346   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9347   *) ac_try_echo=$ac_try;;
9348 esac
9349 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9350 $as_echo "$ac_try_echo") >&5
9351   (eval "$ac_link") 2>conftest.er1
9352   ac_status=$?
9353   grep -v '^ *+' conftest.er1 >conftest.err
9354   rm -f conftest.er1
9355   cat conftest.err >&5
9356   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9357   (exit $ac_status); } && {
9358          test -z "$ac_c_werror_flag" ||
9359          test ! -s conftest.err
9360        } && test -s conftest$ac_exeext && {
9361          test "$cross_compiling" = yes ||
9362          $as_test_x conftest$ac_exeext
9363        }; then
9364   ac_cv_lib_uuid_uuid_export=yes
9365 else
9366   $as_echo "$as_me: failed program was:" >&5
9367 sed 's/^/| /' conftest.$ac_ext >&5
9368
9369         ac_cv_lib_uuid_uuid_export=no
9370 fi
9371
9372 rm -rf conftest.dSYM
9373 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9374       conftest$ac_exeext conftest.$ac_ext
9375 LIBS=$ac_check_lib_save_LIBS
9376 fi
9377 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
9378 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
9379 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
9380   OSSP_UUID_LIBS="-luuid"
9381 else
9382   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
9383 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
9384    { (exit 1); exit 1; }; }
9385 fi
9386
9387 fi
9388
9389 fi
9390
9391
9392
9393 ##
9394 ## Header files
9395 ##
9396
9397 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
9398 $as_echo_n "checking for ANSI C header files... " >&6; }
9399 if test "${ac_cv_header_stdc+set}" = set; then
9400   $as_echo_n "(cached) " >&6
9401 else
9402   cat >conftest.$ac_ext <<_ACEOF
9403 /* confdefs.h.  */
9404 _ACEOF
9405 cat confdefs.h >>conftest.$ac_ext
9406 cat >>conftest.$ac_ext <<_ACEOF
9407 /* end confdefs.h.  */
9408 #include <stdlib.h>
9409 #include <stdarg.h>
9410 #include <string.h>
9411 #include <float.h>
9412
9413 int
9414 main ()
9415 {
9416
9417   ;
9418   return 0;
9419 }
9420 _ACEOF
9421 rm -f conftest.$ac_objext
9422 if { (ac_try="$ac_compile"
9423 case "(($ac_try" in
9424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9425   *) ac_try_echo=$ac_try;;
9426 esac
9427 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9428 $as_echo "$ac_try_echo") >&5
9429   (eval "$ac_compile") 2>conftest.er1
9430   ac_status=$?
9431   grep -v '^ *+' conftest.er1 >conftest.err
9432   rm -f conftest.er1
9433   cat conftest.err >&5
9434   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9435   (exit $ac_status); } && {
9436          test -z "$ac_c_werror_flag" ||
9437          test ! -s conftest.err
9438        } && test -s conftest.$ac_objext; then
9439   ac_cv_header_stdc=yes
9440 else
9441   $as_echo "$as_me: failed program was:" >&5
9442 sed 's/^/| /' conftest.$ac_ext >&5
9443
9444         ac_cv_header_stdc=no
9445 fi
9446
9447 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9448
9449 if test $ac_cv_header_stdc = yes; then
9450   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9451   cat >conftest.$ac_ext <<_ACEOF
9452 /* confdefs.h.  */
9453 _ACEOF
9454 cat confdefs.h >>conftest.$ac_ext
9455 cat >>conftest.$ac_ext <<_ACEOF
9456 /* end confdefs.h.  */
9457 #include <string.h>
9458
9459 _ACEOF
9460 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9461   $EGREP "memchr" >/dev/null 2>&1; then
9462   :
9463 else
9464   ac_cv_header_stdc=no
9465 fi
9466 rm -f conftest*
9467
9468 fi
9469
9470 if test $ac_cv_header_stdc = yes; then
9471   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9472   cat >conftest.$ac_ext <<_ACEOF
9473 /* confdefs.h.  */
9474 _ACEOF
9475 cat confdefs.h >>conftest.$ac_ext
9476 cat >>conftest.$ac_ext <<_ACEOF
9477 /* end confdefs.h.  */
9478 #include <stdlib.h>
9479
9480 _ACEOF
9481 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9482   $EGREP "free" >/dev/null 2>&1; then
9483   :
9484 else
9485   ac_cv_header_stdc=no
9486 fi
9487 rm -f conftest*
9488
9489 fi
9490
9491 if test $ac_cv_header_stdc = yes; then
9492   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9493   if test "$cross_compiling" = yes; then
9494   :
9495 else
9496   cat >conftest.$ac_ext <<_ACEOF
9497 /* confdefs.h.  */
9498 _ACEOF
9499 cat confdefs.h >>conftest.$ac_ext
9500 cat >>conftest.$ac_ext <<_ACEOF
9501 /* end confdefs.h.  */
9502 #include <ctype.h>
9503 #include <stdlib.h>
9504 #if ((' ' & 0x0FF) == 0x020)
9505 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
9506 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
9507 #else
9508 # define ISLOWER(c) \
9509                    (('a' <= (c) && (c) <= 'i') \
9510                      || ('j' <= (c) && (c) <= 'r') \
9511                      || ('s' <= (c) && (c) <= 'z'))
9512 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
9513 #endif
9514
9515 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
9516 int
9517 main ()
9518 {
9519   int i;
9520   for (i = 0; i < 256; i++)
9521     if (XOR (islower (i), ISLOWER (i))
9522         || toupper (i) != TOUPPER (i))
9523       return 2;
9524   return 0;
9525 }
9526 _ACEOF
9527 rm -f conftest$ac_exeext
9528 if { (ac_try="$ac_link"
9529 case "(($ac_try" in
9530   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9531   *) ac_try_echo=$ac_try;;
9532 esac
9533 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9534 $as_echo "$ac_try_echo") >&5
9535   (eval "$ac_link") 2>&5
9536   ac_status=$?
9537   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9538   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9539   { (case "(($ac_try" in
9540   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9541   *) ac_try_echo=$ac_try;;
9542 esac
9543 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9544 $as_echo "$ac_try_echo") >&5
9545   (eval "$ac_try") 2>&5
9546   ac_status=$?
9547   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9548   (exit $ac_status); }; }; then
9549   :
9550 else
9551   $as_echo "$as_me: program exited with status $ac_status" >&5
9552 $as_echo "$as_me: failed program was:" >&5
9553 sed 's/^/| /' conftest.$ac_ext >&5
9554
9555 ( exit $ac_status )
9556 ac_cv_header_stdc=no
9557 fi
9558 rm -rf conftest.dSYM
9559 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9560 fi
9561
9562
9563 fi
9564 fi
9565 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
9566 $as_echo "$ac_cv_header_stdc" >&6; }
9567 if test $ac_cv_header_stdc = yes; then
9568
9569 cat >>confdefs.h <<\_ACEOF
9570 #define STDC_HEADERS 1
9571 _ACEOF
9572
9573 fi
9574
9575 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
9576
9577
9578
9579
9580
9581
9582
9583
9584
9585 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
9586                   inttypes.h stdint.h unistd.h
9587 do
9588 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9589 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9590 $as_echo_n "checking for $ac_header... " >&6; }
9591 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9592   $as_echo_n "(cached) " >&6
9593 else
9594   cat >conftest.$ac_ext <<_ACEOF
9595 /* confdefs.h.  */
9596 _ACEOF
9597 cat confdefs.h >>conftest.$ac_ext
9598 cat >>conftest.$ac_ext <<_ACEOF
9599 /* end confdefs.h.  */
9600 $ac_includes_default
9601
9602 #include <$ac_header>
9603 _ACEOF
9604 rm -f conftest.$ac_objext
9605 if { (ac_try="$ac_compile"
9606 case "(($ac_try" in
9607   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9608   *) ac_try_echo=$ac_try;;
9609 esac
9610 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9611 $as_echo "$ac_try_echo") >&5
9612   (eval "$ac_compile") 2>conftest.er1
9613   ac_status=$?
9614   grep -v '^ *+' conftest.er1 >conftest.err
9615   rm -f conftest.er1
9616   cat conftest.err >&5
9617   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9618   (exit $ac_status); } && {
9619          test -z "$ac_c_werror_flag" ||
9620          test ! -s conftest.err
9621        } && test -s conftest.$ac_objext; then
9622   eval "$as_ac_Header=yes"
9623 else
9624   $as_echo "$as_me: failed program was:" >&5
9625 sed 's/^/| /' conftest.$ac_ext >&5
9626
9627         eval "$as_ac_Header=no"
9628 fi
9629
9630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9631 fi
9632 ac_res=`eval 'as_val=${'$as_ac_Header'}
9633                  $as_echo "$as_val"'`
9634                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9635 $as_echo "$ac_res" >&6; }
9636 as_val=`eval 'as_val=${'$as_ac_Header'}
9637                  $as_echo "$as_val"'`
9638    if test "x$as_val" = x""yes; then
9639   cat >>confdefs.h <<_ACEOF
9640 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9641 _ACEOF
9642
9643 fi
9644
9645 done
9646
9647
9648
9649
9650
9651
9652
9653
9654
9655
9656
9657
9658
9659
9660
9661
9662
9663
9664
9665
9666
9667
9668
9669
9670
9671
9672
9673
9674
9675
9676
9677
9678 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
9679 do
9680 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9681 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9682   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9683 $as_echo_n "checking for $ac_header... " >&6; }
9684 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9685   $as_echo_n "(cached) " >&6
9686 fi
9687 ac_res=`eval 'as_val=${'$as_ac_Header'}
9688                  $as_echo "$as_val"'`
9689                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9690 $as_echo "$ac_res" >&6; }
9691 else
9692   # Is the header compilable?
9693 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9694 $as_echo_n "checking $ac_header usability... " >&6; }
9695 cat >conftest.$ac_ext <<_ACEOF
9696 /* confdefs.h.  */
9697 _ACEOF
9698 cat confdefs.h >>conftest.$ac_ext
9699 cat >>conftest.$ac_ext <<_ACEOF
9700 /* end confdefs.h.  */
9701 $ac_includes_default
9702 #include <$ac_header>
9703 _ACEOF
9704 rm -f conftest.$ac_objext
9705 if { (ac_try="$ac_compile"
9706 case "(($ac_try" in
9707   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9708   *) ac_try_echo=$ac_try;;
9709 esac
9710 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9711 $as_echo "$ac_try_echo") >&5
9712   (eval "$ac_compile") 2>conftest.er1
9713   ac_status=$?
9714   grep -v '^ *+' conftest.er1 >conftest.err
9715   rm -f conftest.er1
9716   cat conftest.err >&5
9717   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9718   (exit $ac_status); } && {
9719          test -z "$ac_c_werror_flag" ||
9720          test ! -s conftest.err
9721        } && test -s conftest.$ac_objext; then
9722   ac_header_compiler=yes
9723 else
9724   $as_echo "$as_me: failed program was:" >&5
9725 sed 's/^/| /' conftest.$ac_ext >&5
9726
9727         ac_header_compiler=no
9728 fi
9729
9730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9731 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9732 $as_echo "$ac_header_compiler" >&6; }
9733
9734 # Is the header present?
9735 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9736 $as_echo_n "checking $ac_header presence... " >&6; }
9737 cat >conftest.$ac_ext <<_ACEOF
9738 /* confdefs.h.  */
9739 _ACEOF
9740 cat confdefs.h >>conftest.$ac_ext
9741 cat >>conftest.$ac_ext <<_ACEOF
9742 /* end confdefs.h.  */
9743 #include <$ac_header>
9744 _ACEOF
9745 if { (ac_try="$ac_cpp conftest.$ac_ext"
9746 case "(($ac_try" in
9747   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9748   *) ac_try_echo=$ac_try;;
9749 esac
9750 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9751 $as_echo "$ac_try_echo") >&5
9752   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9753   ac_status=$?
9754   grep -v '^ *+' conftest.er1 >conftest.err
9755   rm -f conftest.er1
9756   cat conftest.err >&5
9757   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9758   (exit $ac_status); } >/dev/null && {
9759          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9760          test ! -s conftest.err
9761        }; then
9762   ac_header_preproc=yes
9763 else
9764   $as_echo "$as_me: failed program was:" >&5
9765 sed 's/^/| /' conftest.$ac_ext >&5
9766
9767   ac_header_preproc=no
9768 fi
9769
9770 rm -f conftest.err conftest.$ac_ext
9771 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9772 $as_echo "$ac_header_preproc" >&6; }
9773
9774 # So?  What about this header?
9775 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9776   yes:no: )
9777     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9778 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9779     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9780 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9781     ac_header_preproc=yes
9782     ;;
9783   no:yes:* )
9784     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9785 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9786     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9787 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9788     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9789 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9790     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9791 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9792     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9793 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9794     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9795 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9796     ( cat <<\_ASBOX
9797 ## ---------------------------------------- ##
9798 ## Report this to pgsql-bugs@postgresql.org ##
9799 ## ---------------------------------------- ##
9800 _ASBOX
9801      ) | sed "s/^/$as_me: WARNING:     /" >&2
9802     ;;
9803 esac
9804 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9805 $as_echo_n "checking for $ac_header... " >&6; }
9806 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9807   $as_echo_n "(cached) " >&6
9808 else
9809   eval "$as_ac_Header=\$ac_header_preproc"
9810 fi
9811 ac_res=`eval 'as_val=${'$as_ac_Header'}
9812                  $as_echo "$as_val"'`
9813                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9814 $as_echo "$ac_res" >&6; }
9815
9816 fi
9817 as_val=`eval 'as_val=${'$as_ac_Header'}
9818                  $as_echo "$as_val"'`
9819    if test "x$as_val" = x""yes; then
9820   cat >>confdefs.h <<_ACEOF
9821 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9822 _ACEOF
9823
9824 fi
9825
9826 done
9827
9828
9829 # On BSD, cpp test for net/if.h will fail unless sys/socket.h
9830 # is included first.
9831
9832 for ac_header in net/if.h
9833 do
9834 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9835 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9836 $as_echo_n "checking for $ac_header... " >&6; }
9837 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9838   $as_echo_n "(cached) " >&6
9839 else
9840   cat >conftest.$ac_ext <<_ACEOF
9841 /* confdefs.h.  */
9842 _ACEOF
9843 cat confdefs.h >>conftest.$ac_ext
9844 cat >>conftest.$ac_ext <<_ACEOF
9845 /* end confdefs.h.  */
9846 $ac_includes_default
9847 #ifdef HAVE_SYS_SOCKET_H
9848 #include <sys/socket.h>
9849 #endif
9850
9851
9852 #include <$ac_header>
9853 _ACEOF
9854 rm -f conftest.$ac_objext
9855 if { (ac_try="$ac_compile"
9856 case "(($ac_try" in
9857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9858   *) ac_try_echo=$ac_try;;
9859 esac
9860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9861 $as_echo "$ac_try_echo") >&5
9862   (eval "$ac_compile") 2>conftest.er1
9863   ac_status=$?
9864   grep -v '^ *+' conftest.er1 >conftest.err
9865   rm -f conftest.er1
9866   cat conftest.err >&5
9867   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9868   (exit $ac_status); } && {
9869          test -z "$ac_c_werror_flag" ||
9870          test ! -s conftest.err
9871        } && test -s conftest.$ac_objext; then
9872   eval "$as_ac_Header=yes"
9873 else
9874   $as_echo "$as_me: failed program was:" >&5
9875 sed 's/^/| /' conftest.$ac_ext >&5
9876
9877         eval "$as_ac_Header=no"
9878 fi
9879
9880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9881 fi
9882 ac_res=`eval 'as_val=${'$as_ac_Header'}
9883                  $as_echo "$as_val"'`
9884                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9885 $as_echo "$ac_res" >&6; }
9886 as_val=`eval 'as_val=${'$as_ac_Header'}
9887                  $as_echo "$as_val"'`
9888    if test "x$as_val" = x""yes; then
9889   cat >>confdefs.h <<_ACEOF
9890 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9891 _ACEOF
9892
9893 fi
9894
9895 done
9896
9897
9898 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
9899 # netinet/in.h is included first.
9900
9901 for ac_header in netinet/in.h
9902 do
9903 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9904 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9905   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9906 $as_echo_n "checking for $ac_header... " >&6; }
9907 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9908   $as_echo_n "(cached) " >&6
9909 fi
9910 ac_res=`eval 'as_val=${'$as_ac_Header'}
9911                  $as_echo "$as_val"'`
9912                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9913 $as_echo "$ac_res" >&6; }
9914 else
9915   # Is the header compilable?
9916 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9917 $as_echo_n "checking $ac_header usability... " >&6; }
9918 cat >conftest.$ac_ext <<_ACEOF
9919 /* confdefs.h.  */
9920 _ACEOF
9921 cat confdefs.h >>conftest.$ac_ext
9922 cat >>conftest.$ac_ext <<_ACEOF
9923 /* end confdefs.h.  */
9924 $ac_includes_default
9925 #include <$ac_header>
9926 _ACEOF
9927 rm -f conftest.$ac_objext
9928 if { (ac_try="$ac_compile"
9929 case "(($ac_try" in
9930   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9931   *) ac_try_echo=$ac_try;;
9932 esac
9933 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9934 $as_echo "$ac_try_echo") >&5
9935   (eval "$ac_compile") 2>conftest.er1
9936   ac_status=$?
9937   grep -v '^ *+' conftest.er1 >conftest.err
9938   rm -f conftest.er1
9939   cat conftest.err >&5
9940   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9941   (exit $ac_status); } && {
9942          test -z "$ac_c_werror_flag" ||
9943          test ! -s conftest.err
9944        } && test -s conftest.$ac_objext; then
9945   ac_header_compiler=yes
9946 else
9947   $as_echo "$as_me: failed program was:" >&5
9948 sed 's/^/| /' conftest.$ac_ext >&5
9949
9950         ac_header_compiler=no
9951 fi
9952
9953 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9954 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9955 $as_echo "$ac_header_compiler" >&6; }
9956
9957 # Is the header present?
9958 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9959 $as_echo_n "checking $ac_header presence... " >&6; }
9960 cat >conftest.$ac_ext <<_ACEOF
9961 /* confdefs.h.  */
9962 _ACEOF
9963 cat confdefs.h >>conftest.$ac_ext
9964 cat >>conftest.$ac_ext <<_ACEOF
9965 /* end confdefs.h.  */
9966 #include <$ac_header>
9967 _ACEOF
9968 if { (ac_try="$ac_cpp conftest.$ac_ext"
9969 case "(($ac_try" in
9970   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9971   *) ac_try_echo=$ac_try;;
9972 esac
9973 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9974 $as_echo "$ac_try_echo") >&5
9975   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9976   ac_status=$?
9977   grep -v '^ *+' conftest.er1 >conftest.err
9978   rm -f conftest.er1
9979   cat conftest.err >&5
9980   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9981   (exit $ac_status); } >/dev/null && {
9982          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9983          test ! -s conftest.err
9984        }; then
9985   ac_header_preproc=yes
9986 else
9987   $as_echo "$as_me: failed program was:" >&5
9988 sed 's/^/| /' conftest.$ac_ext >&5
9989
9990   ac_header_preproc=no
9991 fi
9992
9993 rm -f conftest.err conftest.$ac_ext
9994 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9995 $as_echo "$ac_header_preproc" >&6; }
9996
9997 # So?  What about this header?
9998 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9999   yes:no: )
10000     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10001 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10002     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10003 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10004     ac_header_preproc=yes
10005     ;;
10006   no:yes:* )
10007     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10008 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10009     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10010 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10011     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10012 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10013     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10014 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10015     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10016 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10017     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10018 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10019     ( cat <<\_ASBOX
10020 ## ---------------------------------------- ##
10021 ## Report this to pgsql-bugs@postgresql.org ##
10022 ## ---------------------------------------- ##
10023 _ASBOX
10024      ) | sed "s/^/$as_me: WARNING:     /" >&2
10025     ;;
10026 esac
10027 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10028 $as_echo_n "checking for $ac_header... " >&6; }
10029 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10030   $as_echo_n "(cached) " >&6
10031 else
10032   eval "$as_ac_Header=\$ac_header_preproc"
10033 fi
10034 ac_res=`eval 'as_val=${'$as_ac_Header'}
10035                  $as_echo "$as_val"'`
10036                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10037 $as_echo "$ac_res" >&6; }
10038
10039 fi
10040 as_val=`eval 'as_val=${'$as_ac_Header'}
10041                  $as_echo "$as_val"'`
10042    if test "x$as_val" = x""yes; then
10043   cat >>confdefs.h <<_ACEOF
10044 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10045 _ACEOF
10046
10047 fi
10048
10049 done
10050
10051
10052 for ac_header in netinet/tcp.h
10053 do
10054 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10055 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10056 $as_echo_n "checking for $ac_header... " >&6; }
10057 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10058   $as_echo_n "(cached) " >&6
10059 else
10060   cat >conftest.$ac_ext <<_ACEOF
10061 /* confdefs.h.  */
10062 _ACEOF
10063 cat confdefs.h >>conftest.$ac_ext
10064 cat >>conftest.$ac_ext <<_ACEOF
10065 /* end confdefs.h.  */
10066 $ac_includes_default
10067 #ifdef HAVE_NETINET_IN_H
10068 #include <netinet/in.h>
10069 #endif
10070
10071
10072 #include <$ac_header>
10073 _ACEOF
10074 rm -f conftest.$ac_objext
10075 if { (ac_try="$ac_compile"
10076 case "(($ac_try" in
10077   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10078   *) ac_try_echo=$ac_try;;
10079 esac
10080 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10081 $as_echo "$ac_try_echo") >&5
10082   (eval "$ac_compile") 2>conftest.er1
10083   ac_status=$?
10084   grep -v '^ *+' conftest.er1 >conftest.err
10085   rm -f conftest.er1
10086   cat conftest.err >&5
10087   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10088   (exit $ac_status); } && {
10089          test -z "$ac_c_werror_flag" ||
10090          test ! -s conftest.err
10091        } && test -s conftest.$ac_objext; then
10092   eval "$as_ac_Header=yes"
10093 else
10094   $as_echo "$as_me: failed program was:" >&5
10095 sed 's/^/| /' conftest.$ac_ext >&5
10096
10097         eval "$as_ac_Header=no"
10098 fi
10099
10100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10101 fi
10102 ac_res=`eval 'as_val=${'$as_ac_Header'}
10103                  $as_echo "$as_val"'`
10104                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10105 $as_echo "$ac_res" >&6; }
10106 as_val=`eval 'as_val=${'$as_ac_Header'}
10107                  $as_echo "$as_val"'`
10108    if test "x$as_val" = x""yes; then
10109   cat >>confdefs.h <<_ACEOF
10110 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10111 _ACEOF
10112
10113 fi
10114
10115 done
10116
10117
10118 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
10119
10120 for ac_header in readline/readline.h
10121 do
10122 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10123 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10124   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10125 $as_echo_n "checking for $ac_header... " >&6; }
10126 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10127   $as_echo_n "(cached) " >&6
10128 fi
10129 ac_res=`eval 'as_val=${'$as_ac_Header'}
10130                  $as_echo "$as_val"'`
10131                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10132 $as_echo "$ac_res" >&6; }
10133 else
10134   # Is the header compilable?
10135 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10136 $as_echo_n "checking $ac_header usability... " >&6; }
10137 cat >conftest.$ac_ext <<_ACEOF
10138 /* confdefs.h.  */
10139 _ACEOF
10140 cat confdefs.h >>conftest.$ac_ext
10141 cat >>conftest.$ac_ext <<_ACEOF
10142 /* end confdefs.h.  */
10143 $ac_includes_default
10144 #include <$ac_header>
10145 _ACEOF
10146 rm -f conftest.$ac_objext
10147 if { (ac_try="$ac_compile"
10148 case "(($ac_try" in
10149   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10150   *) ac_try_echo=$ac_try;;
10151 esac
10152 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10153 $as_echo "$ac_try_echo") >&5
10154   (eval "$ac_compile") 2>conftest.er1
10155   ac_status=$?
10156   grep -v '^ *+' conftest.er1 >conftest.err
10157   rm -f conftest.er1
10158   cat conftest.err >&5
10159   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10160   (exit $ac_status); } && {
10161          test -z "$ac_c_werror_flag" ||
10162          test ! -s conftest.err
10163        } && test -s conftest.$ac_objext; then
10164   ac_header_compiler=yes
10165 else
10166   $as_echo "$as_me: failed program was:" >&5
10167 sed 's/^/| /' conftest.$ac_ext >&5
10168
10169         ac_header_compiler=no
10170 fi
10171
10172 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10173 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10174 $as_echo "$ac_header_compiler" >&6; }
10175
10176 # Is the header present?
10177 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10178 $as_echo_n "checking $ac_header presence... " >&6; }
10179 cat >conftest.$ac_ext <<_ACEOF
10180 /* confdefs.h.  */
10181 _ACEOF
10182 cat confdefs.h >>conftest.$ac_ext
10183 cat >>conftest.$ac_ext <<_ACEOF
10184 /* end confdefs.h.  */
10185 #include <$ac_header>
10186 _ACEOF
10187 if { (ac_try="$ac_cpp conftest.$ac_ext"
10188 case "(($ac_try" in
10189   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10190   *) ac_try_echo=$ac_try;;
10191 esac
10192 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10193 $as_echo "$ac_try_echo") >&5
10194   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10195   ac_status=$?
10196   grep -v '^ *+' conftest.er1 >conftest.err
10197   rm -f conftest.er1
10198   cat conftest.err >&5
10199   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10200   (exit $ac_status); } >/dev/null && {
10201          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10202          test ! -s conftest.err
10203        }; then
10204   ac_header_preproc=yes
10205 else
10206   $as_echo "$as_me: failed program was:" >&5
10207 sed 's/^/| /' conftest.$ac_ext >&5
10208
10209   ac_header_preproc=no
10210 fi
10211
10212 rm -f conftest.err conftest.$ac_ext
10213 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10214 $as_echo "$ac_header_preproc" >&6; }
10215
10216 # So?  What about this header?
10217 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10218   yes:no: )
10219     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10220 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10221     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10222 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10223     ac_header_preproc=yes
10224     ;;
10225   no:yes:* )
10226     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10227 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10228     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10229 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10230     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10231 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10232     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10233 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10234     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10235 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10236     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10237 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10238     ( cat <<\_ASBOX
10239 ## ---------------------------------------- ##
10240 ## Report this to pgsql-bugs@postgresql.org ##
10241 ## ---------------------------------------- ##
10242 _ASBOX
10243      ) | sed "s/^/$as_me: WARNING:     /" >&2
10244     ;;
10245 esac
10246 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10247 $as_echo_n "checking for $ac_header... " >&6; }
10248 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10249   $as_echo_n "(cached) " >&6
10250 else
10251   eval "$as_ac_Header=\$ac_header_preproc"
10252 fi
10253 ac_res=`eval 'as_val=${'$as_ac_Header'}
10254                  $as_echo "$as_val"'`
10255                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10256 $as_echo "$ac_res" >&6; }
10257
10258 fi
10259 as_val=`eval 'as_val=${'$as_ac_Header'}
10260                  $as_echo "$as_val"'`
10261    if test "x$as_val" = x""yes; then
10262   cat >>confdefs.h <<_ACEOF
10263 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10264 _ACEOF
10265
10266 else
10267
10268 for ac_header in readline.h
10269 do
10270 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10271 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10272   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10273 $as_echo_n "checking for $ac_header... " >&6; }
10274 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10275   $as_echo_n "(cached) " >&6
10276 fi
10277 ac_res=`eval 'as_val=${'$as_ac_Header'}
10278                  $as_echo "$as_val"'`
10279                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10280 $as_echo "$ac_res" >&6; }
10281 else
10282   # Is the header compilable?
10283 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10284 $as_echo_n "checking $ac_header usability... " >&6; }
10285 cat >conftest.$ac_ext <<_ACEOF
10286 /* confdefs.h.  */
10287 _ACEOF
10288 cat confdefs.h >>conftest.$ac_ext
10289 cat >>conftest.$ac_ext <<_ACEOF
10290 /* end confdefs.h.  */
10291 $ac_includes_default
10292 #include <$ac_header>
10293 _ACEOF
10294 rm -f conftest.$ac_objext
10295 if { (ac_try="$ac_compile"
10296 case "(($ac_try" in
10297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10298   *) ac_try_echo=$ac_try;;
10299 esac
10300 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10301 $as_echo "$ac_try_echo") >&5
10302   (eval "$ac_compile") 2>conftest.er1
10303   ac_status=$?
10304   grep -v '^ *+' conftest.er1 >conftest.err
10305   rm -f conftest.er1
10306   cat conftest.err >&5
10307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10308   (exit $ac_status); } && {
10309          test -z "$ac_c_werror_flag" ||
10310          test ! -s conftest.err
10311        } && test -s conftest.$ac_objext; then
10312   ac_header_compiler=yes
10313 else
10314   $as_echo "$as_me: failed program was:" >&5
10315 sed 's/^/| /' conftest.$ac_ext >&5
10316
10317         ac_header_compiler=no
10318 fi
10319
10320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10321 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10322 $as_echo "$ac_header_compiler" >&6; }
10323
10324 # Is the header present?
10325 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10326 $as_echo_n "checking $ac_header presence... " >&6; }
10327 cat >conftest.$ac_ext <<_ACEOF
10328 /* confdefs.h.  */
10329 _ACEOF
10330 cat confdefs.h >>conftest.$ac_ext
10331 cat >>conftest.$ac_ext <<_ACEOF
10332 /* end confdefs.h.  */
10333 #include <$ac_header>
10334 _ACEOF
10335 if { (ac_try="$ac_cpp conftest.$ac_ext"
10336 case "(($ac_try" in
10337   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10338   *) ac_try_echo=$ac_try;;
10339 esac
10340 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10341 $as_echo "$ac_try_echo") >&5
10342   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10343   ac_status=$?
10344   grep -v '^ *+' conftest.er1 >conftest.err
10345   rm -f conftest.er1
10346   cat conftest.err >&5
10347   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10348   (exit $ac_status); } >/dev/null && {
10349          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10350          test ! -s conftest.err
10351        }; then
10352   ac_header_preproc=yes
10353 else
10354   $as_echo "$as_me: failed program was:" >&5
10355 sed 's/^/| /' conftest.$ac_ext >&5
10356
10357   ac_header_preproc=no
10358 fi
10359
10360 rm -f conftest.err conftest.$ac_ext
10361 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10362 $as_echo "$ac_header_preproc" >&6; }
10363
10364 # So?  What about this header?
10365 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10366   yes:no: )
10367     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10368 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10369     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10370 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10371     ac_header_preproc=yes
10372     ;;
10373   no:yes:* )
10374     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10375 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10376     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10377 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10378     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10379 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10380     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10381 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10382     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10383 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10384     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10385 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10386     ( cat <<\_ASBOX
10387 ## ---------------------------------------- ##
10388 ## Report this to pgsql-bugs@postgresql.org ##
10389 ## ---------------------------------------- ##
10390 _ASBOX
10391      ) | sed "s/^/$as_me: WARNING:     /" >&2
10392     ;;
10393 esac
10394 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10395 $as_echo_n "checking for $ac_header... " >&6; }
10396 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10397   $as_echo_n "(cached) " >&6
10398 else
10399   eval "$as_ac_Header=\$ac_header_preproc"
10400 fi
10401 ac_res=`eval 'as_val=${'$as_ac_Header'}
10402                  $as_echo "$as_val"'`
10403                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10404 $as_echo "$ac_res" >&6; }
10405
10406 fi
10407 as_val=`eval 'as_val=${'$as_ac_Header'}
10408                  $as_echo "$as_val"'`
10409    if test "x$as_val" = x""yes; then
10410   cat >>confdefs.h <<_ACEOF
10411 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10412 _ACEOF
10413
10414 else
10415   { { $as_echo "$as_me:$LINENO: error: readline header not found
10416 If you have readline already installed, see config.log for details on the
10417 failure.  It is possible the compiler isn't looking in the proper directory.
10418 Use --without-readline to disable readline support." >&5
10419 $as_echo "$as_me: error: readline header not found
10420 If you have readline already installed, see config.log for details on the
10421 failure.  It is possible the compiler isn't looking in the proper directory.
10422 Use --without-readline to disable readline support." >&2;}
10423    { (exit 1); exit 1; }; }
10424 fi
10425
10426 done
10427
10428 fi
10429
10430 done
10431
10432
10433 for ac_header in readline/history.h
10434 do
10435 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10436 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10437   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10438 $as_echo_n "checking for $ac_header... " >&6; }
10439 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10440   $as_echo_n "(cached) " >&6
10441 fi
10442 ac_res=`eval 'as_val=${'$as_ac_Header'}
10443                  $as_echo "$as_val"'`
10444                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10445 $as_echo "$ac_res" >&6; }
10446 else
10447   # Is the header compilable?
10448 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10449 $as_echo_n "checking $ac_header usability... " >&6; }
10450 cat >conftest.$ac_ext <<_ACEOF
10451 /* confdefs.h.  */
10452 _ACEOF
10453 cat confdefs.h >>conftest.$ac_ext
10454 cat >>conftest.$ac_ext <<_ACEOF
10455 /* end confdefs.h.  */
10456 $ac_includes_default
10457 #include <$ac_header>
10458 _ACEOF
10459 rm -f conftest.$ac_objext
10460 if { (ac_try="$ac_compile"
10461 case "(($ac_try" in
10462   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10463   *) ac_try_echo=$ac_try;;
10464 esac
10465 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10466 $as_echo "$ac_try_echo") >&5
10467   (eval "$ac_compile") 2>conftest.er1
10468   ac_status=$?
10469   grep -v '^ *+' conftest.er1 >conftest.err
10470   rm -f conftest.er1
10471   cat conftest.err >&5
10472   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10473   (exit $ac_status); } && {
10474          test -z "$ac_c_werror_flag" ||
10475          test ! -s conftest.err
10476        } && test -s conftest.$ac_objext; then
10477   ac_header_compiler=yes
10478 else
10479   $as_echo "$as_me: failed program was:" >&5
10480 sed 's/^/| /' conftest.$ac_ext >&5
10481
10482         ac_header_compiler=no
10483 fi
10484
10485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10486 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10487 $as_echo "$ac_header_compiler" >&6; }
10488
10489 # Is the header present?
10490 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10491 $as_echo_n "checking $ac_header presence... " >&6; }
10492 cat >conftest.$ac_ext <<_ACEOF
10493 /* confdefs.h.  */
10494 _ACEOF
10495 cat confdefs.h >>conftest.$ac_ext
10496 cat >>conftest.$ac_ext <<_ACEOF
10497 /* end confdefs.h.  */
10498 #include <$ac_header>
10499 _ACEOF
10500 if { (ac_try="$ac_cpp conftest.$ac_ext"
10501 case "(($ac_try" in
10502   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10503   *) ac_try_echo=$ac_try;;
10504 esac
10505 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10506 $as_echo "$ac_try_echo") >&5
10507   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10508   ac_status=$?
10509   grep -v '^ *+' conftest.er1 >conftest.err
10510   rm -f conftest.er1
10511   cat conftest.err >&5
10512   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10513   (exit $ac_status); } >/dev/null && {
10514          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10515          test ! -s conftest.err
10516        }; then
10517   ac_header_preproc=yes
10518 else
10519   $as_echo "$as_me: failed program was:" >&5
10520 sed 's/^/| /' conftest.$ac_ext >&5
10521
10522   ac_header_preproc=no
10523 fi
10524
10525 rm -f conftest.err conftest.$ac_ext
10526 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10527 $as_echo "$ac_header_preproc" >&6; }
10528
10529 # So?  What about this header?
10530 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10531   yes:no: )
10532     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10533 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10534     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10535 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10536     ac_header_preproc=yes
10537     ;;
10538   no:yes:* )
10539     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10540 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10541     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10542 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10543     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10544 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10545     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10546 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10547     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10548 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10549     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10550 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10551     ( cat <<\_ASBOX
10552 ## ---------------------------------------- ##
10553 ## Report this to pgsql-bugs@postgresql.org ##
10554 ## ---------------------------------------- ##
10555 _ASBOX
10556      ) | sed "s/^/$as_me: WARNING:     /" >&2
10557     ;;
10558 esac
10559 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10560 $as_echo_n "checking for $ac_header... " >&6; }
10561 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10562   $as_echo_n "(cached) " >&6
10563 else
10564   eval "$as_ac_Header=\$ac_header_preproc"
10565 fi
10566 ac_res=`eval 'as_val=${'$as_ac_Header'}
10567                  $as_echo "$as_val"'`
10568                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10569 $as_echo "$ac_res" >&6; }
10570
10571 fi
10572 as_val=`eval 'as_val=${'$as_ac_Header'}
10573                  $as_echo "$as_val"'`
10574    if test "x$as_val" = x""yes; then
10575   cat >>confdefs.h <<_ACEOF
10576 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10577 _ACEOF
10578
10579 else
10580
10581 for ac_header in history.h
10582 do
10583 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10584 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10585   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10586 $as_echo_n "checking for $ac_header... " >&6; }
10587 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10588   $as_echo_n "(cached) " >&6
10589 fi
10590 ac_res=`eval 'as_val=${'$as_ac_Header'}
10591                  $as_echo "$as_val"'`
10592                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10593 $as_echo "$ac_res" >&6; }
10594 else
10595   # Is the header compilable?
10596 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10597 $as_echo_n "checking $ac_header usability... " >&6; }
10598 cat >conftest.$ac_ext <<_ACEOF
10599 /* confdefs.h.  */
10600 _ACEOF
10601 cat confdefs.h >>conftest.$ac_ext
10602 cat >>conftest.$ac_ext <<_ACEOF
10603 /* end confdefs.h.  */
10604 $ac_includes_default
10605 #include <$ac_header>
10606 _ACEOF
10607 rm -f conftest.$ac_objext
10608 if { (ac_try="$ac_compile"
10609 case "(($ac_try" in
10610   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10611   *) ac_try_echo=$ac_try;;
10612 esac
10613 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10614 $as_echo "$ac_try_echo") >&5
10615   (eval "$ac_compile") 2>conftest.er1
10616   ac_status=$?
10617   grep -v '^ *+' conftest.er1 >conftest.err
10618   rm -f conftest.er1
10619   cat conftest.err >&5
10620   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10621   (exit $ac_status); } && {
10622          test -z "$ac_c_werror_flag" ||
10623          test ! -s conftest.err
10624        } && test -s conftest.$ac_objext; then
10625   ac_header_compiler=yes
10626 else
10627   $as_echo "$as_me: failed program was:" >&5
10628 sed 's/^/| /' conftest.$ac_ext >&5
10629
10630         ac_header_compiler=no
10631 fi
10632
10633 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10634 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10635 $as_echo "$ac_header_compiler" >&6; }
10636
10637 # Is the header present?
10638 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10639 $as_echo_n "checking $ac_header presence... " >&6; }
10640 cat >conftest.$ac_ext <<_ACEOF
10641 /* confdefs.h.  */
10642 _ACEOF
10643 cat confdefs.h >>conftest.$ac_ext
10644 cat >>conftest.$ac_ext <<_ACEOF
10645 /* end confdefs.h.  */
10646 #include <$ac_header>
10647 _ACEOF
10648 if { (ac_try="$ac_cpp conftest.$ac_ext"
10649 case "(($ac_try" in
10650   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10651   *) ac_try_echo=$ac_try;;
10652 esac
10653 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10654 $as_echo "$ac_try_echo") >&5
10655   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10656   ac_status=$?
10657   grep -v '^ *+' conftest.er1 >conftest.err
10658   rm -f conftest.er1
10659   cat conftest.err >&5
10660   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10661   (exit $ac_status); } >/dev/null && {
10662          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10663          test ! -s conftest.err
10664        }; then
10665   ac_header_preproc=yes
10666 else
10667   $as_echo "$as_me: failed program was:" >&5
10668 sed 's/^/| /' conftest.$ac_ext >&5
10669
10670   ac_header_preproc=no
10671 fi
10672
10673 rm -f conftest.err conftest.$ac_ext
10674 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10675 $as_echo "$ac_header_preproc" >&6; }
10676
10677 # So?  What about this header?
10678 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10679   yes:no: )
10680     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10681 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10682     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10683 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10684     ac_header_preproc=yes
10685     ;;
10686   no:yes:* )
10687     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10688 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10689     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10690 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10691     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10692 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10693     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10694 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10695     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10696 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10697     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10698 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10699     ( cat <<\_ASBOX
10700 ## ---------------------------------------- ##
10701 ## Report this to pgsql-bugs@postgresql.org ##
10702 ## ---------------------------------------- ##
10703 _ASBOX
10704      ) | sed "s/^/$as_me: WARNING:     /" >&2
10705     ;;
10706 esac
10707 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10708 $as_echo_n "checking for $ac_header... " >&6; }
10709 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10710   $as_echo_n "(cached) " >&6
10711 else
10712   eval "$as_ac_Header=\$ac_header_preproc"
10713 fi
10714 ac_res=`eval 'as_val=${'$as_ac_Header'}
10715                  $as_echo "$as_val"'`
10716                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10717 $as_echo "$ac_res" >&6; }
10718
10719 fi
10720 as_val=`eval 'as_val=${'$as_ac_Header'}
10721                  $as_echo "$as_val"'`
10722    if test "x$as_val" = x""yes; then
10723   cat >>confdefs.h <<_ACEOF
10724 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10725 _ACEOF
10726
10727 else
10728   { { $as_echo "$as_me:$LINENO: error: history header not found
10729 If you have readline already installed, see config.log for details on the
10730 failure.  It is possible the compiler isn't looking in the proper directory.
10731 Use --without-readline to disable readline support." >&5
10732 $as_echo "$as_me: error: history header not found
10733 If you have readline already installed, see config.log for details on the
10734 failure.  It is possible the compiler isn't looking in the proper directory.
10735 Use --without-readline to disable readline support." >&2;}
10736    { (exit 1); exit 1; }; }
10737 fi
10738
10739 done
10740
10741 fi
10742
10743 done
10744
10745 fi
10746
10747 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
10748 # Some installations of libedit usurp /usr/include/readline/, which seems
10749 # bad practice, since in combined installations readline will have its headers
10750 # there.  We might have to resort to AC_EGREP checks to make sure we found
10751 # the proper header...
10752
10753 for ac_header in editline/readline.h
10754 do
10755 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10756 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10757   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10758 $as_echo_n "checking for $ac_header... " >&6; }
10759 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10760   $as_echo_n "(cached) " >&6
10761 fi
10762 ac_res=`eval 'as_val=${'$as_ac_Header'}
10763                  $as_echo "$as_val"'`
10764                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10765 $as_echo "$ac_res" >&6; }
10766 else
10767   # Is the header compilable?
10768 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10769 $as_echo_n "checking $ac_header usability... " >&6; }
10770 cat >conftest.$ac_ext <<_ACEOF
10771 /* confdefs.h.  */
10772 _ACEOF
10773 cat confdefs.h >>conftest.$ac_ext
10774 cat >>conftest.$ac_ext <<_ACEOF
10775 /* end confdefs.h.  */
10776 $ac_includes_default
10777 #include <$ac_header>
10778 _ACEOF
10779 rm -f conftest.$ac_objext
10780 if { (ac_try="$ac_compile"
10781 case "(($ac_try" in
10782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10783   *) ac_try_echo=$ac_try;;
10784 esac
10785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10786 $as_echo "$ac_try_echo") >&5
10787   (eval "$ac_compile") 2>conftest.er1
10788   ac_status=$?
10789   grep -v '^ *+' conftest.er1 >conftest.err
10790   rm -f conftest.er1
10791   cat conftest.err >&5
10792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10793   (exit $ac_status); } && {
10794          test -z "$ac_c_werror_flag" ||
10795          test ! -s conftest.err
10796        } && test -s conftest.$ac_objext; then
10797   ac_header_compiler=yes
10798 else
10799   $as_echo "$as_me: failed program was:" >&5
10800 sed 's/^/| /' conftest.$ac_ext >&5
10801
10802         ac_header_compiler=no
10803 fi
10804
10805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10806 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10807 $as_echo "$ac_header_compiler" >&6; }
10808
10809 # Is the header present?
10810 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10811 $as_echo_n "checking $ac_header presence... " >&6; }
10812 cat >conftest.$ac_ext <<_ACEOF
10813 /* confdefs.h.  */
10814 _ACEOF
10815 cat confdefs.h >>conftest.$ac_ext
10816 cat >>conftest.$ac_ext <<_ACEOF
10817 /* end confdefs.h.  */
10818 #include <$ac_header>
10819 _ACEOF
10820 if { (ac_try="$ac_cpp conftest.$ac_ext"
10821 case "(($ac_try" in
10822   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10823   *) ac_try_echo=$ac_try;;
10824 esac
10825 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10826 $as_echo "$ac_try_echo") >&5
10827   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10828   ac_status=$?
10829   grep -v '^ *+' conftest.er1 >conftest.err
10830   rm -f conftest.er1
10831   cat conftest.err >&5
10832   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10833   (exit $ac_status); } >/dev/null && {
10834          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10835          test ! -s conftest.err
10836        }; then
10837   ac_header_preproc=yes
10838 else
10839   $as_echo "$as_me: failed program was:" >&5
10840 sed 's/^/| /' conftest.$ac_ext >&5
10841
10842   ac_header_preproc=no
10843 fi
10844
10845 rm -f conftest.err conftest.$ac_ext
10846 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10847 $as_echo "$ac_header_preproc" >&6; }
10848
10849 # So?  What about this header?
10850 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10851   yes:no: )
10852     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10853 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10854     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10855 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10856     ac_header_preproc=yes
10857     ;;
10858   no:yes:* )
10859     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10860 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10861     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10862 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10863     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10864 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10865     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10866 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10867     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10868 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10869     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10870 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10871     ( cat <<\_ASBOX
10872 ## ---------------------------------------- ##
10873 ## Report this to pgsql-bugs@postgresql.org ##
10874 ## ---------------------------------------- ##
10875 _ASBOX
10876      ) | sed "s/^/$as_me: WARNING:     /" >&2
10877     ;;
10878 esac
10879 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10880 $as_echo_n "checking for $ac_header... " >&6; }
10881 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10882   $as_echo_n "(cached) " >&6
10883 else
10884   eval "$as_ac_Header=\$ac_header_preproc"
10885 fi
10886 ac_res=`eval 'as_val=${'$as_ac_Header'}
10887                  $as_echo "$as_val"'`
10888                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10889 $as_echo "$ac_res" >&6; }
10890
10891 fi
10892 as_val=`eval 'as_val=${'$as_ac_Header'}
10893                  $as_echo "$as_val"'`
10894    if test "x$as_val" = x""yes; then
10895   cat >>confdefs.h <<_ACEOF
10896 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10897 _ACEOF
10898
10899 else
10900
10901 for ac_header in readline.h
10902 do
10903 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10904 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10905   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10906 $as_echo_n "checking for $ac_header... " >&6; }
10907 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10908   $as_echo_n "(cached) " >&6
10909 fi
10910 ac_res=`eval 'as_val=${'$as_ac_Header'}
10911                  $as_echo "$as_val"'`
10912                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10913 $as_echo "$ac_res" >&6; }
10914 else
10915   # Is the header compilable?
10916 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10917 $as_echo_n "checking $ac_header usability... " >&6; }
10918 cat >conftest.$ac_ext <<_ACEOF
10919 /* confdefs.h.  */
10920 _ACEOF
10921 cat confdefs.h >>conftest.$ac_ext
10922 cat >>conftest.$ac_ext <<_ACEOF
10923 /* end confdefs.h.  */
10924 $ac_includes_default
10925 #include <$ac_header>
10926 _ACEOF
10927 rm -f conftest.$ac_objext
10928 if { (ac_try="$ac_compile"
10929 case "(($ac_try" in
10930   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10931   *) ac_try_echo=$ac_try;;
10932 esac
10933 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10934 $as_echo "$ac_try_echo") >&5
10935   (eval "$ac_compile") 2>conftest.er1
10936   ac_status=$?
10937   grep -v '^ *+' conftest.er1 >conftest.err
10938   rm -f conftest.er1
10939   cat conftest.err >&5
10940   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10941   (exit $ac_status); } && {
10942          test -z "$ac_c_werror_flag" ||
10943          test ! -s conftest.err
10944        } && test -s conftest.$ac_objext; then
10945   ac_header_compiler=yes
10946 else
10947   $as_echo "$as_me: failed program was:" >&5
10948 sed 's/^/| /' conftest.$ac_ext >&5
10949
10950         ac_header_compiler=no
10951 fi
10952
10953 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10954 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10955 $as_echo "$ac_header_compiler" >&6; }
10956
10957 # Is the header present?
10958 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10959 $as_echo_n "checking $ac_header presence... " >&6; }
10960 cat >conftest.$ac_ext <<_ACEOF
10961 /* confdefs.h.  */
10962 _ACEOF
10963 cat confdefs.h >>conftest.$ac_ext
10964 cat >>conftest.$ac_ext <<_ACEOF
10965 /* end confdefs.h.  */
10966 #include <$ac_header>
10967 _ACEOF
10968 if { (ac_try="$ac_cpp conftest.$ac_ext"
10969 case "(($ac_try" in
10970   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10971   *) ac_try_echo=$ac_try;;
10972 esac
10973 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10974 $as_echo "$ac_try_echo") >&5
10975   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10976   ac_status=$?
10977   grep -v '^ *+' conftest.er1 >conftest.err
10978   rm -f conftest.er1
10979   cat conftest.err >&5
10980   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10981   (exit $ac_status); } >/dev/null && {
10982          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10983          test ! -s conftest.err
10984        }; then
10985   ac_header_preproc=yes
10986 else
10987   $as_echo "$as_me: failed program was:" >&5
10988 sed 's/^/| /' conftest.$ac_ext >&5
10989
10990   ac_header_preproc=no
10991 fi
10992
10993 rm -f conftest.err conftest.$ac_ext
10994 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10995 $as_echo "$ac_header_preproc" >&6; }
10996
10997 # So?  What about this header?
10998 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10999   yes:no: )
11000     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11001 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11002     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11003 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11004     ac_header_preproc=yes
11005     ;;
11006   no:yes:* )
11007     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11008 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11009     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11010 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11011     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11012 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11013     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11014 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11015     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11016 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11017     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11018 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11019     ( cat <<\_ASBOX
11020 ## ---------------------------------------- ##
11021 ## Report this to pgsql-bugs@postgresql.org ##
11022 ## ---------------------------------------- ##
11023 _ASBOX
11024      ) | sed "s/^/$as_me: WARNING:     /" >&2
11025     ;;
11026 esac
11027 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11028 $as_echo_n "checking for $ac_header... " >&6; }
11029 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11030   $as_echo_n "(cached) " >&6
11031 else
11032   eval "$as_ac_Header=\$ac_header_preproc"
11033 fi
11034 ac_res=`eval 'as_val=${'$as_ac_Header'}
11035                  $as_echo "$as_val"'`
11036                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11037 $as_echo "$ac_res" >&6; }
11038
11039 fi
11040 as_val=`eval 'as_val=${'$as_ac_Header'}
11041                  $as_echo "$as_val"'`
11042    if test "x$as_val" = x""yes; then
11043   cat >>confdefs.h <<_ACEOF
11044 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11045 _ACEOF
11046
11047 else
11048
11049 for ac_header in readline/readline.h
11050 do
11051 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11052 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11053   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11054 $as_echo_n "checking for $ac_header... " >&6; }
11055 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11056   $as_echo_n "(cached) " >&6
11057 fi
11058 ac_res=`eval 'as_val=${'$as_ac_Header'}
11059                  $as_echo "$as_val"'`
11060                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11061 $as_echo "$ac_res" >&6; }
11062 else
11063   # Is the header compilable?
11064 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11065 $as_echo_n "checking $ac_header usability... " >&6; }
11066 cat >conftest.$ac_ext <<_ACEOF
11067 /* confdefs.h.  */
11068 _ACEOF
11069 cat confdefs.h >>conftest.$ac_ext
11070 cat >>conftest.$ac_ext <<_ACEOF
11071 /* end confdefs.h.  */
11072 $ac_includes_default
11073 #include <$ac_header>
11074 _ACEOF
11075 rm -f conftest.$ac_objext
11076 if { (ac_try="$ac_compile"
11077 case "(($ac_try" in
11078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11079   *) ac_try_echo=$ac_try;;
11080 esac
11081 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11082 $as_echo "$ac_try_echo") >&5
11083   (eval "$ac_compile") 2>conftest.er1
11084   ac_status=$?
11085   grep -v '^ *+' conftest.er1 >conftest.err
11086   rm -f conftest.er1
11087   cat conftest.err >&5
11088   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11089   (exit $ac_status); } && {
11090          test -z "$ac_c_werror_flag" ||
11091          test ! -s conftest.err
11092        } && test -s conftest.$ac_objext; then
11093   ac_header_compiler=yes
11094 else
11095   $as_echo "$as_me: failed program was:" >&5
11096 sed 's/^/| /' conftest.$ac_ext >&5
11097
11098         ac_header_compiler=no
11099 fi
11100
11101 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11102 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11103 $as_echo "$ac_header_compiler" >&6; }
11104
11105 # Is the header present?
11106 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11107 $as_echo_n "checking $ac_header presence... " >&6; }
11108 cat >conftest.$ac_ext <<_ACEOF
11109 /* confdefs.h.  */
11110 _ACEOF
11111 cat confdefs.h >>conftest.$ac_ext
11112 cat >>conftest.$ac_ext <<_ACEOF
11113 /* end confdefs.h.  */
11114 #include <$ac_header>
11115 _ACEOF
11116 if { (ac_try="$ac_cpp conftest.$ac_ext"
11117 case "(($ac_try" in
11118   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11119   *) ac_try_echo=$ac_try;;
11120 esac
11121 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11122 $as_echo "$ac_try_echo") >&5
11123   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11124   ac_status=$?
11125   grep -v '^ *+' conftest.er1 >conftest.err
11126   rm -f conftest.er1
11127   cat conftest.err >&5
11128   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11129   (exit $ac_status); } >/dev/null && {
11130          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11131          test ! -s conftest.err
11132        }; then
11133   ac_header_preproc=yes
11134 else
11135   $as_echo "$as_me: failed program was:" >&5
11136 sed 's/^/| /' conftest.$ac_ext >&5
11137
11138   ac_header_preproc=no
11139 fi
11140
11141 rm -f conftest.err conftest.$ac_ext
11142 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11143 $as_echo "$ac_header_preproc" >&6; }
11144
11145 # So?  What about this header?
11146 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11147   yes:no: )
11148     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11149 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11150     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11151 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11152     ac_header_preproc=yes
11153     ;;
11154   no:yes:* )
11155     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11156 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11157     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11158 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11159     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11160 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11161     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11162 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11163     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11164 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11165     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11166 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11167     ( cat <<\_ASBOX
11168 ## ---------------------------------------- ##
11169 ## Report this to pgsql-bugs@postgresql.org ##
11170 ## ---------------------------------------- ##
11171 _ASBOX
11172      ) | sed "s/^/$as_me: WARNING:     /" >&2
11173     ;;
11174 esac
11175 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11176 $as_echo_n "checking for $ac_header... " >&6; }
11177 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11178   $as_echo_n "(cached) " >&6
11179 else
11180   eval "$as_ac_Header=\$ac_header_preproc"
11181 fi
11182 ac_res=`eval 'as_val=${'$as_ac_Header'}
11183                  $as_echo "$as_val"'`
11184                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11185 $as_echo "$ac_res" >&6; }
11186
11187 fi
11188 as_val=`eval 'as_val=${'$as_ac_Header'}
11189                  $as_echo "$as_val"'`
11190    if test "x$as_val" = x""yes; then
11191   cat >>confdefs.h <<_ACEOF
11192 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11193 _ACEOF
11194
11195 else
11196   { { $as_echo "$as_me:$LINENO: error: readline header not found
11197 If you have libedit already installed, see config.log for details on the
11198 failure.  It is possible the compiler isn't looking in the proper directory.
11199 Use --without-readline to disable libedit support." >&5
11200 $as_echo "$as_me: error: readline header not found
11201 If you have libedit already installed, see config.log for details on the
11202 failure.  It is possible the compiler isn't looking in the proper directory.
11203 Use --without-readline to disable libedit support." >&2;}
11204    { (exit 1); exit 1; }; }
11205 fi
11206
11207 done
11208
11209 fi
11210
11211 done
11212
11213 fi
11214
11215 done
11216
11217 # Note: in a libedit installation, history.h is sometimes a dummy, and may
11218 # not be there at all.  Hence, don't complain if not found.  We must check
11219 # though, since in yet other versions it is an independent header.
11220
11221 for ac_header in editline/history.h
11222 do
11223 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11224 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11225   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11226 $as_echo_n "checking for $ac_header... " >&6; }
11227 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11228   $as_echo_n "(cached) " >&6
11229 fi
11230 ac_res=`eval 'as_val=${'$as_ac_Header'}
11231                  $as_echo "$as_val"'`
11232                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11233 $as_echo "$ac_res" >&6; }
11234 else
11235   # Is the header compilable?
11236 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11237 $as_echo_n "checking $ac_header usability... " >&6; }
11238 cat >conftest.$ac_ext <<_ACEOF
11239 /* confdefs.h.  */
11240 _ACEOF
11241 cat confdefs.h >>conftest.$ac_ext
11242 cat >>conftest.$ac_ext <<_ACEOF
11243 /* end confdefs.h.  */
11244 $ac_includes_default
11245 #include <$ac_header>
11246 _ACEOF
11247 rm -f conftest.$ac_objext
11248 if { (ac_try="$ac_compile"
11249 case "(($ac_try" in
11250   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11251   *) ac_try_echo=$ac_try;;
11252 esac
11253 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11254 $as_echo "$ac_try_echo") >&5
11255   (eval "$ac_compile") 2>conftest.er1
11256   ac_status=$?
11257   grep -v '^ *+' conftest.er1 >conftest.err
11258   rm -f conftest.er1
11259   cat conftest.err >&5
11260   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11261   (exit $ac_status); } && {
11262          test -z "$ac_c_werror_flag" ||
11263          test ! -s conftest.err
11264        } && test -s conftest.$ac_objext; then
11265   ac_header_compiler=yes
11266 else
11267   $as_echo "$as_me: failed program was:" >&5
11268 sed 's/^/| /' conftest.$ac_ext >&5
11269
11270         ac_header_compiler=no
11271 fi
11272
11273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11274 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11275 $as_echo "$ac_header_compiler" >&6; }
11276
11277 # Is the header present?
11278 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11279 $as_echo_n "checking $ac_header presence... " >&6; }
11280 cat >conftest.$ac_ext <<_ACEOF
11281 /* confdefs.h.  */
11282 _ACEOF
11283 cat confdefs.h >>conftest.$ac_ext
11284 cat >>conftest.$ac_ext <<_ACEOF
11285 /* end confdefs.h.  */
11286 #include <$ac_header>
11287 _ACEOF
11288 if { (ac_try="$ac_cpp conftest.$ac_ext"
11289 case "(($ac_try" in
11290   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11291   *) ac_try_echo=$ac_try;;
11292 esac
11293 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11294 $as_echo "$ac_try_echo") >&5
11295   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11296   ac_status=$?
11297   grep -v '^ *+' conftest.er1 >conftest.err
11298   rm -f conftest.er1
11299   cat conftest.err >&5
11300   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11301   (exit $ac_status); } >/dev/null && {
11302          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11303          test ! -s conftest.err
11304        }; then
11305   ac_header_preproc=yes
11306 else
11307   $as_echo "$as_me: failed program was:" >&5
11308 sed 's/^/| /' conftest.$ac_ext >&5
11309
11310   ac_header_preproc=no
11311 fi
11312
11313 rm -f conftest.err conftest.$ac_ext
11314 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11315 $as_echo "$ac_header_preproc" >&6; }
11316
11317 # So?  What about this header?
11318 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11319   yes:no: )
11320     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11321 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11322     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11323 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11324     ac_header_preproc=yes
11325     ;;
11326   no:yes:* )
11327     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11328 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11329     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11330 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11331     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11332 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11333     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11334 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11335     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11336 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11337     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11338 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11339     ( cat <<\_ASBOX
11340 ## ---------------------------------------- ##
11341 ## Report this to pgsql-bugs@postgresql.org ##
11342 ## ---------------------------------------- ##
11343 _ASBOX
11344      ) | sed "s/^/$as_me: WARNING:     /" >&2
11345     ;;
11346 esac
11347 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11348 $as_echo_n "checking for $ac_header... " >&6; }
11349 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11350   $as_echo_n "(cached) " >&6
11351 else
11352   eval "$as_ac_Header=\$ac_header_preproc"
11353 fi
11354 ac_res=`eval 'as_val=${'$as_ac_Header'}
11355                  $as_echo "$as_val"'`
11356                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11357 $as_echo "$ac_res" >&6; }
11358
11359 fi
11360 as_val=`eval 'as_val=${'$as_ac_Header'}
11361                  $as_echo "$as_val"'`
11362    if test "x$as_val" = x""yes; then
11363   cat >>confdefs.h <<_ACEOF
11364 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11365 _ACEOF
11366
11367 else
11368
11369 for ac_header in history.h
11370 do
11371 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11372 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11373   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11374 $as_echo_n "checking for $ac_header... " >&6; }
11375 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11376   $as_echo_n "(cached) " >&6
11377 fi
11378 ac_res=`eval 'as_val=${'$as_ac_Header'}
11379                  $as_echo "$as_val"'`
11380                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11381 $as_echo "$ac_res" >&6; }
11382 else
11383   # Is the header compilable?
11384 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11385 $as_echo_n "checking $ac_header usability... " >&6; }
11386 cat >conftest.$ac_ext <<_ACEOF
11387 /* confdefs.h.  */
11388 _ACEOF
11389 cat confdefs.h >>conftest.$ac_ext
11390 cat >>conftest.$ac_ext <<_ACEOF
11391 /* end confdefs.h.  */
11392 $ac_includes_default
11393 #include <$ac_header>
11394 _ACEOF
11395 rm -f conftest.$ac_objext
11396 if { (ac_try="$ac_compile"
11397 case "(($ac_try" in
11398   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11399   *) ac_try_echo=$ac_try;;
11400 esac
11401 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11402 $as_echo "$ac_try_echo") >&5
11403   (eval "$ac_compile") 2>conftest.er1
11404   ac_status=$?
11405   grep -v '^ *+' conftest.er1 >conftest.err
11406   rm -f conftest.er1
11407   cat conftest.err >&5
11408   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11409   (exit $ac_status); } && {
11410          test -z "$ac_c_werror_flag" ||
11411          test ! -s conftest.err
11412        } && test -s conftest.$ac_objext; then
11413   ac_header_compiler=yes
11414 else
11415   $as_echo "$as_me: failed program was:" >&5
11416 sed 's/^/| /' conftest.$ac_ext >&5
11417
11418         ac_header_compiler=no
11419 fi
11420
11421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11422 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11423 $as_echo "$ac_header_compiler" >&6; }
11424
11425 # Is the header present?
11426 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11427 $as_echo_n "checking $ac_header presence... " >&6; }
11428 cat >conftest.$ac_ext <<_ACEOF
11429 /* confdefs.h.  */
11430 _ACEOF
11431 cat confdefs.h >>conftest.$ac_ext
11432 cat >>conftest.$ac_ext <<_ACEOF
11433 /* end confdefs.h.  */
11434 #include <$ac_header>
11435 _ACEOF
11436 if { (ac_try="$ac_cpp conftest.$ac_ext"
11437 case "(($ac_try" in
11438   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11439   *) ac_try_echo=$ac_try;;
11440 esac
11441 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11442 $as_echo "$ac_try_echo") >&5
11443   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11444   ac_status=$?
11445   grep -v '^ *+' conftest.er1 >conftest.err
11446   rm -f conftest.er1
11447   cat conftest.err >&5
11448   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11449   (exit $ac_status); } >/dev/null && {
11450          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11451          test ! -s conftest.err
11452        }; then
11453   ac_header_preproc=yes
11454 else
11455   $as_echo "$as_me: failed program was:" >&5
11456 sed 's/^/| /' conftest.$ac_ext >&5
11457
11458   ac_header_preproc=no
11459 fi
11460
11461 rm -f conftest.err conftest.$ac_ext
11462 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11463 $as_echo "$ac_header_preproc" >&6; }
11464
11465 # So?  What about this header?
11466 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11467   yes:no: )
11468     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11469 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11470     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11471 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11472     ac_header_preproc=yes
11473     ;;
11474   no:yes:* )
11475     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11476 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11477     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11478 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11479     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11480 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11481     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11482 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11483     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11484 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11485     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11486 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11487     ( cat <<\_ASBOX
11488 ## ---------------------------------------- ##
11489 ## Report this to pgsql-bugs@postgresql.org ##
11490 ## ---------------------------------------- ##
11491 _ASBOX
11492      ) | sed "s/^/$as_me: WARNING:     /" >&2
11493     ;;
11494 esac
11495 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11496 $as_echo_n "checking for $ac_header... " >&6; }
11497 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11498   $as_echo_n "(cached) " >&6
11499 else
11500   eval "$as_ac_Header=\$ac_header_preproc"
11501 fi
11502 ac_res=`eval 'as_val=${'$as_ac_Header'}
11503                  $as_echo "$as_val"'`
11504                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11505 $as_echo "$ac_res" >&6; }
11506
11507 fi
11508 as_val=`eval 'as_val=${'$as_ac_Header'}
11509                  $as_echo "$as_val"'`
11510    if test "x$as_val" = x""yes; then
11511   cat >>confdefs.h <<_ACEOF
11512 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11513 _ACEOF
11514
11515 else
11516
11517 for ac_header in readline/history.h
11518 do
11519 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11520 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11521   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11522 $as_echo_n "checking for $ac_header... " >&6; }
11523 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11524   $as_echo_n "(cached) " >&6
11525 fi
11526 ac_res=`eval 'as_val=${'$as_ac_Header'}
11527                  $as_echo "$as_val"'`
11528                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11529 $as_echo "$ac_res" >&6; }
11530 else
11531   # Is the header compilable?
11532 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11533 $as_echo_n "checking $ac_header usability... " >&6; }
11534 cat >conftest.$ac_ext <<_ACEOF
11535 /* confdefs.h.  */
11536 _ACEOF
11537 cat confdefs.h >>conftest.$ac_ext
11538 cat >>conftest.$ac_ext <<_ACEOF
11539 /* end confdefs.h.  */
11540 $ac_includes_default
11541 #include <$ac_header>
11542 _ACEOF
11543 rm -f conftest.$ac_objext
11544 if { (ac_try="$ac_compile"
11545 case "(($ac_try" in
11546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11547   *) ac_try_echo=$ac_try;;
11548 esac
11549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11550 $as_echo "$ac_try_echo") >&5
11551   (eval "$ac_compile") 2>conftest.er1
11552   ac_status=$?
11553   grep -v '^ *+' conftest.er1 >conftest.err
11554   rm -f conftest.er1
11555   cat conftest.err >&5
11556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11557   (exit $ac_status); } && {
11558          test -z "$ac_c_werror_flag" ||
11559          test ! -s conftest.err
11560        } && test -s conftest.$ac_objext; then
11561   ac_header_compiler=yes
11562 else
11563   $as_echo "$as_me: failed program was:" >&5
11564 sed 's/^/| /' conftest.$ac_ext >&5
11565
11566         ac_header_compiler=no
11567 fi
11568
11569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11570 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11571 $as_echo "$ac_header_compiler" >&6; }
11572
11573 # Is the header present?
11574 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11575 $as_echo_n "checking $ac_header presence... " >&6; }
11576 cat >conftest.$ac_ext <<_ACEOF
11577 /* confdefs.h.  */
11578 _ACEOF
11579 cat confdefs.h >>conftest.$ac_ext
11580 cat >>conftest.$ac_ext <<_ACEOF
11581 /* end confdefs.h.  */
11582 #include <$ac_header>
11583 _ACEOF
11584 if { (ac_try="$ac_cpp conftest.$ac_ext"
11585 case "(($ac_try" in
11586   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11587   *) ac_try_echo=$ac_try;;
11588 esac
11589 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11590 $as_echo "$ac_try_echo") >&5
11591   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11592   ac_status=$?
11593   grep -v '^ *+' conftest.er1 >conftest.err
11594   rm -f conftest.er1
11595   cat conftest.err >&5
11596   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11597   (exit $ac_status); } >/dev/null && {
11598          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11599          test ! -s conftest.err
11600        }; then
11601   ac_header_preproc=yes
11602 else
11603   $as_echo "$as_me: failed program was:" >&5
11604 sed 's/^/| /' conftest.$ac_ext >&5
11605
11606   ac_header_preproc=no
11607 fi
11608
11609 rm -f conftest.err conftest.$ac_ext
11610 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11611 $as_echo "$ac_header_preproc" >&6; }
11612
11613 # So?  What about this header?
11614 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11615   yes:no: )
11616     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11617 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11618     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11619 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11620     ac_header_preproc=yes
11621     ;;
11622   no:yes:* )
11623     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11624 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11625     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11626 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11627     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11628 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11629     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11630 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11631     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11632 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11633     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11634 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11635     ( cat <<\_ASBOX
11636 ## ---------------------------------------- ##
11637 ## Report this to pgsql-bugs@postgresql.org ##
11638 ## ---------------------------------------- ##
11639 _ASBOX
11640      ) | sed "s/^/$as_me: WARNING:     /" >&2
11641     ;;
11642 esac
11643 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11644 $as_echo_n "checking for $ac_header... " >&6; }
11645 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11646   $as_echo_n "(cached) " >&6
11647 else
11648   eval "$as_ac_Header=\$ac_header_preproc"
11649 fi
11650 ac_res=`eval 'as_val=${'$as_ac_Header'}
11651                  $as_echo "$as_val"'`
11652                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11653 $as_echo "$ac_res" >&6; }
11654
11655 fi
11656 as_val=`eval 'as_val=${'$as_ac_Header'}
11657                  $as_echo "$as_val"'`
11658    if test "x$as_val" = x""yes; then
11659   cat >>confdefs.h <<_ACEOF
11660 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11661 _ACEOF
11662
11663 fi
11664
11665 done
11666
11667 fi
11668
11669 done
11670
11671 fi
11672
11673 done
11674
11675 fi
11676
11677 if test "$with_zlib" = yes; then
11678   if test "${ac_cv_header_zlib_h+set}" = set; then
11679   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11680 $as_echo_n "checking for zlib.h... " >&6; }
11681 if test "${ac_cv_header_zlib_h+set}" = set; then
11682   $as_echo_n "(cached) " >&6
11683 fi
11684 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11685 $as_echo "$ac_cv_header_zlib_h" >&6; }
11686 else
11687   # Is the header compilable?
11688 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
11689 $as_echo_n "checking zlib.h usability... " >&6; }
11690 cat >conftest.$ac_ext <<_ACEOF
11691 /* confdefs.h.  */
11692 _ACEOF
11693 cat confdefs.h >>conftest.$ac_ext
11694 cat >>conftest.$ac_ext <<_ACEOF
11695 /* end confdefs.h.  */
11696 $ac_includes_default
11697 #include <zlib.h>
11698 _ACEOF
11699 rm -f conftest.$ac_objext
11700 if { (ac_try="$ac_compile"
11701 case "(($ac_try" in
11702   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11703   *) ac_try_echo=$ac_try;;
11704 esac
11705 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11706 $as_echo "$ac_try_echo") >&5
11707   (eval "$ac_compile") 2>conftest.er1
11708   ac_status=$?
11709   grep -v '^ *+' conftest.er1 >conftest.err
11710   rm -f conftest.er1
11711   cat conftest.err >&5
11712   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11713   (exit $ac_status); } && {
11714          test -z "$ac_c_werror_flag" ||
11715          test ! -s conftest.err
11716        } && test -s conftest.$ac_objext; then
11717   ac_header_compiler=yes
11718 else
11719   $as_echo "$as_me: failed program was:" >&5
11720 sed 's/^/| /' conftest.$ac_ext >&5
11721
11722         ac_header_compiler=no
11723 fi
11724
11725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11726 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11727 $as_echo "$ac_header_compiler" >&6; }
11728
11729 # Is the header present?
11730 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
11731 $as_echo_n "checking zlib.h presence... " >&6; }
11732 cat >conftest.$ac_ext <<_ACEOF
11733 /* confdefs.h.  */
11734 _ACEOF
11735 cat confdefs.h >>conftest.$ac_ext
11736 cat >>conftest.$ac_ext <<_ACEOF
11737 /* end confdefs.h.  */
11738 #include <zlib.h>
11739 _ACEOF
11740 if { (ac_try="$ac_cpp conftest.$ac_ext"
11741 case "(($ac_try" in
11742   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11743   *) ac_try_echo=$ac_try;;
11744 esac
11745 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11746 $as_echo "$ac_try_echo") >&5
11747   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11748   ac_status=$?
11749   grep -v '^ *+' conftest.er1 >conftest.err
11750   rm -f conftest.er1
11751   cat conftest.err >&5
11752   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11753   (exit $ac_status); } >/dev/null && {
11754          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11755          test ! -s conftest.err
11756        }; then
11757   ac_header_preproc=yes
11758 else
11759   $as_echo "$as_me: failed program was:" >&5
11760 sed 's/^/| /' conftest.$ac_ext >&5
11761
11762   ac_header_preproc=no
11763 fi
11764
11765 rm -f conftest.err conftest.$ac_ext
11766 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11767 $as_echo "$ac_header_preproc" >&6; }
11768
11769 # So?  What about this header?
11770 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11771   yes:no: )
11772     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11773 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11774     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
11775 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
11776     ac_header_preproc=yes
11777     ;;
11778   no:yes:* )
11779     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
11780 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
11781     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
11782 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
11783     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
11784 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
11785     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
11786 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11787     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
11788 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
11789     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
11790 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
11791     ( cat <<\_ASBOX
11792 ## ---------------------------------------- ##
11793 ## Report this to pgsql-bugs@postgresql.org ##
11794 ## ---------------------------------------- ##
11795 _ASBOX
11796      ) | sed "s/^/$as_me: WARNING:     /" >&2
11797     ;;
11798 esac
11799 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11800 $as_echo_n "checking for zlib.h... " >&6; }
11801 if test "${ac_cv_header_zlib_h+set}" = set; then
11802   $as_echo_n "(cached) " >&6
11803 else
11804   ac_cv_header_zlib_h=$ac_header_preproc
11805 fi
11806 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11807 $as_echo "$ac_cv_header_zlib_h" >&6; }
11808
11809 fi
11810 if test "x$ac_cv_header_zlib_h" = x""yes; then
11811   :
11812 else
11813   { { $as_echo "$as_me:$LINENO: error: zlib header not found
11814 If you have zlib already installed, see config.log for details on the
11815 failure.  It is possible the compiler isn't looking in the proper directory.
11816 Use --without-zlib to disable zlib support." >&5
11817 $as_echo "$as_me: error: zlib header not found
11818 If you have zlib already installed, see config.log for details on the
11819 failure.  It is possible the compiler isn't looking in the proper directory.
11820 Use --without-zlib to disable zlib support." >&2;}
11821    { (exit 1); exit 1; }; }
11822 fi
11823
11824
11825 fi
11826
11827 if test "$with_gssapi" = yes ; then
11828
11829 for ac_header in gssapi/gssapi.h
11830 do
11831 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11832 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11833   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11834 $as_echo_n "checking for $ac_header... " >&6; }
11835 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11836   $as_echo_n "(cached) " >&6
11837 fi
11838 ac_res=`eval 'as_val=${'$as_ac_Header'}
11839                  $as_echo "$as_val"'`
11840                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11841 $as_echo "$ac_res" >&6; }
11842 else
11843   # Is the header compilable?
11844 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11845 $as_echo_n "checking $ac_header usability... " >&6; }
11846 cat >conftest.$ac_ext <<_ACEOF
11847 /* confdefs.h.  */
11848 _ACEOF
11849 cat confdefs.h >>conftest.$ac_ext
11850 cat >>conftest.$ac_ext <<_ACEOF
11851 /* end confdefs.h.  */
11852 $ac_includes_default
11853 #include <$ac_header>
11854 _ACEOF
11855 rm -f conftest.$ac_objext
11856 if { (ac_try="$ac_compile"
11857 case "(($ac_try" in
11858   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11859   *) ac_try_echo=$ac_try;;
11860 esac
11861 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11862 $as_echo "$ac_try_echo") >&5
11863   (eval "$ac_compile") 2>conftest.er1
11864   ac_status=$?
11865   grep -v '^ *+' conftest.er1 >conftest.err
11866   rm -f conftest.er1
11867   cat conftest.err >&5
11868   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11869   (exit $ac_status); } && {
11870          test -z "$ac_c_werror_flag" ||
11871          test ! -s conftest.err
11872        } && test -s conftest.$ac_objext; then
11873   ac_header_compiler=yes
11874 else
11875   $as_echo "$as_me: failed program was:" >&5
11876 sed 's/^/| /' conftest.$ac_ext >&5
11877
11878         ac_header_compiler=no
11879 fi
11880
11881 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11882 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11883 $as_echo "$ac_header_compiler" >&6; }
11884
11885 # Is the header present?
11886 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11887 $as_echo_n "checking $ac_header presence... " >&6; }
11888 cat >conftest.$ac_ext <<_ACEOF
11889 /* confdefs.h.  */
11890 _ACEOF
11891 cat confdefs.h >>conftest.$ac_ext
11892 cat >>conftest.$ac_ext <<_ACEOF
11893 /* end confdefs.h.  */
11894 #include <$ac_header>
11895 _ACEOF
11896 if { (ac_try="$ac_cpp conftest.$ac_ext"
11897 case "(($ac_try" in
11898   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11899   *) ac_try_echo=$ac_try;;
11900 esac
11901 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11902 $as_echo "$ac_try_echo") >&5
11903   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11904   ac_status=$?
11905   grep -v '^ *+' conftest.er1 >conftest.err
11906   rm -f conftest.er1
11907   cat conftest.err >&5
11908   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11909   (exit $ac_status); } >/dev/null && {
11910          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11911          test ! -s conftest.err
11912        }; then
11913   ac_header_preproc=yes
11914 else
11915   $as_echo "$as_me: failed program was:" >&5
11916 sed 's/^/| /' conftest.$ac_ext >&5
11917
11918   ac_header_preproc=no
11919 fi
11920
11921 rm -f conftest.err conftest.$ac_ext
11922 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11923 $as_echo "$ac_header_preproc" >&6; }
11924
11925 # So?  What about this header?
11926 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11927   yes:no: )
11928     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11929 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11930     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11931 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11932     ac_header_preproc=yes
11933     ;;
11934   no:yes:* )
11935     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11936 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11937     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11938 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11939     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11940 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11941     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11942 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11943     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11944 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11945     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11946 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11947     ( cat <<\_ASBOX
11948 ## ---------------------------------------- ##
11949 ## Report this to pgsql-bugs@postgresql.org ##
11950 ## ---------------------------------------- ##
11951 _ASBOX
11952      ) | sed "s/^/$as_me: WARNING:     /" >&2
11953     ;;
11954 esac
11955 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11956 $as_echo_n "checking for $ac_header... " >&6; }
11957 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11958   $as_echo_n "(cached) " >&6
11959 else
11960   eval "$as_ac_Header=\$ac_header_preproc"
11961 fi
11962 ac_res=`eval 'as_val=${'$as_ac_Header'}
11963                  $as_echo "$as_val"'`
11964                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11965 $as_echo "$ac_res" >&6; }
11966
11967 fi
11968 as_val=`eval 'as_val=${'$as_ac_Header'}
11969                  $as_echo "$as_val"'`
11970    if test "x$as_val" = x""yes; then
11971   cat >>confdefs.h <<_ACEOF
11972 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11973 _ACEOF
11974
11975 else
11976
11977 for ac_header in gssapi.h
11978 do
11979 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11980 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11981   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11982 $as_echo_n "checking for $ac_header... " >&6; }
11983 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11984   $as_echo_n "(cached) " >&6
11985 fi
11986 ac_res=`eval 'as_val=${'$as_ac_Header'}
11987                  $as_echo "$as_val"'`
11988                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11989 $as_echo "$ac_res" >&6; }
11990 else
11991   # Is the header compilable?
11992 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11993 $as_echo_n "checking $ac_header usability... " >&6; }
11994 cat >conftest.$ac_ext <<_ACEOF
11995 /* confdefs.h.  */
11996 _ACEOF
11997 cat confdefs.h >>conftest.$ac_ext
11998 cat >>conftest.$ac_ext <<_ACEOF
11999 /* end confdefs.h.  */
12000 $ac_includes_default
12001 #include <$ac_header>
12002 _ACEOF
12003 rm -f conftest.$ac_objext
12004 if { (ac_try="$ac_compile"
12005 case "(($ac_try" in
12006   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12007   *) ac_try_echo=$ac_try;;
12008 esac
12009 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12010 $as_echo "$ac_try_echo") >&5
12011   (eval "$ac_compile") 2>conftest.er1
12012   ac_status=$?
12013   grep -v '^ *+' conftest.er1 >conftest.err
12014   rm -f conftest.er1
12015   cat conftest.err >&5
12016   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12017   (exit $ac_status); } && {
12018          test -z "$ac_c_werror_flag" ||
12019          test ! -s conftest.err
12020        } && test -s conftest.$ac_objext; then
12021   ac_header_compiler=yes
12022 else
12023   $as_echo "$as_me: failed program was:" >&5
12024 sed 's/^/| /' conftest.$ac_ext >&5
12025
12026         ac_header_compiler=no
12027 fi
12028
12029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12030 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12031 $as_echo "$ac_header_compiler" >&6; }
12032
12033 # Is the header present?
12034 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12035 $as_echo_n "checking $ac_header presence... " >&6; }
12036 cat >conftest.$ac_ext <<_ACEOF
12037 /* confdefs.h.  */
12038 _ACEOF
12039 cat confdefs.h >>conftest.$ac_ext
12040 cat >>conftest.$ac_ext <<_ACEOF
12041 /* end confdefs.h.  */
12042 #include <$ac_header>
12043 _ACEOF
12044 if { (ac_try="$ac_cpp conftest.$ac_ext"
12045 case "(($ac_try" in
12046   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12047   *) ac_try_echo=$ac_try;;
12048 esac
12049 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12050 $as_echo "$ac_try_echo") >&5
12051   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12052   ac_status=$?
12053   grep -v '^ *+' conftest.er1 >conftest.err
12054   rm -f conftest.er1
12055   cat conftest.err >&5
12056   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12057   (exit $ac_status); } >/dev/null && {
12058          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12059          test ! -s conftest.err
12060        }; then
12061   ac_header_preproc=yes
12062 else
12063   $as_echo "$as_me: failed program was:" >&5
12064 sed 's/^/| /' conftest.$ac_ext >&5
12065
12066   ac_header_preproc=no
12067 fi
12068
12069 rm -f conftest.err conftest.$ac_ext
12070 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12071 $as_echo "$ac_header_preproc" >&6; }
12072
12073 # So?  What about this header?
12074 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12075   yes:no: )
12076     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12077 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12078     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12079 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12080     ac_header_preproc=yes
12081     ;;
12082   no:yes:* )
12083     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12084 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12085     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12086 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12087     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12088 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12089     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12090 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12091     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12092 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12093     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12094 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12095     ( cat <<\_ASBOX
12096 ## ---------------------------------------- ##
12097 ## Report this to pgsql-bugs@postgresql.org ##
12098 ## ---------------------------------------- ##
12099 _ASBOX
12100      ) | sed "s/^/$as_me: WARNING:     /" >&2
12101     ;;
12102 esac
12103 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12104 $as_echo_n "checking for $ac_header... " >&6; }
12105 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12106   $as_echo_n "(cached) " >&6
12107 else
12108   eval "$as_ac_Header=\$ac_header_preproc"
12109 fi
12110 ac_res=`eval 'as_val=${'$as_ac_Header'}
12111                  $as_echo "$as_val"'`
12112                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12113 $as_echo "$ac_res" >&6; }
12114
12115 fi
12116 as_val=`eval 'as_val=${'$as_ac_Header'}
12117                  $as_echo "$as_val"'`
12118    if test "x$as_val" = x""yes; then
12119   cat >>confdefs.h <<_ACEOF
12120 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12121 _ACEOF
12122
12123 else
12124   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
12125 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
12126    { (exit 1); exit 1; }; }
12127 fi
12128
12129 done
12130
12131 fi
12132
12133 done
12134
12135 fi
12136
12137 if test "$with_krb5" = yes ; then
12138   if test "${ac_cv_header_krb5_h+set}" = set; then
12139   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12140 $as_echo_n "checking for krb5.h... " >&6; }
12141 if test "${ac_cv_header_krb5_h+set}" = set; then
12142   $as_echo_n "(cached) " >&6
12143 fi
12144 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12145 $as_echo "$ac_cv_header_krb5_h" >&6; }
12146 else
12147   # Is the header compilable?
12148 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
12149 $as_echo_n "checking krb5.h usability... " >&6; }
12150 cat >conftest.$ac_ext <<_ACEOF
12151 /* confdefs.h.  */
12152 _ACEOF
12153 cat confdefs.h >>conftest.$ac_ext
12154 cat >>conftest.$ac_ext <<_ACEOF
12155 /* end confdefs.h.  */
12156 $ac_includes_default
12157 #include <krb5.h>
12158 _ACEOF
12159 rm -f conftest.$ac_objext
12160 if { (ac_try="$ac_compile"
12161 case "(($ac_try" in
12162   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12163   *) ac_try_echo=$ac_try;;
12164 esac
12165 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12166 $as_echo "$ac_try_echo") >&5
12167   (eval "$ac_compile") 2>conftest.er1
12168   ac_status=$?
12169   grep -v '^ *+' conftest.er1 >conftest.err
12170   rm -f conftest.er1
12171   cat conftest.err >&5
12172   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12173   (exit $ac_status); } && {
12174          test -z "$ac_c_werror_flag" ||
12175          test ! -s conftest.err
12176        } && test -s conftest.$ac_objext; then
12177   ac_header_compiler=yes
12178 else
12179   $as_echo "$as_me: failed program was:" >&5
12180 sed 's/^/| /' conftest.$ac_ext >&5
12181
12182         ac_header_compiler=no
12183 fi
12184
12185 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12186 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12187 $as_echo "$ac_header_compiler" >&6; }
12188
12189 # Is the header present?
12190 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
12191 $as_echo_n "checking krb5.h presence... " >&6; }
12192 cat >conftest.$ac_ext <<_ACEOF
12193 /* confdefs.h.  */
12194 _ACEOF
12195 cat confdefs.h >>conftest.$ac_ext
12196 cat >>conftest.$ac_ext <<_ACEOF
12197 /* end confdefs.h.  */
12198 #include <krb5.h>
12199 _ACEOF
12200 if { (ac_try="$ac_cpp conftest.$ac_ext"
12201 case "(($ac_try" in
12202   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12203   *) ac_try_echo=$ac_try;;
12204 esac
12205 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12206 $as_echo "$ac_try_echo") >&5
12207   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12208   ac_status=$?
12209   grep -v '^ *+' conftest.er1 >conftest.err
12210   rm -f conftest.er1
12211   cat conftest.err >&5
12212   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12213   (exit $ac_status); } >/dev/null && {
12214          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12215          test ! -s conftest.err
12216        }; then
12217   ac_header_preproc=yes
12218 else
12219   $as_echo "$as_me: failed program was:" >&5
12220 sed 's/^/| /' conftest.$ac_ext >&5
12221
12222   ac_header_preproc=no
12223 fi
12224
12225 rm -f conftest.err conftest.$ac_ext
12226 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12227 $as_echo "$ac_header_preproc" >&6; }
12228
12229 # So?  What about this header?
12230 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12231   yes:no: )
12232     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
12233 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12234     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
12235 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
12236     ac_header_preproc=yes
12237     ;;
12238   no:yes:* )
12239     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
12240 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
12241     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
12242 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
12243     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
12244 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
12245     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
12246 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12247     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
12248 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
12249     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
12250 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
12251     ( cat <<\_ASBOX
12252 ## ---------------------------------------- ##
12253 ## Report this to pgsql-bugs@postgresql.org ##
12254 ## ---------------------------------------- ##
12255 _ASBOX
12256      ) | sed "s/^/$as_me: WARNING:     /" >&2
12257     ;;
12258 esac
12259 { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12260 $as_echo_n "checking for krb5.h... " >&6; }
12261 if test "${ac_cv_header_krb5_h+set}" = set; then
12262   $as_echo_n "(cached) " >&6
12263 else
12264   ac_cv_header_krb5_h=$ac_header_preproc
12265 fi
12266 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12267 $as_echo "$ac_cv_header_krb5_h" >&6; }
12268
12269 fi
12270 if test "x$ac_cv_header_krb5_h" = x""yes; then
12271   :
12272 else
12273   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
12274 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
12275    { (exit 1); exit 1; }; }
12276 fi
12277
12278
12279 fi
12280
12281 if test "$with_openssl" = yes ; then
12282   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12283   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12284 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12285 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12286   $as_echo_n "(cached) " >&6
12287 fi
12288 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12289 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12290 else
12291   # Is the header compilable?
12292 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
12293 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
12294 cat >conftest.$ac_ext <<_ACEOF
12295 /* confdefs.h.  */
12296 _ACEOF
12297 cat confdefs.h >>conftest.$ac_ext
12298 cat >>conftest.$ac_ext <<_ACEOF
12299 /* end confdefs.h.  */
12300 $ac_includes_default
12301 #include <openssl/ssl.h>
12302 _ACEOF
12303 rm -f conftest.$ac_objext
12304 if { (ac_try="$ac_compile"
12305 case "(($ac_try" in
12306   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12307   *) ac_try_echo=$ac_try;;
12308 esac
12309 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12310 $as_echo "$ac_try_echo") >&5
12311   (eval "$ac_compile") 2>conftest.er1
12312   ac_status=$?
12313   grep -v '^ *+' conftest.er1 >conftest.err
12314   rm -f conftest.er1
12315   cat conftest.err >&5
12316   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12317   (exit $ac_status); } && {
12318          test -z "$ac_c_werror_flag" ||
12319          test ! -s conftest.err
12320        } && test -s conftest.$ac_objext; then
12321   ac_header_compiler=yes
12322 else
12323   $as_echo "$as_me: failed program was:" >&5
12324 sed 's/^/| /' conftest.$ac_ext >&5
12325
12326         ac_header_compiler=no
12327 fi
12328
12329 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12330 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12331 $as_echo "$ac_header_compiler" >&6; }
12332
12333 # Is the header present?
12334 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
12335 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
12336 cat >conftest.$ac_ext <<_ACEOF
12337 /* confdefs.h.  */
12338 _ACEOF
12339 cat confdefs.h >>conftest.$ac_ext
12340 cat >>conftest.$ac_ext <<_ACEOF
12341 /* end confdefs.h.  */
12342 #include <openssl/ssl.h>
12343 _ACEOF
12344 if { (ac_try="$ac_cpp conftest.$ac_ext"
12345 case "(($ac_try" in
12346   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12347   *) ac_try_echo=$ac_try;;
12348 esac
12349 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12350 $as_echo "$ac_try_echo") >&5
12351   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12352   ac_status=$?
12353   grep -v '^ *+' conftest.er1 >conftest.err
12354   rm -f conftest.er1
12355   cat conftest.err >&5
12356   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12357   (exit $ac_status); } >/dev/null && {
12358          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12359          test ! -s conftest.err
12360        }; then
12361   ac_header_preproc=yes
12362 else
12363   $as_echo "$as_me: failed program was:" >&5
12364 sed 's/^/| /' conftest.$ac_ext >&5
12365
12366   ac_header_preproc=no
12367 fi
12368
12369 rm -f conftest.err conftest.$ac_ext
12370 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12371 $as_echo "$ac_header_preproc" >&6; }
12372
12373 # So?  What about this header?
12374 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12375   yes:no: )
12376     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
12377 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12378     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
12379 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
12380     ac_header_preproc=yes
12381     ;;
12382   no:yes:* )
12383     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
12384 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
12385     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
12386 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
12387     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
12388 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
12389     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
12390 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12391     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
12392 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
12393     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
12394 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
12395     ( cat <<\_ASBOX
12396 ## ---------------------------------------- ##
12397 ## Report this to pgsql-bugs@postgresql.org ##
12398 ## ---------------------------------------- ##
12399 _ASBOX
12400      ) | sed "s/^/$as_me: WARNING:     /" >&2
12401     ;;
12402 esac
12403 { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12404 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12405 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12406   $as_echo_n "(cached) " >&6
12407 else
12408   ac_cv_header_openssl_ssl_h=$ac_header_preproc
12409 fi
12410 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12411 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12412
12413 fi
12414 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
12415   :
12416 else
12417   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
12418 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
12419    { (exit 1); exit 1; }; }
12420 fi
12421
12422
12423   if test "${ac_cv_header_openssl_err_h+set}" = set; then
12424   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12425 $as_echo_n "checking for openssl/err.h... " >&6; }
12426 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12427   $as_echo_n "(cached) " >&6
12428 fi
12429 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12430 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12431 else
12432   # Is the header compilable?
12433 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
12434 $as_echo_n "checking openssl/err.h usability... " >&6; }
12435 cat >conftest.$ac_ext <<_ACEOF
12436 /* confdefs.h.  */
12437 _ACEOF
12438 cat confdefs.h >>conftest.$ac_ext
12439 cat >>conftest.$ac_ext <<_ACEOF
12440 /* end confdefs.h.  */
12441 $ac_includes_default
12442 #include <openssl/err.h>
12443 _ACEOF
12444 rm -f conftest.$ac_objext
12445 if { (ac_try="$ac_compile"
12446 case "(($ac_try" in
12447   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12448   *) ac_try_echo=$ac_try;;
12449 esac
12450 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12451 $as_echo "$ac_try_echo") >&5
12452   (eval "$ac_compile") 2>conftest.er1
12453   ac_status=$?
12454   grep -v '^ *+' conftest.er1 >conftest.err
12455   rm -f conftest.er1
12456   cat conftest.err >&5
12457   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12458   (exit $ac_status); } && {
12459          test -z "$ac_c_werror_flag" ||
12460          test ! -s conftest.err
12461        } && test -s conftest.$ac_objext; then
12462   ac_header_compiler=yes
12463 else
12464   $as_echo "$as_me: failed program was:" >&5
12465 sed 's/^/| /' conftest.$ac_ext >&5
12466
12467         ac_header_compiler=no
12468 fi
12469
12470 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12471 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12472 $as_echo "$ac_header_compiler" >&6; }
12473
12474 # Is the header present?
12475 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
12476 $as_echo_n "checking openssl/err.h presence... " >&6; }
12477 cat >conftest.$ac_ext <<_ACEOF
12478 /* confdefs.h.  */
12479 _ACEOF
12480 cat confdefs.h >>conftest.$ac_ext
12481 cat >>conftest.$ac_ext <<_ACEOF
12482 /* end confdefs.h.  */
12483 #include <openssl/err.h>
12484 _ACEOF
12485 if { (ac_try="$ac_cpp conftest.$ac_ext"
12486 case "(($ac_try" in
12487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12488   *) ac_try_echo=$ac_try;;
12489 esac
12490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12491 $as_echo "$ac_try_echo") >&5
12492   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12493   ac_status=$?
12494   grep -v '^ *+' conftest.er1 >conftest.err
12495   rm -f conftest.er1
12496   cat conftest.err >&5
12497   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12498   (exit $ac_status); } >/dev/null && {
12499          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12500          test ! -s conftest.err
12501        }; then
12502   ac_header_preproc=yes
12503 else
12504   $as_echo "$as_me: failed program was:" >&5
12505 sed 's/^/| /' conftest.$ac_ext >&5
12506
12507   ac_header_preproc=no
12508 fi
12509
12510 rm -f conftest.err conftest.$ac_ext
12511 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12512 $as_echo "$ac_header_preproc" >&6; }
12513
12514 # So?  What about this header?
12515 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12516   yes:no: )
12517     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
12518 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12519     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
12520 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
12521     ac_header_preproc=yes
12522     ;;
12523   no:yes:* )
12524     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
12525 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
12526     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
12527 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
12528     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
12529 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
12530     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
12531 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12532     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
12533 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
12534     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
12535 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
12536     ( cat <<\_ASBOX
12537 ## ---------------------------------------- ##
12538 ## Report this to pgsql-bugs@postgresql.org ##
12539 ## ---------------------------------------- ##
12540 _ASBOX
12541      ) | sed "s/^/$as_me: WARNING:     /" >&2
12542     ;;
12543 esac
12544 { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12545 $as_echo_n "checking for openssl/err.h... " >&6; }
12546 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12547   $as_echo_n "(cached) " >&6
12548 else
12549   ac_cv_header_openssl_err_h=$ac_header_preproc
12550 fi
12551 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12552 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12553
12554 fi
12555 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
12556   :
12557 else
12558   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
12559 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
12560    { (exit 1); exit 1; }; }
12561 fi
12562
12563
12564
12565 for ac_func in ERR_set_mark
12566 do
12567 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12568 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
12569 $as_echo_n "checking for $ac_func... " >&6; }
12570 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
12571   $as_echo_n "(cached) " >&6
12572 else
12573   cat >conftest.$ac_ext <<_ACEOF
12574 /* confdefs.h.  */
12575 _ACEOF
12576 cat confdefs.h >>conftest.$ac_ext
12577 cat >>conftest.$ac_ext <<_ACEOF
12578 /* end confdefs.h.  */
12579 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12580    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12581 #define $ac_func innocuous_$ac_func
12582
12583 /* System header to define __stub macros and hopefully few prototypes,
12584     which can conflict with char $ac_func (); below.
12585     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12586     <limits.h> exists even on freestanding compilers.  */
12587
12588 #ifdef __STDC__
12589 # include <limits.h>
12590 #else
12591 # include <assert.h>
12592 #endif
12593
12594 #undef $ac_func
12595
12596 /* Override any GCC internal prototype to avoid an error.
12597    Use char because int might match the return type of a GCC
12598    builtin and then its argument prototype would still apply.  */
12599 #ifdef __cplusplus
12600 extern "C"
12601 #endif
12602 char $ac_func ();
12603 /* The GNU C library defines this for functions which it implements
12604     to always fail with ENOSYS.  Some functions are actually named
12605     something starting with __ and the normal name is an alias.  */
12606 #if defined __stub_$ac_func || defined __stub___$ac_func
12607 choke me
12608 #endif
12609
12610 int
12611 main ()
12612 {
12613 return $ac_func ();
12614   ;
12615   return 0;
12616 }
12617 _ACEOF
12618 rm -f conftest.$ac_objext conftest$ac_exeext
12619 if { (ac_try="$ac_link"
12620 case "(($ac_try" in
12621   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12622   *) ac_try_echo=$ac_try;;
12623 esac
12624 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12625 $as_echo "$ac_try_echo") >&5
12626   (eval "$ac_link") 2>conftest.er1
12627   ac_status=$?
12628   grep -v '^ *+' conftest.er1 >conftest.err
12629   rm -f conftest.er1
12630   cat conftest.err >&5
12631   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12632   (exit $ac_status); } && {
12633          test -z "$ac_c_werror_flag" ||
12634          test ! -s conftest.err
12635        } && test -s conftest$ac_exeext && {
12636          test "$cross_compiling" = yes ||
12637          $as_test_x conftest$ac_exeext
12638        }; then
12639   eval "$as_ac_var=yes"
12640 else
12641   $as_echo "$as_me: failed program was:" >&5
12642 sed 's/^/| /' conftest.$ac_ext >&5
12643
12644         eval "$as_ac_var=no"
12645 fi
12646
12647 rm -rf conftest.dSYM
12648 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12649       conftest$ac_exeext conftest.$ac_ext
12650 fi
12651 ac_res=`eval 'as_val=${'$as_ac_var'}
12652                  $as_echo "$as_val"'`
12653                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12654 $as_echo "$ac_res" >&6; }
12655 as_val=`eval 'as_val=${'$as_ac_var'}
12656                  $as_echo "$as_val"'`
12657    if test "x$as_val" = x""yes; then
12658   cat >>confdefs.h <<_ACEOF
12659 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12660 _ACEOF
12661
12662 fi
12663 done
12664
12665 fi
12666
12667 if test "$with_pam" = yes ; then
12668
12669 for ac_header in security/pam_appl.h
12670 do
12671 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12672 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12673   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12674 $as_echo_n "checking for $ac_header... " >&6; }
12675 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12676   $as_echo_n "(cached) " >&6
12677 fi
12678 ac_res=`eval 'as_val=${'$as_ac_Header'}
12679                  $as_echo "$as_val"'`
12680                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12681 $as_echo "$ac_res" >&6; }
12682 else
12683   # Is the header compilable?
12684 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12685 $as_echo_n "checking $ac_header usability... " >&6; }
12686 cat >conftest.$ac_ext <<_ACEOF
12687 /* confdefs.h.  */
12688 _ACEOF
12689 cat confdefs.h >>conftest.$ac_ext
12690 cat >>conftest.$ac_ext <<_ACEOF
12691 /* end confdefs.h.  */
12692 $ac_includes_default
12693 #include <$ac_header>
12694 _ACEOF
12695 rm -f conftest.$ac_objext
12696 if { (ac_try="$ac_compile"
12697 case "(($ac_try" in
12698   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12699   *) ac_try_echo=$ac_try;;
12700 esac
12701 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12702 $as_echo "$ac_try_echo") >&5
12703   (eval "$ac_compile") 2>conftest.er1
12704   ac_status=$?
12705   grep -v '^ *+' conftest.er1 >conftest.err
12706   rm -f conftest.er1
12707   cat conftest.err >&5
12708   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12709   (exit $ac_status); } && {
12710          test -z "$ac_c_werror_flag" ||
12711          test ! -s conftest.err
12712        } && test -s conftest.$ac_objext; then
12713   ac_header_compiler=yes
12714 else
12715   $as_echo "$as_me: failed program was:" >&5
12716 sed 's/^/| /' conftest.$ac_ext >&5
12717
12718         ac_header_compiler=no
12719 fi
12720
12721 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12722 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12723 $as_echo "$ac_header_compiler" >&6; }
12724
12725 # Is the header present?
12726 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12727 $as_echo_n "checking $ac_header presence... " >&6; }
12728 cat >conftest.$ac_ext <<_ACEOF
12729 /* confdefs.h.  */
12730 _ACEOF
12731 cat confdefs.h >>conftest.$ac_ext
12732 cat >>conftest.$ac_ext <<_ACEOF
12733 /* end confdefs.h.  */
12734 #include <$ac_header>
12735 _ACEOF
12736 if { (ac_try="$ac_cpp conftest.$ac_ext"
12737 case "(($ac_try" in
12738   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12739   *) ac_try_echo=$ac_try;;
12740 esac
12741 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12742 $as_echo "$ac_try_echo") >&5
12743   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12744   ac_status=$?
12745   grep -v '^ *+' conftest.er1 >conftest.err
12746   rm -f conftest.er1
12747   cat conftest.err >&5
12748   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12749   (exit $ac_status); } >/dev/null && {
12750          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12751          test ! -s conftest.err
12752        }; then
12753   ac_header_preproc=yes
12754 else
12755   $as_echo "$as_me: failed program was:" >&5
12756 sed 's/^/| /' conftest.$ac_ext >&5
12757
12758   ac_header_preproc=no
12759 fi
12760
12761 rm -f conftest.err conftest.$ac_ext
12762 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12763 $as_echo "$ac_header_preproc" >&6; }
12764
12765 # So?  What about this header?
12766 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12767   yes:no: )
12768     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12769 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12770     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12771 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12772     ac_header_preproc=yes
12773     ;;
12774   no:yes:* )
12775     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12776 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12777     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12778 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12779     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12780 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12781     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12782 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12783     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12784 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12785     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12786 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12787     ( cat <<\_ASBOX
12788 ## ---------------------------------------- ##
12789 ## Report this to pgsql-bugs@postgresql.org ##
12790 ## ---------------------------------------- ##
12791 _ASBOX
12792      ) | sed "s/^/$as_me: WARNING:     /" >&2
12793     ;;
12794 esac
12795 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12796 $as_echo_n "checking for $ac_header... " >&6; }
12797 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12798   $as_echo_n "(cached) " >&6
12799 else
12800   eval "$as_ac_Header=\$ac_header_preproc"
12801 fi
12802 ac_res=`eval 'as_val=${'$as_ac_Header'}
12803                  $as_echo "$as_val"'`
12804                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12805 $as_echo "$ac_res" >&6; }
12806
12807 fi
12808 as_val=`eval 'as_val=${'$as_ac_Header'}
12809                  $as_echo "$as_val"'`
12810    if test "x$as_val" = x""yes; then
12811   cat >>confdefs.h <<_ACEOF
12812 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12813 _ACEOF
12814
12815 else
12816
12817 for ac_header in pam/pam_appl.h
12818 do
12819 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12820 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12821   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12822 $as_echo_n "checking for $ac_header... " >&6; }
12823 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12824   $as_echo_n "(cached) " >&6
12825 fi
12826 ac_res=`eval 'as_val=${'$as_ac_Header'}
12827                  $as_echo "$as_val"'`
12828                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12829 $as_echo "$ac_res" >&6; }
12830 else
12831   # Is the header compilable?
12832 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12833 $as_echo_n "checking $ac_header usability... " >&6; }
12834 cat >conftest.$ac_ext <<_ACEOF
12835 /* confdefs.h.  */
12836 _ACEOF
12837 cat confdefs.h >>conftest.$ac_ext
12838 cat >>conftest.$ac_ext <<_ACEOF
12839 /* end confdefs.h.  */
12840 $ac_includes_default
12841 #include <$ac_header>
12842 _ACEOF
12843 rm -f conftest.$ac_objext
12844 if { (ac_try="$ac_compile"
12845 case "(($ac_try" in
12846   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12847   *) ac_try_echo=$ac_try;;
12848 esac
12849 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12850 $as_echo "$ac_try_echo") >&5
12851   (eval "$ac_compile") 2>conftest.er1
12852   ac_status=$?
12853   grep -v '^ *+' conftest.er1 >conftest.err
12854   rm -f conftest.er1
12855   cat conftest.err >&5
12856   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12857   (exit $ac_status); } && {
12858          test -z "$ac_c_werror_flag" ||
12859          test ! -s conftest.err
12860        } && test -s conftest.$ac_objext; then
12861   ac_header_compiler=yes
12862 else
12863   $as_echo "$as_me: failed program was:" >&5
12864 sed 's/^/| /' conftest.$ac_ext >&5
12865
12866         ac_header_compiler=no
12867 fi
12868
12869 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12870 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12871 $as_echo "$ac_header_compiler" >&6; }
12872
12873 # Is the header present?
12874 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12875 $as_echo_n "checking $ac_header presence... " >&6; }
12876 cat >conftest.$ac_ext <<_ACEOF
12877 /* confdefs.h.  */
12878 _ACEOF
12879 cat confdefs.h >>conftest.$ac_ext
12880 cat >>conftest.$ac_ext <<_ACEOF
12881 /* end confdefs.h.  */
12882 #include <$ac_header>
12883 _ACEOF
12884 if { (ac_try="$ac_cpp conftest.$ac_ext"
12885 case "(($ac_try" in
12886   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12887   *) ac_try_echo=$ac_try;;
12888 esac
12889 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12890 $as_echo "$ac_try_echo") >&5
12891   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12892   ac_status=$?
12893   grep -v '^ *+' conftest.er1 >conftest.err
12894   rm -f conftest.er1
12895   cat conftest.err >&5
12896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12897   (exit $ac_status); } >/dev/null && {
12898          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12899          test ! -s conftest.err
12900        }; then
12901   ac_header_preproc=yes
12902 else
12903   $as_echo "$as_me: failed program was:" >&5
12904 sed 's/^/| /' conftest.$ac_ext >&5
12905
12906   ac_header_preproc=no
12907 fi
12908
12909 rm -f conftest.err conftest.$ac_ext
12910 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12911 $as_echo "$ac_header_preproc" >&6; }
12912
12913 # So?  What about this header?
12914 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12915   yes:no: )
12916     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12917 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12918     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12919 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12920     ac_header_preproc=yes
12921     ;;
12922   no:yes:* )
12923     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12924 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12925     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12926 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12927     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12928 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12929     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12930 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12931     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12932 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12933     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12934 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12935     ( cat <<\_ASBOX
12936 ## ---------------------------------------- ##
12937 ## Report this to pgsql-bugs@postgresql.org ##
12938 ## ---------------------------------------- ##
12939 _ASBOX
12940      ) | sed "s/^/$as_me: WARNING:     /" >&2
12941     ;;
12942 esac
12943 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12944 $as_echo_n "checking for $ac_header... " >&6; }
12945 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12946   $as_echo_n "(cached) " >&6
12947 else
12948   eval "$as_ac_Header=\$ac_header_preproc"
12949 fi
12950 ac_res=`eval 'as_val=${'$as_ac_Header'}
12951                  $as_echo "$as_val"'`
12952                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12953 $as_echo "$ac_res" >&6; }
12954
12955 fi
12956 as_val=`eval 'as_val=${'$as_ac_Header'}
12957                  $as_echo "$as_val"'`
12958    if test "x$as_val" = x""yes; then
12959   cat >>confdefs.h <<_ACEOF
12960 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12961 _ACEOF
12962
12963 else
12964   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
12965 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
12966    { (exit 1); exit 1; }; }
12967 fi
12968
12969 done
12970
12971 fi
12972
12973 done
12974
12975 fi
12976
12977 if test "$with_libxml" = yes ; then
12978   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
12979   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
12980 $as_echo_n "checking for libxml/parser.h... " >&6; }
12981 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
12982   $as_echo_n "(cached) " >&6
12983 fi
12984 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
12985 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
12986 else
12987   # Is the header compilable?
12988 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
12989 $as_echo_n "checking libxml/parser.h usability... " >&6; }
12990 cat >conftest.$ac_ext <<_ACEOF
12991 /* confdefs.h.  */
12992 _ACEOF
12993 cat confdefs.h >>conftest.$ac_ext
12994 cat >>conftest.$ac_ext <<_ACEOF
12995 /* end confdefs.h.  */
12996 $ac_includes_default
12997 #include <libxml/parser.h>
12998 _ACEOF
12999 rm -f conftest.$ac_objext
13000 if { (ac_try="$ac_compile"
13001 case "(($ac_try" in
13002   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13003   *) ac_try_echo=$ac_try;;
13004 esac
13005 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13006 $as_echo "$ac_try_echo") >&5
13007   (eval "$ac_compile") 2>conftest.er1
13008   ac_status=$?
13009   grep -v '^ *+' conftest.er1 >conftest.err
13010   rm -f conftest.er1
13011   cat conftest.err >&5
13012   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13013   (exit $ac_status); } && {
13014          test -z "$ac_c_werror_flag" ||
13015          test ! -s conftest.err
13016        } && test -s conftest.$ac_objext; then
13017   ac_header_compiler=yes
13018 else
13019   $as_echo "$as_me: failed program was:" >&5
13020 sed 's/^/| /' conftest.$ac_ext >&5
13021
13022         ac_header_compiler=no
13023 fi
13024
13025 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13026 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13027 $as_echo "$ac_header_compiler" >&6; }
13028
13029 # Is the header present?
13030 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
13031 $as_echo_n "checking libxml/parser.h presence... " >&6; }
13032 cat >conftest.$ac_ext <<_ACEOF
13033 /* confdefs.h.  */
13034 _ACEOF
13035 cat confdefs.h >>conftest.$ac_ext
13036 cat >>conftest.$ac_ext <<_ACEOF
13037 /* end confdefs.h.  */
13038 #include <libxml/parser.h>
13039 _ACEOF
13040 if { (ac_try="$ac_cpp conftest.$ac_ext"
13041 case "(($ac_try" in
13042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13043   *) ac_try_echo=$ac_try;;
13044 esac
13045 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13046 $as_echo "$ac_try_echo") >&5
13047   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13048   ac_status=$?
13049   grep -v '^ *+' conftest.er1 >conftest.err
13050   rm -f conftest.er1
13051   cat conftest.err >&5
13052   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13053   (exit $ac_status); } >/dev/null && {
13054          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13055          test ! -s conftest.err
13056        }; then
13057   ac_header_preproc=yes
13058 else
13059   $as_echo "$as_me: failed program was:" >&5
13060 sed 's/^/| /' conftest.$ac_ext >&5
13061
13062   ac_header_preproc=no
13063 fi
13064
13065 rm -f conftest.err conftest.$ac_ext
13066 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13067 $as_echo "$ac_header_preproc" >&6; }
13068
13069 # So?  What about this header?
13070 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13071   yes:no: )
13072     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13073 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13074     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13075 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13076     ac_header_preproc=yes
13077     ;;
13078   no:yes:* )
13079     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13080 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13081     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13082 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13083     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13084 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13085     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13086 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13087     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13088 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13089     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13090 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13091     ( cat <<\_ASBOX
13092 ## ---------------------------------------- ##
13093 ## Report this to pgsql-bugs@postgresql.org ##
13094 ## ---------------------------------------- ##
13095 _ASBOX
13096      ) | sed "s/^/$as_me: WARNING:     /" >&2
13097     ;;
13098 esac
13099 { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13100 $as_echo_n "checking for libxml/parser.h... " >&6; }
13101 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13102   $as_echo_n "(cached) " >&6
13103 else
13104   ac_cv_header_libxml_parser_h=$ac_header_preproc
13105 fi
13106 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13107 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13108
13109 fi
13110 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13111   :
13112 else
13113   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13114 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13115    { (exit 1); exit 1; }; }
13116 fi
13117
13118
13119 fi
13120
13121 if test "$with_libxslt" = yes ; then
13122   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13123   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13124 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13125 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13126   $as_echo_n "(cached) " >&6
13127 fi
13128 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13129 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13130 else
13131   # Is the header compilable?
13132 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13133 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13134 cat >conftest.$ac_ext <<_ACEOF
13135 /* confdefs.h.  */
13136 _ACEOF
13137 cat confdefs.h >>conftest.$ac_ext
13138 cat >>conftest.$ac_ext <<_ACEOF
13139 /* end confdefs.h.  */
13140 $ac_includes_default
13141 #include <libxslt/xslt.h>
13142 _ACEOF
13143 rm -f conftest.$ac_objext
13144 if { (ac_try="$ac_compile"
13145 case "(($ac_try" in
13146   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13147   *) ac_try_echo=$ac_try;;
13148 esac
13149 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13150 $as_echo "$ac_try_echo") >&5
13151   (eval "$ac_compile") 2>conftest.er1
13152   ac_status=$?
13153   grep -v '^ *+' conftest.er1 >conftest.err
13154   rm -f conftest.er1
13155   cat conftest.err >&5
13156   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13157   (exit $ac_status); } && {
13158          test -z "$ac_c_werror_flag" ||
13159          test ! -s conftest.err
13160        } && test -s conftest.$ac_objext; then
13161   ac_header_compiler=yes
13162 else
13163   $as_echo "$as_me: failed program was:" >&5
13164 sed 's/^/| /' conftest.$ac_ext >&5
13165
13166         ac_header_compiler=no
13167 fi
13168
13169 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13170 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13171 $as_echo "$ac_header_compiler" >&6; }
13172
13173 # Is the header present?
13174 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13175 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13176 cat >conftest.$ac_ext <<_ACEOF
13177 /* confdefs.h.  */
13178 _ACEOF
13179 cat confdefs.h >>conftest.$ac_ext
13180 cat >>conftest.$ac_ext <<_ACEOF
13181 /* end confdefs.h.  */
13182 #include <libxslt/xslt.h>
13183 _ACEOF
13184 if { (ac_try="$ac_cpp conftest.$ac_ext"
13185 case "(($ac_try" in
13186   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13187   *) ac_try_echo=$ac_try;;
13188 esac
13189 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13190 $as_echo "$ac_try_echo") >&5
13191   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13192   ac_status=$?
13193   grep -v '^ *+' conftest.er1 >conftest.err
13194   rm -f conftest.er1
13195   cat conftest.err >&5
13196   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13197   (exit $ac_status); } >/dev/null && {
13198          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13199          test ! -s conftest.err
13200        }; then
13201   ac_header_preproc=yes
13202 else
13203   $as_echo "$as_me: failed program was:" >&5
13204 sed 's/^/| /' conftest.$ac_ext >&5
13205
13206   ac_header_preproc=no
13207 fi
13208
13209 rm -f conftest.err conftest.$ac_ext
13210 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13211 $as_echo "$ac_header_preproc" >&6; }
13212
13213 # So?  What about this header?
13214 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13215   yes:no: )
13216     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
13217 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13218     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
13219 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
13220     ac_header_preproc=yes
13221     ;;
13222   no:yes:* )
13223     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
13224 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
13225     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
13226 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
13227     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
13228 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
13229     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
13230 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13231     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
13232 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
13233     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
13234 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
13235     ( cat <<\_ASBOX
13236 ## ---------------------------------------- ##
13237 ## Report this to pgsql-bugs@postgresql.org ##
13238 ## ---------------------------------------- ##
13239 _ASBOX
13240      ) | sed "s/^/$as_me: WARNING:     /" >&2
13241     ;;
13242 esac
13243 { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13244 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13245 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13246   $as_echo_n "(cached) " >&6
13247 else
13248   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
13249 fi
13250 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13251 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13252
13253 fi
13254 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
13255   :
13256 else
13257   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
13258 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
13259    { (exit 1); exit 1; }; }
13260 fi
13261
13262
13263 fi
13264
13265 if test "$with_ldap" = yes ; then
13266   if test "$PORTNAME" != "win32"; then
13267
13268 for ac_header in ldap.h
13269 do
13270 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13271 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13272   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13273 $as_echo_n "checking for $ac_header... " >&6; }
13274 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13275   $as_echo_n "(cached) " >&6
13276 fi
13277 ac_res=`eval 'as_val=${'$as_ac_Header'}
13278                  $as_echo "$as_val"'`
13279                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13280 $as_echo "$ac_res" >&6; }
13281 else
13282   # Is the header compilable?
13283 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13284 $as_echo_n "checking $ac_header usability... " >&6; }
13285 cat >conftest.$ac_ext <<_ACEOF
13286 /* confdefs.h.  */
13287 _ACEOF
13288 cat confdefs.h >>conftest.$ac_ext
13289 cat >>conftest.$ac_ext <<_ACEOF
13290 /* end confdefs.h.  */
13291 $ac_includes_default
13292 #include <$ac_header>
13293 _ACEOF
13294 rm -f conftest.$ac_objext
13295 if { (ac_try="$ac_compile"
13296 case "(($ac_try" in
13297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13298   *) ac_try_echo=$ac_try;;
13299 esac
13300 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13301 $as_echo "$ac_try_echo") >&5
13302   (eval "$ac_compile") 2>conftest.er1
13303   ac_status=$?
13304   grep -v '^ *+' conftest.er1 >conftest.err
13305   rm -f conftest.er1
13306   cat conftest.err >&5
13307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13308   (exit $ac_status); } && {
13309          test -z "$ac_c_werror_flag" ||
13310          test ! -s conftest.err
13311        } && test -s conftest.$ac_objext; then
13312   ac_header_compiler=yes
13313 else
13314   $as_echo "$as_me: failed program was:" >&5
13315 sed 's/^/| /' conftest.$ac_ext >&5
13316
13317         ac_header_compiler=no
13318 fi
13319
13320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13321 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13322 $as_echo "$ac_header_compiler" >&6; }
13323
13324 # Is the header present?
13325 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13326 $as_echo_n "checking $ac_header presence... " >&6; }
13327 cat >conftest.$ac_ext <<_ACEOF
13328 /* confdefs.h.  */
13329 _ACEOF
13330 cat confdefs.h >>conftest.$ac_ext
13331 cat >>conftest.$ac_ext <<_ACEOF
13332 /* end confdefs.h.  */
13333 #include <$ac_header>
13334 _ACEOF
13335 if { (ac_try="$ac_cpp conftest.$ac_ext"
13336 case "(($ac_try" in
13337   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13338   *) ac_try_echo=$ac_try;;
13339 esac
13340 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13341 $as_echo "$ac_try_echo") >&5
13342   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13343   ac_status=$?
13344   grep -v '^ *+' conftest.er1 >conftest.err
13345   rm -f conftest.er1
13346   cat conftest.err >&5
13347   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13348   (exit $ac_status); } >/dev/null && {
13349          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13350          test ! -s conftest.err
13351        }; then
13352   ac_header_preproc=yes
13353 else
13354   $as_echo "$as_me: failed program was:" >&5
13355 sed 's/^/| /' conftest.$ac_ext >&5
13356
13357   ac_header_preproc=no
13358 fi
13359
13360 rm -f conftest.err conftest.$ac_ext
13361 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13362 $as_echo "$ac_header_preproc" >&6; }
13363
13364 # So?  What about this header?
13365 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13366   yes:no: )
13367     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13368 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13369     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13370 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13371     ac_header_preproc=yes
13372     ;;
13373   no:yes:* )
13374     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13375 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13376     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13377 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13378     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13379 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13380     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13381 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13382     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13383 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13384     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13385 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13386     ( cat <<\_ASBOX
13387 ## ---------------------------------------- ##
13388 ## Report this to pgsql-bugs@postgresql.org ##
13389 ## ---------------------------------------- ##
13390 _ASBOX
13391      ) | sed "s/^/$as_me: WARNING:     /" >&2
13392     ;;
13393 esac
13394 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13395 $as_echo_n "checking for $ac_header... " >&6; }
13396 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13397   $as_echo_n "(cached) " >&6
13398 else
13399   eval "$as_ac_Header=\$ac_header_preproc"
13400 fi
13401 ac_res=`eval 'as_val=${'$as_ac_Header'}
13402                  $as_echo "$as_val"'`
13403                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13404 $as_echo "$ac_res" >&6; }
13405
13406 fi
13407 as_val=`eval 'as_val=${'$as_ac_Header'}
13408                  $as_echo "$as_val"'`
13409    if test "x$as_val" = x""yes; then
13410   cat >>confdefs.h <<_ACEOF
13411 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13412 _ACEOF
13413
13414 else
13415   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
13416 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
13417    { (exit 1); exit 1; }; }
13418 fi
13419
13420 done
13421
13422   else
13423
13424 for ac_header in winldap.h
13425 do
13426 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13427 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13428 $as_echo_n "checking for $ac_header... " >&6; }
13429 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13430   $as_echo_n "(cached) " >&6
13431 else
13432   cat >conftest.$ac_ext <<_ACEOF
13433 /* confdefs.h.  */
13434 _ACEOF
13435 cat confdefs.h >>conftest.$ac_ext
13436 cat >>conftest.$ac_ext <<_ACEOF
13437 /* end confdefs.h.  */
13438 $ac_includes_default
13439 #include <windows.h>
13440
13441
13442 #include <$ac_header>
13443 _ACEOF
13444 rm -f conftest.$ac_objext
13445 if { (ac_try="$ac_compile"
13446 case "(($ac_try" in
13447   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13448   *) ac_try_echo=$ac_try;;
13449 esac
13450 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13451 $as_echo "$ac_try_echo") >&5
13452   (eval "$ac_compile") 2>conftest.er1
13453   ac_status=$?
13454   grep -v '^ *+' conftest.er1 >conftest.err
13455   rm -f conftest.er1
13456   cat conftest.err >&5
13457   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13458   (exit $ac_status); } && {
13459          test -z "$ac_c_werror_flag" ||
13460          test ! -s conftest.err
13461        } && test -s conftest.$ac_objext; then
13462   eval "$as_ac_Header=yes"
13463 else
13464   $as_echo "$as_me: failed program was:" >&5
13465 sed 's/^/| /' conftest.$ac_ext >&5
13466
13467         eval "$as_ac_Header=no"
13468 fi
13469
13470 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13471 fi
13472 ac_res=`eval 'as_val=${'$as_ac_Header'}
13473                  $as_echo "$as_val"'`
13474                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13475 $as_echo "$ac_res" >&6; }
13476 as_val=`eval 'as_val=${'$as_ac_Header'}
13477                  $as_echo "$as_val"'`
13478    if test "x$as_val" = x""yes; then
13479   cat >>confdefs.h <<_ACEOF
13480 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13481 _ACEOF
13482
13483 else
13484   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
13485 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
13486    { (exit 1); exit 1; }; }
13487 fi
13488
13489 done
13490
13491   fi
13492 fi
13493
13494 if test "$with_bonjour" = yes ; then
13495   if test "${ac_cv_header_dns_sd_h+set}" = set; then
13496   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13497 $as_echo_n "checking for dns_sd.h... " >&6; }
13498 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13499   $as_echo_n "(cached) " >&6
13500 fi
13501 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13502 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13503 else
13504   # Is the header compilable?
13505 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
13506 $as_echo_n "checking dns_sd.h usability... " >&6; }
13507 cat >conftest.$ac_ext <<_ACEOF
13508 /* confdefs.h.  */
13509 _ACEOF
13510 cat confdefs.h >>conftest.$ac_ext
13511 cat >>conftest.$ac_ext <<_ACEOF
13512 /* end confdefs.h.  */
13513 $ac_includes_default
13514 #include <dns_sd.h>
13515 _ACEOF
13516 rm -f conftest.$ac_objext
13517 if { (ac_try="$ac_compile"
13518 case "(($ac_try" in
13519   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13520   *) ac_try_echo=$ac_try;;
13521 esac
13522 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13523 $as_echo "$ac_try_echo") >&5
13524   (eval "$ac_compile") 2>conftest.er1
13525   ac_status=$?
13526   grep -v '^ *+' conftest.er1 >conftest.err
13527   rm -f conftest.er1
13528   cat conftest.err >&5
13529   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13530   (exit $ac_status); } && {
13531          test -z "$ac_c_werror_flag" ||
13532          test ! -s conftest.err
13533        } && test -s conftest.$ac_objext; then
13534   ac_header_compiler=yes
13535 else
13536   $as_echo "$as_me: failed program was:" >&5
13537 sed 's/^/| /' conftest.$ac_ext >&5
13538
13539         ac_header_compiler=no
13540 fi
13541
13542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13543 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13544 $as_echo "$ac_header_compiler" >&6; }
13545
13546 # Is the header present?
13547 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
13548 $as_echo_n "checking dns_sd.h presence... " >&6; }
13549 cat >conftest.$ac_ext <<_ACEOF
13550 /* confdefs.h.  */
13551 _ACEOF
13552 cat confdefs.h >>conftest.$ac_ext
13553 cat >>conftest.$ac_ext <<_ACEOF
13554 /* end confdefs.h.  */
13555 #include <dns_sd.h>
13556 _ACEOF
13557 if { (ac_try="$ac_cpp conftest.$ac_ext"
13558 case "(($ac_try" in
13559   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13560   *) ac_try_echo=$ac_try;;
13561 esac
13562 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13563 $as_echo "$ac_try_echo") >&5
13564   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13565   ac_status=$?
13566   grep -v '^ *+' conftest.er1 >conftest.err
13567   rm -f conftest.er1
13568   cat conftest.err >&5
13569   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13570   (exit $ac_status); } >/dev/null && {
13571          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13572          test ! -s conftest.err
13573        }; then
13574   ac_header_preproc=yes
13575 else
13576   $as_echo "$as_me: failed program was:" >&5
13577 sed 's/^/| /' conftest.$ac_ext >&5
13578
13579   ac_header_preproc=no
13580 fi
13581
13582 rm -f conftest.err conftest.$ac_ext
13583 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13584 $as_echo "$ac_header_preproc" >&6; }
13585
13586 # So?  What about this header?
13587 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13588   yes:no: )
13589     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
13590 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13591     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
13592 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
13593     ac_header_preproc=yes
13594     ;;
13595   no:yes:* )
13596     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
13597 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
13598     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
13599 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
13600     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
13601 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
13602     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
13603 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13604     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
13605 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
13606     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
13607 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
13608     ( cat <<\_ASBOX
13609 ## ---------------------------------------- ##
13610 ## Report this to pgsql-bugs@postgresql.org ##
13611 ## ---------------------------------------- ##
13612 _ASBOX
13613      ) | sed "s/^/$as_me: WARNING:     /" >&2
13614     ;;
13615 esac
13616 { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13617 $as_echo_n "checking for dns_sd.h... " >&6; }
13618 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13619   $as_echo_n "(cached) " >&6
13620 else
13621   ac_cv_header_dns_sd_h=$ac_header_preproc
13622 fi
13623 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13624 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13625
13626 fi
13627 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
13628   :
13629 else
13630   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
13631 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
13632    { (exit 1); exit 1; }; }
13633 fi
13634
13635
13636 fi
13637
13638 # for contrib/uuid-ossp
13639 if test "$with_ossp_uuid" = yes ; then
13640
13641 for ac_header in ossp/uuid.h
13642 do
13643 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13644 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13645   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13646 $as_echo_n "checking for $ac_header... " >&6; }
13647 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13648   $as_echo_n "(cached) " >&6
13649 fi
13650 ac_res=`eval 'as_val=${'$as_ac_Header'}
13651                  $as_echo "$as_val"'`
13652                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13653 $as_echo "$ac_res" >&6; }
13654 else
13655   # Is the header compilable?
13656 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13657 $as_echo_n "checking $ac_header usability... " >&6; }
13658 cat >conftest.$ac_ext <<_ACEOF
13659 /* confdefs.h.  */
13660 _ACEOF
13661 cat confdefs.h >>conftest.$ac_ext
13662 cat >>conftest.$ac_ext <<_ACEOF
13663 /* end confdefs.h.  */
13664 $ac_includes_default
13665 #include <$ac_header>
13666 _ACEOF
13667 rm -f conftest.$ac_objext
13668 if { (ac_try="$ac_compile"
13669 case "(($ac_try" in
13670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13671   *) ac_try_echo=$ac_try;;
13672 esac
13673 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13674 $as_echo "$ac_try_echo") >&5
13675   (eval "$ac_compile") 2>conftest.er1
13676   ac_status=$?
13677   grep -v '^ *+' conftest.er1 >conftest.err
13678   rm -f conftest.er1
13679   cat conftest.err >&5
13680   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13681   (exit $ac_status); } && {
13682          test -z "$ac_c_werror_flag" ||
13683          test ! -s conftest.err
13684        } && test -s conftest.$ac_objext; then
13685   ac_header_compiler=yes
13686 else
13687   $as_echo "$as_me: failed program was:" >&5
13688 sed 's/^/| /' conftest.$ac_ext >&5
13689
13690         ac_header_compiler=no
13691 fi
13692
13693 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13694 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13695 $as_echo "$ac_header_compiler" >&6; }
13696
13697 # Is the header present?
13698 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13699 $as_echo_n "checking $ac_header presence... " >&6; }
13700 cat >conftest.$ac_ext <<_ACEOF
13701 /* confdefs.h.  */
13702 _ACEOF
13703 cat confdefs.h >>conftest.$ac_ext
13704 cat >>conftest.$ac_ext <<_ACEOF
13705 /* end confdefs.h.  */
13706 #include <$ac_header>
13707 _ACEOF
13708 if { (ac_try="$ac_cpp conftest.$ac_ext"
13709 case "(($ac_try" in
13710   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13711   *) ac_try_echo=$ac_try;;
13712 esac
13713 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13714 $as_echo "$ac_try_echo") >&5
13715   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13716   ac_status=$?
13717   grep -v '^ *+' conftest.er1 >conftest.err
13718   rm -f conftest.er1
13719   cat conftest.err >&5
13720   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13721   (exit $ac_status); } >/dev/null && {
13722          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13723          test ! -s conftest.err
13724        }; then
13725   ac_header_preproc=yes
13726 else
13727   $as_echo "$as_me: failed program was:" >&5
13728 sed 's/^/| /' conftest.$ac_ext >&5
13729
13730   ac_header_preproc=no
13731 fi
13732
13733 rm -f conftest.err conftest.$ac_ext
13734 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13735 $as_echo "$ac_header_preproc" >&6; }
13736
13737 # So?  What about this header?
13738 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13739   yes:no: )
13740     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13741 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13742     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13743 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13744     ac_header_preproc=yes
13745     ;;
13746   no:yes:* )
13747     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13748 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13749     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13750 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13751     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13752 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13753     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13754 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13755     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13756 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13757     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13758 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13759     ( cat <<\_ASBOX
13760 ## ---------------------------------------- ##
13761 ## Report this to pgsql-bugs@postgresql.org ##
13762 ## ---------------------------------------- ##
13763 _ASBOX
13764      ) | sed "s/^/$as_me: WARNING:     /" >&2
13765     ;;
13766 esac
13767 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13768 $as_echo_n "checking for $ac_header... " >&6; }
13769 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13770   $as_echo_n "(cached) " >&6
13771 else
13772   eval "$as_ac_Header=\$ac_header_preproc"
13773 fi
13774 ac_res=`eval 'as_val=${'$as_ac_Header'}
13775                  $as_echo "$as_val"'`
13776                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13777 $as_echo "$ac_res" >&6; }
13778
13779 fi
13780 as_val=`eval 'as_val=${'$as_ac_Header'}
13781                  $as_echo "$as_val"'`
13782    if test "x$as_val" = x""yes; then
13783   cat >>confdefs.h <<_ACEOF
13784 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13785 _ACEOF
13786
13787 else
13788
13789
13790 for ac_header in uuid.h
13791 do
13792 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13793 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13794   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13795 $as_echo_n "checking for $ac_header... " >&6; }
13796 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13797   $as_echo_n "(cached) " >&6
13798 fi
13799 ac_res=`eval 'as_val=${'$as_ac_Header'}
13800                  $as_echo "$as_val"'`
13801                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13802 $as_echo "$ac_res" >&6; }
13803 else
13804   # Is the header compilable?
13805 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13806 $as_echo_n "checking $ac_header usability... " >&6; }
13807 cat >conftest.$ac_ext <<_ACEOF
13808 /* confdefs.h.  */
13809 _ACEOF
13810 cat confdefs.h >>conftest.$ac_ext
13811 cat >>conftest.$ac_ext <<_ACEOF
13812 /* end confdefs.h.  */
13813 $ac_includes_default
13814 #include <$ac_header>
13815 _ACEOF
13816 rm -f conftest.$ac_objext
13817 if { (ac_try="$ac_compile"
13818 case "(($ac_try" in
13819   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13820   *) ac_try_echo=$ac_try;;
13821 esac
13822 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13823 $as_echo "$ac_try_echo") >&5
13824   (eval "$ac_compile") 2>conftest.er1
13825   ac_status=$?
13826   grep -v '^ *+' conftest.er1 >conftest.err
13827   rm -f conftest.er1
13828   cat conftest.err >&5
13829   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13830   (exit $ac_status); } && {
13831          test -z "$ac_c_werror_flag" ||
13832          test ! -s conftest.err
13833        } && test -s conftest.$ac_objext; then
13834   ac_header_compiler=yes
13835 else
13836   $as_echo "$as_me: failed program was:" >&5
13837 sed 's/^/| /' conftest.$ac_ext >&5
13838
13839         ac_header_compiler=no
13840 fi
13841
13842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13843 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13844 $as_echo "$ac_header_compiler" >&6; }
13845
13846 # Is the header present?
13847 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13848 $as_echo_n "checking $ac_header presence... " >&6; }
13849 cat >conftest.$ac_ext <<_ACEOF
13850 /* confdefs.h.  */
13851 _ACEOF
13852 cat confdefs.h >>conftest.$ac_ext
13853 cat >>conftest.$ac_ext <<_ACEOF
13854 /* end confdefs.h.  */
13855 #include <$ac_header>
13856 _ACEOF
13857 if { (ac_try="$ac_cpp conftest.$ac_ext"
13858 case "(($ac_try" in
13859   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13860   *) ac_try_echo=$ac_try;;
13861 esac
13862 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13863 $as_echo "$ac_try_echo") >&5
13864   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13865   ac_status=$?
13866   grep -v '^ *+' conftest.er1 >conftest.err
13867   rm -f conftest.er1
13868   cat conftest.err >&5
13869   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13870   (exit $ac_status); } >/dev/null && {
13871          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13872          test ! -s conftest.err
13873        }; then
13874   ac_header_preproc=yes
13875 else
13876   $as_echo "$as_me: failed program was:" >&5
13877 sed 's/^/| /' conftest.$ac_ext >&5
13878
13879   ac_header_preproc=no
13880 fi
13881
13882 rm -f conftest.err conftest.$ac_ext
13883 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13884 $as_echo "$ac_header_preproc" >&6; }
13885
13886 # So?  What about this header?
13887 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13888   yes:no: )
13889     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13890 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13891     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13892 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13893     ac_header_preproc=yes
13894     ;;
13895   no:yes:* )
13896     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13897 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13898     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13899 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13900     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13901 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13902     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13903 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13904     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13905 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13906     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13907 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13908     ( cat <<\_ASBOX
13909 ## ---------------------------------------- ##
13910 ## Report this to pgsql-bugs@postgresql.org ##
13911 ## ---------------------------------------- ##
13912 _ASBOX
13913      ) | sed "s/^/$as_me: WARNING:     /" >&2
13914     ;;
13915 esac
13916 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13917 $as_echo_n "checking for $ac_header... " >&6; }
13918 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13919   $as_echo_n "(cached) " >&6
13920 else
13921   eval "$as_ac_Header=\$ac_header_preproc"
13922 fi
13923 ac_res=`eval 'as_val=${'$as_ac_Header'}
13924                  $as_echo "$as_val"'`
13925                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13926 $as_echo "$ac_res" >&6; }
13927
13928 fi
13929 as_val=`eval 'as_val=${'$as_ac_Header'}
13930                  $as_echo "$as_val"'`
13931    if test "x$as_val" = x""yes; then
13932   cat >>confdefs.h <<_ACEOF
13933 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13934 _ACEOF
13935
13936 else
13937   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
13938 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
13939    { (exit 1); exit 1; }; }
13940 fi
13941
13942 done
13943
13944 fi
13945
13946 done
13947
13948 fi
13949
13950
13951 ##
13952 ## Types, structures, compiler characteristics
13953 ##
13954
13955
13956  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
13957 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13958 if test "${ac_cv_c_bigendian+set}" = set; then
13959   $as_echo_n "(cached) " >&6
13960 else
13961   ac_cv_c_bigendian=unknown
13962     # See if we're dealing with a universal compiler.
13963     cat >conftest.$ac_ext <<_ACEOF
13964 /* confdefs.h.  */
13965 _ACEOF
13966 cat confdefs.h >>conftest.$ac_ext
13967 cat >>conftest.$ac_ext <<_ACEOF
13968 /* end confdefs.h.  */
13969 #ifndef __APPLE_CC__
13970                not a universal capable compiler
13971              #endif
13972              typedef int dummy;
13973
13974 _ACEOF
13975 rm -f conftest.$ac_objext
13976 if { (ac_try="$ac_compile"
13977 case "(($ac_try" in
13978   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13979   *) ac_try_echo=$ac_try;;
13980 esac
13981 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13982 $as_echo "$ac_try_echo") >&5
13983   (eval "$ac_compile") 2>conftest.er1
13984   ac_status=$?
13985   grep -v '^ *+' conftest.er1 >conftest.err
13986   rm -f conftest.er1
13987   cat conftest.err >&5
13988   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13989   (exit $ac_status); } && {
13990          test -z "$ac_c_werror_flag" ||
13991          test ! -s conftest.err
13992        } && test -s conftest.$ac_objext; then
13993
13994         # Check for potential -arch flags.  It is not universal unless
13995         # there are some -arch flags.  Note that *ppc* also matches
13996         # ppc64.  This check is also rather less than ideal.
13997         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
13998           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
13999         esac
14000 else
14001   $as_echo "$as_me: failed program was:" >&5
14002 sed 's/^/| /' conftest.$ac_ext >&5
14003
14004
14005 fi
14006
14007 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14008     if test $ac_cv_c_bigendian = unknown; then
14009       # See if sys/param.h defines the BYTE_ORDER macro.
14010       cat >conftest.$ac_ext <<_ACEOF
14011 /* confdefs.h.  */
14012 _ACEOF
14013 cat confdefs.h >>conftest.$ac_ext
14014 cat >>conftest.$ac_ext <<_ACEOF
14015 /* end confdefs.h.  */
14016 #include <sys/types.h>
14017              #include <sys/param.h>
14018
14019 int
14020 main ()
14021 {
14022 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14023                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14024                      && LITTLE_ENDIAN)
14025               bogus endian macros
14026              #endif
14027
14028   ;
14029   return 0;
14030 }
14031 _ACEOF
14032 rm -f conftest.$ac_objext
14033 if { (ac_try="$ac_compile"
14034 case "(($ac_try" in
14035   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14036   *) ac_try_echo=$ac_try;;
14037 esac
14038 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14039 $as_echo "$ac_try_echo") >&5
14040   (eval "$ac_compile") 2>conftest.er1
14041   ac_status=$?
14042   grep -v '^ *+' conftest.er1 >conftest.err
14043   rm -f conftest.er1
14044   cat conftest.err >&5
14045   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14046   (exit $ac_status); } && {
14047          test -z "$ac_c_werror_flag" ||
14048          test ! -s conftest.err
14049        } && test -s conftest.$ac_objext; then
14050   # It does; now see whether it defined to BIG_ENDIAN or not.
14051          cat >conftest.$ac_ext <<_ACEOF
14052 /* confdefs.h.  */
14053 _ACEOF
14054 cat confdefs.h >>conftest.$ac_ext
14055 cat >>conftest.$ac_ext <<_ACEOF
14056 /* end confdefs.h.  */
14057 #include <sys/types.h>
14058                 #include <sys/param.h>
14059
14060 int
14061 main ()
14062 {
14063 #if BYTE_ORDER != BIG_ENDIAN
14064                  not big endian
14065                 #endif
14066
14067   ;
14068   return 0;
14069 }
14070 _ACEOF
14071 rm -f conftest.$ac_objext
14072 if { (ac_try="$ac_compile"
14073 case "(($ac_try" in
14074   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14075   *) ac_try_echo=$ac_try;;
14076 esac
14077 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14078 $as_echo "$ac_try_echo") >&5
14079   (eval "$ac_compile") 2>conftest.er1
14080   ac_status=$?
14081   grep -v '^ *+' conftest.er1 >conftest.err
14082   rm -f conftest.er1
14083   cat conftest.err >&5
14084   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14085   (exit $ac_status); } && {
14086          test -z "$ac_c_werror_flag" ||
14087          test ! -s conftest.err
14088        } && test -s conftest.$ac_objext; then
14089   ac_cv_c_bigendian=yes
14090 else
14091   $as_echo "$as_me: failed program was:" >&5
14092 sed 's/^/| /' conftest.$ac_ext >&5
14093
14094         ac_cv_c_bigendian=no
14095 fi
14096
14097 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14098 else
14099   $as_echo "$as_me: failed program was:" >&5
14100 sed 's/^/| /' conftest.$ac_ext >&5
14101
14102
14103 fi
14104
14105 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14106     fi
14107     if test $ac_cv_c_bigendian = unknown; then
14108       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14109       cat >conftest.$ac_ext <<_ACEOF
14110 /* confdefs.h.  */
14111 _ACEOF
14112 cat confdefs.h >>conftest.$ac_ext
14113 cat >>conftest.$ac_ext <<_ACEOF
14114 /* end confdefs.h.  */
14115 #include <limits.h>
14116
14117 int
14118 main ()
14119 {
14120 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14121               bogus endian macros
14122              #endif
14123
14124   ;
14125   return 0;
14126 }
14127 _ACEOF
14128 rm -f conftest.$ac_objext
14129 if { (ac_try="$ac_compile"
14130 case "(($ac_try" in
14131   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14132   *) ac_try_echo=$ac_try;;
14133 esac
14134 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14135 $as_echo "$ac_try_echo") >&5
14136   (eval "$ac_compile") 2>conftest.er1
14137   ac_status=$?
14138   grep -v '^ *+' conftest.er1 >conftest.err
14139   rm -f conftest.er1
14140   cat conftest.err >&5
14141   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14142   (exit $ac_status); } && {
14143          test -z "$ac_c_werror_flag" ||
14144          test ! -s conftest.err
14145        } && test -s conftest.$ac_objext; then
14146   # It does; now see whether it defined to _BIG_ENDIAN or not.
14147          cat >conftest.$ac_ext <<_ACEOF
14148 /* confdefs.h.  */
14149 _ACEOF
14150 cat confdefs.h >>conftest.$ac_ext
14151 cat >>conftest.$ac_ext <<_ACEOF
14152 /* end confdefs.h.  */
14153 #include <limits.h>
14154
14155 int
14156 main ()
14157 {
14158 #ifndef _BIG_ENDIAN
14159                  not big endian
14160                 #endif
14161
14162   ;
14163   return 0;
14164 }
14165 _ACEOF
14166 rm -f conftest.$ac_objext
14167 if { (ac_try="$ac_compile"
14168 case "(($ac_try" in
14169   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14170   *) ac_try_echo=$ac_try;;
14171 esac
14172 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14173 $as_echo "$ac_try_echo") >&5
14174   (eval "$ac_compile") 2>conftest.er1
14175   ac_status=$?
14176   grep -v '^ *+' conftest.er1 >conftest.err
14177   rm -f conftest.er1
14178   cat conftest.err >&5
14179   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14180   (exit $ac_status); } && {
14181          test -z "$ac_c_werror_flag" ||
14182          test ! -s conftest.err
14183        } && test -s conftest.$ac_objext; then
14184   ac_cv_c_bigendian=yes
14185 else
14186   $as_echo "$as_me: failed program was:" >&5
14187 sed 's/^/| /' conftest.$ac_ext >&5
14188
14189         ac_cv_c_bigendian=no
14190 fi
14191
14192 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14193 else
14194   $as_echo "$as_me: failed program was:" >&5
14195 sed 's/^/| /' conftest.$ac_ext >&5
14196
14197
14198 fi
14199
14200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14201     fi
14202     if test $ac_cv_c_bigendian = unknown; then
14203       # Compile a test program.
14204       if test "$cross_compiling" = yes; then
14205   # Try to guess by grepping values from an object file.
14206          cat >conftest.$ac_ext <<_ACEOF
14207 /* confdefs.h.  */
14208 _ACEOF
14209 cat confdefs.h >>conftest.$ac_ext
14210 cat >>conftest.$ac_ext <<_ACEOF
14211 /* end confdefs.h.  */
14212 short int ascii_mm[] =
14213                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14214                 short int ascii_ii[] =
14215                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14216                 int use_ascii (int i) {
14217                   return ascii_mm[i] + ascii_ii[i];
14218                 }
14219                 short int ebcdic_ii[] =
14220                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14221                 short int ebcdic_mm[] =
14222                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14223                 int use_ebcdic (int i) {
14224                   return ebcdic_mm[i] + ebcdic_ii[i];
14225                 }
14226                 extern int foo;
14227
14228 int
14229 main ()
14230 {
14231 return use_ascii (foo) == use_ebcdic (foo);
14232   ;
14233   return 0;
14234 }
14235 _ACEOF
14236 rm -f conftest.$ac_objext
14237 if { (ac_try="$ac_compile"
14238 case "(($ac_try" in
14239   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14240   *) ac_try_echo=$ac_try;;
14241 esac
14242 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14243 $as_echo "$ac_try_echo") >&5
14244   (eval "$ac_compile") 2>conftest.er1
14245   ac_status=$?
14246   grep -v '^ *+' conftest.er1 >conftest.err
14247   rm -f conftest.er1
14248   cat conftest.err >&5
14249   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14250   (exit $ac_status); } && {
14251          test -z "$ac_c_werror_flag" ||
14252          test ! -s conftest.err
14253        } && test -s conftest.$ac_objext; then
14254   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14255               ac_cv_c_bigendian=yes
14256             fi
14257             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14258               if test "$ac_cv_c_bigendian" = unknown; then
14259                 ac_cv_c_bigendian=no
14260               else
14261                 # finding both strings is unlikely to happen, but who knows?
14262                 ac_cv_c_bigendian=unknown
14263               fi
14264             fi
14265 else
14266   $as_echo "$as_me: failed program was:" >&5
14267 sed 's/^/| /' conftest.$ac_ext >&5
14268
14269
14270 fi
14271
14272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14273 else
14274   cat >conftest.$ac_ext <<_ACEOF
14275 /* confdefs.h.  */
14276 _ACEOF
14277 cat confdefs.h >>conftest.$ac_ext
14278 cat >>conftest.$ac_ext <<_ACEOF
14279 /* end confdefs.h.  */
14280 $ac_includes_default
14281 int
14282 main ()
14283 {
14284
14285              /* Are we little or big endian?  From Harbison&Steele.  */
14286              union
14287              {
14288                long int l;
14289                char c[sizeof (long int)];
14290              } u;
14291              u.l = 1;
14292              return u.c[sizeof (long int) - 1] == 1;
14293
14294   ;
14295   return 0;
14296 }
14297 _ACEOF
14298 rm -f conftest$ac_exeext
14299 if { (ac_try="$ac_link"
14300 case "(($ac_try" in
14301   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14302   *) ac_try_echo=$ac_try;;
14303 esac
14304 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14305 $as_echo "$ac_try_echo") >&5
14306   (eval "$ac_link") 2>&5
14307   ac_status=$?
14308   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14309   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14310   { (case "(($ac_try" in
14311   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14312   *) ac_try_echo=$ac_try;;
14313 esac
14314 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14315 $as_echo "$ac_try_echo") >&5
14316   (eval "$ac_try") 2>&5
14317   ac_status=$?
14318   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14319   (exit $ac_status); }; }; then
14320   ac_cv_c_bigendian=no
14321 else
14322   $as_echo "$as_me: program exited with status $ac_status" >&5
14323 $as_echo "$as_me: failed program was:" >&5
14324 sed 's/^/| /' conftest.$ac_ext >&5
14325
14326 ( exit $ac_status )
14327 ac_cv_c_bigendian=yes
14328 fi
14329 rm -rf conftest.dSYM
14330 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14331 fi
14332
14333
14334     fi
14335 fi
14336 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14337 $as_echo "$ac_cv_c_bigendian" >&6; }
14338  case $ac_cv_c_bigendian in #(
14339    yes)
14340      cat >>confdefs.h <<\_ACEOF
14341 #define WORDS_BIGENDIAN 1
14342 _ACEOF
14343 ;; #(
14344    no)
14345       ;; #(
14346    universal)
14347
14348 cat >>confdefs.h <<\_ACEOF
14349 #define AC_APPLE_UNIVERSAL_BUILD 1
14350 _ACEOF
14351
14352      ;; #(
14353    *)
14354      { { $as_echo "$as_me:$LINENO: error: unknown endianness
14355  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14356 $as_echo "$as_me: error: unknown endianness
14357  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14358    { (exit 1); exit 1; }; } ;;
14359  esac
14360
14361 { $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14362 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14363 if test "${ac_cv_c_const+set}" = set; then
14364   $as_echo_n "(cached) " >&6
14365 else
14366   cat >conftest.$ac_ext <<_ACEOF
14367 /* confdefs.h.  */
14368 _ACEOF
14369 cat confdefs.h >>conftest.$ac_ext
14370 cat >>conftest.$ac_ext <<_ACEOF
14371 /* end confdefs.h.  */
14372
14373 int
14374 main ()
14375 {
14376 /* FIXME: Include the comments suggested by Paul. */
14377 #ifndef __cplusplus
14378   /* Ultrix mips cc rejects this.  */
14379   typedef int charset[2];
14380   const charset cs;
14381   /* SunOS 4.1.1 cc rejects this.  */
14382   char const *const *pcpcc;
14383   char **ppc;
14384   /* NEC SVR4.0.2 mips cc rejects this.  */
14385   struct point {int x, y;};
14386   static struct point const zero = {0,0};
14387   /* AIX XL C 1.02.0.0 rejects this.
14388      It does not let you subtract one const X* pointer from another in
14389      an arm of an if-expression whose if-part is not a constant
14390      expression */
14391   const char *g = "string";
14392   pcpcc = &g + (g ? g-g : 0);
14393   /* HPUX 7.0 cc rejects these. */
14394   ++pcpcc;
14395   ppc = (char**) pcpcc;
14396   pcpcc = (char const *const *) ppc;
14397   { /* SCO 3.2v4 cc rejects this.  */
14398     char *t;
14399     char const *s = 0 ? (char *) 0 : (char const *) 0;
14400
14401     *t++ = 0;
14402     if (s) return 0;
14403   }
14404   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14405     int x[] = {25, 17};
14406     const int *foo = &x[0];
14407     ++foo;
14408   }
14409   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14410     typedef const int *iptr;
14411     iptr p = 0;
14412     ++p;
14413   }
14414   { /* AIX XL C 1.02.0.0 rejects this saying
14415        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14416     struct s { int j; const int *ap[3]; };
14417     struct s *b; b->j = 5;
14418   }
14419   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14420     const int foo = 10;
14421     if (!foo) return 0;
14422   }
14423   return !cs[0] && !zero.x;
14424 #endif
14425
14426   ;
14427   return 0;
14428 }
14429 _ACEOF
14430 rm -f conftest.$ac_objext
14431 if { (ac_try="$ac_compile"
14432 case "(($ac_try" in
14433   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14434   *) ac_try_echo=$ac_try;;
14435 esac
14436 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14437 $as_echo "$ac_try_echo") >&5
14438   (eval "$ac_compile") 2>conftest.er1
14439   ac_status=$?
14440   grep -v '^ *+' conftest.er1 >conftest.err
14441   rm -f conftest.er1
14442   cat conftest.err >&5
14443   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14444   (exit $ac_status); } && {
14445          test -z "$ac_c_werror_flag" ||
14446          test ! -s conftest.err
14447        } && test -s conftest.$ac_objext; then
14448   ac_cv_c_const=yes
14449 else
14450   $as_echo "$as_me: failed program was:" >&5
14451 sed 's/^/| /' conftest.$ac_ext >&5
14452
14453         ac_cv_c_const=no
14454 fi
14455
14456 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14457 fi
14458 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14459 $as_echo "$ac_cv_c_const" >&6; }
14460 if test $ac_cv_c_const = no; then
14461
14462 cat >>confdefs.h <<\_ACEOF
14463 #define const /**/
14464 _ACEOF
14465
14466 fi
14467
14468 { $as_echo "$as_me:$LINENO: checking for inline" >&5
14469 $as_echo_n "checking for inline... " >&6; }
14470 if test "${ac_cv_c_inline+set}" = set; then
14471   $as_echo_n "(cached) " >&6
14472 else
14473   ac_cv_c_inline=no
14474 for ac_kw in inline __inline__ __inline; do
14475   cat >conftest.$ac_ext <<_ACEOF
14476 /* confdefs.h.  */
14477 _ACEOF
14478 cat confdefs.h >>conftest.$ac_ext
14479 cat >>conftest.$ac_ext <<_ACEOF
14480 /* end confdefs.h.  */
14481 #ifndef __cplusplus
14482 typedef int foo_t;
14483 static $ac_kw foo_t static_foo () {return 0; }
14484 $ac_kw foo_t foo () {return 0; }
14485 #endif
14486
14487 _ACEOF
14488 rm -f conftest.$ac_objext
14489 if { (ac_try="$ac_compile"
14490 case "(($ac_try" in
14491   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14492   *) ac_try_echo=$ac_try;;
14493 esac
14494 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14495 $as_echo "$ac_try_echo") >&5
14496   (eval "$ac_compile") 2>conftest.er1
14497   ac_status=$?
14498   grep -v '^ *+' conftest.er1 >conftest.err
14499   rm -f conftest.er1
14500   cat conftest.err >&5
14501   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14502   (exit $ac_status); } && {
14503          test -z "$ac_c_werror_flag" ||
14504          test ! -s conftest.err
14505        } && test -s conftest.$ac_objext; then
14506   ac_cv_c_inline=$ac_kw
14507 else
14508   $as_echo "$as_me: failed program was:" >&5
14509 sed 's/^/| /' conftest.$ac_ext >&5
14510
14511
14512 fi
14513
14514 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14515   test "$ac_cv_c_inline" != no && break
14516 done
14517
14518 fi
14519 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
14520 $as_echo "$ac_cv_c_inline" >&6; }
14521
14522
14523 case $ac_cv_c_inline in
14524   inline | yes) ;;
14525   *)
14526     case $ac_cv_c_inline in
14527       no) ac_val=;;
14528       *) ac_val=$ac_cv_c_inline;;
14529     esac
14530     cat >>confdefs.h <<_ACEOF
14531 #ifndef __cplusplus
14532 #define inline $ac_val
14533 #endif
14534 _ACEOF
14535     ;;
14536 esac
14537
14538 { $as_echo "$as_me:$LINENO: checking for quiet inline (no complaint if unreferenced)" >&5
14539 $as_echo_n "checking for quiet inline (no complaint if unreferenced)... " >&6; }
14540 if test "${pgac_cv_c_inline_quietly+set}" = set; then
14541   $as_echo_n "(cached) " >&6
14542 else
14543   pgac_cv_c_inline_quietly=no
14544   if test "$ac_cv_c_inline" != no; then
14545     pgac_c_inline_save_werror=$ac_c_werror_flag
14546     ac_c_werror_flag=yes
14547     cat >conftest.$ac_ext <<_ACEOF
14548 /* confdefs.h.  */
14549 _ACEOF
14550 cat confdefs.h >>conftest.$ac_ext
14551 cat >>conftest.$ac_ext <<_ACEOF
14552 /* end confdefs.h.  */
14553 static inline int fun () {return 0;}
14554 int
14555 main ()
14556 {
14557
14558   ;
14559   return 0;
14560 }
14561 _ACEOF
14562 rm -f conftest.$ac_objext conftest$ac_exeext
14563 if { (ac_try="$ac_link"
14564 case "(($ac_try" in
14565   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14566   *) ac_try_echo=$ac_try;;
14567 esac
14568 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14569 $as_echo "$ac_try_echo") >&5
14570   (eval "$ac_link") 2>conftest.er1
14571   ac_status=$?
14572   grep -v '^ *+' conftest.er1 >conftest.err
14573   rm -f conftest.er1
14574   cat conftest.err >&5
14575   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14576   (exit $ac_status); } && {
14577          test -z "$ac_c_werror_flag" ||
14578          test ! -s conftest.err
14579        } && test -s conftest$ac_exeext && {
14580          test "$cross_compiling" = yes ||
14581          $as_test_x conftest$ac_exeext
14582        }; then
14583   pgac_cv_c_inline_quietly=yes
14584 else
14585   $as_echo "$as_me: failed program was:" >&5
14586 sed 's/^/| /' conftest.$ac_ext >&5
14587
14588
14589 fi
14590
14591 rm -rf conftest.dSYM
14592 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14593       conftest$ac_exeext conftest.$ac_ext
14594     ac_c_werror_flag=$pgac_c_inline_save_werror
14595   fi
14596 fi
14597 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_inline_quietly" >&5
14598 $as_echo "$pgac_cv_c_inline_quietly" >&6; }
14599 if test "$pgac_cv_c_inline_quietly" != no; then
14600
14601 cat >>confdefs.h <<_ACEOF
14602 #define USE_INLINE 1
14603 _ACEOF
14604
14605 fi
14606
14607 { $as_echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
14608 $as_echo_n "checking for preprocessor stringizing operator... " >&6; }
14609 if test "${ac_cv_c_stringize+set}" = set; then
14610   $as_echo_n "(cached) " >&6
14611 else
14612   cat >conftest.$ac_ext <<_ACEOF
14613 /* confdefs.h.  */
14614 _ACEOF
14615 cat confdefs.h >>conftest.$ac_ext
14616 cat >>conftest.$ac_ext <<_ACEOF
14617 /* end confdefs.h.  */
14618 #define x(y) #y
14619
14620 char *s = x(teststring);
14621 _ACEOF
14622 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14623   $EGREP "#teststring" >/dev/null 2>&1; then
14624   ac_cv_c_stringize=no
14625 else
14626   ac_cv_c_stringize=yes
14627 fi
14628 rm -f conftest*
14629
14630 fi
14631 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
14632 $as_echo "$ac_cv_c_stringize" >&6; }
14633 if test $ac_cv_c_stringize = yes; then
14634
14635 cat >>confdefs.h <<\_ACEOF
14636 #define HAVE_STRINGIZE 1
14637 _ACEOF
14638
14639 fi
14640
14641 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
14642 $as_echo_n "checking for signed types... " >&6; }
14643 if test "${pgac_cv_c_signed+set}" = set; then
14644   $as_echo_n "(cached) " >&6
14645 else
14646   cat >conftest.$ac_ext <<_ACEOF
14647 /* confdefs.h.  */
14648 _ACEOF
14649 cat confdefs.h >>conftest.$ac_ext
14650 cat >>conftest.$ac_ext <<_ACEOF
14651 /* end confdefs.h.  */
14652
14653 int
14654 main ()
14655 {
14656 signed char c; signed short s; signed int i;
14657   ;
14658   return 0;
14659 }
14660 _ACEOF
14661 rm -f conftest.$ac_objext
14662 if { (ac_try="$ac_compile"
14663 case "(($ac_try" in
14664   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14665   *) ac_try_echo=$ac_try;;
14666 esac
14667 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14668 $as_echo "$ac_try_echo") >&5
14669   (eval "$ac_compile") 2>conftest.er1
14670   ac_status=$?
14671   grep -v '^ *+' conftest.er1 >conftest.err
14672   rm -f conftest.er1
14673   cat conftest.err >&5
14674   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14675   (exit $ac_status); } && {
14676          test -z "$ac_c_werror_flag" ||
14677          test ! -s conftest.err
14678        } && test -s conftest.$ac_objext; then
14679   pgac_cv_c_signed=yes
14680 else
14681   $as_echo "$as_me: failed program was:" >&5
14682 sed 's/^/| /' conftest.$ac_ext >&5
14683
14684         pgac_cv_c_signed=no
14685 fi
14686
14687 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14688 fi
14689 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
14690 $as_echo "$pgac_cv_c_signed" >&6; }
14691 if test x"$pgac_cv_c_signed" = xno ; then
14692
14693 cat >>confdefs.h <<\_ACEOF
14694 #define signed /**/
14695 _ACEOF
14696
14697 fi
14698 { $as_echo "$as_me:$LINENO: checking for working volatile" >&5
14699 $as_echo_n "checking for working volatile... " >&6; }
14700 if test "${ac_cv_c_volatile+set}" = set; then
14701   $as_echo_n "(cached) " >&6
14702 else
14703   cat >conftest.$ac_ext <<_ACEOF
14704 /* confdefs.h.  */
14705 _ACEOF
14706 cat confdefs.h >>conftest.$ac_ext
14707 cat >>conftest.$ac_ext <<_ACEOF
14708 /* end confdefs.h.  */
14709
14710 int
14711 main ()
14712 {
14713
14714 volatile int x;
14715 int * volatile y = (int *) 0;
14716 return !x && !y;
14717   ;
14718   return 0;
14719 }
14720 _ACEOF
14721 rm -f conftest.$ac_objext
14722 if { (ac_try="$ac_compile"
14723 case "(($ac_try" in
14724   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14725   *) ac_try_echo=$ac_try;;
14726 esac
14727 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14728 $as_echo "$ac_try_echo") >&5
14729   (eval "$ac_compile") 2>conftest.er1
14730   ac_status=$?
14731   grep -v '^ *+' conftest.er1 >conftest.err
14732   rm -f conftest.er1
14733   cat conftest.err >&5
14734   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14735   (exit $ac_status); } && {
14736          test -z "$ac_c_werror_flag" ||
14737          test ! -s conftest.err
14738        } && test -s conftest.$ac_objext; then
14739   ac_cv_c_volatile=yes
14740 else
14741   $as_echo "$as_me: failed program was:" >&5
14742 sed 's/^/| /' conftest.$ac_ext >&5
14743
14744         ac_cv_c_volatile=no
14745 fi
14746
14747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14748 fi
14749 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
14750 $as_echo "$ac_cv_c_volatile" >&6; }
14751 if test $ac_cv_c_volatile = no; then
14752
14753 cat >>confdefs.h <<\_ACEOF
14754 #define volatile /**/
14755 _ACEOF
14756
14757 fi
14758
14759 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
14760 $as_echo_n "checking for __func__... " >&6; }
14761 if test "${pgac_cv_funcname_func_support+set}" = set; then
14762   $as_echo_n "(cached) " >&6
14763 else
14764   cat >conftest.$ac_ext <<_ACEOF
14765 /* confdefs.h.  */
14766 _ACEOF
14767 cat confdefs.h >>conftest.$ac_ext
14768 cat >>conftest.$ac_ext <<_ACEOF
14769 /* end confdefs.h.  */
14770 #include <stdio.h>
14771 int
14772 main ()
14773 {
14774 printf("%s\n", __func__);
14775   ;
14776   return 0;
14777 }
14778 _ACEOF
14779 rm -f conftest.$ac_objext
14780 if { (ac_try="$ac_compile"
14781 case "(($ac_try" in
14782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14783   *) ac_try_echo=$ac_try;;
14784 esac
14785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14786 $as_echo "$ac_try_echo") >&5
14787   (eval "$ac_compile") 2>conftest.er1
14788   ac_status=$?
14789   grep -v '^ *+' conftest.er1 >conftest.err
14790   rm -f conftest.er1
14791   cat conftest.err >&5
14792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14793   (exit $ac_status); } && {
14794          test -z "$ac_c_werror_flag" ||
14795          test ! -s conftest.err
14796        } && test -s conftest.$ac_objext; then
14797   pgac_cv_funcname_func_support=yes
14798 else
14799   $as_echo "$as_me: failed program was:" >&5
14800 sed 's/^/| /' conftest.$ac_ext >&5
14801
14802         pgac_cv_funcname_func_support=no
14803 fi
14804
14805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14806 fi
14807 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
14808 $as_echo "$pgac_cv_funcname_func_support" >&6; }
14809 if test x"$pgac_cv_funcname_func_support" = xyes ; then
14810
14811 cat >>confdefs.h <<\_ACEOF
14812 #define HAVE_FUNCNAME__FUNC 1
14813 _ACEOF
14814
14815 else
14816 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
14817 $as_echo_n "checking for __FUNCTION__... " >&6; }
14818 if test "${pgac_cv_funcname_function_support+set}" = set; then
14819   $as_echo_n "(cached) " >&6
14820 else
14821   cat >conftest.$ac_ext <<_ACEOF
14822 /* confdefs.h.  */
14823 _ACEOF
14824 cat confdefs.h >>conftest.$ac_ext
14825 cat >>conftest.$ac_ext <<_ACEOF
14826 /* end confdefs.h.  */
14827 #include <stdio.h>
14828 int
14829 main ()
14830 {
14831 printf("%s\n", __FUNCTION__);
14832   ;
14833   return 0;
14834 }
14835 _ACEOF
14836 rm -f conftest.$ac_objext
14837 if { (ac_try="$ac_compile"
14838 case "(($ac_try" in
14839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14840   *) ac_try_echo=$ac_try;;
14841 esac
14842 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14843 $as_echo "$ac_try_echo") >&5
14844   (eval "$ac_compile") 2>conftest.er1
14845   ac_status=$?
14846   grep -v '^ *+' conftest.er1 >conftest.err
14847   rm -f conftest.er1
14848   cat conftest.err >&5
14849   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14850   (exit $ac_status); } && {
14851          test -z "$ac_c_werror_flag" ||
14852          test ! -s conftest.err
14853        } && test -s conftest.$ac_objext; then
14854   pgac_cv_funcname_function_support=yes
14855 else
14856   $as_echo "$as_me: failed program was:" >&5
14857 sed 's/^/| /' conftest.$ac_ext >&5
14858
14859         pgac_cv_funcname_function_support=no
14860 fi
14861
14862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14863 fi
14864 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
14865 $as_echo "$pgac_cv_funcname_function_support" >&6; }
14866 if test x"$pgac_cv_funcname_function_support" = xyes ; then
14867
14868 cat >>confdefs.h <<\_ACEOF
14869 #define HAVE_FUNCNAME__FUNCTION 1
14870 _ACEOF
14871
14872 fi
14873 fi
14874 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
14875 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
14876 if test "${ac_cv_struct_tm+set}" = set; then
14877   $as_echo_n "(cached) " >&6
14878 else
14879   cat >conftest.$ac_ext <<_ACEOF
14880 /* confdefs.h.  */
14881 _ACEOF
14882 cat confdefs.h >>conftest.$ac_ext
14883 cat >>conftest.$ac_ext <<_ACEOF
14884 /* end confdefs.h.  */
14885 #include <sys/types.h>
14886 #include <time.h>
14887
14888 int
14889 main ()
14890 {
14891 struct tm tm;
14892                                      int *p = &tm.tm_sec;
14893                                      return !p;
14894   ;
14895   return 0;
14896 }
14897 _ACEOF
14898 rm -f conftest.$ac_objext
14899 if { (ac_try="$ac_compile"
14900 case "(($ac_try" in
14901   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14902   *) ac_try_echo=$ac_try;;
14903 esac
14904 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14905 $as_echo "$ac_try_echo") >&5
14906   (eval "$ac_compile") 2>conftest.er1
14907   ac_status=$?
14908   grep -v '^ *+' conftest.er1 >conftest.err
14909   rm -f conftest.er1
14910   cat conftest.err >&5
14911   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14912   (exit $ac_status); } && {
14913          test -z "$ac_c_werror_flag" ||
14914          test ! -s conftest.err
14915        } && test -s conftest.$ac_objext; then
14916   ac_cv_struct_tm=time.h
14917 else
14918   $as_echo "$as_me: failed program was:" >&5
14919 sed 's/^/| /' conftest.$ac_ext >&5
14920
14921         ac_cv_struct_tm=sys/time.h
14922 fi
14923
14924 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14925 fi
14926 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
14927 $as_echo "$ac_cv_struct_tm" >&6; }
14928 if test $ac_cv_struct_tm = sys/time.h; then
14929
14930 cat >>confdefs.h <<\_ACEOF
14931 #define TM_IN_SYS_TIME 1
14932 _ACEOF
14933
14934 fi
14935
14936 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
14937 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
14938 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
14939   $as_echo_n "(cached) " >&6
14940 else
14941   cat >conftest.$ac_ext <<_ACEOF
14942 /* confdefs.h.  */
14943 _ACEOF
14944 cat confdefs.h >>conftest.$ac_ext
14945 cat >>conftest.$ac_ext <<_ACEOF
14946 /* end confdefs.h.  */
14947 #include <sys/types.h>
14948 #include <$ac_cv_struct_tm>
14949
14950
14951 int
14952 main ()
14953 {
14954 static struct tm ac_aggr;
14955 if (ac_aggr.tm_zone)
14956 return 0;
14957   ;
14958   return 0;
14959 }
14960 _ACEOF
14961 rm -f conftest.$ac_objext
14962 if { (ac_try="$ac_compile"
14963 case "(($ac_try" in
14964   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14965   *) ac_try_echo=$ac_try;;
14966 esac
14967 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14968 $as_echo "$ac_try_echo") >&5
14969   (eval "$ac_compile") 2>conftest.er1
14970   ac_status=$?
14971   grep -v '^ *+' conftest.er1 >conftest.err
14972   rm -f conftest.er1
14973   cat conftest.err >&5
14974   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14975   (exit $ac_status); } && {
14976          test -z "$ac_c_werror_flag" ||
14977          test ! -s conftest.err
14978        } && test -s conftest.$ac_objext; then
14979   ac_cv_member_struct_tm_tm_zone=yes
14980 else
14981   $as_echo "$as_me: failed program was:" >&5
14982 sed 's/^/| /' conftest.$ac_ext >&5
14983
14984         cat >conftest.$ac_ext <<_ACEOF
14985 /* confdefs.h.  */
14986 _ACEOF
14987 cat confdefs.h >>conftest.$ac_ext
14988 cat >>conftest.$ac_ext <<_ACEOF
14989 /* end confdefs.h.  */
14990 #include <sys/types.h>
14991 #include <$ac_cv_struct_tm>
14992
14993
14994 int
14995 main ()
14996 {
14997 static struct tm ac_aggr;
14998 if (sizeof ac_aggr.tm_zone)
14999 return 0;
15000   ;
15001   return 0;
15002 }
15003 _ACEOF
15004 rm -f conftest.$ac_objext
15005 if { (ac_try="$ac_compile"
15006 case "(($ac_try" in
15007   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15008   *) ac_try_echo=$ac_try;;
15009 esac
15010 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15011 $as_echo "$ac_try_echo") >&5
15012   (eval "$ac_compile") 2>conftest.er1
15013   ac_status=$?
15014   grep -v '^ *+' conftest.er1 >conftest.err
15015   rm -f conftest.er1
15016   cat conftest.err >&5
15017   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15018   (exit $ac_status); } && {
15019          test -z "$ac_c_werror_flag" ||
15020          test ! -s conftest.err
15021        } && test -s conftest.$ac_objext; then
15022   ac_cv_member_struct_tm_tm_zone=yes
15023 else
15024   $as_echo "$as_me: failed program was:" >&5
15025 sed 's/^/| /' conftest.$ac_ext >&5
15026
15027         ac_cv_member_struct_tm_tm_zone=no
15028 fi
15029
15030 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15031 fi
15032
15033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15034 fi
15035 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
15036 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
15037 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
15038
15039 cat >>confdefs.h <<_ACEOF
15040 #define HAVE_STRUCT_TM_TM_ZONE 1
15041 _ACEOF
15042
15043
15044 fi
15045
15046 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15047
15048 cat >>confdefs.h <<\_ACEOF
15049 #define HAVE_TM_ZONE 1
15050 _ACEOF
15051
15052 fi
15053 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
15054 $as_echo_n "checking for tzname... " >&6; }
15055 if test "${ac_cv_var_tzname+set}" = set; then
15056   $as_echo_n "(cached) " >&6
15057 else
15058   cat >conftest.$ac_ext <<_ACEOF
15059 /* confdefs.h.  */
15060 _ACEOF
15061 cat confdefs.h >>conftest.$ac_ext
15062 cat >>conftest.$ac_ext <<_ACEOF
15063 /* end confdefs.h.  */
15064 #include <time.h>
15065 #ifndef tzname /* For SGI.  */
15066 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
15067 #endif
15068
15069 int
15070 main ()
15071 {
15072 atoi(*tzname);
15073   ;
15074   return 0;
15075 }
15076 _ACEOF
15077 rm -f conftest.$ac_objext conftest$ac_exeext
15078 if { (ac_try="$ac_link"
15079 case "(($ac_try" in
15080   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15081   *) ac_try_echo=$ac_try;;
15082 esac
15083 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15084 $as_echo "$ac_try_echo") >&5
15085   (eval "$ac_link") 2>conftest.er1
15086   ac_status=$?
15087   grep -v '^ *+' conftest.er1 >conftest.err
15088   rm -f conftest.er1
15089   cat conftest.err >&5
15090   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15091   (exit $ac_status); } && {
15092          test -z "$ac_c_werror_flag" ||
15093          test ! -s conftest.err
15094        } && test -s conftest$ac_exeext && {
15095          test "$cross_compiling" = yes ||
15096          $as_test_x conftest$ac_exeext
15097        }; then
15098   ac_cv_var_tzname=yes
15099 else
15100   $as_echo "$as_me: failed program was:" >&5
15101 sed 's/^/| /' conftest.$ac_ext >&5
15102
15103         ac_cv_var_tzname=no
15104 fi
15105
15106 rm -rf conftest.dSYM
15107 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15108       conftest$ac_exeext conftest.$ac_ext
15109 fi
15110 { $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
15111 $as_echo "$ac_cv_var_tzname" >&6; }
15112 if test $ac_cv_var_tzname = yes; then
15113
15114 cat >>confdefs.h <<\_ACEOF
15115 #define HAVE_TZNAME 1
15116 _ACEOF
15117
15118 fi
15119
15120 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
15121 $as_echo_n "checking for union semun... " >&6; }
15122 if test "${ac_cv_type_union_semun+set}" = set; then
15123   $as_echo_n "(cached) " >&6
15124 else
15125   ac_cv_type_union_semun=no
15126 cat >conftest.$ac_ext <<_ACEOF
15127 /* confdefs.h.  */
15128 _ACEOF
15129 cat confdefs.h >>conftest.$ac_ext
15130 cat >>conftest.$ac_ext <<_ACEOF
15131 /* end confdefs.h.  */
15132 #include <sys/types.h>
15133 #include <sys/ipc.h>
15134 #include <sys/sem.h>
15135
15136 int
15137 main ()
15138 {
15139 if (sizeof (union semun))
15140        return 0;
15141   ;
15142   return 0;
15143 }
15144 _ACEOF
15145 rm -f conftest.$ac_objext
15146 if { (ac_try="$ac_compile"
15147 case "(($ac_try" in
15148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15149   *) ac_try_echo=$ac_try;;
15150 esac
15151 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15152 $as_echo "$ac_try_echo") >&5
15153   (eval "$ac_compile") 2>conftest.er1
15154   ac_status=$?
15155   grep -v '^ *+' conftest.er1 >conftest.err
15156   rm -f conftest.er1
15157   cat conftest.err >&5
15158   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15159   (exit $ac_status); } && {
15160          test -z "$ac_c_werror_flag" ||
15161          test ! -s conftest.err
15162        } && test -s conftest.$ac_objext; then
15163   cat >conftest.$ac_ext <<_ACEOF
15164 /* confdefs.h.  */
15165 _ACEOF
15166 cat confdefs.h >>conftest.$ac_ext
15167 cat >>conftest.$ac_ext <<_ACEOF
15168 /* end confdefs.h.  */
15169 #include <sys/types.h>
15170 #include <sys/ipc.h>
15171 #include <sys/sem.h>
15172
15173 int
15174 main ()
15175 {
15176 if (sizeof ((union semun)))
15177           return 0;
15178   ;
15179   return 0;
15180 }
15181 _ACEOF
15182 rm -f conftest.$ac_objext
15183 if { (ac_try="$ac_compile"
15184 case "(($ac_try" in
15185   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15186   *) ac_try_echo=$ac_try;;
15187 esac
15188 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15189 $as_echo "$ac_try_echo") >&5
15190   (eval "$ac_compile") 2>conftest.er1
15191   ac_status=$?
15192   grep -v '^ *+' conftest.er1 >conftest.err
15193   rm -f conftest.er1
15194   cat conftest.err >&5
15195   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15196   (exit $ac_status); } && {
15197          test -z "$ac_c_werror_flag" ||
15198          test ! -s conftest.err
15199        } && test -s conftest.$ac_objext; then
15200   :
15201 else
15202   $as_echo "$as_me: failed program was:" >&5
15203 sed 's/^/| /' conftest.$ac_ext >&5
15204
15205         ac_cv_type_union_semun=yes
15206 fi
15207
15208 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15209 else
15210   $as_echo "$as_me: failed program was:" >&5
15211 sed 's/^/| /' conftest.$ac_ext >&5
15212
15213
15214 fi
15215
15216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15217 fi
15218 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
15219 $as_echo "$ac_cv_type_union_semun" >&6; }
15220 if test "x$ac_cv_type_union_semun" = x""yes; then
15221
15222 cat >>confdefs.h <<_ACEOF
15223 #define HAVE_UNION_SEMUN 1
15224 _ACEOF
15225
15226
15227 fi
15228
15229 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
15230 $as_echo_n "checking for struct sockaddr_un... " >&6; }
15231 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
15232   $as_echo_n "(cached) " >&6
15233 else
15234   ac_cv_type_struct_sockaddr_un=no
15235 cat >conftest.$ac_ext <<_ACEOF
15236 /* confdefs.h.  */
15237 _ACEOF
15238 cat confdefs.h >>conftest.$ac_ext
15239 cat >>conftest.$ac_ext <<_ACEOF
15240 /* end confdefs.h.  */
15241 #include <sys/types.h>
15242 #ifdef HAVE_SYS_UN_H
15243 #include <sys/un.h>
15244 #endif
15245
15246
15247 int
15248 main ()
15249 {
15250 if (sizeof (struct sockaddr_un))
15251        return 0;
15252   ;
15253   return 0;
15254 }
15255 _ACEOF
15256 rm -f conftest.$ac_objext
15257 if { (ac_try="$ac_compile"
15258 case "(($ac_try" in
15259   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15260   *) ac_try_echo=$ac_try;;
15261 esac
15262 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15263 $as_echo "$ac_try_echo") >&5
15264   (eval "$ac_compile") 2>conftest.er1
15265   ac_status=$?
15266   grep -v '^ *+' conftest.er1 >conftest.err
15267   rm -f conftest.er1
15268   cat conftest.err >&5
15269   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15270   (exit $ac_status); } && {
15271          test -z "$ac_c_werror_flag" ||
15272          test ! -s conftest.err
15273        } && test -s conftest.$ac_objext; then
15274   cat >conftest.$ac_ext <<_ACEOF
15275 /* confdefs.h.  */
15276 _ACEOF
15277 cat confdefs.h >>conftest.$ac_ext
15278 cat >>conftest.$ac_ext <<_ACEOF
15279 /* end confdefs.h.  */
15280 #include <sys/types.h>
15281 #ifdef HAVE_SYS_UN_H
15282 #include <sys/un.h>
15283 #endif
15284
15285
15286 int
15287 main ()
15288 {
15289 if (sizeof ((struct sockaddr_un)))
15290           return 0;
15291   ;
15292   return 0;
15293 }
15294 _ACEOF
15295 rm -f conftest.$ac_objext
15296 if { (ac_try="$ac_compile"
15297 case "(($ac_try" in
15298   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15299   *) ac_try_echo=$ac_try;;
15300 esac
15301 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15302 $as_echo "$ac_try_echo") >&5
15303   (eval "$ac_compile") 2>conftest.er1
15304   ac_status=$?
15305   grep -v '^ *+' conftest.er1 >conftest.err
15306   rm -f conftest.er1
15307   cat conftest.err >&5
15308   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15309   (exit $ac_status); } && {
15310          test -z "$ac_c_werror_flag" ||
15311          test ! -s conftest.err
15312        } && test -s conftest.$ac_objext; then
15313   :
15314 else
15315   $as_echo "$as_me: failed program was:" >&5
15316 sed 's/^/| /' conftest.$ac_ext >&5
15317
15318         ac_cv_type_struct_sockaddr_un=yes
15319 fi
15320
15321 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15322 else
15323   $as_echo "$as_me: failed program was:" >&5
15324 sed 's/^/| /' conftest.$ac_ext >&5
15325
15326
15327 fi
15328
15329 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15330 fi
15331 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
15332 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
15333 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
15334
15335 cat >>confdefs.h <<_ACEOF
15336 #define HAVE_STRUCT_SOCKADDR_UN 1
15337 _ACEOF
15338
15339
15340 cat >>confdefs.h <<\_ACEOF
15341 #define HAVE_UNIX_SOCKETS 1
15342 _ACEOF
15343
15344 fi
15345
15346 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
15347 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
15348 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
15349   $as_echo_n "(cached) " >&6
15350 else
15351   ac_cv_type_struct_sockaddr_storage=no
15352 cat >conftest.$ac_ext <<_ACEOF
15353 /* confdefs.h.  */
15354 _ACEOF
15355 cat confdefs.h >>conftest.$ac_ext
15356 cat >>conftest.$ac_ext <<_ACEOF
15357 /* end confdefs.h.  */
15358 #include <sys/types.h>
15359 #ifdef HAVE_SYS_SOCKET_H
15360 #include <sys/socket.h>
15361 #endif
15362
15363
15364 int
15365 main ()
15366 {
15367 if (sizeof (struct sockaddr_storage))
15368        return 0;
15369   ;
15370   return 0;
15371 }
15372 _ACEOF
15373 rm -f conftest.$ac_objext
15374 if { (ac_try="$ac_compile"
15375 case "(($ac_try" in
15376   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15377   *) ac_try_echo=$ac_try;;
15378 esac
15379 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15380 $as_echo "$ac_try_echo") >&5
15381   (eval "$ac_compile") 2>conftest.er1
15382   ac_status=$?
15383   grep -v '^ *+' conftest.er1 >conftest.err
15384   rm -f conftest.er1
15385   cat conftest.err >&5
15386   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15387   (exit $ac_status); } && {
15388          test -z "$ac_c_werror_flag" ||
15389          test ! -s conftest.err
15390        } && test -s conftest.$ac_objext; then
15391   cat >conftest.$ac_ext <<_ACEOF
15392 /* confdefs.h.  */
15393 _ACEOF
15394 cat confdefs.h >>conftest.$ac_ext
15395 cat >>conftest.$ac_ext <<_ACEOF
15396 /* end confdefs.h.  */
15397 #include <sys/types.h>
15398 #ifdef HAVE_SYS_SOCKET_H
15399 #include <sys/socket.h>
15400 #endif
15401
15402
15403 int
15404 main ()
15405 {
15406 if (sizeof ((struct sockaddr_storage)))
15407           return 0;
15408   ;
15409   return 0;
15410 }
15411 _ACEOF
15412 rm -f conftest.$ac_objext
15413 if { (ac_try="$ac_compile"
15414 case "(($ac_try" in
15415   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15416   *) ac_try_echo=$ac_try;;
15417 esac
15418 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15419 $as_echo "$ac_try_echo") >&5
15420   (eval "$ac_compile") 2>conftest.er1
15421   ac_status=$?
15422   grep -v '^ *+' conftest.er1 >conftest.err
15423   rm -f conftest.er1
15424   cat conftest.err >&5
15425   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15426   (exit $ac_status); } && {
15427          test -z "$ac_c_werror_flag" ||
15428          test ! -s conftest.err
15429        } && test -s conftest.$ac_objext; then
15430   :
15431 else
15432   $as_echo "$as_me: failed program was:" >&5
15433 sed 's/^/| /' conftest.$ac_ext >&5
15434
15435         ac_cv_type_struct_sockaddr_storage=yes
15436 fi
15437
15438 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15439 else
15440   $as_echo "$as_me: failed program was:" >&5
15441 sed 's/^/| /' conftest.$ac_ext >&5
15442
15443
15444 fi
15445
15446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15447 fi
15448 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
15449 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
15450 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
15451
15452 cat >>confdefs.h <<_ACEOF
15453 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
15454 _ACEOF
15455
15456
15457 fi
15458
15459 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
15460 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
15461 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
15462   $as_echo_n "(cached) " >&6
15463 else
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_SOCKET_H
15472 #include <sys/socket.h>
15473 #endif
15474
15475
15476 int
15477 main ()
15478 {
15479 static struct sockaddr_storage ac_aggr;
15480 if (ac_aggr.ss_family)
15481 return 0;
15482   ;
15483   return 0;
15484 }
15485 _ACEOF
15486 rm -f conftest.$ac_objext
15487 if { (ac_try="$ac_compile"
15488 case "(($ac_try" in
15489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15490   *) ac_try_echo=$ac_try;;
15491 esac
15492 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15493 $as_echo "$ac_try_echo") >&5
15494   (eval "$ac_compile") 2>conftest.er1
15495   ac_status=$?
15496   grep -v '^ *+' conftest.er1 >conftest.err
15497   rm -f conftest.er1
15498   cat conftest.err >&5
15499   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15500   (exit $ac_status); } && {
15501          test -z "$ac_c_werror_flag" ||
15502          test ! -s conftest.err
15503        } && test -s conftest.$ac_objext; then
15504   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15505 else
15506   $as_echo "$as_me: failed program was:" >&5
15507 sed 's/^/| /' conftest.$ac_ext >&5
15508
15509         cat >conftest.$ac_ext <<_ACEOF
15510 /* confdefs.h.  */
15511 _ACEOF
15512 cat confdefs.h >>conftest.$ac_ext
15513 cat >>conftest.$ac_ext <<_ACEOF
15514 /* end confdefs.h.  */
15515 #include <sys/types.h>
15516 #ifdef HAVE_SYS_SOCKET_H
15517 #include <sys/socket.h>
15518 #endif
15519
15520
15521 int
15522 main ()
15523 {
15524 static struct sockaddr_storage ac_aggr;
15525 if (sizeof ac_aggr.ss_family)
15526 return 0;
15527   ;
15528   return 0;
15529 }
15530 _ACEOF
15531 rm -f conftest.$ac_objext
15532 if { (ac_try="$ac_compile"
15533 case "(($ac_try" in
15534   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15535   *) ac_try_echo=$ac_try;;
15536 esac
15537 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15538 $as_echo "$ac_try_echo") >&5
15539   (eval "$ac_compile") 2>conftest.er1
15540   ac_status=$?
15541   grep -v '^ *+' conftest.er1 >conftest.err
15542   rm -f conftest.er1
15543   cat conftest.err >&5
15544   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15545   (exit $ac_status); } && {
15546          test -z "$ac_c_werror_flag" ||
15547          test ! -s conftest.err
15548        } && test -s conftest.$ac_objext; then
15549   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15550 else
15551   $as_echo "$as_me: failed program was:" >&5
15552 sed 's/^/| /' conftest.$ac_ext >&5
15553
15554         ac_cv_member_struct_sockaddr_storage_ss_family=no
15555 fi
15556
15557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15558 fi
15559
15560 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15561 fi
15562 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
15563 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
15564 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
15565
15566 cat >>confdefs.h <<_ACEOF
15567 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
15568 _ACEOF
15569
15570
15571 fi
15572 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
15573 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
15574 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
15575   $as_echo_n "(cached) " >&6
15576 else
15577   cat >conftest.$ac_ext <<_ACEOF
15578 /* confdefs.h.  */
15579 _ACEOF
15580 cat confdefs.h >>conftest.$ac_ext
15581 cat >>conftest.$ac_ext <<_ACEOF
15582 /* end confdefs.h.  */
15583 #include <sys/types.h>
15584 #ifdef HAVE_SYS_SOCKET_H
15585 #include <sys/socket.h>
15586 #endif
15587
15588
15589 int
15590 main ()
15591 {
15592 static struct sockaddr_storage ac_aggr;
15593 if (ac_aggr.__ss_family)
15594 return 0;
15595   ;
15596   return 0;
15597 }
15598 _ACEOF
15599 rm -f conftest.$ac_objext
15600 if { (ac_try="$ac_compile"
15601 case "(($ac_try" in
15602   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15603   *) ac_try_echo=$ac_try;;
15604 esac
15605 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15606 $as_echo "$ac_try_echo") >&5
15607   (eval "$ac_compile") 2>conftest.er1
15608   ac_status=$?
15609   grep -v '^ *+' conftest.er1 >conftest.err
15610   rm -f conftest.er1
15611   cat conftest.err >&5
15612   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15613   (exit $ac_status); } && {
15614          test -z "$ac_c_werror_flag" ||
15615          test ! -s conftest.err
15616        } && test -s conftest.$ac_objext; then
15617   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15618 else
15619   $as_echo "$as_me: failed program was:" >&5
15620 sed 's/^/| /' conftest.$ac_ext >&5
15621
15622         cat >conftest.$ac_ext <<_ACEOF
15623 /* confdefs.h.  */
15624 _ACEOF
15625 cat confdefs.h >>conftest.$ac_ext
15626 cat >>conftest.$ac_ext <<_ACEOF
15627 /* end confdefs.h.  */
15628 #include <sys/types.h>
15629 #ifdef HAVE_SYS_SOCKET_H
15630 #include <sys/socket.h>
15631 #endif
15632
15633
15634 int
15635 main ()
15636 {
15637 static struct sockaddr_storage ac_aggr;
15638 if (sizeof ac_aggr.__ss_family)
15639 return 0;
15640   ;
15641   return 0;
15642 }
15643 _ACEOF
15644 rm -f conftest.$ac_objext
15645 if { (ac_try="$ac_compile"
15646 case "(($ac_try" in
15647   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15648   *) ac_try_echo=$ac_try;;
15649 esac
15650 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15651 $as_echo "$ac_try_echo") >&5
15652   (eval "$ac_compile") 2>conftest.er1
15653   ac_status=$?
15654   grep -v '^ *+' conftest.er1 >conftest.err
15655   rm -f conftest.er1
15656   cat conftest.err >&5
15657   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15658   (exit $ac_status); } && {
15659          test -z "$ac_c_werror_flag" ||
15660          test ! -s conftest.err
15661        } && test -s conftest.$ac_objext; then
15662   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15663 else
15664   $as_echo "$as_me: failed program was:" >&5
15665 sed 's/^/| /' conftest.$ac_ext >&5
15666
15667         ac_cv_member_struct_sockaddr_storage___ss_family=no
15668 fi
15669
15670 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15671 fi
15672
15673 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15674 fi
15675 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
15676 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
15677 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
15678
15679 cat >>confdefs.h <<_ACEOF
15680 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
15681 _ACEOF
15682
15683
15684 fi
15685 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
15686 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
15687 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
15688   $as_echo_n "(cached) " >&6
15689 else
15690   cat >conftest.$ac_ext <<_ACEOF
15691 /* confdefs.h.  */
15692 _ACEOF
15693 cat confdefs.h >>conftest.$ac_ext
15694 cat >>conftest.$ac_ext <<_ACEOF
15695 /* end confdefs.h.  */
15696 #include <sys/types.h>
15697 #ifdef HAVE_SYS_SOCKET_H
15698 #include <sys/socket.h>
15699 #endif
15700
15701
15702 int
15703 main ()
15704 {
15705 static struct sockaddr_storage ac_aggr;
15706 if (ac_aggr.ss_len)
15707 return 0;
15708   ;
15709   return 0;
15710 }
15711 _ACEOF
15712 rm -f conftest.$ac_objext
15713 if { (ac_try="$ac_compile"
15714 case "(($ac_try" in
15715   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15716   *) ac_try_echo=$ac_try;;
15717 esac
15718 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15719 $as_echo "$ac_try_echo") >&5
15720   (eval "$ac_compile") 2>conftest.er1
15721   ac_status=$?
15722   grep -v '^ *+' conftest.er1 >conftest.err
15723   rm -f conftest.er1
15724   cat conftest.err >&5
15725   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15726   (exit $ac_status); } && {
15727          test -z "$ac_c_werror_flag" ||
15728          test ! -s conftest.err
15729        } && test -s conftest.$ac_objext; then
15730   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15731 else
15732   $as_echo "$as_me: failed program was:" >&5
15733 sed 's/^/| /' conftest.$ac_ext >&5
15734
15735         cat >conftest.$ac_ext <<_ACEOF
15736 /* confdefs.h.  */
15737 _ACEOF
15738 cat confdefs.h >>conftest.$ac_ext
15739 cat >>conftest.$ac_ext <<_ACEOF
15740 /* end confdefs.h.  */
15741 #include <sys/types.h>
15742 #ifdef HAVE_SYS_SOCKET_H
15743 #include <sys/socket.h>
15744 #endif
15745
15746
15747 int
15748 main ()
15749 {
15750 static struct sockaddr_storage ac_aggr;
15751 if (sizeof ac_aggr.ss_len)
15752 return 0;
15753   ;
15754   return 0;
15755 }
15756 _ACEOF
15757 rm -f conftest.$ac_objext
15758 if { (ac_try="$ac_compile"
15759 case "(($ac_try" in
15760   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15761   *) ac_try_echo=$ac_try;;
15762 esac
15763 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15764 $as_echo "$ac_try_echo") >&5
15765   (eval "$ac_compile") 2>conftest.er1
15766   ac_status=$?
15767   grep -v '^ *+' conftest.er1 >conftest.err
15768   rm -f conftest.er1
15769   cat conftest.err >&5
15770   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15771   (exit $ac_status); } && {
15772          test -z "$ac_c_werror_flag" ||
15773          test ! -s conftest.err
15774        } && test -s conftest.$ac_objext; then
15775   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15776 else
15777   $as_echo "$as_me: failed program was:" >&5
15778 sed 's/^/| /' conftest.$ac_ext >&5
15779
15780         ac_cv_member_struct_sockaddr_storage_ss_len=no
15781 fi
15782
15783 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15784 fi
15785
15786 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15787 fi
15788 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
15789 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
15790 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
15791
15792 cat >>confdefs.h <<_ACEOF
15793 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
15794 _ACEOF
15795
15796
15797 fi
15798 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
15799 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
15800 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
15801   $as_echo_n "(cached) " >&6
15802 else
15803   cat >conftest.$ac_ext <<_ACEOF
15804 /* confdefs.h.  */
15805 _ACEOF
15806 cat confdefs.h >>conftest.$ac_ext
15807 cat >>conftest.$ac_ext <<_ACEOF
15808 /* end confdefs.h.  */
15809 #include <sys/types.h>
15810 #ifdef HAVE_SYS_SOCKET_H
15811 #include <sys/socket.h>
15812 #endif
15813
15814
15815 int
15816 main ()
15817 {
15818 static struct sockaddr_storage ac_aggr;
15819 if (ac_aggr.__ss_len)
15820 return 0;
15821   ;
15822   return 0;
15823 }
15824 _ACEOF
15825 rm -f conftest.$ac_objext
15826 if { (ac_try="$ac_compile"
15827 case "(($ac_try" in
15828   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15829   *) ac_try_echo=$ac_try;;
15830 esac
15831 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15832 $as_echo "$ac_try_echo") >&5
15833   (eval "$ac_compile") 2>conftest.er1
15834   ac_status=$?
15835   grep -v '^ *+' conftest.er1 >conftest.err
15836   rm -f conftest.er1
15837   cat conftest.err >&5
15838   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15839   (exit $ac_status); } && {
15840          test -z "$ac_c_werror_flag" ||
15841          test ! -s conftest.err
15842        } && test -s conftest.$ac_objext; then
15843   ac_cv_member_struct_sockaddr_storage___ss_len=yes
15844 else
15845   $as_echo "$as_me: failed program was:" >&5
15846 sed 's/^/| /' conftest.$ac_ext >&5
15847
15848         cat >conftest.$ac_ext <<_ACEOF
15849 /* confdefs.h.  */
15850 _ACEOF
15851 cat confdefs.h >>conftest.$ac_ext
15852 cat >>conftest.$ac_ext <<_ACEOF
15853 /* end confdefs.h.  */
15854 #include <sys/types.h>
15855 #ifdef HAVE_SYS_SOCKET_H
15856 #include <sys/socket.h>
15857 #endif
15858
15859
15860 int
15861 main ()
15862 {
15863 static struct sockaddr_storage ac_aggr;
15864 if (sizeof ac_aggr.__ss_len)
15865 return 0;
15866   ;
15867   return 0;
15868 }
15869 _ACEOF
15870 rm -f conftest.$ac_objext
15871 if { (ac_try="$ac_compile"
15872 case "(($ac_try" in
15873   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15874   *) ac_try_echo=$ac_try;;
15875 esac
15876 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15877 $as_echo "$ac_try_echo") >&5
15878   (eval "$ac_compile") 2>conftest.er1
15879   ac_status=$?
15880   grep -v '^ *+' conftest.er1 >conftest.err
15881   rm -f conftest.er1
15882   cat conftest.err >&5
15883   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15884   (exit $ac_status); } && {
15885          test -z "$ac_c_werror_flag" ||
15886          test ! -s conftest.err
15887        } && test -s conftest.$ac_objext; then
15888   ac_cv_member_struct_sockaddr_storage___ss_len=yes
15889 else
15890   $as_echo "$as_me: failed program was:" >&5
15891 sed 's/^/| /' conftest.$ac_ext >&5
15892
15893         ac_cv_member_struct_sockaddr_storage___ss_len=no
15894 fi
15895
15896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15897 fi
15898
15899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15900 fi
15901 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
15902 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
15903 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
15904
15905 cat >>confdefs.h <<_ACEOF
15906 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
15907 _ACEOF
15908
15909
15910 fi
15911 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
15912 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
15913 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
15914   $as_echo_n "(cached) " >&6
15915 else
15916   cat >conftest.$ac_ext <<_ACEOF
15917 /* confdefs.h.  */
15918 _ACEOF
15919 cat confdefs.h >>conftest.$ac_ext
15920 cat >>conftest.$ac_ext <<_ACEOF
15921 /* end confdefs.h.  */
15922 #include <sys/types.h>
15923 #ifdef HAVE_SYS_SOCKET_H
15924 #include <sys/socket.h>
15925 #endif
15926
15927
15928 int
15929 main ()
15930 {
15931 static struct sockaddr ac_aggr;
15932 if (ac_aggr.sa_len)
15933 return 0;
15934   ;
15935   return 0;
15936 }
15937 _ACEOF
15938 rm -f conftest.$ac_objext
15939 if { (ac_try="$ac_compile"
15940 case "(($ac_try" in
15941   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15942   *) ac_try_echo=$ac_try;;
15943 esac
15944 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15945 $as_echo "$ac_try_echo") >&5
15946   (eval "$ac_compile") 2>conftest.er1
15947   ac_status=$?
15948   grep -v '^ *+' conftest.er1 >conftest.err
15949   rm -f conftest.er1
15950   cat conftest.err >&5
15951   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15952   (exit $ac_status); } && {
15953          test -z "$ac_c_werror_flag" ||
15954          test ! -s conftest.err
15955        } && test -s conftest.$ac_objext; then
15956   ac_cv_member_struct_sockaddr_sa_len=yes
15957 else
15958   $as_echo "$as_me: failed program was:" >&5
15959 sed 's/^/| /' conftest.$ac_ext >&5
15960
15961         cat >conftest.$ac_ext <<_ACEOF
15962 /* confdefs.h.  */
15963 _ACEOF
15964 cat confdefs.h >>conftest.$ac_ext
15965 cat >>conftest.$ac_ext <<_ACEOF
15966 /* end confdefs.h.  */
15967 #include <sys/types.h>
15968 #ifdef HAVE_SYS_SOCKET_H
15969 #include <sys/socket.h>
15970 #endif
15971
15972
15973 int
15974 main ()
15975 {
15976 static struct sockaddr ac_aggr;
15977 if (sizeof ac_aggr.sa_len)
15978 return 0;
15979   ;
15980   return 0;
15981 }
15982 _ACEOF
15983 rm -f conftest.$ac_objext
15984 if { (ac_try="$ac_compile"
15985 case "(($ac_try" in
15986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15987   *) ac_try_echo=$ac_try;;
15988 esac
15989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15990 $as_echo "$ac_try_echo") >&5
15991   (eval "$ac_compile") 2>conftest.er1
15992   ac_status=$?
15993   grep -v '^ *+' conftest.er1 >conftest.err
15994   rm -f conftest.er1
15995   cat conftest.err >&5
15996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15997   (exit $ac_status); } && {
15998          test -z "$ac_c_werror_flag" ||
15999          test ! -s conftest.err
16000        } && test -s conftest.$ac_objext; then
16001   ac_cv_member_struct_sockaddr_sa_len=yes
16002 else
16003   $as_echo "$as_me: failed program was:" >&5
16004 sed 's/^/| /' conftest.$ac_ext >&5
16005
16006         ac_cv_member_struct_sockaddr_sa_len=no
16007 fi
16008
16009 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16010 fi
16011
16012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16013 fi
16014 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
16015 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
16016 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
16017
16018 cat >>confdefs.h <<_ACEOF
16019 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
16020 _ACEOF
16021
16022
16023 fi
16024
16025 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
16026 $as_echo_n "checking for struct addrinfo... " >&6; }
16027 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
16028   $as_echo_n "(cached) " >&6
16029 else
16030   ac_cv_type_struct_addrinfo=no
16031 cat >conftest.$ac_ext <<_ACEOF
16032 /* confdefs.h.  */
16033 _ACEOF
16034 cat confdefs.h >>conftest.$ac_ext
16035 cat >>conftest.$ac_ext <<_ACEOF
16036 /* end confdefs.h.  */
16037 #include <sys/types.h>
16038 #include <sys/socket.h>
16039 #include <netdb.h>
16040
16041
16042 int
16043 main ()
16044 {
16045 if (sizeof (struct addrinfo))
16046        return 0;
16047   ;
16048   return 0;
16049 }
16050 _ACEOF
16051 rm -f conftest.$ac_objext
16052 if { (ac_try="$ac_compile"
16053 case "(($ac_try" in
16054   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16055   *) ac_try_echo=$ac_try;;
16056 esac
16057 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16058 $as_echo "$ac_try_echo") >&5
16059   (eval "$ac_compile") 2>conftest.er1
16060   ac_status=$?
16061   grep -v '^ *+' conftest.er1 >conftest.err
16062   rm -f conftest.er1
16063   cat conftest.err >&5
16064   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16065   (exit $ac_status); } && {
16066          test -z "$ac_c_werror_flag" ||
16067          test ! -s conftest.err
16068        } && test -s conftest.$ac_objext; then
16069   cat >conftest.$ac_ext <<_ACEOF
16070 /* confdefs.h.  */
16071 _ACEOF
16072 cat confdefs.h >>conftest.$ac_ext
16073 cat >>conftest.$ac_ext <<_ACEOF
16074 /* end confdefs.h.  */
16075 #include <sys/types.h>
16076 #include <sys/socket.h>
16077 #include <netdb.h>
16078
16079
16080 int
16081 main ()
16082 {
16083 if (sizeof ((struct addrinfo)))
16084           return 0;
16085   ;
16086   return 0;
16087 }
16088 _ACEOF
16089 rm -f conftest.$ac_objext
16090 if { (ac_try="$ac_compile"
16091 case "(($ac_try" in
16092   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16093   *) ac_try_echo=$ac_try;;
16094 esac
16095 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16096 $as_echo "$ac_try_echo") >&5
16097   (eval "$ac_compile") 2>conftest.er1
16098   ac_status=$?
16099   grep -v '^ *+' conftest.er1 >conftest.err
16100   rm -f conftest.er1
16101   cat conftest.err >&5
16102   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16103   (exit $ac_status); } && {
16104          test -z "$ac_c_werror_flag" ||
16105          test ! -s conftest.err
16106        } && test -s conftest.$ac_objext; then
16107   :
16108 else
16109   $as_echo "$as_me: failed program was:" >&5
16110 sed 's/^/| /' conftest.$ac_ext >&5
16111
16112         ac_cv_type_struct_addrinfo=yes
16113 fi
16114
16115 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16116 else
16117   $as_echo "$as_me: failed program was:" >&5
16118 sed 's/^/| /' conftest.$ac_ext >&5
16119
16120
16121 fi
16122
16123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16124 fi
16125 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
16126 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
16127 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
16128
16129 cat >>confdefs.h <<_ACEOF
16130 #define HAVE_STRUCT_ADDRINFO 1
16131 _ACEOF
16132
16133
16134 fi
16135
16136
16137   { $as_echo "$as_me:$LINENO: checking for intptr_t" >&5
16138 $as_echo_n "checking for intptr_t... " >&6; }
16139 if test "${ac_cv_type_intptr_t+set}" = set; then
16140   $as_echo_n "(cached) " >&6
16141 else
16142   ac_cv_type_intptr_t=no
16143 cat >conftest.$ac_ext <<_ACEOF
16144 /* confdefs.h.  */
16145 _ACEOF
16146 cat confdefs.h >>conftest.$ac_ext
16147 cat >>conftest.$ac_ext <<_ACEOF
16148 /* end confdefs.h.  */
16149 $ac_includes_default
16150 int
16151 main ()
16152 {
16153 if (sizeof (intptr_t))
16154        return 0;
16155   ;
16156   return 0;
16157 }
16158 _ACEOF
16159 rm -f conftest.$ac_objext
16160 if { (ac_try="$ac_compile"
16161 case "(($ac_try" in
16162   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16163   *) ac_try_echo=$ac_try;;
16164 esac
16165 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16166 $as_echo "$ac_try_echo") >&5
16167   (eval "$ac_compile") 2>conftest.er1
16168   ac_status=$?
16169   grep -v '^ *+' conftest.er1 >conftest.err
16170   rm -f conftest.er1
16171   cat conftest.err >&5
16172   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16173   (exit $ac_status); } && {
16174          test -z "$ac_c_werror_flag" ||
16175          test ! -s conftest.err
16176        } && test -s conftest.$ac_objext; then
16177   cat >conftest.$ac_ext <<_ACEOF
16178 /* confdefs.h.  */
16179 _ACEOF
16180 cat confdefs.h >>conftest.$ac_ext
16181 cat >>conftest.$ac_ext <<_ACEOF
16182 /* end confdefs.h.  */
16183 $ac_includes_default
16184 int
16185 main ()
16186 {
16187 if (sizeof ((intptr_t)))
16188           return 0;
16189   ;
16190   return 0;
16191 }
16192 _ACEOF
16193 rm -f conftest.$ac_objext
16194 if { (ac_try="$ac_compile"
16195 case "(($ac_try" in
16196   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16197   *) ac_try_echo=$ac_try;;
16198 esac
16199 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16200 $as_echo "$ac_try_echo") >&5
16201   (eval "$ac_compile") 2>conftest.er1
16202   ac_status=$?
16203   grep -v '^ *+' conftest.er1 >conftest.err
16204   rm -f conftest.er1
16205   cat conftest.err >&5
16206   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16207   (exit $ac_status); } && {
16208          test -z "$ac_c_werror_flag" ||
16209          test ! -s conftest.err
16210        } && test -s conftest.$ac_objext; then
16211   :
16212 else
16213   $as_echo "$as_me: failed program was:" >&5
16214 sed 's/^/| /' conftest.$ac_ext >&5
16215
16216         ac_cv_type_intptr_t=yes
16217 fi
16218
16219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16220 else
16221   $as_echo "$as_me: failed program was:" >&5
16222 sed 's/^/| /' conftest.$ac_ext >&5
16223
16224
16225 fi
16226
16227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16228 fi
16229 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
16230 $as_echo "$ac_cv_type_intptr_t" >&6; }
16231 if test "x$ac_cv_type_intptr_t" = x""yes; then
16232
16233 cat >>confdefs.h <<\_ACEOF
16234 #define HAVE_INTPTR_T 1
16235 _ACEOF
16236
16237 else
16238   for ac_type in 'int' 'long int' 'long long int'; do
16239        cat >conftest.$ac_ext <<_ACEOF
16240 /* confdefs.h.  */
16241 _ACEOF
16242 cat confdefs.h >>conftest.$ac_ext
16243 cat >>conftest.$ac_ext <<_ACEOF
16244 /* end confdefs.h.  */
16245 $ac_includes_default
16246 int
16247 main ()
16248 {
16249 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16250 test_array [0] = 0
16251
16252   ;
16253   return 0;
16254 }
16255 _ACEOF
16256 rm -f conftest.$ac_objext
16257 if { (ac_try="$ac_compile"
16258 case "(($ac_try" in
16259   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16260   *) ac_try_echo=$ac_try;;
16261 esac
16262 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16263 $as_echo "$ac_try_echo") >&5
16264   (eval "$ac_compile") 2>conftest.er1
16265   ac_status=$?
16266   grep -v '^ *+' conftest.er1 >conftest.err
16267   rm -f conftest.er1
16268   cat conftest.err >&5
16269   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16270   (exit $ac_status); } && {
16271          test -z "$ac_c_werror_flag" ||
16272          test ! -s conftest.err
16273        } && test -s conftest.$ac_objext; then
16274
16275 cat >>confdefs.h <<_ACEOF
16276 #define intptr_t $ac_type
16277 _ACEOF
16278
16279           ac_type=
16280 else
16281   $as_echo "$as_me: failed program was:" >&5
16282 sed 's/^/| /' conftest.$ac_ext >&5
16283
16284
16285 fi
16286
16287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16288        test -z "$ac_type" && break
16289      done
16290 fi
16291
16292
16293
16294   { $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
16295 $as_echo_n "checking for uintptr_t... " >&6; }
16296 if test "${ac_cv_type_uintptr_t+set}" = set; then
16297   $as_echo_n "(cached) " >&6
16298 else
16299   ac_cv_type_uintptr_t=no
16300 cat >conftest.$ac_ext <<_ACEOF
16301 /* confdefs.h.  */
16302 _ACEOF
16303 cat confdefs.h >>conftest.$ac_ext
16304 cat >>conftest.$ac_ext <<_ACEOF
16305 /* end confdefs.h.  */
16306 $ac_includes_default
16307 int
16308 main ()
16309 {
16310 if (sizeof (uintptr_t))
16311        return 0;
16312   ;
16313   return 0;
16314 }
16315 _ACEOF
16316 rm -f conftest.$ac_objext
16317 if { (ac_try="$ac_compile"
16318 case "(($ac_try" in
16319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16320   *) ac_try_echo=$ac_try;;
16321 esac
16322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16323 $as_echo "$ac_try_echo") >&5
16324   (eval "$ac_compile") 2>conftest.er1
16325   ac_status=$?
16326   grep -v '^ *+' conftest.er1 >conftest.err
16327   rm -f conftest.er1
16328   cat conftest.err >&5
16329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16330   (exit $ac_status); } && {
16331          test -z "$ac_c_werror_flag" ||
16332          test ! -s conftest.err
16333        } && test -s conftest.$ac_objext; then
16334   cat >conftest.$ac_ext <<_ACEOF
16335 /* confdefs.h.  */
16336 _ACEOF
16337 cat confdefs.h >>conftest.$ac_ext
16338 cat >>conftest.$ac_ext <<_ACEOF
16339 /* end confdefs.h.  */
16340 $ac_includes_default
16341 int
16342 main ()
16343 {
16344 if (sizeof ((uintptr_t)))
16345           return 0;
16346   ;
16347   return 0;
16348 }
16349 _ACEOF
16350 rm -f conftest.$ac_objext
16351 if { (ac_try="$ac_compile"
16352 case "(($ac_try" in
16353   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16354   *) ac_try_echo=$ac_try;;
16355 esac
16356 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16357 $as_echo "$ac_try_echo") >&5
16358   (eval "$ac_compile") 2>conftest.er1
16359   ac_status=$?
16360   grep -v '^ *+' conftest.er1 >conftest.err
16361   rm -f conftest.er1
16362   cat conftest.err >&5
16363   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16364   (exit $ac_status); } && {
16365          test -z "$ac_c_werror_flag" ||
16366          test ! -s conftest.err
16367        } && test -s conftest.$ac_objext; then
16368   :
16369 else
16370   $as_echo "$as_me: failed program was:" >&5
16371 sed 's/^/| /' conftest.$ac_ext >&5
16372
16373         ac_cv_type_uintptr_t=yes
16374 fi
16375
16376 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16377 else
16378   $as_echo "$as_me: failed program was:" >&5
16379 sed 's/^/| /' conftest.$ac_ext >&5
16380
16381
16382 fi
16383
16384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16385 fi
16386 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
16387 $as_echo "$ac_cv_type_uintptr_t" >&6; }
16388 if test "x$ac_cv_type_uintptr_t" = x""yes; then
16389
16390 cat >>confdefs.h <<\_ACEOF
16391 #define HAVE_UINTPTR_T 1
16392 _ACEOF
16393
16394 else
16395   for ac_type in 'unsigned int' 'unsigned long int' \
16396         'unsigned long long int'; do
16397        cat >conftest.$ac_ext <<_ACEOF
16398 /* confdefs.h.  */
16399 _ACEOF
16400 cat confdefs.h >>conftest.$ac_ext
16401 cat >>conftest.$ac_ext <<_ACEOF
16402 /* end confdefs.h.  */
16403 $ac_includes_default
16404 int
16405 main ()
16406 {
16407 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16408 test_array [0] = 0
16409
16410   ;
16411   return 0;
16412 }
16413 _ACEOF
16414 rm -f conftest.$ac_objext
16415 if { (ac_try="$ac_compile"
16416 case "(($ac_try" in
16417   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16418   *) ac_try_echo=$ac_try;;
16419 esac
16420 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16421 $as_echo "$ac_try_echo") >&5
16422   (eval "$ac_compile") 2>conftest.er1
16423   ac_status=$?
16424   grep -v '^ *+' conftest.er1 >conftest.err
16425   rm -f conftest.er1
16426   cat conftest.err >&5
16427   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16428   (exit $ac_status); } && {
16429          test -z "$ac_c_werror_flag" ||
16430          test ! -s conftest.err
16431        } && test -s conftest.$ac_objext; then
16432
16433 cat >>confdefs.h <<_ACEOF
16434 #define uintptr_t $ac_type
16435 _ACEOF
16436
16437           ac_type=
16438 else
16439   $as_echo "$as_me: failed program was:" >&5
16440 sed 's/^/| /' conftest.$ac_ext >&5
16441
16442
16443 fi
16444
16445 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16446        test -z "$ac_type" && break
16447      done
16448 fi
16449
16450
16451
16452   { $as_echo "$as_me:$LINENO: checking for long long int" >&5
16453 $as_echo_n "checking for long long int... " >&6; }
16454 if test "${ac_cv_type_long_long_int+set}" = set; then
16455   $as_echo_n "(cached) " >&6
16456 else
16457   cat >conftest.$ac_ext <<_ACEOF
16458
16459   /* confdefs.h.  */
16460 _ACEOF
16461 cat confdefs.h >>conftest.$ac_ext
16462 cat >>conftest.$ac_ext <<_ACEOF
16463 /* end confdefs.h.  */
16464 /* For now, do not test the preprocessor; as of 2007 there are too many
16465          implementations with broken preprocessors.  Perhaps this can
16466          be revisited in 2012.  In the meantime, code should not expect
16467          #if to work with literals wider than 32 bits.  */
16468       /* Test literals.  */
16469       long long int ll = 9223372036854775807ll;
16470       long long int nll = -9223372036854775807LL;
16471       unsigned long long int ull = 18446744073709551615ULL;
16472       /* Test constant expressions.   */
16473       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
16474                      ? 1 : -1)];
16475       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
16476                      ? 1 : -1)];
16477       int i = 63;
16478 int
16479 main ()
16480 {
16481 /* Test availability of runtime routines for shift and division.  */
16482       long long int llmax = 9223372036854775807ll;
16483       unsigned long long int ullmax = 18446744073709551615ull;
16484       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
16485               | (llmax / ll) | (llmax % ll)
16486               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
16487               | (ullmax / ull) | (ullmax % ull));
16488   ;
16489   return 0;
16490 }
16491
16492 _ACEOF
16493 rm -f conftest.$ac_objext conftest$ac_exeext
16494 if { (ac_try="$ac_link"
16495 case "(($ac_try" in
16496   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16497   *) ac_try_echo=$ac_try;;
16498 esac
16499 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16500 $as_echo "$ac_try_echo") >&5
16501   (eval "$ac_link") 2>conftest.er1
16502   ac_status=$?
16503   grep -v '^ *+' conftest.er1 >conftest.err
16504   rm -f conftest.er1
16505   cat conftest.err >&5
16506   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16507   (exit $ac_status); } && {
16508          test -z "$ac_c_werror_flag" ||
16509          test ! -s conftest.err
16510        } && test -s conftest$ac_exeext && {
16511          test "$cross_compiling" = yes ||
16512          $as_test_x conftest$ac_exeext
16513        }; then
16514                         if test "$cross_compiling" = yes; then
16515   ac_cv_type_long_long_int=yes
16516 else
16517   cat >conftest.$ac_ext <<_ACEOF
16518 /* confdefs.h.  */
16519 _ACEOF
16520 cat confdefs.h >>conftest.$ac_ext
16521 cat >>conftest.$ac_ext <<_ACEOF
16522 /* end confdefs.h.  */
16523 #include <limits.h>
16524                #ifndef LLONG_MAX
16525                # define HALF \
16526                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
16527                # define LLONG_MAX (HALF - 1 + HALF)
16528                #endif
16529 int
16530 main ()
16531 {
16532 long long int n = 1;
16533                int i;
16534                for (i = 0; ; i++)
16535                  {
16536                    long long int m = n << i;
16537                    if (m >> i != n)
16538                      return 1;
16539                    if (LLONG_MAX / 2 < m)
16540                      break;
16541                  }
16542                return 0;
16543   ;
16544   return 0;
16545 }
16546 _ACEOF
16547 rm -f conftest$ac_exeext
16548 if { (ac_try="$ac_link"
16549 case "(($ac_try" in
16550   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16551   *) ac_try_echo=$ac_try;;
16552 esac
16553 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16554 $as_echo "$ac_try_echo") >&5
16555   (eval "$ac_link") 2>&5
16556   ac_status=$?
16557   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16558   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16559   { (case "(($ac_try" in
16560   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16561   *) ac_try_echo=$ac_try;;
16562 esac
16563 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16564 $as_echo "$ac_try_echo") >&5
16565   (eval "$ac_try") 2>&5
16566   ac_status=$?
16567   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16568   (exit $ac_status); }; }; then
16569   ac_cv_type_long_long_int=yes
16570 else
16571   $as_echo "$as_me: program exited with status $ac_status" >&5
16572 $as_echo "$as_me: failed program was:" >&5
16573 sed 's/^/| /' conftest.$ac_ext >&5
16574
16575 ( exit $ac_status )
16576 ac_cv_type_long_long_int=no
16577 fi
16578 rm -rf conftest.dSYM
16579 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16580 fi
16581
16582
16583 else
16584   $as_echo "$as_me: failed program was:" >&5
16585 sed 's/^/| /' conftest.$ac_ext >&5
16586
16587         ac_cv_type_long_long_int=no
16588 fi
16589
16590 rm -rf conftest.dSYM
16591 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16592       conftest$ac_exeext conftest.$ac_ext
16593 fi
16594 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
16595 $as_echo "$ac_cv_type_long_long_int" >&6; }
16596   if test $ac_cv_type_long_long_int = yes; then
16597
16598 cat >>confdefs.h <<\_ACEOF
16599 #define HAVE_LONG_LONG_INT 1
16600 _ACEOF
16601
16602   fi
16603
16604
16605 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
16606 $as_echo_n "checking for struct cmsgcred... " >&6; }
16607 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
16608   $as_echo_n "(cached) " >&6
16609 else
16610   ac_cv_type_struct_cmsgcred=no
16611 cat >conftest.$ac_ext <<_ACEOF
16612 /* confdefs.h.  */
16613 _ACEOF
16614 cat confdefs.h >>conftest.$ac_ext
16615 cat >>conftest.$ac_ext <<_ACEOF
16616 /* end confdefs.h.  */
16617 #include <sys/param.h>
16618 #include <sys/types.h>
16619 #include <sys/socket.h>
16620 #include <sys/ucred.h>
16621
16622 int
16623 main ()
16624 {
16625 if (sizeof (struct cmsgcred))
16626        return 0;
16627   ;
16628   return 0;
16629 }
16630 _ACEOF
16631 rm -f conftest.$ac_objext
16632 if { (ac_try="$ac_compile"
16633 case "(($ac_try" in
16634   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16635   *) ac_try_echo=$ac_try;;
16636 esac
16637 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16638 $as_echo "$ac_try_echo") >&5
16639   (eval "$ac_compile") 2>conftest.er1
16640   ac_status=$?
16641   grep -v '^ *+' conftest.er1 >conftest.err
16642   rm -f conftest.er1
16643   cat conftest.err >&5
16644   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16645   (exit $ac_status); } && {
16646          test -z "$ac_c_werror_flag" ||
16647          test ! -s conftest.err
16648        } && test -s conftest.$ac_objext; then
16649   cat >conftest.$ac_ext <<_ACEOF
16650 /* confdefs.h.  */
16651 _ACEOF
16652 cat confdefs.h >>conftest.$ac_ext
16653 cat >>conftest.$ac_ext <<_ACEOF
16654 /* end confdefs.h.  */
16655 #include <sys/param.h>
16656 #include <sys/types.h>
16657 #include <sys/socket.h>
16658 #include <sys/ucred.h>
16659
16660 int
16661 main ()
16662 {
16663 if (sizeof ((struct cmsgcred)))
16664           return 0;
16665   ;
16666   return 0;
16667 }
16668 _ACEOF
16669 rm -f conftest.$ac_objext
16670 if { (ac_try="$ac_compile"
16671 case "(($ac_try" in
16672   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16673   *) ac_try_echo=$ac_try;;
16674 esac
16675 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16676 $as_echo "$ac_try_echo") >&5
16677   (eval "$ac_compile") 2>conftest.er1
16678   ac_status=$?
16679   grep -v '^ *+' conftest.er1 >conftest.err
16680   rm -f conftest.er1
16681   cat conftest.err >&5
16682   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16683   (exit $ac_status); } && {
16684          test -z "$ac_c_werror_flag" ||
16685          test ! -s conftest.err
16686        } && test -s conftest.$ac_objext; then
16687   :
16688 else
16689   $as_echo "$as_me: failed program was:" >&5
16690 sed 's/^/| /' conftest.$ac_ext >&5
16691
16692         ac_cv_type_struct_cmsgcred=yes
16693 fi
16694
16695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16696 else
16697   $as_echo "$as_me: failed program was:" >&5
16698 sed 's/^/| /' conftest.$ac_ext >&5
16699
16700
16701 fi
16702
16703 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16704 fi
16705 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
16706 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
16707 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
16708
16709 cat >>confdefs.h <<_ACEOF
16710 #define HAVE_STRUCT_CMSGCRED 1
16711 _ACEOF
16712
16713
16714 fi
16715 { $as_echo "$as_me:$LINENO: checking for struct fcred" >&5
16716 $as_echo_n "checking for struct fcred... " >&6; }
16717 if test "${ac_cv_type_struct_fcred+set}" = set; then
16718   $as_echo_n "(cached) " >&6
16719 else
16720   ac_cv_type_struct_fcred=no
16721 cat >conftest.$ac_ext <<_ACEOF
16722 /* confdefs.h.  */
16723 _ACEOF
16724 cat confdefs.h >>conftest.$ac_ext
16725 cat >>conftest.$ac_ext <<_ACEOF
16726 /* end confdefs.h.  */
16727 #include <sys/param.h>
16728 #include <sys/types.h>
16729 #include <sys/socket.h>
16730 #include <sys/ucred.h>
16731
16732 int
16733 main ()
16734 {
16735 if (sizeof (struct fcred))
16736        return 0;
16737   ;
16738   return 0;
16739 }
16740 _ACEOF
16741 rm -f conftest.$ac_objext
16742 if { (ac_try="$ac_compile"
16743 case "(($ac_try" in
16744   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16745   *) ac_try_echo=$ac_try;;
16746 esac
16747 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16748 $as_echo "$ac_try_echo") >&5
16749   (eval "$ac_compile") 2>conftest.er1
16750   ac_status=$?
16751   grep -v '^ *+' conftest.er1 >conftest.err
16752   rm -f conftest.er1
16753   cat conftest.err >&5
16754   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16755   (exit $ac_status); } && {
16756          test -z "$ac_c_werror_flag" ||
16757          test ! -s conftest.err
16758        } && test -s conftest.$ac_objext; then
16759   cat >conftest.$ac_ext <<_ACEOF
16760 /* confdefs.h.  */
16761 _ACEOF
16762 cat confdefs.h >>conftest.$ac_ext
16763 cat >>conftest.$ac_ext <<_ACEOF
16764 /* end confdefs.h.  */
16765 #include <sys/param.h>
16766 #include <sys/types.h>
16767 #include <sys/socket.h>
16768 #include <sys/ucred.h>
16769
16770 int
16771 main ()
16772 {
16773 if (sizeof ((struct fcred)))
16774           return 0;
16775   ;
16776   return 0;
16777 }
16778 _ACEOF
16779 rm -f conftest.$ac_objext
16780 if { (ac_try="$ac_compile"
16781 case "(($ac_try" in
16782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16783   *) ac_try_echo=$ac_try;;
16784 esac
16785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16786 $as_echo "$ac_try_echo") >&5
16787   (eval "$ac_compile") 2>conftest.er1
16788   ac_status=$?
16789   grep -v '^ *+' conftest.er1 >conftest.err
16790   rm -f conftest.er1
16791   cat conftest.err >&5
16792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16793   (exit $ac_status); } && {
16794          test -z "$ac_c_werror_flag" ||
16795          test ! -s conftest.err
16796        } && test -s conftest.$ac_objext; then
16797   :
16798 else
16799   $as_echo "$as_me: failed program was:" >&5
16800 sed 's/^/| /' conftest.$ac_ext >&5
16801
16802         ac_cv_type_struct_fcred=yes
16803 fi
16804
16805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16806 else
16807   $as_echo "$as_me: failed program was:" >&5
16808 sed 's/^/| /' conftest.$ac_ext >&5
16809
16810
16811 fi
16812
16813 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16814 fi
16815 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
16816 $as_echo "$ac_cv_type_struct_fcred" >&6; }
16817 if test "x$ac_cv_type_struct_fcred" = x""yes; then
16818
16819 cat >>confdefs.h <<_ACEOF
16820 #define HAVE_STRUCT_FCRED 1
16821 _ACEOF
16822
16823
16824 fi
16825 { $as_echo "$as_me:$LINENO: checking for struct sockcred" >&5
16826 $as_echo_n "checking for struct sockcred... " >&6; }
16827 if test "${ac_cv_type_struct_sockcred+set}" = set; then
16828   $as_echo_n "(cached) " >&6
16829 else
16830   ac_cv_type_struct_sockcred=no
16831 cat >conftest.$ac_ext <<_ACEOF
16832 /* confdefs.h.  */
16833 _ACEOF
16834 cat confdefs.h >>conftest.$ac_ext
16835 cat >>conftest.$ac_ext <<_ACEOF
16836 /* end confdefs.h.  */
16837 #include <sys/param.h>
16838 #include <sys/types.h>
16839 #include <sys/socket.h>
16840 #include <sys/ucred.h>
16841
16842 int
16843 main ()
16844 {
16845 if (sizeof (struct sockcred))
16846        return 0;
16847   ;
16848   return 0;
16849 }
16850 _ACEOF
16851 rm -f conftest.$ac_objext
16852 if { (ac_try="$ac_compile"
16853 case "(($ac_try" in
16854   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16855   *) ac_try_echo=$ac_try;;
16856 esac
16857 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16858 $as_echo "$ac_try_echo") >&5
16859   (eval "$ac_compile") 2>conftest.er1
16860   ac_status=$?
16861   grep -v '^ *+' conftest.er1 >conftest.err
16862   rm -f conftest.er1
16863   cat conftest.err >&5
16864   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16865   (exit $ac_status); } && {
16866          test -z "$ac_c_werror_flag" ||
16867          test ! -s conftest.err
16868        } && test -s conftest.$ac_objext; then
16869   cat >conftest.$ac_ext <<_ACEOF
16870 /* confdefs.h.  */
16871 _ACEOF
16872 cat confdefs.h >>conftest.$ac_ext
16873 cat >>conftest.$ac_ext <<_ACEOF
16874 /* end confdefs.h.  */
16875 #include <sys/param.h>
16876 #include <sys/types.h>
16877 #include <sys/socket.h>
16878 #include <sys/ucred.h>
16879
16880 int
16881 main ()
16882 {
16883 if (sizeof ((struct sockcred)))
16884           return 0;
16885   ;
16886   return 0;
16887 }
16888 _ACEOF
16889 rm -f conftest.$ac_objext
16890 if { (ac_try="$ac_compile"
16891 case "(($ac_try" in
16892   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16893   *) ac_try_echo=$ac_try;;
16894 esac
16895 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16896 $as_echo "$ac_try_echo") >&5
16897   (eval "$ac_compile") 2>conftest.er1
16898   ac_status=$?
16899   grep -v '^ *+' conftest.er1 >conftest.err
16900   rm -f conftest.er1
16901   cat conftest.err >&5
16902   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16903   (exit $ac_status); } && {
16904          test -z "$ac_c_werror_flag" ||
16905          test ! -s conftest.err
16906        } && test -s conftest.$ac_objext; then
16907   :
16908 else
16909   $as_echo "$as_me: failed program was:" >&5
16910 sed 's/^/| /' conftest.$ac_ext >&5
16911
16912         ac_cv_type_struct_sockcred=yes
16913 fi
16914
16915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16916 else
16917   $as_echo "$as_me: failed program was:" >&5
16918 sed 's/^/| /' conftest.$ac_ext >&5
16919
16920
16921 fi
16922
16923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16924 fi
16925 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
16926 $as_echo "$ac_cv_type_struct_sockcred" >&6; }
16927 if test "x$ac_cv_type_struct_sockcred" = x""yes; then
16928
16929 cat >>confdefs.h <<_ACEOF
16930 #define HAVE_STRUCT_SOCKCRED 1
16931 _ACEOF
16932
16933
16934 fi
16935
16936
16937 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
16938 $as_echo_n "checking for struct option... " >&6; }
16939 if test "${ac_cv_type_struct_option+set}" = set; then
16940   $as_echo_n "(cached) " >&6
16941 else
16942   ac_cv_type_struct_option=no
16943 cat >conftest.$ac_ext <<_ACEOF
16944 /* confdefs.h.  */
16945 _ACEOF
16946 cat confdefs.h >>conftest.$ac_ext
16947 cat >>conftest.$ac_ext <<_ACEOF
16948 /* end confdefs.h.  */
16949 #ifdef HAVE_GETOPT_H
16950 #include <getopt.h>
16951 #endif
16952
16953 int
16954 main ()
16955 {
16956 if (sizeof (struct option))
16957        return 0;
16958   ;
16959   return 0;
16960 }
16961 _ACEOF
16962 rm -f conftest.$ac_objext
16963 if { (ac_try="$ac_compile"
16964 case "(($ac_try" in
16965   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16966   *) ac_try_echo=$ac_try;;
16967 esac
16968 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16969 $as_echo "$ac_try_echo") >&5
16970   (eval "$ac_compile") 2>conftest.er1
16971   ac_status=$?
16972   grep -v '^ *+' conftest.er1 >conftest.err
16973   rm -f conftest.er1
16974   cat conftest.err >&5
16975   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16976   (exit $ac_status); } && {
16977          test -z "$ac_c_werror_flag" ||
16978          test ! -s conftest.err
16979        } && test -s conftest.$ac_objext; then
16980   cat >conftest.$ac_ext <<_ACEOF
16981 /* confdefs.h.  */
16982 _ACEOF
16983 cat confdefs.h >>conftest.$ac_ext
16984 cat >>conftest.$ac_ext <<_ACEOF
16985 /* end confdefs.h.  */
16986 #ifdef HAVE_GETOPT_H
16987 #include <getopt.h>
16988 #endif
16989
16990 int
16991 main ()
16992 {
16993 if (sizeof ((struct option)))
16994           return 0;
16995   ;
16996   return 0;
16997 }
16998 _ACEOF
16999 rm -f conftest.$ac_objext
17000 if { (ac_try="$ac_compile"
17001 case "(($ac_try" in
17002   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17003   *) ac_try_echo=$ac_try;;
17004 esac
17005 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17006 $as_echo "$ac_try_echo") >&5
17007   (eval "$ac_compile") 2>conftest.er1
17008   ac_status=$?
17009   grep -v '^ *+' conftest.er1 >conftest.err
17010   rm -f conftest.er1
17011   cat conftest.err >&5
17012   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17013   (exit $ac_status); } && {
17014          test -z "$ac_c_werror_flag" ||
17015          test ! -s conftest.err
17016        } && test -s conftest.$ac_objext; then
17017   :
17018 else
17019   $as_echo "$as_me: failed program was:" >&5
17020 sed 's/^/| /' conftest.$ac_ext >&5
17021
17022         ac_cv_type_struct_option=yes
17023 fi
17024
17025 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17026 else
17027   $as_echo "$as_me: failed program was:" >&5
17028 sed 's/^/| /' conftest.$ac_ext >&5
17029
17030
17031 fi
17032
17033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17034 fi
17035 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
17036 $as_echo "$ac_cv_type_struct_option" >&6; }
17037 if test "x$ac_cv_type_struct_option" = x""yes; then
17038
17039 cat >>confdefs.h <<_ACEOF
17040 #define HAVE_STRUCT_OPTION 1
17041 _ACEOF
17042
17043
17044 fi
17045
17046
17047 if test "$with_zlib" = yes; then
17048   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
17049   # did not).  While we could work around the lack of z_streamp, it
17050   # seems unwise to encourage people to use such old zlib versions...
17051   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
17052 $as_echo_n "checking for z_streamp... " >&6; }
17053 if test "${ac_cv_type_z_streamp+set}" = set; then
17054   $as_echo_n "(cached) " >&6
17055 else
17056   ac_cv_type_z_streamp=no
17057 cat >conftest.$ac_ext <<_ACEOF
17058 /* confdefs.h.  */
17059 _ACEOF
17060 cat confdefs.h >>conftest.$ac_ext
17061 cat >>conftest.$ac_ext <<_ACEOF
17062 /* end confdefs.h.  */
17063 #include <zlib.h>
17064
17065 int
17066 main ()
17067 {
17068 if (sizeof (z_streamp))
17069        return 0;
17070   ;
17071   return 0;
17072 }
17073 _ACEOF
17074 rm -f conftest.$ac_objext
17075 if { (ac_try="$ac_compile"
17076 case "(($ac_try" in
17077   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17078   *) ac_try_echo=$ac_try;;
17079 esac
17080 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17081 $as_echo "$ac_try_echo") >&5
17082   (eval "$ac_compile") 2>conftest.er1
17083   ac_status=$?
17084   grep -v '^ *+' conftest.er1 >conftest.err
17085   rm -f conftest.er1
17086   cat conftest.err >&5
17087   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17088   (exit $ac_status); } && {
17089          test -z "$ac_c_werror_flag" ||
17090          test ! -s conftest.err
17091        } && test -s conftest.$ac_objext; then
17092   cat >conftest.$ac_ext <<_ACEOF
17093 /* confdefs.h.  */
17094 _ACEOF
17095 cat confdefs.h >>conftest.$ac_ext
17096 cat >>conftest.$ac_ext <<_ACEOF
17097 /* end confdefs.h.  */
17098 #include <zlib.h>
17099
17100 int
17101 main ()
17102 {
17103 if (sizeof ((z_streamp)))
17104           return 0;
17105   ;
17106   return 0;
17107 }
17108 _ACEOF
17109 rm -f conftest.$ac_objext
17110 if { (ac_try="$ac_compile"
17111 case "(($ac_try" in
17112   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17113   *) ac_try_echo=$ac_try;;
17114 esac
17115 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17116 $as_echo "$ac_try_echo") >&5
17117   (eval "$ac_compile") 2>conftest.er1
17118   ac_status=$?
17119   grep -v '^ *+' conftest.er1 >conftest.err
17120   rm -f conftest.er1
17121   cat conftest.err >&5
17122   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17123   (exit $ac_status); } && {
17124          test -z "$ac_c_werror_flag" ||
17125          test ! -s conftest.err
17126        } && test -s conftest.$ac_objext; then
17127   :
17128 else
17129   $as_echo "$as_me: failed program was:" >&5
17130 sed 's/^/| /' conftest.$ac_ext >&5
17131
17132         ac_cv_type_z_streamp=yes
17133 fi
17134
17135 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17136 else
17137   $as_echo "$as_me: failed program was:" >&5
17138 sed 's/^/| /' conftest.$ac_ext >&5
17139
17140
17141 fi
17142
17143 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17144 fi
17145 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
17146 $as_echo "$ac_cv_type_z_streamp" >&6; }
17147 if test "x$ac_cv_type_z_streamp" = x""yes; then
17148   :
17149 else
17150   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
17151 Use --without-zlib to disable zlib support." >&5
17152 $as_echo "$as_me: error: zlib version is too old
17153 Use --without-zlib to disable zlib support." >&2;}
17154    { (exit 1); exit 1; }; }
17155 fi
17156
17157 fi
17158
17159 if test "$with_krb5" = yes; then
17160 # Check for differences between MIT and Heimdal (KTH) releases
17161   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
17162 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
17163 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
17164   $as_echo_n "(cached) " >&6
17165 else
17166   cat >conftest.$ac_ext <<_ACEOF
17167 /* confdefs.h.  */
17168 _ACEOF
17169 cat confdefs.h >>conftest.$ac_ext
17170 cat >>conftest.$ac_ext <<_ACEOF
17171 /* end confdefs.h.  */
17172 #include <krb5.h>
17173
17174 int
17175 main ()
17176 {
17177 static krb5_ticket ac_aggr;
17178 if (ac_aggr.enc_part2)
17179 return 0;
17180   ;
17181   return 0;
17182 }
17183 _ACEOF
17184 rm -f conftest.$ac_objext
17185 if { (ac_try="$ac_compile"
17186 case "(($ac_try" in
17187   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17188   *) ac_try_echo=$ac_try;;
17189 esac
17190 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17191 $as_echo "$ac_try_echo") >&5
17192   (eval "$ac_compile") 2>conftest.er1
17193   ac_status=$?
17194   grep -v '^ *+' conftest.er1 >conftest.err
17195   rm -f conftest.er1
17196   cat conftest.err >&5
17197   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17198   (exit $ac_status); } && {
17199          test -z "$ac_c_werror_flag" ||
17200          test ! -s conftest.err
17201        } && test -s conftest.$ac_objext; then
17202   ac_cv_member_krb5_ticket_enc_part2=yes
17203 else
17204   $as_echo "$as_me: failed program was:" >&5
17205 sed 's/^/| /' conftest.$ac_ext >&5
17206
17207         cat >conftest.$ac_ext <<_ACEOF
17208 /* confdefs.h.  */
17209 _ACEOF
17210 cat confdefs.h >>conftest.$ac_ext
17211 cat >>conftest.$ac_ext <<_ACEOF
17212 /* end confdefs.h.  */
17213 #include <krb5.h>
17214
17215 int
17216 main ()
17217 {
17218 static krb5_ticket ac_aggr;
17219 if (sizeof ac_aggr.enc_part2)
17220 return 0;
17221   ;
17222   return 0;
17223 }
17224 _ACEOF
17225 rm -f conftest.$ac_objext
17226 if { (ac_try="$ac_compile"
17227 case "(($ac_try" in
17228   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17229   *) ac_try_echo=$ac_try;;
17230 esac
17231 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17232 $as_echo "$ac_try_echo") >&5
17233   (eval "$ac_compile") 2>conftest.er1
17234   ac_status=$?
17235   grep -v '^ *+' conftest.er1 >conftest.err
17236   rm -f conftest.er1
17237   cat conftest.err >&5
17238   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17239   (exit $ac_status); } && {
17240          test -z "$ac_c_werror_flag" ||
17241          test ! -s conftest.err
17242        } && test -s conftest.$ac_objext; then
17243   ac_cv_member_krb5_ticket_enc_part2=yes
17244 else
17245   $as_echo "$as_me: failed program was:" >&5
17246 sed 's/^/| /' conftest.$ac_ext >&5
17247
17248         ac_cv_member_krb5_ticket_enc_part2=no
17249 fi
17250
17251 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17252 fi
17253
17254 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17255 fi
17256 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
17257 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
17258 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
17259
17260 cat >>confdefs.h <<_ACEOF
17261 #define HAVE_KRB5_TICKET_ENC_PART2 1
17262 _ACEOF
17263
17264
17265 else
17266   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
17267 $as_echo_n "checking for krb5_ticket.client... " >&6; }
17268 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
17269   $as_echo_n "(cached) " >&6
17270 else
17271   cat >conftest.$ac_ext <<_ACEOF
17272 /* confdefs.h.  */
17273 _ACEOF
17274 cat confdefs.h >>conftest.$ac_ext
17275 cat >>conftest.$ac_ext <<_ACEOF
17276 /* end confdefs.h.  */
17277 #include <krb5.h>
17278
17279 int
17280 main ()
17281 {
17282 static krb5_ticket ac_aggr;
17283 if (ac_aggr.client)
17284 return 0;
17285   ;
17286   return 0;
17287 }
17288 _ACEOF
17289 rm -f conftest.$ac_objext
17290 if { (ac_try="$ac_compile"
17291 case "(($ac_try" in
17292   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17293   *) ac_try_echo=$ac_try;;
17294 esac
17295 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17296 $as_echo "$ac_try_echo") >&5
17297   (eval "$ac_compile") 2>conftest.er1
17298   ac_status=$?
17299   grep -v '^ *+' conftest.er1 >conftest.err
17300   rm -f conftest.er1
17301   cat conftest.err >&5
17302   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17303   (exit $ac_status); } && {
17304          test -z "$ac_c_werror_flag" ||
17305          test ! -s conftest.err
17306        } && test -s conftest.$ac_objext; then
17307   ac_cv_member_krb5_ticket_client=yes
17308 else
17309   $as_echo "$as_me: failed program was:" >&5
17310 sed 's/^/| /' conftest.$ac_ext >&5
17311
17312         cat >conftest.$ac_ext <<_ACEOF
17313 /* confdefs.h.  */
17314 _ACEOF
17315 cat confdefs.h >>conftest.$ac_ext
17316 cat >>conftest.$ac_ext <<_ACEOF
17317 /* end confdefs.h.  */
17318 #include <krb5.h>
17319
17320 int
17321 main ()
17322 {
17323 static krb5_ticket ac_aggr;
17324 if (sizeof ac_aggr.client)
17325 return 0;
17326   ;
17327   return 0;
17328 }
17329 _ACEOF
17330 rm -f conftest.$ac_objext
17331 if { (ac_try="$ac_compile"
17332 case "(($ac_try" in
17333   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17334   *) ac_try_echo=$ac_try;;
17335 esac
17336 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17337 $as_echo "$ac_try_echo") >&5
17338   (eval "$ac_compile") 2>conftest.er1
17339   ac_status=$?
17340   grep -v '^ *+' conftest.er1 >conftest.err
17341   rm -f conftest.er1
17342   cat conftest.err >&5
17343   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17344   (exit $ac_status); } && {
17345          test -z "$ac_c_werror_flag" ||
17346          test ! -s conftest.err
17347        } && test -s conftest.$ac_objext; then
17348   ac_cv_member_krb5_ticket_client=yes
17349 else
17350   $as_echo "$as_me: failed program was:" >&5
17351 sed 's/^/| /' conftest.$ac_ext >&5
17352
17353         ac_cv_member_krb5_ticket_client=no
17354 fi
17355
17356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17357 fi
17358
17359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17360 fi
17361 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
17362 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
17363 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
17364
17365 cat >>confdefs.h <<_ACEOF
17366 #define HAVE_KRB5_TICKET_CLIENT 1
17367 _ACEOF
17368
17369
17370 else
17371   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
17372 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
17373    { (exit 1); exit 1; }; }
17374 fi
17375
17376 fi
17377
17378   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
17379 $as_echo_n "checking for krb5_error.text.data... " >&6; }
17380 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
17381   $as_echo_n "(cached) " >&6
17382 else
17383   cat >conftest.$ac_ext <<_ACEOF
17384 /* confdefs.h.  */
17385 _ACEOF
17386 cat confdefs.h >>conftest.$ac_ext
17387 cat >>conftest.$ac_ext <<_ACEOF
17388 /* end confdefs.h.  */
17389 #include <krb5.h>
17390
17391 int
17392 main ()
17393 {
17394 static krb5_error ac_aggr;
17395 if (ac_aggr.text.data)
17396 return 0;
17397   ;
17398   return 0;
17399 }
17400 _ACEOF
17401 rm -f conftest.$ac_objext
17402 if { (ac_try="$ac_compile"
17403 case "(($ac_try" in
17404   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17405   *) ac_try_echo=$ac_try;;
17406 esac
17407 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17408 $as_echo "$ac_try_echo") >&5
17409   (eval "$ac_compile") 2>conftest.er1
17410   ac_status=$?
17411   grep -v '^ *+' conftest.er1 >conftest.err
17412   rm -f conftest.er1
17413   cat conftest.err >&5
17414   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17415   (exit $ac_status); } && {
17416          test -z "$ac_c_werror_flag" ||
17417          test ! -s conftest.err
17418        } && test -s conftest.$ac_objext; then
17419   ac_cv_member_krb5_error_text_data=yes
17420 else
17421   $as_echo "$as_me: failed program was:" >&5
17422 sed 's/^/| /' conftest.$ac_ext >&5
17423
17424         cat >conftest.$ac_ext <<_ACEOF
17425 /* confdefs.h.  */
17426 _ACEOF
17427 cat confdefs.h >>conftest.$ac_ext
17428 cat >>conftest.$ac_ext <<_ACEOF
17429 /* end confdefs.h.  */
17430 #include <krb5.h>
17431
17432 int
17433 main ()
17434 {
17435 static krb5_error ac_aggr;
17436 if (sizeof ac_aggr.text.data)
17437 return 0;
17438   ;
17439   return 0;
17440 }
17441 _ACEOF
17442 rm -f conftest.$ac_objext
17443 if { (ac_try="$ac_compile"
17444 case "(($ac_try" in
17445   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17446   *) ac_try_echo=$ac_try;;
17447 esac
17448 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17449 $as_echo "$ac_try_echo") >&5
17450   (eval "$ac_compile") 2>conftest.er1
17451   ac_status=$?
17452   grep -v '^ *+' conftest.er1 >conftest.err
17453   rm -f conftest.er1
17454   cat conftest.err >&5
17455   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17456   (exit $ac_status); } && {
17457          test -z "$ac_c_werror_flag" ||
17458          test ! -s conftest.err
17459        } && test -s conftest.$ac_objext; then
17460   ac_cv_member_krb5_error_text_data=yes
17461 else
17462   $as_echo "$as_me: failed program was:" >&5
17463 sed 's/^/| /' conftest.$ac_ext >&5
17464
17465         ac_cv_member_krb5_error_text_data=no
17466 fi
17467
17468 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17469 fi
17470
17471 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17472 fi
17473 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
17474 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
17475 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
17476
17477 cat >>confdefs.h <<_ACEOF
17478 #define HAVE_KRB5_ERROR_TEXT_DATA 1
17479 _ACEOF
17480
17481
17482 else
17483   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
17484 $as_echo_n "checking for krb5_error.e_data... " >&6; }
17485 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
17486   $as_echo_n "(cached) " >&6
17487 else
17488   cat >conftest.$ac_ext <<_ACEOF
17489 /* confdefs.h.  */
17490 _ACEOF
17491 cat confdefs.h >>conftest.$ac_ext
17492 cat >>conftest.$ac_ext <<_ACEOF
17493 /* end confdefs.h.  */
17494 #include <krb5.h>
17495
17496 int
17497 main ()
17498 {
17499 static krb5_error ac_aggr;
17500 if (ac_aggr.e_data)
17501 return 0;
17502   ;
17503   return 0;
17504 }
17505 _ACEOF
17506 rm -f conftest.$ac_objext
17507 if { (ac_try="$ac_compile"
17508 case "(($ac_try" in
17509   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17510   *) ac_try_echo=$ac_try;;
17511 esac
17512 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17513 $as_echo "$ac_try_echo") >&5
17514   (eval "$ac_compile") 2>conftest.er1
17515   ac_status=$?
17516   grep -v '^ *+' conftest.er1 >conftest.err
17517   rm -f conftest.er1
17518   cat conftest.err >&5
17519   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17520   (exit $ac_status); } && {
17521          test -z "$ac_c_werror_flag" ||
17522          test ! -s conftest.err
17523        } && test -s conftest.$ac_objext; then
17524   ac_cv_member_krb5_error_e_data=yes
17525 else
17526   $as_echo "$as_me: failed program was:" >&5
17527 sed 's/^/| /' conftest.$ac_ext >&5
17528
17529         cat >conftest.$ac_ext <<_ACEOF
17530 /* confdefs.h.  */
17531 _ACEOF
17532 cat confdefs.h >>conftest.$ac_ext
17533 cat >>conftest.$ac_ext <<_ACEOF
17534 /* end confdefs.h.  */
17535 #include <krb5.h>
17536
17537 int
17538 main ()
17539 {
17540 static krb5_error ac_aggr;
17541 if (sizeof ac_aggr.e_data)
17542 return 0;
17543   ;
17544   return 0;
17545 }
17546 _ACEOF
17547 rm -f conftest.$ac_objext
17548 if { (ac_try="$ac_compile"
17549 case "(($ac_try" in
17550   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17551   *) ac_try_echo=$ac_try;;
17552 esac
17553 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17554 $as_echo "$ac_try_echo") >&5
17555   (eval "$ac_compile") 2>conftest.er1
17556   ac_status=$?
17557   grep -v '^ *+' conftest.er1 >conftest.err
17558   rm -f conftest.er1
17559   cat conftest.err >&5
17560   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17561   (exit $ac_status); } && {
17562          test -z "$ac_c_werror_flag" ||
17563          test ! -s conftest.err
17564        } && test -s conftest.$ac_objext; then
17565   ac_cv_member_krb5_error_e_data=yes
17566 else
17567   $as_echo "$as_me: failed program was:" >&5
17568 sed 's/^/| /' conftest.$ac_ext >&5
17569
17570         ac_cv_member_krb5_error_e_data=no
17571 fi
17572
17573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17574 fi
17575
17576 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17577 fi
17578 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
17579 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
17580 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
17581
17582 cat >>confdefs.h <<_ACEOF
17583 #define HAVE_KRB5_ERROR_E_DATA 1
17584 _ACEOF
17585
17586
17587 else
17588   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
17589 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
17590    { (exit 1); exit 1; }; }
17591 fi
17592
17593 fi
17594
17595
17596 # Win32 requires headers to be loaded for __stdcall, so can't use
17597 # AC_CHECK_FUNCS here.
17598   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
17599 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
17600   cat >conftest.$ac_ext <<_ACEOF
17601 /* confdefs.h.  */
17602 _ACEOF
17603 cat confdefs.h >>conftest.$ac_ext
17604 cat >>conftest.$ac_ext <<_ACEOF
17605 /* end confdefs.h.  */
17606 #include <krb5.h>
17607 int
17608 main ()
17609 {
17610 krb5_free_unparsed_name(NULL,NULL);
17611   ;
17612   return 0;
17613 }
17614 _ACEOF
17615 rm -f conftest.$ac_objext conftest$ac_exeext
17616 if { (ac_try="$ac_link"
17617 case "(($ac_try" in
17618   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17619   *) ac_try_echo=$ac_try;;
17620 esac
17621 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17622 $as_echo "$ac_try_echo") >&5
17623   (eval "$ac_link") 2>conftest.er1
17624   ac_status=$?
17625   grep -v '^ *+' conftest.er1 >conftest.err
17626   rm -f conftest.er1
17627   cat conftest.err >&5
17628   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17629   (exit $ac_status); } && {
17630          test -z "$ac_c_werror_flag" ||
17631          test ! -s conftest.err
17632        } && test -s conftest$ac_exeext && {
17633          test "$cross_compiling" = yes ||
17634          $as_test_x conftest$ac_exeext
17635        }; then
17636
17637 cat >>confdefs.h <<\_ACEOF
17638 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
17639 _ACEOF
17640
17641 { $as_echo "$as_me:$LINENO: result: yes" >&5
17642 $as_echo "yes" >&6; }
17643 else
17644   $as_echo "$as_me: failed program was:" >&5
17645 sed 's/^/| /' conftest.$ac_ext >&5
17646
17647         { $as_echo "$as_me:$LINENO: result: no" >&5
17648 $as_echo "no" >&6; }
17649 fi
17650
17651 rm -rf conftest.dSYM
17652 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17653       conftest$ac_exeext conftest.$ac_ext
17654 fi
17655
17656 # Check largefile support.  You might think this is a system service not a
17657 # compiler characteristic, but you'd be wrong.  We must check this before
17658 # probing existence of related functions such as fseeko, since the largefile
17659 # defines can affect what is generated for that.
17660 # Check whether --enable-largefile was given.
17661 if test "${enable_largefile+set}" = set; then
17662   enableval=$enable_largefile;
17663 fi
17664
17665 if test "$enable_largefile" != no; then
17666
17667   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
17668 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
17669 if test "${ac_cv_sys_largefile_CC+set}" = set; then
17670   $as_echo_n "(cached) " >&6
17671 else
17672   ac_cv_sys_largefile_CC=no
17673      if test "$GCC" != yes; then
17674        ac_save_CC=$CC
17675        while :; do
17676          # IRIX 6.2 and later do not support large files by default,
17677          # so use the C compiler's -n32 option if that helps.
17678          cat >conftest.$ac_ext <<_ACEOF
17679 /* confdefs.h.  */
17680 _ACEOF
17681 cat confdefs.h >>conftest.$ac_ext
17682 cat >>conftest.$ac_ext <<_ACEOF
17683 /* end confdefs.h.  */
17684 #include <sys/types.h>
17685  /* Check that off_t can represent 2**63 - 1 correctly.
17686     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17687     since some C++ compilers masquerading as C compilers
17688     incorrectly reject 9223372036854775807.  */
17689 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17690   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17691                        && LARGE_OFF_T % 2147483647 == 1)
17692                       ? 1 : -1];
17693 int
17694 main ()
17695 {
17696
17697   ;
17698   return 0;
17699 }
17700 _ACEOF
17701          rm -f conftest.$ac_objext
17702 if { (ac_try="$ac_compile"
17703 case "(($ac_try" in
17704   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17705   *) ac_try_echo=$ac_try;;
17706 esac
17707 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17708 $as_echo "$ac_try_echo") >&5
17709   (eval "$ac_compile") 2>conftest.er1
17710   ac_status=$?
17711   grep -v '^ *+' conftest.er1 >conftest.err
17712   rm -f conftest.er1
17713   cat conftest.err >&5
17714   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17715   (exit $ac_status); } && {
17716          test -z "$ac_c_werror_flag" ||
17717          test ! -s conftest.err
17718        } && test -s conftest.$ac_objext; then
17719   break
17720 else
17721   $as_echo "$as_me: failed program was:" >&5
17722 sed 's/^/| /' conftest.$ac_ext >&5
17723
17724
17725 fi
17726
17727 rm -f core conftest.err conftest.$ac_objext
17728          CC="$CC -n32"
17729          rm -f conftest.$ac_objext
17730 if { (ac_try="$ac_compile"
17731 case "(($ac_try" in
17732   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17733   *) ac_try_echo=$ac_try;;
17734 esac
17735 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17736 $as_echo "$ac_try_echo") >&5
17737   (eval "$ac_compile") 2>conftest.er1
17738   ac_status=$?
17739   grep -v '^ *+' conftest.er1 >conftest.err
17740   rm -f conftest.er1
17741   cat conftest.err >&5
17742   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17743   (exit $ac_status); } && {
17744          test -z "$ac_c_werror_flag" ||
17745          test ! -s conftest.err
17746        } && test -s conftest.$ac_objext; then
17747   ac_cv_sys_largefile_CC=' -n32'; break
17748 else
17749   $as_echo "$as_me: failed program was:" >&5
17750 sed 's/^/| /' conftest.$ac_ext >&5
17751
17752
17753 fi
17754
17755 rm -f core conftest.err conftest.$ac_objext
17756          break
17757        done
17758        CC=$ac_save_CC
17759        rm -f conftest.$ac_ext
17760     fi
17761 fi
17762 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
17763 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
17764   if test "$ac_cv_sys_largefile_CC" != no; then
17765     CC=$CC$ac_cv_sys_largefile_CC
17766   fi
17767
17768   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
17769 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
17770 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
17771   $as_echo_n "(cached) " >&6
17772 else
17773   while :; do
17774   cat >conftest.$ac_ext <<_ACEOF
17775 /* confdefs.h.  */
17776 _ACEOF
17777 cat confdefs.h >>conftest.$ac_ext
17778 cat >>conftest.$ac_ext <<_ACEOF
17779 /* end confdefs.h.  */
17780 #include <sys/types.h>
17781  /* Check that off_t can represent 2**63 - 1 correctly.
17782     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17783     since some C++ compilers masquerading as C compilers
17784     incorrectly reject 9223372036854775807.  */
17785 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17786   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17787                        && LARGE_OFF_T % 2147483647 == 1)
17788                       ? 1 : -1];
17789 int
17790 main ()
17791 {
17792
17793   ;
17794   return 0;
17795 }
17796 _ACEOF
17797 rm -f conftest.$ac_objext
17798 if { (ac_try="$ac_compile"
17799 case "(($ac_try" in
17800   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17801   *) ac_try_echo=$ac_try;;
17802 esac
17803 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17804 $as_echo "$ac_try_echo") >&5
17805   (eval "$ac_compile") 2>conftest.er1
17806   ac_status=$?
17807   grep -v '^ *+' conftest.er1 >conftest.err
17808   rm -f conftest.er1
17809   cat conftest.err >&5
17810   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17811   (exit $ac_status); } && {
17812          test -z "$ac_c_werror_flag" ||
17813          test ! -s conftest.err
17814        } && test -s conftest.$ac_objext; then
17815   ac_cv_sys_file_offset_bits=no; break
17816 else
17817   $as_echo "$as_me: failed program was:" >&5
17818 sed 's/^/| /' conftest.$ac_ext >&5
17819
17820
17821 fi
17822
17823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17824   cat >conftest.$ac_ext <<_ACEOF
17825 /* confdefs.h.  */
17826 _ACEOF
17827 cat confdefs.h >>conftest.$ac_ext
17828 cat >>conftest.$ac_ext <<_ACEOF
17829 /* end confdefs.h.  */
17830 #define _FILE_OFFSET_BITS 64
17831 #include <sys/types.h>
17832  /* Check that off_t can represent 2**63 - 1 correctly.
17833     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17834     since some C++ compilers masquerading as C compilers
17835     incorrectly reject 9223372036854775807.  */
17836 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17837   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17838                        && LARGE_OFF_T % 2147483647 == 1)
17839                       ? 1 : -1];
17840 int
17841 main ()
17842 {
17843
17844   ;
17845   return 0;
17846 }
17847 _ACEOF
17848 rm -f conftest.$ac_objext
17849 if { (ac_try="$ac_compile"
17850 case "(($ac_try" in
17851   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17852   *) ac_try_echo=$ac_try;;
17853 esac
17854 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17855 $as_echo "$ac_try_echo") >&5
17856   (eval "$ac_compile") 2>conftest.er1
17857   ac_status=$?
17858   grep -v '^ *+' conftest.er1 >conftest.err
17859   rm -f conftest.er1
17860   cat conftest.err >&5
17861   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17862   (exit $ac_status); } && {
17863          test -z "$ac_c_werror_flag" ||
17864          test ! -s conftest.err
17865        } && test -s conftest.$ac_objext; then
17866   ac_cv_sys_file_offset_bits=64; break
17867 else
17868   $as_echo "$as_me: failed program was:" >&5
17869 sed 's/^/| /' conftest.$ac_ext >&5
17870
17871
17872 fi
17873
17874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17875   ac_cv_sys_file_offset_bits=unknown
17876   break
17877 done
17878 fi
17879 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
17880 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
17881 case $ac_cv_sys_file_offset_bits in #(
17882   no | unknown) ;;
17883   *)
17884 cat >>confdefs.h <<_ACEOF
17885 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
17886 _ACEOF
17887 ;;
17888 esac
17889 rm -rf conftest*
17890   if test $ac_cv_sys_file_offset_bits = unknown; then
17891     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
17892 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
17893 if test "${ac_cv_sys_large_files+set}" = set; then
17894   $as_echo_n "(cached) " >&6
17895 else
17896   while :; do
17897   cat >conftest.$ac_ext <<_ACEOF
17898 /* confdefs.h.  */
17899 _ACEOF
17900 cat confdefs.h >>conftest.$ac_ext
17901 cat >>conftest.$ac_ext <<_ACEOF
17902 /* end confdefs.h.  */
17903 #include <sys/types.h>
17904  /* Check that off_t can represent 2**63 - 1 correctly.
17905     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17906     since some C++ compilers masquerading as C compilers
17907     incorrectly reject 9223372036854775807.  */
17908 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17909   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17910                        && LARGE_OFF_T % 2147483647 == 1)
17911                       ? 1 : -1];
17912 int
17913 main ()
17914 {
17915
17916   ;
17917   return 0;
17918 }
17919 _ACEOF
17920 rm -f conftest.$ac_objext
17921 if { (ac_try="$ac_compile"
17922 case "(($ac_try" in
17923   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17924   *) ac_try_echo=$ac_try;;
17925 esac
17926 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17927 $as_echo "$ac_try_echo") >&5
17928   (eval "$ac_compile") 2>conftest.er1
17929   ac_status=$?
17930   grep -v '^ *+' conftest.er1 >conftest.err
17931   rm -f conftest.er1
17932   cat conftest.err >&5
17933   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17934   (exit $ac_status); } && {
17935          test -z "$ac_c_werror_flag" ||
17936          test ! -s conftest.err
17937        } && test -s conftest.$ac_objext; then
17938   ac_cv_sys_large_files=no; break
17939 else
17940   $as_echo "$as_me: failed program was:" >&5
17941 sed 's/^/| /' conftest.$ac_ext >&5
17942
17943
17944 fi
17945
17946 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17947   cat >conftest.$ac_ext <<_ACEOF
17948 /* confdefs.h.  */
17949 _ACEOF
17950 cat confdefs.h >>conftest.$ac_ext
17951 cat >>conftest.$ac_ext <<_ACEOF
17952 /* end confdefs.h.  */
17953 #define _LARGE_FILES 1
17954 #include <sys/types.h>
17955  /* Check that off_t can represent 2**63 - 1 correctly.
17956     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17957     since some C++ compilers masquerading as C compilers
17958     incorrectly reject 9223372036854775807.  */
17959 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17960   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17961                        && LARGE_OFF_T % 2147483647 == 1)
17962                       ? 1 : -1];
17963 int
17964 main ()
17965 {
17966
17967   ;
17968   return 0;
17969 }
17970 _ACEOF
17971 rm -f conftest.$ac_objext
17972 if { (ac_try="$ac_compile"
17973 case "(($ac_try" in
17974   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17975   *) ac_try_echo=$ac_try;;
17976 esac
17977 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17978 $as_echo "$ac_try_echo") >&5
17979   (eval "$ac_compile") 2>conftest.er1
17980   ac_status=$?
17981   grep -v '^ *+' conftest.er1 >conftest.err
17982   rm -f conftest.er1
17983   cat conftest.err >&5
17984   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17985   (exit $ac_status); } && {
17986          test -z "$ac_c_werror_flag" ||
17987          test ! -s conftest.err
17988        } && test -s conftest.$ac_objext; then
17989   ac_cv_sys_large_files=1; break
17990 else
17991   $as_echo "$as_me: failed program was:" >&5
17992 sed 's/^/| /' conftest.$ac_ext >&5
17993
17994
17995 fi
17996
17997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17998   ac_cv_sys_large_files=unknown
17999   break
18000 done
18001 fi
18002 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
18003 $as_echo "$ac_cv_sys_large_files" >&6; }
18004 case $ac_cv_sys_large_files in #(
18005   no | unknown) ;;
18006   *)
18007 cat >>confdefs.h <<_ACEOF
18008 #define _LARGE_FILES $ac_cv_sys_large_files
18009 _ACEOF
18010 ;;
18011 esac
18012 rm -rf conftest*
18013   fi
18014 fi
18015
18016
18017 # Check for largefile support (must be after AC_SYS_LARGEFILE)
18018 # The cast to long int works around a bug in the HP C Compiler
18019 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18020 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18021 # This bug is HP SR number 8606223364.
18022 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
18023 $as_echo_n "checking size of off_t... " >&6; }
18024 if test "${ac_cv_sizeof_off_t+set}" = set; then
18025   $as_echo_n "(cached) " >&6
18026 else
18027   if test "$cross_compiling" = yes; then
18028   # Depending upon the size, compute the lo and hi bounds.
18029 cat >conftest.$ac_ext <<_ACEOF
18030 /* confdefs.h.  */
18031 _ACEOF
18032 cat confdefs.h >>conftest.$ac_ext
18033 cat >>conftest.$ac_ext <<_ACEOF
18034 /* end confdefs.h.  */
18035 $ac_includes_default
18036 int
18037 main ()
18038 {
18039 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
18040 test_array [0] = 0
18041
18042   ;
18043   return 0;
18044 }
18045 _ACEOF
18046 rm -f conftest.$ac_objext
18047 if { (ac_try="$ac_compile"
18048 case "(($ac_try" in
18049   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18050   *) ac_try_echo=$ac_try;;
18051 esac
18052 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18053 $as_echo "$ac_try_echo") >&5
18054   (eval "$ac_compile") 2>conftest.er1
18055   ac_status=$?
18056   grep -v '^ *+' conftest.er1 >conftest.err
18057   rm -f conftest.er1
18058   cat conftest.err >&5
18059   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18060   (exit $ac_status); } && {
18061          test -z "$ac_c_werror_flag" ||
18062          test ! -s conftest.err
18063        } && test -s conftest.$ac_objext; then
18064   ac_lo=0 ac_mid=0
18065   while :; do
18066     cat >conftest.$ac_ext <<_ACEOF
18067 /* confdefs.h.  */
18068 _ACEOF
18069 cat confdefs.h >>conftest.$ac_ext
18070 cat >>conftest.$ac_ext <<_ACEOF
18071 /* end confdefs.h.  */
18072 $ac_includes_default
18073 int
18074 main ()
18075 {
18076 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18077 test_array [0] = 0
18078
18079   ;
18080   return 0;
18081 }
18082 _ACEOF
18083 rm -f conftest.$ac_objext
18084 if { (ac_try="$ac_compile"
18085 case "(($ac_try" in
18086   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18087   *) ac_try_echo=$ac_try;;
18088 esac
18089 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18090 $as_echo "$ac_try_echo") >&5
18091   (eval "$ac_compile") 2>conftest.er1
18092   ac_status=$?
18093   grep -v '^ *+' conftest.er1 >conftest.err
18094   rm -f conftest.er1
18095   cat conftest.err >&5
18096   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18097   (exit $ac_status); } && {
18098          test -z "$ac_c_werror_flag" ||
18099          test ! -s conftest.err
18100        } && test -s conftest.$ac_objext; then
18101   ac_hi=$ac_mid; break
18102 else
18103   $as_echo "$as_me: failed program was:" >&5
18104 sed 's/^/| /' conftest.$ac_ext >&5
18105
18106         ac_lo=`expr $ac_mid + 1`
18107                         if test $ac_lo -le $ac_mid; then
18108                           ac_lo= ac_hi=
18109                           break
18110                         fi
18111                         ac_mid=`expr 2 '*' $ac_mid + 1`
18112 fi
18113
18114 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18115   done
18116 else
18117   $as_echo "$as_me: failed program was:" >&5
18118 sed 's/^/| /' conftest.$ac_ext >&5
18119
18120         cat >conftest.$ac_ext <<_ACEOF
18121 /* confdefs.h.  */
18122 _ACEOF
18123 cat confdefs.h >>conftest.$ac_ext
18124 cat >>conftest.$ac_ext <<_ACEOF
18125 /* end confdefs.h.  */
18126 $ac_includes_default
18127 int
18128 main ()
18129 {
18130 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
18131 test_array [0] = 0
18132
18133   ;
18134   return 0;
18135 }
18136 _ACEOF
18137 rm -f conftest.$ac_objext
18138 if { (ac_try="$ac_compile"
18139 case "(($ac_try" in
18140   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18141   *) ac_try_echo=$ac_try;;
18142 esac
18143 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18144 $as_echo "$ac_try_echo") >&5
18145   (eval "$ac_compile") 2>conftest.er1
18146   ac_status=$?
18147   grep -v '^ *+' conftest.er1 >conftest.err
18148   rm -f conftest.er1
18149   cat conftest.err >&5
18150   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18151   (exit $ac_status); } && {
18152          test -z "$ac_c_werror_flag" ||
18153          test ! -s conftest.err
18154        } && test -s conftest.$ac_objext; then
18155   ac_hi=-1 ac_mid=-1
18156   while :; do
18157     cat >conftest.$ac_ext <<_ACEOF
18158 /* confdefs.h.  */
18159 _ACEOF
18160 cat confdefs.h >>conftest.$ac_ext
18161 cat >>conftest.$ac_ext <<_ACEOF
18162 /* end confdefs.h.  */
18163 $ac_includes_default
18164 int
18165 main ()
18166 {
18167 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
18168 test_array [0] = 0
18169
18170   ;
18171   return 0;
18172 }
18173 _ACEOF
18174 rm -f conftest.$ac_objext
18175 if { (ac_try="$ac_compile"
18176 case "(($ac_try" in
18177   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18178   *) ac_try_echo=$ac_try;;
18179 esac
18180 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18181 $as_echo "$ac_try_echo") >&5
18182   (eval "$ac_compile") 2>conftest.er1
18183   ac_status=$?
18184   grep -v '^ *+' conftest.er1 >conftest.err
18185   rm -f conftest.er1
18186   cat conftest.err >&5
18187   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18188   (exit $ac_status); } && {
18189          test -z "$ac_c_werror_flag" ||
18190          test ! -s conftest.err
18191        } && test -s conftest.$ac_objext; then
18192   ac_lo=$ac_mid; break
18193 else
18194   $as_echo "$as_me: failed program was:" >&5
18195 sed 's/^/| /' conftest.$ac_ext >&5
18196
18197         ac_hi=`expr '(' $ac_mid ')' - 1`
18198                         if test $ac_mid -le $ac_hi; then
18199                           ac_lo= ac_hi=
18200                           break
18201                         fi
18202                         ac_mid=`expr 2 '*' $ac_mid`
18203 fi
18204
18205 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18206   done
18207 else
18208   $as_echo "$as_me: failed program was:" >&5
18209 sed 's/^/| /' conftest.$ac_ext >&5
18210
18211         ac_lo= ac_hi=
18212 fi
18213
18214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18215 fi
18216
18217 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18218 # Binary search between lo and hi bounds.
18219 while test "x$ac_lo" != "x$ac_hi"; do
18220   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18221   cat >conftest.$ac_ext <<_ACEOF
18222 /* confdefs.h.  */
18223 _ACEOF
18224 cat confdefs.h >>conftest.$ac_ext
18225 cat >>conftest.$ac_ext <<_ACEOF
18226 /* end confdefs.h.  */
18227 $ac_includes_default
18228 int
18229 main ()
18230 {
18231 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18232 test_array [0] = 0
18233
18234   ;
18235   return 0;
18236 }
18237 _ACEOF
18238 rm -f conftest.$ac_objext
18239 if { (ac_try="$ac_compile"
18240 case "(($ac_try" in
18241   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18242   *) ac_try_echo=$ac_try;;
18243 esac
18244 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18245 $as_echo "$ac_try_echo") >&5
18246   (eval "$ac_compile") 2>conftest.er1
18247   ac_status=$?
18248   grep -v '^ *+' conftest.er1 >conftest.err
18249   rm -f conftest.er1
18250   cat conftest.err >&5
18251   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18252   (exit $ac_status); } && {
18253          test -z "$ac_c_werror_flag" ||
18254          test ! -s conftest.err
18255        } && test -s conftest.$ac_objext; then
18256   ac_hi=$ac_mid
18257 else
18258   $as_echo "$as_me: failed program was:" >&5
18259 sed 's/^/| /' conftest.$ac_ext >&5
18260
18261         ac_lo=`expr '(' $ac_mid ')' + 1`
18262 fi
18263
18264 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18265 done
18266 case $ac_lo in
18267 ?*) ac_cv_sizeof_off_t=$ac_lo;;
18268 '') if test "$ac_cv_type_off_t" = yes; then
18269      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18270 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18271 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18272 See \`config.log' for more details." >&5
18273 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18274 See \`config.log' for more details." >&2;}
18275    { (exit 77); exit 77; }; }; }
18276    else
18277      ac_cv_sizeof_off_t=0
18278    fi ;;
18279 esac
18280 else
18281   cat >conftest.$ac_ext <<_ACEOF
18282 /* confdefs.h.  */
18283 _ACEOF
18284 cat confdefs.h >>conftest.$ac_ext
18285 cat >>conftest.$ac_ext <<_ACEOF
18286 /* end confdefs.h.  */
18287 $ac_includes_default
18288 static long int longval () { return (long int) (sizeof (off_t)); }
18289 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
18290 #include <stdio.h>
18291 #include <stdlib.h>
18292 int
18293 main ()
18294 {
18295
18296   FILE *f = fopen ("conftest.val", "w");
18297   if (! f)
18298     return 1;
18299   if (((long int) (sizeof (off_t))) < 0)
18300     {
18301       long int i = longval ();
18302       if (i != ((long int) (sizeof (off_t))))
18303         return 1;
18304       fprintf (f, "%ld", i);
18305     }
18306   else
18307     {
18308       unsigned long int i = ulongval ();
18309       if (i != ((long int) (sizeof (off_t))))
18310         return 1;
18311       fprintf (f, "%lu", i);
18312     }
18313   /* Do not output a trailing newline, as this causes \r\n confusion
18314      on some platforms.  */
18315   return ferror (f) || fclose (f) != 0;
18316
18317   ;
18318   return 0;
18319 }
18320 _ACEOF
18321 rm -f conftest$ac_exeext
18322 if { (ac_try="$ac_link"
18323 case "(($ac_try" in
18324   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18325   *) ac_try_echo=$ac_try;;
18326 esac
18327 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18328 $as_echo "$ac_try_echo") >&5
18329   (eval "$ac_link") 2>&5
18330   ac_status=$?
18331   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18332   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18333   { (case "(($ac_try" in
18334   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18335   *) ac_try_echo=$ac_try;;
18336 esac
18337 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18338 $as_echo "$ac_try_echo") >&5
18339   (eval "$ac_try") 2>&5
18340   ac_status=$?
18341   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18342   (exit $ac_status); }; }; then
18343   ac_cv_sizeof_off_t=`cat conftest.val`
18344 else
18345   $as_echo "$as_me: program exited with status $ac_status" >&5
18346 $as_echo "$as_me: failed program was:" >&5
18347 sed 's/^/| /' conftest.$ac_ext >&5
18348
18349 ( exit $ac_status )
18350 if test "$ac_cv_type_off_t" = yes; then
18351      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18352 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18353 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18354 See \`config.log' for more details." >&5
18355 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18356 See \`config.log' for more details." >&2;}
18357    { (exit 77); exit 77; }; }; }
18358    else
18359      ac_cv_sizeof_off_t=0
18360    fi
18361 fi
18362 rm -rf conftest.dSYM
18363 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18364 fi
18365 rm -f conftest.val
18366 fi
18367 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
18368 $as_echo "$ac_cv_sizeof_off_t" >&6; }
18369
18370
18371
18372 cat >>confdefs.h <<_ACEOF
18373 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
18374 _ACEOF
18375
18376
18377
18378 # If we don't have largefile support, can't handle segsize >= 2GB.
18379 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
18380    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
18381 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
18382    { (exit 1); exit 1; }; }
18383 fi
18384
18385
18386 ##
18387 ## Functions, global variables
18388 ##
18389
18390 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
18391 $as_echo_n "checking for int timezone... " >&6; }
18392 if test "${pgac_cv_var_int_timezone+set}" = set; then
18393   $as_echo_n "(cached) " >&6
18394 else
18395   cat >conftest.$ac_ext <<_ACEOF
18396 /* confdefs.h.  */
18397 _ACEOF
18398 cat confdefs.h >>conftest.$ac_ext
18399 cat >>conftest.$ac_ext <<_ACEOF
18400 /* end confdefs.h.  */
18401 #include <time.h>
18402 int res;
18403 int
18404 main ()
18405 {
18406 #ifndef __CYGWIN__
18407 res = timezone / 60;
18408 #else
18409 res = _timezone / 60;
18410 #endif
18411   ;
18412   return 0;
18413 }
18414 _ACEOF
18415 rm -f conftest.$ac_objext conftest$ac_exeext
18416 if { (ac_try="$ac_link"
18417 case "(($ac_try" in
18418   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18419   *) ac_try_echo=$ac_try;;
18420 esac
18421 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18422 $as_echo "$ac_try_echo") >&5
18423   (eval "$ac_link") 2>conftest.er1
18424   ac_status=$?
18425   grep -v '^ *+' conftest.er1 >conftest.err
18426   rm -f conftest.er1
18427   cat conftest.err >&5
18428   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18429   (exit $ac_status); } && {
18430          test -z "$ac_c_werror_flag" ||
18431          test ! -s conftest.err
18432        } && test -s conftest$ac_exeext && {
18433          test "$cross_compiling" = yes ||
18434          $as_test_x conftest$ac_exeext
18435        }; then
18436   pgac_cv_var_int_timezone=yes
18437 else
18438   $as_echo "$as_me: failed program was:" >&5
18439 sed 's/^/| /' conftest.$ac_ext >&5
18440
18441         pgac_cv_var_int_timezone=no
18442 fi
18443
18444 rm -rf conftest.dSYM
18445 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18446       conftest$ac_exeext conftest.$ac_ext
18447 fi
18448 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
18449 $as_echo "$pgac_cv_var_int_timezone" >&6; }
18450 if test x"$pgac_cv_var_int_timezone" = xyes ; then
18451
18452 cat >>confdefs.h <<\_ACEOF
18453 #define HAVE_INT_TIMEZONE /**/
18454 _ACEOF
18455
18456 fi
18457 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
18458 $as_echo_n "checking types of arguments for accept()... " >&6; }
18459  if test "${ac_cv_func_accept_return+set}" = set; then
18460   $as_echo_n "(cached) " >&6
18461 else
18462    if test "${ac_cv_func_accept_arg1+set}" = set; then
18463   $as_echo_n "(cached) " >&6
18464 else
18465     if test "${ac_cv_func_accept_arg2+set}" = set; then
18466   $as_echo_n "(cached) " >&6
18467 else
18468      if test "${ac_cv_func_accept_arg3+set}" = set; then
18469   $as_echo_n "(cached) " >&6
18470 else
18471       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
18472       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
18473        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
18474         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
18475          cat >conftest.$ac_ext <<_ACEOF
18476 /* confdefs.h.  */
18477 _ACEOF
18478 cat confdefs.h >>conftest.$ac_ext
18479 cat >>conftest.$ac_ext <<_ACEOF
18480 /* end confdefs.h.  */
18481 #ifdef HAVE_SYS_TYPES_H
18482 #include <sys/types.h>
18483 #endif
18484 #ifdef HAVE_SYS_SOCKET_H
18485 #include <sys/socket.h>
18486 #endif
18487 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
18488 int
18489 main ()
18490 {
18491
18492   ;
18493   return 0;
18494 }
18495 _ACEOF
18496 rm -f conftest.$ac_objext
18497 if { (ac_try="$ac_compile"
18498 case "(($ac_try" in
18499   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18500   *) ac_try_echo=$ac_try;;
18501 esac
18502 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18503 $as_echo "$ac_try_echo") >&5
18504   (eval "$ac_compile") 2>conftest.er1
18505   ac_status=$?
18506   grep -v '^ *+' conftest.er1 >conftest.err
18507   rm -f conftest.er1
18508   cat conftest.err >&5
18509   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18510   (exit $ac_status); } && {
18511          test -z "$ac_c_werror_flag" ||
18512          test ! -s conftest.err
18513        } && test -s conftest.$ac_objext; then
18514   ac_not_found=no; break 4
18515 else
18516   $as_echo "$as_me: failed program was:" >&5
18517 sed 's/^/| /' conftest.$ac_ext >&5
18518
18519         ac_not_found=yes
18520 fi
18521
18522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18523        done
18524       done
18525      done
18526     done
18527     if test "$ac_not_found" = yes; then
18528       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
18529 $as_echo "$as_me: error: could not determine argument types" >&2;}
18530    { (exit 1); exit 1; }; }
18531     fi
18532     if test "$ac_cv_func_accept_arg3" = "void"; then
18533       ac_cv_func_accept_arg3=int
18534     fi
18535
18536 fi
18537
18538 fi
18539
18540 fi
18541
18542 fi
18543  { $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
18544 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
18545
18546 cat >>confdefs.h <<_ACEOF
18547 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
18548 _ACEOF
18549
18550
18551 cat >>confdefs.h <<_ACEOF
18552 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
18553 _ACEOF
18554
18555
18556 cat >>confdefs.h <<_ACEOF
18557 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
18558 _ACEOF
18559
18560
18561 cat >>confdefs.h <<_ACEOF
18562 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
18563 _ACEOF
18564
18565
18566 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
18567 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
18568 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
18569   $as_echo_n "(cached) " >&6
18570 else
18571   cat >conftest.$ac_ext <<_ACEOF
18572 /* confdefs.h.  */
18573 _ACEOF
18574 cat confdefs.h >>conftest.$ac_ext
18575 cat >>conftest.$ac_ext <<_ACEOF
18576 /* end confdefs.h.  */
18577 #include <sys/time.h>
18578 int
18579 main ()
18580 {
18581 struct timeval *tp;
18582 struct timezone *tzp;
18583 gettimeofday(tp,tzp);
18584   ;
18585   return 0;
18586 }
18587 _ACEOF
18588 rm -f conftest.$ac_objext
18589 if { (ac_try="$ac_compile"
18590 case "(($ac_try" in
18591   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18592   *) ac_try_echo=$ac_try;;
18593 esac
18594 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18595 $as_echo "$ac_try_echo") >&5
18596   (eval "$ac_compile") 2>conftest.er1
18597   ac_status=$?
18598   grep -v '^ *+' conftest.er1 >conftest.err
18599   rm -f conftest.er1
18600   cat conftest.err >&5
18601   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18602   (exit $ac_status); } && {
18603          test -z "$ac_c_werror_flag" ||
18604          test ! -s conftest.err
18605        } && test -s conftest.$ac_objext; then
18606   pgac_cv_func_gettimeofday_1arg=no
18607 else
18608   $as_echo "$as_me: failed program was:" >&5
18609 sed 's/^/| /' conftest.$ac_ext >&5
18610
18611         pgac_cv_func_gettimeofday_1arg=yes
18612 fi
18613
18614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18615 fi
18616 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
18617 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
18618 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
18619
18620 cat >>confdefs.h <<\_ACEOF
18621 #define GETTIMEOFDAY_1ARG /**/
18622 _ACEOF
18623
18624 fi
18625
18626
18627
18628
18629
18630
18631
18632
18633
18634
18635
18636
18637
18638
18639
18640
18641
18642
18643
18644
18645
18646
18647
18648
18649
18650
18651 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
18652 do
18653 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18654 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18655 $as_echo_n "checking for $ac_func... " >&6; }
18656 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18657   $as_echo_n "(cached) " >&6
18658 else
18659   cat >conftest.$ac_ext <<_ACEOF
18660 /* confdefs.h.  */
18661 _ACEOF
18662 cat confdefs.h >>conftest.$ac_ext
18663 cat >>conftest.$ac_ext <<_ACEOF
18664 /* end confdefs.h.  */
18665 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18666    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18667 #define $ac_func innocuous_$ac_func
18668
18669 /* System header to define __stub macros and hopefully few prototypes,
18670     which can conflict with char $ac_func (); below.
18671     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18672     <limits.h> exists even on freestanding compilers.  */
18673
18674 #ifdef __STDC__
18675 # include <limits.h>
18676 #else
18677 # include <assert.h>
18678 #endif
18679
18680 #undef $ac_func
18681
18682 /* Override any GCC internal prototype to avoid an error.
18683    Use char because int might match the return type of a GCC
18684    builtin and then its argument prototype would still apply.  */
18685 #ifdef __cplusplus
18686 extern "C"
18687 #endif
18688 char $ac_func ();
18689 /* The GNU C library defines this for functions which it implements
18690     to always fail with ENOSYS.  Some functions are actually named
18691     something starting with __ and the normal name is an alias.  */
18692 #if defined __stub_$ac_func || defined __stub___$ac_func
18693 choke me
18694 #endif
18695
18696 int
18697 main ()
18698 {
18699 return $ac_func ();
18700   ;
18701   return 0;
18702 }
18703 _ACEOF
18704 rm -f conftest.$ac_objext conftest$ac_exeext
18705 if { (ac_try="$ac_link"
18706 case "(($ac_try" in
18707   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18708   *) ac_try_echo=$ac_try;;
18709 esac
18710 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18711 $as_echo "$ac_try_echo") >&5
18712   (eval "$ac_link") 2>conftest.er1
18713   ac_status=$?
18714   grep -v '^ *+' conftest.er1 >conftest.err
18715   rm -f conftest.er1
18716   cat conftest.err >&5
18717   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18718   (exit $ac_status); } && {
18719          test -z "$ac_c_werror_flag" ||
18720          test ! -s conftest.err
18721        } && test -s conftest$ac_exeext && {
18722          test "$cross_compiling" = yes ||
18723          $as_test_x conftest$ac_exeext
18724        }; then
18725   eval "$as_ac_var=yes"
18726 else
18727   $as_echo "$as_me: failed program was:" >&5
18728 sed 's/^/| /' conftest.$ac_ext >&5
18729
18730         eval "$as_ac_var=no"
18731 fi
18732
18733 rm -rf conftest.dSYM
18734 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18735       conftest$ac_exeext conftest.$ac_ext
18736 fi
18737 ac_res=`eval 'as_val=${'$as_ac_var'}
18738                  $as_echo "$as_val"'`
18739                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18740 $as_echo "$ac_res" >&6; }
18741 as_val=`eval 'as_val=${'$as_ac_var'}
18742                  $as_echo "$as_val"'`
18743    if test "x$as_val" = x""yes; then
18744   cat >>confdefs.h <<_ACEOF
18745 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18746 _ACEOF
18747
18748 fi
18749 done
18750
18751
18752
18753 for ac_func in fseeko
18754 do
18755 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18756 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18757 $as_echo_n "checking for $ac_func... " >&6; }
18758 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18759   $as_echo_n "(cached) " >&6
18760 else
18761   cat >conftest.$ac_ext <<_ACEOF
18762 /* confdefs.h.  */
18763 _ACEOF
18764 cat confdefs.h >>conftest.$ac_ext
18765 cat >>conftest.$ac_ext <<_ACEOF
18766 /* end confdefs.h.  */
18767 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18768    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18769 #define $ac_func innocuous_$ac_func
18770
18771 /* System header to define __stub macros and hopefully few prototypes,
18772     which can conflict with char $ac_func (); below.
18773     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18774     <limits.h> exists even on freestanding compilers.  */
18775
18776 #ifdef __STDC__
18777 # include <limits.h>
18778 #else
18779 # include <assert.h>
18780 #endif
18781
18782 #undef $ac_func
18783
18784 /* Override any GCC internal prototype to avoid an error.
18785    Use char because int might match the return type of a GCC
18786    builtin and then its argument prototype would still apply.  */
18787 #ifdef __cplusplus
18788 extern "C"
18789 #endif
18790 char $ac_func ();
18791 /* The GNU C library defines this for functions which it implements
18792     to always fail with ENOSYS.  Some functions are actually named
18793     something starting with __ and the normal name is an alias.  */
18794 #if defined __stub_$ac_func || defined __stub___$ac_func
18795 choke me
18796 #endif
18797
18798 int
18799 main ()
18800 {
18801 return $ac_func ();
18802   ;
18803   return 0;
18804 }
18805 _ACEOF
18806 rm -f conftest.$ac_objext conftest$ac_exeext
18807 if { (ac_try="$ac_link"
18808 case "(($ac_try" in
18809   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18810   *) ac_try_echo=$ac_try;;
18811 esac
18812 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18813 $as_echo "$ac_try_echo") >&5
18814   (eval "$ac_link") 2>conftest.er1
18815   ac_status=$?
18816   grep -v '^ *+' conftest.er1 >conftest.err
18817   rm -f conftest.er1
18818   cat conftest.err >&5
18819   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18820   (exit $ac_status); } && {
18821          test -z "$ac_c_werror_flag" ||
18822          test ! -s conftest.err
18823        } && test -s conftest$ac_exeext && {
18824          test "$cross_compiling" = yes ||
18825          $as_test_x conftest$ac_exeext
18826        }; then
18827   eval "$as_ac_var=yes"
18828 else
18829   $as_echo "$as_me: failed program was:" >&5
18830 sed 's/^/| /' conftest.$ac_ext >&5
18831
18832         eval "$as_ac_var=no"
18833 fi
18834
18835 rm -rf conftest.dSYM
18836 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18837       conftest$ac_exeext conftest.$ac_ext
18838 fi
18839 ac_res=`eval 'as_val=${'$as_ac_var'}
18840                  $as_echo "$as_val"'`
18841                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18842 $as_echo "$ac_res" >&6; }
18843 as_val=`eval 'as_val=${'$as_ac_var'}
18844                  $as_echo "$as_val"'`
18845    if test "x$as_val" = x""yes; then
18846   cat >>confdefs.h <<_ACEOF
18847 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18848 _ACEOF
18849
18850 else
18851   case " $LIBOBJS " in
18852   *" $ac_func.$ac_objext "* ) ;;
18853   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18854  ;;
18855 esac
18856
18857 fi
18858 done
18859
18860
18861 case $host_os in
18862         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
18863         # Mingw uses macros to access Win32 API calls
18864         bsdi*|netbsd*|mingw*)
18865
18866 cat >>confdefs.h <<\_ACEOF
18867 #define HAVE_FSEEKO 1
18868 _ACEOF
18869
18870                 ac_cv_func_fseeko=yes;;
18871         *)
18872                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
18873 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
18874 if test "${ac_cv_sys_largefile_source+set}" = set; then
18875   $as_echo_n "(cached) " >&6
18876 else
18877   while :; do
18878   cat >conftest.$ac_ext <<_ACEOF
18879 /* confdefs.h.  */
18880 _ACEOF
18881 cat confdefs.h >>conftest.$ac_ext
18882 cat >>conftest.$ac_ext <<_ACEOF
18883 /* end confdefs.h.  */
18884 #include <sys/types.h> /* for off_t */
18885      #include <stdio.h>
18886 int
18887 main ()
18888 {
18889 int (*fp) (FILE *, off_t, int) = fseeko;
18890      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18891   ;
18892   return 0;
18893 }
18894 _ACEOF
18895 rm -f conftest.$ac_objext conftest$ac_exeext
18896 if { (ac_try="$ac_link"
18897 case "(($ac_try" in
18898   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18899   *) ac_try_echo=$ac_try;;
18900 esac
18901 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18902 $as_echo "$ac_try_echo") >&5
18903   (eval "$ac_link") 2>conftest.er1
18904   ac_status=$?
18905   grep -v '^ *+' conftest.er1 >conftest.err
18906   rm -f conftest.er1
18907   cat conftest.err >&5
18908   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18909   (exit $ac_status); } && {
18910          test -z "$ac_c_werror_flag" ||
18911          test ! -s conftest.err
18912        } && test -s conftest$ac_exeext && {
18913          test "$cross_compiling" = yes ||
18914          $as_test_x conftest$ac_exeext
18915        }; then
18916   ac_cv_sys_largefile_source=no; break
18917 else
18918   $as_echo "$as_me: failed program was:" >&5
18919 sed 's/^/| /' conftest.$ac_ext >&5
18920
18921
18922 fi
18923
18924 rm -rf conftest.dSYM
18925 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18926       conftest$ac_exeext conftest.$ac_ext
18927   cat >conftest.$ac_ext <<_ACEOF
18928 /* confdefs.h.  */
18929 _ACEOF
18930 cat confdefs.h >>conftest.$ac_ext
18931 cat >>conftest.$ac_ext <<_ACEOF
18932 /* end confdefs.h.  */
18933 #define _LARGEFILE_SOURCE 1
18934 #include <sys/types.h> /* for off_t */
18935      #include <stdio.h>
18936 int
18937 main ()
18938 {
18939 int (*fp) (FILE *, off_t, int) = fseeko;
18940      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18941   ;
18942   return 0;
18943 }
18944 _ACEOF
18945 rm -f conftest.$ac_objext conftest$ac_exeext
18946 if { (ac_try="$ac_link"
18947 case "(($ac_try" in
18948   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18949   *) ac_try_echo=$ac_try;;
18950 esac
18951 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18952 $as_echo "$ac_try_echo") >&5
18953   (eval "$ac_link") 2>conftest.er1
18954   ac_status=$?
18955   grep -v '^ *+' conftest.er1 >conftest.err
18956   rm -f conftest.er1
18957   cat conftest.err >&5
18958   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18959   (exit $ac_status); } && {
18960          test -z "$ac_c_werror_flag" ||
18961          test ! -s conftest.err
18962        } && test -s conftest$ac_exeext && {
18963          test "$cross_compiling" = yes ||
18964          $as_test_x conftest$ac_exeext
18965        }; then
18966   ac_cv_sys_largefile_source=1; break
18967 else
18968   $as_echo "$as_me: failed program was:" >&5
18969 sed 's/^/| /' conftest.$ac_ext >&5
18970
18971
18972 fi
18973
18974 rm -rf conftest.dSYM
18975 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18976       conftest$ac_exeext conftest.$ac_ext
18977   ac_cv_sys_largefile_source=unknown
18978   break
18979 done
18980 fi
18981 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
18982 $as_echo "$ac_cv_sys_largefile_source" >&6; }
18983 case $ac_cv_sys_largefile_source in #(
18984   no | unknown) ;;
18985   *)
18986 cat >>confdefs.h <<_ACEOF
18987 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
18988 _ACEOF
18989 ;;
18990 esac
18991 rm -rf conftest*
18992
18993 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
18994 # in glibc 2.1.3, but that breaks too many other things.
18995 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
18996 if test $ac_cv_sys_largefile_source != unknown; then
18997
18998 cat >>confdefs.h <<\_ACEOF
18999 #define HAVE_FSEEKO 1
19000 _ACEOF
19001
19002 fi
19003 ;;
19004 esac
19005
19006 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
19007 # by calling it, 2009-04-02
19008 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
19009 if test "$PORTNAME" != "solaris"; then
19010
19011 for ac_func in posix_fadvise
19012 do
19013 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19014 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19015 $as_echo_n "checking for $ac_func... " >&6; }
19016 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19017   $as_echo_n "(cached) " >&6
19018 else
19019   cat >conftest.$ac_ext <<_ACEOF
19020 /* confdefs.h.  */
19021 _ACEOF
19022 cat confdefs.h >>conftest.$ac_ext
19023 cat >>conftest.$ac_ext <<_ACEOF
19024 /* end confdefs.h.  */
19025 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19026    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19027 #define $ac_func innocuous_$ac_func
19028
19029 /* System header to define __stub macros and hopefully few prototypes,
19030     which can conflict with char $ac_func (); below.
19031     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19032     <limits.h> exists even on freestanding compilers.  */
19033
19034 #ifdef __STDC__
19035 # include <limits.h>
19036 #else
19037 # include <assert.h>
19038 #endif
19039
19040 #undef $ac_func
19041
19042 /* Override any GCC internal prototype to avoid an error.
19043    Use char because int might match the return type of a GCC
19044    builtin and then its argument prototype would still apply.  */
19045 #ifdef __cplusplus
19046 extern "C"
19047 #endif
19048 char $ac_func ();
19049 /* The GNU C library defines this for functions which it implements
19050     to always fail with ENOSYS.  Some functions are actually named
19051     something starting with __ and the normal name is an alias.  */
19052 #if defined __stub_$ac_func || defined __stub___$ac_func
19053 choke me
19054 #endif
19055
19056 int
19057 main ()
19058 {
19059 return $ac_func ();
19060   ;
19061   return 0;
19062 }
19063 _ACEOF
19064 rm -f conftest.$ac_objext conftest$ac_exeext
19065 if { (ac_try="$ac_link"
19066 case "(($ac_try" in
19067   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19068   *) ac_try_echo=$ac_try;;
19069 esac
19070 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19071 $as_echo "$ac_try_echo") >&5
19072   (eval "$ac_link") 2>conftest.er1
19073   ac_status=$?
19074   grep -v '^ *+' conftest.er1 >conftest.err
19075   rm -f conftest.er1
19076   cat conftest.err >&5
19077   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19078   (exit $ac_status); } && {
19079          test -z "$ac_c_werror_flag" ||
19080          test ! -s conftest.err
19081        } && test -s conftest$ac_exeext && {
19082          test "$cross_compiling" = yes ||
19083          $as_test_x conftest$ac_exeext
19084        }; then
19085   eval "$as_ac_var=yes"
19086 else
19087   $as_echo "$as_me: failed program was:" >&5
19088 sed 's/^/| /' conftest.$ac_ext >&5
19089
19090         eval "$as_ac_var=no"
19091 fi
19092
19093 rm -rf conftest.dSYM
19094 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19095       conftest$ac_exeext conftest.$ac_ext
19096 fi
19097 ac_res=`eval 'as_val=${'$as_ac_var'}
19098                  $as_echo "$as_val"'`
19099                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19100 $as_echo "$ac_res" >&6; }
19101 as_val=`eval 'as_val=${'$as_ac_var'}
19102                  $as_echo "$as_val"'`
19103    if test "x$as_val" = x""yes; then
19104   cat >>confdefs.h <<_ACEOF
19105 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19106 _ACEOF
19107
19108 fi
19109 done
19110
19111 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
19112 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
19113 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
19114   $as_echo_n "(cached) " >&6
19115 else
19116   cat >conftest.$ac_ext <<_ACEOF
19117 /* confdefs.h.  */
19118 _ACEOF
19119 cat confdefs.h >>conftest.$ac_ext
19120 cat >>conftest.$ac_ext <<_ACEOF
19121 /* end confdefs.h.  */
19122 #include <fcntl.h>
19123
19124 int
19125 main ()
19126 {
19127 #ifndef posix_fadvise
19128   (void) posix_fadvise;
19129 #endif
19130
19131   ;
19132   return 0;
19133 }
19134 _ACEOF
19135 rm -f conftest.$ac_objext
19136 if { (ac_try="$ac_compile"
19137 case "(($ac_try" in
19138   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19139   *) ac_try_echo=$ac_try;;
19140 esac
19141 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19142 $as_echo "$ac_try_echo") >&5
19143   (eval "$ac_compile") 2>conftest.er1
19144   ac_status=$?
19145   grep -v '^ *+' conftest.er1 >conftest.err
19146   rm -f conftest.er1
19147   cat conftest.err >&5
19148   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19149   (exit $ac_status); } && {
19150          test -z "$ac_c_werror_flag" ||
19151          test ! -s conftest.err
19152        } && test -s conftest.$ac_objext; then
19153   ac_cv_have_decl_posix_fadvise=yes
19154 else
19155   $as_echo "$as_me: failed program was:" >&5
19156 sed 's/^/| /' conftest.$ac_ext >&5
19157
19158         ac_cv_have_decl_posix_fadvise=no
19159 fi
19160
19161 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19162 fi
19163 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
19164 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
19165 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
19166
19167 cat >>confdefs.h <<_ACEOF
19168 #define HAVE_DECL_POSIX_FADVISE 1
19169 _ACEOF
19170
19171
19172 else
19173   cat >>confdefs.h <<_ACEOF
19174 #define HAVE_DECL_POSIX_FADVISE 0
19175 _ACEOF
19176
19177
19178 fi
19179
19180
19181 fi
19182
19183 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
19184 $as_echo_n "checking whether fdatasync is declared... " >&6; }
19185 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
19186   $as_echo_n "(cached) " >&6
19187 else
19188   cat >conftest.$ac_ext <<_ACEOF
19189 /* confdefs.h.  */
19190 _ACEOF
19191 cat confdefs.h >>conftest.$ac_ext
19192 cat >>conftest.$ac_ext <<_ACEOF
19193 /* end confdefs.h.  */
19194 #include <unistd.h>
19195
19196 int
19197 main ()
19198 {
19199 #ifndef fdatasync
19200   (void) fdatasync;
19201 #endif
19202
19203   ;
19204   return 0;
19205 }
19206 _ACEOF
19207 rm -f conftest.$ac_objext
19208 if { (ac_try="$ac_compile"
19209 case "(($ac_try" in
19210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19211   *) ac_try_echo=$ac_try;;
19212 esac
19213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19214 $as_echo "$ac_try_echo") >&5
19215   (eval "$ac_compile") 2>conftest.er1
19216   ac_status=$?
19217   grep -v '^ *+' conftest.er1 >conftest.err
19218   rm -f conftest.er1
19219   cat conftest.err >&5
19220   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19221   (exit $ac_status); } && {
19222          test -z "$ac_c_werror_flag" ||
19223          test ! -s conftest.err
19224        } && test -s conftest.$ac_objext; then
19225   ac_cv_have_decl_fdatasync=yes
19226 else
19227   $as_echo "$as_me: failed program was:" >&5
19228 sed 's/^/| /' conftest.$ac_ext >&5
19229
19230         ac_cv_have_decl_fdatasync=no
19231 fi
19232
19233 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19234 fi
19235 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
19236 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
19237 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
19238
19239 cat >>confdefs.h <<_ACEOF
19240 #define HAVE_DECL_FDATASYNC 1
19241 _ACEOF
19242
19243
19244 else
19245   cat >>confdefs.h <<_ACEOF
19246 #define HAVE_DECL_FDATASYNC 0
19247 _ACEOF
19248
19249
19250 fi
19251
19252
19253 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
19254 $as_echo_n "checking whether strlcat is declared... " >&6; }
19255 if test "${ac_cv_have_decl_strlcat+set}" = set; then
19256   $as_echo_n "(cached) " >&6
19257 else
19258   cat >conftest.$ac_ext <<_ACEOF
19259 /* confdefs.h.  */
19260 _ACEOF
19261 cat confdefs.h >>conftest.$ac_ext
19262 cat >>conftest.$ac_ext <<_ACEOF
19263 /* end confdefs.h.  */
19264 $ac_includes_default
19265 int
19266 main ()
19267 {
19268 #ifndef strlcat
19269   (void) strlcat;
19270 #endif
19271
19272   ;
19273   return 0;
19274 }
19275 _ACEOF
19276 rm -f conftest.$ac_objext
19277 if { (ac_try="$ac_compile"
19278 case "(($ac_try" in
19279   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19280   *) ac_try_echo=$ac_try;;
19281 esac
19282 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19283 $as_echo "$ac_try_echo") >&5
19284   (eval "$ac_compile") 2>conftest.er1
19285   ac_status=$?
19286   grep -v '^ *+' conftest.er1 >conftest.err
19287   rm -f conftest.er1
19288   cat conftest.err >&5
19289   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19290   (exit $ac_status); } && {
19291          test -z "$ac_c_werror_flag" ||
19292          test ! -s conftest.err
19293        } && test -s conftest.$ac_objext; then
19294   ac_cv_have_decl_strlcat=yes
19295 else
19296   $as_echo "$as_me: failed program was:" >&5
19297 sed 's/^/| /' conftest.$ac_ext >&5
19298
19299         ac_cv_have_decl_strlcat=no
19300 fi
19301
19302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19303 fi
19304 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
19305 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
19306 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
19307
19308 cat >>confdefs.h <<_ACEOF
19309 #define HAVE_DECL_STRLCAT 1
19310 _ACEOF
19311
19312
19313 else
19314   cat >>confdefs.h <<_ACEOF
19315 #define HAVE_DECL_STRLCAT 0
19316 _ACEOF
19317
19318
19319 fi
19320 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
19321 $as_echo_n "checking whether strlcpy is declared... " >&6; }
19322 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
19323   $as_echo_n "(cached) " >&6
19324 else
19325   cat >conftest.$ac_ext <<_ACEOF
19326 /* confdefs.h.  */
19327 _ACEOF
19328 cat confdefs.h >>conftest.$ac_ext
19329 cat >>conftest.$ac_ext <<_ACEOF
19330 /* end confdefs.h.  */
19331 $ac_includes_default
19332 int
19333 main ()
19334 {
19335 #ifndef strlcpy
19336   (void) strlcpy;
19337 #endif
19338
19339   ;
19340   return 0;
19341 }
19342 _ACEOF
19343 rm -f conftest.$ac_objext
19344 if { (ac_try="$ac_compile"
19345 case "(($ac_try" in
19346   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19347   *) ac_try_echo=$ac_try;;
19348 esac
19349 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19350 $as_echo "$ac_try_echo") >&5
19351   (eval "$ac_compile") 2>conftest.er1
19352   ac_status=$?
19353   grep -v '^ *+' conftest.er1 >conftest.err
19354   rm -f conftest.er1
19355   cat conftest.err >&5
19356   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19357   (exit $ac_status); } && {
19358          test -z "$ac_c_werror_flag" ||
19359          test ! -s conftest.err
19360        } && test -s conftest.$ac_objext; then
19361   ac_cv_have_decl_strlcpy=yes
19362 else
19363   $as_echo "$as_me: failed program was:" >&5
19364 sed 's/^/| /' conftest.$ac_ext >&5
19365
19366         ac_cv_have_decl_strlcpy=no
19367 fi
19368
19369 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19370 fi
19371 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
19372 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
19373 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
19374
19375 cat >>confdefs.h <<_ACEOF
19376 #define HAVE_DECL_STRLCPY 1
19377 _ACEOF
19378
19379
19380 else
19381   cat >>confdefs.h <<_ACEOF
19382 #define HAVE_DECL_STRLCPY 0
19383 _ACEOF
19384
19385
19386 fi
19387
19388
19389 # This is probably only present on Darwin, but may as well check always
19390 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
19391 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
19392 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
19393   $as_echo_n "(cached) " >&6
19394 else
19395   cat >conftest.$ac_ext <<_ACEOF
19396 /* confdefs.h.  */
19397 _ACEOF
19398 cat confdefs.h >>conftest.$ac_ext
19399 cat >>conftest.$ac_ext <<_ACEOF
19400 /* end confdefs.h.  */
19401 #include <fcntl.h>
19402
19403 int
19404 main ()
19405 {
19406 #ifndef F_FULLFSYNC
19407   (void) F_FULLFSYNC;
19408 #endif
19409
19410   ;
19411   return 0;
19412 }
19413 _ACEOF
19414 rm -f conftest.$ac_objext
19415 if { (ac_try="$ac_compile"
19416 case "(($ac_try" in
19417   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19418   *) ac_try_echo=$ac_try;;
19419 esac
19420 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19421 $as_echo "$ac_try_echo") >&5
19422   (eval "$ac_compile") 2>conftest.er1
19423   ac_status=$?
19424   grep -v '^ *+' conftest.er1 >conftest.err
19425   rm -f conftest.er1
19426   cat conftest.err >&5
19427   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19428   (exit $ac_status); } && {
19429          test -z "$ac_c_werror_flag" ||
19430          test ! -s conftest.err
19431        } && test -s conftest.$ac_objext; then
19432   ac_cv_have_decl_F_FULLFSYNC=yes
19433 else
19434   $as_echo "$as_me: failed program was:" >&5
19435 sed 's/^/| /' conftest.$ac_ext >&5
19436
19437         ac_cv_have_decl_F_FULLFSYNC=no
19438 fi
19439
19440 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19441 fi
19442 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
19443 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
19444 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
19445
19446 cat >>confdefs.h <<_ACEOF
19447 #define HAVE_DECL_F_FULLFSYNC 1
19448 _ACEOF
19449
19450
19451 else
19452   cat >>confdefs.h <<_ACEOF
19453 #define HAVE_DECL_F_FULLFSYNC 0
19454 _ACEOF
19455
19456
19457 fi
19458
19459
19460
19461 HAVE_IPV6=no
19462 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
19463 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
19464 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
19465   $as_echo_n "(cached) " >&6
19466 else
19467   ac_cv_type_struct_sockaddr_in6=no
19468 cat >conftest.$ac_ext <<_ACEOF
19469 /* confdefs.h.  */
19470 _ACEOF
19471 cat confdefs.h >>conftest.$ac_ext
19472 cat >>conftest.$ac_ext <<_ACEOF
19473 /* end confdefs.h.  */
19474 $ac_includes_default
19475 #include <netinet/in.h>
19476
19477 int
19478 main ()
19479 {
19480 if (sizeof (struct sockaddr_in6))
19481        return 0;
19482   ;
19483   return 0;
19484 }
19485 _ACEOF
19486 rm -f conftest.$ac_objext
19487 if { (ac_try="$ac_compile"
19488 case "(($ac_try" in
19489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19490   *) ac_try_echo=$ac_try;;
19491 esac
19492 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19493 $as_echo "$ac_try_echo") >&5
19494   (eval "$ac_compile") 2>conftest.er1
19495   ac_status=$?
19496   grep -v '^ *+' conftest.er1 >conftest.err
19497   rm -f conftest.er1
19498   cat conftest.err >&5
19499   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19500   (exit $ac_status); } && {
19501          test -z "$ac_c_werror_flag" ||
19502          test ! -s conftest.err
19503        } && test -s conftest.$ac_objext; then
19504   cat >conftest.$ac_ext <<_ACEOF
19505 /* confdefs.h.  */
19506 _ACEOF
19507 cat confdefs.h >>conftest.$ac_ext
19508 cat >>conftest.$ac_ext <<_ACEOF
19509 /* end confdefs.h.  */
19510 $ac_includes_default
19511 #include <netinet/in.h>
19512
19513 int
19514 main ()
19515 {
19516 if (sizeof ((struct sockaddr_in6)))
19517           return 0;
19518   ;
19519   return 0;
19520 }
19521 _ACEOF
19522 rm -f conftest.$ac_objext
19523 if { (ac_try="$ac_compile"
19524 case "(($ac_try" in
19525   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19526   *) ac_try_echo=$ac_try;;
19527 esac
19528 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19529 $as_echo "$ac_try_echo") >&5
19530   (eval "$ac_compile") 2>conftest.er1
19531   ac_status=$?
19532   grep -v '^ *+' conftest.er1 >conftest.err
19533   rm -f conftest.er1
19534   cat conftest.err >&5
19535   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19536   (exit $ac_status); } && {
19537          test -z "$ac_c_werror_flag" ||
19538          test ! -s conftest.err
19539        } && test -s conftest.$ac_objext; then
19540   :
19541 else
19542   $as_echo "$as_me: failed program was:" >&5
19543 sed 's/^/| /' conftest.$ac_ext >&5
19544
19545         ac_cv_type_struct_sockaddr_in6=yes
19546 fi
19547
19548 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19549 else
19550   $as_echo "$as_me: failed program was:" >&5
19551 sed 's/^/| /' conftest.$ac_ext >&5
19552
19553
19554 fi
19555
19556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19557 fi
19558 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
19559 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
19560 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
19561
19562 cat >>confdefs.h <<\_ACEOF
19563 #define HAVE_IPV6 1
19564 _ACEOF
19565
19566          HAVE_IPV6=yes
19567 fi
19568
19569
19570
19571 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
19572 $as_echo_n "checking for PS_STRINGS... " >&6; }
19573 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
19574   $as_echo_n "(cached) " >&6
19575 else
19576   cat >conftest.$ac_ext <<_ACEOF
19577 /* confdefs.h.  */
19578 _ACEOF
19579 cat confdefs.h >>conftest.$ac_ext
19580 cat >>conftest.$ac_ext <<_ACEOF
19581 /* end confdefs.h.  */
19582 #include <machine/vmparam.h>
19583 #include <sys/exec.h>
19584
19585 int
19586 main ()
19587 {
19588 PS_STRINGS->ps_nargvstr = 1;
19589 PS_STRINGS->ps_argvstr = "foo";
19590   ;
19591   return 0;
19592 }
19593 _ACEOF
19594 rm -f conftest.$ac_objext conftest$ac_exeext
19595 if { (ac_try="$ac_link"
19596 case "(($ac_try" in
19597   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19598   *) ac_try_echo=$ac_try;;
19599 esac
19600 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19601 $as_echo "$ac_try_echo") >&5
19602   (eval "$ac_link") 2>conftest.er1
19603   ac_status=$?
19604   grep -v '^ *+' conftest.er1 >conftest.err
19605   rm -f conftest.er1
19606   cat conftest.err >&5
19607   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19608   (exit $ac_status); } && {
19609          test -z "$ac_c_werror_flag" ||
19610          test ! -s conftest.err
19611        } && test -s conftest$ac_exeext && {
19612          test "$cross_compiling" = yes ||
19613          $as_test_x conftest$ac_exeext
19614        }; then
19615   pgac_cv_var_PS_STRINGS=yes
19616 else
19617   $as_echo "$as_me: failed program was:" >&5
19618 sed 's/^/| /' conftest.$ac_ext >&5
19619
19620         pgac_cv_var_PS_STRINGS=no
19621 fi
19622
19623 rm -rf conftest.dSYM
19624 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19625       conftest$ac_exeext conftest.$ac_ext
19626 fi
19627 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
19628 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
19629 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
19630
19631 cat >>confdefs.h <<\_ACEOF
19632 #define HAVE_PS_STRINGS /**/
19633 _ACEOF
19634
19635 fi
19636
19637
19638 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
19639 # is missing.  Yes, there are machines that have only one.  We may
19640 # also decide to use snprintf.c if snprintf() is present but does not
19641 # have all the features we need --- see below.
19642
19643 if test "$PORTNAME" = "win32"; then
19644   # Win32 gets snprintf.c built unconditionally.
19645   #
19646   # To properly translate all NLS languages strings, we must support the
19647   # *printf() %$ format, which allows *printf() arguments to be selected
19648   # by position in the translated string.
19649   #
19650   # libintl versions < 0.13 use the native *printf() functions, and Win32
19651   # *printf() doesn't understand %$, so we must use our /port versions,
19652   # which do understand %$. libintl versions >= 0.13 include their own
19653   # *printf versions on Win32.  The libintl 0.13 release note text is:
19654   #
19655   #   C format strings with positions, as they arise when a translator
19656   #   needs to reorder a sentence, are now supported on all platforms.
19657   #   On those few platforms (NetBSD and Woe32) for which the native
19658   #   printf()/fprintf()/... functions don't support such format
19659   #   strings, replacements are provided through <libintl.h>.
19660   #
19661   # We could use libintl >= 0.13's *printf() if we were sure that we had
19662   # a litint >= 0.13 at runtime, but seeing that there is no clean way
19663   # to guarantee that, it is best to just use our own, so we are sure to
19664   # get %$ support. In include/port.h we disable the *printf() macros
19665   # that might have been defined by libintl.
19666   #
19667   # We do this unconditionally whether NLS is used or not so we are sure
19668   # that all Win32 libraries and binaries behave the same.
19669   pgac_need_repl_snprintf=yes
19670 else
19671   pgac_need_repl_snprintf=no
19672
19673 for ac_func in snprintf
19674 do
19675 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19676 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19677 $as_echo_n "checking for $ac_func... " >&6; }
19678 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19679   $as_echo_n "(cached) " >&6
19680 else
19681   cat >conftest.$ac_ext <<_ACEOF
19682 /* confdefs.h.  */
19683 _ACEOF
19684 cat confdefs.h >>conftest.$ac_ext
19685 cat >>conftest.$ac_ext <<_ACEOF
19686 /* end confdefs.h.  */
19687 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19688    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19689 #define $ac_func innocuous_$ac_func
19690
19691 /* System header to define __stub macros and hopefully few prototypes,
19692     which can conflict with char $ac_func (); below.
19693     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19694     <limits.h> exists even on freestanding compilers.  */
19695
19696 #ifdef __STDC__
19697 # include <limits.h>
19698 #else
19699 # include <assert.h>
19700 #endif
19701
19702 #undef $ac_func
19703
19704 /* Override any GCC internal prototype to avoid an error.
19705    Use char because int might match the return type of a GCC
19706    builtin and then its argument prototype would still apply.  */
19707 #ifdef __cplusplus
19708 extern "C"
19709 #endif
19710 char $ac_func ();
19711 /* The GNU C library defines this for functions which it implements
19712     to always fail with ENOSYS.  Some functions are actually named
19713     something starting with __ and the normal name is an alias.  */
19714 #if defined __stub_$ac_func || defined __stub___$ac_func
19715 choke me
19716 #endif
19717
19718 int
19719 main ()
19720 {
19721 return $ac_func ();
19722   ;
19723   return 0;
19724 }
19725 _ACEOF
19726 rm -f conftest.$ac_objext conftest$ac_exeext
19727 if { (ac_try="$ac_link"
19728 case "(($ac_try" in
19729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19730   *) ac_try_echo=$ac_try;;
19731 esac
19732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19733 $as_echo "$ac_try_echo") >&5
19734   (eval "$ac_link") 2>conftest.er1
19735   ac_status=$?
19736   grep -v '^ *+' conftest.er1 >conftest.err
19737   rm -f conftest.er1
19738   cat conftest.err >&5
19739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19740   (exit $ac_status); } && {
19741          test -z "$ac_c_werror_flag" ||
19742          test ! -s conftest.err
19743        } && test -s conftest$ac_exeext && {
19744          test "$cross_compiling" = yes ||
19745          $as_test_x conftest$ac_exeext
19746        }; then
19747   eval "$as_ac_var=yes"
19748 else
19749   $as_echo "$as_me: failed program was:" >&5
19750 sed 's/^/| /' conftest.$ac_ext >&5
19751
19752         eval "$as_ac_var=no"
19753 fi
19754
19755 rm -rf conftest.dSYM
19756 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19757       conftest$ac_exeext conftest.$ac_ext
19758 fi
19759 ac_res=`eval 'as_val=${'$as_ac_var'}
19760                  $as_echo "$as_val"'`
19761                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19762 $as_echo "$ac_res" >&6; }
19763 as_val=`eval 'as_val=${'$as_ac_var'}
19764                  $as_echo "$as_val"'`
19765    if test "x$as_val" = x""yes; then
19766   cat >>confdefs.h <<_ACEOF
19767 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19768 _ACEOF
19769
19770 else
19771   pgac_need_repl_snprintf=yes
19772 fi
19773 done
19774
19775
19776 for ac_func in vsnprintf
19777 do
19778 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19779 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19780 $as_echo_n "checking for $ac_func... " >&6; }
19781 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19782   $as_echo_n "(cached) " >&6
19783 else
19784   cat >conftest.$ac_ext <<_ACEOF
19785 /* confdefs.h.  */
19786 _ACEOF
19787 cat confdefs.h >>conftest.$ac_ext
19788 cat >>conftest.$ac_ext <<_ACEOF
19789 /* end confdefs.h.  */
19790 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19791    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19792 #define $ac_func innocuous_$ac_func
19793
19794 /* System header to define __stub macros and hopefully few prototypes,
19795     which can conflict with char $ac_func (); below.
19796     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19797     <limits.h> exists even on freestanding compilers.  */
19798
19799 #ifdef __STDC__
19800 # include <limits.h>
19801 #else
19802 # include <assert.h>
19803 #endif
19804
19805 #undef $ac_func
19806
19807 /* Override any GCC internal prototype to avoid an error.
19808    Use char because int might match the return type of a GCC
19809    builtin and then its argument prototype would still apply.  */
19810 #ifdef __cplusplus
19811 extern "C"
19812 #endif
19813 char $ac_func ();
19814 /* The GNU C library defines this for functions which it implements
19815     to always fail with ENOSYS.  Some functions are actually named
19816     something starting with __ and the normal name is an alias.  */
19817 #if defined __stub_$ac_func || defined __stub___$ac_func
19818 choke me
19819 #endif
19820
19821 int
19822 main ()
19823 {
19824 return $ac_func ();
19825   ;
19826   return 0;
19827 }
19828 _ACEOF
19829 rm -f conftest.$ac_objext conftest$ac_exeext
19830 if { (ac_try="$ac_link"
19831 case "(($ac_try" in
19832   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19833   *) ac_try_echo=$ac_try;;
19834 esac
19835 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19836 $as_echo "$ac_try_echo") >&5
19837   (eval "$ac_link") 2>conftest.er1
19838   ac_status=$?
19839   grep -v '^ *+' conftest.er1 >conftest.err
19840   rm -f conftest.er1
19841   cat conftest.err >&5
19842   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19843   (exit $ac_status); } && {
19844          test -z "$ac_c_werror_flag" ||
19845          test ! -s conftest.err
19846        } && test -s conftest$ac_exeext && {
19847          test "$cross_compiling" = yes ||
19848          $as_test_x conftest$ac_exeext
19849        }; then
19850   eval "$as_ac_var=yes"
19851 else
19852   $as_echo "$as_me: failed program was:" >&5
19853 sed 's/^/| /' conftest.$ac_ext >&5
19854
19855         eval "$as_ac_var=no"
19856 fi
19857
19858 rm -rf conftest.dSYM
19859 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19860       conftest$ac_exeext conftest.$ac_ext
19861 fi
19862 ac_res=`eval 'as_val=${'$as_ac_var'}
19863                  $as_echo "$as_val"'`
19864                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19865 $as_echo "$ac_res" >&6; }
19866 as_val=`eval 'as_val=${'$as_ac_var'}
19867                  $as_echo "$as_val"'`
19868    if test "x$as_val" = x""yes; then
19869   cat >>confdefs.h <<_ACEOF
19870 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19871 _ACEOF
19872
19873 else
19874   pgac_need_repl_snprintf=yes
19875 fi
19876 done
19877
19878 fi
19879
19880
19881 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
19882 # include/c.h will provide declarations.  Note this is a separate test
19883 # from whether the functions exist in the C library --- there are
19884 # systems that have the functions but don't bother to declare them :-(
19885
19886 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
19887 $as_echo_n "checking whether snprintf is declared... " >&6; }
19888 if test "${ac_cv_have_decl_snprintf+set}" = set; then
19889   $as_echo_n "(cached) " >&6
19890 else
19891   cat >conftest.$ac_ext <<_ACEOF
19892 /* confdefs.h.  */
19893 _ACEOF
19894 cat confdefs.h >>conftest.$ac_ext
19895 cat >>conftest.$ac_ext <<_ACEOF
19896 /* end confdefs.h.  */
19897 $ac_includes_default
19898 int
19899 main ()
19900 {
19901 #ifndef snprintf
19902   (void) snprintf;
19903 #endif
19904
19905   ;
19906   return 0;
19907 }
19908 _ACEOF
19909 rm -f conftest.$ac_objext
19910 if { (ac_try="$ac_compile"
19911 case "(($ac_try" in
19912   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19913   *) ac_try_echo=$ac_try;;
19914 esac
19915 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19916 $as_echo "$ac_try_echo") >&5
19917   (eval "$ac_compile") 2>conftest.er1
19918   ac_status=$?
19919   grep -v '^ *+' conftest.er1 >conftest.err
19920   rm -f conftest.er1
19921   cat conftest.err >&5
19922   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19923   (exit $ac_status); } && {
19924          test -z "$ac_c_werror_flag" ||
19925          test ! -s conftest.err
19926        } && test -s conftest.$ac_objext; then
19927   ac_cv_have_decl_snprintf=yes
19928 else
19929   $as_echo "$as_me: failed program was:" >&5
19930 sed 's/^/| /' conftest.$ac_ext >&5
19931
19932         ac_cv_have_decl_snprintf=no
19933 fi
19934
19935 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19936 fi
19937 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
19938 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
19939 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
19940
19941 cat >>confdefs.h <<_ACEOF
19942 #define HAVE_DECL_SNPRINTF 1
19943 _ACEOF
19944
19945
19946 else
19947   cat >>confdefs.h <<_ACEOF
19948 #define HAVE_DECL_SNPRINTF 0
19949 _ACEOF
19950
19951
19952 fi
19953 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
19954 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
19955 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
19956   $as_echo_n "(cached) " >&6
19957 else
19958   cat >conftest.$ac_ext <<_ACEOF
19959 /* confdefs.h.  */
19960 _ACEOF
19961 cat confdefs.h >>conftest.$ac_ext
19962 cat >>conftest.$ac_ext <<_ACEOF
19963 /* end confdefs.h.  */
19964 $ac_includes_default
19965 int
19966 main ()
19967 {
19968 #ifndef vsnprintf
19969   (void) vsnprintf;
19970 #endif
19971
19972   ;
19973   return 0;
19974 }
19975 _ACEOF
19976 rm -f conftest.$ac_objext
19977 if { (ac_try="$ac_compile"
19978 case "(($ac_try" in
19979   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19980   *) ac_try_echo=$ac_try;;
19981 esac
19982 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19983 $as_echo "$ac_try_echo") >&5
19984   (eval "$ac_compile") 2>conftest.er1
19985   ac_status=$?
19986   grep -v '^ *+' conftest.er1 >conftest.err
19987   rm -f conftest.er1
19988   cat conftest.err >&5
19989   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19990   (exit $ac_status); } && {
19991          test -z "$ac_c_werror_flag" ||
19992          test ! -s conftest.err
19993        } && test -s conftest.$ac_objext; then
19994   ac_cv_have_decl_vsnprintf=yes
19995 else
19996   $as_echo "$as_me: failed program was:" >&5
19997 sed 's/^/| /' conftest.$ac_ext >&5
19998
19999         ac_cv_have_decl_vsnprintf=no
20000 fi
20001
20002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20003 fi
20004 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
20005 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
20006 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
20007
20008 cat >>confdefs.h <<_ACEOF
20009 #define HAVE_DECL_VSNPRINTF 1
20010 _ACEOF
20011
20012
20013 else
20014   cat >>confdefs.h <<_ACEOF
20015 #define HAVE_DECL_VSNPRINTF 0
20016 _ACEOF
20017
20018
20019 fi
20020
20021
20022
20023
20024 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
20025 $as_echo_n "checking for isinf... " >&6; }
20026 if test "${ac_cv_func_isinf+set}" = set; then
20027   $as_echo_n "(cached) " >&6
20028 else
20029   cat >conftest.$ac_ext <<_ACEOF
20030 /* confdefs.h.  */
20031 _ACEOF
20032 cat confdefs.h >>conftest.$ac_ext
20033 cat >>conftest.$ac_ext <<_ACEOF
20034 /* end confdefs.h.  */
20035
20036 #include <math.h>
20037 double glob_double;
20038
20039 int
20040 main ()
20041 {
20042 return isinf(glob_double) ? 0 : 1;
20043   ;
20044   return 0;
20045 }
20046 _ACEOF
20047 rm -f conftest.$ac_objext conftest$ac_exeext
20048 if { (ac_try="$ac_link"
20049 case "(($ac_try" in
20050   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20051   *) ac_try_echo=$ac_try;;
20052 esac
20053 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20054 $as_echo "$ac_try_echo") >&5
20055   (eval "$ac_link") 2>conftest.er1
20056   ac_status=$?
20057   grep -v '^ *+' conftest.er1 >conftest.err
20058   rm -f conftest.er1
20059   cat conftest.err >&5
20060   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20061   (exit $ac_status); } && {
20062          test -z "$ac_c_werror_flag" ||
20063          test ! -s conftest.err
20064        } && test -s conftest$ac_exeext && {
20065          test "$cross_compiling" = yes ||
20066          $as_test_x conftest$ac_exeext
20067        }; then
20068   ac_cv_func_isinf=yes
20069 else
20070   $as_echo "$as_me: failed program was:" >&5
20071 sed 's/^/| /' conftest.$ac_ext >&5
20072
20073         ac_cv_func_isinf=no
20074 fi
20075
20076 rm -rf conftest.dSYM
20077 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20078       conftest$ac_exeext conftest.$ac_ext
20079 fi
20080 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
20081 $as_echo "$ac_cv_func_isinf" >&6; }
20082
20083 if test $ac_cv_func_isinf = yes ; then
20084
20085 cat >>confdefs.h <<\_ACEOF
20086 #define HAVE_ISINF 1
20087 _ACEOF
20088
20089 else
20090   case " $LIBOBJS " in
20091   *" isinf.$ac_objext "* ) ;;
20092   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
20093  ;;
20094 esac
20095
20096   # Look for a way to implement a substitute for isinf()
20097
20098
20099
20100
20101 for ac_func in fpclass fp_class fp_class_d class
20102 do
20103 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20104 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20105 $as_echo_n "checking for $ac_func... " >&6; }
20106 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20107   $as_echo_n "(cached) " >&6
20108 else
20109   cat >conftest.$ac_ext <<_ACEOF
20110 /* confdefs.h.  */
20111 _ACEOF
20112 cat confdefs.h >>conftest.$ac_ext
20113 cat >>conftest.$ac_ext <<_ACEOF
20114 /* end confdefs.h.  */
20115 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20116    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20117 #define $ac_func innocuous_$ac_func
20118
20119 /* System header to define __stub macros and hopefully few prototypes,
20120     which can conflict with char $ac_func (); below.
20121     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20122     <limits.h> exists even on freestanding compilers.  */
20123
20124 #ifdef __STDC__
20125 # include <limits.h>
20126 #else
20127 # include <assert.h>
20128 #endif
20129
20130 #undef $ac_func
20131
20132 /* Override any GCC internal prototype to avoid an error.
20133    Use char because int might match the return type of a GCC
20134    builtin and then its argument prototype would still apply.  */
20135 #ifdef __cplusplus
20136 extern "C"
20137 #endif
20138 char $ac_func ();
20139 /* The GNU C library defines this for functions which it implements
20140     to always fail with ENOSYS.  Some functions are actually named
20141     something starting with __ and the normal name is an alias.  */
20142 #if defined __stub_$ac_func || defined __stub___$ac_func
20143 choke me
20144 #endif
20145
20146 int
20147 main ()
20148 {
20149 return $ac_func ();
20150   ;
20151   return 0;
20152 }
20153 _ACEOF
20154 rm -f conftest.$ac_objext conftest$ac_exeext
20155 if { (ac_try="$ac_link"
20156 case "(($ac_try" in
20157   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20158   *) ac_try_echo=$ac_try;;
20159 esac
20160 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20161 $as_echo "$ac_try_echo") >&5
20162   (eval "$ac_link") 2>conftest.er1
20163   ac_status=$?
20164   grep -v '^ *+' conftest.er1 >conftest.err
20165   rm -f conftest.er1
20166   cat conftest.err >&5
20167   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20168   (exit $ac_status); } && {
20169          test -z "$ac_c_werror_flag" ||
20170          test ! -s conftest.err
20171        } && test -s conftest$ac_exeext && {
20172          test "$cross_compiling" = yes ||
20173          $as_test_x conftest$ac_exeext
20174        }; then
20175   eval "$as_ac_var=yes"
20176 else
20177   $as_echo "$as_me: failed program was:" >&5
20178 sed 's/^/| /' conftest.$ac_ext >&5
20179
20180         eval "$as_ac_var=no"
20181 fi
20182
20183 rm -rf conftest.dSYM
20184 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20185       conftest$ac_exeext conftest.$ac_ext
20186 fi
20187 ac_res=`eval 'as_val=${'$as_ac_var'}
20188                  $as_echo "$as_val"'`
20189                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20190 $as_echo "$ac_res" >&6; }
20191 as_val=`eval 'as_val=${'$as_ac_var'}
20192                  $as_echo "$as_val"'`
20193    if test "x$as_val" = x""yes; then
20194   cat >>confdefs.h <<_ACEOF
20195 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20196 _ACEOF
20197  break
20198 fi
20199 done
20200
20201 fi
20202
20203 # Some versions of libedit contain strlcpy(); so disregard that library while
20204 # checking for these standard libc functions.
20205 pgac_save_LIBS="$LIBS"
20206 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
20207
20208
20209
20210
20211
20212
20213
20214
20215
20216
20217
20218
20219
20220
20221
20222 for ac_func in crypt erand48 getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul
20223 do
20224 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20225 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20226 $as_echo_n "checking for $ac_func... " >&6; }
20227 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20228   $as_echo_n "(cached) " >&6
20229 else
20230   cat >conftest.$ac_ext <<_ACEOF
20231 /* confdefs.h.  */
20232 _ACEOF
20233 cat confdefs.h >>conftest.$ac_ext
20234 cat >>conftest.$ac_ext <<_ACEOF
20235 /* end confdefs.h.  */
20236 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20237    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20238 #define $ac_func innocuous_$ac_func
20239
20240 /* System header to define __stub macros and hopefully few prototypes,
20241     which can conflict with char $ac_func (); below.
20242     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20243     <limits.h> exists even on freestanding compilers.  */
20244
20245 #ifdef __STDC__
20246 # include <limits.h>
20247 #else
20248 # include <assert.h>
20249 #endif
20250
20251 #undef $ac_func
20252
20253 /* Override any GCC internal prototype to avoid an error.
20254    Use char because int might match the return type of a GCC
20255    builtin and then its argument prototype would still apply.  */
20256 #ifdef __cplusplus
20257 extern "C"
20258 #endif
20259 char $ac_func ();
20260 /* The GNU C library defines this for functions which it implements
20261     to always fail with ENOSYS.  Some functions are actually named
20262     something starting with __ and the normal name is an alias.  */
20263 #if defined __stub_$ac_func || defined __stub___$ac_func
20264 choke me
20265 #endif
20266
20267 int
20268 main ()
20269 {
20270 return $ac_func ();
20271   ;
20272   return 0;
20273 }
20274 _ACEOF
20275 rm -f conftest.$ac_objext conftest$ac_exeext
20276 if { (ac_try="$ac_link"
20277 case "(($ac_try" in
20278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20279   *) ac_try_echo=$ac_try;;
20280 esac
20281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20282 $as_echo "$ac_try_echo") >&5
20283   (eval "$ac_link") 2>conftest.er1
20284   ac_status=$?
20285   grep -v '^ *+' conftest.er1 >conftest.err
20286   rm -f conftest.er1
20287   cat conftest.err >&5
20288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20289   (exit $ac_status); } && {
20290          test -z "$ac_c_werror_flag" ||
20291          test ! -s conftest.err
20292        } && test -s conftest$ac_exeext && {
20293          test "$cross_compiling" = yes ||
20294          $as_test_x conftest$ac_exeext
20295        }; then
20296   eval "$as_ac_var=yes"
20297 else
20298   $as_echo "$as_me: failed program was:" >&5
20299 sed 's/^/| /' conftest.$ac_ext >&5
20300
20301         eval "$as_ac_var=no"
20302 fi
20303
20304 rm -rf conftest.dSYM
20305 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20306       conftest$ac_exeext conftest.$ac_ext
20307 fi
20308 ac_res=`eval 'as_val=${'$as_ac_var'}
20309                  $as_echo "$as_val"'`
20310                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20311 $as_echo "$ac_res" >&6; }
20312 as_val=`eval 'as_val=${'$as_ac_var'}
20313                  $as_echo "$as_val"'`
20314    if test "x$as_val" = x""yes; then
20315   cat >>confdefs.h <<_ACEOF
20316 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20317 _ACEOF
20318
20319 else
20320   case " $LIBOBJS " in
20321   *" $ac_func.$ac_objext "* ) ;;
20322   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20323  ;;
20324 esac
20325
20326 fi
20327 done
20328
20329
20330
20331 case $host_os in
20332
20333         # Windows uses a specialised env handler
20334         mingw*)
20335
20336 cat >>confdefs.h <<\_ACEOF
20337 #define HAVE_UNSETENV 1
20338 _ACEOF
20339
20340                 ac_cv_func_unsetenv=yes;;
20341         *)
20342
20343 for ac_func in unsetenv
20344 do
20345 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20346 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20347 $as_echo_n "checking for $ac_func... " >&6; }
20348 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20349   $as_echo_n "(cached) " >&6
20350 else
20351   cat >conftest.$ac_ext <<_ACEOF
20352 /* confdefs.h.  */
20353 _ACEOF
20354 cat confdefs.h >>conftest.$ac_ext
20355 cat >>conftest.$ac_ext <<_ACEOF
20356 /* end confdefs.h.  */
20357 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20358    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20359 #define $ac_func innocuous_$ac_func
20360
20361 /* System header to define __stub macros and hopefully few prototypes,
20362     which can conflict with char $ac_func (); below.
20363     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20364     <limits.h> exists even on freestanding compilers.  */
20365
20366 #ifdef __STDC__
20367 # include <limits.h>
20368 #else
20369 # include <assert.h>
20370 #endif
20371
20372 #undef $ac_func
20373
20374 /* Override any GCC internal prototype to avoid an error.
20375    Use char because int might match the return type of a GCC
20376    builtin and then its argument prototype would still apply.  */
20377 #ifdef __cplusplus
20378 extern "C"
20379 #endif
20380 char $ac_func ();
20381 /* The GNU C library defines this for functions which it implements
20382     to always fail with ENOSYS.  Some functions are actually named
20383     something starting with __ and the normal name is an alias.  */
20384 #if defined __stub_$ac_func || defined __stub___$ac_func
20385 choke me
20386 #endif
20387
20388 int
20389 main ()
20390 {
20391 return $ac_func ();
20392   ;
20393   return 0;
20394 }
20395 _ACEOF
20396 rm -f conftest.$ac_objext conftest$ac_exeext
20397 if { (ac_try="$ac_link"
20398 case "(($ac_try" in
20399   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20400   *) ac_try_echo=$ac_try;;
20401 esac
20402 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20403 $as_echo "$ac_try_echo") >&5
20404   (eval "$ac_link") 2>conftest.er1
20405   ac_status=$?
20406   grep -v '^ *+' conftest.er1 >conftest.err
20407   rm -f conftest.er1
20408   cat conftest.err >&5
20409   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20410   (exit $ac_status); } && {
20411          test -z "$ac_c_werror_flag" ||
20412          test ! -s conftest.err
20413        } && test -s conftest$ac_exeext && {
20414          test "$cross_compiling" = yes ||
20415          $as_test_x conftest$ac_exeext
20416        }; then
20417   eval "$as_ac_var=yes"
20418 else
20419   $as_echo "$as_me: failed program was:" >&5
20420 sed 's/^/| /' conftest.$ac_ext >&5
20421
20422         eval "$as_ac_var=no"
20423 fi
20424
20425 rm -rf conftest.dSYM
20426 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20427       conftest$ac_exeext conftest.$ac_ext
20428 fi
20429 ac_res=`eval 'as_val=${'$as_ac_var'}
20430                  $as_echo "$as_val"'`
20431                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20432 $as_echo "$ac_res" >&6; }
20433 as_val=`eval 'as_val=${'$as_ac_var'}
20434                  $as_echo "$as_val"'`
20435    if test "x$as_val" = x""yes; then
20436   cat >>confdefs.h <<_ACEOF
20437 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20438 _ACEOF
20439
20440 else
20441   case " $LIBOBJS " in
20442   *" $ac_func.$ac_objext "* ) ;;
20443   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20444  ;;
20445 esac
20446
20447 fi
20448 done
20449
20450
20451                 ;;
20452 esac
20453
20454
20455 LIBS="$pgac_save_LIBS"
20456
20457 # System's version of getaddrinfo(), if any, may be used only if we found
20458 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
20459 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
20460 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
20461 # because we want to use our own getaddrinfo.c on Windows anyway.)
20462 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
20463
20464 for ac_func in getaddrinfo
20465 do
20466 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20467 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20468 $as_echo_n "checking for $ac_func... " >&6; }
20469 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20470   $as_echo_n "(cached) " >&6
20471 else
20472   cat >conftest.$ac_ext <<_ACEOF
20473 /* confdefs.h.  */
20474 _ACEOF
20475 cat confdefs.h >>conftest.$ac_ext
20476 cat >>conftest.$ac_ext <<_ACEOF
20477 /* end confdefs.h.  */
20478 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20479    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20480 #define $ac_func innocuous_$ac_func
20481
20482 /* System header to define __stub macros and hopefully few prototypes,
20483     which can conflict with char $ac_func (); below.
20484     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20485     <limits.h> exists even on freestanding compilers.  */
20486
20487 #ifdef __STDC__
20488 # include <limits.h>
20489 #else
20490 # include <assert.h>
20491 #endif
20492
20493 #undef $ac_func
20494
20495 /* Override any GCC internal prototype to avoid an error.
20496    Use char because int might match the return type of a GCC
20497    builtin and then its argument prototype would still apply.  */
20498 #ifdef __cplusplus
20499 extern "C"
20500 #endif
20501 char $ac_func ();
20502 /* The GNU C library defines this for functions which it implements
20503     to always fail with ENOSYS.  Some functions are actually named
20504     something starting with __ and the normal name is an alias.  */
20505 #if defined __stub_$ac_func || defined __stub___$ac_func
20506 choke me
20507 #endif
20508
20509 int
20510 main ()
20511 {
20512 return $ac_func ();
20513   ;
20514   return 0;
20515 }
20516 _ACEOF
20517 rm -f conftest.$ac_objext conftest$ac_exeext
20518 if { (ac_try="$ac_link"
20519 case "(($ac_try" in
20520   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20521   *) ac_try_echo=$ac_try;;
20522 esac
20523 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20524 $as_echo "$ac_try_echo") >&5
20525   (eval "$ac_link") 2>conftest.er1
20526   ac_status=$?
20527   grep -v '^ *+' conftest.er1 >conftest.err
20528   rm -f conftest.er1
20529   cat conftest.err >&5
20530   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20531   (exit $ac_status); } && {
20532          test -z "$ac_c_werror_flag" ||
20533          test ! -s conftest.err
20534        } && test -s conftest$ac_exeext && {
20535          test "$cross_compiling" = yes ||
20536          $as_test_x conftest$ac_exeext
20537        }; then
20538   eval "$as_ac_var=yes"
20539 else
20540   $as_echo "$as_me: failed program was:" >&5
20541 sed 's/^/| /' conftest.$ac_ext >&5
20542
20543         eval "$as_ac_var=no"
20544 fi
20545
20546 rm -rf conftest.dSYM
20547 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20548       conftest$ac_exeext conftest.$ac_ext
20549 fi
20550 ac_res=`eval 'as_val=${'$as_ac_var'}
20551                  $as_echo "$as_val"'`
20552                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20553 $as_echo "$ac_res" >&6; }
20554 as_val=`eval 'as_val=${'$as_ac_var'}
20555                  $as_echo "$as_val"'`
20556    if test "x$as_val" = x""yes; then
20557   cat >>confdefs.h <<_ACEOF
20558 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20559 _ACEOF
20560
20561 else
20562   case " $LIBOBJS " in
20563   *" $ac_func.$ac_objext "* ) ;;
20564   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20565  ;;
20566 esac
20567
20568 fi
20569 done
20570
20571
20572 else
20573   case " $LIBOBJS " in
20574   *" getaddrinfo.$ac_objext "* ) ;;
20575   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
20576  ;;
20577 esac
20578
20579 fi
20580
20581 # Similarly, use system's getopt_long() only if system provides struct option.
20582 if test x"$ac_cv_type_struct_option" = xyes ; then
20583
20584 for ac_func in getopt_long
20585 do
20586 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20587 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20588 $as_echo_n "checking for $ac_func... " >&6; }
20589 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20590   $as_echo_n "(cached) " >&6
20591 else
20592   cat >conftest.$ac_ext <<_ACEOF
20593 /* confdefs.h.  */
20594 _ACEOF
20595 cat confdefs.h >>conftest.$ac_ext
20596 cat >>conftest.$ac_ext <<_ACEOF
20597 /* end confdefs.h.  */
20598 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20599    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20600 #define $ac_func innocuous_$ac_func
20601
20602 /* System header to define __stub macros and hopefully few prototypes,
20603     which can conflict with char $ac_func (); below.
20604     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20605     <limits.h> exists even on freestanding compilers.  */
20606
20607 #ifdef __STDC__
20608 # include <limits.h>
20609 #else
20610 # include <assert.h>
20611 #endif
20612
20613 #undef $ac_func
20614
20615 /* Override any GCC internal prototype to avoid an error.
20616    Use char because int might match the return type of a GCC
20617    builtin and then its argument prototype would still apply.  */
20618 #ifdef __cplusplus
20619 extern "C"
20620 #endif
20621 char $ac_func ();
20622 /* The GNU C library defines this for functions which it implements
20623     to always fail with ENOSYS.  Some functions are actually named
20624     something starting with __ and the normal name is an alias.  */
20625 #if defined __stub_$ac_func || defined __stub___$ac_func
20626 choke me
20627 #endif
20628
20629 int
20630 main ()
20631 {
20632 return $ac_func ();
20633   ;
20634   return 0;
20635 }
20636 _ACEOF
20637 rm -f conftest.$ac_objext conftest$ac_exeext
20638 if { (ac_try="$ac_link"
20639 case "(($ac_try" in
20640   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20641   *) ac_try_echo=$ac_try;;
20642 esac
20643 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20644 $as_echo "$ac_try_echo") >&5
20645   (eval "$ac_link") 2>conftest.er1
20646   ac_status=$?
20647   grep -v '^ *+' conftest.er1 >conftest.err
20648   rm -f conftest.er1
20649   cat conftest.err >&5
20650   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20651   (exit $ac_status); } && {
20652          test -z "$ac_c_werror_flag" ||
20653          test ! -s conftest.err
20654        } && test -s conftest$ac_exeext && {
20655          test "$cross_compiling" = yes ||
20656          $as_test_x conftest$ac_exeext
20657        }; then
20658   eval "$as_ac_var=yes"
20659 else
20660   $as_echo "$as_me: failed program was:" >&5
20661 sed 's/^/| /' conftest.$ac_ext >&5
20662
20663         eval "$as_ac_var=no"
20664 fi
20665
20666 rm -rf conftest.dSYM
20667 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20668       conftest$ac_exeext conftest.$ac_ext
20669 fi
20670 ac_res=`eval 'as_val=${'$as_ac_var'}
20671                  $as_echo "$as_val"'`
20672                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20673 $as_echo "$ac_res" >&6; }
20674 as_val=`eval 'as_val=${'$as_ac_var'}
20675                  $as_echo "$as_val"'`
20676    if test "x$as_val" = x""yes; then
20677   cat >>confdefs.h <<_ACEOF
20678 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20679 _ACEOF
20680
20681 else
20682   case " $LIBOBJS " in
20683   *" $ac_func.$ac_objext "* ) ;;
20684   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20685  ;;
20686 esac
20687
20688 fi
20689 done
20690
20691
20692 else
20693   case " $LIBOBJS " in
20694   *" getopt_long.$ac_objext "* ) ;;
20695   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
20696  ;;
20697 esac
20698
20699 fi
20700
20701 # Solaris' getopt() doesn't do what we want for long options, so always use
20702 # our version on that platform.
20703 if test "$PORTNAME" = "solaris"; then
20704   case " $LIBOBJS " in
20705   *" getopt.$ac_objext "* ) ;;
20706   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
20707  ;;
20708 esac
20709
20710 fi
20711
20712 # Cygwin's erand48() is broken (always returns zero) in some releases,
20713 # so force use of ours.
20714 if test "$PORTNAME" = "cygwin"; then
20715   case " $LIBOBJS " in
20716   *" erand48.$ac_objext "* ) ;;
20717   *) LIBOBJS="$LIBOBJS erand48.$ac_objext"
20718  ;;
20719 esac
20720
20721 fi
20722
20723 # Win32 support
20724 if test "$PORTNAME" = "win32"; then
20725
20726 for ac_func in gettimeofday
20727 do
20728 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20729 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20730 $as_echo_n "checking for $ac_func... " >&6; }
20731 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20732   $as_echo_n "(cached) " >&6
20733 else
20734   cat >conftest.$ac_ext <<_ACEOF
20735 /* confdefs.h.  */
20736 _ACEOF
20737 cat confdefs.h >>conftest.$ac_ext
20738 cat >>conftest.$ac_ext <<_ACEOF
20739 /* end confdefs.h.  */
20740 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20741    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20742 #define $ac_func innocuous_$ac_func
20743
20744 /* System header to define __stub macros and hopefully few prototypes,
20745     which can conflict with char $ac_func (); below.
20746     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20747     <limits.h> exists even on freestanding compilers.  */
20748
20749 #ifdef __STDC__
20750 # include <limits.h>
20751 #else
20752 # include <assert.h>
20753 #endif
20754
20755 #undef $ac_func
20756
20757 /* Override any GCC internal prototype to avoid an error.
20758    Use char because int might match the return type of a GCC
20759    builtin and then its argument prototype would still apply.  */
20760 #ifdef __cplusplus
20761 extern "C"
20762 #endif
20763 char $ac_func ();
20764 /* The GNU C library defines this for functions which it implements
20765     to always fail with ENOSYS.  Some functions are actually named
20766     something starting with __ and the normal name is an alias.  */
20767 #if defined __stub_$ac_func || defined __stub___$ac_func
20768 choke me
20769 #endif
20770
20771 int
20772 main ()
20773 {
20774 return $ac_func ();
20775   ;
20776   return 0;
20777 }
20778 _ACEOF
20779 rm -f conftest.$ac_objext conftest$ac_exeext
20780 if { (ac_try="$ac_link"
20781 case "(($ac_try" in
20782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20783   *) ac_try_echo=$ac_try;;
20784 esac
20785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20786 $as_echo "$ac_try_echo") >&5
20787   (eval "$ac_link") 2>conftest.er1
20788   ac_status=$?
20789   grep -v '^ *+' conftest.er1 >conftest.err
20790   rm -f conftest.er1
20791   cat conftest.err >&5
20792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20793   (exit $ac_status); } && {
20794          test -z "$ac_c_werror_flag" ||
20795          test ! -s conftest.err
20796        } && test -s conftest$ac_exeext && {
20797          test "$cross_compiling" = yes ||
20798          $as_test_x conftest$ac_exeext
20799        }; then
20800   eval "$as_ac_var=yes"
20801 else
20802   $as_echo "$as_me: failed program was:" >&5
20803 sed 's/^/| /' conftest.$ac_ext >&5
20804
20805         eval "$as_ac_var=no"
20806 fi
20807
20808 rm -rf conftest.dSYM
20809 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20810       conftest$ac_exeext conftest.$ac_ext
20811 fi
20812 ac_res=`eval 'as_val=${'$as_ac_var'}
20813                  $as_echo "$as_val"'`
20814                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20815 $as_echo "$ac_res" >&6; }
20816 as_val=`eval 'as_val=${'$as_ac_var'}
20817                  $as_echo "$as_val"'`
20818    if test "x$as_val" = x""yes; then
20819   cat >>confdefs.h <<_ACEOF
20820 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20821 _ACEOF
20822
20823 else
20824   case " $LIBOBJS " in
20825   *" $ac_func.$ac_objext "* ) ;;
20826   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20827  ;;
20828 esac
20829
20830 fi
20831 done
20832
20833
20834 case " $LIBOBJS " in
20835   *" kill.$ac_objext "* ) ;;
20836   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
20837  ;;
20838 esac
20839
20840 case " $LIBOBJS " in
20841   *" open.$ac_objext "* ) ;;
20842   *) LIBOBJS="$LIBOBJS open.$ac_objext"
20843  ;;
20844 esac
20845
20846 case " $LIBOBJS " in
20847   *" win32env.$ac_objext "* ) ;;
20848   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
20849  ;;
20850 esac
20851
20852 case " $LIBOBJS " in
20853   *" win32error.$ac_objext "* ) ;;
20854   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
20855  ;;
20856 esac
20857
20858
20859 cat >>confdefs.h <<\_ACEOF
20860 #define HAVE_SYMLINK 1
20861 _ACEOF
20862
20863 fi
20864
20865 if test "$with_readline" = yes; then
20866   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
20867 $as_echo_n "checking for rl_completion_append_character... " >&6; }
20868 cat >conftest.$ac_ext <<_ACEOF
20869 /* confdefs.h.  */
20870 _ACEOF
20871 cat confdefs.h >>conftest.$ac_ext
20872 cat >>conftest.$ac_ext <<_ACEOF
20873 /* end confdefs.h.  */
20874 #include <stdio.h>
20875 #ifdef HAVE_READLINE_READLINE_H
20876 # include <readline/readline.h>
20877 #elif defined(HAVE_READLINE_H)
20878 # include <readline.h>
20879 #endif
20880
20881 int
20882 main ()
20883 {
20884 rl_completion_append_character = 'x';
20885   ;
20886   return 0;
20887 }
20888 _ACEOF
20889 rm -f conftest.$ac_objext conftest$ac_exeext
20890 if { (ac_try="$ac_link"
20891 case "(($ac_try" in
20892   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20893   *) ac_try_echo=$ac_try;;
20894 esac
20895 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20896 $as_echo "$ac_try_echo") >&5
20897   (eval "$ac_link") 2>conftest.er1
20898   ac_status=$?
20899   grep -v '^ *+' conftest.er1 >conftest.err
20900   rm -f conftest.er1
20901   cat conftest.err >&5
20902   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20903   (exit $ac_status); } && {
20904          test -z "$ac_c_werror_flag" ||
20905          test ! -s conftest.err
20906        } && test -s conftest$ac_exeext && {
20907          test "$cross_compiling" = yes ||
20908          $as_test_x conftest$ac_exeext
20909        }; then
20910   { $as_echo "$as_me:$LINENO: result: yes" >&5
20911 $as_echo "yes" >&6; }
20912
20913 cat >>confdefs.h <<\_ACEOF
20914 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
20915 _ACEOF
20916
20917 else
20918   $as_echo "$as_me: failed program was:" >&5
20919 sed 's/^/| /' conftest.$ac_ext >&5
20920
20921         { $as_echo "$as_me:$LINENO: result: no" >&5
20922 $as_echo "no" >&6; }
20923 fi
20924
20925 rm -rf conftest.dSYM
20926 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20927       conftest$ac_exeext conftest.$ac_ext
20928
20929
20930 for ac_func in rl_completion_matches rl_filename_completion_function
20931 do
20932 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20933 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20934 $as_echo_n "checking for $ac_func... " >&6; }
20935 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20936   $as_echo_n "(cached) " >&6
20937 else
20938   cat >conftest.$ac_ext <<_ACEOF
20939 /* confdefs.h.  */
20940 _ACEOF
20941 cat confdefs.h >>conftest.$ac_ext
20942 cat >>conftest.$ac_ext <<_ACEOF
20943 /* end confdefs.h.  */
20944 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20945    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20946 #define $ac_func innocuous_$ac_func
20947
20948 /* System header to define __stub macros and hopefully few prototypes,
20949     which can conflict with char $ac_func (); below.
20950     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20951     <limits.h> exists even on freestanding compilers.  */
20952
20953 #ifdef __STDC__
20954 # include <limits.h>
20955 #else
20956 # include <assert.h>
20957 #endif
20958
20959 #undef $ac_func
20960
20961 /* Override any GCC internal prototype to avoid an error.
20962    Use char because int might match the return type of a GCC
20963    builtin and then its argument prototype would still apply.  */
20964 #ifdef __cplusplus
20965 extern "C"
20966 #endif
20967 char $ac_func ();
20968 /* The GNU C library defines this for functions which it implements
20969     to always fail with ENOSYS.  Some functions are actually named
20970     something starting with __ and the normal name is an alias.  */
20971 #if defined __stub_$ac_func || defined __stub___$ac_func
20972 choke me
20973 #endif
20974
20975 int
20976 main ()
20977 {
20978 return $ac_func ();
20979   ;
20980   return 0;
20981 }
20982 _ACEOF
20983 rm -f conftest.$ac_objext conftest$ac_exeext
20984 if { (ac_try="$ac_link"
20985 case "(($ac_try" in
20986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20987   *) ac_try_echo=$ac_try;;
20988 esac
20989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20990 $as_echo "$ac_try_echo") >&5
20991   (eval "$ac_link") 2>conftest.er1
20992   ac_status=$?
20993   grep -v '^ *+' conftest.er1 >conftest.err
20994   rm -f conftest.er1
20995   cat conftest.err >&5
20996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20997   (exit $ac_status); } && {
20998          test -z "$ac_c_werror_flag" ||
20999          test ! -s conftest.err
21000        } && test -s conftest$ac_exeext && {
21001          test "$cross_compiling" = yes ||
21002          $as_test_x conftest$ac_exeext
21003        }; then
21004   eval "$as_ac_var=yes"
21005 else
21006   $as_echo "$as_me: failed program was:" >&5
21007 sed 's/^/| /' conftest.$ac_ext >&5
21008
21009         eval "$as_ac_var=no"
21010 fi
21011
21012 rm -rf conftest.dSYM
21013 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21014       conftest$ac_exeext conftest.$ac_ext
21015 fi
21016 ac_res=`eval 'as_val=${'$as_ac_var'}
21017                  $as_echo "$as_val"'`
21018                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21019 $as_echo "$ac_res" >&6; }
21020 as_val=`eval 'as_val=${'$as_ac_var'}
21021                  $as_echo "$as_val"'`
21022    if test "x$as_val" = x""yes; then
21023   cat >>confdefs.h <<_ACEOF
21024 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21025 _ACEOF
21026
21027 fi
21028 done
21029
21030
21031
21032 for ac_func in append_history history_truncate_file
21033 do
21034 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21035 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21036 $as_echo_n "checking for $ac_func... " >&6; }
21037 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21038   $as_echo_n "(cached) " >&6
21039 else
21040   cat >conftest.$ac_ext <<_ACEOF
21041 /* confdefs.h.  */
21042 _ACEOF
21043 cat confdefs.h >>conftest.$ac_ext
21044 cat >>conftest.$ac_ext <<_ACEOF
21045 /* end confdefs.h.  */
21046 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21047    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21048 #define $ac_func innocuous_$ac_func
21049
21050 /* System header to define __stub macros and hopefully few prototypes,
21051     which can conflict with char $ac_func (); below.
21052     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21053     <limits.h> exists even on freestanding compilers.  */
21054
21055 #ifdef __STDC__
21056 # include <limits.h>
21057 #else
21058 # include <assert.h>
21059 #endif
21060
21061 #undef $ac_func
21062
21063 /* Override any GCC internal prototype to avoid an error.
21064    Use char because int might match the return type of a GCC
21065    builtin and then its argument prototype would still apply.  */
21066 #ifdef __cplusplus
21067 extern "C"
21068 #endif
21069 char $ac_func ();
21070 /* The GNU C library defines this for functions which it implements
21071     to always fail with ENOSYS.  Some functions are actually named
21072     something starting with __ and the normal name is an alias.  */
21073 #if defined __stub_$ac_func || defined __stub___$ac_func
21074 choke me
21075 #endif
21076
21077 int
21078 main ()
21079 {
21080 return $ac_func ();
21081   ;
21082   return 0;
21083 }
21084 _ACEOF
21085 rm -f conftest.$ac_objext conftest$ac_exeext
21086 if { (ac_try="$ac_link"
21087 case "(($ac_try" in
21088   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21089   *) ac_try_echo=$ac_try;;
21090 esac
21091 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21092 $as_echo "$ac_try_echo") >&5
21093   (eval "$ac_link") 2>conftest.er1
21094   ac_status=$?
21095   grep -v '^ *+' conftest.er1 >conftest.err
21096   rm -f conftest.er1
21097   cat conftest.err >&5
21098   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21099   (exit $ac_status); } && {
21100          test -z "$ac_c_werror_flag" ||
21101          test ! -s conftest.err
21102        } && test -s conftest$ac_exeext && {
21103          test "$cross_compiling" = yes ||
21104          $as_test_x conftest$ac_exeext
21105        }; then
21106   eval "$as_ac_var=yes"
21107 else
21108   $as_echo "$as_me: failed program was:" >&5
21109 sed 's/^/| /' conftest.$ac_ext >&5
21110
21111         eval "$as_ac_var=no"
21112 fi
21113
21114 rm -rf conftest.dSYM
21115 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21116       conftest$ac_exeext conftest.$ac_ext
21117 fi
21118 ac_res=`eval 'as_val=${'$as_ac_var'}
21119                  $as_echo "$as_val"'`
21120                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21121 $as_echo "$ac_res" >&6; }
21122 as_val=`eval 'as_val=${'$as_ac_var'}
21123                  $as_echo "$as_val"'`
21124    if test "x$as_val" = x""yes; then
21125   cat >>confdefs.h <<_ACEOF
21126 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21127 _ACEOF
21128
21129 fi
21130 done
21131
21132 fi
21133
21134
21135 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
21136 $as_echo_n "checking for sigsetjmp... " >&6; }
21137 cat >conftest.$ac_ext <<_ACEOF
21138 /* confdefs.h.  */
21139 _ACEOF
21140 cat confdefs.h >>conftest.$ac_ext
21141 cat >>conftest.$ac_ext <<_ACEOF
21142 /* end confdefs.h.  */
21143 #include <setjmp.h>
21144 int
21145 main ()
21146 {
21147 sigjmp_buf x; sigsetjmp(x, 1);
21148   ;
21149   return 0;
21150 }
21151 _ACEOF
21152 rm -f conftest.$ac_objext conftest$ac_exeext
21153 if { (ac_try="$ac_link"
21154 case "(($ac_try" in
21155   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21156   *) ac_try_echo=$ac_try;;
21157 esac
21158 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21159 $as_echo "$ac_try_echo") >&5
21160   (eval "$ac_link") 2>conftest.er1
21161   ac_status=$?
21162   grep -v '^ *+' conftest.er1 >conftest.err
21163   rm -f conftest.er1
21164   cat conftest.err >&5
21165   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21166   (exit $ac_status); } && {
21167          test -z "$ac_c_werror_flag" ||
21168          test ! -s conftest.err
21169        } && test -s conftest$ac_exeext && {
21170          test "$cross_compiling" = yes ||
21171          $as_test_x conftest$ac_exeext
21172        }; then
21173
21174 cat >>confdefs.h <<\_ACEOF
21175 #define HAVE_SIGSETJMP 1
21176 _ACEOF
21177
21178 { $as_echo "$as_me:$LINENO: result: yes" >&5
21179 $as_echo "yes" >&6; }
21180 else
21181   $as_echo "$as_me: failed program was:" >&5
21182 sed 's/^/| /' conftest.$ac_ext >&5
21183
21184         { $as_echo "$as_me:$LINENO: result: no" >&5
21185 $as_echo "no" >&6; }
21186 fi
21187
21188 rm -rf conftest.dSYM
21189 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21190       conftest$ac_exeext conftest.$ac_ext
21191
21192 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
21193 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
21194 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
21195   $as_echo_n "(cached) " >&6
21196 else
21197   cat >conftest.$ac_ext <<_ACEOF
21198 /* confdefs.h.  */
21199 _ACEOF
21200 cat confdefs.h >>conftest.$ac_ext
21201 cat >>conftest.$ac_ext <<_ACEOF
21202 /* end confdefs.h.  */
21203 #include <signal.h>
21204 /* NetBSD declares sys_siglist in unistd.h.  */
21205 #ifdef HAVE_UNISTD_H
21206 # include <unistd.h>
21207 #endif
21208
21209
21210 int
21211 main ()
21212 {
21213 #ifndef sys_siglist
21214   (void) sys_siglist;
21215 #endif
21216
21217   ;
21218   return 0;
21219 }
21220 _ACEOF
21221 rm -f conftest.$ac_objext
21222 if { (ac_try="$ac_compile"
21223 case "(($ac_try" in
21224   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21225   *) ac_try_echo=$ac_try;;
21226 esac
21227 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21228 $as_echo "$ac_try_echo") >&5
21229   (eval "$ac_compile") 2>conftest.er1
21230   ac_status=$?
21231   grep -v '^ *+' conftest.er1 >conftest.err
21232   rm -f conftest.er1
21233   cat conftest.err >&5
21234   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21235   (exit $ac_status); } && {
21236          test -z "$ac_c_werror_flag" ||
21237          test ! -s conftest.err
21238        } && test -s conftest.$ac_objext; then
21239   ac_cv_have_decl_sys_siglist=yes
21240 else
21241   $as_echo "$as_me: failed program was:" >&5
21242 sed 's/^/| /' conftest.$ac_ext >&5
21243
21244         ac_cv_have_decl_sys_siglist=no
21245 fi
21246
21247 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21248 fi
21249 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
21250 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
21251 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
21252
21253 cat >>confdefs.h <<_ACEOF
21254 #define HAVE_DECL_SYS_SIGLIST 1
21255 _ACEOF
21256
21257
21258 else
21259   cat >>confdefs.h <<_ACEOF
21260 #define HAVE_DECL_SYS_SIGLIST 0
21261 _ACEOF
21262
21263
21264 fi
21265
21266
21267
21268
21269 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
21270 $as_echo_n "checking for syslog... " >&6; }
21271 if test "${ac_cv_func_syslog+set}" = set; then
21272   $as_echo_n "(cached) " >&6
21273 else
21274   cat >conftest.$ac_ext <<_ACEOF
21275 /* confdefs.h.  */
21276 _ACEOF
21277 cat confdefs.h >>conftest.$ac_ext
21278 cat >>conftest.$ac_ext <<_ACEOF
21279 /* end confdefs.h.  */
21280 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
21281    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21282 #define syslog innocuous_syslog
21283
21284 /* System header to define __stub macros and hopefully few prototypes,
21285     which can conflict with char syslog (); below.
21286     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21287     <limits.h> exists even on freestanding compilers.  */
21288
21289 #ifdef __STDC__
21290 # include <limits.h>
21291 #else
21292 # include <assert.h>
21293 #endif
21294
21295 #undef syslog
21296
21297 /* Override any GCC internal prototype to avoid an error.
21298    Use char because int might match the return type of a GCC
21299    builtin and then its argument prototype would still apply.  */
21300 #ifdef __cplusplus
21301 extern "C"
21302 #endif
21303 char syslog ();
21304 /* The GNU C library defines this for functions which it implements
21305     to always fail with ENOSYS.  Some functions are actually named
21306     something starting with __ and the normal name is an alias.  */
21307 #if defined __stub_syslog || defined __stub___syslog
21308 choke me
21309 #endif
21310
21311 int
21312 main ()
21313 {
21314 return syslog ();
21315   ;
21316   return 0;
21317 }
21318 _ACEOF
21319 rm -f conftest.$ac_objext conftest$ac_exeext
21320 if { (ac_try="$ac_link"
21321 case "(($ac_try" in
21322   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21323   *) ac_try_echo=$ac_try;;
21324 esac
21325 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21326 $as_echo "$ac_try_echo") >&5
21327   (eval "$ac_link") 2>conftest.er1
21328   ac_status=$?
21329   grep -v '^ *+' conftest.er1 >conftest.err
21330   rm -f conftest.er1
21331   cat conftest.err >&5
21332   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21333   (exit $ac_status); } && {
21334          test -z "$ac_c_werror_flag" ||
21335          test ! -s conftest.err
21336        } && test -s conftest$ac_exeext && {
21337          test "$cross_compiling" = yes ||
21338          $as_test_x conftest$ac_exeext
21339        }; then
21340   ac_cv_func_syslog=yes
21341 else
21342   $as_echo "$as_me: failed program was:" >&5
21343 sed 's/^/| /' conftest.$ac_ext >&5
21344
21345         ac_cv_func_syslog=no
21346 fi
21347
21348 rm -rf conftest.dSYM
21349 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21350       conftest$ac_exeext conftest.$ac_ext
21351 fi
21352 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
21353 $as_echo "$ac_cv_func_syslog" >&6; }
21354 if test "x$ac_cv_func_syslog" = x""yes; then
21355   if test "${ac_cv_header_syslog_h+set}" = set; then
21356   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21357 $as_echo_n "checking for syslog.h... " >&6; }
21358 if test "${ac_cv_header_syslog_h+set}" = set; then
21359   $as_echo_n "(cached) " >&6
21360 fi
21361 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21362 $as_echo "$ac_cv_header_syslog_h" >&6; }
21363 else
21364   # Is the header compilable?
21365 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
21366 $as_echo_n "checking syslog.h usability... " >&6; }
21367 cat >conftest.$ac_ext <<_ACEOF
21368 /* confdefs.h.  */
21369 _ACEOF
21370 cat confdefs.h >>conftest.$ac_ext
21371 cat >>conftest.$ac_ext <<_ACEOF
21372 /* end confdefs.h.  */
21373 $ac_includes_default
21374 #include <syslog.h>
21375 _ACEOF
21376 rm -f conftest.$ac_objext
21377 if { (ac_try="$ac_compile"
21378 case "(($ac_try" in
21379   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21380   *) ac_try_echo=$ac_try;;
21381 esac
21382 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21383 $as_echo "$ac_try_echo") >&5
21384   (eval "$ac_compile") 2>conftest.er1
21385   ac_status=$?
21386   grep -v '^ *+' conftest.er1 >conftest.err
21387   rm -f conftest.er1
21388   cat conftest.err >&5
21389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21390   (exit $ac_status); } && {
21391          test -z "$ac_c_werror_flag" ||
21392          test ! -s conftest.err
21393        } && test -s conftest.$ac_objext; then
21394   ac_header_compiler=yes
21395 else
21396   $as_echo "$as_me: failed program was:" >&5
21397 sed 's/^/| /' conftest.$ac_ext >&5
21398
21399         ac_header_compiler=no
21400 fi
21401
21402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21403 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21404 $as_echo "$ac_header_compiler" >&6; }
21405
21406 # Is the header present?
21407 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
21408 $as_echo_n "checking syslog.h presence... " >&6; }
21409 cat >conftest.$ac_ext <<_ACEOF
21410 /* confdefs.h.  */
21411 _ACEOF
21412 cat confdefs.h >>conftest.$ac_ext
21413 cat >>conftest.$ac_ext <<_ACEOF
21414 /* end confdefs.h.  */
21415 #include <syslog.h>
21416 _ACEOF
21417 if { (ac_try="$ac_cpp conftest.$ac_ext"
21418 case "(($ac_try" in
21419   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21420   *) ac_try_echo=$ac_try;;
21421 esac
21422 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21423 $as_echo "$ac_try_echo") >&5
21424   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21425   ac_status=$?
21426   grep -v '^ *+' conftest.er1 >conftest.err
21427   rm -f conftest.er1
21428   cat conftest.err >&5
21429   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21430   (exit $ac_status); } >/dev/null && {
21431          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21432          test ! -s conftest.err
21433        }; then
21434   ac_header_preproc=yes
21435 else
21436   $as_echo "$as_me: failed program was:" >&5
21437 sed 's/^/| /' conftest.$ac_ext >&5
21438
21439   ac_header_preproc=no
21440 fi
21441
21442 rm -f conftest.err conftest.$ac_ext
21443 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21444 $as_echo "$ac_header_preproc" >&6; }
21445
21446 # So?  What about this header?
21447 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21448   yes:no: )
21449     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
21450 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21451     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
21452 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
21453     ac_header_preproc=yes
21454     ;;
21455   no:yes:* )
21456     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
21457 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
21458     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
21459 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
21460     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
21461 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
21462     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
21463 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21464     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
21465 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
21466     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
21467 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
21468     ( cat <<\_ASBOX
21469 ## ---------------------------------------- ##
21470 ## Report this to pgsql-bugs@postgresql.org ##
21471 ## ---------------------------------------- ##
21472 _ASBOX
21473      ) | sed "s/^/$as_me: WARNING:     /" >&2
21474     ;;
21475 esac
21476 { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21477 $as_echo_n "checking for syslog.h... " >&6; }
21478 if test "${ac_cv_header_syslog_h+set}" = set; then
21479   $as_echo_n "(cached) " >&6
21480 else
21481   ac_cv_header_syslog_h=$ac_header_preproc
21482 fi
21483 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21484 $as_echo "$ac_cv_header_syslog_h" >&6; }
21485
21486 fi
21487 if test "x$ac_cv_header_syslog_h" = x""yes; then
21488
21489 cat >>confdefs.h <<\_ACEOF
21490 #define HAVE_SYSLOG 1
21491 _ACEOF
21492
21493 fi
21494
21495
21496 fi
21497
21498
21499 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
21500 $as_echo_n "checking for opterr... " >&6; }
21501 if test "${pgac_cv_var_int_opterr+set}" = set; then
21502   $as_echo_n "(cached) " >&6
21503 else
21504   cat >conftest.$ac_ext <<_ACEOF
21505 /* confdefs.h.  */
21506 _ACEOF
21507 cat confdefs.h >>conftest.$ac_ext
21508 cat >>conftest.$ac_ext <<_ACEOF
21509 /* end confdefs.h.  */
21510 #include <unistd.h>
21511 int
21512 main ()
21513 {
21514 extern int opterr; opterr = 1;
21515   ;
21516   return 0;
21517 }
21518 _ACEOF
21519 rm -f conftest.$ac_objext conftest$ac_exeext
21520 if { (ac_try="$ac_link"
21521 case "(($ac_try" in
21522   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21523   *) ac_try_echo=$ac_try;;
21524 esac
21525 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21526 $as_echo "$ac_try_echo") >&5
21527   (eval "$ac_link") 2>conftest.er1
21528   ac_status=$?
21529   grep -v '^ *+' conftest.er1 >conftest.err
21530   rm -f conftest.er1
21531   cat conftest.err >&5
21532   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21533   (exit $ac_status); } && {
21534          test -z "$ac_c_werror_flag" ||
21535          test ! -s conftest.err
21536        } && test -s conftest$ac_exeext && {
21537          test "$cross_compiling" = yes ||
21538          $as_test_x conftest$ac_exeext
21539        }; then
21540   pgac_cv_var_int_opterr=yes
21541 else
21542   $as_echo "$as_me: failed program was:" >&5
21543 sed 's/^/| /' conftest.$ac_ext >&5
21544
21545         pgac_cv_var_int_opterr=no
21546 fi
21547
21548 rm -rf conftest.dSYM
21549 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21550       conftest$ac_exeext conftest.$ac_ext
21551 fi
21552 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
21553 $as_echo "$pgac_cv_var_int_opterr" >&6; }
21554 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
21555
21556 cat >>confdefs.h <<\_ACEOF
21557 #define HAVE_INT_OPTERR 1
21558 _ACEOF
21559
21560 fi
21561
21562 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
21563 $as_echo_n "checking for optreset... " >&6; }
21564 if test "${pgac_cv_var_int_optreset+set}" = set; then
21565   $as_echo_n "(cached) " >&6
21566 else
21567   cat >conftest.$ac_ext <<_ACEOF
21568 /* confdefs.h.  */
21569 _ACEOF
21570 cat confdefs.h >>conftest.$ac_ext
21571 cat >>conftest.$ac_ext <<_ACEOF
21572 /* end confdefs.h.  */
21573 #include <unistd.h>
21574 int
21575 main ()
21576 {
21577 extern int optreset; optreset = 1;
21578   ;
21579   return 0;
21580 }
21581 _ACEOF
21582 rm -f conftest.$ac_objext conftest$ac_exeext
21583 if { (ac_try="$ac_link"
21584 case "(($ac_try" in
21585   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21586   *) ac_try_echo=$ac_try;;
21587 esac
21588 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21589 $as_echo "$ac_try_echo") >&5
21590   (eval "$ac_link") 2>conftest.er1
21591   ac_status=$?
21592   grep -v '^ *+' conftest.er1 >conftest.err
21593   rm -f conftest.er1
21594   cat conftest.err >&5
21595   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21596   (exit $ac_status); } && {
21597          test -z "$ac_c_werror_flag" ||
21598          test ! -s conftest.err
21599        } && test -s conftest$ac_exeext && {
21600          test "$cross_compiling" = yes ||
21601          $as_test_x conftest$ac_exeext
21602        }; then
21603   pgac_cv_var_int_optreset=yes
21604 else
21605   $as_echo "$as_me: failed program was:" >&5
21606 sed 's/^/| /' conftest.$ac_ext >&5
21607
21608         pgac_cv_var_int_optreset=no
21609 fi
21610
21611 rm -rf conftest.dSYM
21612 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21613       conftest$ac_exeext conftest.$ac_ext
21614 fi
21615 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
21616 $as_echo "$pgac_cv_var_int_optreset" >&6; }
21617 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
21618
21619 cat >>confdefs.h <<\_ACEOF
21620 #define HAVE_INT_OPTRESET 1
21621 _ACEOF
21622
21623 fi
21624
21625
21626
21627 for ac_func in strtoll strtoq
21628 do
21629 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21630 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21631 $as_echo_n "checking for $ac_func... " >&6; }
21632 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21633   $as_echo_n "(cached) " >&6
21634 else
21635   cat >conftest.$ac_ext <<_ACEOF
21636 /* confdefs.h.  */
21637 _ACEOF
21638 cat confdefs.h >>conftest.$ac_ext
21639 cat >>conftest.$ac_ext <<_ACEOF
21640 /* end confdefs.h.  */
21641 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21642    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21643 #define $ac_func innocuous_$ac_func
21644
21645 /* System header to define __stub macros and hopefully few prototypes,
21646     which can conflict with char $ac_func (); below.
21647     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21648     <limits.h> exists even on freestanding compilers.  */
21649
21650 #ifdef __STDC__
21651 # include <limits.h>
21652 #else
21653 # include <assert.h>
21654 #endif
21655
21656 #undef $ac_func
21657
21658 /* Override any GCC internal prototype to avoid an error.
21659    Use char because int might match the return type of a GCC
21660    builtin and then its argument prototype would still apply.  */
21661 #ifdef __cplusplus
21662 extern "C"
21663 #endif
21664 char $ac_func ();
21665 /* The GNU C library defines this for functions which it implements
21666     to always fail with ENOSYS.  Some functions are actually named
21667     something starting with __ and the normal name is an alias.  */
21668 #if defined __stub_$ac_func || defined __stub___$ac_func
21669 choke me
21670 #endif
21671
21672 int
21673 main ()
21674 {
21675 return $ac_func ();
21676   ;
21677   return 0;
21678 }
21679 _ACEOF
21680 rm -f conftest.$ac_objext conftest$ac_exeext
21681 if { (ac_try="$ac_link"
21682 case "(($ac_try" in
21683   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21684   *) ac_try_echo=$ac_try;;
21685 esac
21686 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21687 $as_echo "$ac_try_echo") >&5
21688   (eval "$ac_link") 2>conftest.er1
21689   ac_status=$?
21690   grep -v '^ *+' conftest.er1 >conftest.err
21691   rm -f conftest.er1
21692   cat conftest.err >&5
21693   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21694   (exit $ac_status); } && {
21695          test -z "$ac_c_werror_flag" ||
21696          test ! -s conftest.err
21697        } && test -s conftest$ac_exeext && {
21698          test "$cross_compiling" = yes ||
21699          $as_test_x conftest$ac_exeext
21700        }; then
21701   eval "$as_ac_var=yes"
21702 else
21703   $as_echo "$as_me: failed program was:" >&5
21704 sed 's/^/| /' conftest.$ac_ext >&5
21705
21706         eval "$as_ac_var=no"
21707 fi
21708
21709 rm -rf conftest.dSYM
21710 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21711       conftest$ac_exeext conftest.$ac_ext
21712 fi
21713 ac_res=`eval 'as_val=${'$as_ac_var'}
21714                  $as_echo "$as_val"'`
21715                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21716 $as_echo "$ac_res" >&6; }
21717 as_val=`eval 'as_val=${'$as_ac_var'}
21718                  $as_echo "$as_val"'`
21719    if test "x$as_val" = x""yes; then
21720   cat >>confdefs.h <<_ACEOF
21721 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21722 _ACEOF
21723  break
21724 fi
21725 done
21726
21727
21728
21729 for ac_func in strtoull strtouq
21730 do
21731 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21732 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21733 $as_echo_n "checking for $ac_func... " >&6; }
21734 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21735   $as_echo_n "(cached) " >&6
21736 else
21737   cat >conftest.$ac_ext <<_ACEOF
21738 /* confdefs.h.  */
21739 _ACEOF
21740 cat confdefs.h >>conftest.$ac_ext
21741 cat >>conftest.$ac_ext <<_ACEOF
21742 /* end confdefs.h.  */
21743 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21744    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21745 #define $ac_func innocuous_$ac_func
21746
21747 /* System header to define __stub macros and hopefully few prototypes,
21748     which can conflict with char $ac_func (); below.
21749     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21750     <limits.h> exists even on freestanding compilers.  */
21751
21752 #ifdef __STDC__
21753 # include <limits.h>
21754 #else
21755 # include <assert.h>
21756 #endif
21757
21758 #undef $ac_func
21759
21760 /* Override any GCC internal prototype to avoid an error.
21761    Use char because int might match the return type of a GCC
21762    builtin and then its argument prototype would still apply.  */
21763 #ifdef __cplusplus
21764 extern "C"
21765 #endif
21766 char $ac_func ();
21767 /* The GNU C library defines this for functions which it implements
21768     to always fail with ENOSYS.  Some functions are actually named
21769     something starting with __ and the normal name is an alias.  */
21770 #if defined __stub_$ac_func || defined __stub___$ac_func
21771 choke me
21772 #endif
21773
21774 int
21775 main ()
21776 {
21777 return $ac_func ();
21778   ;
21779   return 0;
21780 }
21781 _ACEOF
21782 rm -f conftest.$ac_objext conftest$ac_exeext
21783 if { (ac_try="$ac_link"
21784 case "(($ac_try" in
21785   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21786   *) ac_try_echo=$ac_try;;
21787 esac
21788 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21789 $as_echo "$ac_try_echo") >&5
21790   (eval "$ac_link") 2>conftest.er1
21791   ac_status=$?
21792   grep -v '^ *+' conftest.er1 >conftest.err
21793   rm -f conftest.er1
21794   cat conftest.err >&5
21795   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21796   (exit $ac_status); } && {
21797          test -z "$ac_c_werror_flag" ||
21798          test ! -s conftest.err
21799        } && test -s conftest$ac_exeext && {
21800          test "$cross_compiling" = yes ||
21801          $as_test_x conftest$ac_exeext
21802        }; then
21803   eval "$as_ac_var=yes"
21804 else
21805   $as_echo "$as_me: failed program was:" >&5
21806 sed 's/^/| /' conftest.$ac_ext >&5
21807
21808         eval "$as_ac_var=no"
21809 fi
21810
21811 rm -rf conftest.dSYM
21812 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21813       conftest$ac_exeext conftest.$ac_ext
21814 fi
21815 ac_res=`eval 'as_val=${'$as_ac_var'}
21816                  $as_echo "$as_val"'`
21817                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21818 $as_echo "$ac_res" >&6; }
21819 as_val=`eval 'as_val=${'$as_ac_var'}
21820                  $as_echo "$as_val"'`
21821    if test "x$as_val" = x""yes; then
21822   cat >>confdefs.h <<_ACEOF
21823 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21824 _ACEOF
21825  break
21826 fi
21827 done
21828
21829
21830 # Check for one of atexit() or on_exit()
21831
21832 for ac_func in atexit
21833 do
21834 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21835 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21836 $as_echo_n "checking for $ac_func... " >&6; }
21837 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21838   $as_echo_n "(cached) " >&6
21839 else
21840   cat >conftest.$ac_ext <<_ACEOF
21841 /* confdefs.h.  */
21842 _ACEOF
21843 cat confdefs.h >>conftest.$ac_ext
21844 cat >>conftest.$ac_ext <<_ACEOF
21845 /* end confdefs.h.  */
21846 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21847    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21848 #define $ac_func innocuous_$ac_func
21849
21850 /* System header to define __stub macros and hopefully few prototypes,
21851     which can conflict with char $ac_func (); below.
21852     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21853     <limits.h> exists even on freestanding compilers.  */
21854
21855 #ifdef __STDC__
21856 # include <limits.h>
21857 #else
21858 # include <assert.h>
21859 #endif
21860
21861 #undef $ac_func
21862
21863 /* Override any GCC internal prototype to avoid an error.
21864    Use char because int might match the return type of a GCC
21865    builtin and then its argument prototype would still apply.  */
21866 #ifdef __cplusplus
21867 extern "C"
21868 #endif
21869 char $ac_func ();
21870 /* The GNU C library defines this for functions which it implements
21871     to always fail with ENOSYS.  Some functions are actually named
21872     something starting with __ and the normal name is an alias.  */
21873 #if defined __stub_$ac_func || defined __stub___$ac_func
21874 choke me
21875 #endif
21876
21877 int
21878 main ()
21879 {
21880 return $ac_func ();
21881   ;
21882   return 0;
21883 }
21884 _ACEOF
21885 rm -f conftest.$ac_objext conftest$ac_exeext
21886 if { (ac_try="$ac_link"
21887 case "(($ac_try" in
21888   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21889   *) ac_try_echo=$ac_try;;
21890 esac
21891 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21892 $as_echo "$ac_try_echo") >&5
21893   (eval "$ac_link") 2>conftest.er1
21894   ac_status=$?
21895   grep -v '^ *+' conftest.er1 >conftest.err
21896   rm -f conftest.er1
21897   cat conftest.err >&5
21898   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21899   (exit $ac_status); } && {
21900          test -z "$ac_c_werror_flag" ||
21901          test ! -s conftest.err
21902        } && test -s conftest$ac_exeext && {
21903          test "$cross_compiling" = yes ||
21904          $as_test_x conftest$ac_exeext
21905        }; then
21906   eval "$as_ac_var=yes"
21907 else
21908   $as_echo "$as_me: failed program was:" >&5
21909 sed 's/^/| /' conftest.$ac_ext >&5
21910
21911         eval "$as_ac_var=no"
21912 fi
21913
21914 rm -rf conftest.dSYM
21915 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21916       conftest$ac_exeext conftest.$ac_ext
21917 fi
21918 ac_res=`eval 'as_val=${'$as_ac_var'}
21919                  $as_echo "$as_val"'`
21920                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21921 $as_echo "$ac_res" >&6; }
21922 as_val=`eval 'as_val=${'$as_ac_var'}
21923                  $as_echo "$as_val"'`
21924    if test "x$as_val" = x""yes; then
21925   cat >>confdefs.h <<_ACEOF
21926 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21927 _ACEOF
21928
21929 else
21930
21931 for ac_func in on_exit
21932 do
21933 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21934 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21935 $as_echo_n "checking for $ac_func... " >&6; }
21936 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21937   $as_echo_n "(cached) " >&6
21938 else
21939   cat >conftest.$ac_ext <<_ACEOF
21940 /* confdefs.h.  */
21941 _ACEOF
21942 cat confdefs.h >>conftest.$ac_ext
21943 cat >>conftest.$ac_ext <<_ACEOF
21944 /* end confdefs.h.  */
21945 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21946    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21947 #define $ac_func innocuous_$ac_func
21948
21949 /* System header to define __stub macros and hopefully few prototypes,
21950     which can conflict with char $ac_func (); below.
21951     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21952     <limits.h> exists even on freestanding compilers.  */
21953
21954 #ifdef __STDC__
21955 # include <limits.h>
21956 #else
21957 # include <assert.h>
21958 #endif
21959
21960 #undef $ac_func
21961
21962 /* Override any GCC internal prototype to avoid an error.
21963    Use char because int might match the return type of a GCC
21964    builtin and then its argument prototype would still apply.  */
21965 #ifdef __cplusplus
21966 extern "C"
21967 #endif
21968 char $ac_func ();
21969 /* The GNU C library defines this for functions which it implements
21970     to always fail with ENOSYS.  Some functions are actually named
21971     something starting with __ and the normal name is an alias.  */
21972 #if defined __stub_$ac_func || defined __stub___$ac_func
21973 choke me
21974 #endif
21975
21976 int
21977 main ()
21978 {
21979 return $ac_func ();
21980   ;
21981   return 0;
21982 }
21983 _ACEOF
21984 rm -f conftest.$ac_objext conftest$ac_exeext
21985 if { (ac_try="$ac_link"
21986 case "(($ac_try" in
21987   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21988   *) ac_try_echo=$ac_try;;
21989 esac
21990 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21991 $as_echo "$ac_try_echo") >&5
21992   (eval "$ac_link") 2>conftest.er1
21993   ac_status=$?
21994   grep -v '^ *+' conftest.er1 >conftest.err
21995   rm -f conftest.er1
21996   cat conftest.err >&5
21997   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21998   (exit $ac_status); } && {
21999          test -z "$ac_c_werror_flag" ||
22000          test ! -s conftest.err
22001        } && test -s conftest$ac_exeext && {
22002          test "$cross_compiling" = yes ||
22003          $as_test_x conftest$ac_exeext
22004        }; then
22005   eval "$as_ac_var=yes"
22006 else
22007   $as_echo "$as_me: failed program was:" >&5
22008 sed 's/^/| /' conftest.$ac_ext >&5
22009
22010         eval "$as_ac_var=no"
22011 fi
22012
22013 rm -rf conftest.dSYM
22014 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22015       conftest$ac_exeext conftest.$ac_ext
22016 fi
22017 ac_res=`eval 'as_val=${'$as_ac_var'}
22018                  $as_echo "$as_val"'`
22019                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22020 $as_echo "$ac_res" >&6; }
22021 as_val=`eval 'as_val=${'$as_ac_var'}
22022                  $as_echo "$as_val"'`
22023    if test "x$as_val" = x""yes; then
22024   cat >>confdefs.h <<_ACEOF
22025 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22026 _ACEOF
22027
22028 else
22029   { { $as_echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
22030 $as_echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
22031    { (exit 1); exit 1; }; }
22032 fi
22033 done
22034
22035 fi
22036 done
22037
22038
22039
22040 #
22041 # Pthreads
22042 #
22043 # For each platform, we need to know about any special compile and link
22044 # libraries, and whether the normal C function names are thread-safe.
22045 # See the comment at the top of src/port/thread.c for more information.
22046 # WIN32 doesn't need the pthread tests;  it always uses threads
22047 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
22048
22049
22050
22051 ac_ext=c
22052 ac_cpp='$CPP $CPPFLAGS'
22053 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22054 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22055 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22056
22057 acx_pthread_ok=no
22058
22059 # We used to check for pthread.h first, but this fails if pthread.h
22060 # requires special compiler flags (e.g. on True64 or Sequent).
22061 # It gets checked for in the link test anyway.
22062
22063 # First of all, check if the user has set any of the PTHREAD_LIBS,
22064 # etcetera environment variables, and if threads linking works using
22065 # them:
22066 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
22067         save_CFLAGS="$CFLAGS"
22068         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22069         save_LIBS="$LIBS"
22070         LIBS="$PTHREAD_LIBS $LIBS"
22071         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
22072 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
22073         cat >conftest.$ac_ext <<_ACEOF
22074 /* confdefs.h.  */
22075 _ACEOF
22076 cat confdefs.h >>conftest.$ac_ext
22077 cat >>conftest.$ac_ext <<_ACEOF
22078 /* end confdefs.h.  */
22079
22080 /* Override any GCC internal prototype to avoid an error.
22081    Use char because int might match the return type of a GCC
22082    builtin and then its argument prototype would still apply.  */
22083 #ifdef __cplusplus
22084 extern "C"
22085 #endif
22086 char pthread_join ();
22087 int
22088 main ()
22089 {
22090 return pthread_join ();
22091   ;
22092   return 0;
22093 }
22094 _ACEOF
22095 rm -f conftest.$ac_objext conftest$ac_exeext
22096 if { (ac_try="$ac_link"
22097 case "(($ac_try" in
22098   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22099   *) ac_try_echo=$ac_try;;
22100 esac
22101 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22102 $as_echo "$ac_try_echo") >&5
22103   (eval "$ac_link") 2>conftest.er1
22104   ac_status=$?
22105   grep -v '^ *+' conftest.er1 >conftest.err
22106   rm -f conftest.er1
22107   cat conftest.err >&5
22108   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22109   (exit $ac_status); } && {
22110          test -z "$ac_c_werror_flag" ||
22111          test ! -s conftest.err
22112        } && test -s conftest$ac_exeext && {
22113          test "$cross_compiling" = yes ||
22114          $as_test_x conftest$ac_exeext
22115        }; then
22116   acx_pthread_ok=yes
22117 else
22118   $as_echo "$as_me: failed program was:" >&5
22119 sed 's/^/| /' conftest.$ac_ext >&5
22120
22121
22122 fi
22123
22124 rm -rf conftest.dSYM
22125 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22126       conftest$ac_exeext conftest.$ac_ext
22127         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22128 $as_echo "$acx_pthread_ok" >&6; }
22129         if test x"$acx_pthread_ok" = xno; then
22130                 PTHREAD_LIBS=""
22131                 PTHREAD_CFLAGS=""
22132         fi
22133         LIBS="$save_LIBS"
22134         CFLAGS="$save_CFLAGS"
22135 fi
22136
22137 # We must check for the threads library under a number of different
22138 # names; the ordering is very important because some systems
22139 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
22140 # libraries is broken (non-POSIX).
22141
22142 # Create a list of thread flags to try.  Items starting with a "-" are
22143 # C compiler flags, and other items are library names, except for "none"
22144 # which indicates that we try without any flags at all, and "pthread-config"
22145 # which is a program returning the flags for the Pth emulation library.
22146
22147 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
22148
22149 # The ordering *is* (sometimes) important.  Some notes on the
22150 # individual items follow:
22151
22152 # pthreads: AIX (must check this before -lpthread)
22153 # none: in case threads are in libc; should be tried before -Kthread and
22154 #       other compiler flags to prevent continual compiler warnings
22155 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
22156 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
22157 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
22158 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
22159 # -pthreads: Solaris/gcc
22160 # -mthreads: Mingw32/gcc, Lynx/gcc
22161 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
22162 #      doesn't hurt to check since this sometimes defines pthreads too;
22163 #      also defines -D_REENTRANT)
22164 # pthread: Linux, etcetera
22165 # --thread-safe: KAI C++
22166 # pthread-config: use pthread-config program (for GNU Pth library)
22167
22168 case "${host_cpu}-${host_os}" in
22169         *solaris*)
22170
22171         # On Solaris (at least, for some versions), libc contains stubbed
22172         # (non-functional) versions of the pthreads routines, so link-based
22173         # tests will erroneously succeed.  (We need to link with -pthread or
22174         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
22175         # a function called by this macro, so we could check for that, but
22176         # who knows whether they'll stub that too in a future libc.)  So,
22177         # we'll just look for -pthreads and -lpthread first:
22178
22179         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
22180         ;;
22181 esac
22182
22183 if test x"$acx_pthread_ok" = xno; then
22184 for flag in $acx_pthread_flags; do
22185
22186         tryPTHREAD_CFLAGS=""
22187         tryPTHREAD_LIBS=""
22188         case $flag in
22189                 none)
22190                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
22191 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
22192                 ;;
22193
22194                 -*)
22195                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
22196 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
22197                 tryPTHREAD_CFLAGS="$flag"
22198                 ;;
22199
22200                 pthread-config)
22201                 # skip this if we already have flags defined, for PostgreSQL
22202                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
22203                 # Extract the first word of "pthread-config", so it can be a program name with args.
22204 set dummy pthread-config; ac_word=$2
22205 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22206 $as_echo_n "checking for $ac_word... " >&6; }
22207 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
22208   $as_echo_n "(cached) " >&6
22209 else
22210   if test -n "$acx_pthread_config"; then
22211   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
22212 else
22213 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22214 for as_dir in $PATH
22215 do
22216   IFS=$as_save_IFS
22217   test -z "$as_dir" && as_dir=.
22218   for ac_exec_ext in '' $ac_executable_extensions; do
22219   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22220     ac_cv_prog_acx_pthread_config="yes"
22221     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22222     break 2
22223   fi
22224 done
22225 done
22226 IFS=$as_save_IFS
22227
22228   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
22229 fi
22230 fi
22231 acx_pthread_config=$ac_cv_prog_acx_pthread_config
22232 if test -n "$acx_pthread_config"; then
22233   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
22234 $as_echo "$acx_pthread_config" >&6; }
22235 else
22236   { $as_echo "$as_me:$LINENO: result: no" >&5
22237 $as_echo "no" >&6; }
22238 fi
22239
22240
22241                 if test x"$acx_pthread_config" = xno; then continue; fi
22242                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
22243                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
22244                 ;;
22245
22246                 *)
22247                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
22248 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
22249                 tryPTHREAD_LIBS="-l$flag"
22250                 ;;
22251         esac
22252
22253         save_LIBS="$LIBS"
22254         save_CFLAGS="$CFLAGS"
22255         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
22256         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22257
22258         # Check for various functions.  We must include pthread.h,
22259         # since some functions may be macros.  (On the Sequent, we
22260         # need a special flag -Kthread to make this header compile.)
22261         # We check for pthread_join because it is in -lpthread on IRIX
22262         # while pthread_create is in libc.  We check for pthread_attr_init
22263         # due to DEC craziness with -lpthreads.  We check for
22264         # pthread_cleanup_push because it is one of the few pthread
22265         # functions on Solaris that doesn't have a non-functional libc stub.
22266         # We try pthread_create on general principles.
22267         cat >conftest.$ac_ext <<_ACEOF
22268 /* confdefs.h.  */
22269 _ACEOF
22270 cat confdefs.h >>conftest.$ac_ext
22271 cat >>conftest.$ac_ext <<_ACEOF
22272 /* end confdefs.h.  */
22273 #include <pthread.h>
22274 int
22275 main ()
22276 {
22277 pthread_t th; pthread_join(th, 0);
22278                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
22279                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
22280   ;
22281   return 0;
22282 }
22283 _ACEOF
22284 rm -f conftest.$ac_objext conftest$ac_exeext
22285 if { (ac_try="$ac_link"
22286 case "(($ac_try" in
22287   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22288   *) ac_try_echo=$ac_try;;
22289 esac
22290 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22291 $as_echo "$ac_try_echo") >&5
22292   (eval "$ac_link") 2>conftest.er1
22293   ac_status=$?
22294   grep -v '^ *+' conftest.er1 >conftest.err
22295   rm -f conftest.er1
22296   cat conftest.err >&5
22297   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22298   (exit $ac_status); } && {
22299          test -z "$ac_c_werror_flag" ||
22300          test ! -s conftest.err
22301        } && test -s conftest$ac_exeext && {
22302          test "$cross_compiling" = yes ||
22303          $as_test_x conftest$ac_exeext
22304        }; then
22305   acx_pthread_ok=yes
22306 else
22307   $as_echo "$as_me: failed program was:" >&5
22308 sed 's/^/| /' conftest.$ac_ext >&5
22309
22310         acx_pthread_ok=no
22311 fi
22312
22313 rm -rf conftest.dSYM
22314 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22315       conftest$ac_exeext conftest.$ac_ext
22316
22317         if test "x$acx_pthread_ok" = xyes; then
22318             # Don't use options that are ignored by the compiler.
22319             # We find them by checking stderror.
22320             cat >conftest.$ac_ext <<_ACEOF
22321 int
22322 main (int argc, char **argv)
22323 {
22324   (void) argc;
22325   (void) argv;
22326   return 0;
22327 }
22328 _ACEOF
22329             rm -f conftest.$ac_objext conftest$ac_exeext
22330             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
22331                 # we continue with more flags because Linux needs -lpthread
22332                 # for libpq builds on PostgreSQL.  The test above only
22333                 # tests for building binaries, not shared libraries.
22334                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
22335                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22336             else   acx_pthread_ok=no
22337             fi
22338         fi
22339
22340         LIBS="$save_LIBS"
22341         CFLAGS="$save_CFLAGS"
22342
22343         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22344 $as_echo "$acx_pthread_ok" >&6; }
22345 done
22346 fi
22347
22348 # Various other checks:
22349 if test "x$acx_pthread_ok" = xyes; then
22350         save_LIBS="$LIBS"
22351         LIBS="$PTHREAD_LIBS $LIBS"
22352         save_CFLAGS="$CFLAGS"
22353         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22354
22355         # Detect AIX lossage: threads are created detached by default
22356         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
22357         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
22358 $as_echo_n "checking for joinable pthread attribute... " >&6; }
22359         cat >conftest.$ac_ext <<_ACEOF
22360 /* confdefs.h.  */
22361 _ACEOF
22362 cat confdefs.h >>conftest.$ac_ext
22363 cat >>conftest.$ac_ext <<_ACEOF
22364 /* end confdefs.h.  */
22365 #include <pthread.h>
22366 int
22367 main ()
22368 {
22369 int attr=PTHREAD_CREATE_JOINABLE;
22370   ;
22371   return 0;
22372 }
22373 _ACEOF
22374 rm -f conftest.$ac_objext conftest$ac_exeext
22375 if { (ac_try="$ac_link"
22376 case "(($ac_try" in
22377   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22378   *) ac_try_echo=$ac_try;;
22379 esac
22380 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22381 $as_echo "$ac_try_echo") >&5
22382   (eval "$ac_link") 2>conftest.er1
22383   ac_status=$?
22384   grep -v '^ *+' conftest.er1 >conftest.err
22385   rm -f conftest.er1
22386   cat conftest.err >&5
22387   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22388   (exit $ac_status); } && {
22389          test -z "$ac_c_werror_flag" ||
22390          test ! -s conftest.err
22391        } && test -s conftest$ac_exeext && {
22392          test "$cross_compiling" = yes ||
22393          $as_test_x conftest$ac_exeext
22394        }; then
22395   ok=PTHREAD_CREATE_JOINABLE
22396 else
22397   $as_echo "$as_me: failed program was:" >&5
22398 sed 's/^/| /' conftest.$ac_ext >&5
22399
22400         ok=unknown
22401 fi
22402
22403 rm -rf conftest.dSYM
22404 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22405       conftest$ac_exeext conftest.$ac_ext
22406         if test x"$ok" = xunknown; then
22407                 cat >conftest.$ac_ext <<_ACEOF
22408 /* confdefs.h.  */
22409 _ACEOF
22410 cat confdefs.h >>conftest.$ac_ext
22411 cat >>conftest.$ac_ext <<_ACEOF
22412 /* end confdefs.h.  */
22413 #include <pthread.h>
22414 int
22415 main ()
22416 {
22417 int attr=PTHREAD_CREATE_UNDETACHED;
22418   ;
22419   return 0;
22420 }
22421 _ACEOF
22422 rm -f conftest.$ac_objext conftest$ac_exeext
22423 if { (ac_try="$ac_link"
22424 case "(($ac_try" in
22425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22426   *) ac_try_echo=$ac_try;;
22427 esac
22428 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22429 $as_echo "$ac_try_echo") >&5
22430   (eval "$ac_link") 2>conftest.er1
22431   ac_status=$?
22432   grep -v '^ *+' conftest.er1 >conftest.err
22433   rm -f conftest.er1
22434   cat conftest.err >&5
22435   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22436   (exit $ac_status); } && {
22437          test -z "$ac_c_werror_flag" ||
22438          test ! -s conftest.err
22439        } && test -s conftest$ac_exeext && {
22440          test "$cross_compiling" = yes ||
22441          $as_test_x conftest$ac_exeext
22442        }; then
22443   ok=PTHREAD_CREATE_UNDETACHED
22444 else
22445   $as_echo "$as_me: failed program was:" >&5
22446 sed 's/^/| /' conftest.$ac_ext >&5
22447
22448         ok=unknown
22449 fi
22450
22451 rm -rf conftest.dSYM
22452 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22453       conftest$ac_exeext conftest.$ac_ext
22454         fi
22455         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
22456
22457 cat >>confdefs.h <<\_ACEOF
22458 #define PTHREAD_CREATE_JOINABLE $ok
22459 _ACEOF
22460
22461         fi
22462         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
22463 $as_echo "${ok}" >&6; }
22464         if test x"$ok" = xunknown; then
22465                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
22466 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
22467         fi
22468
22469         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
22470 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
22471         flag=no
22472 # We always add these in PostgreSQL
22473 #       case "${host_cpu}-${host_os}" in
22474 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
22475 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
22476 #       esac
22477         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
22478 $as_echo "${flag}" >&6; }
22479         if test "x$flag" != xno; then
22480                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
22481         fi
22482
22483         LIBS="$save_LIBS"
22484         CFLAGS="$save_CFLAGS"
22485
22486 # Supporting cc_r would require a special CC in all places that
22487 # use libpq, and that is ugly, so we don't do it.  Users can still
22488 # define their compiler as cc_r to do thread builds of everything.
22489         # More AIX lossage: must compile with cc_r
22490         # Extract the first word of "cc_r", so it can be a program name with args.
22491 set dummy cc_r; ac_word=$2
22492 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22493 $as_echo_n "checking for $ac_word... " >&6; }
22494 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
22495   $as_echo_n "(cached) " >&6
22496 else
22497   if test -n "$PTHREAD_CC"; then
22498   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
22499 else
22500 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22501 for as_dir in $PATH
22502 do
22503   IFS=$as_save_IFS
22504   test -z "$as_dir" && as_dir=.
22505   for ac_exec_ext in '' $ac_executable_extensions; do
22506   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22507     ac_cv_prog_PTHREAD_CC="cc_r"
22508     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22509     break 2
22510   fi
22511 done
22512 done
22513 IFS=$as_save_IFS
22514
22515   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
22516 fi
22517 fi
22518 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
22519 if test -n "$PTHREAD_CC"; then
22520   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
22521 $as_echo "$PTHREAD_CC" >&6; }
22522 else
22523   { $as_echo "$as_me:$LINENO: result: no" >&5
22524 $as_echo "no" >&6; }
22525 fi
22526
22527
22528 else
22529         PTHREAD_CC="$CC"
22530 fi
22531
22532
22533
22534
22535
22536 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
22537 if test x"$acx_pthread_ok" = xyes; then
22538
22539 cat >>confdefs.h <<\_ACEOF
22540 #define HAVE_PTHREAD 1
22541 _ACEOF
22542
22543         :
22544 else
22545         acx_pthread_ok=no
22546
22547 fi
22548 ac_ext=c
22549 ac_cpp='$CPP $CPPFLAGS'
22550 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22551 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22552 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22553
22554         # set thread flags
22555
22556 # Some platforms use these, so just define them.  They can't hurt if they
22557 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
22558 # enables 5-arg getpwuid_r, among other things.
22559 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
22560
22561
22562 # At this point, we don't want to muck with the compiler name for threading.
22563 # Let's see who fails, perhaps AIX.  2004-04-23
22564 if test "$PTHREAD_CC" != "$CC"; then
22565 { { $as_echo "$as_me:$LINENO: error:
22566 PostgreSQL does not support platforms that require a special compiler
22567 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
22568 $as_echo "$as_me: error:
22569 PostgreSQL does not support platforms that require a special compiler
22570 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
22571    { (exit 1); exit 1; }; }
22572 fi
22573
22574 # Check for *_r functions
22575 _CFLAGS="$CFLAGS"
22576 _LIBS="$LIBS"
22577 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22578 LIBS="$LIBS $PTHREAD_LIBS"
22579
22580 if test "$PORTNAME" != "win32"; then
22581 if test "${ac_cv_header_pthread_h+set}" = set; then
22582   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
22583 $as_echo_n "checking for pthread.h... " >&6; }
22584 if test "${ac_cv_header_pthread_h+set}" = set; then
22585   $as_echo_n "(cached) " >&6
22586 fi
22587 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
22588 $as_echo "$ac_cv_header_pthread_h" >&6; }
22589 else
22590   # Is the header compilable?
22591 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
22592 $as_echo_n "checking pthread.h usability... " >&6; }
22593 cat >conftest.$ac_ext <<_ACEOF
22594 /* confdefs.h.  */
22595 _ACEOF
22596 cat confdefs.h >>conftest.$ac_ext
22597 cat >>conftest.$ac_ext <<_ACEOF
22598 /* end confdefs.h.  */
22599 $ac_includes_default
22600 #include <pthread.h>
22601 _ACEOF
22602 rm -f conftest.$ac_objext
22603 if { (ac_try="$ac_compile"
22604 case "(($ac_try" in
22605   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22606   *) ac_try_echo=$ac_try;;
22607 esac
22608 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22609 $as_echo "$ac_try_echo") >&5
22610   (eval "$ac_compile") 2>conftest.er1
22611   ac_status=$?
22612   grep -v '^ *+' conftest.er1 >conftest.err
22613   rm -f conftest.er1
22614   cat conftest.err >&5
22615   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22616   (exit $ac_status); } && {
22617          test -z "$ac_c_werror_flag" ||
22618          test ! -s conftest.err
22619        } && test -s conftest.$ac_objext; then
22620   ac_header_compiler=yes
22621 else
22622   $as_echo "$as_me: failed program was:" >&5
22623 sed 's/^/| /' conftest.$ac_ext >&5
22624
22625         ac_header_compiler=no
22626 fi
22627
22628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22629 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22630 $as_echo "$ac_header_compiler" >&6; }
22631
22632 # Is the header present?
22633 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
22634 $as_echo_n "checking pthread.h presence... " >&6; }
22635 cat >conftest.$ac_ext <<_ACEOF
22636 /* confdefs.h.  */
22637 _ACEOF
22638 cat confdefs.h >>conftest.$ac_ext
22639 cat >>conftest.$ac_ext <<_ACEOF
22640 /* end confdefs.h.  */
22641 #include <pthread.h>
22642 _ACEOF
22643 if { (ac_try="$ac_cpp conftest.$ac_ext"
22644 case "(($ac_try" in
22645   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22646   *) ac_try_echo=$ac_try;;
22647 esac
22648 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22649 $as_echo "$ac_try_echo") >&5
22650   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
22651   ac_status=$?
22652   grep -v '^ *+' conftest.er1 >conftest.err
22653   rm -f conftest.er1
22654   cat conftest.err >&5
22655   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22656   (exit $ac_status); } >/dev/null && {
22657          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22658          test ! -s conftest.err
22659        }; then
22660   ac_header_preproc=yes
22661 else
22662   $as_echo "$as_me: failed program was:" >&5
22663 sed 's/^/| /' conftest.$ac_ext >&5
22664
22665   ac_header_preproc=no
22666 fi
22667
22668 rm -f conftest.err conftest.$ac_ext
22669 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22670 $as_echo "$ac_header_preproc" >&6; }
22671
22672 # So?  What about this header?
22673 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22674   yes:no: )
22675     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
22676 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22677     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
22678 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
22679     ac_header_preproc=yes
22680     ;;
22681   no:yes:* )
22682     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
22683 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
22684     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
22685 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
22686     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
22687 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
22688     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
22689 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22690     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
22691 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
22692     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
22693 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
22694     ( cat <<\_ASBOX
22695 ## ---------------------------------------- ##
22696 ## Report this to pgsql-bugs@postgresql.org ##
22697 ## ---------------------------------------- ##
22698 _ASBOX
22699      ) | sed "s/^/$as_me: WARNING:     /" >&2
22700     ;;
22701 esac
22702 { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
22703 $as_echo_n "checking for pthread.h... " >&6; }
22704 if test "${ac_cv_header_pthread_h+set}" = set; then
22705   $as_echo_n "(cached) " >&6
22706 else
22707   ac_cv_header_pthread_h=$ac_header_preproc
22708 fi
22709 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
22710 $as_echo "$ac_cv_header_pthread_h" >&6; }
22711
22712 fi
22713 if test "x$ac_cv_header_pthread_h" = x""yes; then
22714   :
22715 else
22716   { { $as_echo "$as_me:$LINENO: error:
22717 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
22718 $as_echo "$as_me: error:
22719 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
22720    { (exit 1); exit 1; }; }
22721 fi
22722
22723
22724 fi
22725
22726
22727
22728
22729 for ac_func in strerror_r getpwuid_r gethostbyname_r
22730 do
22731 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22732 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22733 $as_echo_n "checking for $ac_func... " >&6; }
22734 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22735   $as_echo_n "(cached) " >&6
22736 else
22737   cat >conftest.$ac_ext <<_ACEOF
22738 /* confdefs.h.  */
22739 _ACEOF
22740 cat confdefs.h >>conftest.$ac_ext
22741 cat >>conftest.$ac_ext <<_ACEOF
22742 /* end confdefs.h.  */
22743 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22744    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22745 #define $ac_func innocuous_$ac_func
22746
22747 /* System header to define __stub macros and hopefully few prototypes,
22748     which can conflict with char $ac_func (); below.
22749     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22750     <limits.h> exists even on freestanding compilers.  */
22751
22752 #ifdef __STDC__
22753 # include <limits.h>
22754 #else
22755 # include <assert.h>
22756 #endif
22757
22758 #undef $ac_func
22759
22760 /* Override any GCC internal prototype to avoid an error.
22761    Use char because int might match the return type of a GCC
22762    builtin and then its argument prototype would still apply.  */
22763 #ifdef __cplusplus
22764 extern "C"
22765 #endif
22766 char $ac_func ();
22767 /* The GNU C library defines this for functions which it implements
22768     to always fail with ENOSYS.  Some functions are actually named
22769     something starting with __ and the normal name is an alias.  */
22770 #if defined __stub_$ac_func || defined __stub___$ac_func
22771 choke me
22772 #endif
22773
22774 int
22775 main ()
22776 {
22777 return $ac_func ();
22778   ;
22779   return 0;
22780 }
22781 _ACEOF
22782 rm -f conftest.$ac_objext conftest$ac_exeext
22783 if { (ac_try="$ac_link"
22784 case "(($ac_try" in
22785   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22786   *) ac_try_echo=$ac_try;;
22787 esac
22788 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22789 $as_echo "$ac_try_echo") >&5
22790   (eval "$ac_link") 2>conftest.er1
22791   ac_status=$?
22792   grep -v '^ *+' conftest.er1 >conftest.err
22793   rm -f conftest.er1
22794   cat conftest.err >&5
22795   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22796   (exit $ac_status); } && {
22797          test -z "$ac_c_werror_flag" ||
22798          test ! -s conftest.err
22799        } && test -s conftest$ac_exeext && {
22800          test "$cross_compiling" = yes ||
22801          $as_test_x conftest$ac_exeext
22802        }; then
22803   eval "$as_ac_var=yes"
22804 else
22805   $as_echo "$as_me: failed program was:" >&5
22806 sed 's/^/| /' conftest.$ac_ext >&5
22807
22808         eval "$as_ac_var=no"
22809 fi
22810
22811 rm -rf conftest.dSYM
22812 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22813       conftest$ac_exeext conftest.$ac_ext
22814 fi
22815 ac_res=`eval 'as_val=${'$as_ac_var'}
22816                  $as_echo "$as_val"'`
22817                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22818 $as_echo "$ac_res" >&6; }
22819 as_val=`eval 'as_val=${'$as_ac_var'}
22820                  $as_echo "$as_val"'`
22821    if test "x$as_val" = x""yes; then
22822   cat >>confdefs.h <<_ACEOF
22823 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22824 _ACEOF
22825
22826 fi
22827 done
22828
22829
22830 # Do test here with the proper thread flags
22831 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
22832 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
22833 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
22834   $as_echo_n "(cached) " >&6
22835 else
22836   cat >conftest.$ac_ext <<_ACEOF
22837 /* confdefs.h.  */
22838 _ACEOF
22839 cat confdefs.h >>conftest.$ac_ext
22840 cat >>conftest.$ac_ext <<_ACEOF
22841 /* end confdefs.h.  */
22842 #include <sys/types.h>
22843 #include <pwd.h>
22844 int
22845 main ()
22846 {
22847 uid_t uid;
22848 struct passwd *space;
22849 char *buf;
22850 size_t bufsize;
22851 struct passwd **result;
22852 getpwuid_r(uid, space, buf, bufsize, result);
22853   ;
22854   return 0;
22855 }
22856 _ACEOF
22857 rm -f conftest.$ac_objext
22858 if { (ac_try="$ac_compile"
22859 case "(($ac_try" in
22860   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22861   *) ac_try_echo=$ac_try;;
22862 esac
22863 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22864 $as_echo "$ac_try_echo") >&5
22865   (eval "$ac_compile") 2>conftest.er1
22866   ac_status=$?
22867   grep -v '^ *+' conftest.er1 >conftest.err
22868   rm -f conftest.er1
22869   cat conftest.err >&5
22870   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22871   (exit $ac_status); } && {
22872          test -z "$ac_c_werror_flag" ||
22873          test ! -s conftest.err
22874        } && test -s conftest.$ac_objext; then
22875   pgac_cv_func_getpwuid_r_5arg=yes
22876 else
22877   $as_echo "$as_me: failed program was:" >&5
22878 sed 's/^/| /' conftest.$ac_ext >&5
22879
22880         pgac_cv_func_getpwuid_r_5arg=no
22881 fi
22882
22883 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22884 fi
22885 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
22886 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
22887 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
22888
22889 cat >>confdefs.h <<\_ACEOF
22890 #define GETPWUID_R_5ARG /**/
22891 _ACEOF
22892
22893 fi
22894
22895 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
22896 $as_echo_n "checking whether strerror_r returns int... " >&6; }
22897 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
22898   $as_echo_n "(cached) " >&6
22899 else
22900   cat >conftest.$ac_ext <<_ACEOF
22901 /* confdefs.h.  */
22902 _ACEOF
22903 cat confdefs.h >>conftest.$ac_ext
22904 cat >>conftest.$ac_ext <<_ACEOF
22905 /* end confdefs.h.  */
22906 #include <string.h>
22907 int
22908 main ()
22909 {
22910 #ifndef _AIX
22911 int strerror_r(int, char *, size_t);
22912 #else
22913 /* Older AIX has 'int' for the third argument so we don't test the args. */
22914 int strerror_r();
22915 #endif
22916   ;
22917   return 0;
22918 }
22919 _ACEOF
22920 rm -f conftest.$ac_objext
22921 if { (ac_try="$ac_compile"
22922 case "(($ac_try" in
22923   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22924   *) ac_try_echo=$ac_try;;
22925 esac
22926 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22927 $as_echo "$ac_try_echo") >&5
22928   (eval "$ac_compile") 2>conftest.er1
22929   ac_status=$?
22930   grep -v '^ *+' conftest.er1 >conftest.err
22931   rm -f conftest.er1
22932   cat conftest.err >&5
22933   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22934   (exit $ac_status); } && {
22935          test -z "$ac_c_werror_flag" ||
22936          test ! -s conftest.err
22937        } && test -s conftest.$ac_objext; then
22938   pgac_cv_func_strerror_r_int=yes
22939 else
22940   $as_echo "$as_me: failed program was:" >&5
22941 sed 's/^/| /' conftest.$ac_ext >&5
22942
22943         pgac_cv_func_strerror_r_int=no
22944 fi
22945
22946 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22947 fi
22948 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
22949 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
22950 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
22951
22952 cat >>confdefs.h <<\_ACEOF
22953 #define STRERROR_R_INT /**/
22954 _ACEOF
22955
22956 fi
22957
22958
22959 CFLAGS="$_CFLAGS"
22960 LIBS="$_LIBS"
22961
22962 else
22963 # do not use values from template file
22964 PTHREAD_CFLAGS=
22965 PTHREAD_LIBS=
22966 fi
22967
22968
22969
22970
22971
22972 # We can test for libldap_r only after we know PTHREAD_LIBS
22973 if test "$with_ldap" = yes ; then
22974   _LIBS="$LIBS"
22975   if test "$PORTNAME" != "win32"; then
22976
22977 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
22978 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
22979 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
22980   $as_echo_n "(cached) " >&6
22981 else
22982   ac_check_lib_save_LIBS=$LIBS
22983 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
22984 cat >conftest.$ac_ext <<_ACEOF
22985 /* confdefs.h.  */
22986 _ACEOF
22987 cat confdefs.h >>conftest.$ac_ext
22988 cat >>conftest.$ac_ext <<_ACEOF
22989 /* end confdefs.h.  */
22990
22991 /* Override any GCC internal prototype to avoid an error.
22992    Use char because int might match the return type of a GCC
22993    builtin and then its argument prototype would still apply.  */
22994 #ifdef __cplusplus
22995 extern "C"
22996 #endif
22997 char ldap_bind ();
22998 int
22999 main ()
23000 {
23001 return ldap_bind ();
23002   ;
23003   return 0;
23004 }
23005 _ACEOF
23006 rm -f conftest.$ac_objext conftest$ac_exeext
23007 if { (ac_try="$ac_link"
23008 case "(($ac_try" in
23009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23010   *) ac_try_echo=$ac_try;;
23011 esac
23012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23013 $as_echo "$ac_try_echo") >&5
23014   (eval "$ac_link") 2>conftest.er1
23015   ac_status=$?
23016   grep -v '^ *+' conftest.er1 >conftest.err
23017   rm -f conftest.er1
23018   cat conftest.err >&5
23019   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23020   (exit $ac_status); } && {
23021          test -z "$ac_c_werror_flag" ||
23022          test ! -s conftest.err
23023        } && test -s conftest$ac_exeext && {
23024          test "$cross_compiling" = yes ||
23025          $as_test_x conftest$ac_exeext
23026        }; then
23027   ac_cv_lib_ldap_ldap_bind=yes
23028 else
23029   $as_echo "$as_me: failed program was:" >&5
23030 sed 's/^/| /' conftest.$ac_ext >&5
23031
23032         ac_cv_lib_ldap_ldap_bind=no
23033 fi
23034
23035 rm -rf conftest.dSYM
23036 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23037       conftest$ac_exeext conftest.$ac_ext
23038 LIBS=$ac_check_lib_save_LIBS
23039 fi
23040 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
23041 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
23042 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
23043   cat >>confdefs.h <<_ACEOF
23044 #define HAVE_LIBLDAP 1
23045 _ACEOF
23046
23047   LIBS="-lldap $LIBS"
23048
23049 else
23050   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
23051 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
23052    { (exit 1); exit 1; }; }
23053 fi
23054
23055     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
23056     if test "$enable_thread_safety" = yes; then
23057       # on some platforms ldap_r fails to link without PTHREAD_LIBS
23058
23059 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
23060 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
23061 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
23062   $as_echo_n "(cached) " >&6
23063 else
23064   ac_check_lib_save_LIBS=$LIBS
23065 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
23066 cat >conftest.$ac_ext <<_ACEOF
23067 /* confdefs.h.  */
23068 _ACEOF
23069 cat confdefs.h >>conftest.$ac_ext
23070 cat >>conftest.$ac_ext <<_ACEOF
23071 /* end confdefs.h.  */
23072
23073 /* Override any GCC internal prototype to avoid an error.
23074    Use char because int might match the return type of a GCC
23075    builtin and then its argument prototype would still apply.  */
23076 #ifdef __cplusplus
23077 extern "C"
23078 #endif
23079 char ldap_simple_bind ();
23080 int
23081 main ()
23082 {
23083 return ldap_simple_bind ();
23084   ;
23085   return 0;
23086 }
23087 _ACEOF
23088 rm -f conftest.$ac_objext conftest$ac_exeext
23089 if { (ac_try="$ac_link"
23090 case "(($ac_try" in
23091   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23092   *) ac_try_echo=$ac_try;;
23093 esac
23094 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23095 $as_echo "$ac_try_echo") >&5
23096   (eval "$ac_link") 2>conftest.er1
23097   ac_status=$?
23098   grep -v '^ *+' conftest.er1 >conftest.err
23099   rm -f conftest.er1
23100   cat conftest.err >&5
23101   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23102   (exit $ac_status); } && {
23103          test -z "$ac_c_werror_flag" ||
23104          test ! -s conftest.err
23105        } && test -s conftest$ac_exeext && {
23106          test "$cross_compiling" = yes ||
23107          $as_test_x conftest$ac_exeext
23108        }; then
23109   ac_cv_lib_ldap_r_ldap_simple_bind=yes
23110 else
23111   $as_echo "$as_me: failed program was:" >&5
23112 sed 's/^/| /' conftest.$ac_ext >&5
23113
23114         ac_cv_lib_ldap_r_ldap_simple_bind=no
23115 fi
23116
23117 rm -rf conftest.dSYM
23118 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23119       conftest$ac_exeext conftest.$ac_ext
23120 LIBS=$ac_check_lib_save_LIBS
23121 fi
23122 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
23123 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
23124 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
23125   cat >>confdefs.h <<_ACEOF
23126 #define HAVE_LIBLDAP_R 1
23127 _ACEOF
23128
23129   LIBS="-lldap_r $LIBS"
23130
23131 else
23132   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
23133 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
23134    { (exit 1); exit 1; }; }
23135 fi
23136
23137       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
23138     else
23139       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
23140     fi
23141   else
23142
23143 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
23144 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
23145 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
23146   $as_echo_n "(cached) " >&6
23147 else
23148   ac_check_lib_save_LIBS=$LIBS
23149 LIBS="-lwldap32  $LIBS"
23150 cat >conftest.$ac_ext <<_ACEOF
23151 /* confdefs.h.  */
23152 _ACEOF
23153 cat confdefs.h >>conftest.$ac_ext
23154 cat >>conftest.$ac_ext <<_ACEOF
23155 /* end confdefs.h.  */
23156
23157 /* Override any GCC internal prototype to avoid an error.
23158    Use char because int might match the return type of a GCC
23159    builtin and then its argument prototype would still apply.  */
23160 #ifdef __cplusplus
23161 extern "C"
23162 #endif
23163 char ldap_bind ();
23164 int
23165 main ()
23166 {
23167 return ldap_bind ();
23168   ;
23169   return 0;
23170 }
23171 _ACEOF
23172 rm -f conftest.$ac_objext conftest$ac_exeext
23173 if { (ac_try="$ac_link"
23174 case "(($ac_try" in
23175   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23176   *) ac_try_echo=$ac_try;;
23177 esac
23178 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23179 $as_echo "$ac_try_echo") >&5
23180   (eval "$ac_link") 2>conftest.er1
23181   ac_status=$?
23182   grep -v '^ *+' conftest.er1 >conftest.err
23183   rm -f conftest.er1
23184   cat conftest.err >&5
23185   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23186   (exit $ac_status); } && {
23187          test -z "$ac_c_werror_flag" ||
23188          test ! -s conftest.err
23189        } && test -s conftest$ac_exeext && {
23190          test "$cross_compiling" = yes ||
23191          $as_test_x conftest$ac_exeext
23192        }; then
23193   ac_cv_lib_wldap32_ldap_bind=yes
23194 else
23195   $as_echo "$as_me: failed program was:" >&5
23196 sed 's/^/| /' conftest.$ac_ext >&5
23197
23198         ac_cv_lib_wldap32_ldap_bind=no
23199 fi
23200
23201 rm -rf conftest.dSYM
23202 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23203       conftest$ac_exeext conftest.$ac_ext
23204 LIBS=$ac_check_lib_save_LIBS
23205 fi
23206 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
23207 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
23208 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
23209   cat >>confdefs.h <<_ACEOF
23210 #define HAVE_LIBWLDAP32 1
23211 _ACEOF
23212
23213   LIBS="-lwldap32 $LIBS"
23214
23215 else
23216   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
23217 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
23218    { (exit 1); exit 1; }; }
23219 fi
23220
23221     LDAP_LIBS_FE="-lwldap32"
23222     LDAP_LIBS_BE="-lwldap32"
23223   fi
23224   LIBS="$_LIBS"
23225 fi
23226
23227
23228
23229
23230 # This test makes sure that run tests work at all.  Sometimes a shared
23231 # library is found by the linker, but the runtime linker can't find it.
23232 # This check should come after all modifications of compiler or linker
23233 # variables, and before any other run tests.
23234 { $as_echo "$as_me:$LINENO: checking test program" >&5
23235 $as_echo_n "checking test program... " >&6; }
23236 if test "$cross_compiling" = yes; then
23237   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
23238 $as_echo "cross-compiling" >&6; }
23239 else
23240   cat >conftest.$ac_ext <<_ACEOF
23241 /* confdefs.h.  */
23242 _ACEOF
23243 cat confdefs.h >>conftest.$ac_ext
23244 cat >>conftest.$ac_ext <<_ACEOF
23245 /* end confdefs.h.  */
23246 int main() { return 0; }
23247 _ACEOF
23248 rm -f conftest$ac_exeext
23249 if { (ac_try="$ac_link"
23250 case "(($ac_try" in
23251   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23252   *) ac_try_echo=$ac_try;;
23253 esac
23254 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23255 $as_echo "$ac_try_echo") >&5
23256   (eval "$ac_link") 2>&5
23257   ac_status=$?
23258   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23259   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23260   { (case "(($ac_try" in
23261   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23262   *) ac_try_echo=$ac_try;;
23263 esac
23264 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23265 $as_echo "$ac_try_echo") >&5
23266   (eval "$ac_try") 2>&5
23267   ac_status=$?
23268   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23269   (exit $ac_status); }; }; then
23270   { $as_echo "$as_me:$LINENO: result: ok" >&5
23271 $as_echo "ok" >&6; }
23272 else
23273   $as_echo "$as_me: program exited with status $ac_status" >&5
23274 $as_echo "$as_me: failed program was:" >&5
23275 sed 's/^/| /' conftest.$ac_ext >&5
23276
23277 ( exit $ac_status )
23278 { $as_echo "$as_me:$LINENO: result: failed" >&5
23279 $as_echo "failed" >&6; }
23280 { { $as_echo "$as_me:$LINENO: error:
23281 Could not execute a simple test program.  This may be a problem
23282 related to locating shared libraries.  Check the file 'config.log'
23283 for the exact reason." >&5
23284 $as_echo "$as_me: error:
23285 Could not execute a simple test program.  This may be a problem
23286 related to locating shared libraries.  Check the file 'config.log'
23287 for the exact reason." >&2;}
23288    { (exit 1); exit 1; }; }
23289 fi
23290 rm -rf conftest.dSYM
23291 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23292 fi
23293
23294
23295
23296 # --------------------
23297 # Run tests below here
23298 # --------------------
23299
23300 # Force use of our snprintf if system's doesn't do arg control
23301 # See comment above at snprintf test for details.
23302 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
23303   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
23304 $as_echo_n "checking whether printf supports argument control... " >&6; }
23305 if test "${pgac_cv_printf_arg_control+set}" = set; then
23306   $as_echo_n "(cached) " >&6
23307 else
23308   if test "$cross_compiling" = yes; then
23309   pgac_cv_printf_arg_control=cross
23310 else
23311   cat >conftest.$ac_ext <<_ACEOF
23312 /* confdefs.h.  */
23313 _ACEOF
23314 cat confdefs.h >>conftest.$ac_ext
23315 cat >>conftest.$ac_ext <<_ACEOF
23316 /* end confdefs.h.  */
23317 #include <stdio.h>
23318 #include <string.h>
23319
23320 int main()
23321 {
23322   char buf[100];
23323
23324   /* can it swap arguments? */
23325   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
23326   if (strcmp(buf, "4 3") != 0)
23327     return 1;
23328   return 0;
23329 }
23330 _ACEOF
23331 rm -f conftest$ac_exeext
23332 if { (ac_try="$ac_link"
23333 case "(($ac_try" in
23334   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23335   *) ac_try_echo=$ac_try;;
23336 esac
23337 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23338 $as_echo "$ac_try_echo") >&5
23339   (eval "$ac_link") 2>&5
23340   ac_status=$?
23341   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23342   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23343   { (case "(($ac_try" in
23344   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23345   *) ac_try_echo=$ac_try;;
23346 esac
23347 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23348 $as_echo "$ac_try_echo") >&5
23349   (eval "$ac_try") 2>&5
23350   ac_status=$?
23351   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23352   (exit $ac_status); }; }; then
23353   pgac_cv_printf_arg_control=yes
23354 else
23355   $as_echo "$as_me: program exited with status $ac_status" >&5
23356 $as_echo "$as_me: failed program was:" >&5
23357 sed 's/^/| /' conftest.$ac_ext >&5
23358
23359 ( exit $ac_status )
23360 pgac_cv_printf_arg_control=no
23361 fi
23362 rm -rf conftest.dSYM
23363 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23364 fi
23365
23366
23367
23368 fi
23369 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
23370 $as_echo "$pgac_cv_printf_arg_control" >&6; }
23371
23372   if test $pgac_cv_printf_arg_control != yes ; then
23373     pgac_need_repl_snprintf=yes
23374   fi
23375 fi
23376
23377
23378
23379
23380 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
23381 $as_echo_n "checking whether long int is 64 bits... " >&6; }
23382 if test "${pgac_cv_type_long_int_64+set}" = set; then
23383   $as_echo_n "(cached) " >&6
23384 else
23385   if test "$cross_compiling" = yes; then
23386   # If cross-compiling, check the size reported by the compiler and
23387 # trust that the arithmetic works.
23388 cat >conftest.$ac_ext <<_ACEOF
23389 /* confdefs.h.  */
23390 _ACEOF
23391 cat confdefs.h >>conftest.$ac_ext
23392 cat >>conftest.$ac_ext <<_ACEOF
23393 /* end confdefs.h.  */
23394
23395 int
23396 main ()
23397 {
23398 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
23399 test_array [0] = 0
23400
23401   ;
23402   return 0;
23403 }
23404 _ACEOF
23405 rm -f conftest.$ac_objext
23406 if { (ac_try="$ac_compile"
23407 case "(($ac_try" in
23408   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23409   *) ac_try_echo=$ac_try;;
23410 esac
23411 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23412 $as_echo "$ac_try_echo") >&5
23413   (eval "$ac_compile") 2>conftest.er1
23414   ac_status=$?
23415   grep -v '^ *+' conftest.er1 >conftest.err
23416   rm -f conftest.er1
23417   cat conftest.err >&5
23418   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23419   (exit $ac_status); } && {
23420          test -z "$ac_c_werror_flag" ||
23421          test ! -s conftest.err
23422        } && test -s conftest.$ac_objext; then
23423   pgac_cv_type_long_int_64=yes
23424 else
23425   $as_echo "$as_me: failed program was:" >&5
23426 sed 's/^/| /' conftest.$ac_ext >&5
23427
23428         pgac_cv_type_long_int_64=no
23429 fi
23430
23431 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23432 else
23433   cat >conftest.$ac_ext <<_ACEOF
23434 /* confdefs.h.  */
23435 _ACEOF
23436 cat confdefs.h >>conftest.$ac_ext
23437 cat >>conftest.$ac_ext <<_ACEOF
23438 /* end confdefs.h.  */
23439 typedef long int ac_int64;
23440
23441 /*
23442  * These are globals to discourage the compiler from folding all the
23443  * arithmetic tests down to compile-time constants.
23444  */
23445 ac_int64 a = 20000001;
23446 ac_int64 b = 40000005;
23447
23448 int does_int64_work()
23449 {
23450   ac_int64 c,d;
23451
23452   if (sizeof(ac_int64) != 8)
23453     return 0;                   /* definitely not the right size */
23454
23455   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23456   c = a * b;
23457   d = (c + b) / b;
23458   if (d != a+1)
23459     return 0;
23460   return 1;
23461 }
23462 main() {
23463   exit(! does_int64_work());
23464 }
23465 _ACEOF
23466 rm -f conftest$ac_exeext
23467 if { (ac_try="$ac_link"
23468 case "(($ac_try" in
23469   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23470   *) ac_try_echo=$ac_try;;
23471 esac
23472 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23473 $as_echo "$ac_try_echo") >&5
23474   (eval "$ac_link") 2>&5
23475   ac_status=$?
23476   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23477   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23478   { (case "(($ac_try" in
23479   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23480   *) ac_try_echo=$ac_try;;
23481 esac
23482 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23483 $as_echo "$ac_try_echo") >&5
23484   (eval "$ac_try") 2>&5
23485   ac_status=$?
23486   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23487   (exit $ac_status); }; }; then
23488   pgac_cv_type_long_int_64=yes
23489 else
23490   $as_echo "$as_me: program exited with status $ac_status" >&5
23491 $as_echo "$as_me: failed program was:" >&5
23492 sed 's/^/| /' conftest.$ac_ext >&5
23493
23494 ( exit $ac_status )
23495 pgac_cv_type_long_int_64=no
23496 fi
23497 rm -rf conftest.dSYM
23498 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23499 fi
23500
23501
23502 fi
23503 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
23504 $as_echo "$pgac_cv_type_long_int_64" >&6; }
23505
23506 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
23507 if test x"$pgac_cv_type_long_int_64" = xyes ; then
23508
23509 cat >>confdefs.h <<\_ACEOF
23510 #define HAVE_LONG_INT_64 1
23511 _ACEOF
23512
23513 fi
23514
23515
23516 if test x"$HAVE_LONG_INT_64" = x"no" ; then
23517   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
23518 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
23519 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
23520   $as_echo_n "(cached) " >&6
23521 else
23522   if test "$cross_compiling" = yes; then
23523   # If cross-compiling, check the size reported by the compiler and
23524 # trust that the arithmetic works.
23525 cat >conftest.$ac_ext <<_ACEOF
23526 /* confdefs.h.  */
23527 _ACEOF
23528 cat confdefs.h >>conftest.$ac_ext
23529 cat >>conftest.$ac_ext <<_ACEOF
23530 /* end confdefs.h.  */
23531
23532 int
23533 main ()
23534 {
23535 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
23536 test_array [0] = 0
23537
23538   ;
23539   return 0;
23540 }
23541 _ACEOF
23542 rm -f conftest.$ac_objext
23543 if { (ac_try="$ac_compile"
23544 case "(($ac_try" in
23545   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23546   *) ac_try_echo=$ac_try;;
23547 esac
23548 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23549 $as_echo "$ac_try_echo") >&5
23550   (eval "$ac_compile") 2>conftest.er1
23551   ac_status=$?
23552   grep -v '^ *+' conftest.er1 >conftest.err
23553   rm -f conftest.er1
23554   cat conftest.err >&5
23555   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23556   (exit $ac_status); } && {
23557          test -z "$ac_c_werror_flag" ||
23558          test ! -s conftest.err
23559        } && test -s conftest.$ac_objext; then
23560   pgac_cv_type_long_long_int_64=yes
23561 else
23562   $as_echo "$as_me: failed program was:" >&5
23563 sed 's/^/| /' conftest.$ac_ext >&5
23564
23565         pgac_cv_type_long_long_int_64=no
23566 fi
23567
23568 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23569 else
23570   cat >conftest.$ac_ext <<_ACEOF
23571 /* confdefs.h.  */
23572 _ACEOF
23573 cat confdefs.h >>conftest.$ac_ext
23574 cat >>conftest.$ac_ext <<_ACEOF
23575 /* end confdefs.h.  */
23576 typedef long long int ac_int64;
23577
23578 /*
23579  * These are globals to discourage the compiler from folding all the
23580  * arithmetic tests down to compile-time constants.
23581  */
23582 ac_int64 a = 20000001;
23583 ac_int64 b = 40000005;
23584
23585 int does_int64_work()
23586 {
23587   ac_int64 c,d;
23588
23589   if (sizeof(ac_int64) != 8)
23590     return 0;                   /* definitely not the right size */
23591
23592   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23593   c = a * b;
23594   d = (c + b) / b;
23595   if (d != a+1)
23596     return 0;
23597   return 1;
23598 }
23599 main() {
23600   exit(! does_int64_work());
23601 }
23602 _ACEOF
23603 rm -f conftest$ac_exeext
23604 if { (ac_try="$ac_link"
23605 case "(($ac_try" in
23606   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23607   *) ac_try_echo=$ac_try;;
23608 esac
23609 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23610 $as_echo "$ac_try_echo") >&5
23611   (eval "$ac_link") 2>&5
23612   ac_status=$?
23613   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23614   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23615   { (case "(($ac_try" in
23616   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23617   *) ac_try_echo=$ac_try;;
23618 esac
23619 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23620 $as_echo "$ac_try_echo") >&5
23621   (eval "$ac_try") 2>&5
23622   ac_status=$?
23623   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23624   (exit $ac_status); }; }; then
23625   pgac_cv_type_long_long_int_64=yes
23626 else
23627   $as_echo "$as_me: program exited with status $ac_status" >&5
23628 $as_echo "$as_me: failed program was:" >&5
23629 sed 's/^/| /' conftest.$ac_ext >&5
23630
23631 ( exit $ac_status )
23632 pgac_cv_type_long_long_int_64=no
23633 fi
23634 rm -rf conftest.dSYM
23635 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23636 fi
23637
23638
23639 fi
23640 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
23641 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
23642
23643 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
23644 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
23645
23646 cat >>confdefs.h <<\_ACEOF
23647 #define HAVE_LONG_LONG_INT_64 1
23648 _ACEOF
23649
23650 fi
23651
23652   if test x"$HAVE_LONG_LONG_INT_64" = x"no" ; then
23653     { { $as_echo "$as_me:$LINENO: error: Cannot find a working 64-bit integer type." >&5
23654 $as_echo "$as_me: error: Cannot find a working 64-bit integer type." >&2;}
23655    { (exit 1); exit 1; }; }
23656   fi
23657 fi
23658
23659
23660
23661 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
23662   cat >conftest.$ac_ext <<_ACEOF
23663 /* confdefs.h.  */
23664 _ACEOF
23665 cat confdefs.h >>conftest.$ac_ext
23666 cat >>conftest.$ac_ext <<_ACEOF
23667 /* end confdefs.h.  */
23668
23669 #define INT64CONST(x)  x##LL
23670 long long int foo = INT64CONST(0x1234567890123456);
23671
23672 int
23673 main ()
23674 {
23675
23676   ;
23677   return 0;
23678 }
23679 _ACEOF
23680 rm -f conftest.$ac_objext
23681 if { (ac_try="$ac_compile"
23682 case "(($ac_try" in
23683   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23684   *) ac_try_echo=$ac_try;;
23685 esac
23686 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23687 $as_echo "$ac_try_echo") >&5
23688   (eval "$ac_compile") 2>conftest.er1
23689   ac_status=$?
23690   grep -v '^ *+' conftest.er1 >conftest.err
23691   rm -f conftest.er1
23692   cat conftest.err >&5
23693   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23694   (exit $ac_status); } && {
23695          test -z "$ac_c_werror_flag" ||
23696          test ! -s conftest.err
23697        } && test -s conftest.$ac_objext; then
23698
23699 cat >>confdefs.h <<\_ACEOF
23700 #define HAVE_LL_CONSTANTS 1
23701 _ACEOF
23702
23703 else
23704   $as_echo "$as_me: failed program was:" >&5
23705 sed 's/^/| /' conftest.$ac_ext >&5
23706
23707
23708 fi
23709
23710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23711 fi
23712
23713
23714 # If we found "long int" is 64 bits, assume snprintf handles it.  If
23715 # we found we need to use "long long int", better check.  We cope with
23716 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
23717 # work, fall back to our own snprintf emulation (which we know uses %lld).
23718
23719 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
23720   if test $pgac_need_repl_snprintf = no; then
23721     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
23722 $as_echo_n "checking snprintf format for long long int... " >&6; }
23723 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
23724   $as_echo_n "(cached) " >&6
23725 else
23726   for pgac_format in '%lld' '%qd' '%I64d'; do
23727 if test "$cross_compiling" = yes; then
23728   pgac_cv_snprintf_long_long_int_format=cross; break
23729 else
23730   cat >conftest.$ac_ext <<_ACEOF
23731 /* confdefs.h.  */
23732 _ACEOF
23733 cat confdefs.h >>conftest.$ac_ext
23734 cat >>conftest.$ac_ext <<_ACEOF
23735 /* end confdefs.h.  */
23736 #include <stdio.h>
23737 typedef long long int ac_int64;
23738 #define INT64_FORMAT "$pgac_format"
23739
23740 ac_int64 a = 20000001;
23741 ac_int64 b = 40000005;
23742
23743 int does_int64_snprintf_work()
23744 {
23745   ac_int64 c;
23746   char buf[100];
23747
23748   if (sizeof(ac_int64) != 8)
23749     return 0;                   /* doesn't look like the right size */
23750
23751   c = a * b;
23752   snprintf(buf, 100, INT64_FORMAT, c);
23753   if (strcmp(buf, "800000140000005") != 0)
23754     return 0;                   /* either multiply or snprintf is busted */
23755   return 1;
23756 }
23757 main() {
23758   exit(! does_int64_snprintf_work());
23759 }
23760 _ACEOF
23761 rm -f conftest$ac_exeext
23762 if { (ac_try="$ac_link"
23763 case "(($ac_try" in
23764   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23765   *) ac_try_echo=$ac_try;;
23766 esac
23767 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23768 $as_echo "$ac_try_echo") >&5
23769   (eval "$ac_link") 2>&5
23770   ac_status=$?
23771   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23772   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23773   { (case "(($ac_try" in
23774   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23775   *) ac_try_echo=$ac_try;;
23776 esac
23777 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23778 $as_echo "$ac_try_echo") >&5
23779   (eval "$ac_try") 2>&5
23780   ac_status=$?
23781   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23782   (exit $ac_status); }; }; then
23783   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
23784 else
23785   $as_echo "$as_me: program exited with status $ac_status" >&5
23786 $as_echo "$as_me: failed program was:" >&5
23787 sed 's/^/| /' conftest.$ac_ext >&5
23788
23789 fi
23790 rm -rf conftest.dSYM
23791 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23792 fi
23793
23794
23795 done
23796 fi
23797
23798 LONG_LONG_INT_FORMAT=''
23799
23800 case $pgac_cv_snprintf_long_long_int_format in
23801   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
23802 $as_echo "cannot test (not on host machine)" >&6; };;
23803   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
23804 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
23805          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
23806   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
23807 $as_echo "none" >&6; };;
23808 esac
23809     if test "$LONG_LONG_INT_FORMAT" = ""; then
23810       # Force usage of our own snprintf, since system snprintf is broken
23811       pgac_need_repl_snprintf=yes
23812       LONG_LONG_INT_FORMAT='%lld'
23813     fi
23814   else
23815     # Here if we previously decided we needed to use our own snprintf
23816     LONG_LONG_INT_FORMAT='%lld'
23817   fi
23818   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
23819   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
23820   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
23821 else
23822   # Here if we are not using 'long long int' at all
23823   INT64_FORMAT='"%ld"'
23824   UINT64_FORMAT='"%lu"'
23825 fi
23826
23827
23828 cat >>confdefs.h <<_ACEOF
23829 #define INT64_FORMAT $INT64_FORMAT
23830 _ACEOF
23831
23832
23833
23834 cat >>confdefs.h <<_ACEOF
23835 #define UINT64_FORMAT $UINT64_FORMAT
23836 _ACEOF
23837
23838
23839 # Now we have checked all the reasons to replace snprintf
23840 if test $pgac_need_repl_snprintf = yes; then
23841
23842 cat >>confdefs.h <<\_ACEOF
23843 #define USE_REPL_SNPRINTF 1
23844 _ACEOF
23845
23846   case " $LIBOBJS " in
23847   *" snprintf.$ac_objext "* ) ;;
23848   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
23849  ;;
23850 esac
23851
23852 fi
23853
23854 # Check size of void *, size_t (enables tweaks for > 32bit address space)
23855 # The cast to long int works around a bug in the HP C Compiler
23856 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23857 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23858 # This bug is HP SR number 8606223364.
23859 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
23860 $as_echo_n "checking size of void *... " >&6; }
23861 if test "${ac_cv_sizeof_void_p+set}" = set; then
23862   $as_echo_n "(cached) " >&6
23863 else
23864   if test "$cross_compiling" = yes; then
23865   # Depending upon the size, compute the lo and hi bounds.
23866 cat >conftest.$ac_ext <<_ACEOF
23867 /* confdefs.h.  */
23868 _ACEOF
23869 cat confdefs.h >>conftest.$ac_ext
23870 cat >>conftest.$ac_ext <<_ACEOF
23871 /* end confdefs.h.  */
23872 $ac_includes_default
23873 int
23874 main ()
23875 {
23876 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
23877 test_array [0] = 0
23878
23879   ;
23880   return 0;
23881 }
23882 _ACEOF
23883 rm -f conftest.$ac_objext
23884 if { (ac_try="$ac_compile"
23885 case "(($ac_try" in
23886   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23887   *) ac_try_echo=$ac_try;;
23888 esac
23889 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23890 $as_echo "$ac_try_echo") >&5
23891   (eval "$ac_compile") 2>conftest.er1
23892   ac_status=$?
23893   grep -v '^ *+' conftest.er1 >conftest.err
23894   rm -f conftest.er1
23895   cat conftest.err >&5
23896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23897   (exit $ac_status); } && {
23898          test -z "$ac_c_werror_flag" ||
23899          test ! -s conftest.err
23900        } && test -s conftest.$ac_objext; then
23901   ac_lo=0 ac_mid=0
23902   while :; do
23903     cat >conftest.$ac_ext <<_ACEOF
23904 /* confdefs.h.  */
23905 _ACEOF
23906 cat confdefs.h >>conftest.$ac_ext
23907 cat >>conftest.$ac_ext <<_ACEOF
23908 /* end confdefs.h.  */
23909 $ac_includes_default
23910 int
23911 main ()
23912 {
23913 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
23914 test_array [0] = 0
23915
23916   ;
23917   return 0;
23918 }
23919 _ACEOF
23920 rm -f conftest.$ac_objext
23921 if { (ac_try="$ac_compile"
23922 case "(($ac_try" in
23923   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23924   *) ac_try_echo=$ac_try;;
23925 esac
23926 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23927 $as_echo "$ac_try_echo") >&5
23928   (eval "$ac_compile") 2>conftest.er1
23929   ac_status=$?
23930   grep -v '^ *+' conftest.er1 >conftest.err
23931   rm -f conftest.er1
23932   cat conftest.err >&5
23933   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23934   (exit $ac_status); } && {
23935          test -z "$ac_c_werror_flag" ||
23936          test ! -s conftest.err
23937        } && test -s conftest.$ac_objext; then
23938   ac_hi=$ac_mid; break
23939 else
23940   $as_echo "$as_me: failed program was:" >&5
23941 sed 's/^/| /' conftest.$ac_ext >&5
23942
23943         ac_lo=`expr $ac_mid + 1`
23944                         if test $ac_lo -le $ac_mid; then
23945                           ac_lo= ac_hi=
23946                           break
23947                         fi
23948                         ac_mid=`expr 2 '*' $ac_mid + 1`
23949 fi
23950
23951 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23952   done
23953 else
23954   $as_echo "$as_me: failed program was:" >&5
23955 sed 's/^/| /' conftest.$ac_ext >&5
23956
23957         cat >conftest.$ac_ext <<_ACEOF
23958 /* confdefs.h.  */
23959 _ACEOF
23960 cat confdefs.h >>conftest.$ac_ext
23961 cat >>conftest.$ac_ext <<_ACEOF
23962 /* end confdefs.h.  */
23963 $ac_includes_default
23964 int
23965 main ()
23966 {
23967 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
23968 test_array [0] = 0
23969
23970   ;
23971   return 0;
23972 }
23973 _ACEOF
23974 rm -f conftest.$ac_objext
23975 if { (ac_try="$ac_compile"
23976 case "(($ac_try" in
23977   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23978   *) ac_try_echo=$ac_try;;
23979 esac
23980 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23981 $as_echo "$ac_try_echo") >&5
23982   (eval "$ac_compile") 2>conftest.er1
23983   ac_status=$?
23984   grep -v '^ *+' conftest.er1 >conftest.err
23985   rm -f conftest.er1
23986   cat conftest.err >&5
23987   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23988   (exit $ac_status); } && {
23989          test -z "$ac_c_werror_flag" ||
23990          test ! -s conftest.err
23991        } && test -s conftest.$ac_objext; then
23992   ac_hi=-1 ac_mid=-1
23993   while :; do
23994     cat >conftest.$ac_ext <<_ACEOF
23995 /* confdefs.h.  */
23996 _ACEOF
23997 cat confdefs.h >>conftest.$ac_ext
23998 cat >>conftest.$ac_ext <<_ACEOF
23999 /* end confdefs.h.  */
24000 $ac_includes_default
24001 int
24002 main ()
24003 {
24004 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
24005 test_array [0] = 0
24006
24007   ;
24008   return 0;
24009 }
24010 _ACEOF
24011 rm -f conftest.$ac_objext
24012 if { (ac_try="$ac_compile"
24013 case "(($ac_try" in
24014   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24015   *) ac_try_echo=$ac_try;;
24016 esac
24017 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24018 $as_echo "$ac_try_echo") >&5
24019   (eval "$ac_compile") 2>conftest.er1
24020   ac_status=$?
24021   grep -v '^ *+' conftest.er1 >conftest.err
24022   rm -f conftest.er1
24023   cat conftest.err >&5
24024   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24025   (exit $ac_status); } && {
24026          test -z "$ac_c_werror_flag" ||
24027          test ! -s conftest.err
24028        } && test -s conftest.$ac_objext; then
24029   ac_lo=$ac_mid; break
24030 else
24031   $as_echo "$as_me: failed program was:" >&5
24032 sed 's/^/| /' conftest.$ac_ext >&5
24033
24034         ac_hi=`expr '(' $ac_mid ')' - 1`
24035                         if test $ac_mid -le $ac_hi; then
24036                           ac_lo= ac_hi=
24037                           break
24038                         fi
24039                         ac_mid=`expr 2 '*' $ac_mid`
24040 fi
24041
24042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24043   done
24044 else
24045   $as_echo "$as_me: failed program was:" >&5
24046 sed 's/^/| /' conftest.$ac_ext >&5
24047
24048         ac_lo= ac_hi=
24049 fi
24050
24051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24052 fi
24053
24054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24055 # Binary search between lo and hi bounds.
24056 while test "x$ac_lo" != "x$ac_hi"; do
24057   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24058   cat >conftest.$ac_ext <<_ACEOF
24059 /* confdefs.h.  */
24060 _ACEOF
24061 cat confdefs.h >>conftest.$ac_ext
24062 cat >>conftest.$ac_ext <<_ACEOF
24063 /* end confdefs.h.  */
24064 $ac_includes_default
24065 int
24066 main ()
24067 {
24068 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24069 test_array [0] = 0
24070
24071   ;
24072   return 0;
24073 }
24074 _ACEOF
24075 rm -f conftest.$ac_objext
24076 if { (ac_try="$ac_compile"
24077 case "(($ac_try" in
24078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24079   *) ac_try_echo=$ac_try;;
24080 esac
24081 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24082 $as_echo "$ac_try_echo") >&5
24083   (eval "$ac_compile") 2>conftest.er1
24084   ac_status=$?
24085   grep -v '^ *+' conftest.er1 >conftest.err
24086   rm -f conftest.er1
24087   cat conftest.err >&5
24088   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24089   (exit $ac_status); } && {
24090          test -z "$ac_c_werror_flag" ||
24091          test ! -s conftest.err
24092        } && test -s conftest.$ac_objext; then
24093   ac_hi=$ac_mid
24094 else
24095   $as_echo "$as_me: failed program was:" >&5
24096 sed 's/^/| /' conftest.$ac_ext >&5
24097
24098         ac_lo=`expr '(' $ac_mid ')' + 1`
24099 fi
24100
24101 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24102 done
24103 case $ac_lo in
24104 ?*) ac_cv_sizeof_void_p=$ac_lo;;
24105 '') if test "$ac_cv_type_void_p" = yes; then
24106      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24107 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24108 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24109 See \`config.log' for more details." >&5
24110 $as_echo "$as_me: error: cannot compute sizeof (void *)
24111 See \`config.log' for more details." >&2;}
24112    { (exit 77); exit 77; }; }; }
24113    else
24114      ac_cv_sizeof_void_p=0
24115    fi ;;
24116 esac
24117 else
24118   cat >conftest.$ac_ext <<_ACEOF
24119 /* confdefs.h.  */
24120 _ACEOF
24121 cat confdefs.h >>conftest.$ac_ext
24122 cat >>conftest.$ac_ext <<_ACEOF
24123 /* end confdefs.h.  */
24124 $ac_includes_default
24125 static long int longval () { return (long int) (sizeof (void *)); }
24126 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
24127 #include <stdio.h>
24128 #include <stdlib.h>
24129 int
24130 main ()
24131 {
24132
24133   FILE *f = fopen ("conftest.val", "w");
24134   if (! f)
24135     return 1;
24136   if (((long int) (sizeof (void *))) < 0)
24137     {
24138       long int i = longval ();
24139       if (i != ((long int) (sizeof (void *))))
24140         return 1;
24141       fprintf (f, "%ld", i);
24142     }
24143   else
24144     {
24145       unsigned long int i = ulongval ();
24146       if (i != ((long int) (sizeof (void *))))
24147         return 1;
24148       fprintf (f, "%lu", i);
24149     }
24150   /* Do not output a trailing newline, as this causes \r\n confusion
24151      on some platforms.  */
24152   return ferror (f) || fclose (f) != 0;
24153
24154   ;
24155   return 0;
24156 }
24157 _ACEOF
24158 rm -f conftest$ac_exeext
24159 if { (ac_try="$ac_link"
24160 case "(($ac_try" in
24161   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24162   *) ac_try_echo=$ac_try;;
24163 esac
24164 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24165 $as_echo "$ac_try_echo") >&5
24166   (eval "$ac_link") 2>&5
24167   ac_status=$?
24168   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24169   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24170   { (case "(($ac_try" in
24171   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24172   *) ac_try_echo=$ac_try;;
24173 esac
24174 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24175 $as_echo "$ac_try_echo") >&5
24176   (eval "$ac_try") 2>&5
24177   ac_status=$?
24178   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24179   (exit $ac_status); }; }; then
24180   ac_cv_sizeof_void_p=`cat conftest.val`
24181 else
24182   $as_echo "$as_me: program exited with status $ac_status" >&5
24183 $as_echo "$as_me: failed program was:" >&5
24184 sed 's/^/| /' conftest.$ac_ext >&5
24185
24186 ( exit $ac_status )
24187 if test "$ac_cv_type_void_p" = yes; then
24188      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24189 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24190 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24191 See \`config.log' for more details." >&5
24192 $as_echo "$as_me: error: cannot compute sizeof (void *)
24193 See \`config.log' for more details." >&2;}
24194    { (exit 77); exit 77; }; }; }
24195    else
24196      ac_cv_sizeof_void_p=0
24197    fi
24198 fi
24199 rm -rf conftest.dSYM
24200 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24201 fi
24202 rm -f conftest.val
24203 fi
24204 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
24205 $as_echo "$ac_cv_sizeof_void_p" >&6; }
24206
24207
24208
24209 cat >>confdefs.h <<_ACEOF
24210 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
24211 _ACEOF
24212
24213
24214 # The cast to long int works around a bug in the HP C Compiler
24215 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24216 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24217 # This bug is HP SR number 8606223364.
24218 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
24219 $as_echo_n "checking size of size_t... " >&6; }
24220 if test "${ac_cv_sizeof_size_t+set}" = set; then
24221   $as_echo_n "(cached) " >&6
24222 else
24223   if test "$cross_compiling" = yes; then
24224   # Depending upon the size, compute the lo and hi bounds.
24225 cat >conftest.$ac_ext <<_ACEOF
24226 /* confdefs.h.  */
24227 _ACEOF
24228 cat confdefs.h >>conftest.$ac_ext
24229 cat >>conftest.$ac_ext <<_ACEOF
24230 /* end confdefs.h.  */
24231 $ac_includes_default
24232 int
24233 main ()
24234 {
24235 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
24236 test_array [0] = 0
24237
24238   ;
24239   return 0;
24240 }
24241 _ACEOF
24242 rm -f conftest.$ac_objext
24243 if { (ac_try="$ac_compile"
24244 case "(($ac_try" in
24245   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24246   *) ac_try_echo=$ac_try;;
24247 esac
24248 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24249 $as_echo "$ac_try_echo") >&5
24250   (eval "$ac_compile") 2>conftest.er1
24251   ac_status=$?
24252   grep -v '^ *+' conftest.er1 >conftest.err
24253   rm -f conftest.er1
24254   cat conftest.err >&5
24255   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24256   (exit $ac_status); } && {
24257          test -z "$ac_c_werror_flag" ||
24258          test ! -s conftest.err
24259        } && test -s conftest.$ac_objext; then
24260   ac_lo=0 ac_mid=0
24261   while :; do
24262     cat >conftest.$ac_ext <<_ACEOF
24263 /* confdefs.h.  */
24264 _ACEOF
24265 cat confdefs.h >>conftest.$ac_ext
24266 cat >>conftest.$ac_ext <<_ACEOF
24267 /* end confdefs.h.  */
24268 $ac_includes_default
24269 int
24270 main ()
24271 {
24272 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24273 test_array [0] = 0
24274
24275   ;
24276   return 0;
24277 }
24278 _ACEOF
24279 rm -f conftest.$ac_objext
24280 if { (ac_try="$ac_compile"
24281 case "(($ac_try" in
24282   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24283   *) ac_try_echo=$ac_try;;
24284 esac
24285 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24286 $as_echo "$ac_try_echo") >&5
24287   (eval "$ac_compile") 2>conftest.er1
24288   ac_status=$?
24289   grep -v '^ *+' conftest.er1 >conftest.err
24290   rm -f conftest.er1
24291   cat conftest.err >&5
24292   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24293   (exit $ac_status); } && {
24294          test -z "$ac_c_werror_flag" ||
24295          test ! -s conftest.err
24296        } && test -s conftest.$ac_objext; then
24297   ac_hi=$ac_mid; break
24298 else
24299   $as_echo "$as_me: failed program was:" >&5
24300 sed 's/^/| /' conftest.$ac_ext >&5
24301
24302         ac_lo=`expr $ac_mid + 1`
24303                         if test $ac_lo -le $ac_mid; then
24304                           ac_lo= ac_hi=
24305                           break
24306                         fi
24307                         ac_mid=`expr 2 '*' $ac_mid + 1`
24308 fi
24309
24310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24311   done
24312 else
24313   $as_echo "$as_me: failed program was:" >&5
24314 sed 's/^/| /' conftest.$ac_ext >&5
24315
24316         cat >conftest.$ac_ext <<_ACEOF
24317 /* confdefs.h.  */
24318 _ACEOF
24319 cat confdefs.h >>conftest.$ac_ext
24320 cat >>conftest.$ac_ext <<_ACEOF
24321 /* end confdefs.h.  */
24322 $ac_includes_default
24323 int
24324 main ()
24325 {
24326 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
24327 test_array [0] = 0
24328
24329   ;
24330   return 0;
24331 }
24332 _ACEOF
24333 rm -f conftest.$ac_objext
24334 if { (ac_try="$ac_compile"
24335 case "(($ac_try" in
24336   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24337   *) ac_try_echo=$ac_try;;
24338 esac
24339 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24340 $as_echo "$ac_try_echo") >&5
24341   (eval "$ac_compile") 2>conftest.er1
24342   ac_status=$?
24343   grep -v '^ *+' conftest.er1 >conftest.err
24344   rm -f conftest.er1
24345   cat conftest.err >&5
24346   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24347   (exit $ac_status); } && {
24348          test -z "$ac_c_werror_flag" ||
24349          test ! -s conftest.err
24350        } && test -s conftest.$ac_objext; then
24351   ac_hi=-1 ac_mid=-1
24352   while :; do
24353     cat >conftest.$ac_ext <<_ACEOF
24354 /* confdefs.h.  */
24355 _ACEOF
24356 cat confdefs.h >>conftest.$ac_ext
24357 cat >>conftest.$ac_ext <<_ACEOF
24358 /* end confdefs.h.  */
24359 $ac_includes_default
24360 int
24361 main ()
24362 {
24363 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
24364 test_array [0] = 0
24365
24366   ;
24367   return 0;
24368 }
24369 _ACEOF
24370 rm -f conftest.$ac_objext
24371 if { (ac_try="$ac_compile"
24372 case "(($ac_try" in
24373   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24374   *) ac_try_echo=$ac_try;;
24375 esac
24376 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24377 $as_echo "$ac_try_echo") >&5
24378   (eval "$ac_compile") 2>conftest.er1
24379   ac_status=$?
24380   grep -v '^ *+' conftest.er1 >conftest.err
24381   rm -f conftest.er1
24382   cat conftest.err >&5
24383   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24384   (exit $ac_status); } && {
24385          test -z "$ac_c_werror_flag" ||
24386          test ! -s conftest.err
24387        } && test -s conftest.$ac_objext; then
24388   ac_lo=$ac_mid; break
24389 else
24390   $as_echo "$as_me: failed program was:" >&5
24391 sed 's/^/| /' conftest.$ac_ext >&5
24392
24393         ac_hi=`expr '(' $ac_mid ')' - 1`
24394                         if test $ac_mid -le $ac_hi; then
24395                           ac_lo= ac_hi=
24396                           break
24397                         fi
24398                         ac_mid=`expr 2 '*' $ac_mid`
24399 fi
24400
24401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24402   done
24403 else
24404   $as_echo "$as_me: failed program was:" >&5
24405 sed 's/^/| /' conftest.$ac_ext >&5
24406
24407         ac_lo= ac_hi=
24408 fi
24409
24410 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24411 fi
24412
24413 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24414 # Binary search between lo and hi bounds.
24415 while test "x$ac_lo" != "x$ac_hi"; do
24416   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24417   cat >conftest.$ac_ext <<_ACEOF
24418 /* confdefs.h.  */
24419 _ACEOF
24420 cat confdefs.h >>conftest.$ac_ext
24421 cat >>conftest.$ac_ext <<_ACEOF
24422 /* end confdefs.h.  */
24423 $ac_includes_default
24424 int
24425 main ()
24426 {
24427 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24428 test_array [0] = 0
24429
24430   ;
24431   return 0;
24432 }
24433 _ACEOF
24434 rm -f conftest.$ac_objext
24435 if { (ac_try="$ac_compile"
24436 case "(($ac_try" in
24437   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24438   *) ac_try_echo=$ac_try;;
24439 esac
24440 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24441 $as_echo "$ac_try_echo") >&5
24442   (eval "$ac_compile") 2>conftest.er1
24443   ac_status=$?
24444   grep -v '^ *+' conftest.er1 >conftest.err
24445   rm -f conftest.er1
24446   cat conftest.err >&5
24447   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24448   (exit $ac_status); } && {
24449          test -z "$ac_c_werror_flag" ||
24450          test ! -s conftest.err
24451        } && test -s conftest.$ac_objext; then
24452   ac_hi=$ac_mid
24453 else
24454   $as_echo "$as_me: failed program was:" >&5
24455 sed 's/^/| /' conftest.$ac_ext >&5
24456
24457         ac_lo=`expr '(' $ac_mid ')' + 1`
24458 fi
24459
24460 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24461 done
24462 case $ac_lo in
24463 ?*) ac_cv_sizeof_size_t=$ac_lo;;
24464 '') if test "$ac_cv_type_size_t" = yes; then
24465      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24466 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24467 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24468 See \`config.log' for more details." >&5
24469 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24470 See \`config.log' for more details." >&2;}
24471    { (exit 77); exit 77; }; }; }
24472    else
24473      ac_cv_sizeof_size_t=0
24474    fi ;;
24475 esac
24476 else
24477   cat >conftest.$ac_ext <<_ACEOF
24478 /* confdefs.h.  */
24479 _ACEOF
24480 cat confdefs.h >>conftest.$ac_ext
24481 cat >>conftest.$ac_ext <<_ACEOF
24482 /* end confdefs.h.  */
24483 $ac_includes_default
24484 static long int longval () { return (long int) (sizeof (size_t)); }
24485 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
24486 #include <stdio.h>
24487 #include <stdlib.h>
24488 int
24489 main ()
24490 {
24491
24492   FILE *f = fopen ("conftest.val", "w");
24493   if (! f)
24494     return 1;
24495   if (((long int) (sizeof (size_t))) < 0)
24496     {
24497       long int i = longval ();
24498       if (i != ((long int) (sizeof (size_t))))
24499         return 1;
24500       fprintf (f, "%ld", i);
24501     }
24502   else
24503     {
24504       unsigned long int i = ulongval ();
24505       if (i != ((long int) (sizeof (size_t))))
24506         return 1;
24507       fprintf (f, "%lu", i);
24508     }
24509   /* Do not output a trailing newline, as this causes \r\n confusion
24510      on some platforms.  */
24511   return ferror (f) || fclose (f) != 0;
24512
24513   ;
24514   return 0;
24515 }
24516 _ACEOF
24517 rm -f conftest$ac_exeext
24518 if { (ac_try="$ac_link"
24519 case "(($ac_try" in
24520   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24521   *) ac_try_echo=$ac_try;;
24522 esac
24523 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24524 $as_echo "$ac_try_echo") >&5
24525   (eval "$ac_link") 2>&5
24526   ac_status=$?
24527   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24528   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24529   { (case "(($ac_try" in
24530   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24531   *) ac_try_echo=$ac_try;;
24532 esac
24533 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24534 $as_echo "$ac_try_echo") >&5
24535   (eval "$ac_try") 2>&5
24536   ac_status=$?
24537   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24538   (exit $ac_status); }; }; then
24539   ac_cv_sizeof_size_t=`cat conftest.val`
24540 else
24541   $as_echo "$as_me: program exited with status $ac_status" >&5
24542 $as_echo "$as_me: failed program was:" >&5
24543 sed 's/^/| /' conftest.$ac_ext >&5
24544
24545 ( exit $ac_status )
24546 if test "$ac_cv_type_size_t" = yes; then
24547      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24548 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24549 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24550 See \`config.log' for more details." >&5
24551 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24552 See \`config.log' for more details." >&2;}
24553    { (exit 77); exit 77; }; }; }
24554    else
24555      ac_cv_sizeof_size_t=0
24556    fi
24557 fi
24558 rm -rf conftest.dSYM
24559 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24560 fi
24561 rm -f conftest.val
24562 fi
24563 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
24564 $as_echo "$ac_cv_sizeof_size_t" >&6; }
24565
24566
24567
24568 cat >>confdefs.h <<_ACEOF
24569 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
24570 _ACEOF
24571
24572
24573 # The cast to long int works around a bug in the HP C Compiler
24574 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24575 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24576 # This bug is HP SR number 8606223364.
24577 { $as_echo "$as_me:$LINENO: checking size of long" >&5
24578 $as_echo_n "checking size of long... " >&6; }
24579 if test "${ac_cv_sizeof_long+set}" = set; then
24580   $as_echo_n "(cached) " >&6
24581 else
24582   if test "$cross_compiling" = yes; then
24583   # Depending upon the size, compute the lo and hi bounds.
24584 cat >conftest.$ac_ext <<_ACEOF
24585 /* confdefs.h.  */
24586 _ACEOF
24587 cat confdefs.h >>conftest.$ac_ext
24588 cat >>conftest.$ac_ext <<_ACEOF
24589 /* end confdefs.h.  */
24590 $ac_includes_default
24591 int
24592 main ()
24593 {
24594 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
24595 test_array [0] = 0
24596
24597   ;
24598   return 0;
24599 }
24600 _ACEOF
24601 rm -f conftest.$ac_objext
24602 if { (ac_try="$ac_compile"
24603 case "(($ac_try" in
24604   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24605   *) ac_try_echo=$ac_try;;
24606 esac
24607 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24608 $as_echo "$ac_try_echo") >&5
24609   (eval "$ac_compile") 2>conftest.er1
24610   ac_status=$?
24611   grep -v '^ *+' conftest.er1 >conftest.err
24612   rm -f conftest.er1
24613   cat conftest.err >&5
24614   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24615   (exit $ac_status); } && {
24616          test -z "$ac_c_werror_flag" ||
24617          test ! -s conftest.err
24618        } && test -s conftest.$ac_objext; then
24619   ac_lo=0 ac_mid=0
24620   while :; do
24621     cat >conftest.$ac_ext <<_ACEOF
24622 /* confdefs.h.  */
24623 _ACEOF
24624 cat confdefs.h >>conftest.$ac_ext
24625 cat >>conftest.$ac_ext <<_ACEOF
24626 /* end confdefs.h.  */
24627 $ac_includes_default
24628 int
24629 main ()
24630 {
24631 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
24632 test_array [0] = 0
24633
24634   ;
24635   return 0;
24636 }
24637 _ACEOF
24638 rm -f conftest.$ac_objext
24639 if { (ac_try="$ac_compile"
24640 case "(($ac_try" in
24641   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24642   *) ac_try_echo=$ac_try;;
24643 esac
24644 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24645 $as_echo "$ac_try_echo") >&5
24646   (eval "$ac_compile") 2>conftest.er1
24647   ac_status=$?
24648   grep -v '^ *+' conftest.er1 >conftest.err
24649   rm -f conftest.er1
24650   cat conftest.err >&5
24651   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24652   (exit $ac_status); } && {
24653          test -z "$ac_c_werror_flag" ||
24654          test ! -s conftest.err
24655        } && test -s conftest.$ac_objext; then
24656   ac_hi=$ac_mid; break
24657 else
24658   $as_echo "$as_me: failed program was:" >&5
24659 sed 's/^/| /' conftest.$ac_ext >&5
24660
24661         ac_lo=`expr $ac_mid + 1`
24662                         if test $ac_lo -le $ac_mid; then
24663                           ac_lo= ac_hi=
24664                           break
24665                         fi
24666                         ac_mid=`expr 2 '*' $ac_mid + 1`
24667 fi
24668
24669 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24670   done
24671 else
24672   $as_echo "$as_me: failed program was:" >&5
24673 sed 's/^/| /' conftest.$ac_ext >&5
24674
24675         cat >conftest.$ac_ext <<_ACEOF
24676 /* confdefs.h.  */
24677 _ACEOF
24678 cat confdefs.h >>conftest.$ac_ext
24679 cat >>conftest.$ac_ext <<_ACEOF
24680 /* end confdefs.h.  */
24681 $ac_includes_default
24682 int
24683 main ()
24684 {
24685 static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
24686 test_array [0] = 0
24687
24688   ;
24689   return 0;
24690 }
24691 _ACEOF
24692 rm -f conftest.$ac_objext
24693 if { (ac_try="$ac_compile"
24694 case "(($ac_try" in
24695   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24696   *) ac_try_echo=$ac_try;;
24697 esac
24698 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24699 $as_echo "$ac_try_echo") >&5
24700   (eval "$ac_compile") 2>conftest.er1
24701   ac_status=$?
24702   grep -v '^ *+' conftest.er1 >conftest.err
24703   rm -f conftest.er1
24704   cat conftest.err >&5
24705   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24706   (exit $ac_status); } && {
24707          test -z "$ac_c_werror_flag" ||
24708          test ! -s conftest.err
24709        } && test -s conftest.$ac_objext; then
24710   ac_hi=-1 ac_mid=-1
24711   while :; do
24712     cat >conftest.$ac_ext <<_ACEOF
24713 /* confdefs.h.  */
24714 _ACEOF
24715 cat confdefs.h >>conftest.$ac_ext
24716 cat >>conftest.$ac_ext <<_ACEOF
24717 /* end confdefs.h.  */
24718 $ac_includes_default
24719 int
24720 main ()
24721 {
24722 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
24723 test_array [0] = 0
24724
24725   ;
24726   return 0;
24727 }
24728 _ACEOF
24729 rm -f conftest.$ac_objext
24730 if { (ac_try="$ac_compile"
24731 case "(($ac_try" in
24732   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24733   *) ac_try_echo=$ac_try;;
24734 esac
24735 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24736 $as_echo "$ac_try_echo") >&5
24737   (eval "$ac_compile") 2>conftest.er1
24738   ac_status=$?
24739   grep -v '^ *+' conftest.er1 >conftest.err
24740   rm -f conftest.er1
24741   cat conftest.err >&5
24742   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24743   (exit $ac_status); } && {
24744          test -z "$ac_c_werror_flag" ||
24745          test ! -s conftest.err
24746        } && test -s conftest.$ac_objext; then
24747   ac_lo=$ac_mid; break
24748 else
24749   $as_echo "$as_me: failed program was:" >&5
24750 sed 's/^/| /' conftest.$ac_ext >&5
24751
24752         ac_hi=`expr '(' $ac_mid ')' - 1`
24753                         if test $ac_mid -le $ac_hi; then
24754                           ac_lo= ac_hi=
24755                           break
24756                         fi
24757                         ac_mid=`expr 2 '*' $ac_mid`
24758 fi
24759
24760 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24761   done
24762 else
24763   $as_echo "$as_me: failed program was:" >&5
24764 sed 's/^/| /' conftest.$ac_ext >&5
24765
24766         ac_lo= ac_hi=
24767 fi
24768
24769 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24770 fi
24771
24772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24773 # Binary search between lo and hi bounds.
24774 while test "x$ac_lo" != "x$ac_hi"; do
24775   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24776   cat >conftest.$ac_ext <<_ACEOF
24777 /* confdefs.h.  */
24778 _ACEOF
24779 cat confdefs.h >>conftest.$ac_ext
24780 cat >>conftest.$ac_ext <<_ACEOF
24781 /* end confdefs.h.  */
24782 $ac_includes_default
24783 int
24784 main ()
24785 {
24786 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
24787 test_array [0] = 0
24788
24789   ;
24790   return 0;
24791 }
24792 _ACEOF
24793 rm -f conftest.$ac_objext
24794 if { (ac_try="$ac_compile"
24795 case "(($ac_try" in
24796   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24797   *) ac_try_echo=$ac_try;;
24798 esac
24799 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24800 $as_echo "$ac_try_echo") >&5
24801   (eval "$ac_compile") 2>conftest.er1
24802   ac_status=$?
24803   grep -v '^ *+' conftest.er1 >conftest.err
24804   rm -f conftest.er1
24805   cat conftest.err >&5
24806   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24807   (exit $ac_status); } && {
24808          test -z "$ac_c_werror_flag" ||
24809          test ! -s conftest.err
24810        } && test -s conftest.$ac_objext; then
24811   ac_hi=$ac_mid
24812 else
24813   $as_echo "$as_me: failed program was:" >&5
24814 sed 's/^/| /' conftest.$ac_ext >&5
24815
24816         ac_lo=`expr '(' $ac_mid ')' + 1`
24817 fi
24818
24819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24820 done
24821 case $ac_lo in
24822 ?*) ac_cv_sizeof_long=$ac_lo;;
24823 '') if test "$ac_cv_type_long" = yes; then
24824      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24825 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24826 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
24827 See \`config.log' for more details." >&5
24828 $as_echo "$as_me: error: cannot compute sizeof (long)
24829 See \`config.log' for more details." >&2;}
24830    { (exit 77); exit 77; }; }; }
24831    else
24832      ac_cv_sizeof_long=0
24833    fi ;;
24834 esac
24835 else
24836   cat >conftest.$ac_ext <<_ACEOF
24837 /* confdefs.h.  */
24838 _ACEOF
24839 cat confdefs.h >>conftest.$ac_ext
24840 cat >>conftest.$ac_ext <<_ACEOF
24841 /* end confdefs.h.  */
24842 $ac_includes_default
24843 static long int longval () { return (long int) (sizeof (long)); }
24844 static unsigned long int ulongval () { return (long int) (sizeof (long)); }
24845 #include <stdio.h>
24846 #include <stdlib.h>
24847 int
24848 main ()
24849 {
24850
24851   FILE *f = fopen ("conftest.val", "w");
24852   if (! f)
24853     return 1;
24854   if (((long int) (sizeof (long))) < 0)
24855     {
24856       long int i = longval ();
24857       if (i != ((long int) (sizeof (long))))
24858         return 1;
24859       fprintf (f, "%ld", i);
24860     }
24861   else
24862     {
24863       unsigned long int i = ulongval ();
24864       if (i != ((long int) (sizeof (long))))
24865         return 1;
24866       fprintf (f, "%lu", i);
24867     }
24868   /* Do not output a trailing newline, as this causes \r\n confusion
24869      on some platforms.  */
24870   return ferror (f) || fclose (f) != 0;
24871
24872   ;
24873   return 0;
24874 }
24875 _ACEOF
24876 rm -f conftest$ac_exeext
24877 if { (ac_try="$ac_link"
24878 case "(($ac_try" in
24879   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24880   *) ac_try_echo=$ac_try;;
24881 esac
24882 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24883 $as_echo "$ac_try_echo") >&5
24884   (eval "$ac_link") 2>&5
24885   ac_status=$?
24886   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24887   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24888   { (case "(($ac_try" in
24889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24890   *) ac_try_echo=$ac_try;;
24891 esac
24892 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24893 $as_echo "$ac_try_echo") >&5
24894   (eval "$ac_try") 2>&5
24895   ac_status=$?
24896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24897   (exit $ac_status); }; }; then
24898   ac_cv_sizeof_long=`cat conftest.val`
24899 else
24900   $as_echo "$as_me: program exited with status $ac_status" >&5
24901 $as_echo "$as_me: failed program was:" >&5
24902 sed 's/^/| /' conftest.$ac_ext >&5
24903
24904 ( exit $ac_status )
24905 if test "$ac_cv_type_long" = yes; then
24906      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24907 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24908 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
24909 See \`config.log' for more details." >&5
24910 $as_echo "$as_me: error: cannot compute sizeof (long)
24911 See \`config.log' for more details." >&2;}
24912    { (exit 77); exit 77; }; }; }
24913    else
24914      ac_cv_sizeof_long=0
24915    fi
24916 fi
24917 rm -rf conftest.dSYM
24918 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24919 fi
24920 rm -f conftest.val
24921 fi
24922 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
24923 $as_echo "$ac_cv_sizeof_long" >&6; }
24924
24925
24926
24927 cat >>confdefs.h <<_ACEOF
24928 #define SIZEOF_LONG $ac_cv_sizeof_long
24929 _ACEOF
24930
24931
24932
24933 # Decide whether float4 is passed by value: user-selectable, enabled by default
24934 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
24935 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
24936
24937
24938 # Check whether --enable-float4-byval was given.
24939 if test "${enable_float4_byval+set}" = set; then
24940   enableval=$enable_float4_byval;
24941   case $enableval in
24942     yes)
24943
24944 cat >>confdefs.h <<\_ACEOF
24945 #define USE_FLOAT4_BYVAL 1
24946 _ACEOF
24947
24948                float4passbyval=true
24949       ;;
24950     no)
24951       float4passbyval=false
24952       ;;
24953     *)
24954       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
24955 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
24956    { (exit 1); exit 1; }; }
24957       ;;
24958   esac
24959
24960 else
24961   enable_float4_byval=yes
24962
24963 cat >>confdefs.h <<\_ACEOF
24964 #define USE_FLOAT4_BYVAL 1
24965 _ACEOF
24966
24967                float4passbyval=true
24968 fi
24969
24970
24971 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
24972 $as_echo "$enable_float4_byval" >&6; }
24973
24974 cat >>confdefs.h <<_ACEOF
24975 #define FLOAT4PASSBYVAL $float4passbyval
24976 _ACEOF
24977
24978
24979 # Decide whether float8 is passed by value.
24980 # Note: this setting also controls int8 and related types such as timestamp.
24981 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
24982 # If not, trying to select it is an error.
24983 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
24984 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
24985 if test $ac_cv_sizeof_void_p -ge 8 ; then
24986
24987
24988 # Check whether --enable-float8-byval was given.
24989 if test "${enable_float8_byval+set}" = set; then
24990   enableval=$enable_float8_byval;
24991   case $enableval in
24992     yes)
24993       :
24994       ;;
24995     no)
24996       :
24997       ;;
24998     *)
24999       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25000 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25001    { (exit 1); exit 1; }; }
25002       ;;
25003   esac
25004
25005 else
25006   enable_float8_byval=yes
25007
25008 fi
25009
25010
25011 else
25012
25013
25014 # Check whether --enable-float8-byval was given.
25015 if test "${enable_float8_byval+set}" = set; then
25016   enableval=$enable_float8_byval;
25017   case $enableval in
25018     yes)
25019       :
25020       ;;
25021     no)
25022       :
25023       ;;
25024     *)
25025       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25026 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25027    { (exit 1); exit 1; }; }
25028       ;;
25029   esac
25030
25031 else
25032   enable_float8_byval=no
25033
25034 fi
25035
25036
25037   if test "$enable_float8_byval" = yes ; then
25038     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
25039 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
25040    { (exit 1); exit 1; }; }
25041   fi
25042 fi
25043 if test "$enable_float8_byval" = yes ; then
25044
25045 cat >>confdefs.h <<\_ACEOF
25046 #define USE_FLOAT8_BYVAL 1
25047 _ACEOF
25048
25049   float8passbyval=true
25050 else
25051   float8passbyval=false
25052 fi
25053 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
25054 $as_echo "$enable_float8_byval" >&6; }
25055
25056 cat >>confdefs.h <<_ACEOF
25057 #define FLOAT8PASSBYVAL $float8passbyval
25058 _ACEOF
25059
25060
25061 # Determine memory alignment requirements for the basic C data types.
25062
25063 # The cast to long int works around a bug in the HP C Compiler,
25064 # see AC_CHECK_SIZEOF for more information.
25065 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
25066 $as_echo_n "checking alignment of short... " >&6; }
25067 if test "${ac_cv_alignof_short+set}" = set; then
25068   $as_echo_n "(cached) " >&6
25069 else
25070   if test "$cross_compiling" = yes; then
25071   # Depending upon the size, compute the lo and hi bounds.
25072 cat >conftest.$ac_ext <<_ACEOF
25073 /* confdefs.h.  */
25074 _ACEOF
25075 cat confdefs.h >>conftest.$ac_ext
25076 cat >>conftest.$ac_ext <<_ACEOF
25077 /* end confdefs.h.  */
25078 $ac_includes_default
25079 #ifndef offsetof
25080 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25081 #endif
25082 typedef struct { char x; short y; } ac__type_alignof_;
25083 int
25084 main ()
25085 {
25086 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25087 test_array [0] = 0
25088
25089   ;
25090   return 0;
25091 }
25092 _ACEOF
25093 rm -f conftest.$ac_objext
25094 if { (ac_try="$ac_compile"
25095 case "(($ac_try" in
25096   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25097   *) ac_try_echo=$ac_try;;
25098 esac
25099 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25100 $as_echo "$ac_try_echo") >&5
25101   (eval "$ac_compile") 2>conftest.er1
25102   ac_status=$?
25103   grep -v '^ *+' conftest.er1 >conftest.err
25104   rm -f conftest.er1
25105   cat conftest.err >&5
25106   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25107   (exit $ac_status); } && {
25108          test -z "$ac_c_werror_flag" ||
25109          test ! -s conftest.err
25110        } && test -s conftest.$ac_objext; then
25111   ac_lo=0 ac_mid=0
25112   while :; do
25113     cat >conftest.$ac_ext <<_ACEOF
25114 /* confdefs.h.  */
25115 _ACEOF
25116 cat confdefs.h >>conftest.$ac_ext
25117 cat >>conftest.$ac_ext <<_ACEOF
25118 /* end confdefs.h.  */
25119 $ac_includes_default
25120 #ifndef offsetof
25121 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25122 #endif
25123 typedef struct { char x; short y; } ac__type_alignof_;
25124 int
25125 main ()
25126 {
25127 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25128 test_array [0] = 0
25129
25130   ;
25131   return 0;
25132 }
25133 _ACEOF
25134 rm -f conftest.$ac_objext
25135 if { (ac_try="$ac_compile"
25136 case "(($ac_try" in
25137   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25138   *) ac_try_echo=$ac_try;;
25139 esac
25140 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25141 $as_echo "$ac_try_echo") >&5
25142   (eval "$ac_compile") 2>conftest.er1
25143   ac_status=$?
25144   grep -v '^ *+' conftest.er1 >conftest.err
25145   rm -f conftest.er1
25146   cat conftest.err >&5
25147   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25148   (exit $ac_status); } && {
25149          test -z "$ac_c_werror_flag" ||
25150          test ! -s conftest.err
25151        } && test -s conftest.$ac_objext; then
25152   ac_hi=$ac_mid; break
25153 else
25154   $as_echo "$as_me: failed program was:" >&5
25155 sed 's/^/| /' conftest.$ac_ext >&5
25156
25157         ac_lo=`expr $ac_mid + 1`
25158                         if test $ac_lo -le $ac_mid; then
25159                           ac_lo= ac_hi=
25160                           break
25161                         fi
25162                         ac_mid=`expr 2 '*' $ac_mid + 1`
25163 fi
25164
25165 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25166   done
25167 else
25168   $as_echo "$as_me: failed program was:" >&5
25169 sed 's/^/| /' conftest.$ac_ext >&5
25170
25171         cat >conftest.$ac_ext <<_ACEOF
25172 /* confdefs.h.  */
25173 _ACEOF
25174 cat confdefs.h >>conftest.$ac_ext
25175 cat >>conftest.$ac_ext <<_ACEOF
25176 /* end confdefs.h.  */
25177 $ac_includes_default
25178 #ifndef offsetof
25179 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25180 #endif
25181 typedef struct { char x; short y; } ac__type_alignof_;
25182 int
25183 main ()
25184 {
25185 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25186 test_array [0] = 0
25187
25188   ;
25189   return 0;
25190 }
25191 _ACEOF
25192 rm -f conftest.$ac_objext
25193 if { (ac_try="$ac_compile"
25194 case "(($ac_try" in
25195   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25196   *) ac_try_echo=$ac_try;;
25197 esac
25198 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25199 $as_echo "$ac_try_echo") >&5
25200   (eval "$ac_compile") 2>conftest.er1
25201   ac_status=$?
25202   grep -v '^ *+' conftest.er1 >conftest.err
25203   rm -f conftest.er1
25204   cat conftest.err >&5
25205   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25206   (exit $ac_status); } && {
25207          test -z "$ac_c_werror_flag" ||
25208          test ! -s conftest.err
25209        } && test -s conftest.$ac_objext; then
25210   ac_hi=-1 ac_mid=-1
25211   while :; do
25212     cat >conftest.$ac_ext <<_ACEOF
25213 /* confdefs.h.  */
25214 _ACEOF
25215 cat confdefs.h >>conftest.$ac_ext
25216 cat >>conftest.$ac_ext <<_ACEOF
25217 /* end confdefs.h.  */
25218 $ac_includes_default
25219 #ifndef offsetof
25220 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25221 #endif
25222 typedef struct { char x; short y; } ac__type_alignof_;
25223 int
25224 main ()
25225 {
25226 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25227 test_array [0] = 0
25228
25229   ;
25230   return 0;
25231 }
25232 _ACEOF
25233 rm -f conftest.$ac_objext
25234 if { (ac_try="$ac_compile"
25235 case "(($ac_try" in
25236   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25237   *) ac_try_echo=$ac_try;;
25238 esac
25239 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25240 $as_echo "$ac_try_echo") >&5
25241   (eval "$ac_compile") 2>conftest.er1
25242   ac_status=$?
25243   grep -v '^ *+' conftest.er1 >conftest.err
25244   rm -f conftest.er1
25245   cat conftest.err >&5
25246   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25247   (exit $ac_status); } && {
25248          test -z "$ac_c_werror_flag" ||
25249          test ! -s conftest.err
25250        } && test -s conftest.$ac_objext; then
25251   ac_lo=$ac_mid; break
25252 else
25253   $as_echo "$as_me: failed program was:" >&5
25254 sed 's/^/| /' conftest.$ac_ext >&5
25255
25256         ac_hi=`expr '(' $ac_mid ')' - 1`
25257                         if test $ac_mid -le $ac_hi; then
25258                           ac_lo= ac_hi=
25259                           break
25260                         fi
25261                         ac_mid=`expr 2 '*' $ac_mid`
25262 fi
25263
25264 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25265   done
25266 else
25267   $as_echo "$as_me: failed program was:" >&5
25268 sed 's/^/| /' conftest.$ac_ext >&5
25269
25270         ac_lo= ac_hi=
25271 fi
25272
25273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25274 fi
25275
25276 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25277 # Binary search between lo and hi bounds.
25278 while test "x$ac_lo" != "x$ac_hi"; do
25279   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25280   cat >conftest.$ac_ext <<_ACEOF
25281 /* confdefs.h.  */
25282 _ACEOF
25283 cat confdefs.h >>conftest.$ac_ext
25284 cat >>conftest.$ac_ext <<_ACEOF
25285 /* end confdefs.h.  */
25286 $ac_includes_default
25287 #ifndef offsetof
25288 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25289 #endif
25290 typedef struct { char x; short y; } ac__type_alignof_;
25291 int
25292 main ()
25293 {
25294 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25295 test_array [0] = 0
25296
25297   ;
25298   return 0;
25299 }
25300 _ACEOF
25301 rm -f conftest.$ac_objext
25302 if { (ac_try="$ac_compile"
25303 case "(($ac_try" in
25304   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25305   *) ac_try_echo=$ac_try;;
25306 esac
25307 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25308 $as_echo "$ac_try_echo") >&5
25309   (eval "$ac_compile") 2>conftest.er1
25310   ac_status=$?
25311   grep -v '^ *+' conftest.er1 >conftest.err
25312   rm -f conftest.er1
25313   cat conftest.err >&5
25314   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25315   (exit $ac_status); } && {
25316          test -z "$ac_c_werror_flag" ||
25317          test ! -s conftest.err
25318        } && test -s conftest.$ac_objext; then
25319   ac_hi=$ac_mid
25320 else
25321   $as_echo "$as_me: failed program was:" >&5
25322 sed 's/^/| /' conftest.$ac_ext >&5
25323
25324         ac_lo=`expr '(' $ac_mid ')' + 1`
25325 fi
25326
25327 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25328 done
25329 case $ac_lo in
25330 ?*) ac_cv_alignof_short=$ac_lo;;
25331 '') if test "$ac_cv_type_short" = yes; then
25332      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25333 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25334 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25335 See \`config.log' for more details." >&5
25336 $as_echo "$as_me: error: cannot compute alignment of short
25337 See \`config.log' for more details." >&2;}
25338    { (exit 77); exit 77; }; }; }
25339    else
25340      ac_cv_alignof_short=0
25341    fi ;;
25342 esac
25343 else
25344   cat >conftest.$ac_ext <<_ACEOF
25345 /* confdefs.h.  */
25346 _ACEOF
25347 cat confdefs.h >>conftest.$ac_ext
25348 cat >>conftest.$ac_ext <<_ACEOF
25349 /* end confdefs.h.  */
25350 $ac_includes_default
25351 #ifndef offsetof
25352 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25353 #endif
25354 typedef struct { char x; short y; } ac__type_alignof_;
25355 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25356 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25357 #include <stdio.h>
25358 #include <stdlib.h>
25359 int
25360 main ()
25361 {
25362
25363   FILE *f = fopen ("conftest.val", "w");
25364   if (! f)
25365     return 1;
25366   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25367     {
25368       long int i = longval ();
25369       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25370         return 1;
25371       fprintf (f, "%ld", i);
25372     }
25373   else
25374     {
25375       unsigned long int i = ulongval ();
25376       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25377         return 1;
25378       fprintf (f, "%lu", i);
25379     }
25380   /* Do not output a trailing newline, as this causes \r\n confusion
25381      on some platforms.  */
25382   return ferror (f) || fclose (f) != 0;
25383
25384   ;
25385   return 0;
25386 }
25387 _ACEOF
25388 rm -f conftest$ac_exeext
25389 if { (ac_try="$ac_link"
25390 case "(($ac_try" in
25391   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25392   *) ac_try_echo=$ac_try;;
25393 esac
25394 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25395 $as_echo "$ac_try_echo") >&5
25396   (eval "$ac_link") 2>&5
25397   ac_status=$?
25398   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25399   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25400   { (case "(($ac_try" in
25401   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25402   *) ac_try_echo=$ac_try;;
25403 esac
25404 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25405 $as_echo "$ac_try_echo") >&5
25406   (eval "$ac_try") 2>&5
25407   ac_status=$?
25408   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25409   (exit $ac_status); }; }; then
25410   ac_cv_alignof_short=`cat conftest.val`
25411 else
25412   $as_echo "$as_me: program exited with status $ac_status" >&5
25413 $as_echo "$as_me: failed program was:" >&5
25414 sed 's/^/| /' conftest.$ac_ext >&5
25415
25416 ( exit $ac_status )
25417 if test "$ac_cv_type_short" = yes; then
25418      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25419 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25420 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25421 See \`config.log' for more details." >&5
25422 $as_echo "$as_me: error: cannot compute alignment of short
25423 See \`config.log' for more details." >&2;}
25424    { (exit 77); exit 77; }; }; }
25425    else
25426      ac_cv_alignof_short=0
25427    fi
25428 fi
25429 rm -rf conftest.dSYM
25430 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25431 fi
25432 rm -f conftest.val
25433 fi
25434 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
25435 $as_echo "$ac_cv_alignof_short" >&6; }
25436
25437
25438
25439 cat >>confdefs.h <<_ACEOF
25440 #define ALIGNOF_SHORT $ac_cv_alignof_short
25441 _ACEOF
25442
25443
25444 # The cast to long int works around a bug in the HP C Compiler,
25445 # see AC_CHECK_SIZEOF for more information.
25446 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
25447 $as_echo_n "checking alignment of int... " >&6; }
25448 if test "${ac_cv_alignof_int+set}" = set; then
25449   $as_echo_n "(cached) " >&6
25450 else
25451   if test "$cross_compiling" = yes; then
25452   # Depending upon the size, compute the lo and hi bounds.
25453 cat >conftest.$ac_ext <<_ACEOF
25454 /* confdefs.h.  */
25455 _ACEOF
25456 cat confdefs.h >>conftest.$ac_ext
25457 cat >>conftest.$ac_ext <<_ACEOF
25458 /* end confdefs.h.  */
25459 $ac_includes_default
25460 #ifndef offsetof
25461 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25462 #endif
25463 typedef struct { char x; int y; } ac__type_alignof_;
25464 int
25465 main ()
25466 {
25467 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25468 test_array [0] = 0
25469
25470   ;
25471   return 0;
25472 }
25473 _ACEOF
25474 rm -f conftest.$ac_objext
25475 if { (ac_try="$ac_compile"
25476 case "(($ac_try" in
25477   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25478   *) ac_try_echo=$ac_try;;
25479 esac
25480 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25481 $as_echo "$ac_try_echo") >&5
25482   (eval "$ac_compile") 2>conftest.er1
25483   ac_status=$?
25484   grep -v '^ *+' conftest.er1 >conftest.err
25485   rm -f conftest.er1
25486   cat conftest.err >&5
25487   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25488   (exit $ac_status); } && {
25489          test -z "$ac_c_werror_flag" ||
25490          test ! -s conftest.err
25491        } && test -s conftest.$ac_objext; then
25492   ac_lo=0 ac_mid=0
25493   while :; do
25494     cat >conftest.$ac_ext <<_ACEOF
25495 /* confdefs.h.  */
25496 _ACEOF
25497 cat confdefs.h >>conftest.$ac_ext
25498 cat >>conftest.$ac_ext <<_ACEOF
25499 /* end confdefs.h.  */
25500 $ac_includes_default
25501 #ifndef offsetof
25502 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25503 #endif
25504 typedef struct { char x; int y; } ac__type_alignof_;
25505 int
25506 main ()
25507 {
25508 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25509 test_array [0] = 0
25510
25511   ;
25512   return 0;
25513 }
25514 _ACEOF
25515 rm -f conftest.$ac_objext
25516 if { (ac_try="$ac_compile"
25517 case "(($ac_try" in
25518   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25519   *) ac_try_echo=$ac_try;;
25520 esac
25521 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25522 $as_echo "$ac_try_echo") >&5
25523   (eval "$ac_compile") 2>conftest.er1
25524   ac_status=$?
25525   grep -v '^ *+' conftest.er1 >conftest.err
25526   rm -f conftest.er1
25527   cat conftest.err >&5
25528   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25529   (exit $ac_status); } && {
25530          test -z "$ac_c_werror_flag" ||
25531          test ! -s conftest.err
25532        } && test -s conftest.$ac_objext; then
25533   ac_hi=$ac_mid; break
25534 else
25535   $as_echo "$as_me: failed program was:" >&5
25536 sed 's/^/| /' conftest.$ac_ext >&5
25537
25538         ac_lo=`expr $ac_mid + 1`
25539                         if test $ac_lo -le $ac_mid; then
25540                           ac_lo= ac_hi=
25541                           break
25542                         fi
25543                         ac_mid=`expr 2 '*' $ac_mid + 1`
25544 fi
25545
25546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25547   done
25548 else
25549   $as_echo "$as_me: failed program was:" >&5
25550 sed 's/^/| /' conftest.$ac_ext >&5
25551
25552         cat >conftest.$ac_ext <<_ACEOF
25553 /* confdefs.h.  */
25554 _ACEOF
25555 cat confdefs.h >>conftest.$ac_ext
25556 cat >>conftest.$ac_ext <<_ACEOF
25557 /* end confdefs.h.  */
25558 $ac_includes_default
25559 #ifndef offsetof
25560 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25561 #endif
25562 typedef struct { char x; int y; } ac__type_alignof_;
25563 int
25564 main ()
25565 {
25566 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25567 test_array [0] = 0
25568
25569   ;
25570   return 0;
25571 }
25572 _ACEOF
25573 rm -f conftest.$ac_objext
25574 if { (ac_try="$ac_compile"
25575 case "(($ac_try" in
25576   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25577   *) ac_try_echo=$ac_try;;
25578 esac
25579 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25580 $as_echo "$ac_try_echo") >&5
25581   (eval "$ac_compile") 2>conftest.er1
25582   ac_status=$?
25583   grep -v '^ *+' conftest.er1 >conftest.err
25584   rm -f conftest.er1
25585   cat conftest.err >&5
25586   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25587   (exit $ac_status); } && {
25588          test -z "$ac_c_werror_flag" ||
25589          test ! -s conftest.err
25590        } && test -s conftest.$ac_objext; then
25591   ac_hi=-1 ac_mid=-1
25592   while :; do
25593     cat >conftest.$ac_ext <<_ACEOF
25594 /* confdefs.h.  */
25595 _ACEOF
25596 cat confdefs.h >>conftest.$ac_ext
25597 cat >>conftest.$ac_ext <<_ACEOF
25598 /* end confdefs.h.  */
25599 $ac_includes_default
25600 #ifndef offsetof
25601 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25602 #endif
25603 typedef struct { char x; int y; } ac__type_alignof_;
25604 int
25605 main ()
25606 {
25607 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25608 test_array [0] = 0
25609
25610   ;
25611   return 0;
25612 }
25613 _ACEOF
25614 rm -f conftest.$ac_objext
25615 if { (ac_try="$ac_compile"
25616 case "(($ac_try" in
25617   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25618   *) ac_try_echo=$ac_try;;
25619 esac
25620 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25621 $as_echo "$ac_try_echo") >&5
25622   (eval "$ac_compile") 2>conftest.er1
25623   ac_status=$?
25624   grep -v '^ *+' conftest.er1 >conftest.err
25625   rm -f conftest.er1
25626   cat conftest.err >&5
25627   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25628   (exit $ac_status); } && {
25629          test -z "$ac_c_werror_flag" ||
25630          test ! -s conftest.err
25631        } && test -s conftest.$ac_objext; then
25632   ac_lo=$ac_mid; break
25633 else
25634   $as_echo "$as_me: failed program was:" >&5
25635 sed 's/^/| /' conftest.$ac_ext >&5
25636
25637         ac_hi=`expr '(' $ac_mid ')' - 1`
25638                         if test $ac_mid -le $ac_hi; then
25639                           ac_lo= ac_hi=
25640                           break
25641                         fi
25642                         ac_mid=`expr 2 '*' $ac_mid`
25643 fi
25644
25645 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25646   done
25647 else
25648   $as_echo "$as_me: failed program was:" >&5
25649 sed 's/^/| /' conftest.$ac_ext >&5
25650
25651         ac_lo= ac_hi=
25652 fi
25653
25654 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25655 fi
25656
25657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25658 # Binary search between lo and hi bounds.
25659 while test "x$ac_lo" != "x$ac_hi"; do
25660   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25661   cat >conftest.$ac_ext <<_ACEOF
25662 /* confdefs.h.  */
25663 _ACEOF
25664 cat confdefs.h >>conftest.$ac_ext
25665 cat >>conftest.$ac_ext <<_ACEOF
25666 /* end confdefs.h.  */
25667 $ac_includes_default
25668 #ifndef offsetof
25669 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25670 #endif
25671 typedef struct { char x; int y; } ac__type_alignof_;
25672 int
25673 main ()
25674 {
25675 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25676 test_array [0] = 0
25677
25678   ;
25679   return 0;
25680 }
25681 _ACEOF
25682 rm -f conftest.$ac_objext
25683 if { (ac_try="$ac_compile"
25684 case "(($ac_try" in
25685   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25686   *) ac_try_echo=$ac_try;;
25687 esac
25688 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25689 $as_echo "$ac_try_echo") >&5
25690   (eval "$ac_compile") 2>conftest.er1
25691   ac_status=$?
25692   grep -v '^ *+' conftest.er1 >conftest.err
25693   rm -f conftest.er1
25694   cat conftest.err >&5
25695   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25696   (exit $ac_status); } && {
25697          test -z "$ac_c_werror_flag" ||
25698          test ! -s conftest.err
25699        } && test -s conftest.$ac_objext; then
25700   ac_hi=$ac_mid
25701 else
25702   $as_echo "$as_me: failed program was:" >&5
25703 sed 's/^/| /' conftest.$ac_ext >&5
25704
25705         ac_lo=`expr '(' $ac_mid ')' + 1`
25706 fi
25707
25708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25709 done
25710 case $ac_lo in
25711 ?*) ac_cv_alignof_int=$ac_lo;;
25712 '') if test "$ac_cv_type_int" = yes; then
25713      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25714 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25715 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
25716 See \`config.log' for more details." >&5
25717 $as_echo "$as_me: error: cannot compute alignment of int
25718 See \`config.log' for more details." >&2;}
25719    { (exit 77); exit 77; }; }; }
25720    else
25721      ac_cv_alignof_int=0
25722    fi ;;
25723 esac
25724 else
25725   cat >conftest.$ac_ext <<_ACEOF
25726 /* confdefs.h.  */
25727 _ACEOF
25728 cat confdefs.h >>conftest.$ac_ext
25729 cat >>conftest.$ac_ext <<_ACEOF
25730 /* end confdefs.h.  */
25731 $ac_includes_default
25732 #ifndef offsetof
25733 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25734 #endif
25735 typedef struct { char x; int y; } ac__type_alignof_;
25736 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25737 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25738 #include <stdio.h>
25739 #include <stdlib.h>
25740 int
25741 main ()
25742 {
25743
25744   FILE *f = fopen ("conftest.val", "w");
25745   if (! f)
25746     return 1;
25747   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25748     {
25749       long int i = longval ();
25750       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25751         return 1;
25752       fprintf (f, "%ld", i);
25753     }
25754   else
25755     {
25756       unsigned long int i = ulongval ();
25757       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25758         return 1;
25759       fprintf (f, "%lu", i);
25760     }
25761   /* Do not output a trailing newline, as this causes \r\n confusion
25762      on some platforms.  */
25763   return ferror (f) || fclose (f) != 0;
25764
25765   ;
25766   return 0;
25767 }
25768 _ACEOF
25769 rm -f conftest$ac_exeext
25770 if { (ac_try="$ac_link"
25771 case "(($ac_try" in
25772   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25773   *) ac_try_echo=$ac_try;;
25774 esac
25775 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25776 $as_echo "$ac_try_echo") >&5
25777   (eval "$ac_link") 2>&5
25778   ac_status=$?
25779   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25780   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25781   { (case "(($ac_try" in
25782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25783   *) ac_try_echo=$ac_try;;
25784 esac
25785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25786 $as_echo "$ac_try_echo") >&5
25787   (eval "$ac_try") 2>&5
25788   ac_status=$?
25789   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25790   (exit $ac_status); }; }; then
25791   ac_cv_alignof_int=`cat conftest.val`
25792 else
25793   $as_echo "$as_me: program exited with status $ac_status" >&5
25794 $as_echo "$as_me: failed program was:" >&5
25795 sed 's/^/| /' conftest.$ac_ext >&5
25796
25797 ( exit $ac_status )
25798 if test "$ac_cv_type_int" = yes; then
25799      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25800 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25801 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
25802 See \`config.log' for more details." >&5
25803 $as_echo "$as_me: error: cannot compute alignment of int
25804 See \`config.log' for more details." >&2;}
25805    { (exit 77); exit 77; }; }; }
25806    else
25807      ac_cv_alignof_int=0
25808    fi
25809 fi
25810 rm -rf conftest.dSYM
25811 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25812 fi
25813 rm -f conftest.val
25814 fi
25815 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
25816 $as_echo "$ac_cv_alignof_int" >&6; }
25817
25818
25819
25820 cat >>confdefs.h <<_ACEOF
25821 #define ALIGNOF_INT $ac_cv_alignof_int
25822 _ACEOF
25823
25824
25825 # The cast to long int works around a bug in the HP C Compiler,
25826 # see AC_CHECK_SIZEOF for more information.
25827 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
25828 $as_echo_n "checking alignment of long... " >&6; }
25829 if test "${ac_cv_alignof_long+set}" = set; then
25830   $as_echo_n "(cached) " >&6
25831 else
25832   if test "$cross_compiling" = yes; then
25833   # Depending upon the size, compute the lo and hi bounds.
25834 cat >conftest.$ac_ext <<_ACEOF
25835 /* confdefs.h.  */
25836 _ACEOF
25837 cat confdefs.h >>conftest.$ac_ext
25838 cat >>conftest.$ac_ext <<_ACEOF
25839 /* end confdefs.h.  */
25840 $ac_includes_default
25841 #ifndef offsetof
25842 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25843 #endif
25844 typedef struct { char x; long y; } ac__type_alignof_;
25845 int
25846 main ()
25847 {
25848 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25849 test_array [0] = 0
25850
25851   ;
25852   return 0;
25853 }
25854 _ACEOF
25855 rm -f conftest.$ac_objext
25856 if { (ac_try="$ac_compile"
25857 case "(($ac_try" in
25858   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25859   *) ac_try_echo=$ac_try;;
25860 esac
25861 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25862 $as_echo "$ac_try_echo") >&5
25863   (eval "$ac_compile") 2>conftest.er1
25864   ac_status=$?
25865   grep -v '^ *+' conftest.er1 >conftest.err
25866   rm -f conftest.er1
25867   cat conftest.err >&5
25868   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25869   (exit $ac_status); } && {
25870          test -z "$ac_c_werror_flag" ||
25871          test ! -s conftest.err
25872        } && test -s conftest.$ac_objext; then
25873   ac_lo=0 ac_mid=0
25874   while :; do
25875     cat >conftest.$ac_ext <<_ACEOF
25876 /* confdefs.h.  */
25877 _ACEOF
25878 cat confdefs.h >>conftest.$ac_ext
25879 cat >>conftest.$ac_ext <<_ACEOF
25880 /* end confdefs.h.  */
25881 $ac_includes_default
25882 #ifndef offsetof
25883 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25884 #endif
25885 typedef struct { char x; long y; } ac__type_alignof_;
25886 int
25887 main ()
25888 {
25889 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25890 test_array [0] = 0
25891
25892   ;
25893   return 0;
25894 }
25895 _ACEOF
25896 rm -f conftest.$ac_objext
25897 if { (ac_try="$ac_compile"
25898 case "(($ac_try" in
25899   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25900   *) ac_try_echo=$ac_try;;
25901 esac
25902 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25903 $as_echo "$ac_try_echo") >&5
25904   (eval "$ac_compile") 2>conftest.er1
25905   ac_status=$?
25906   grep -v '^ *+' conftest.er1 >conftest.err
25907   rm -f conftest.er1
25908   cat conftest.err >&5
25909   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25910   (exit $ac_status); } && {
25911          test -z "$ac_c_werror_flag" ||
25912          test ! -s conftest.err
25913        } && test -s conftest.$ac_objext; then
25914   ac_hi=$ac_mid; break
25915 else
25916   $as_echo "$as_me: failed program was:" >&5
25917 sed 's/^/| /' conftest.$ac_ext >&5
25918
25919         ac_lo=`expr $ac_mid + 1`
25920                         if test $ac_lo -le $ac_mid; then
25921                           ac_lo= ac_hi=
25922                           break
25923                         fi
25924                         ac_mid=`expr 2 '*' $ac_mid + 1`
25925 fi
25926
25927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25928   done
25929 else
25930   $as_echo "$as_me: failed program was:" >&5
25931 sed 's/^/| /' conftest.$ac_ext >&5
25932
25933         cat >conftest.$ac_ext <<_ACEOF
25934 /* confdefs.h.  */
25935 _ACEOF
25936 cat confdefs.h >>conftest.$ac_ext
25937 cat >>conftest.$ac_ext <<_ACEOF
25938 /* end confdefs.h.  */
25939 $ac_includes_default
25940 #ifndef offsetof
25941 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25942 #endif
25943 typedef struct { char x; long y; } ac__type_alignof_;
25944 int
25945 main ()
25946 {
25947 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25948 test_array [0] = 0
25949
25950   ;
25951   return 0;
25952 }
25953 _ACEOF
25954 rm -f conftest.$ac_objext
25955 if { (ac_try="$ac_compile"
25956 case "(($ac_try" in
25957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25958   *) ac_try_echo=$ac_try;;
25959 esac
25960 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25961 $as_echo "$ac_try_echo") >&5
25962   (eval "$ac_compile") 2>conftest.er1
25963   ac_status=$?
25964   grep -v '^ *+' conftest.er1 >conftest.err
25965   rm -f conftest.er1
25966   cat conftest.err >&5
25967   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25968   (exit $ac_status); } && {
25969          test -z "$ac_c_werror_flag" ||
25970          test ! -s conftest.err
25971        } && test -s conftest.$ac_objext; then
25972   ac_hi=-1 ac_mid=-1
25973   while :; do
25974     cat >conftest.$ac_ext <<_ACEOF
25975 /* confdefs.h.  */
25976 _ACEOF
25977 cat confdefs.h >>conftest.$ac_ext
25978 cat >>conftest.$ac_ext <<_ACEOF
25979 /* end confdefs.h.  */
25980 $ac_includes_default
25981 #ifndef offsetof
25982 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25983 #endif
25984 typedef struct { char x; long y; } ac__type_alignof_;
25985 int
25986 main ()
25987 {
25988 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25989 test_array [0] = 0
25990
25991   ;
25992   return 0;
25993 }
25994 _ACEOF
25995 rm -f conftest.$ac_objext
25996 if { (ac_try="$ac_compile"
25997 case "(($ac_try" in
25998   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25999   *) ac_try_echo=$ac_try;;
26000 esac
26001 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26002 $as_echo "$ac_try_echo") >&5
26003   (eval "$ac_compile") 2>conftest.er1
26004   ac_status=$?
26005   grep -v '^ *+' conftest.er1 >conftest.err
26006   rm -f conftest.er1
26007   cat conftest.err >&5
26008   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26009   (exit $ac_status); } && {
26010          test -z "$ac_c_werror_flag" ||
26011          test ! -s conftest.err
26012        } && test -s conftest.$ac_objext; then
26013   ac_lo=$ac_mid; break
26014 else
26015   $as_echo "$as_me: failed program was:" >&5
26016 sed 's/^/| /' conftest.$ac_ext >&5
26017
26018         ac_hi=`expr '(' $ac_mid ')' - 1`
26019                         if test $ac_mid -le $ac_hi; then
26020                           ac_lo= ac_hi=
26021                           break
26022                         fi
26023                         ac_mid=`expr 2 '*' $ac_mid`
26024 fi
26025
26026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26027   done
26028 else
26029   $as_echo "$as_me: failed program was:" >&5
26030 sed 's/^/| /' conftest.$ac_ext >&5
26031
26032         ac_lo= ac_hi=
26033 fi
26034
26035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26036 fi
26037
26038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26039 # Binary search between lo and hi bounds.
26040 while test "x$ac_lo" != "x$ac_hi"; do
26041   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26042   cat >conftest.$ac_ext <<_ACEOF
26043 /* confdefs.h.  */
26044 _ACEOF
26045 cat confdefs.h >>conftest.$ac_ext
26046 cat >>conftest.$ac_ext <<_ACEOF
26047 /* end confdefs.h.  */
26048 $ac_includes_default
26049 #ifndef offsetof
26050 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26051 #endif
26052 typedef struct { char x; long y; } ac__type_alignof_;
26053 int
26054 main ()
26055 {
26056 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26057 test_array [0] = 0
26058
26059   ;
26060   return 0;
26061 }
26062 _ACEOF
26063 rm -f conftest.$ac_objext
26064 if { (ac_try="$ac_compile"
26065 case "(($ac_try" in
26066   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26067   *) ac_try_echo=$ac_try;;
26068 esac
26069 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26070 $as_echo "$ac_try_echo") >&5
26071   (eval "$ac_compile") 2>conftest.er1
26072   ac_status=$?
26073   grep -v '^ *+' conftest.er1 >conftest.err
26074   rm -f conftest.er1
26075   cat conftest.err >&5
26076   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26077   (exit $ac_status); } && {
26078          test -z "$ac_c_werror_flag" ||
26079          test ! -s conftest.err
26080        } && test -s conftest.$ac_objext; then
26081   ac_hi=$ac_mid
26082 else
26083   $as_echo "$as_me: failed program was:" >&5
26084 sed 's/^/| /' conftest.$ac_ext >&5
26085
26086         ac_lo=`expr '(' $ac_mid ')' + 1`
26087 fi
26088
26089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26090 done
26091 case $ac_lo in
26092 ?*) ac_cv_alignof_long=$ac_lo;;
26093 '') if test "$ac_cv_type_long" = yes; then
26094      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26095 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26096 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26097 See \`config.log' for more details." >&5
26098 $as_echo "$as_me: error: cannot compute alignment of long
26099 See \`config.log' for more details." >&2;}
26100    { (exit 77); exit 77; }; }; }
26101    else
26102      ac_cv_alignof_long=0
26103    fi ;;
26104 esac
26105 else
26106   cat >conftest.$ac_ext <<_ACEOF
26107 /* confdefs.h.  */
26108 _ACEOF
26109 cat confdefs.h >>conftest.$ac_ext
26110 cat >>conftest.$ac_ext <<_ACEOF
26111 /* end confdefs.h.  */
26112 $ac_includes_default
26113 #ifndef offsetof
26114 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26115 #endif
26116 typedef struct { char x; long y; } ac__type_alignof_;
26117 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26118 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26119 #include <stdio.h>
26120 #include <stdlib.h>
26121 int
26122 main ()
26123 {
26124
26125   FILE *f = fopen ("conftest.val", "w");
26126   if (! f)
26127     return 1;
26128   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26129     {
26130       long int i = longval ();
26131       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26132         return 1;
26133       fprintf (f, "%ld", i);
26134     }
26135   else
26136     {
26137       unsigned long int i = ulongval ();
26138       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26139         return 1;
26140       fprintf (f, "%lu", i);
26141     }
26142   /* Do not output a trailing newline, as this causes \r\n confusion
26143      on some platforms.  */
26144   return ferror (f) || fclose (f) != 0;
26145
26146   ;
26147   return 0;
26148 }
26149 _ACEOF
26150 rm -f conftest$ac_exeext
26151 if { (ac_try="$ac_link"
26152 case "(($ac_try" in
26153   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26154   *) ac_try_echo=$ac_try;;
26155 esac
26156 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26157 $as_echo "$ac_try_echo") >&5
26158   (eval "$ac_link") 2>&5
26159   ac_status=$?
26160   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26161   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26162   { (case "(($ac_try" in
26163   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26164   *) ac_try_echo=$ac_try;;
26165 esac
26166 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26167 $as_echo "$ac_try_echo") >&5
26168   (eval "$ac_try") 2>&5
26169   ac_status=$?
26170   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26171   (exit $ac_status); }; }; then
26172   ac_cv_alignof_long=`cat conftest.val`
26173 else
26174   $as_echo "$as_me: program exited with status $ac_status" >&5
26175 $as_echo "$as_me: failed program was:" >&5
26176 sed 's/^/| /' conftest.$ac_ext >&5
26177
26178 ( exit $ac_status )
26179 if test "$ac_cv_type_long" = yes; then
26180      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26181 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26182 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26183 See \`config.log' for more details." >&5
26184 $as_echo "$as_me: error: cannot compute alignment of long
26185 See \`config.log' for more details." >&2;}
26186    { (exit 77); exit 77; }; }; }
26187    else
26188      ac_cv_alignof_long=0
26189    fi
26190 fi
26191 rm -rf conftest.dSYM
26192 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26193 fi
26194 rm -f conftest.val
26195 fi
26196 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
26197 $as_echo "$ac_cv_alignof_long" >&6; }
26198
26199
26200
26201 cat >>confdefs.h <<_ACEOF
26202 #define ALIGNOF_LONG $ac_cv_alignof_long
26203 _ACEOF
26204
26205
26206 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
26207   # The cast to long int works around a bug in the HP C Compiler,
26208 # see AC_CHECK_SIZEOF for more information.
26209 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
26210 $as_echo_n "checking alignment of long long int... " >&6; }
26211 if test "${ac_cv_alignof_long_long_int+set}" = set; then
26212   $as_echo_n "(cached) " >&6
26213 else
26214   if test "$cross_compiling" = yes; then
26215   # Depending upon the size, compute the lo and hi bounds.
26216 cat >conftest.$ac_ext <<_ACEOF
26217 /* confdefs.h.  */
26218 _ACEOF
26219 cat confdefs.h >>conftest.$ac_ext
26220 cat >>conftest.$ac_ext <<_ACEOF
26221 /* end confdefs.h.  */
26222 $ac_includes_default
26223 #ifndef offsetof
26224 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26225 #endif
26226 typedef struct { char x; long long int y; } ac__type_alignof_;
26227 int
26228 main ()
26229 {
26230 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26231 test_array [0] = 0
26232
26233   ;
26234   return 0;
26235 }
26236 _ACEOF
26237 rm -f conftest.$ac_objext
26238 if { (ac_try="$ac_compile"
26239 case "(($ac_try" in
26240   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26241   *) ac_try_echo=$ac_try;;
26242 esac
26243 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26244 $as_echo "$ac_try_echo") >&5
26245   (eval "$ac_compile") 2>conftest.er1
26246   ac_status=$?
26247   grep -v '^ *+' conftest.er1 >conftest.err
26248   rm -f conftest.er1
26249   cat conftest.err >&5
26250   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26251   (exit $ac_status); } && {
26252          test -z "$ac_c_werror_flag" ||
26253          test ! -s conftest.err
26254        } && test -s conftest.$ac_objext; then
26255   ac_lo=0 ac_mid=0
26256   while :; do
26257     cat >conftest.$ac_ext <<_ACEOF
26258 /* confdefs.h.  */
26259 _ACEOF
26260 cat confdefs.h >>conftest.$ac_ext
26261 cat >>conftest.$ac_ext <<_ACEOF
26262 /* end confdefs.h.  */
26263 $ac_includes_default
26264 #ifndef offsetof
26265 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26266 #endif
26267 typedef struct { char x; long long int y; } ac__type_alignof_;
26268 int
26269 main ()
26270 {
26271 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26272 test_array [0] = 0
26273
26274   ;
26275   return 0;
26276 }
26277 _ACEOF
26278 rm -f conftest.$ac_objext
26279 if { (ac_try="$ac_compile"
26280 case "(($ac_try" in
26281   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26282   *) ac_try_echo=$ac_try;;
26283 esac
26284 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26285 $as_echo "$ac_try_echo") >&5
26286   (eval "$ac_compile") 2>conftest.er1
26287   ac_status=$?
26288   grep -v '^ *+' conftest.er1 >conftest.err
26289   rm -f conftest.er1
26290   cat conftest.err >&5
26291   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26292   (exit $ac_status); } && {
26293          test -z "$ac_c_werror_flag" ||
26294          test ! -s conftest.err
26295        } && test -s conftest.$ac_objext; then
26296   ac_hi=$ac_mid; break
26297 else
26298   $as_echo "$as_me: failed program was:" >&5
26299 sed 's/^/| /' conftest.$ac_ext >&5
26300
26301         ac_lo=`expr $ac_mid + 1`
26302                         if test $ac_lo -le $ac_mid; then
26303                           ac_lo= ac_hi=
26304                           break
26305                         fi
26306                         ac_mid=`expr 2 '*' $ac_mid + 1`
26307 fi
26308
26309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26310   done
26311 else
26312   $as_echo "$as_me: failed program was:" >&5
26313 sed 's/^/| /' conftest.$ac_ext >&5
26314
26315         cat >conftest.$ac_ext <<_ACEOF
26316 /* confdefs.h.  */
26317 _ACEOF
26318 cat confdefs.h >>conftest.$ac_ext
26319 cat >>conftest.$ac_ext <<_ACEOF
26320 /* end confdefs.h.  */
26321 $ac_includes_default
26322 #ifndef offsetof
26323 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26324 #endif
26325 typedef struct { char x; long long int y; } ac__type_alignof_;
26326 int
26327 main ()
26328 {
26329 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26330 test_array [0] = 0
26331
26332   ;
26333   return 0;
26334 }
26335 _ACEOF
26336 rm -f conftest.$ac_objext
26337 if { (ac_try="$ac_compile"
26338 case "(($ac_try" in
26339   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26340   *) ac_try_echo=$ac_try;;
26341 esac
26342 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26343 $as_echo "$ac_try_echo") >&5
26344   (eval "$ac_compile") 2>conftest.er1
26345   ac_status=$?
26346   grep -v '^ *+' conftest.er1 >conftest.err
26347   rm -f conftest.er1
26348   cat conftest.err >&5
26349   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26350   (exit $ac_status); } && {
26351          test -z "$ac_c_werror_flag" ||
26352          test ! -s conftest.err
26353        } && test -s conftest.$ac_objext; then
26354   ac_hi=-1 ac_mid=-1
26355   while :; do
26356     cat >conftest.$ac_ext <<_ACEOF
26357 /* confdefs.h.  */
26358 _ACEOF
26359 cat confdefs.h >>conftest.$ac_ext
26360 cat >>conftest.$ac_ext <<_ACEOF
26361 /* end confdefs.h.  */
26362 $ac_includes_default
26363 #ifndef offsetof
26364 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26365 #endif
26366 typedef struct { char x; long long int y; } ac__type_alignof_;
26367 int
26368 main ()
26369 {
26370 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26371 test_array [0] = 0
26372
26373   ;
26374   return 0;
26375 }
26376 _ACEOF
26377 rm -f conftest.$ac_objext
26378 if { (ac_try="$ac_compile"
26379 case "(($ac_try" in
26380   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26381   *) ac_try_echo=$ac_try;;
26382 esac
26383 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26384 $as_echo "$ac_try_echo") >&5
26385   (eval "$ac_compile") 2>conftest.er1
26386   ac_status=$?
26387   grep -v '^ *+' conftest.er1 >conftest.err
26388   rm -f conftest.er1
26389   cat conftest.err >&5
26390   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26391   (exit $ac_status); } && {
26392          test -z "$ac_c_werror_flag" ||
26393          test ! -s conftest.err
26394        } && test -s conftest.$ac_objext; then
26395   ac_lo=$ac_mid; break
26396 else
26397   $as_echo "$as_me: failed program was:" >&5
26398 sed 's/^/| /' conftest.$ac_ext >&5
26399
26400         ac_hi=`expr '(' $ac_mid ')' - 1`
26401                         if test $ac_mid -le $ac_hi; then
26402                           ac_lo= ac_hi=
26403                           break
26404                         fi
26405                         ac_mid=`expr 2 '*' $ac_mid`
26406 fi
26407
26408 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26409   done
26410 else
26411   $as_echo "$as_me: failed program was:" >&5
26412 sed 's/^/| /' conftest.$ac_ext >&5
26413
26414         ac_lo= ac_hi=
26415 fi
26416
26417 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26418 fi
26419
26420 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26421 # Binary search between lo and hi bounds.
26422 while test "x$ac_lo" != "x$ac_hi"; do
26423   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26424   cat >conftest.$ac_ext <<_ACEOF
26425 /* confdefs.h.  */
26426 _ACEOF
26427 cat confdefs.h >>conftest.$ac_ext
26428 cat >>conftest.$ac_ext <<_ACEOF
26429 /* end confdefs.h.  */
26430 $ac_includes_default
26431 #ifndef offsetof
26432 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26433 #endif
26434 typedef struct { char x; long long int y; } ac__type_alignof_;
26435 int
26436 main ()
26437 {
26438 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26439 test_array [0] = 0
26440
26441   ;
26442   return 0;
26443 }
26444 _ACEOF
26445 rm -f conftest.$ac_objext
26446 if { (ac_try="$ac_compile"
26447 case "(($ac_try" in
26448   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26449   *) ac_try_echo=$ac_try;;
26450 esac
26451 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26452 $as_echo "$ac_try_echo") >&5
26453   (eval "$ac_compile") 2>conftest.er1
26454   ac_status=$?
26455   grep -v '^ *+' conftest.er1 >conftest.err
26456   rm -f conftest.er1
26457   cat conftest.err >&5
26458   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26459   (exit $ac_status); } && {
26460          test -z "$ac_c_werror_flag" ||
26461          test ! -s conftest.err
26462        } && test -s conftest.$ac_objext; then
26463   ac_hi=$ac_mid
26464 else
26465   $as_echo "$as_me: failed program was:" >&5
26466 sed 's/^/| /' conftest.$ac_ext >&5
26467
26468         ac_lo=`expr '(' $ac_mid ')' + 1`
26469 fi
26470
26471 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26472 done
26473 case $ac_lo in
26474 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
26475 '') if test "$ac_cv_type_long_long_int" = yes; then
26476      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26477 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26478 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26479 See \`config.log' for more details." >&5
26480 $as_echo "$as_me: error: cannot compute alignment of long long int
26481 See \`config.log' for more details." >&2;}
26482    { (exit 77); exit 77; }; }; }
26483    else
26484      ac_cv_alignof_long_long_int=0
26485    fi ;;
26486 esac
26487 else
26488   cat >conftest.$ac_ext <<_ACEOF
26489 /* confdefs.h.  */
26490 _ACEOF
26491 cat confdefs.h >>conftest.$ac_ext
26492 cat >>conftest.$ac_ext <<_ACEOF
26493 /* end confdefs.h.  */
26494 $ac_includes_default
26495 #ifndef offsetof
26496 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26497 #endif
26498 typedef struct { char x; long long int y; } ac__type_alignof_;
26499 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26500 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26501 #include <stdio.h>
26502 #include <stdlib.h>
26503 int
26504 main ()
26505 {
26506
26507   FILE *f = fopen ("conftest.val", "w");
26508   if (! f)
26509     return 1;
26510   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26511     {
26512       long int i = longval ();
26513       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26514         return 1;
26515       fprintf (f, "%ld", i);
26516     }
26517   else
26518     {
26519       unsigned long int i = ulongval ();
26520       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26521         return 1;
26522       fprintf (f, "%lu", i);
26523     }
26524   /* Do not output a trailing newline, as this causes \r\n confusion
26525      on some platforms.  */
26526   return ferror (f) || fclose (f) != 0;
26527
26528   ;
26529   return 0;
26530 }
26531 _ACEOF
26532 rm -f conftest$ac_exeext
26533 if { (ac_try="$ac_link"
26534 case "(($ac_try" in
26535   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26536   *) ac_try_echo=$ac_try;;
26537 esac
26538 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26539 $as_echo "$ac_try_echo") >&5
26540   (eval "$ac_link") 2>&5
26541   ac_status=$?
26542   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26543   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26544   { (case "(($ac_try" in
26545   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26546   *) ac_try_echo=$ac_try;;
26547 esac
26548 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26549 $as_echo "$ac_try_echo") >&5
26550   (eval "$ac_try") 2>&5
26551   ac_status=$?
26552   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26553   (exit $ac_status); }; }; then
26554   ac_cv_alignof_long_long_int=`cat conftest.val`
26555 else
26556   $as_echo "$as_me: program exited with status $ac_status" >&5
26557 $as_echo "$as_me: failed program was:" >&5
26558 sed 's/^/| /' conftest.$ac_ext >&5
26559
26560 ( exit $ac_status )
26561 if test "$ac_cv_type_long_long_int" = yes; then
26562      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26563 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26564 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26565 See \`config.log' for more details." >&5
26566 $as_echo "$as_me: error: cannot compute alignment of long long int
26567 See \`config.log' for more details." >&2;}
26568    { (exit 77); exit 77; }; }; }
26569    else
26570      ac_cv_alignof_long_long_int=0
26571    fi
26572 fi
26573 rm -rf conftest.dSYM
26574 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26575 fi
26576 rm -f conftest.val
26577 fi
26578 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
26579 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
26580
26581
26582
26583 cat >>confdefs.h <<_ACEOF
26584 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
26585 _ACEOF
26586
26587
26588 fi
26589 # The cast to long int works around a bug in the HP C Compiler,
26590 # see AC_CHECK_SIZEOF for more information.
26591 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
26592 $as_echo_n "checking alignment of double... " >&6; }
26593 if test "${ac_cv_alignof_double+set}" = set; then
26594   $as_echo_n "(cached) " >&6
26595 else
26596   if test "$cross_compiling" = yes; then
26597   # Depending upon the size, compute the lo and hi bounds.
26598 cat >conftest.$ac_ext <<_ACEOF
26599 /* confdefs.h.  */
26600 _ACEOF
26601 cat confdefs.h >>conftest.$ac_ext
26602 cat >>conftest.$ac_ext <<_ACEOF
26603 /* end confdefs.h.  */
26604 $ac_includes_default
26605 #ifndef offsetof
26606 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26607 #endif
26608 typedef struct { char x; double y; } ac__type_alignof_;
26609 int
26610 main ()
26611 {
26612 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26613 test_array [0] = 0
26614
26615   ;
26616   return 0;
26617 }
26618 _ACEOF
26619 rm -f conftest.$ac_objext
26620 if { (ac_try="$ac_compile"
26621 case "(($ac_try" in
26622   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26623   *) ac_try_echo=$ac_try;;
26624 esac
26625 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26626 $as_echo "$ac_try_echo") >&5
26627   (eval "$ac_compile") 2>conftest.er1
26628   ac_status=$?
26629   grep -v '^ *+' conftest.er1 >conftest.err
26630   rm -f conftest.er1
26631   cat conftest.err >&5
26632   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26633   (exit $ac_status); } && {
26634          test -z "$ac_c_werror_flag" ||
26635          test ! -s conftest.err
26636        } && test -s conftest.$ac_objext; then
26637   ac_lo=0 ac_mid=0
26638   while :; do
26639     cat >conftest.$ac_ext <<_ACEOF
26640 /* confdefs.h.  */
26641 _ACEOF
26642 cat confdefs.h >>conftest.$ac_ext
26643 cat >>conftest.$ac_ext <<_ACEOF
26644 /* end confdefs.h.  */
26645 $ac_includes_default
26646 #ifndef offsetof
26647 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26648 #endif
26649 typedef struct { char x; double y; } ac__type_alignof_;
26650 int
26651 main ()
26652 {
26653 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26654 test_array [0] = 0
26655
26656   ;
26657   return 0;
26658 }
26659 _ACEOF
26660 rm -f conftest.$ac_objext
26661 if { (ac_try="$ac_compile"
26662 case "(($ac_try" in
26663   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26664   *) ac_try_echo=$ac_try;;
26665 esac
26666 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26667 $as_echo "$ac_try_echo") >&5
26668   (eval "$ac_compile") 2>conftest.er1
26669   ac_status=$?
26670   grep -v '^ *+' conftest.er1 >conftest.err
26671   rm -f conftest.er1
26672   cat conftest.err >&5
26673   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26674   (exit $ac_status); } && {
26675          test -z "$ac_c_werror_flag" ||
26676          test ! -s conftest.err
26677        } && test -s conftest.$ac_objext; then
26678   ac_hi=$ac_mid; break
26679 else
26680   $as_echo "$as_me: failed program was:" >&5
26681 sed 's/^/| /' conftest.$ac_ext >&5
26682
26683         ac_lo=`expr $ac_mid + 1`
26684                         if test $ac_lo -le $ac_mid; then
26685                           ac_lo= ac_hi=
26686                           break
26687                         fi
26688                         ac_mid=`expr 2 '*' $ac_mid + 1`
26689 fi
26690
26691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26692   done
26693 else
26694   $as_echo "$as_me: failed program was:" >&5
26695 sed 's/^/| /' conftest.$ac_ext >&5
26696
26697         cat >conftest.$ac_ext <<_ACEOF
26698 /* confdefs.h.  */
26699 _ACEOF
26700 cat confdefs.h >>conftest.$ac_ext
26701 cat >>conftest.$ac_ext <<_ACEOF
26702 /* end confdefs.h.  */
26703 $ac_includes_default
26704 #ifndef offsetof
26705 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26706 #endif
26707 typedef struct { char x; double y; } ac__type_alignof_;
26708 int
26709 main ()
26710 {
26711 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26712 test_array [0] = 0
26713
26714   ;
26715   return 0;
26716 }
26717 _ACEOF
26718 rm -f conftest.$ac_objext
26719 if { (ac_try="$ac_compile"
26720 case "(($ac_try" in
26721   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26722   *) ac_try_echo=$ac_try;;
26723 esac
26724 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26725 $as_echo "$ac_try_echo") >&5
26726   (eval "$ac_compile") 2>conftest.er1
26727   ac_status=$?
26728   grep -v '^ *+' conftest.er1 >conftest.err
26729   rm -f conftest.er1
26730   cat conftest.err >&5
26731   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26732   (exit $ac_status); } && {
26733          test -z "$ac_c_werror_flag" ||
26734          test ! -s conftest.err
26735        } && test -s conftest.$ac_objext; then
26736   ac_hi=-1 ac_mid=-1
26737   while :; do
26738     cat >conftest.$ac_ext <<_ACEOF
26739 /* confdefs.h.  */
26740 _ACEOF
26741 cat confdefs.h >>conftest.$ac_ext
26742 cat >>conftest.$ac_ext <<_ACEOF
26743 /* end confdefs.h.  */
26744 $ac_includes_default
26745 #ifndef offsetof
26746 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26747 #endif
26748 typedef struct { char x; double y; } ac__type_alignof_;
26749 int
26750 main ()
26751 {
26752 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26753 test_array [0] = 0
26754
26755   ;
26756   return 0;
26757 }
26758 _ACEOF
26759 rm -f conftest.$ac_objext
26760 if { (ac_try="$ac_compile"
26761 case "(($ac_try" in
26762   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26763   *) ac_try_echo=$ac_try;;
26764 esac
26765 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26766 $as_echo "$ac_try_echo") >&5
26767   (eval "$ac_compile") 2>conftest.er1
26768   ac_status=$?
26769   grep -v '^ *+' conftest.er1 >conftest.err
26770   rm -f conftest.er1
26771   cat conftest.err >&5
26772   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26773   (exit $ac_status); } && {
26774          test -z "$ac_c_werror_flag" ||
26775          test ! -s conftest.err
26776        } && test -s conftest.$ac_objext; then
26777   ac_lo=$ac_mid; break
26778 else
26779   $as_echo "$as_me: failed program was:" >&5
26780 sed 's/^/| /' conftest.$ac_ext >&5
26781
26782         ac_hi=`expr '(' $ac_mid ')' - 1`
26783                         if test $ac_mid -le $ac_hi; then
26784                           ac_lo= ac_hi=
26785                           break
26786                         fi
26787                         ac_mid=`expr 2 '*' $ac_mid`
26788 fi
26789
26790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26791   done
26792 else
26793   $as_echo "$as_me: failed program was:" >&5
26794 sed 's/^/| /' conftest.$ac_ext >&5
26795
26796         ac_lo= ac_hi=
26797 fi
26798
26799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26800 fi
26801
26802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26803 # Binary search between lo and hi bounds.
26804 while test "x$ac_lo" != "x$ac_hi"; do
26805   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26806   cat >conftest.$ac_ext <<_ACEOF
26807 /* confdefs.h.  */
26808 _ACEOF
26809 cat confdefs.h >>conftest.$ac_ext
26810 cat >>conftest.$ac_ext <<_ACEOF
26811 /* end confdefs.h.  */
26812 $ac_includes_default
26813 #ifndef offsetof
26814 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26815 #endif
26816 typedef struct { char x; double y; } ac__type_alignof_;
26817 int
26818 main ()
26819 {
26820 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26821 test_array [0] = 0
26822
26823   ;
26824   return 0;
26825 }
26826 _ACEOF
26827 rm -f conftest.$ac_objext
26828 if { (ac_try="$ac_compile"
26829 case "(($ac_try" in
26830   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26831   *) ac_try_echo=$ac_try;;
26832 esac
26833 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26834 $as_echo "$ac_try_echo") >&5
26835   (eval "$ac_compile") 2>conftest.er1
26836   ac_status=$?
26837   grep -v '^ *+' conftest.er1 >conftest.err
26838   rm -f conftest.er1
26839   cat conftest.err >&5
26840   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26841   (exit $ac_status); } && {
26842          test -z "$ac_c_werror_flag" ||
26843          test ! -s conftest.err
26844        } && test -s conftest.$ac_objext; then
26845   ac_hi=$ac_mid
26846 else
26847   $as_echo "$as_me: failed program was:" >&5
26848 sed 's/^/| /' conftest.$ac_ext >&5
26849
26850         ac_lo=`expr '(' $ac_mid ')' + 1`
26851 fi
26852
26853 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26854 done
26855 case $ac_lo in
26856 ?*) ac_cv_alignof_double=$ac_lo;;
26857 '') if test "$ac_cv_type_double" = yes; then
26858      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26859 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26860 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
26861 See \`config.log' for more details." >&5
26862 $as_echo "$as_me: error: cannot compute alignment of double
26863 See \`config.log' for more details." >&2;}
26864    { (exit 77); exit 77; }; }; }
26865    else
26866      ac_cv_alignof_double=0
26867    fi ;;
26868 esac
26869 else
26870   cat >conftest.$ac_ext <<_ACEOF
26871 /* confdefs.h.  */
26872 _ACEOF
26873 cat confdefs.h >>conftest.$ac_ext
26874 cat >>conftest.$ac_ext <<_ACEOF
26875 /* end confdefs.h.  */
26876 $ac_includes_default
26877 #ifndef offsetof
26878 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26879 #endif
26880 typedef struct { char x; double y; } ac__type_alignof_;
26881 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26882 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26883 #include <stdio.h>
26884 #include <stdlib.h>
26885 int
26886 main ()
26887 {
26888
26889   FILE *f = fopen ("conftest.val", "w");
26890   if (! f)
26891     return 1;
26892   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26893     {
26894       long int i = longval ();
26895       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26896         return 1;
26897       fprintf (f, "%ld", i);
26898     }
26899   else
26900     {
26901       unsigned long int i = ulongval ();
26902       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26903         return 1;
26904       fprintf (f, "%lu", i);
26905     }
26906   /* Do not output a trailing newline, as this causes \r\n confusion
26907      on some platforms.  */
26908   return ferror (f) || fclose (f) != 0;
26909
26910   ;
26911   return 0;
26912 }
26913 _ACEOF
26914 rm -f conftest$ac_exeext
26915 if { (ac_try="$ac_link"
26916 case "(($ac_try" in
26917   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26918   *) ac_try_echo=$ac_try;;
26919 esac
26920 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26921 $as_echo "$ac_try_echo") >&5
26922   (eval "$ac_link") 2>&5
26923   ac_status=$?
26924   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26925   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26926   { (case "(($ac_try" in
26927   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26928   *) ac_try_echo=$ac_try;;
26929 esac
26930 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26931 $as_echo "$ac_try_echo") >&5
26932   (eval "$ac_try") 2>&5
26933   ac_status=$?
26934   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26935   (exit $ac_status); }; }; then
26936   ac_cv_alignof_double=`cat conftest.val`
26937 else
26938   $as_echo "$as_me: program exited with status $ac_status" >&5
26939 $as_echo "$as_me: failed program was:" >&5
26940 sed 's/^/| /' conftest.$ac_ext >&5
26941
26942 ( exit $ac_status )
26943 if test "$ac_cv_type_double" = yes; then
26944      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26945 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26946 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
26947 See \`config.log' for more details." >&5
26948 $as_echo "$as_me: error: cannot compute alignment of double
26949 See \`config.log' for more details." >&2;}
26950    { (exit 77); exit 77; }; }; }
26951    else
26952      ac_cv_alignof_double=0
26953    fi
26954 fi
26955 rm -rf conftest.dSYM
26956 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26957 fi
26958 rm -f conftest.val
26959 fi
26960 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
26961 $as_echo "$ac_cv_alignof_double" >&6; }
26962
26963
26964
26965 cat >>confdefs.h <<_ACEOF
26966 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
26967 _ACEOF
26968
26969
26970
26971 # Compute maximum alignment of any basic type.
26972 # We assume long's alignment is at least as strong as char, short, or int;
26973 # but we must check long long (if it exists) and double.
26974
26975 MAX_ALIGNOF=$ac_cv_alignof_long
26976 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
26977   MAX_ALIGNOF=$ac_cv_alignof_double
26978 fi
26979 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
26980   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
26981 fi
26982
26983 cat >>confdefs.h <<_ACEOF
26984 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
26985 _ACEOF
26986
26987
26988
26989 # Some platforms predefine the types int8, int16, etc.  Only check
26990 # a (hopefully) representative subset.
26991 { $as_echo "$as_me:$LINENO: checking for int8" >&5
26992 $as_echo_n "checking for int8... " >&6; }
26993 if test "${ac_cv_type_int8+set}" = set; then
26994   $as_echo_n "(cached) " >&6
26995 else
26996   ac_cv_type_int8=no
26997 cat >conftest.$ac_ext <<_ACEOF
26998 /* confdefs.h.  */
26999 _ACEOF
27000 cat confdefs.h >>conftest.$ac_ext
27001 cat >>conftest.$ac_ext <<_ACEOF
27002 /* end confdefs.h.  */
27003 #include <stdio.h>
27004 #ifdef HAVE_SUPPORTDEFS_H
27005 #include <SupportDefs.h>
27006 #endif
27007
27008 int
27009 main ()
27010 {
27011 if (sizeof (int8))
27012        return 0;
27013   ;
27014   return 0;
27015 }
27016 _ACEOF
27017 rm -f conftest.$ac_objext
27018 if { (ac_try="$ac_compile"
27019 case "(($ac_try" in
27020   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27021   *) ac_try_echo=$ac_try;;
27022 esac
27023 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27024 $as_echo "$ac_try_echo") >&5
27025   (eval "$ac_compile") 2>conftest.er1
27026   ac_status=$?
27027   grep -v '^ *+' conftest.er1 >conftest.err
27028   rm -f conftest.er1
27029   cat conftest.err >&5
27030   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27031   (exit $ac_status); } && {
27032          test -z "$ac_c_werror_flag" ||
27033          test ! -s conftest.err
27034        } && test -s conftest.$ac_objext; then
27035   cat >conftest.$ac_ext <<_ACEOF
27036 /* confdefs.h.  */
27037 _ACEOF
27038 cat confdefs.h >>conftest.$ac_ext
27039 cat >>conftest.$ac_ext <<_ACEOF
27040 /* end confdefs.h.  */
27041 #include <stdio.h>
27042 #ifdef HAVE_SUPPORTDEFS_H
27043 #include <SupportDefs.h>
27044 #endif
27045
27046 int
27047 main ()
27048 {
27049 if (sizeof ((int8)))
27050           return 0;
27051   ;
27052   return 0;
27053 }
27054 _ACEOF
27055 rm -f conftest.$ac_objext
27056 if { (ac_try="$ac_compile"
27057 case "(($ac_try" in
27058   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27059   *) ac_try_echo=$ac_try;;
27060 esac
27061 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27062 $as_echo "$ac_try_echo") >&5
27063   (eval "$ac_compile") 2>conftest.er1
27064   ac_status=$?
27065   grep -v '^ *+' conftest.er1 >conftest.err
27066   rm -f conftest.er1
27067   cat conftest.err >&5
27068   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27069   (exit $ac_status); } && {
27070          test -z "$ac_c_werror_flag" ||
27071          test ! -s conftest.err
27072        } && test -s conftest.$ac_objext; then
27073   :
27074 else
27075   $as_echo "$as_me: failed program was:" >&5
27076 sed 's/^/| /' conftest.$ac_ext >&5
27077
27078         ac_cv_type_int8=yes
27079 fi
27080
27081 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27082 else
27083   $as_echo "$as_me: failed program was:" >&5
27084 sed 's/^/| /' conftest.$ac_ext >&5
27085
27086
27087 fi
27088
27089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27090 fi
27091 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
27092 $as_echo "$ac_cv_type_int8" >&6; }
27093 if test "x$ac_cv_type_int8" = x""yes; then
27094
27095 cat >>confdefs.h <<_ACEOF
27096 #define HAVE_INT8 1
27097 _ACEOF
27098
27099
27100 fi
27101 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
27102 $as_echo_n "checking for uint8... " >&6; }
27103 if test "${ac_cv_type_uint8+set}" = set; then
27104   $as_echo_n "(cached) " >&6
27105 else
27106   ac_cv_type_uint8=no
27107 cat >conftest.$ac_ext <<_ACEOF
27108 /* confdefs.h.  */
27109 _ACEOF
27110 cat confdefs.h >>conftest.$ac_ext
27111 cat >>conftest.$ac_ext <<_ACEOF
27112 /* end confdefs.h.  */
27113 #include <stdio.h>
27114 #ifdef HAVE_SUPPORTDEFS_H
27115 #include <SupportDefs.h>
27116 #endif
27117
27118 int
27119 main ()
27120 {
27121 if (sizeof (uint8))
27122        return 0;
27123   ;
27124   return 0;
27125 }
27126 _ACEOF
27127 rm -f conftest.$ac_objext
27128 if { (ac_try="$ac_compile"
27129 case "(($ac_try" in
27130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27131   *) ac_try_echo=$ac_try;;
27132 esac
27133 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27134 $as_echo "$ac_try_echo") >&5
27135   (eval "$ac_compile") 2>conftest.er1
27136   ac_status=$?
27137   grep -v '^ *+' conftest.er1 >conftest.err
27138   rm -f conftest.er1
27139   cat conftest.err >&5
27140   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27141   (exit $ac_status); } && {
27142          test -z "$ac_c_werror_flag" ||
27143          test ! -s conftest.err
27144        } && test -s conftest.$ac_objext; then
27145   cat >conftest.$ac_ext <<_ACEOF
27146 /* confdefs.h.  */
27147 _ACEOF
27148 cat confdefs.h >>conftest.$ac_ext
27149 cat >>conftest.$ac_ext <<_ACEOF
27150 /* end confdefs.h.  */
27151 #include <stdio.h>
27152 #ifdef HAVE_SUPPORTDEFS_H
27153 #include <SupportDefs.h>
27154 #endif
27155
27156 int
27157 main ()
27158 {
27159 if (sizeof ((uint8)))
27160           return 0;
27161   ;
27162   return 0;
27163 }
27164 _ACEOF
27165 rm -f conftest.$ac_objext
27166 if { (ac_try="$ac_compile"
27167 case "(($ac_try" in
27168   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27169   *) ac_try_echo=$ac_try;;
27170 esac
27171 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27172 $as_echo "$ac_try_echo") >&5
27173   (eval "$ac_compile") 2>conftest.er1
27174   ac_status=$?
27175   grep -v '^ *+' conftest.er1 >conftest.err
27176   rm -f conftest.er1
27177   cat conftest.err >&5
27178   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27179   (exit $ac_status); } && {
27180          test -z "$ac_c_werror_flag" ||
27181          test ! -s conftest.err
27182        } && test -s conftest.$ac_objext; then
27183   :
27184 else
27185   $as_echo "$as_me: failed program was:" >&5
27186 sed 's/^/| /' conftest.$ac_ext >&5
27187
27188         ac_cv_type_uint8=yes
27189 fi
27190
27191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27192 else
27193   $as_echo "$as_me: failed program was:" >&5
27194 sed 's/^/| /' conftest.$ac_ext >&5
27195
27196
27197 fi
27198
27199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27200 fi
27201 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
27202 $as_echo "$ac_cv_type_uint8" >&6; }
27203 if test "x$ac_cv_type_uint8" = x""yes; then
27204
27205 cat >>confdefs.h <<_ACEOF
27206 #define HAVE_UINT8 1
27207 _ACEOF
27208
27209
27210 fi
27211 { $as_echo "$as_me:$LINENO: checking for int64" >&5
27212 $as_echo_n "checking for int64... " >&6; }
27213 if test "${ac_cv_type_int64+set}" = set; then
27214   $as_echo_n "(cached) " >&6
27215 else
27216   ac_cv_type_int64=no
27217 cat >conftest.$ac_ext <<_ACEOF
27218 /* confdefs.h.  */
27219 _ACEOF
27220 cat confdefs.h >>conftest.$ac_ext
27221 cat >>conftest.$ac_ext <<_ACEOF
27222 /* end confdefs.h.  */
27223 #include <stdio.h>
27224 #ifdef HAVE_SUPPORTDEFS_H
27225 #include <SupportDefs.h>
27226 #endif
27227
27228 int
27229 main ()
27230 {
27231 if (sizeof (int64))
27232        return 0;
27233   ;
27234   return 0;
27235 }
27236 _ACEOF
27237 rm -f conftest.$ac_objext
27238 if { (ac_try="$ac_compile"
27239 case "(($ac_try" in
27240   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27241   *) ac_try_echo=$ac_try;;
27242 esac
27243 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27244 $as_echo "$ac_try_echo") >&5
27245   (eval "$ac_compile") 2>conftest.er1
27246   ac_status=$?
27247   grep -v '^ *+' conftest.er1 >conftest.err
27248   rm -f conftest.er1
27249   cat conftest.err >&5
27250   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27251   (exit $ac_status); } && {
27252          test -z "$ac_c_werror_flag" ||
27253          test ! -s conftest.err
27254        } && test -s conftest.$ac_objext; then
27255   cat >conftest.$ac_ext <<_ACEOF
27256 /* confdefs.h.  */
27257 _ACEOF
27258 cat confdefs.h >>conftest.$ac_ext
27259 cat >>conftest.$ac_ext <<_ACEOF
27260 /* end confdefs.h.  */
27261 #include <stdio.h>
27262 #ifdef HAVE_SUPPORTDEFS_H
27263 #include <SupportDefs.h>
27264 #endif
27265
27266 int
27267 main ()
27268 {
27269 if (sizeof ((int64)))
27270           return 0;
27271   ;
27272   return 0;
27273 }
27274 _ACEOF
27275 rm -f conftest.$ac_objext
27276 if { (ac_try="$ac_compile"
27277 case "(($ac_try" in
27278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27279   *) ac_try_echo=$ac_try;;
27280 esac
27281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27282 $as_echo "$ac_try_echo") >&5
27283   (eval "$ac_compile") 2>conftest.er1
27284   ac_status=$?
27285   grep -v '^ *+' conftest.er1 >conftest.err
27286   rm -f conftest.er1
27287   cat conftest.err >&5
27288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27289   (exit $ac_status); } && {
27290          test -z "$ac_c_werror_flag" ||
27291          test ! -s conftest.err
27292        } && test -s conftest.$ac_objext; then
27293   :
27294 else
27295   $as_echo "$as_me: failed program was:" >&5
27296 sed 's/^/| /' conftest.$ac_ext >&5
27297
27298         ac_cv_type_int64=yes
27299 fi
27300
27301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27302 else
27303   $as_echo "$as_me: failed program was:" >&5
27304 sed 's/^/| /' conftest.$ac_ext >&5
27305
27306
27307 fi
27308
27309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27310 fi
27311 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
27312 $as_echo "$ac_cv_type_int64" >&6; }
27313 if test "x$ac_cv_type_int64" = x""yes; then
27314
27315 cat >>confdefs.h <<_ACEOF
27316 #define HAVE_INT64 1
27317 _ACEOF
27318
27319
27320 fi
27321 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
27322 $as_echo_n "checking for uint64... " >&6; }
27323 if test "${ac_cv_type_uint64+set}" = set; then
27324   $as_echo_n "(cached) " >&6
27325 else
27326   ac_cv_type_uint64=no
27327 cat >conftest.$ac_ext <<_ACEOF
27328 /* confdefs.h.  */
27329 _ACEOF
27330 cat confdefs.h >>conftest.$ac_ext
27331 cat >>conftest.$ac_ext <<_ACEOF
27332 /* end confdefs.h.  */
27333 #include <stdio.h>
27334 #ifdef HAVE_SUPPORTDEFS_H
27335 #include <SupportDefs.h>
27336 #endif
27337
27338 int
27339 main ()
27340 {
27341 if (sizeof (uint64))
27342        return 0;
27343   ;
27344   return 0;
27345 }
27346 _ACEOF
27347 rm -f conftest.$ac_objext
27348 if { (ac_try="$ac_compile"
27349 case "(($ac_try" in
27350   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27351   *) ac_try_echo=$ac_try;;
27352 esac
27353 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27354 $as_echo "$ac_try_echo") >&5
27355   (eval "$ac_compile") 2>conftest.er1
27356   ac_status=$?
27357   grep -v '^ *+' conftest.er1 >conftest.err
27358   rm -f conftest.er1
27359   cat conftest.err >&5
27360   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27361   (exit $ac_status); } && {
27362          test -z "$ac_c_werror_flag" ||
27363          test ! -s conftest.err
27364        } && test -s conftest.$ac_objext; then
27365   cat >conftest.$ac_ext <<_ACEOF
27366 /* confdefs.h.  */
27367 _ACEOF
27368 cat confdefs.h >>conftest.$ac_ext
27369 cat >>conftest.$ac_ext <<_ACEOF
27370 /* end confdefs.h.  */
27371 #include <stdio.h>
27372 #ifdef HAVE_SUPPORTDEFS_H
27373 #include <SupportDefs.h>
27374 #endif
27375
27376 int
27377 main ()
27378 {
27379 if (sizeof ((uint64)))
27380           return 0;
27381   ;
27382   return 0;
27383 }
27384 _ACEOF
27385 rm -f conftest.$ac_objext
27386 if { (ac_try="$ac_compile"
27387 case "(($ac_try" in
27388   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27389   *) ac_try_echo=$ac_try;;
27390 esac
27391 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27392 $as_echo "$ac_try_echo") >&5
27393   (eval "$ac_compile") 2>conftest.er1
27394   ac_status=$?
27395   grep -v '^ *+' conftest.er1 >conftest.err
27396   rm -f conftest.er1
27397   cat conftest.err >&5
27398   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27399   (exit $ac_status); } && {
27400          test -z "$ac_c_werror_flag" ||
27401          test ! -s conftest.err
27402        } && test -s conftest.$ac_objext; then
27403   :
27404 else
27405   $as_echo "$as_me: failed program was:" >&5
27406 sed 's/^/| /' conftest.$ac_ext >&5
27407
27408         ac_cv_type_uint64=yes
27409 fi
27410
27411 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27412 else
27413   $as_echo "$as_me: failed program was:" >&5
27414 sed 's/^/| /' conftest.$ac_ext >&5
27415
27416
27417 fi
27418
27419 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27420 fi
27421 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
27422 $as_echo "$ac_cv_type_uint64" >&6; }
27423 if test "x$ac_cv_type_uint64" = x""yes; then
27424
27425 cat >>confdefs.h <<_ACEOF
27426 #define HAVE_UINT64 1
27427 _ACEOF
27428
27429
27430 fi
27431
27432
27433 # We also check for sig_atomic_t, which *should* be defined per ANSI
27434 # C, but is missing on some old platforms.
27435 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
27436 $as_echo_n "checking for sig_atomic_t... " >&6; }
27437 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
27438   $as_echo_n "(cached) " >&6
27439 else
27440   ac_cv_type_sig_atomic_t=no
27441 cat >conftest.$ac_ext <<_ACEOF
27442 /* confdefs.h.  */
27443 _ACEOF
27444 cat confdefs.h >>conftest.$ac_ext
27445 cat >>conftest.$ac_ext <<_ACEOF
27446 /* end confdefs.h.  */
27447 #include <signal.h>
27448
27449 int
27450 main ()
27451 {
27452 if (sizeof (sig_atomic_t))
27453        return 0;
27454   ;
27455   return 0;
27456 }
27457 _ACEOF
27458 rm -f conftest.$ac_objext
27459 if { (ac_try="$ac_compile"
27460 case "(($ac_try" in
27461   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27462   *) ac_try_echo=$ac_try;;
27463 esac
27464 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27465 $as_echo "$ac_try_echo") >&5
27466   (eval "$ac_compile") 2>conftest.er1
27467   ac_status=$?
27468   grep -v '^ *+' conftest.er1 >conftest.err
27469   rm -f conftest.er1
27470   cat conftest.err >&5
27471   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27472   (exit $ac_status); } && {
27473          test -z "$ac_c_werror_flag" ||
27474          test ! -s conftest.err
27475        } && test -s conftest.$ac_objext; then
27476   cat >conftest.$ac_ext <<_ACEOF
27477 /* confdefs.h.  */
27478 _ACEOF
27479 cat confdefs.h >>conftest.$ac_ext
27480 cat >>conftest.$ac_ext <<_ACEOF
27481 /* end confdefs.h.  */
27482 #include <signal.h>
27483
27484 int
27485 main ()
27486 {
27487 if (sizeof ((sig_atomic_t)))
27488           return 0;
27489   ;
27490   return 0;
27491 }
27492 _ACEOF
27493 rm -f conftest.$ac_objext
27494 if { (ac_try="$ac_compile"
27495 case "(($ac_try" in
27496   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27497   *) ac_try_echo=$ac_try;;
27498 esac
27499 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27500 $as_echo "$ac_try_echo") >&5
27501   (eval "$ac_compile") 2>conftest.er1
27502   ac_status=$?
27503   grep -v '^ *+' conftest.er1 >conftest.err
27504   rm -f conftest.er1
27505   cat conftest.err >&5
27506   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27507   (exit $ac_status); } && {
27508          test -z "$ac_c_werror_flag" ||
27509          test ! -s conftest.err
27510        } && test -s conftest.$ac_objext; then
27511   :
27512 else
27513   $as_echo "$as_me: failed program was:" >&5
27514 sed 's/^/| /' conftest.$ac_ext >&5
27515
27516         ac_cv_type_sig_atomic_t=yes
27517 fi
27518
27519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27520 else
27521   $as_echo "$as_me: failed program was:" >&5
27522 sed 's/^/| /' conftest.$ac_ext >&5
27523
27524
27525 fi
27526
27527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27528 fi
27529 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
27530 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
27531 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
27532
27533 cat >>confdefs.h <<_ACEOF
27534 #define HAVE_SIG_ATOMIC_T 1
27535 _ACEOF
27536
27537
27538 fi
27539
27540
27541
27542 if test "$PORTNAME" != "win32"
27543 then
27544 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
27545 $as_echo_n "checking for POSIX signal interface... " >&6; }
27546 if test "${pgac_cv_func_posix_signals+set}" = set; then
27547   $as_echo_n "(cached) " >&6
27548 else
27549   cat >conftest.$ac_ext <<_ACEOF
27550 /* confdefs.h.  */
27551 _ACEOF
27552 cat confdefs.h >>conftest.$ac_ext
27553 cat >>conftest.$ac_ext <<_ACEOF
27554 /* end confdefs.h.  */
27555 #include <signal.h>
27556
27557 int
27558 main ()
27559 {
27560 struct sigaction act, oact;
27561 sigemptyset(&act.sa_mask);
27562 act.sa_flags = SA_RESTART;
27563 sigaction(0, &act, &oact);
27564   ;
27565   return 0;
27566 }
27567 _ACEOF
27568 rm -f conftest.$ac_objext conftest$ac_exeext
27569 if { (ac_try="$ac_link"
27570 case "(($ac_try" in
27571   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27572   *) ac_try_echo=$ac_try;;
27573 esac
27574 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27575 $as_echo "$ac_try_echo") >&5
27576   (eval "$ac_link") 2>conftest.er1
27577   ac_status=$?
27578   grep -v '^ *+' conftest.er1 >conftest.err
27579   rm -f conftest.er1
27580   cat conftest.err >&5
27581   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27582   (exit $ac_status); } && {
27583          test -z "$ac_c_werror_flag" ||
27584          test ! -s conftest.err
27585        } && test -s conftest$ac_exeext && {
27586          test "$cross_compiling" = yes ||
27587          $as_test_x conftest$ac_exeext
27588        }; then
27589   pgac_cv_func_posix_signals=yes
27590 else
27591   $as_echo "$as_me: failed program was:" >&5
27592 sed 's/^/| /' conftest.$ac_ext >&5
27593
27594         pgac_cv_func_posix_signals=no
27595 fi
27596
27597 rm -rf conftest.dSYM
27598 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27599       conftest$ac_exeext conftest.$ac_ext
27600 fi
27601 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
27602 $as_echo "$pgac_cv_func_posix_signals" >&6; }
27603 if test x"$pgac_cv_func_posix_signals" = xyes ; then
27604
27605 cat >>confdefs.h <<\_ACEOF
27606 #define HAVE_POSIX_SIGNALS /**/
27607 _ACEOF
27608
27609 fi
27610 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
27611
27612 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
27613   { { $as_echo "$as_me:$LINENO: error:
27614 Thread-safety requires POSIX signals, which are not supported by this
27615 operating system;  use --disable-thread-safety to disable thread safety." >&5
27616 $as_echo "$as_me: error:
27617 Thread-safety requires POSIX signals, which are not supported by this
27618 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
27619    { (exit 1); exit 1; }; }
27620 fi
27621 fi
27622
27623 # SunOS doesn't handle negative byte comparisons properly with +/- return
27624 { $as_echo "$as_me:$LINENO: checking for working memcmp" >&5
27625 $as_echo_n "checking for working memcmp... " >&6; }
27626 if test "${ac_cv_func_memcmp_working+set}" = set; then
27627   $as_echo_n "(cached) " >&6
27628 else
27629   if test "$cross_compiling" = yes; then
27630   ac_cv_func_memcmp_working=no
27631 else
27632   cat >conftest.$ac_ext <<_ACEOF
27633 /* confdefs.h.  */
27634 _ACEOF
27635 cat confdefs.h >>conftest.$ac_ext
27636 cat >>conftest.$ac_ext <<_ACEOF
27637 /* end confdefs.h.  */
27638 $ac_includes_default
27639 int
27640 main ()
27641 {
27642
27643   /* Some versions of memcmp are not 8-bit clean.  */
27644   char c0 = '\100', c1 = '\200', c2 = '\201';
27645   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
27646     return 1;
27647
27648   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
27649      or more and with at least one buffer not starting on a 4-byte boundary.
27650      William Lewis provided this test program.   */
27651   {
27652     char foo[21];
27653     char bar[21];
27654     int i;
27655     for (i = 0; i < 4; i++)
27656       {
27657         char *a = foo + i;
27658         char *b = bar + i;
27659         strcpy (a, "--------01111111");
27660         strcpy (b, "--------10000000");
27661         if (memcmp (a, b, 16) >= 0)
27662           return 1;
27663       }
27664     return 0;
27665   }
27666
27667   ;
27668   return 0;
27669 }
27670 _ACEOF
27671 rm -f conftest$ac_exeext
27672 if { (ac_try="$ac_link"
27673 case "(($ac_try" in
27674   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27675   *) ac_try_echo=$ac_try;;
27676 esac
27677 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27678 $as_echo "$ac_try_echo") >&5
27679   (eval "$ac_link") 2>&5
27680   ac_status=$?
27681   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27682   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27683   { (case "(($ac_try" in
27684   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27685   *) ac_try_echo=$ac_try;;
27686 esac
27687 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27688 $as_echo "$ac_try_echo") >&5
27689   (eval "$ac_try") 2>&5
27690   ac_status=$?
27691   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27692   (exit $ac_status); }; }; then
27693   ac_cv_func_memcmp_working=yes
27694 else
27695   $as_echo "$as_me: program exited with status $ac_status" >&5
27696 $as_echo "$as_me: failed program was:" >&5
27697 sed 's/^/| /' conftest.$ac_ext >&5
27698
27699 ( exit $ac_status )
27700 ac_cv_func_memcmp_working=no
27701 fi
27702 rm -rf conftest.dSYM
27703 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27704 fi
27705
27706
27707 fi
27708 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
27709 $as_echo "$ac_cv_func_memcmp_working" >&6; }
27710 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
27711   *" memcmp.$ac_objext "* ) ;;
27712   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
27713  ;;
27714 esac
27715
27716
27717
27718
27719 # Select semaphore implementation type.
27720 if test "$PORTNAME" != "win32"; then
27721   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
27722
27723 cat >>confdefs.h <<\_ACEOF
27724 #define USE_NAMED_POSIX_SEMAPHORES 1
27725 _ACEOF
27726
27727     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
27728   else
27729     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
27730
27731 cat >>confdefs.h <<\_ACEOF
27732 #define USE_UNNAMED_POSIX_SEMAPHORES 1
27733 _ACEOF
27734
27735       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
27736     else
27737
27738 cat >>confdefs.h <<\_ACEOF
27739 #define USE_SYSV_SEMAPHORES 1
27740 _ACEOF
27741
27742       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
27743     fi
27744   fi
27745 else
27746
27747 cat >>confdefs.h <<\_ACEOF
27748 #define USE_WIN32_SEMAPHORES 1
27749 _ACEOF
27750
27751   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
27752 fi
27753
27754
27755 # Select shared-memory implementation type.
27756 if test "$PORTNAME" != "win32"; then
27757
27758 cat >>confdefs.h <<\_ACEOF
27759 #define USE_SYSV_SHARED_MEMORY 1
27760 _ACEOF
27761
27762   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
27763 else
27764
27765 cat >>confdefs.h <<\_ACEOF
27766 #define USE_WIN32_SHARED_MEMORY 1
27767 _ACEOF
27768
27769   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
27770 fi
27771
27772 # If not set in template file, set bytes to use libc memset()
27773 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
27774   MEMSET_LOOP_LIMIT=1024
27775 fi
27776
27777 cat >>confdefs.h <<_ACEOF
27778 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
27779 _ACEOF
27780
27781
27782
27783 if test "$enable_nls" = yes ; then
27784
27785   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
27786 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
27787 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27788   $as_echo_n "(cached) " >&6
27789 else
27790   ac_func_search_save_LIBS=$LIBS
27791 cat >conftest.$ac_ext <<_ACEOF
27792 /* confdefs.h.  */
27793 _ACEOF
27794 cat confdefs.h >>conftest.$ac_ext
27795 cat >>conftest.$ac_ext <<_ACEOF
27796 /* end confdefs.h.  */
27797
27798 /* Override any GCC internal prototype to avoid an error.
27799    Use char because int might match the return type of a GCC
27800    builtin and then its argument prototype would still apply.  */
27801 #ifdef __cplusplus
27802 extern "C"
27803 #endif
27804 char bind_textdomain_codeset ();
27805 int
27806 main ()
27807 {
27808 return bind_textdomain_codeset ();
27809   ;
27810   return 0;
27811 }
27812 _ACEOF
27813 for ac_lib in '' intl; do
27814   if test -z "$ac_lib"; then
27815     ac_res="none required"
27816   else
27817     ac_res=-l$ac_lib
27818     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
27819   fi
27820   rm -f conftest.$ac_objext conftest$ac_exeext
27821 if { (ac_try="$ac_link"
27822 case "(($ac_try" in
27823   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27824   *) ac_try_echo=$ac_try;;
27825 esac
27826 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27827 $as_echo "$ac_try_echo") >&5
27828   (eval "$ac_link") 2>conftest.er1
27829   ac_status=$?
27830   grep -v '^ *+' conftest.er1 >conftest.err
27831   rm -f conftest.er1
27832   cat conftest.err >&5
27833   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27834   (exit $ac_status); } && {
27835          test -z "$ac_c_werror_flag" ||
27836          test ! -s conftest.err
27837        } && test -s conftest$ac_exeext && {
27838          test "$cross_compiling" = yes ||
27839          $as_test_x conftest$ac_exeext
27840        }; then
27841   ac_cv_search_bind_textdomain_codeset=$ac_res
27842 else
27843   $as_echo "$as_me: failed program was:" >&5
27844 sed 's/^/| /' conftest.$ac_ext >&5
27845
27846
27847 fi
27848
27849 rm -rf conftest.dSYM
27850 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27851       conftest$ac_exeext
27852   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27853   break
27854 fi
27855 done
27856 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27857   :
27858 else
27859   ac_cv_search_bind_textdomain_codeset=no
27860 fi
27861 rm conftest.$ac_ext
27862 LIBS=$ac_func_search_save_LIBS
27863 fi
27864 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
27865 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
27866 ac_res=$ac_cv_search_bind_textdomain_codeset
27867 if test "$ac_res" != no; then
27868   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27869
27870 else
27871   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
27872 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
27873    { (exit 1); exit 1; }; }
27874 fi
27875
27876   if test "${ac_cv_header_libintl_h+set}" = set; then
27877   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
27878 $as_echo_n "checking for libintl.h... " >&6; }
27879 if test "${ac_cv_header_libintl_h+set}" = set; then
27880   $as_echo_n "(cached) " >&6
27881 fi
27882 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
27883 $as_echo "$ac_cv_header_libintl_h" >&6; }
27884 else
27885   # Is the header compilable?
27886 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
27887 $as_echo_n "checking libintl.h usability... " >&6; }
27888 cat >conftest.$ac_ext <<_ACEOF
27889 /* confdefs.h.  */
27890 _ACEOF
27891 cat confdefs.h >>conftest.$ac_ext
27892 cat >>conftest.$ac_ext <<_ACEOF
27893 /* end confdefs.h.  */
27894 $ac_includes_default
27895 #include <libintl.h>
27896 _ACEOF
27897 rm -f conftest.$ac_objext
27898 if { (ac_try="$ac_compile"
27899 case "(($ac_try" in
27900   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27901   *) ac_try_echo=$ac_try;;
27902 esac
27903 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27904 $as_echo "$ac_try_echo") >&5
27905   (eval "$ac_compile") 2>conftest.er1
27906   ac_status=$?
27907   grep -v '^ *+' conftest.er1 >conftest.err
27908   rm -f conftest.er1
27909   cat conftest.err >&5
27910   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27911   (exit $ac_status); } && {
27912          test -z "$ac_c_werror_flag" ||
27913          test ! -s conftest.err
27914        } && test -s conftest.$ac_objext; then
27915   ac_header_compiler=yes
27916 else
27917   $as_echo "$as_me: failed program was:" >&5
27918 sed 's/^/| /' conftest.$ac_ext >&5
27919
27920         ac_header_compiler=no
27921 fi
27922
27923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27924 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27925 $as_echo "$ac_header_compiler" >&6; }
27926
27927 # Is the header present?
27928 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
27929 $as_echo_n "checking libintl.h presence... " >&6; }
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 <libintl.h>
27937 _ACEOF
27938 if { (ac_try="$ac_cpp conftest.$ac_ext"
27939 case "(($ac_try" in
27940   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27941   *) ac_try_echo=$ac_try;;
27942 esac
27943 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27944 $as_echo "$ac_try_echo") >&5
27945   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
27946   ac_status=$?
27947   grep -v '^ *+' conftest.er1 >conftest.err
27948   rm -f conftest.er1
27949   cat conftest.err >&5
27950   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27951   (exit $ac_status); } >/dev/null && {
27952          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
27953          test ! -s conftest.err
27954        }; then
27955   ac_header_preproc=yes
27956 else
27957   $as_echo "$as_me: failed program was:" >&5
27958 sed 's/^/| /' conftest.$ac_ext >&5
27959
27960   ac_header_preproc=no
27961 fi
27962
27963 rm -f conftest.err conftest.$ac_ext
27964 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27965 $as_echo "$ac_header_preproc" >&6; }
27966
27967 # So?  What about this header?
27968 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27969   yes:no: )
27970     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
27971 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
27972     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
27973 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
27974     ac_header_preproc=yes
27975     ;;
27976   no:yes:* )
27977     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
27978 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
27979     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
27980 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
27981     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
27982 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
27983     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
27984 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
27985     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
27986 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
27987     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
27988 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
27989     ( cat <<\_ASBOX
27990 ## ---------------------------------------- ##
27991 ## Report this to pgsql-bugs@postgresql.org ##
27992 ## ---------------------------------------- ##
27993 _ASBOX
27994      ) | sed "s/^/$as_me: WARNING:     /" >&2
27995     ;;
27996 esac
27997 { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
27998 $as_echo_n "checking for libintl.h... " >&6; }
27999 if test "${ac_cv_header_libintl_h+set}" = set; then
28000   $as_echo_n "(cached) " >&6
28001 else
28002   ac_cv_header_libintl_h=$ac_header_preproc
28003 fi
28004 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28005 $as_echo "$ac_cv_header_libintl_h" >&6; }
28006
28007 fi
28008 if test "x$ac_cv_header_libintl_h" = x""yes; then
28009   :
28010 else
28011   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
28012 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
28013    { (exit 1); exit 1; }; }
28014 fi
28015
28016
28017   for ac_prog in msgfmt
28018 do
28019   # Extract the first word of "$ac_prog", so it can be a program name with args.
28020 set dummy $ac_prog; ac_word=$2
28021 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28022 $as_echo_n "checking for $ac_word... " >&6; }
28023 if test "${ac_cv_prog_MSGFMT+set}" = set; then
28024   $as_echo_n "(cached) " >&6
28025 else
28026   if test -n "$MSGFMT"; then
28027   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
28028 else
28029 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28030 for as_dir in $PATH
28031 do
28032   IFS=$as_save_IFS
28033   test -z "$as_dir" && as_dir=.
28034   for ac_exec_ext in '' $ac_executable_extensions; do
28035   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28036     ac_cv_prog_MSGFMT="$ac_prog"
28037     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28038     break 2
28039   fi
28040 done
28041 done
28042 IFS=$as_save_IFS
28043
28044 fi
28045 fi
28046 MSGFMT=$ac_cv_prog_MSGFMT
28047 if test -n "$MSGFMT"; then
28048   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
28049 $as_echo "$MSGFMT" >&6; }
28050 else
28051   { $as_echo "$as_me:$LINENO: result: no" >&5
28052 $as_echo "no" >&6; }
28053 fi
28054
28055
28056   test -n "$MSGFMT" && break
28057 done
28058
28059   if test -z "$MSGFMT"; then
28060     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
28061 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
28062    { (exit 1); exit 1; }; }
28063   fi
28064   for ac_prog in msgmerge
28065 do
28066   # Extract the first word of "$ac_prog", so it can be a program name with args.
28067 set dummy $ac_prog; ac_word=$2
28068 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28069 $as_echo_n "checking for $ac_word... " >&6; }
28070 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
28071   $as_echo_n "(cached) " >&6
28072 else
28073   if test -n "$MSGMERGE"; then
28074   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
28075 else
28076 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28077 for as_dir in $PATH
28078 do
28079   IFS=$as_save_IFS
28080   test -z "$as_dir" && as_dir=.
28081   for ac_exec_ext in '' $ac_executable_extensions; do
28082   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28083     ac_cv_prog_MSGMERGE="$ac_prog"
28084     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28085     break 2
28086   fi
28087 done
28088 done
28089 IFS=$as_save_IFS
28090
28091 fi
28092 fi
28093 MSGMERGE=$ac_cv_prog_MSGMERGE
28094 if test -n "$MSGMERGE"; then
28095   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
28096 $as_echo "$MSGMERGE" >&6; }
28097 else
28098   { $as_echo "$as_me:$LINENO: result: no" >&5
28099 $as_echo "no" >&6; }
28100 fi
28101
28102
28103   test -n "$MSGMERGE" && break
28104 done
28105
28106   for ac_prog in xgettext
28107 do
28108   # Extract the first word of "$ac_prog", so it can be a program name with args.
28109 set dummy $ac_prog; ac_word=$2
28110 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28111 $as_echo_n "checking for $ac_word... " >&6; }
28112 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
28113   $as_echo_n "(cached) " >&6
28114 else
28115   if test -n "$XGETTEXT"; then
28116   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
28117 else
28118 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28119 for as_dir in $PATH
28120 do
28121   IFS=$as_save_IFS
28122   test -z "$as_dir" && as_dir=.
28123   for ac_exec_ext in '' $ac_executable_extensions; do
28124   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28125     ac_cv_prog_XGETTEXT="$ac_prog"
28126     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28127     break 2
28128   fi
28129 done
28130 done
28131 IFS=$as_save_IFS
28132
28133 fi
28134 fi
28135 XGETTEXT=$ac_cv_prog_XGETTEXT
28136 if test -n "$XGETTEXT"; then
28137   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
28138 $as_echo "$XGETTEXT" >&6; }
28139 else
28140   { $as_echo "$as_me:$LINENO: result: no" >&5
28141 $as_echo "no" >&6; }
28142 fi
28143
28144
28145   test -n "$XGETTEXT" && break
28146 done
28147
28148
28149 fi
28150
28151 # Check for Tcl configuration script tclConfig.sh
28152 if test "$with_tcl" = yes; then
28153     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
28154 do
28155   # Extract the first word of "$ac_prog", so it can be a program name with args.
28156 set dummy $ac_prog; ac_word=$2
28157 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28158 $as_echo_n "checking for $ac_word... " >&6; }
28159 if test "${ac_cv_path_TCLSH+set}" = set; then
28160   $as_echo_n "(cached) " >&6
28161 else
28162   case $TCLSH in
28163   [\\/]* | ?:[\\/]*)
28164   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
28165   ;;
28166   *)
28167   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28168 for as_dir in $PATH
28169 do
28170   IFS=$as_save_IFS
28171   test -z "$as_dir" && as_dir=.
28172   for ac_exec_ext in '' $ac_executable_extensions; do
28173   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28174     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
28175     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28176     break 2
28177   fi
28178 done
28179 done
28180 IFS=$as_save_IFS
28181
28182   ;;
28183 esac
28184 fi
28185 TCLSH=$ac_cv_path_TCLSH
28186 if test -n "$TCLSH"; then
28187   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
28188 $as_echo "$TCLSH" >&6; }
28189 else
28190   { $as_echo "$as_me:$LINENO: result: no" >&5
28191 $as_echo "no" >&6; }
28192 fi
28193
28194
28195   test -n "$TCLSH" && break
28196 done
28197
28198 if test x"$TCLSH" = x""; then
28199   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
28200 $as_echo "$as_me: error: Tcl shell not found" >&2;}
28201    { (exit 1); exit 1; }; }
28202 fi
28203
28204 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
28205 $as_echo_n "checking for tclConfig.sh... " >&6; }
28206 # Let user override test
28207 if test -z "$TCL_CONFIG_SH"; then
28208     pgac_test_dirs="$with_tclconfig"
28209
28210     set X $pgac_test_dirs; shift
28211     if test $# -eq 0; then
28212         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
28213 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
28214    { (exit 1); exit 1; }; }
28215         set X `echo 'puts $auto_path' | $TCLSH`; shift
28216     fi
28217
28218     for pgac_dir do
28219         if test -r "$pgac_dir/tclConfig.sh"; then
28220             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
28221             break
28222         fi
28223     done
28224 fi
28225
28226 if test -z "$TCL_CONFIG_SH"; then
28227     { $as_echo "$as_me:$LINENO: result: no" >&5
28228 $as_echo "no" >&6; }
28229     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
28230 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
28231    { (exit 1); exit 1; }; }
28232 else
28233     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
28234 $as_echo "$TCL_CONFIG_SH" >&6; }
28235 fi
28236
28237
28238
28239     . "$TCL_CONFIG_SH"
28240 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
28241 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
28242 eval TCL_LIBS=\"$TCL_LIBS\"
28243 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
28244 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
28245
28246         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
28247     ac_save_CPPFLAGS=$CPPFLAGS
28248     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
28249     if test "${ac_cv_header_tcl_h+set}" = set; then
28250   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28251 $as_echo_n "checking for tcl.h... " >&6; }
28252 if test "${ac_cv_header_tcl_h+set}" = set; then
28253   $as_echo_n "(cached) " >&6
28254 fi
28255 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28256 $as_echo "$ac_cv_header_tcl_h" >&6; }
28257 else
28258   # Is the header compilable?
28259 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
28260 $as_echo_n "checking tcl.h usability... " >&6; }
28261 cat >conftest.$ac_ext <<_ACEOF
28262 /* confdefs.h.  */
28263 _ACEOF
28264 cat confdefs.h >>conftest.$ac_ext
28265 cat >>conftest.$ac_ext <<_ACEOF
28266 /* end confdefs.h.  */
28267 $ac_includes_default
28268 #include <tcl.h>
28269 _ACEOF
28270 rm -f conftest.$ac_objext
28271 if { (ac_try="$ac_compile"
28272 case "(($ac_try" in
28273   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28274   *) ac_try_echo=$ac_try;;
28275 esac
28276 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28277 $as_echo "$ac_try_echo") >&5
28278   (eval "$ac_compile") 2>conftest.er1
28279   ac_status=$?
28280   grep -v '^ *+' conftest.er1 >conftest.err
28281   rm -f conftest.er1
28282   cat conftest.err >&5
28283   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28284   (exit $ac_status); } && {
28285          test -z "$ac_c_werror_flag" ||
28286          test ! -s conftest.err
28287        } && test -s conftest.$ac_objext; then
28288   ac_header_compiler=yes
28289 else
28290   $as_echo "$as_me: failed program was:" >&5
28291 sed 's/^/| /' conftest.$ac_ext >&5
28292
28293         ac_header_compiler=no
28294 fi
28295
28296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28297 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28298 $as_echo "$ac_header_compiler" >&6; }
28299
28300 # Is the header present?
28301 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
28302 $as_echo_n "checking tcl.h presence... " >&6; }
28303 cat >conftest.$ac_ext <<_ACEOF
28304 /* confdefs.h.  */
28305 _ACEOF
28306 cat confdefs.h >>conftest.$ac_ext
28307 cat >>conftest.$ac_ext <<_ACEOF
28308 /* end confdefs.h.  */
28309 #include <tcl.h>
28310 _ACEOF
28311 if { (ac_try="$ac_cpp conftest.$ac_ext"
28312 case "(($ac_try" in
28313   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28314   *) ac_try_echo=$ac_try;;
28315 esac
28316 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28317 $as_echo "$ac_try_echo") >&5
28318   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28319   ac_status=$?
28320   grep -v '^ *+' conftest.er1 >conftest.err
28321   rm -f conftest.er1
28322   cat conftest.err >&5
28323   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28324   (exit $ac_status); } >/dev/null && {
28325          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28326          test ! -s conftest.err
28327        }; then
28328   ac_header_preproc=yes
28329 else
28330   $as_echo "$as_me: failed program was:" >&5
28331 sed 's/^/| /' conftest.$ac_ext >&5
28332
28333   ac_header_preproc=no
28334 fi
28335
28336 rm -f conftest.err conftest.$ac_ext
28337 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28338 $as_echo "$ac_header_preproc" >&6; }
28339
28340 # So?  What about this header?
28341 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28342   yes:no: )
28343     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28344 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28345     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
28346 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
28347     ac_header_preproc=yes
28348     ;;
28349   no:yes:* )
28350     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
28351 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
28352     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
28353 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
28354     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
28355 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
28356     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
28357 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28358     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
28359 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
28360     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
28361 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
28362     ( cat <<\_ASBOX
28363 ## ---------------------------------------- ##
28364 ## Report this to pgsql-bugs@postgresql.org ##
28365 ## ---------------------------------------- ##
28366 _ASBOX
28367      ) | sed "s/^/$as_me: WARNING:     /" >&2
28368     ;;
28369 esac
28370 { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28371 $as_echo_n "checking for tcl.h... " >&6; }
28372 if test "${ac_cv_header_tcl_h+set}" = set; then
28373   $as_echo_n "(cached) " >&6
28374 else
28375   ac_cv_header_tcl_h=$ac_header_preproc
28376 fi
28377 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28378 $as_echo "$ac_cv_header_tcl_h" >&6; }
28379
28380 fi
28381 if test "x$ac_cv_header_tcl_h" = x""yes; then
28382   :
28383 else
28384   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
28385 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
28386    { (exit 1); exit 1; }; }
28387 fi
28388
28389
28390     CPPFLAGS=$ac_save_CPPFLAGS
28391 fi
28392
28393 #
28394 # Check for DocBook and tools
28395 #
28396 for ac_prog in onsgmls nsgmls
28397 do
28398   # Extract the first word of "$ac_prog", so it can be a program name with args.
28399 set dummy $ac_prog; ac_word=$2
28400 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28401 $as_echo_n "checking for $ac_word... " >&6; }
28402 if test "${ac_cv_prog_NSGMLS+set}" = set; then
28403   $as_echo_n "(cached) " >&6
28404 else
28405   if test -n "$NSGMLS"; then
28406   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
28407 else
28408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28409 for as_dir in $PATH
28410 do
28411   IFS=$as_save_IFS
28412   test -z "$as_dir" && as_dir=.
28413   for ac_exec_ext in '' $ac_executable_extensions; do
28414   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28415     ac_cv_prog_NSGMLS="$ac_prog"
28416     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28417     break 2
28418   fi
28419 done
28420 done
28421 IFS=$as_save_IFS
28422
28423 fi
28424 fi
28425 NSGMLS=$ac_cv_prog_NSGMLS
28426 if test -n "$NSGMLS"; then
28427   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
28428 $as_echo "$NSGMLS" >&6; }
28429 else
28430   { $as_echo "$as_me:$LINENO: result: no" >&5
28431 $as_echo "no" >&6; }
28432 fi
28433
28434
28435   test -n "$NSGMLS" && break
28436 done
28437
28438 for ac_prog in openjade jade
28439 do
28440   # Extract the first word of "$ac_prog", so it can be a program name with args.
28441 set dummy $ac_prog; ac_word=$2
28442 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28443 $as_echo_n "checking for $ac_word... " >&6; }
28444 if test "${ac_cv_prog_JADE+set}" = set; then
28445   $as_echo_n "(cached) " >&6
28446 else
28447   if test -n "$JADE"; then
28448   ac_cv_prog_JADE="$JADE" # Let the user override the test.
28449 else
28450 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28451 for as_dir in $PATH
28452 do
28453   IFS=$as_save_IFS
28454   test -z "$as_dir" && as_dir=.
28455   for ac_exec_ext in '' $ac_executable_extensions; do
28456   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28457     ac_cv_prog_JADE="$ac_prog"
28458     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28459     break 2
28460   fi
28461 done
28462 done
28463 IFS=$as_save_IFS
28464
28465 fi
28466 fi
28467 JADE=$ac_cv_prog_JADE
28468 if test -n "$JADE"; then
28469   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
28470 $as_echo "$JADE" >&6; }
28471 else
28472   { $as_echo "$as_me:$LINENO: result: no" >&5
28473 $as_echo "no" >&6; }
28474 fi
28475
28476
28477   test -n "$JADE" && break
28478 done
28479
28480
28481 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
28482 $as_echo_n "checking for DocBook V4.2... " >&6; }
28483 if test "${pgac_cv_check_docbook+set}" = set; then
28484   $as_echo_n "(cached) " >&6
28485 else
28486   cat >conftest.sgml <<EOF
28487 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
28488 <book>
28489  <title>test</title>
28490  <chapter>
28491   <title>random</title>
28492    <sect1>
28493     <title>testsect</title>
28494     <para>text</para>
28495   </sect1>
28496  </chapter>
28497 </book>
28498 EOF
28499
28500 pgac_cv_check_docbook=no
28501
28502 if test -n "$NSGMLS"; then
28503   $NSGMLS -s conftest.sgml 1>&5 2>&1
28504   if test $? -eq 0; then
28505     pgac_cv_check_docbook=yes
28506   fi
28507 fi
28508 rm -f conftest.sgml
28509 fi
28510 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
28511 $as_echo "$pgac_cv_check_docbook" >&6; }
28512
28513 have_docbook=$pgac_cv_check_docbook
28514
28515
28516 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
28517 $as_echo_n "checking for DocBook stylesheets... " >&6; }
28518 if test "${pgac_cv_path_stylesheets+set}" = set; then
28519   $as_echo_n "(cached) " >&6
28520 else
28521   if test -n "$DOCBOOKSTYLE"; then
28522   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
28523 else
28524   for pgac_prefix in /usr /usr/local /opt /sw; do
28525     for pgac_infix in share lib; do
28526       for pgac_postfix in \
28527         sgml/stylesheets/nwalsh-modular \
28528         sgml/stylesheets/docbook \
28529         sgml/stylesheets/dsssl/docbook \
28530         sgml/docbook-dsssl \
28531         sgml/docbook/dsssl/modular \
28532         sgml/docbook/stylesheet/dsssl/modular \
28533         sgml/docbook/dsssl-stylesheets \
28534         sgml/dsssl/docbook-dsssl-nwalsh
28535       do
28536         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
28537         if test -r "$pgac_candidate/html/docbook.dsl" \
28538            && test -r "$pgac_candidate/print/docbook.dsl"
28539         then
28540           pgac_cv_path_stylesheets=$pgac_candidate
28541           break 3
28542         fi
28543       done
28544     done
28545   done
28546 fi
28547 fi
28548
28549 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
28550
28551 if test -n "$DOCBOOKSTYLE"; then
28552   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
28553 $as_echo "$DOCBOOKSTYLE" >&6; }
28554 else
28555   { $as_echo "$as_me:$LINENO: result: no" >&5
28556 $as_echo "no" >&6; }
28557 fi
28558 if test -n "$DOCBOOKSTYLE"; then
28559   for ac_prog in collateindex.pl
28560 do
28561   # Extract the first word of "$ac_prog", so it can be a program name with args.
28562 set dummy $ac_prog; ac_word=$2
28563 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28564 $as_echo_n "checking for $ac_word... " >&6; }
28565 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28566   $as_echo_n "(cached) " >&6
28567 else
28568   case $COLLATEINDEX in
28569   [\\/]* | ?:[\\/]*)
28570   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28571   ;;
28572   *)
28573   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28574 for as_dir in $DOCBOOKSTYLE/bin $PATH
28575 do
28576   IFS=$as_save_IFS
28577   test -z "$as_dir" && as_dir=.
28578   for ac_exec_ext in '' $ac_executable_extensions; do
28579   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28580     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28581     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28582     break 2
28583   fi
28584 done
28585 done
28586 IFS=$as_save_IFS
28587
28588   ;;
28589 esac
28590 fi
28591 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28592 if test -n "$COLLATEINDEX"; then
28593   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28594 $as_echo "$COLLATEINDEX" >&6; }
28595 else
28596   { $as_echo "$as_me:$LINENO: result: no" >&5
28597 $as_echo "no" >&6; }
28598 fi
28599
28600
28601   test -n "$COLLATEINDEX" && break
28602 done
28603
28604 else
28605   for ac_prog in collateindex.pl
28606 do
28607   # Extract the first word of "$ac_prog", so it can be a program name with args.
28608 set dummy $ac_prog; ac_word=$2
28609 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28610 $as_echo_n "checking for $ac_word... " >&6; }
28611 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28612   $as_echo_n "(cached) " >&6
28613 else
28614   case $COLLATEINDEX in
28615   [\\/]* | ?:[\\/]*)
28616   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28617   ;;
28618   *)
28619   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28620 for as_dir in $PATH
28621 do
28622   IFS=$as_save_IFS
28623   test -z "$as_dir" && as_dir=.
28624   for ac_exec_ext in '' $ac_executable_extensions; do
28625   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28626     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28627     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28628     break 2
28629   fi
28630 done
28631 done
28632 IFS=$as_save_IFS
28633
28634   ;;
28635 esac
28636 fi
28637 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28638 if test -n "$COLLATEINDEX"; then
28639   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28640 $as_echo "$COLLATEINDEX" >&6; }
28641 else
28642   { $as_echo "$as_me:$LINENO: result: no" >&5
28643 $as_echo "no" >&6; }
28644 fi
28645
28646
28647   test -n "$COLLATEINDEX" && break
28648 done
28649
28650 fi
28651 for ac_prog in xsltproc
28652 do
28653   # Extract the first word of "$ac_prog", so it can be a program name with args.
28654 set dummy $ac_prog; ac_word=$2
28655 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28656 $as_echo_n "checking for $ac_word... " >&6; }
28657 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
28658   $as_echo_n "(cached) " >&6
28659 else
28660   if test -n "$XSLTPROC"; then
28661   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
28662 else
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_prog_XSLTPROC="$ac_prog"
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 fi
28679 fi
28680 XSLTPROC=$ac_cv_prog_XSLTPROC
28681 if test -n "$XSLTPROC"; then
28682   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
28683 $as_echo "$XSLTPROC" >&6; }
28684 else
28685   { $as_echo "$as_me:$LINENO: result: no" >&5
28686 $as_echo "no" >&6; }
28687 fi
28688
28689
28690   test -n "$XSLTPROC" && break
28691 done
28692
28693 for ac_prog in osx sgml2xml sx
28694 do
28695   # Extract the first word of "$ac_prog", so it can be a program name with args.
28696 set dummy $ac_prog; ac_word=$2
28697 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28698 $as_echo_n "checking for $ac_word... " >&6; }
28699 if test "${ac_cv_prog_OSX+set}" = set; then
28700   $as_echo_n "(cached) " >&6
28701 else
28702   if test -n "$OSX"; then
28703   ac_cv_prog_OSX="$OSX" # Let the user override the test.
28704 else
28705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28706 for as_dir in $PATH
28707 do
28708   IFS=$as_save_IFS
28709   test -z "$as_dir" && as_dir=.
28710   for ac_exec_ext in '' $ac_executable_extensions; do
28711   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28712     ac_cv_prog_OSX="$ac_prog"
28713     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28714     break 2
28715   fi
28716 done
28717 done
28718 IFS=$as_save_IFS
28719
28720 fi
28721 fi
28722 OSX=$ac_cv_prog_OSX
28723 if test -n "$OSX"; then
28724   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
28725 $as_echo "$OSX" >&6; }
28726 else
28727   { $as_echo "$as_me:$LINENO: result: no" >&5
28728 $as_echo "no" >&6; }
28729 fi
28730
28731
28732   test -n "$OSX" && break
28733 done
28734
28735
28736 # Thread testing
28737
28738 # We have to run the thread test near the end so we have all our symbols
28739 # defined.  Cross compiling throws a warning.
28740 #
28741 if test "$enable_thread_safety" = yes; then
28742 if test "$PORTNAME" != "win32"
28743 then
28744 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
28745 $as_echo_n "checking thread safety of required library functions... " >&6; }
28746
28747 _CFLAGS="$CFLAGS"
28748 _LIBS="$LIBS"
28749 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
28750 LIBS="$LIBS $PTHREAD_LIBS"
28751 if test "$cross_compiling" = yes; then
28752   { $as_echo "$as_me:$LINENO: result: maybe" >&5
28753 $as_echo "maybe" >&6; }
28754   { $as_echo "$as_me:$LINENO: WARNING:
28755 *** Skipping thread test program because of cross-compile build.
28756 *** Run the program in src/test/thread on the target machine.
28757 " >&5
28758 $as_echo "$as_me: WARNING:
28759 *** Skipping thread test program because of cross-compile build.
28760 *** Run the program in src/test/thread on the target machine.
28761 " >&2;}
28762 else
28763   cat >conftest.$ac_ext <<_ACEOF
28764 /* confdefs.h.  */
28765 _ACEOF
28766 cat confdefs.h >>conftest.$ac_ext
28767 cat >>conftest.$ac_ext <<_ACEOF
28768 /* end confdefs.h.  */
28769 #include "$srcdir/src/test/thread/thread_test.c"
28770 _ACEOF
28771 rm -f conftest$ac_exeext
28772 if { (ac_try="$ac_link"
28773 case "(($ac_try" in
28774   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28775   *) ac_try_echo=$ac_try;;
28776 esac
28777 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28778 $as_echo "$ac_try_echo") >&5
28779   (eval "$ac_link") 2>&5
28780   ac_status=$?
28781   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28782   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28783   { (case "(($ac_try" in
28784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28785   *) ac_try_echo=$ac_try;;
28786 esac
28787 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28788 $as_echo "$ac_try_echo") >&5
28789   (eval "$ac_try") 2>&5
28790   ac_status=$?
28791   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28792   (exit $ac_status); }; }; then
28793   { $as_echo "$as_me:$LINENO: result: yes" >&5
28794 $as_echo "yes" >&6; }
28795 else
28796   $as_echo "$as_me: program exited with status $ac_status" >&5
28797 $as_echo "$as_me: failed program was:" >&5
28798 sed 's/^/| /' conftest.$ac_ext >&5
28799
28800 ( exit $ac_status )
28801 { $as_echo "$as_me:$LINENO: result: no" >&5
28802 $as_echo "no" >&6; }
28803   { { $as_echo "$as_me:$LINENO: error: thread test program failed
28804 This platform is not thread-safe.  Check the file 'config.log' or compile
28805 and run src/test/thread/thread_test for the exact reason.
28806 Use --disable-thread-safety to disable thread safety." >&5
28807 $as_echo "$as_me: error: thread test program failed
28808 This platform is not thread-safe.  Check the file 'config.log' or compile
28809 and run src/test/thread/thread_test for the exact reason.
28810 Use --disable-thread-safety to disable thread safety." >&2;}
28811    { (exit 1); exit 1; }; }
28812 fi
28813 rm -rf conftest.dSYM
28814 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28815 fi
28816
28817
28818 CFLAGS="$_CFLAGS"
28819 LIBS="$_LIBS"
28820 else
28821 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
28822 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
28823 fi
28824 fi
28825
28826 # If compiler will take -Wl,--as-needed (or various platform-specific
28827 # spellings thereof) then add that to LDFLAGS.  This is much easier than
28828 # trying to filter LIBS to the minimum for each executable.
28829 # (Note that shared library links won't use this switch, though.)
28830 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
28831 # libreadline; therefore we postpone testing it until we know what library
28832 # dependencies readline has.  The test code will try to link with $LIBS.
28833 if test "$with_readline" = yes; then
28834   link_test_func=readline
28835 else
28836   link_test_func=exit
28837 fi
28838
28839 if test "$PORTNAME" = "darwin"; then
28840   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,-dead_strip_dylibs" >&5
28841 $as_echo_n "checking if $CC supports -Wl,-dead_strip_dylibs... " >&6; }
28842 pgac_save_LDFLAGS=$LDFLAGS
28843 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
28844 if test "$cross_compiling" = yes; then
28845   LDFLAGS="$pgac_save_LDFLAGS"
28846                { $as_echo "$as_me:$LINENO: result: assuming no" >&5
28847 $as_echo "assuming no" >&6; }
28848 else
28849   cat >conftest.$ac_ext <<_ACEOF
28850 /* confdefs.h.  */
28851 _ACEOF
28852 cat confdefs.h >>conftest.$ac_ext
28853 cat >>conftest.$ac_ext <<_ACEOF
28854 /* end confdefs.h.  */
28855 extern void $link_test_func (); void (*fptr) () = $link_test_func;
28856 int
28857 main ()
28858 {
28859
28860   ;
28861   return 0;
28862 }
28863 _ACEOF
28864 rm -f conftest$ac_exeext
28865 if { (ac_try="$ac_link"
28866 case "(($ac_try" in
28867   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28868   *) ac_try_echo=$ac_try;;
28869 esac
28870 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28871 $as_echo "$ac_try_echo") >&5
28872   (eval "$ac_link") 2>&5
28873   ac_status=$?
28874   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28875   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28876   { (case "(($ac_try" in
28877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28878   *) ac_try_echo=$ac_try;;
28879 esac
28880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28881 $as_echo "$ac_try_echo") >&5
28882   (eval "$ac_try") 2>&5
28883   ac_status=$?
28884   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28885   (exit $ac_status); }; }; then
28886   { $as_echo "$as_me:$LINENO: result: yes" >&5
28887 $as_echo "yes" >&6; }
28888 else
28889   $as_echo "$as_me: program exited with status $ac_status" >&5
28890 $as_echo "$as_me: failed program was:" >&5
28891 sed 's/^/| /' conftest.$ac_ext >&5
28892
28893 ( exit $ac_status )
28894 LDFLAGS="$pgac_save_LDFLAGS"
28895                { $as_echo "$as_me:$LINENO: result: no" >&5
28896 $as_echo "no" >&6; }
28897 fi
28898 rm -rf conftest.dSYM
28899 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28900 fi
28901
28902
28903
28904 elif test "$PORTNAME" = "openbsd"; then
28905   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,-Bdynamic" >&5
28906 $as_echo_n "checking if $CC supports -Wl,-Bdynamic... " >&6; }
28907 pgac_save_LDFLAGS=$LDFLAGS
28908 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
28909 if test "$cross_compiling" = yes; then
28910   LDFLAGS="$pgac_save_LDFLAGS"
28911                { $as_echo "$as_me:$LINENO: result: assuming no" >&5
28912 $as_echo "assuming no" >&6; }
28913 else
28914   cat >conftest.$ac_ext <<_ACEOF
28915 /* confdefs.h.  */
28916 _ACEOF
28917 cat confdefs.h >>conftest.$ac_ext
28918 cat >>conftest.$ac_ext <<_ACEOF
28919 /* end confdefs.h.  */
28920 extern void $link_test_func (); void (*fptr) () = $link_test_func;
28921 int
28922 main ()
28923 {
28924
28925   ;
28926   return 0;
28927 }
28928 _ACEOF
28929 rm -f conftest$ac_exeext
28930 if { (ac_try="$ac_link"
28931 case "(($ac_try" in
28932   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28933   *) ac_try_echo=$ac_try;;
28934 esac
28935 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28936 $as_echo "$ac_try_echo") >&5
28937   (eval "$ac_link") 2>&5
28938   ac_status=$?
28939   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28940   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28941   { (case "(($ac_try" in
28942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28943   *) ac_try_echo=$ac_try;;
28944 esac
28945 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28946 $as_echo "$ac_try_echo") >&5
28947   (eval "$ac_try") 2>&5
28948   ac_status=$?
28949   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28950   (exit $ac_status); }; }; then
28951   { $as_echo "$as_me:$LINENO: result: yes" >&5
28952 $as_echo "yes" >&6; }
28953 else
28954   $as_echo "$as_me: program exited with status $ac_status" >&5
28955 $as_echo "$as_me: failed program was:" >&5
28956 sed 's/^/| /' conftest.$ac_ext >&5
28957
28958 ( exit $ac_status )
28959 LDFLAGS="$pgac_save_LDFLAGS"
28960                { $as_echo "$as_me:$LINENO: result: no" >&5
28961 $as_echo "no" >&6; }
28962 fi
28963 rm -rf conftest.dSYM
28964 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28965 fi
28966
28967
28968
28969 else
28970   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,--as-needed" >&5
28971 $as_echo_n "checking if $CC supports -Wl,--as-needed... " >&6; }
28972 pgac_save_LDFLAGS=$LDFLAGS
28973 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
28974 if test "$cross_compiling" = yes; then
28975   LDFLAGS="$pgac_save_LDFLAGS"
28976                { $as_echo "$as_me:$LINENO: result: assuming no" >&5
28977 $as_echo "assuming no" >&6; }
28978 else
28979   cat >conftest.$ac_ext <<_ACEOF
28980 /* confdefs.h.  */
28981 _ACEOF
28982 cat confdefs.h >>conftest.$ac_ext
28983 cat >>conftest.$ac_ext <<_ACEOF
28984 /* end confdefs.h.  */
28985 extern void $link_test_func (); void (*fptr) () = $link_test_func;
28986 int
28987 main ()
28988 {
28989
28990   ;
28991   return 0;
28992 }
28993 _ACEOF
28994 rm -f conftest$ac_exeext
28995 if { (ac_try="$ac_link"
28996 case "(($ac_try" in
28997   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28998   *) ac_try_echo=$ac_try;;
28999 esac
29000 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29001 $as_echo "$ac_try_echo") >&5
29002   (eval "$ac_link") 2>&5
29003   ac_status=$?
29004   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29005   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29006   { (case "(($ac_try" in
29007   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29008   *) ac_try_echo=$ac_try;;
29009 esac
29010 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29011 $as_echo "$ac_try_echo") >&5
29012   (eval "$ac_try") 2>&5
29013   ac_status=$?
29014   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29015   (exit $ac_status); }; }; then
29016   { $as_echo "$as_me:$LINENO: result: yes" >&5
29017 $as_echo "yes" >&6; }
29018 else
29019   $as_echo "$as_me: program exited with status $ac_status" >&5
29020 $as_echo "$as_me: failed program was:" >&5
29021 sed 's/^/| /' conftest.$ac_ext >&5
29022
29023 ( exit $ac_status )
29024 LDFLAGS="$pgac_save_LDFLAGS"
29025                { $as_echo "$as_me:$LINENO: result: no" >&5
29026 $as_echo "no" >&6; }
29027 fi
29028 rm -rf conftest.dSYM
29029 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29030 fi
29031
29032
29033
29034 fi
29035
29036
29037 # Begin output steps
29038
29039 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
29040 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
29041 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
29042 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
29043 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
29044 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
29045
29046 # Create compiler version string
29047 if test x"$GCC" = x"yes" ; then
29048   cc_string="GCC `${CC} --version | sed q`"
29049 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
29050   cc_string=`${CC} -V 2>&1 | sed q`
29051 else
29052   cc_string=$CC
29053 fi
29054
29055
29056 cat >>confdefs.h <<_ACEOF
29057 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
29058 _ACEOF
29059
29060
29061 # Supply a numeric version string for use by 3rd party add-ons
29062 # awk -F is a regex on some platforms, and not on others, so make "." a tab
29063 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
29064 tr '.' '        ' |
29065 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
29066
29067 cat >>confdefs.h <<_ACEOF
29068 #define PG_VERSION_NUM $PG_VERSION_NUM
29069 _ACEOF
29070
29071
29072
29073 # prepare build tree if outside source tree
29074 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
29075 # Note 2: /bin/pwd might be better than shell's built-in at getting
29076 #         a symlink-free name.
29077 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
29078   vpath_build=no
29079 else
29080   vpath_build=yes
29081   if test "$no_create" != yes; then
29082     $as_echo_n "preparing build tree... " >&6
29083     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
29084     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
29085       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
29086 $as_echo "$as_me: error: failed" >&2;}
29087    { (exit 1); exit 1; }; }
29088     { $as_echo "$as_me:$LINENO: result: done" >&5
29089 $as_echo "done" >&6; }
29090   fi
29091 fi
29092
29093
29094
29095 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
29096
29097
29098 ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
29099
29100
29101 if test "$PORTNAME" = "win32"; then
29102 ac_config_commands="$ac_config_commands check_win32_symlinks"
29103
29104 fi
29105
29106 ac_config_headers="$ac_config_headers src/include/pg_config.h"
29107
29108
29109 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
29110
29111
29112 cat >confcache <<\_ACEOF
29113 # This file is a shell script that caches the results of configure
29114 # tests run on this system so they can be shared between configure
29115 # scripts and configure runs, see configure's option --config-cache.
29116 # It is not useful on other systems.  If it contains results you don't
29117 # want to keep, you may remove or edit it.
29118 #
29119 # config.status only pays attention to the cache file if you give it
29120 # the --recheck option to rerun configure.
29121 #
29122 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29123 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29124 # following values.
29125
29126 _ACEOF
29127
29128 # The following way of writing the cache mishandles newlines in values,
29129 # but we know of no workaround that is simple, portable, and efficient.
29130 # So, we kill variables containing newlines.
29131 # Ultrix sh set writes to stderr and can't be redirected directly,
29132 # and sets the high bit in the cache file unless we assign to the vars.
29133 (
29134   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29135     eval ac_val=\$$ac_var
29136     case $ac_val in #(
29137     *${as_nl}*)
29138       case $ac_var in #(
29139       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
29140 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29141       esac
29142       case $ac_var in #(
29143       _ | IFS | as_nl) ;; #(
29144       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29145       *) $as_unset $ac_var ;;
29146       esac ;;
29147     esac
29148   done
29149
29150   (set) 2>&1 |
29151     case $as_nl`(ac_space=' '; set) 2>&1` in #(
29152     *${as_nl}ac_space=\ *)
29153       # `set' does not quote correctly, so add quotes (double-quote
29154       # substitution turns \\\\ into \\, and sed turns \\ into \).
29155       sed -n \
29156         "s/'/'\\\\''/g;
29157           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29158       ;; #(
29159     *)
29160       # `set' quotes correctly as required by POSIX, so do not add quotes.
29161       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29162       ;;
29163     esac |
29164     sort
29165 ) |
29166   sed '
29167      /^ac_cv_env_/b end
29168      t clear
29169      :clear
29170      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29171      t end
29172      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29173      :end' >>confcache
29174 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29175   if test -w "$cache_file"; then
29176     test "x$cache_file" != "x/dev/null" &&
29177       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
29178 $as_echo "$as_me: updating cache $cache_file" >&6;}
29179     cat confcache >$cache_file
29180   else
29181     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
29182 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29183   fi
29184 fi
29185 rm -f confcache
29186
29187 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29188 # Let make expand exec_prefix.
29189 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29190
29191 DEFS=-DHAVE_CONFIG_H
29192
29193 ac_libobjs=
29194 ac_ltlibobjs=
29195 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29196   # 1. Remove the extension, and $U if already installed.
29197   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29198   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29199   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
29200   #    will be set to the directory where LIBOBJS objects are built.
29201   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29202   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
29203 done
29204 LIBOBJS=$ac_libobjs
29205
29206 LTLIBOBJS=$ac_ltlibobjs
29207
29208
29209
29210
29211 : ${CONFIG_STATUS=./config.status}
29212 ac_write_fail=0
29213 ac_clean_files_save=$ac_clean_files
29214 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29215 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
29216 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29217 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29218 #! $SHELL
29219 # Generated by $as_me.
29220 # Run this file to recreate the current configuration.
29221 # Compiler output produced by configure, useful for debugging
29222 # configure, is in config.log if it exists.
29223
29224 debug=false
29225 ac_cs_recheck=false
29226 ac_cs_silent=false
29227 SHELL=\${CONFIG_SHELL-$SHELL}
29228 _ACEOF
29229
29230 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29231 ## --------------------- ##
29232 ## M4sh Initialization.  ##
29233 ## --------------------- ##
29234
29235 # Be more Bourne compatible
29236 DUALCASE=1; export DUALCASE # for MKS sh
29237 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
29238   emulate sh
29239   NULLCMD=:
29240   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29241   # is contrary to our usage.  Disable this feature.
29242   alias -g '${1+"$@"}'='"$@"'
29243   setopt NO_GLOB_SUBST
29244 else
29245   case `(set -o) 2>/dev/null` in
29246   *posix*) set -o posix ;;
29247 esac
29248
29249 fi
29250
29251
29252
29253
29254 # PATH needs CR
29255 # Avoid depending upon Character Ranges.
29256 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29257 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29258 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29259 as_cr_digits='0123456789'
29260 as_cr_alnum=$as_cr_Letters$as_cr_digits
29261
29262 as_nl='
29263 '
29264 export as_nl
29265 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29266 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29267 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29268 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29269 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29270   as_echo='printf %s\n'
29271   as_echo_n='printf %s'
29272 else
29273   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29274     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29275     as_echo_n='/usr/ucb/echo -n'
29276   else
29277     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29278     as_echo_n_body='eval
29279       arg=$1;
29280       case $arg in
29281       *"$as_nl"*)
29282         expr "X$arg" : "X\\(.*\\)$as_nl";
29283         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29284       esac;
29285       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29286     '
29287     export as_echo_n_body
29288     as_echo_n='sh -c $as_echo_n_body as_echo'
29289   fi
29290   export as_echo_body
29291   as_echo='sh -c $as_echo_body as_echo'
29292 fi
29293
29294 # The user is always right.
29295 if test "${PATH_SEPARATOR+set}" != set; then
29296   PATH_SEPARATOR=:
29297   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29298     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29299       PATH_SEPARATOR=';'
29300   }
29301 fi
29302
29303 # Support unset when possible.
29304 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
29305   as_unset=unset
29306 else
29307   as_unset=false
29308 fi
29309
29310
29311 # IFS
29312 # We need space, tab and new line, in precisely that order.  Quoting is
29313 # there to prevent editors from complaining about space-tab.
29314 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29315 # splitting by setting IFS to empty value.)
29316 IFS=" ""        $as_nl"
29317
29318 # Find who we are.  Look in the path if we contain no directory separator.
29319 case $0 in
29320   *[\\/]* ) as_myself=$0 ;;
29321   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29322 for as_dir in $PATH
29323 do
29324   IFS=$as_save_IFS
29325   test -z "$as_dir" && as_dir=.
29326   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29327 done
29328 IFS=$as_save_IFS
29329
29330      ;;
29331 esac
29332 # We did not find ourselves, most probably we were run as `sh COMMAND'
29333 # in which case we are not to be found in the path.
29334 if test "x$as_myself" = x; then
29335   as_myself=$0
29336 fi
29337 if test ! -f "$as_myself"; then
29338   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29339   { (exit 1); exit 1; }
29340 fi
29341
29342 # Work around bugs in pre-3.0 UWIN ksh.
29343 for as_var in ENV MAIL MAILPATH
29344 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
29345 done
29346 PS1='$ '
29347 PS2='> '
29348 PS4='+ '
29349
29350 # NLS nuisances.
29351 LC_ALL=C
29352 export LC_ALL
29353 LANGUAGE=C
29354 export LANGUAGE
29355
29356 # Required to use basename.
29357 if expr a : '\(a\)' >/dev/null 2>&1 &&
29358    test "X`expr 00001 : '.*\(...\)'`" = X001; then
29359   as_expr=expr
29360 else
29361   as_expr=false
29362 fi
29363
29364 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29365   as_basename=basename
29366 else
29367   as_basename=false
29368 fi
29369
29370
29371 # Name of the executable.
29372 as_me=`$as_basename -- "$0" ||
29373 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29374          X"$0" : 'X\(//\)$' \| \
29375          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29376 $as_echo X/"$0" |
29377     sed '/^.*\/\([^/][^/]*\)\/*$/{
29378             s//\1/
29379             q
29380           }
29381           /^X\/\(\/\/\)$/{
29382             s//\1/
29383             q
29384           }
29385           /^X\/\(\/\).*/{
29386             s//\1/
29387             q
29388           }
29389           s/.*/./; q'`
29390
29391 # CDPATH.
29392 $as_unset CDPATH
29393
29394
29395
29396   as_lineno_1=$LINENO
29397   as_lineno_2=$LINENO
29398   test "x$as_lineno_1" != "x$as_lineno_2" &&
29399   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
29400
29401   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
29402   # uniformly replaced by the line number.  The first 'sed' inserts a
29403   # line-number line after each line using $LINENO; the second 'sed'
29404   # does the real work.  The second script uses 'N' to pair each
29405   # line-number line with the line containing $LINENO, and appends
29406   # trailing '-' during substitution so that $LINENO is not a special
29407   # case at line end.
29408   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
29409   # scripts with optimization help from Paolo Bonzini.  Blame Lee
29410   # E. McMahon (1931-1989) for sed's syntax.  :-)
29411   sed -n '
29412     p
29413     /[$]LINENO/=
29414   ' <$as_myself |
29415     sed '
29416       s/[$]LINENO.*/&-/
29417       t lineno
29418       b
29419       :lineno
29420       N
29421       :loop
29422       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
29423       t loop
29424       s/-\n.*//
29425     ' >$as_me.lineno &&
29426   chmod +x "$as_me.lineno" ||
29427     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
29428    { (exit 1); exit 1; }; }
29429
29430   # Don't try to exec as it changes $[0], causing all sort of problems
29431   # (the dirname of $[0] is not the place where we might find the
29432   # original and so on.  Autoconf is especially sensitive to this).
29433   . "./$as_me.lineno"
29434   # Exit status is that of the last command.
29435   exit
29436 }
29437
29438
29439 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29440   as_dirname=dirname
29441 else
29442   as_dirname=false
29443 fi
29444
29445 ECHO_C= ECHO_N= ECHO_T=
29446 case `echo -n x` in
29447 -n*)
29448   case `echo 'x\c'` in
29449   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
29450   *)   ECHO_C='\c';;
29451   esac;;
29452 *)
29453   ECHO_N='-n';;
29454 esac
29455 if expr a : '\(a\)' >/dev/null 2>&1 &&
29456    test "X`expr 00001 : '.*\(...\)'`" = X001; then
29457   as_expr=expr
29458 else
29459   as_expr=false
29460 fi
29461
29462 rm -f conf$$ conf$$.exe conf$$.file
29463 if test -d conf$$.dir; then
29464   rm -f conf$$.dir/conf$$.file
29465 else
29466   rm -f conf$$.dir
29467   mkdir conf$$.dir 2>/dev/null
29468 fi
29469 if (echo >conf$$.file) 2>/dev/null; then
29470   if ln -s conf$$.file conf$$ 2>/dev/null; then
29471     as_ln_s='ln -s'
29472     # ... but there are two gotchas:
29473     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29474     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29475     # In both cases, we have to default to `cp -p'.
29476     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29477       as_ln_s='cp -p'
29478   elif ln conf$$.file conf$$ 2>/dev/null; then
29479     as_ln_s=ln
29480   else
29481     as_ln_s='cp -p'
29482   fi
29483 else
29484   as_ln_s='cp -p'
29485 fi
29486 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29487 rmdir conf$$.dir 2>/dev/null
29488
29489 if mkdir -p . 2>/dev/null; then
29490   as_mkdir_p=:
29491 else
29492   test -d ./-p && rmdir ./-p
29493   as_mkdir_p=false
29494 fi
29495
29496 if test -x / >/dev/null 2>&1; then
29497   as_test_x='test -x'
29498 else
29499   if ls -dL / >/dev/null 2>&1; then
29500     as_ls_L_option=L
29501   else
29502     as_ls_L_option=
29503   fi
29504   as_test_x='
29505     eval sh -c '\''
29506       if test -d "$1"; then
29507         test -d "$1/.";
29508       else
29509         case $1 in
29510         -*)set "./$1";;
29511         esac;
29512         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
29513         ???[sx]*):;;*)false;;esac;fi
29514     '\'' sh
29515   '
29516 fi
29517 as_executable_p=$as_test_x
29518
29519 # Sed expression to map a string onto a valid CPP name.
29520 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29521
29522 # Sed expression to map a string onto a valid variable name.
29523 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29524
29525
29526 exec 6>&1
29527
29528 # Save the log message, to keep $[0] and so on meaningful, and to
29529 # report actual input values of CONFIG_FILES etc. instead of their
29530 # values after options handling.
29531 ac_log="
29532 This file was extended by PostgreSQL $as_me 9.0beta1, which was
29533 generated by GNU Autoconf 2.63.  Invocation command line was
29534
29535   CONFIG_FILES    = $CONFIG_FILES
29536   CONFIG_HEADERS  = $CONFIG_HEADERS
29537   CONFIG_LINKS    = $CONFIG_LINKS
29538   CONFIG_COMMANDS = $CONFIG_COMMANDS
29539   $ $0 $@
29540
29541 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29542 "
29543
29544 _ACEOF
29545
29546 case $ac_config_files in *"
29547 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29548 esac
29549
29550 case $ac_config_headers in *"
29551 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29552 esac
29553
29554
29555 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29556 # Files that config.status was made for.
29557 config_files="$ac_config_files"
29558 config_headers="$ac_config_headers"
29559 config_links="$ac_config_links"
29560 config_commands="$ac_config_commands"
29561
29562 _ACEOF
29563
29564 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29565 ac_cs_usage="\
29566 \`$as_me' instantiates files from templates according to the
29567 current configuration.
29568
29569 Usage: $0 [OPTION]... [FILE]...
29570
29571   -h, --help       print this help, then exit
29572   -V, --version    print version number and configuration settings, then exit
29573   -q, --quiet, --silent
29574                    do not print progress messages
29575   -d, --debug      don't remove temporary files
29576       --recheck    update $as_me by reconfiguring in the same conditions
29577       --file=FILE[:TEMPLATE]
29578                    instantiate the configuration file FILE
29579       --header=FILE[:TEMPLATE]
29580                    instantiate the configuration header FILE
29581
29582 Configuration files:
29583 $config_files
29584
29585 Configuration headers:
29586 $config_headers
29587
29588 Configuration links:
29589 $config_links
29590
29591 Configuration commands:
29592 $config_commands
29593
29594 Report bugs to <bug-autoconf@gnu.org>."
29595
29596 _ACEOF
29597 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29598 ac_cs_version="\\
29599 PostgreSQL config.status 9.0beta1
29600 configured by $0, generated by GNU Autoconf 2.63,
29601   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
29602
29603 Copyright (C) 2008 Free Software Foundation, Inc.
29604 This config.status script is free software; the Free Software Foundation
29605 gives unlimited permission to copy, distribute and modify it."
29606
29607 ac_pwd='$ac_pwd'
29608 srcdir='$srcdir'
29609 MKDIR_P='$MKDIR_P'
29610 AWK='$AWK'
29611 test -n "\$AWK" || AWK=awk
29612 _ACEOF
29613
29614 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29615 # The default lists apply if the user does not specify any file.
29616 ac_need_defaults=:
29617 while test $# != 0
29618 do
29619   case $1 in
29620   --*=*)
29621     ac_option=`expr "X$1" : 'X\([^=]*\)='`
29622     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29623     ac_shift=:
29624     ;;
29625   *)
29626     ac_option=$1
29627     ac_optarg=$2
29628     ac_shift=shift
29629     ;;
29630   esac
29631
29632   case $ac_option in
29633   # Handling of the options.
29634   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29635     ac_cs_recheck=: ;;
29636   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29637     $as_echo "$ac_cs_version"; exit ;;
29638   --debug | --debu | --deb | --de | --d | -d )
29639     debug=: ;;
29640   --file | --fil | --fi | --f )
29641     $ac_shift
29642     case $ac_optarg in
29643     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29644     esac
29645     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
29646     ac_need_defaults=false;;
29647   --header | --heade | --head | --hea )
29648     $ac_shift
29649     case $ac_optarg in
29650     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29651     esac
29652     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
29653     ac_need_defaults=false;;
29654   --he | --h)
29655     # Conflict between --help and --header
29656     { $as_echo "$as_me: error: ambiguous option: $1
29657 Try \`$0 --help' for more information." >&2
29658    { (exit 1); exit 1; }; };;
29659   --help | --hel | -h )
29660     $as_echo "$ac_cs_usage"; exit ;;
29661   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29662   | -silent | --silent | --silen | --sile | --sil | --si | --s)
29663     ac_cs_silent=: ;;
29664
29665   # This is an error.
29666   -*) { $as_echo "$as_me: error: unrecognized option: $1
29667 Try \`$0 --help' for more information." >&2
29668    { (exit 1); exit 1; }; } ;;
29669
29670   *) ac_config_targets="$ac_config_targets $1"
29671      ac_need_defaults=false ;;
29672
29673   esac
29674   shift
29675 done
29676
29677 ac_configure_extra_args=
29678
29679 if $ac_cs_silent; then
29680   exec 6>/dev/null
29681   ac_configure_extra_args="$ac_configure_extra_args --silent"
29682 fi
29683
29684 _ACEOF
29685 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29686 if \$ac_cs_recheck; then
29687   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29688   shift
29689   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29690   CONFIG_SHELL='$SHELL'
29691   export CONFIG_SHELL
29692   exec "\$@"
29693 fi
29694
29695 _ACEOF
29696 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29697 exec 5>>config.log
29698 {
29699   echo
29700   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29701 ## Running $as_me. ##
29702 _ASBOX
29703   $as_echo "$ac_log"
29704 } >&5
29705
29706 _ACEOF
29707 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29708 _ACEOF
29709
29710 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29711
29712 # Handling of arguments.
29713 for ac_config_target in $ac_config_targets
29714 do
29715   case $ac_config_target in
29716     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
29717     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
29718     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
29719     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
29720     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
29721     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
29722     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
29723     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
29724     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
29725     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
29726     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
29727     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
29728
29729   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
29730 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
29731    { (exit 1); exit 1; }; };;
29732   esac
29733 done
29734
29735
29736 # If the user did not use the arguments to specify the items to instantiate,
29737 # then the envvar interface is used.  Set only those that are not.
29738 # We use the long form for the default assignment because of an extremely
29739 # bizarre bug on SunOS 4.1.3.
29740 if $ac_need_defaults; then
29741   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29742   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29743   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
29744   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29745 fi
29746
29747 # Have a temporary directory for convenience.  Make it in the build tree
29748 # simply because there is no reason against having it here, and in addition,
29749 # creating and moving files from /tmp can sometimes cause problems.
29750 # Hook for its removal unless debugging.
29751 # Note that there is a small window in which the directory will not be cleaned:
29752 # after its creation but before its name has been assigned to `$tmp'.
29753 $debug ||
29754 {
29755   tmp=
29756   trap 'exit_status=$?
29757   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
29758 ' 0
29759   trap '{ (exit 1); exit 1; }' 1 2 13 15
29760 }
29761 # Create a (secure) tmp directory for tmp files.
29762
29763 {
29764   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29765   test -n "$tmp" && test -d "$tmp"
29766 }  ||
29767 {
29768   tmp=./conf$$-$RANDOM
29769   (umask 077 && mkdir "$tmp")
29770 } ||
29771 {
29772    $as_echo "$as_me: cannot create a temporary directory in ." >&2
29773    { (exit 1); exit 1; }
29774 }
29775
29776 # Set up the scripts for CONFIG_FILES section.
29777 # No need to generate them if there are no CONFIG_FILES.
29778 # This happens for instance with `./config.status config.h'.
29779 if test -n "$CONFIG_FILES"; then
29780
29781
29782 ac_cr='\r'
29783 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
29784 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
29785   ac_cs_awk_cr='\\r'
29786 else
29787   ac_cs_awk_cr=$ac_cr
29788 fi
29789
29790 echo 'BEGIN {' >"$tmp/subs1.awk" &&
29791 _ACEOF
29792
29793
29794 {
29795   echo "cat >conf$$subs.awk <<_ACEOF" &&
29796   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
29797   echo "_ACEOF"
29798 } >conf$$subs.sh ||
29799   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
29800 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
29801    { (exit 1); exit 1; }; }
29802 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
29803 ac_delim='%!_!# '
29804 for ac_last_try in false false false false false :; do
29805   . ./conf$$subs.sh ||
29806     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
29807 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
29808    { (exit 1); exit 1; }; }
29809
29810   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
29811   if test $ac_delim_n = $ac_delim_num; then
29812     break
29813   elif $ac_last_try; then
29814     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
29815 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
29816    { (exit 1); exit 1; }; }
29817   else
29818     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29819   fi
29820 done
29821 rm -f conf$$subs.sh
29822
29823 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29824 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
29825 _ACEOF
29826 sed -n '
29827 h
29828 s/^/S["/; s/!.*/"]=/
29829 p
29830 g
29831 s/^[^!]*!//
29832 :repl
29833 t repl
29834 s/'"$ac_delim"'$//
29835 t delim
29836 :nl
29837 h
29838 s/\(.\{148\}\).*/\1/
29839 t more1
29840 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
29841 p
29842 n
29843 b repl
29844 :more1
29845 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29846 p
29847 g
29848 s/.\{148\}//
29849 t nl
29850 :delim
29851 h
29852 s/\(.\{148\}\).*/\1/
29853 t more2
29854 s/["\\]/\\&/g; s/^/"/; s/$/"/
29855 p
29856 b
29857 :more2
29858 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29859 p
29860 g
29861 s/.\{148\}//
29862 t delim
29863 ' <conf$$subs.awk | sed '
29864 /^[^""]/{
29865   N
29866   s/\n//
29867 }
29868 ' >>$CONFIG_STATUS || ac_write_fail=1
29869 rm -f conf$$subs.awk
29870 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29871 _ACAWK
29872 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
29873   for (key in S) S_is_set[key] = 1
29874   FS = "\a"
29875
29876 }
29877 {
29878   line = $ 0
29879   nfields = split(line, field, "@")
29880   substed = 0
29881   len = length(field[1])
29882   for (i = 2; i < nfields; i++) {
29883     key = field[i]
29884     keylen = length(key)
29885     if (S_is_set[key]) {
29886       value = S[key]
29887       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
29888       len += length(value) + length(field[++i])
29889       substed = 1
29890     } else
29891       len += 1 + keylen
29892   }
29893
29894   print line
29895 }
29896
29897 _ACAWK
29898 _ACEOF
29899 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29900 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
29901   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
29902 else
29903   cat
29904 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
29905   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
29906 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
29907    { (exit 1); exit 1; }; }
29908 _ACEOF
29909
29910 # VPATH may cause trouble with some makes, so we remove $(srcdir),
29911 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
29912 # trailing colons and then remove the whole line if VPATH becomes empty
29913 # (actually we leave an empty line to preserve line numbers).
29914 if test "x$srcdir" = x.; then
29915   ac_vpsub='/^[  ]*VPATH[        ]*=/{
29916 s/:*\$(srcdir):*/:/
29917 s/:*\${srcdir}:*/:/
29918 s/:*@srcdir@:*/:/
29919 s/^\([^=]*=[     ]*\):*/\1/
29920 s/:*$//
29921 s/^[^=]*=[       ]*$//
29922 }'
29923 fi
29924
29925 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29926 fi # test -n "$CONFIG_FILES"
29927
29928 # Set up the scripts for CONFIG_HEADERS section.
29929 # No need to generate them if there are no CONFIG_HEADERS.
29930 # This happens for instance with `./config.status Makefile'.
29931 if test -n "$CONFIG_HEADERS"; then
29932 cat >"$tmp/defines.awk" <<\_ACAWK ||
29933 BEGIN {
29934 _ACEOF
29935
29936 # Transform confdefs.h into an awk script `defines.awk', embedded as
29937 # here-document in config.status, that substitutes the proper values into
29938 # config.h.in to produce config.h.
29939
29940 # Create a delimiter string that does not exist in confdefs.h, to ease
29941 # handling of long lines.
29942 ac_delim='%!_!# '
29943 for ac_last_try in false false :; do
29944   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
29945   if test -z "$ac_t"; then
29946     break
29947   elif $ac_last_try; then
29948     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
29949 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
29950    { (exit 1); exit 1; }; }
29951   else
29952     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29953   fi
29954 done
29955
29956 # For the awk script, D is an array of macro values keyed by name,
29957 # likewise P contains macro parameters if any.  Preserve backslash
29958 # newline sequences.
29959
29960 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
29961 sed -n '
29962 s/.\{148\}/&'"$ac_delim"'/g
29963 t rset
29964 :rset
29965 s/^[     ]*#[    ]*define[       ][      ]*/ /
29966 t def
29967 d
29968 :def
29969 s/\\$//
29970 t bsnl
29971 s/["\\]/\\&/g
29972 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
29973 D["\1"]=" \3"/p
29974 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
29975 d
29976 :bsnl
29977 s/["\\]/\\&/g
29978 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
29979 D["\1"]=" \3\\\\\\n"\\/p
29980 t cont
29981 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
29982 t cont
29983 d
29984 :cont
29985 n
29986 s/.\{148\}/&'"$ac_delim"'/g
29987 t clear
29988 :clear
29989 s/\\$//
29990 t bsnlc
29991 s/["\\]/\\&/g; s/^/"/; s/$/"/p
29992 d
29993 :bsnlc
29994 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
29995 b cont
29996 ' <confdefs.h | sed '
29997 s/'"$ac_delim"'/"\\\
29998 "/g' >>$CONFIG_STATUS || ac_write_fail=1
29999
30000 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30001   for (key in D) D_is_set[key] = 1
30002   FS = "\a"
30003 }
30004 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30005   line = \$ 0
30006   split(line, arg, " ")
30007   if (arg[1] == "#") {
30008     defundef = arg[2]
30009     mac1 = arg[3]
30010   } else {
30011     defundef = substr(arg[1], 2)
30012     mac1 = arg[2]
30013   }
30014   split(mac1, mac2, "(") #)
30015   macro = mac2[1]
30016   prefix = substr(line, 1, index(line, defundef) - 1)
30017   if (D_is_set[macro]) {
30018     # Preserve the white space surrounding the "#".
30019     print prefix "define", macro P[macro] D[macro]
30020     next
30021   } else {
30022     # Replace #undef with comments.  This is necessary, for example,
30023     # in the case of _POSIX_SOURCE, which is predefined and required
30024     # on some systems where configure will not decide to define it.
30025     if (defundef == "undef") {
30026       print "/*", prefix defundef, macro, "*/"
30027       next
30028     }
30029   }
30030 }
30031 { print }
30032 _ACAWK
30033 _ACEOF
30034 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30035   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
30036 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
30037    { (exit 1); exit 1; }; }
30038 fi # test -n "$CONFIG_HEADERS"
30039
30040
30041 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
30042 shift
30043 for ac_tag
30044 do
30045   case $ac_tag in
30046   :[FHLC]) ac_mode=$ac_tag; continue;;
30047   esac
30048   case $ac_mode$ac_tag in
30049   :[FHL]*:*);;
30050   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
30051 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
30052    { (exit 1); exit 1; }; };;
30053   :[FH]-) ac_tag=-:-;;
30054   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30055   esac
30056   ac_save_IFS=$IFS
30057   IFS=:
30058   set x $ac_tag
30059   IFS=$ac_save_IFS
30060   shift
30061   ac_file=$1
30062   shift
30063
30064   case $ac_mode in
30065   :L) ac_source=$1;;
30066   :[FH])
30067     ac_file_inputs=
30068     for ac_f
30069     do
30070       case $ac_f in
30071       -) ac_f="$tmp/stdin";;
30072       *) # Look for the file first in the build tree, then in the source tree
30073          # (if the path is not absolute).  The absolute path cannot be DOS-style,
30074          # because $ac_f cannot contain `:'.
30075          test -f "$ac_f" ||
30076            case $ac_f in
30077            [\\/$]*) false;;
30078            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30079            esac ||
30080            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
30081 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
30082    { (exit 1); exit 1; }; };;
30083       esac
30084       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30085       ac_file_inputs="$ac_file_inputs '$ac_f'"
30086     done
30087
30088     # Let's still pretend it is `configure' which instantiates (i.e., don't
30089     # use $as_me), people would be surprised to read:
30090     #    /* config.h.  Generated by config.status.  */
30091     configure_input='Generated from '`
30092           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30093         `' by configure.'
30094     if test x"$ac_file" != x-; then
30095       configure_input="$ac_file.  $configure_input"
30096       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
30097 $as_echo "$as_me: creating $ac_file" >&6;}
30098     fi
30099     # Neutralize special characters interpreted by sed in replacement strings.
30100     case $configure_input in #(
30101     *\&* | *\|* | *\\* )
30102        ac_sed_conf_input=`$as_echo "$configure_input" |
30103        sed 's/[\\\\&|]/\\\\&/g'`;; #(
30104     *) ac_sed_conf_input=$configure_input;;
30105     esac
30106
30107     case $ac_tag in
30108     *:-:* | *:-) cat >"$tmp/stdin" \
30109       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30110 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30111    { (exit 1); exit 1; }; } ;;
30112     esac
30113     ;;
30114   esac
30115
30116   ac_dir=`$as_dirname -- "$ac_file" ||
30117 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30118          X"$ac_file" : 'X\(//\)[^/]' \| \
30119          X"$ac_file" : 'X\(//\)$' \| \
30120          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30121 $as_echo X"$ac_file" |
30122     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30123             s//\1/
30124             q
30125           }
30126           /^X\(\/\/\)[^/].*/{
30127             s//\1/
30128             q
30129           }
30130           /^X\(\/\/\)$/{
30131             s//\1/
30132             q
30133           }
30134           /^X\(\/\).*/{
30135             s//\1/
30136             q
30137           }
30138           s/.*/./; q'`
30139   { as_dir="$ac_dir"
30140   case $as_dir in #(
30141   -*) as_dir=./$as_dir;;
30142   esac
30143   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
30144     as_dirs=
30145     while :; do
30146       case $as_dir in #(
30147       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30148       *) as_qdir=$as_dir;;
30149       esac
30150       as_dirs="'$as_qdir' $as_dirs"
30151       as_dir=`$as_dirname -- "$as_dir" ||
30152 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30153          X"$as_dir" : 'X\(//\)[^/]' \| \
30154          X"$as_dir" : 'X\(//\)$' \| \
30155          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30156 $as_echo X"$as_dir" |
30157     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30158             s//\1/
30159             q
30160           }
30161           /^X\(\/\/\)[^/].*/{
30162             s//\1/
30163             q
30164           }
30165           /^X\(\/\/\)$/{
30166             s//\1/
30167             q
30168           }
30169           /^X\(\/\).*/{
30170             s//\1/
30171             q
30172           }
30173           s/.*/./; q'`
30174       test -d "$as_dir" && break
30175     done
30176     test -z "$as_dirs" || eval "mkdir $as_dirs"
30177   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
30178 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
30179    { (exit 1); exit 1; }; }; }
30180   ac_builddir=.
30181
30182 case "$ac_dir" in
30183 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30184 *)
30185   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30186   # A ".." for each directory in $ac_dir_suffix.
30187   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30188   case $ac_top_builddir_sub in
30189   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30190   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30191   esac ;;
30192 esac
30193 ac_abs_top_builddir=$ac_pwd
30194 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30195 # for backward compatibility:
30196 ac_top_builddir=$ac_top_build_prefix
30197
30198 case $srcdir in
30199   .)  # We are building in place.
30200     ac_srcdir=.
30201     ac_top_srcdir=$ac_top_builddir_sub
30202     ac_abs_top_srcdir=$ac_pwd ;;
30203   [\\/]* | ?:[\\/]* )  # Absolute name.
30204     ac_srcdir=$srcdir$ac_dir_suffix;
30205     ac_top_srcdir=$srcdir
30206     ac_abs_top_srcdir=$srcdir ;;
30207   *) # Relative name.
30208     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30209     ac_top_srcdir=$ac_top_build_prefix$srcdir
30210     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30211 esac
30212 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30213
30214
30215   case $ac_mode in
30216   :F)
30217   #
30218   # CONFIG_FILE
30219   #
30220
30221   ac_MKDIR_P=$MKDIR_P
30222   case $MKDIR_P in
30223   [\\/$]* | ?:[\\/]* ) ;;
30224   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30225   esac
30226 _ACEOF
30227
30228 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30229 # If the template does not know about datarootdir, expand it.
30230 # FIXME: This hack should be removed a few years after 2.60.
30231 ac_datarootdir_hack=; ac_datarootdir_seen=
30232
30233 ac_sed_dataroot='
30234 /datarootdir/ {
30235   p
30236   q
30237 }
30238 /@datadir@/p
30239 /@docdir@/p
30240 /@infodir@/p
30241 /@localedir@/p
30242 /@mandir@/p
30243 '
30244 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30245 *datarootdir*) ac_datarootdir_seen=yes;;
30246 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30247   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30248 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30249 _ACEOF
30250 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30251   ac_datarootdir_hack='
30252   s&@datadir@&$datadir&g
30253   s&@docdir@&$docdir&g
30254   s&@infodir@&$infodir&g
30255   s&@localedir@&$localedir&g
30256   s&@mandir@&$mandir&g
30257     s&\\\${datarootdir}&$datarootdir&g' ;;
30258 esac
30259 _ACEOF
30260
30261 # Neutralize VPATH when `$srcdir' = `.'.
30262 # Shell code in configure.ac might set extrasub.
30263 # FIXME: do we really want to maintain this feature?
30264 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30265 ac_sed_extra="$ac_vpsub
30266 $extrasub
30267 _ACEOF
30268 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30269 :t
30270 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30271 s|@configure_input@|$ac_sed_conf_input|;t t
30272 s&@top_builddir@&$ac_top_builddir_sub&;t t
30273 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30274 s&@srcdir@&$ac_srcdir&;t t
30275 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30276 s&@top_srcdir@&$ac_top_srcdir&;t t
30277 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30278 s&@builddir@&$ac_builddir&;t t
30279 s&@abs_builddir@&$ac_abs_builddir&;t t
30280 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30281 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30282 $ac_datarootdir_hack
30283 "
30284 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
30285   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30286 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30287    { (exit 1); exit 1; }; }
30288
30289 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30290   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30291   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30292   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30293 which seems to be undefined.  Please make sure it is defined." >&5
30294 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30295 which seems to be undefined.  Please make sure it is defined." >&2;}
30296
30297   rm -f "$tmp/stdin"
30298   case $ac_file in
30299   -) cat "$tmp/out" && rm -f "$tmp/out";;
30300   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30301   esac \
30302   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30303 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30304    { (exit 1); exit 1; }; }
30305  ;;
30306   :H)
30307   #
30308   # CONFIG_HEADER
30309   #
30310   if test x"$ac_file" != x-; then
30311     {
30312       $as_echo "/* $configure_input  */" \
30313       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30314     } >"$tmp/config.h" \
30315       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30316 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30317    { (exit 1); exit 1; }; }
30318     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30319       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
30320 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30321     else
30322       rm -f "$ac_file"
30323       mv "$tmp/config.h" "$ac_file" \
30324         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30325 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30326    { (exit 1); exit 1; }; }
30327     fi
30328   else
30329     $as_echo "/* $configure_input  */" \
30330       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30331       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
30332 $as_echo "$as_me: error: could not create -" >&2;}
30333    { (exit 1); exit 1; }; }
30334   fi
30335  ;;
30336   :L)
30337   #
30338   # CONFIG_LINK
30339   #
30340
30341   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
30342     :
30343   else
30344     # Prefer the file from the source tree if names are identical.
30345     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
30346       ac_source=$srcdir/$ac_source
30347     fi
30348
30349     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
30350 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
30351
30352     if test ! -r "$ac_source"; then
30353       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
30354 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
30355    { (exit 1); exit 1; }; }
30356     fi
30357     rm -f "$ac_file"
30358
30359     # Try a relative symlink, then a hard link, then a copy.
30360     case $srcdir in
30361     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
30362         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
30363     esac
30364     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
30365       ln "$ac_source" "$ac_file" 2>/dev/null ||
30366       cp -p "$ac_source" "$ac_file" ||
30367       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
30368 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
30369    { (exit 1); exit 1; }; }
30370   fi
30371  ;;
30372   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
30373 $as_echo "$as_me: executing $ac_file commands" >&6;}
30374  ;;
30375   esac
30376
30377
30378   case $ac_file$ac_mode in
30379     "check_win32_symlinks":C)
30380 # Links sometimes fail undetected on Mingw -
30381 # so here we detect it and warn the user
30382 for FILE in $CONFIG_LINKS
30383  do
30384         # test -e works for symlinks in the MinGW console
30385         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
30386 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
30387  done
30388  ;;
30389     "src/include/pg_config.h":H)
30390 # Update timestamp for pg_config.h (see Makefile.global)
30391 echo >src/include/stamp-h
30392  ;;
30393     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
30394
30395   esac
30396 done # for ac_tag
30397
30398
30399 { (exit 0); exit 0; }
30400 _ACEOF
30401 chmod +x $CONFIG_STATUS
30402 ac_clean_files=$ac_clean_files_save
30403
30404 test $ac_write_fail = 0 ||
30405   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
30406 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
30407    { (exit 1); exit 1; }; }
30408
30409
30410 # configure is writing to config.log, and then calls config.status.
30411 # config.status does its own redirection, appending to config.log.
30412 # Unfortunately, on DOS this fails, as config.log is still kept open
30413 # by configure, so config.status won't be able to write to it; its
30414 # output is simply discarded.  So we exec the FD to /dev/null,
30415 # effectively closing config.log, so it can be properly (re)opened and
30416 # appended to by config.status.  When coming back to configure, we
30417 # need to make the FD available again.
30418 if test "$no_create" != yes; then
30419   ac_cs_success=:
30420   ac_config_status_args=
30421   test "$silent" = yes &&
30422     ac_config_status_args="$ac_config_status_args --quiet"
30423   exec 5>/dev/null
30424   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30425   exec 5>>config.log
30426   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30427   # would make configure fail if this is the last instruction.
30428   $ac_cs_success || { (exit 1); exit 1; }
30429 fi
30430 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30431   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30432 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
30433 fi
30434